Class: shaka.msf.TracksManager

Constructor

new TracksManager(webTransportnon-null, controlStreamnon-null, msfTransportnon-null)

Parameters:
Name Type Description
webTransport WebTransport
controlStream shaka.msf.ControlStream
msfTransport shaka.msf.MSFTransport
Implements:
Source:

Members

FETCH_HEADER_BIGINT :number

@const
Type:
  • number
Source:

SUBGROUP_HEADER_END_BIGINT :number

@const
Type:
  • number
Source:

SUBGROUP_HEADER_START_BIGINT :number

@const
Type:
  • number
Source:

isClosing_ :boolean

Type:
  • boolean
Source:

nextRequestId_ :number

Type:
  • number
Source:

webTransport_ :WebTransport

Type:
  • WebTransport
Source:

Methods

getNextRequestId() → {number}

Get the next request ID (even numbers for client requests)
Source:
Returns:
Type
number

handleIncomingStream_(streamnon-null) → {Promise}

Handle an incoming unidirectional stream
Parameters:
Name Type Description
stream ReadableStream
Source:
Returns:
Type
Promise

handleSubgroupStream_(readernon-null, streamType) → {Promise}

Handle a SUBGROUP_HEADER stream with automatic buffering and retry.
Parameters:
Name Type Description
reader shaka.msf.Reader
streamType number
Source:
Returns:
Type
Promise

notifyCallbacks_(trackAlias, obj)

Notify all callbacks registered for a track
Parameters:
Name Type Description
trackAlias number
obj shaka.msf.Utils.MoQObject
Source:

release()

Request that this object release all internal references.
Implements:
Source:

startListeningForStreams_() → {Promise}

Start listening for incoming unidirectional streams
Source:
Returns:
Type
Promise

subscribeTrack(namespace, trackName, callback) → {Promise<number>}

Subscribe to a track by namespace and track name Returns the track alias that can be used to unsubscribe later
Parameters:
Name Type Description
namespace string
trackName string
callback shaka.msf.Utils.ObjectCallback
Source:
Returns:
Type
Promise<number>

unsubscribeTrack(trackAlias) → {Promise}

Unsubscribe from a track by track alias
Parameters:
Name Type Description
trackAlias number
Source:
Returns:
Type
Promise