Search
Preparing search index...
The search index is not available
DefinitelyTyped
Inherited
Private
Externals
Only exported
YT
Player
Class Player
Index
Constructor methods
constructor
Properties
size
Methods
addEventListener
clearVideo
cueVideoById
cueVideoByUrl
getAvailablePlaybackRates
getCurrentTime
getDuration
getPlaybackRate
getPlayerState
getPlaylist
getPlaylistIndex
getVideoBytesLoaded
getVideoBytesTotal
getVideoEmbedCode
getVideoLoadedFraction
getVideoStartBytes
getVideoUrl
getVolume
isMuted
loadVideoById
loadVideoByUrl
mute
nextVideo
pauseVideo
playVideo
playVideoAt
previousVideo
seekTo
setLoop
setPlaybackRate
setShuffle
setSize
setVolume
stopVideo
unMute
Constructor methods
constructor
(
id
:
string
, playerOptions
:
PlayerOptions
)
:
Player
Parameters
id:
string
playerOptions:
PlayerOptions
Returns
Player
Properties
public
size
:
any
Methods
public
addEventListener
(
event
:
string
, listener
:
string
)
Parameters
event:
string
listener:
string
public
clearVideo
(
)
public
cueVideoById
(
videoId
:
string
, startSeconds
?:
number
, suggestedQuality
?:
string
)
Parameters
videoId:
string
startSeconds?:
number
optional
suggestedQuality?:
string
optional
public
cueVideoById
(
VideoByIdParams
:
any
)
Parameters
VideoByIdParams:
any
public
cueVideoByUrl
(
mediaContentUrl
:
string
, startSeconds
?:
number
, suggestedQuality
?:
string
)
Parameters
mediaContentUrl:
string
startSeconds?:
number
optional
suggestedQuality?:
string
optional
public
cueVideoByUrl
(
VideoByUrlParams
:
any
)
Parameters
VideoByUrlParams:
any
public
getAvailablePlaybackRates
(
)
:
Array<number>
Returns
Array<number>
public
getCurrentTime
(
)
:
number
Returns
number
public
getDuration
(
)
:
number
Returns
number
public
getPlaybackRate
(
)
:
number
Returns
number
public
getPlayerState
(
)
:
number
Returns
number
public
getPlaylist
(
)
:
Array<any>
Returns
Array<any>
public
getPlaylistIndex
(
)
:
number
Returns
number
public
getVideoBytesLoaded
(
)
:
number
Returns
number
public
getVideoBytesTotal
(
)
:
number
Returns
number
public
getVideoEmbedCode
(
)
:
string
Returns
string
public
getVideoLoadedFraction
(
)
:
number
Returns
number
public
getVideoStartBytes
(
)
:
number
Returns
number
public
getVideoUrl
(
)
:
string
Returns
string
public
getVolume
(
)
:
number
Returns
number
public
isMuted
(
)
:
boolean
Returns
boolean
public
loadVideoById
(
videoId
:
string
, startSeconds
?:
number
, suggestedQuality
?:
string
)
Parameters
videoId:
string
startSeconds?:
number
optional
suggestedQuality?:
string
optional
public
loadVideoById
(
VideoByIdParams
:
any
)
Parameters
VideoByIdParams:
any
public
loadVideoByUrl
(
mediaContentUrl
:
string
, startSeconds
?:
number
, suggestedQuality
?:
string
)
Parameters
mediaContentUrl:
string
startSeconds?:
number
optional
suggestedQuality?:
string
optional
public
loadVideoByUrl
(
VideoByUrlParams
:
any
)
Parameters
VideoByUrlParams:
any
public
mute
(
)
public
nextVideo
(
)
public
pauseVideo
(
)
public
playVideo
(
)
public
playVideoAt
(
index
:
number
)
Parameters
index:
number
public
previousVideo
(
)
public
seekTo
(
seconds
:
number
, allowSeekAhead
:
boolean
)
Parameters
seconds:
number
allowSeekAhead:
boolean
public
setLoop
(
loopPlaylists
:
boolean
)
Parameters
loopPlaylists:
boolean
public
setPlaybackRate
(
suggestedRate
:
number
)
Parameters
suggestedRate:
number
public
setShuffle
(
shufflePlaylist
:
boolean
)
Parameters
shufflePlaylist:
boolean
public
setSize
(
width
:
number
, height
:
number
)
:
any
Parameters
width:
number
height:
number
Returns
any
public
setVolume
(
volume
:
number
)
Parameters
volume:
number
public
stopVideo
(
)
public
unMute
(
)
Globals
YT
ListType
PlayerState
EventArgs
EventHandler
Events
PlayerOptions
PlayerVars
VideoByIdParams
VideoByUrlParams
Player
constructor
size
addEventListener
clearVideo
cueVideoById
cueVideoByUrl
getAvailablePlaybackRates
getCurrentTime
getDuration
getPlaybackRate
getPlayerState
getPlaylist
getPlaylistIndex
getVideoBytesLoaded
getVideoBytesTotal
getVideoEmbedCode
getVideoLoadedFraction
getVideoStartBytes
getVideoUrl
getVolume
isMuted
loadVideoById
loadVideoByUrl
mute
nextVideo
pauseVideo
playVideo
playVideoAt
previousVideo
seekTo
setLoop
setPlaybackRate
setShuffle
setSize
setVolume
stopVideo
unMute