Class SinglePeriodAdTimeline

  • All Implemented Interfaces:
    Bundleable

    @Deprecated
    public final class SinglePeriodAdTimeline
    extends ForwardingTimeline
    Deprecated.
    com.google.android.exoplayer2 is deprecated. Please migrate to androidx.media3 (which contains the same ExoPlayer code). See the migration guide for more details, including a script to help with the migration.
    A Timeline for sources that have ads.
    • Constructor Detail

      • SinglePeriodAdTimeline

        public SinglePeriodAdTimeline​(Timeline contentTimeline,
                                      AdPlaybackState adPlaybackState)
        Deprecated.
        Creates a new timeline with a single period containing ads.
        Parameters:
        contentTimeline - The timeline of the content alongside which ads will be played. It must have one window and one period.
        adPlaybackState - The state of the period's ads.