Native Player  1.0
MediaBufferingListener Class Reference

Listener class designed to handle buffering related events. MediaBufferingListener receives event's information and passes it through the communication channel using MessageSender. More...

#include <player_listeners.h>

Inheritance diagram for MediaBufferingListener:

Public Member Functions

 MediaBufferingListener (std::weak_ptr< Communication::MessageSender > message_sender, std::weak_ptr< PlayerController > player_controller={})
 
void OnBufferingStart () override
 
void OnBufferingProgress (uint32_t percent) override
 
void OnBufferingComplete () override
 

Detailed Description

Listener class designed to handle buffering related events. MediaBufferingListener receives event's information and passes it through the communication channel using MessageSender.

Definition at line 121 of file player_listeners.h.

Constructor & Destructor Documentation

MediaBufferingListener::MediaBufferingListener ( std::weak_ptr< Communication::MessageSender message_sender,
std::weak_ptr< PlayerController player_controller = {} 
)
inlineexplicit

Creates a MediaBufferingListener object.

Parameters
[in]message_senderAn object which will be used to send messages based on received subtitle events through the communication channel
[in]player_controllerA handler to a controller, which will be requested to send all text track information through the communication channel when buffering finished.

Definition at line 130 of file player_listeners.h.

Member Function Documentation

void MediaBufferingListener::OnBufferingComplete ( )
override

An event handler method, called when a buffering has been completed by the player. MediaBufferingListener passes this information through the communication channel using MessageSender.

Note
If PlayerController object was registered to this object, then in this method will use it to send information about all text track information.
Elementary stream player type should send elementary stream packets until this event occurs.
Generating this event means that playback can be started.
void MediaBufferingListener::OnBufferingProgress ( uint32_t  percent)
override

An event handler method, called periodically with information about buffering progress. MediaBufferingListener passes it through the communication channel using MessageSender.

Parameters
[in]percentIndicates how much of the initial data has been buffered by the player.
Note
This event is generated only in URL data source playback scenario.
void MediaBufferingListener::OnBufferingStart ( )
override

An event handler method, called when buffering has been started by the player. MediaBufferingListener passes this information through the communication channel using MessageSender.


The documentation for this class was generated from the following file: