Class: PlaylistPlugin

PlaylistPlugin~ PlaylistPlugin


new PlaylistPlugin(player [, options])

PlaylistPlugin Plugin
You can jump between programs, assets and external streams in the playlist.
The 'selected' source will be updated during playback.
There is a Pop-up menu 'playlistButton' for the playlist.
Playlist is independent of the Pop-up menu and 'playlistButton' can be exclude, your can render the playlist GUI by yourself.
You can't jump between programs in a channel it will always play next source in the playlist.
After last source in the playlist has been played, playback will stop.

Load playlist and start playback with first or selected source with SRC method

Parameters:
Name Type Argument Description
player Player

The Player that this class should be attached to.

options Object <optional>

The key/value store of player options.

Extends

  • videojs.Plugin

Members


autoSequence

Get autoSequence option


autoSequence

Set autoSequence option


index

Get the selected Source Index


index

Set and play the Source index


length

length, number of sources


sources

Returns a list with sources

Methods


clear()

clear the sources


currentSource(source)

Returns the current source object.

Parameters:
Name Type Description
source Tech~SourceObject

The source object you want to play.

   If not provided, this method acts as a getter.
Returns:

The current source object

Type
Tech~SourceObject

dispose()

dispose PlaylistPlugin


next()

Play next source


previous()

Play previous source


replay()

replay current src


src( [source])

Get or set the video source.

Parameters:
Name Type Argument Description
source Tech~SourceObject | Array.<Tech~SourceObject> | string <optional>

A SourceObject, an array of SourceObjects, or a string referencing
a URL to a media source. It is highly recommended that an object
or array of objects is used here, so that source selection
algorithms can take the type into account.

   If not provided, this method acts as a getter.
Returns:

If the source argument is missing, returns the current source
URL. Otherwise, returns nothing/undefined.

Type
string | undefined

Class: PlaylistPlugin

PlaylistPlugin~ PlaylistPlugin


new PlaylistPlugin(player [, options])

Create the PlaylistPlugin

Parameters:
Name Type Argument Description
player Player

The Player that this class should be attached to.

options Object <optional>

The key/value store of player options.

Members


autoSequence

Get autoSequence option


autoSequence

Set autoSequence option


index

Get the selected Source Index


index

Set and play the Source index


length

length, number of sources


sources

Returns a list with sources

Methods


clear()

clear the sources


currentSource(source)

Returns the current source object.

Parameters:
Name Type Description
source Tech~SourceObject

The source object you want to play.

   If not provided, this method acts as a getter.
Returns:

The current source object

Type
Tech~SourceObject

dispose()

dispose PlaylistPlugin


next()

Play next source


previous()

Play previous source


replay()

replay current src


src( [source])

Get or set the video source.

Parameters:
Name Type Argument Description
source Tech~SourceObject | Array.<Tech~SourceObject> | string <optional>

A SourceObject, an array of SourceObjects, or a string referencing
a URL to a media source. It is highly recommended that an object
or array of objects is used here, so that source selection
algorithms can take the type into account.

   If not provided, this method acts as a getter.
Returns:

If the source argument is missing, returns the current source
URL. Otherwise, returns nothing/undefined.

Type
string | undefined