Urho3D
Public Member Functions | Private Attributes | List of all members
Urho3D::EventHandler11Impl Class Reference

Template implementation of the event handler invoke helper (std::function instance). More...

#include </home/runner/work/rurho3d.github.io/rurho3d.github.io/urho3d_repo/Source/Urho3D/Core/Object.h>

Inheritance diagram for Urho3D::EventHandler11Impl:
Urho3D::EventHandler Urho3D::LinkedListNode

Public Member Functions

 EventHandler11Impl (std::function< void(StringHash, VariantMap &)> function, void *userData=nullptr)
 Construct with receiver and function pointers and userdata.
 
void Invoke (VariantMap &eventData) override
 Invoke event handler function. More...
 
EventHandlerClone () const override
 Return a unique copy of the event handler. More...
 
- Public Member Functions inherited from Urho3D::EventHandler
 EventHandler (Object *receiver, void *userData=nullptr)
 Construct with specified receiver and userdata.
 
virtual ~EventHandler ()=default
 Destruct.
 
void SetSenderAndEventType (Object *sender, StringHash eventType)
 Set sender and event type.
 
virtual void Invoke (VariantMap &eventData)=0
 Invoke event handler function. More...
 
virtual EventHandlerClone () const =0
 Return a unique copy of the event handler. More...
 
ObjectGetReceiver () const
 Return event receiver.
 
ObjectGetSender () const
 Return event sender. Null if the handler is non-specific.
 
const StringHashGetEventType () const
 Return event type.
 
void * GetUserData () const
 Return userdata.
 
- Public Member Functions inherited from Urho3D::LinkedListNode
 LinkedListNode ()
 Construct.
 

Private Attributes

std::function< void(StringHash, VariantMap &)> function_
 Class-specific pointer to handler function.
 

Additional Inherited Members

- Public Attributes inherited from Urho3D::LinkedListNode
LinkedListNodenext_
 Pointer to next node.
 
- Protected Attributes inherited from Urho3D::EventHandler
Objectreceiver_
 Event receiver.
 
Objectsender_
 Event sender.
 
StringHash eventType_
 Event type.
 
void * userData_
 Userdata.
 

Detailed Description

Template implementation of the event handler invoke helper (std::function instance).

Member Function Documentation

◆ Clone()

EventHandler * Urho3D::EventHandler11Impl::Clone ( ) const
inlineoverridevirtual

Return a unique copy of the event handler.

Implements Urho3D::EventHandler.

◆ Invoke()

void Urho3D::EventHandler11Impl::Invoke ( VariantMap eventData)
inlineoverridevirtual

Invoke event handler function.

Implements Urho3D::EventHandler.


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