Constructor
new Dialect()
- Implements:
- Source:
Members
Methods
buildAuthToken_(token) → {Uint8Array}
Builds the AUTHORIZATION_TOKEN setup parameter value.
Parameters:
| Name | Type | Description |
|---|---|---|
token |
string |
Returns:
- Type
- Uint8Array
connect(webTransportnon-null, confignon-null, authorizationTokenopt, nullable) → {Promise<!shaka.extern.MsfSession>}
Performs this draft's setup handshake over an established WebTransport
connection and returns the resulting session.
The handshake is part of the dialect because it is not stable across
drafts: draft-16 opens a single bidirectional stream and exchanges
CLIENT_SETUP and SERVER_SETUP over it, while draft-17 collapsed the two
into one SETUP message sent on each of a pair of unidirectional streams.
Parameters:
| Name | Type | Attributes | Description |
|---|---|---|---|
webTransport |
WebTransport | ||
config |
shaka.extern.MsfManifestConfiguration | ||
authorizationToken |
string |
<optional> <nullable> |
- Implements:
- Source:
Returns:
- Type
- Promise<!shaka.extern.MsfSession>
createControlStream_(readernon-null, writernon-null) → {shaka.msf.ControlStream}
Parameters:
| Name | Type | Description |
|---|---|---|
reader |
shaka.msf.Reader | |
writer |
shaka.msf.Writer |
- Source:
Returns:
getCodec() → {shaka.extern.MsfCodec}
The primitive codec for this draft, which encodes and decodes the
variable-length integers every other field is built from.
- Implements:
- Source:
Returns:
getDraftNumber() → {number}
The draft number, e.g. 16. Used to order dialects by preference during
negotiation, newest first.
- Implements:
- Source:
Returns:
- Type
- number
getName() → {string}
The draft name, matching the shaka.config.MsfVersion value this dialect is
registered under, e.g. 'draft-16'.
- Implements:
- Source:
Returns:
- Type
- string
getSubprotocol() → {string}
The WebTransport subprotocol string that selects this draft, e.g.
'moqt-16'.
- Implements:
- Source:
Returns:
- Type
- string