Methods
# PlayerExtensionConfig()
Config model for Player Extensions. Will not check anything.
Parameters:
Name | Type | Description |
---|---|---|
param.type |
"subtitle"
|
"audio-track"
|
"drm"
|
String with the type of extension |
param.importer |
function
|
Module async loader |
param.config |
Object
|
Object with the extension configuration |
# _getHTML5DisplayMode(mode) → {String}
Transforms the XDK Display mode to the HTML5
Parameters:
Name | Type | Description |
---|---|---|
mode |
*
|
Display mode
String
# convertTtmlTimeToSeconds(ttmlTime) → {Number}
Parameters:
Name | Type | Description |
---|---|---|
ttmlTime |
String
|
String with hh:mm:ss:msms format |
Time in seconds.ms format
Number
# deviceArrayConfigAddModule(extension, …modules) → {Object}
Generic helper.
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
extension |
"players"
|
"storages"
|
"extensions"
|
"mouse|keymapping"
|
XDK config where the modules will be injected. |
|
modules |
Object
|
<repeatable> |
XDK Module config |
XDK device config
Object
# deviceObjectConfigAddModule(extension, …modules) → {Object}
Generic helper.
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
extension |
"players"
|
"storages"
|
"extensions"
|
"mouse|keymapping"
|
XDK config where the modules will be injected. |
|
modules |
Object
|
<repeatable> |
XDK Module config |
XDK device config
Object
# getSubtitleRenderer(parentNode, className) → {function}
Generator function. Returns a SUBTITLE_UPDATE event handler that renders the subtitles. Valid for any subtitle strategy that requires a reneder, like Samsung tizen or the vtt.js one.
Parameters:
Name | Type | Description |
---|---|---|
parentNode |
Object
|
Parent node where to append the subtitles container. Defaults to body |
className |
String
|
Class name for the DOM element. defaults to subtitle |
Function to be used on a SUBTITLE_UPDATE callback
function
# loadWithExtensions(…extensions) → {Object}
Extends the device configuration with new XDK extensions
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
extensions |
any
|
<repeatable> |
Extensions configuration objects |
XDK deviceConfig with the new extensions prepend to the device config
Object
# loadWithPlayer(…player, playerConfig) → {Object}
Prepend the argument players to the device config to enable them
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
player |
any
|
<repeatable> |
|
playerConfig |
Object
|
Player config that will be pass to the player class |
XDK device config
Object
# overrideNetwork(networkConfig) → {Object}
Overrides the network configuration for a device
Parameters:
Name | Type | Description |
---|---|---|
networkConfig |
Object
|
Network configuration |
XDK device config with overriden network configuration
Object
# setVideoDisplayMode(mode) → {boolean}
Set the video display mode from the available ones
Parameters:
Name | Type | Description |
---|---|---|
mode |
*
|
True if success;
boolean
Type Definitions
Object
# ExtensionConfig
Properties:
Name | Type | Attributes | Description |
---|---|---|---|
type |
String
|
a unique string to identify the type of the extension. |
|
importer |
function
|
The function, when executed, will return
a promise for the module specified. That means
|
|
config |
Object
|
<optional> |
Optional configuration object for the specific extension. |
Object
# StorageConfig
An entry in DevicePackage's defaultConfig.
Properties:
Name | Type | Description |
---|---|---|
type |
String
|
a unique string to identify a storage type. |
importer |
function
|
The function, when executed, will return a
promise for the module specified. That means
|
Object
# StorageEntry
An entry in StorageManager.
Properties:
Name | Type | Attributes | Description |
---|---|---|---|
instance |
Object
|
<nullable> |
The created Storage implementation instance. |
importer |
function
|
The function, when executed, will return a
promise for the module specified. That means
|