AVPlayerCollectorApi
@objc(BMAAVPlayerCollectorApi)
public protocol AVPlayerCollectorApi : Collector
-
Attach a player instance to this analytics collector.
With calling this method the collector starts to listen to player events.
Warning: Needs to be called before loading the source or playlist
Declaration
Swift
func attach(to player: AVPlayer)
Parameters
player
The
AVPlayer
instance which will be monitored -
The
CustomData
which is applied to each sample send to the backendThis property is an accessor of the
SourceMetadata.customData
Setting a value to this property will immediatelly change the values by
- sending out the current sample with old
CustomData
and - overriding it with new one for upcoming samples
Declaration
Swift
var customData: CustomData { get set }
- sending out the current sample with old
-
The
SourceMetadata
which is send to the backend with each sampleNotes:
- Existing
sourceMetadata
will be overriden. - Provided
CustomData
through theSourceMetadata
will overwrite theCustomData
object set viacollector.customData
value by value
Declaration
Swift
var sourceMetadata: SourceMetadata { get set }
- Existing
-
Declaration
Swift
func attachPlayer(player: AVPlayer)
-
Declaration
Swift
func getCustomData() -> CustomData
-
Declaration
Swift
func setCustomData(customData: CustomData)