Interface MediaTrackList

List of media tracks.

interface MediaTrackList {
    length: number;
    addEventListener<TType>(type: TType | readonly TType[], listener: EventListener<TrackListEventMap[TType]>): void;
    item(index: number): MediaTrack;
    removeEventListener<TType>(type: TType | readonly TType[], listener: EventListener<TrackListEventMap[TType]>): void;
    [index: number]: MediaTrack;
}

Hierarchy (view full)

Indexable

  • [index: number]: MediaTrack

    Index signature to get the media track at the requested index in the list.

Properties

length: number

The number of media tracks in the list.

Methods

  • Return the media track at the requested index in the list.

    Parameters

    • index: number

      A number representing the index of a media track in the list.

    Returns MediaTrack

    The media track with index index in the list.