In-Stream Ad
package com.intowow.sdk
public class InStreamAd
Integration
Declare InStreamAd
Create a InStreamAd instance and keep its reference.
import com.intowow.sdk.InStreamAd;
private final static String PLACEMENT = "Obtain from your Intowow account manager";
private InStreamAd mInStreamAd = null;Initialize InStreamAd
// [NOTE]
// It is recommended to initialize as early as possible.
//
Map<String, Object> adProps = new HashMap<>();
adProps.put(AdProperty.HIDE_COUNTDOWN, false);
adProps.put(AdProperty.HIDE_SPEAKER, false);
adProps.put(AdProperty.HIDE_AD_ICON, false);
adProps.put(AdProperty.SILENT_START, false);
adProps.put(AdProperty.HIDE_NON_SKIPPABLE_BUTTON, false);
adProps.put(AdProperty.HIDE_AD_COUNT_VIEW, false);
mInStreamAd = new InStreamAd(this, PLACEMENT, adProps, mContainer);Implement InStreamAdListener to handle InStreamAd Event
Request InStreamAd
startAutoRequestAdmust be called after InStreamAd instance is initializedstartAutoRequestAdshall be called before video content is played, otherwise ad breaks in the beginning of the video, pre-roll ad especially, will be wastedPlease called
startAutoRequestAdonly one time.
Implement CEContentProgressProvider to update Video Content Status
isContentPlayerReady,getContentCurrentPositionandgetContentTotalDurationmust be implemented otherwise InStream ad will not be servedPlease read this carefully: During the time user is seeking the video, APP should always return the progress time that user start seeking instead of the current time that user has sought to. Once user stop seeking, please return the progress time that user stopped at.

Release InStreamAd
InStream ad shall at least be released along with the life cycle of video content
If you want to get more information about integration, please refer to InstreamAd, InstreamAdListener and CEContentProgressProvider.
Last updated