Turbo Engine 0.3
A C++ game engine using Allegro 5
turbo::EventHandler< Args > Class Template Reference

#include <EventHandler.hpp>

Public Types

typedef std::function< void(Args...)> handler_func_type
typedef unsigned int handler_id_type

Public Member Functions

 EventHandler (const handler_func_type &handlerFunc)
 EventHandler (const EventHandler &src)
 EventHandler (EventHandler &&src)
EventHandleroperator= (const EventHandler &src)
EventHandleroperator= (EventHandler &&src)
void operator() (Args... params) const
bool operator== (const EventHandler &other) const
 operator bool () const
handler_id_type id () const

Detailed Description

template<typename... Args>
class turbo::EventHandler< Args >
Examples
events.cpp.

Member Typedef Documentation

◆ handler_func_type

template<typename... Args>
typedef std::function<void(Args...)> turbo::EventHandler< Args >::handler_func_type

◆ handler_id_type

template<typename... Args>
typedef unsigned int turbo::EventHandler< Args >::handler_id_type

Constructor & Destructor Documentation

◆ EventHandler() [1/3]

template<typename... Args>
turbo::EventHandler< Args >::EventHandler ( const handler_func_type & handlerFunc)
inlineexplicit

◆ EventHandler() [2/3]

template<typename... Args>
turbo::EventHandler< Args >::EventHandler ( const EventHandler< Args > & src)
inline

◆ EventHandler() [3/3]

template<typename... Args>
turbo::EventHandler< Args >::EventHandler ( EventHandler< Args > && src)
inline

Member Function Documentation

◆ id()

template<typename... Args>
handler_id_type turbo::EventHandler< Args >::id ( ) const
inline

◆ operator bool()

template<typename... Args>
turbo::EventHandler< Args >::operator bool ( ) const
inline

◆ operator()()

template<typename... Args>
void turbo::EventHandler< Args >::operator() ( Args... params) const
inline

◆ operator=() [1/2]

template<typename... Args>
EventHandler & turbo::EventHandler< Args >::operator= ( const EventHandler< Args > & src)
inline

◆ operator=() [2/2]

template<typename... Args>
EventHandler & turbo::EventHandler< Args >::operator= ( EventHandler< Args > && src)
inline

◆ operator==()

template<typename... Args>
bool turbo::EventHandler< Args >::operator== ( const EventHandler< Args > & other) const
inline

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