com.bitmovin.player.api.event
Contains all Bitmovin events and API to enable subscribing to those events.
Types
| Name | Summary |
|---|---|
| Event | sealed class Event Includes all possible events the Player, Source or OfflineContentManager can emit. |
| EventEmitter | interface EventEmitter<T : Event> : JavaEventEmitter<T> Manages subscriptions to specific Events and notifies those subscribers when such an event is being emitted. Subscribers can be simple function types in Kotlin or EventListener implementations in Java. There are also reified versions of the EventEmitter API to allow for convenient usage from Kotlin. |
| EventListener | interface EventListener<E : Event?> Used to represent event listeners when Kotlin lambdas can not be used to conveniently subscribe to events (e.g. |
| InfoEvent | interface InfoEvent The common supertype implemented by all different info events that are emitted by the Player or Source. |
| JavaEventEmitter | interface JavaEventEmitter<T : Event> Provides EventEmitter functionality that is more convenient for Java usage. |
| OfflineEvent | sealed class OfflineEvent : Event |
| PlayerEvent | sealed class PlayerEvent : Event Includes all possible events that only the Player can emit. |
| SourceEvent | sealed class SourceEvent : Event Includes all possible events that the Source or Player can emit. |
Functions
| Name | Summary |
|---|---|
| next | inline fun <E : Event> EventEmitter<Event>.next(noinline action: (E) -> Unit) @JvmName(name = "nextOfflineEvent") inline fun <E : OfflineEvent> EventEmitter<OfflineEvent>.next(noinline action: (E) -> Unit) @JvmName(name = "nextPlayerEvent") inline fun <E : PlayerEvent> EventEmitter<PlayerEvent>.next(noinline action: (E) -> Unit) @JvmName(name = "nextSourceEvent") inline fun <E : SourceEvent> EventEmitter<SourceEvent>.next(noinline action: (E) -> Unit) |
| on | inline fun <E : Event> EventEmitter<Event>.on(noinline action: (E) -> Unit) @JvmName(name = "onOfflineEvent") inline fun <E : OfflineEvent> EventEmitter<OfflineEvent>.on(noinline action: (E) -> Unit) @JvmName(name = "onPlayerEvent") inline fun <E : PlayerEvent> EventEmitter<PlayerEvent>.on(noinline action: (E) -> Unit) @JvmName(name = "onSourceEvent") inline fun <E : SourceEvent> EventEmitter<SourceEvent>.on(noinline action: (E) -> Unit) |