|
RDK Documentation (Open Sourced RDK Components)
|
Go to the documentation of this file.
25 #ifndef AAMP_EVENT_MANAGER_H
26 #define AAMP_EVENT_MANAGER_H
33 #include "AampUtils.h"
70 typedef std::map<guint, bool>::iterator AsyncEventListIter;
100 guint callbackId = g_source_get_id(g_main_current_source());
104 return G_SOURCE_REMOVE ;
AampEventManager(AampLogManager *logObj)
Default Constructor.
std::map< guint, bool > AsyncEventList
Class for sed event to Listener.
void SetPlayerState(PrivAAMPState state)
SetPlayerState - Flag to update player state.
ListenerData * mEventListeners[AAMP_MAX_NUM_EVENTS]
std::queue< AAMPEventPtr > EventWorkerDataQ
void SetFakeTuneFlag(bool isFakeTuneSetting)
SetFakeTuneFlag - Some events are restricted for FakeTune.
void AsyncEvent()
AsyncEvent - Task function for IdleEvent.
EventListener * eventListener
void AddEventListener(AAMPEventType eventType, EventListener *eventListener)
AddEventListener - Register listener for one eventtype.
@ AAMP_EVENT_DEFAULT_MODE
Structure of the event listener list.
~AampEventManager()
Destructor Function.
Classes for AAMP Event listener.
AAMPEventMode
AAMP event modes.
Class to Handle Aamp Events.
PrivAAMPState mPlayerState
bool IsSpecificEventListenerAvailable(AAMPEventType eventType)
IsSpecificEventListenerAvailable - Check if this particular listener present for this event.
void SendEventAsync(const AAMPEventPtr &eventData)
SendEventAsync - Function to send events Async.
bool IsEventListenerAvailable(AAMPEventType eventType)
IsEventListenerAvailable - Check if any listners present for this event.
PrivAAMPState
Mapping all required status codes based on JS player requirement. These requirements may be forced by...
void AddListenerForAllEvents(EventListener *eventListener)
AddListenerForAllEvents - Register one listener for all events.
void SetCallbackAsPending(guint id)
SetCallbackAsPending - Set callbackId as Pending/to be done.
pthread_mutex_t mMutexVar
void RemoveListenerForAllEvents(EventListener *eventListener)
RemoveListenerForAllEvents - Remove listener for all events.
void SendEventSync(const AAMPEventPtr &eventData)
SendEventSync - Function to send events sync.
guint GetSourceID()
GetSourceID - Get the idle task's source ID.
Events supported by the AAMP player.
void SendEvent(const AAMPEventPtr &eventData, AAMPEventMode eventMode=AAMP_EVENT_DEFAULT_MODE)
SendEvent - Generic function to send events.
void FlushPendingEvents()
FlushPendingEvents - Clear all pending events from EventManager.
AAMPEventType
Type of the events sending to the JSPP player.
static gboolean EventManagerThreadFunction(gpointer This)
Thread entry function for Async Event Processing.
void SetAsyncTuneState(bool isAsyncTuneSetting)
SetAsyncTuneState - Flag for Async Tune.
void RemoveEventListener(AAMPEventType eventType, EventListener *eventListener)
RemoveEventListener - Remove one listener registration for one event.
AampEventManager & operator=(const AampEventManager &)=delete
assignment operator disabled
int mEventStats[AAMP_MAX_NUM_EVENTS]
void SetCallbackAsDispatched(guint id)
SetCallbackAsDispatched - Set callbackId as dispatched/done.