Protocol

TVPlaybackEventMarshaling

A protocol used for sending and receiving information across the JavaScript bridge.

Declaration

@protocol TVPlaybackEventMarshaling

Overview

You must conform to this protocol in order to pass custom events.

Topics

Processing Playback Events

- processReturnJSValue:inContext:

Converts a JavaScript value into a value that is readable in Swift or Objective-C.

properties

An array of custom playback event properties.

Required.

TVPlaybackEventProperty

Extend this structure to create your own custom playback event properties.

Relationships

Inherits From

See Also

Controlling Playback

- next

Plays the next media item in the playlist.

- pause

Pauses the currently playing item.

- previous

Plays the previous media item in the playlist.

state

The current state of the player.

TVPlaybackState

The possible states of a player.

- dispatchEvent:userInfo:completion:

Dispatches custom playback events to the JavaScript environment.

TVPlaybackEvent

Extend this structure to send your custom playback events to the JavaScript environment.

TVPlaybackCustomEventUserInfo

The user information used in a custom playback event.