AnnotoPlayer

Hierarchy

AnnotoPlayer

Constructors

constructor

new AnnotoPlayer(logger: LoggerInterface, widget: WidgetServiceInterface): AnnotoPlayer

Parameters:

Name

Type

logger

LoggerInterface

widget

WidgetServiceInterface

Returns: AnnotoPlayer

Properties

videojs

● videojs: any = vjs

Accessors

aspectRatio

getaspectRatio(): PlayerAspectRatio

Returns: PlayerAspectRatio

currentSrc

getcurrentSrc(): SourceObject

Returns: SourceObject

currentTime

getcurrentTime(): number

Returns: number

duration

getduration(): number

Returns: number

fullscreen

getfullscreen(): boolean

Returns: boolean

isSetup

getisSetup(): boolean

Returns: boolean

paused

getpaused(): boolean

Returns: boolean

Methods

addTextTrack

addTextTrack(trackOpts: TextTrackOptions): Promise<void> | Promise<HTMLTrackElement>

Parameters:

Name

Type

trackOpts

TextTrackOptions

Returns: Promise<void> | Promise<HTMLTrackElement>

close

close(): Promise<void>

Returns: Promise<void>

closeWidget

closeWidget(): Promise<void>

Returns: Promise<void>

layout

layout(): Promise<LayoutPlugin>

Returns: Promise<LayoutPlugin>

loadSrc

loadSrc(src?: SourceObject, pipSrc?: SecondarySourceObject, audioSource?: AudioSource): Promise<AnnotoPlayer>

Parameters:

Name

Type

Optional src

SourceObject

Optional pipSrc

SecondarySourceObject

Optional audioSource

AudioSource

Returns: Promise<AnnotoPlayer>

loadWidget

loadWidget(host?: HTMLElement): Promise<void>

Parameters:

Name

Type

Optional host

HTMLElement

Returns: Promise<void>

off

off(eventT: PlayerEvent, cb: PlayerEventCallback): Promise<void>

Parameters:

Name

Type

eventT

PlayerEvent

cb

PlayerEventCallback

Returns: Promise<void>

on

on(eventT: PlayerEvent, cb: PlayerEventCallback): Promise<void>

Parameters:

Name

Type

eventT

PlayerEvent

cb

PlayerEventCallback

Returns: Promise<void>

once

once(eventT: PlayerEvent, cb: PlayerEventCallback): Promise<void>

Parameters:

Name

Type

eventT

PlayerEvent

cb

PlayerEventCallback

Returns: Promise<void>

pause

pause(): Promise<void>

Returns: Promise<void>

pip

pip(): Promise<PipPlugin>

Returns: Promise<PipPlugin>

play

play(): Promise<void>

Returns: Promise<void>

removeTextTrackKind

removeTextTrackKind(kind: TextTrackKind): Promise<void>

Parameters:

Name

Type

kind

TextTrackKind

Returns: Promise<void>

reset

reset(): Promise<void>

Returns: Promise<void>

setAspectRatio

setAspectRatio(ratio: PlayerAspectRatio): Promise<any>

Parameters:

Name

Type

ratio

PlayerAspectRatio

Returns: Promise<any>

setAutioSource

setAutioSource(source?: AudioSource): Promise<void>

Parameters:

Name

Type

Default value

Default value source

AudioSource

"primary"

Returns: Promise<void>

setAutoplay

setAutoplay(val: boolean): void

Parameters:

Name

Type

val

boolean

Returns: void

setPipLayout

setPipLayout(params: LayoutParams): Promise<void>

Parameters:

Name

Type

params

LayoutParams

Returns: Promise<void>

setPipUI

setPipUI(ui: PipPluginUI): Promise<void>

Parameters:

Name

Type

ui

PipPluginUI

Returns: Promise<void>

setPoster

setPoster(posterUrl: string): Promise<void>

Parameters:

Name

Type

posterUrl

string

Returns: Promise<void>

setup

setup(element: string | Element, options?: PlayerOptions): Promise<PlayerImplementation>

Parameters:

Name

Type

Default value

element

string | Element

-

Default value options

PlayerOptions

{}

Returns: Promise<PlayerImplementation>

setupWidget

setupWidget(options?: WidgetOptions): Promise<void>

Parameters:

Name

Type

Optional options

WidgetOptions

Returns: Promise<void>

timeCut

timeCut(): Promise<TimeCutPlugin>

Returns: Promise<TimeCutPlugin>