AdPlayer.AdPlayerSettings, AdPlayer.Listener<T>
Modifier and Type | Method and Description |
---|---|
void |
addListener(AdPlayer.Listener<com.ooyala.pulse.PulseVideoAd> listener)
Adds a
AdPlayer.Listener . |
static PulseAdPlayer |
createWithExoplayer(BaseVideoView baseVideoView,
com.ooyala.pulse.PulseAdBreak pulseAdBreak,
AdPlayer.Listener<com.ooyala.pulse.PulseVideoAd> listener,
com.brightcove.pulse.PulseAdPlayer.PulseOnClickListener pulseOnClickListener)
Creates a
PulseAdPlayer using an ExoAdPlayer to delegate playback commands. |
void |
loadAd(com.ooyala.pulse.PulseVideoAd pulseVideoAd)
Loads an ad of type T.
|
void |
pauseAd()
Pauses an ad.
|
void |
playAd()
Plays an ad.
|
void |
release()
Releases the
AdPlayer . |
void |
removeListener(AdPlayer.Listener<com.ooyala.pulse.PulseVideoAd> listener)
Removes a
AdPlayer.Listener . |
void |
seekTo(long position)
Seeks to the specified position.
|
void |
skipAd()
Skips the current ad.
|
@NonNull public static PulseAdPlayer createWithExoplayer(@NonNull BaseVideoView baseVideoView, @NonNull com.ooyala.pulse.PulseAdBreak pulseAdBreak, @NonNull AdPlayer.Listener<com.ooyala.pulse.PulseVideoAd> listener, @NonNull com.brightcove.pulse.PulseAdPlayer.PulseOnClickListener pulseOnClickListener)
PulseAdPlayer
using an ExoAdPlayer
to delegate playback commands.baseVideoView
- the video view where the content video is displayed.pulseAdBreak
- the current pulse ad break.listener
- a listener to receive playback events.pulseOnClickListener
- the listener to receive UI/click events.PulseAdPlayer
.public void addListener(@NonNull AdPlayer.Listener<com.ooyala.pulse.PulseVideoAd> listener)
AdPlayer
AdPlayer.Listener
.addListener
in interface AdPlayer<com.ooyala.pulse.PulseVideoAd>
listener
- listener to be added.public void removeListener(@NonNull AdPlayer.Listener<com.ooyala.pulse.PulseVideoAd> listener)
AdPlayer
AdPlayer.Listener
.removeListener
in interface AdPlayer<com.ooyala.pulse.PulseVideoAd>
listener
- listener to be removed.public void loadAd(@NonNull com.ooyala.pulse.PulseVideoAd pulseVideoAd)
AdPlayer
public void playAd()
AdPlayer
public void pauseAd()
AdPlayer
public void seekTo(long position)
AdPlayer