FastEngine 0.9.3
A multiplayer oriented 2D engine made with Vulkan.
Loading...
Searching...
No Matches
fge::CallbackObjectFunctor< TObject, Types > Class Template Reference

Callback functor of a method with an object. More...

#include <C_callback.hpp>

Inheritance diagram for fge::CallbackObjectFunctor< TObject, Types >:
fge::CallbackBase< Types... >

Public Types

using CallbackFunctionObject = void (TObject::*)(Types... args)
 

Public Member Functions

 CallbackObjectFunctor (fge::CallbackObjectFunctor< TObject, Types... >::CallbackFunctionObject func, TObject *object)
 Constructor.
 
void call (Types... args) override
 Call the callback method with the given arguments.
 
bool check (void *ptr) override
 Check if the given object pointer is the same as the one used to construct the functor.
 

Protected Attributes

fge::CallbackObjectFunctor< TObject, Types... >::CallbackFunctionObject g_functionObj
 
TObject * g_object
 

Detailed Description

template<class TObject, class... Types>
class fge::CallbackObjectFunctor< TObject, Types >

Callback functor of a method with an object.

Template Parameters
TypesThe list of arguments types passed to the functor
TObjectThe object type

Constructor & Destructor Documentation

◆ CallbackObjectFunctor()

template<class TObject , class... Types>
fge::CallbackObjectFunctor< TObject, Types >::CallbackObjectFunctor ( fge::CallbackObjectFunctor< TObject, Types... >::CallbackFunctionObject func,
TObject * object )

Constructor.

Parameters
funcThe callback method of the object
objectThe object pointer

Member Function Documentation

◆ call()

template<class TObject , class... Types>
void fge::CallbackObjectFunctor< TObject, Types >::call ( Types... args)
overridevirtual

Call the callback method with the given arguments.

Parameters
argsThe list of arguments

Implements fge::CallbackBase< Types... >.

◆ check()

template<class TObject , class... Types>
bool fge::CallbackObjectFunctor< TObject, Types >::check ( void * ptr)
inlineoverridevirtual

Check if the given object pointer is the same as the one used to construct the functor.

Parameters
ptrThe object pointer to check
Returns
True if the given object pointer is the same as the one used to construct the functor

Implements fge::CallbackBase< Types... >.


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