data class SxConfiguration
Configuration for the advertisement overlay, click handling and other parameters. Can be used to configure the SxAdView or SxSequencer. By default the SxAdView uses the SxConfiguration.OUTSTREAM configuration and the SxSequencer the SxConfiguration.INSTREAM configuration.
<init> |
Configuration for the advertisement overlay, click handling and other parameters. Can be used to configure the SxAdView or SxSequencer. By default the SxAdView uses the SxConfiguration.OUTSTREAM configuration and the SxSequencer the SxConfiguration.INSTREAM configuration. SxConfiguration(title: Int = 0, titleStyle: Int = R.style.Player_Title, showMuteToggleButton: Boolean = true, unmuteIconStyle: Int = R.style.Player_MuteIcon_Unmute, muteIconStyle: Int = R.style.Player_MuteIcon_Mute, initialMuted: Boolean = false, visibleThreshold: Double = MINIMUM_PERCENT_VISIBLE, onEndBehaviour: SxOnEndBehaviour = NOTHING, onEndBehaviourWhenSkipped: SxOnEndBehaviour = COLLAPSE, repeatButtonStyle: Int = R.style.Player_RepeatButton, allowAdSkipping: Boolean = true, skipAdDuration: Int = -1, skipButtonText: Int = R.string.skip_button_text, skipButtonStyle: Int = R.style.Player_SkipButton, showPlaybackProgress: Boolean = true, progressBarStyle: Int = R.style.Player_ProgressBar, clickType: SxClickType = SxClickType.CLICKABLE_WITH_CONFIRMATION_DIALOG, clickThroughDialogTitle: Int = 0, clickThroughDialogMessage: Int = R.string.clickthroughDialogMessage, clickThroughDialogPositiveAnswer: Int = R.string.clickthroughDialogPositiveLabel, clickThroughDialogNegativeAnswer: Int = R.string.clickthroughDialogNegativeLabel, clickThroughListener: ((listener: (Boolean) -> Unit) -> Boolean)? = null, layoutConfiguration: SxLayoutConfiguration = SxLayoutConfiguration(), desiredBitrate: Int = -1, desiredMimeTypes: List<String> = listOf("video/mp4"), adCategories: List<String> = emptyList(), apiFrameworks: List<Int> = listOf(7), appName: String? = "", blockedCategories: List<String> = emptyList(), breakPosition: SxBreakPosition = OTHER, contentId: String = "", contentUri: String = "", domain: String = "", deviceIp: String = "", extension: List<String> = emptyList(), ifa: String = "", ifaType: String = "", inventoryState: List<String> = emptyList(), latLong: String = "", limitAdTracking: Int = 0, mediaPlayhead: String = "", placementType: SxPlacementType = UNDEFINED, playerCapabilities: List<SxPlayerCapabilities> = listOf(MUTE), regulations: List<String> = emptyList(), verificationVendors: List<String> = emptyList(), variantsWithProgress: List<SxVariant> = listOf(COMMERCIAL), useCase: SxAdUseCase = SxAdUseCase.INSTREAM, userAgent: String = USER_AGENT, timeouts: SxTimeoutConfig = SxTimeoutConfig(), gdprConsent: String? = null, handleAudioFocus: Boolean = true) |
adCategories |
List of desired ad categories. Encoded with IABN-N values. var adCategories: List<String> |
allowAdSkipping |
var allowAdSkipping: Boolean |
apiFrameworks |
Player's feature support. var apiFrameworks: List<Int> |
appName |
Configure the name of the Name for the corresponding reporting macro var appName: String? |
blockedCategories |
List of blocked ad categories. Encoded with IABN-N values. var blockedCategories: List<String> |
breakPosition |
Position of the ad break within the underlying video/audio content; 1 for preroll, 2 for first midroll, ... var breakPosition: SxBreakPosition |
clickThroughDialogMessage |
StringRes of the String to use for the message of the click through dialog. var clickThroughDialogMessage: Int |
clickThroughDialogNegativeAnswer |
StringRes of the String to use for the negative button of the click through dialog. var clickThroughDialogNegativeAnswer: Int |
clickThroughDialogPositiveAnswer |
StringRes of the String to use for the positive button of the click through dialog. var clickThroughDialogPositiveAnswer: Int |
clickThroughDialogTitle |
StringRes of the String to use for the title of the click through dialog. var clickThroughDialogTitle: Int |
clickThroughListener |
If defined and clickType is
SxClickType.CLICKABLE_WITH_CONFIRMATION_DIALOG this method will be invoked when a user tapped
on an advertisement.
If you want the SDK to show the dialog to the user just return var clickThroughListener: ((listener: (Boolean) -> Unit) -> Boolean)? |
clickType |
Defines the behaviour when user taps on a video of an advertisement. var clickType: SxClickType |
contentId |
Publisher-specific content identifier for the content asset into which the ad is being loaded or inserted. Only applicable to in-stream ads. var contentId: String |
contentUri |
var contentUri: String |
desiredBitrate |
Defines a preferred bitrate for the advertisement clips. By default the bitrate is determined automatically by the backend. var desiredBitrate: Int |
desiredMimeTypes |
Defines preferred mime types to use. By default the bitrate is determined automatically by the backend. var desiredMimeTypes: List<String> |
deviceIp |
IP address of the device that is rendering the ad to the end user. Only relevant when another device (server) is making the request on behalf of that client. var deviceIp: String |
domain |
var domain: String |
extension |
var extension: List<String> |
gdprConsent |
base64-encoded Cookie Value of IAB GDPR consent info that is used as
var gdprConsent: String? |
handleAudioFocus |
var handleAudioFocus: Boolean |
ifa |
A resettable advertising ID from a device-specific advertising ID scheme, such as Android’s Advertising ID in UUID format or based on the IAB Tech Lab’s Guidelines for IFA on OTT platforms. var ifa: String |
ifaType |
String value indicating the type of IFA included in the IFA macro var ifaType: String |
initialMuted |
var initialMuted: Boolean |
inventoryState |
var inventoryState: List<String> |
latLong |
var latLong: String |
layoutConfiguration |
Defines the layout constraints of the video player. Defaulting to a horizontal var layoutConfiguration: SxLayoutConfiguration |
limitAdTracking |
The limit ad tracking setting of a device-specific advertising ID
scheme. This value is a boolean, with var limitAdTracking: Int |
mediaPlayhead |
Deprecated: Playhead for the video or audio content (NOT the ad creative). var mediaPlayhead: String |
muteIconStyle |
StyleRes of the style for the mute button used when audio is not muted. so next touch would mute audio. var muteIconStyle: Int |
onEndBehaviour |
Defines the behaviour when the advertisement and all separator clips have finished playback without getting skipped. The behaviour for a skipped advertisement is defined in onEndBehaviourWhenSkipped. Only relevant for the SxAdUseCase.OUTSTREAM use case. var onEndBehaviour: SxOnEndBehaviour |
onEndBehaviourWhenSkipped |
Defines the behaviour when the advertisement and all separator clips have finished playback after the user skipped one of the advertisement clips. Only relevant for the SxAdUseCase.OUTSTREAM use case. var onEndBehaviourWhenSkipped: SxOnEndBehaviour |
placementType |
Indicates the type of advertisement placement. Defaulting to UNDEFINED. var placementType: SxPlacementType |
playerCapabilities |
List of SxPlayerCapabilities supported by the player. var playerCapabilities: List<SxPlayerCapabilities> |
progressBarStyle |
StyleRes of the progress bar style. Defaulting to a white progress bar above a dark background. Style should be extended by android:Widget.Material.ProgressBar.Horizontal var progressBarStyle: Int |
regulations |
List of applicable regulations (possible: gdpr, coppa). var regulations: List<String> |
repeatButtonStyle |
StyleRes of the style for the repeat button shown when SxOnEndBehaviour.REPEAT_BUTTON is used as end behaviour. Only relevant for the SxAdUseCase.OUTSTREAM use case. var repeatButtonStyle: Int |
showMuteToggleButton |
var showMuteToggleButton: Boolean |
showPlaybackProgress |
var showPlaybackProgress: Boolean |
skipAdDuration |
Duration in seconds after the advertisement becomes skipable. Can be overwritten by advertisement tag. var skipAdDuration: Int |
skipButtonStyle |
StyleRes of the skip button style. var skipButtonStyle: Int |
skipButtonText |
StringRes of the String for the skip button label. var skipButtonText: Int |
timeouts |
Defines all possible timeouts used by this SDK. See SxTimeoutConfig for more details. var timeouts: SxTimeoutConfig |
title |
StringRes of the String to show in the upper left corner of the advertisement. var title: Int |
titleStyle |
StyleRes of the style for the title. var titleStyle: Int |
unmuteIconStyle |
StyleRes of the style for the mute button used when audio is muted. so next touch would unmute audio. var unmuteIconStyle: Int |
useCase |
Defines the SxAdUseCase of the ad that is used with this configuration. var useCase: SxAdUseCase |
userAgent |
Defines the user agent that is used for the outbound communication with the core as well as for all request made by the ExoPlayer (when using ExoWrapper or InstreamExoWrapper). var userAgent: String |
variantsWithProgress |
SxVariants which will have an active progress bar. var variantsWithProgress: List<SxVariant> |
verificationVendors |
List of VAST Verification vendor attribute values that the player / client supports. var verificationVendors: List<String> |
visibleThreshold |
Relative amount of the video player to be visible to the user until it is interpreted as "visible" so playback can start/continue. If the video players visibility is not interpreted as "visible", playback will pause. Accepts a range from 0.0 (0% -> The video player visibility is always interpreted as "visible" no matter how much of it is visible to the user) to 1.0 (100% -> Only when everything of the video player is visible to the user the visibility will be interpreted as "visible"). Defaulting to 0.5. Only relevant for the SxAdUseCase.OUTSTREAM use case. var visibleThreshold: Double |
string |
fun Context.string(id: Int): String? |
toString |
fun toString(context: Context): String |
INSTREAM |
Configuration which is suitable for most instream usecases. val INSTREAM: SxConfiguration |
OUTSTREAM |
Configuration which is suitable for most outstream usecases. val OUTSTREAM: SxConfiguration |
isInstream |
val SxConfiguration.isInstream: Boolean |
isOutstream |
val SxConfiguration.isOutstream: Boolean |