ServerSideAdInsertionMediaSource.AdPlaybackStateUpdater


interface ServerSideAdInsertionMediaSource.AdPlaybackStateUpdater


Receives ad playback state update requests when the Timeline of the content media source has changed.

Summary

Public functions

Boolean

Called when the content source has refreshed the timeline.

Public functions

onAdPlaybackStateUpdateRequested

fun onAdPlaybackStateUpdateRequested(contentTimeline: Timeline!): Boolean

Called when the content source has refreshed the timeline.

If true is returned the source refresh publication is deferred, to wait for an setAdPlaybackStates ad playback state update}. If false is returned, the source refresh is immediately published.

Called on the playback thread.

Parameters
contentTimeline: Timeline!

The Timeline of the wrapped content media source.

Returns
Boolean

true to defer the source refresh publication, or false to immediately publish the source refresh.