Class: shaka.media.AdaptationSet

Constructor

new AdaptationSet(root, candidatesopt, non-null)

Parameters:
Name Type Attributes Description
root shaka.extern.Variant The variant that all other variants will be tested against when being added to the adaptation set. If a variant is not compatible with the root, it will not be added.
candidates Iterable.<shaka.extern.Variant> <optional>
Variants that may be compatible with the root and should be added if compatible. If a candidate is not compatible, it will not end up in the adaptation set.
Source:

Members

(private, non-null) variants_ :Set.<shaka.extern.Variant>

Type:
Source:

Methods

(static) areAdaptable(a, b) → {boolean}

Parameters:
Name Type Description
a shaka.extern.Variant
b shaka.extern.Variant
Source:
Returns:
Type
boolean

(private, static) areAudiosCompatible_(a, b) → {boolean}

Check if we can switch between two audio streams.
Parameters:
Name Type Description
a shaka.extern.Stream
b shaka.extern.Stream
Source:
Returns:
Type
boolean

(private, static) areRolesEqual_(anon-null, bnon-null) → {boolean}

Check if two role lists are the equal. This will take into account all unique behaviours when comparing roles.
Parameters:
Name Type Description
a Iterable.<string>
b Iterable.<string>
Source:
Returns:
Type
boolean

(private, static) areVideosCompatible_(a, b) → {boolean}

Check if we can switch between two video streams.
Parameters:
Name Type Description
a shaka.extern.Stream
b shaka.extern.Stream
Source:
Returns:
Type
boolean

(private, static) canTransitionBetween_(a, b) → {boolean}

Check if we can switch between two streams based on their codec and mime type.
Parameters:
Name Type Description
a shaka.extern.Stream
b shaka.extern.Stream
Source:
Returns:
Type
boolean

add(variant) → {boolean}

Parameters:
Name Type Description
variant shaka.extern.Variant
Source:
Returns:
Type
boolean

canInclude(variant) → {boolean}

Check if |variant| can be included with the set. If |canInclude| returns |false|, calling |add| will result in it being ignored.
Parameters:
Name Type Description
variant shaka.extern.Variant
Source:
Returns:
Type
boolean

values() → (non-null) {Iterable.<shaka.extern.Variant>}

Source:
Returns:
Type
Iterable.<shaka.extern.Variant>