Represents a cue of a HLS date range metadata text track.

interface DateRangeCue {
    class: undefined | string;
    content: any;
    customAttributes: Record<string, string | number | ArrayBuffer>;
    duration: undefined | number;
    endDate: undefined | Date;
    endOnNext: boolean;
    endTime: number;
    id: string;
    plannedDuration: undefined | number;
    scte35Cmd: undefined | ArrayBuffer;
    scte35In: undefined | ArrayBuffer;
    scte35Out: undefined | ArrayBuffer;
    startDate: Date;
    startTime: number;
    uid: number;
}

Hierarchy (view full)

Properties

class: undefined | string

The class of the date range cue.

Remarks


- The class is a client-defined string specifying a set of attributes with associated value semantics.

content: any

The content of the cue.

Remarks

The content differs depending on the theoplayer!TextTrackCue.track's type:
- 'emsg': Content is a Uint8Array representing the binary message data from the emsg box.
- 'eventstream': Content is the value of the messageData attribute which was specified in the manifest.
- 'ttml': Content is an intermediate TTML document’s body element. This is a view of a TTML document where all nodes in the document are active during the cue’s startTime and endTime. As a result, all begin, dur and end properties have been removed. TTML Styles, Regions and Metadata are stored in cue.styles, cue.regions, cue.metadata respectively. Combining those properties with the given content should suffice to render a TTML cue.
- 'webvtt': Content is the cue text in raw unparsed form.

customAttributes: Record<string, string | number | ArrayBuffer>

Custom attributes extracted from the cue source.

duration: undefined | number

The duration of the date range cue, in milliseconds.

endDate: undefined | Date

The playback position at which the date range cue becomes inactive, as a Date.

endOnNext: boolean

Whether end-on-next is enabled for the date range cue.

Remarks


- End-on-next results in the DateRangeCue.endDate of the date range cue becoming equal to the DateRangeCue.startDate of the next date range cue with the same DateRangeCue."class", once it is known.

endTime: number

The playback position at which the cue becomes inactive, in milliseconds.

id: string

The identifier of the cue.

plannedDuration: undefined | number

The planned duration of the date range cue, in milliseconds.

Remarks


- This is used when the exact duration is not known yet.

scte35Cmd: undefined | ArrayBuffer

The SCTE 'cmd' splice_info_section of the date range cue.

scte35In: undefined | ArrayBuffer

The SCTE 'in' splice_info_section of the date range cue.

scte35Out: undefined | ArrayBuffer

The SCTE 'out' splice_info_section of the date range cue.

startDate: Date

The playback position at which the date range cue becomes active, as a Date.

startTime: number

The playback position at which the cue becomes active, in milliseconds.

uid: number

A unique identifier of the text track cue.

Remarks


- This identifier is unique across text track cues of a THEOplayer instance and can be used to distinguish between cues.
- This identifier is a randomly generated number.