Plasma Engine  2.0
Loading...
Searching...
No Matches
plEvent< EventData, MutexType, AllocatorWrapper, EventType > Class Template Reference

#include <Event.h>

Inheritance diagram for plEvent< EventData, MutexType, AllocatorWrapper, EventType >:

Public Member Functions

 plEvent (plAllocator *pAllocator)
 
- Public Member Functions inherited from plEventBase< EventData, plNoMutex, plEventType::Default >
void Broadcast (EventData pEventData, plUInt8 uiMaxRecursionDepth=MaxRecursionDepthDefault)
 This function will broadcast to all registered users, that this event has just happened. Setting uiMaxRecursionDepth will allow you to permit recursions. When broadcasting consider up to what depth you want recursions to be permitted. By default no recursion is allowed.
 
plEventSubscriptionID AddEventHandler (Handler handler) const
 Adds a function as an event handler. All handlers will be notified in the order that they were registered.
 
void AddEventHandler (Handler handler, Unsubscriber &inout_unsubscriber) const
 An overload that adds an event handler and initializes the given Unsubscriber object.
 
void RemoveEventHandler (const Handler &handler) const
 Removes a previously registered handler. It is an error to remove a handler that was not registered.
 
void RemoveEventHandler (plEventSubscriptionID &inout_id) const
 Removes a previously registered handler via the returned subscription ID.
 
bool HasEventHandler (const Handler &handler) const
 Checks whether an event handler has already been registered.
 
void Clear ()
 Removes all registered event handlers.
 
bool IsEmpty () const
 Returns true, if no event handlers are registered.
 
 PL_DISALLOW_COPY_AND_ASSIGN (plEventBase)
 

Additional Inherited Members

- Public Types inherited from plEventBase< EventData, plNoMutex, plEventType::Default >
enum  
 Implementation specific constants.
 
using Handler
 Notification callback type for events.
 
- Protected Member Functions inherited from plEventBase< EventData, plNoMutex, plEventType::Default >
 plEventBase (plAllocator *pAllocator)
 Constructor.
 

Detailed Description

template<typename EventData, typename MutexType = plNoMutex, typename AllocatorWrapper = plDefaultAllocatorWrapper, plEventType EventType = plEventType::Default>
class plEvent< EventData, MutexType, AllocatorWrapper, EventType >
See also
plEventBase

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