SsaiAd

data class SsaiAd @JvmOverloads constructor(val id: String = UUID.randomUUID().toString(), val duration: Double = -1.0, val skippableAfter: Double? = null, val clickThroughUrl: String? = null) : LinearAd

Represents an ad stitched into the media stream by an SSAI provider.

Constructors

Link copied to clipboard
constructor(id: String = UUID.randomUUID().toString(), duration: Double = -1.0, skippableAfter: Double? = null, clickThroughUrl: String? = null)

Properties

Link copied to clipboard
open override val clickThroughUrl: String?

The url the user should be redirected to when clicking the ad.

Link copied to clipboard
open override val data: AdData? = null

Holds various additional AdData.

Link copied to clipboard
open override val duration: Double

The duration of the ad.

Link copied to clipboard

VAST Extension nodes for the ad.

Link copied to clipboard
open override val height: Int = 0

The height of the ad.

Link copied to clipboard
open override val id: String

Identifier for the ad. A random UUID is generated when no provider-specific identifier is available.

Link copied to clipboard
open override val isLinear: Boolean

Determines whether an ad is linear, i.e. playback of main content needs to be paused for the ad.

Link copied to clipboard
open override val mediaFileUrl: String? = null

The corresponding media file url for the ad.

Link copied to clipboard
open override val skippableAfter: Double?

Time in seconds, after which the ad is skippable. The ad is not skippable if this property is not set.

Link copied to clipboard
open override val uiConfig: LinearAdUiConfig? = null

Holds relevant information for displaying the ad.

Link copied to clipboard
open override val width: Int = 0

The width of the ad.

Functions

Link copied to clipboard
open override fun clickThroughUrlOpened()

Callback function to track the opening of the clickThroughUrl.

Link copied to clipboard
open fun collapsed()

Callback function to track the ad collapsed state.

Link copied to clipboard
open fun expanded()

Callback function to track the ad expanded state.