public static final class HlsMediaPlaylist.Segment
extends java.lang.Object
implements java.lang.Comparable<java.lang.Long>
Modifier and Type | Field and Description |
---|---|
long |
byterangeLength
The segment's byte range length, as defined by #EXT-X-BYTERANGE, or
C.LENGTH_UNSET if
no byte range is specified. |
long |
byterangeOffset
The segment's byte range offset, as defined by #EXT-X-BYTERANGE.
|
long |
durationUs
The duration of the segment in microseconds, as defined by #EXTINF.
|
java.lang.String |
encryptionIV
The encryption initialization vector as defined by #EXT-X-KEY, or null if the segment is not
encrypted.
|
java.lang.String |
fullSegmentEncryptionKeyUri
The encryption identity key uri as defined by #EXT-X-KEY, or null if the segment does not use
full segment encryption with identity key.
|
boolean |
hasGapTag
Whether the segment is tagged with #EXT-X-GAP.
|
int |
relativeDiscontinuitySequence
The number of #EXT-X-DISCONTINUITY tags in the playlist before the segment.
|
long |
relativeStartTimeUs
The start time of the segment in microseconds, relative to the start of the playlist.
|
java.lang.String |
url
The url of the segment.
|
Constructor and Description |
---|
Segment(java.lang.String url,
long durationUs,
int relativeDiscontinuitySequence,
long relativeStartTimeUs,
java.lang.String fullSegmentEncryptionKeyUri,
java.lang.String encryptionIV,
long byterangeOffset,
long byterangeLength,
boolean hasGapTag) |
Segment(java.lang.String uri,
long byterangeOffset,
long byterangeLength) |
Modifier and Type | Method and Description |
---|---|
int |
compareTo(java.lang.Long relativeStartTimeUs) |
public final java.lang.String url
public final long durationUs
public final int relativeDiscontinuitySequence
public final long relativeStartTimeUs
public final java.lang.String fullSegmentEncryptionKeyUri
public final java.lang.String encryptionIV
public final long byterangeOffset
public final long byterangeLength
C.LENGTH_UNSET
if
no byte range is specified.public final boolean hasGapTag
public Segment(java.lang.String uri, long byterangeOffset, long byterangeLength)
uri
- See url
.byterangeOffset
- See byterangeOffset
.byterangeLength
- See byterangeLength
.public Segment(java.lang.String url, long durationUs, int relativeDiscontinuitySequence, long relativeStartTimeUs, java.lang.String fullSegmentEncryptionKeyUri, java.lang.String encryptionIV, long byterangeOffset, long byterangeLength, boolean hasGapTag)
url
- See url
.durationUs
- See durationUs
.relativeDiscontinuitySequence
- See relativeDiscontinuitySequence
.relativeStartTimeUs
- See relativeStartTimeUs
.fullSegmentEncryptionKeyUri
- See fullSegmentEncryptionKeyUri
.encryptionIV
- See encryptionIV
.byterangeOffset
- See byterangeOffset
.byterangeLength
- See byterangeLength
.hasGapTag
- See hasGapTag
.