public abstract class

SegmentBase.MultiSegmentBase

extends SegmentBase

 java.lang.Object

androidx.media3.exoplayer.dash.manifest.SegmentBase

↳androidx.media3.exoplayer.dash.manifest.SegmentBase.MultiSegmentBase

Subclasses:

SegmentBase.SegmentList, SegmentBase.SegmentTemplate

Overview

A SegmentBase that consists of multiple segments.

Summary

Constructors
publicMultiSegmentBase(RangedUri initialization, long timescale, long presentationTimeOffset, long startNumber, long duration, java.util.List<SegmentBase.SegmentTimelineElement> segmentTimeline, long availabilityTimeOffsetUs, long timeShiftBufferDepthUs, long periodStartUnixTimeUs)

Methods
public longgetAvailableSegmentCount(long periodDurationUs, long nowUnixTimeUs)

See DashSegmentIndex.getAvailableSegmentCount(long, long).

public longgetFirstAvailableSegmentNum(long periodDurationUs, long nowUnixTimeUs)

See DashSegmentIndex.getFirstAvailableSegmentNum(long, long).

public longgetFirstSegmentNum()

See DashSegmentIndex.getFirstSegmentNum().

public longgetNextSegmentAvailableTimeUs(long periodDurationUs, long nowUnixTimeUs)

See DashSegmentIndex.getNextSegmentAvailableTimeUs(long, long).

public abstract longgetSegmentCount(long periodDurationUs)

See DashSegmentIndex.getSegmentCount(long).

public final longgetSegmentDurationUs(long sequenceNumber, long periodDurationUs)

See DashSegmentIndex.getDurationUs(long, long).

public longgetSegmentNum(long timeUs, long periodDurationUs)

See DashSegmentIndex.getSegmentNum(long, long).

public final longgetSegmentTimeUs(long sequenceNumber)

See DashSegmentIndex.getTimeUs(long).

public abstract RangedUrigetSegmentUrl(Representation representation, long index)

Returns a RangedUri defining the location of a segment for the given index in the given representation.

public booleanisExplicit()

See DashSegmentIndex.isExplicit()

from SegmentBasegetInitialization, getPresentationTimeOffsetUs
from java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructors

public MultiSegmentBase(RangedUri initialization, long timescale, long presentationTimeOffset, long startNumber, long duration, java.util.List<SegmentBase.SegmentTimelineElement> segmentTimeline, long availabilityTimeOffsetUs, long timeShiftBufferDepthUs, long periodStartUnixTimeUs)

Parameters:

initialization: A RangedUri corresponding to initialization data, if such data exists.
timescale: The timescale in units per second.
presentationTimeOffset: The presentation time offset. The value in seconds is the division of this value and timescale.
startNumber: The sequence number of the first segment.
duration: The duration of each segment in the case of fixed duration segments. The value in seconds is the division of this value and timescale. If segmentTimeline is non-null then this parameter is ignored.
segmentTimeline: A segment timeline corresponding to the segments. If null, then segments are assumed to be of fixed duration as specified by the duration parameter.
availabilityTimeOffsetUs: The offset to the current realtime at which segments become available in microseconds, or C.TIME_UNSET if not applicable.
timeShiftBufferDepthUs: The time shift buffer depth in microseconds.
periodStartUnixTimeUs: The start of the enclosing period in microseconds since the Unix epoch.

Methods

public long getSegmentNum(long timeUs, long periodDurationUs)

See DashSegmentIndex.getSegmentNum(long, long).

public final long getSegmentDurationUs(long sequenceNumber, long periodDurationUs)

See DashSegmentIndex.getDurationUs(long, long).

public final long getSegmentTimeUs(long sequenceNumber)

See DashSegmentIndex.getTimeUs(long).

public abstract RangedUri getSegmentUrl(Representation representation, long index)

Returns a RangedUri defining the location of a segment for the given index in the given representation.

See DashSegmentIndex.getSegmentUrl(long).

public long getFirstSegmentNum()

See DashSegmentIndex.getFirstSegmentNum().

public long getFirstAvailableSegmentNum(long periodDurationUs, long nowUnixTimeUs)

See DashSegmentIndex.getFirstAvailableSegmentNum(long, long).

public long getAvailableSegmentCount(long periodDurationUs, long nowUnixTimeUs)

See DashSegmentIndex.getAvailableSegmentCount(long, long).

public long getNextSegmentAvailableTimeUs(long periodDurationUs, long nowUnixTimeUs)

See DashSegmentIndex.getNextSegmentAvailableTimeUs(long, long).

public boolean isExplicit()

See DashSegmentIndex.isExplicit()

public abstract long getSegmentCount(long periodDurationUs)

See DashSegmentIndex.getSegmentCount(long).