HlsMediaPlaylist.SegmentBase


class HlsMediaPlaylist.SegmentBase : Comparable

Known direct subclasses
HlsMediaPlaylist.Part

A media part.

HlsMediaPlaylist.Segment

Media segment reference.


The base for a Segment or a Part required for playback.

Summary

Public functions

Int
compareTo(relativeStartTimeUs: Long!)

Public properties

Long

The segment's byte range length, as defined by #EXT-X-BYTERANGE, #EXT-X-PART or #EXT-X-PRELOAD-HINT, or LENGTH_UNSET if no byte range is specified or the byte range is open-ended.

Long

The segment's byte range offset, as defined by #EXT-X-BYTERANGE, #EXT-X-PART or #EXT-X-PRELOAD-HINT.

DrmInitData?

DRM initialization data for sample decryption, or null if the segment does not use CDM-DRM protection.

Long

The duration of the segment in microseconds, as defined by #EXTINF or #EXT-X-PART.

String?

The encryption initialization vector as defined by #EXT-X-KEY, or null if the segment is not encrypted.

String?

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

Whether the segment is marked as a gap.

HlsMediaPlaylist.Segment?

The media initialization section for this segment, as defined by #EXT-X-MAP.

Int

The number of #EXT-X-DISCONTINUITY tags in the playlist before the segment.

Long

The start time of the segment in microseconds, relative to the start of the playlist.

String!

The url of the segment.

Public functions

compareTo

fun compareTo(relativeStartTimeUs: Long!): Int

Public properties

byteRangeLength

val byteRangeLengthLong

The segment's byte range length, as defined by #EXT-X-BYTERANGE, #EXT-X-PART or #EXT-X-PRELOAD-HINT, or LENGTH_UNSET if no byte range is specified or the byte range is open-ended.

byteRangeOffset

val byteRangeOffsetLong

The segment's byte range offset, as defined by #EXT-X-BYTERANGE, #EXT-X-PART or #EXT-X-PRELOAD-HINT.

drmInitData

val drmInitDataDrmInitData?

DRM initialization data for sample decryption, or null if the segment does not use CDM-DRM protection.

durationUs

val durationUsLong

The duration of the segment in microseconds, as defined by #EXTINF or #EXT-X-PART.

encryptionIV

val encryptionIVString?

The encryption initialization vector as defined by #EXT-X-KEY, or null if the segment is not encrypted.

fullSegmentEncryptionKeyUri

val fullSegmentEncryptionKeyUriString?

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.

hasGapTag

val hasGapTagBoolean

Whether the segment is marked as a gap.

initializationSegment

val initializationSegmentHlsMediaPlaylist.Segment?

The media initialization section for this segment, as defined by #EXT-X-MAP. May be null if the media playlist does not define a media initialization section for this segment. The same instance is used for all segments that share an EXT-X-MAP tag.

relativeDiscontinuitySequence

val relativeDiscontinuitySequenceInt

The number of #EXT-X-DISCONTINUITY tags in the playlist before the segment.

relativeStartTimeUs

val relativeStartTimeUsLong

The start time of the segment in microseconds, relative to the start of the playlist.

url

val urlString!

The url of the segment.