BlazeIMADelegate - Android
BlazeIMADelegate defines optional callbacks for IMA ad events, errors, and ad tag configuration.
onIMAAdEvent
fun onIMAAdEvent(eventType: BlazeIMAHandlerEventType, adInfo: BlazeImaAdInfo?) {}Called when an ad event fires. Use for click handling, impressions, or logging.
Parameters:
- eventType: Event type from BlazeIMAHandlerEventType.
- adInfo: Extra info about the ad, when available.
onIMAAdError
fun onIMAAdError(errMsg: String) {}Called when an ad-related error occurs.
Parameters:
- errMsg: Error message.
customIMASettings
suspend fun customIMASettings(requestData: BlazeIMAAdRequestInformation): ImaSdkSettings? {
return null
}Called when the Experiences SDK creates a player instance. Return an ImaSdkSettings instance for the SDK to use. If you return null, the SDK uses default IMA settings.
Parameters:
- requestData: Request context from BlazeIMAAdRequestInformation.
additionalIMATagQueryParams
suspend fun additionalIMATagQueryParams(requestData: BlazeIMAAdRequestInformation): Map<String, String> {
return emptyMap()
}Called each time IMA loads for a video. Return query parameters to append to the ad tag URL (including for user consent).
Parameters:
- requestData: Request context from BlazeIMAAdRequestInformation.
overrideAdTagUrl
suspend fun overrideAdTagUrl(requestData: BlazeIMAAdRequestInformation): String? {
return null
}Called each time IMA loads for a video. Return a full ad tag URL to override the default.
Parameters:
- requestData: Request context from BlazeIMAAdRequestInformation.
Updated 11 days ago
Did this page help you?
