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

This struct helper is used to create callbacks. More...

#include <C_callback.hpp>

Public Types

using CalleePtr = TCalleePtr
 

Static Public Member Functions

static CalleePtr newFunctor (typename fge::CallbackFunctor< Types... >::CallbackFunction func)
 Helper function to create a new callback functor.
 
template<typename TLambda >
static CalleePtr newLambda (TLambda const &lambda)
 Helper function to create a new callback lambda.
 
template<class TObject >
static CalleePtr newObjectFunctor (typename fge::CallbackObjectFunctor< TObject, Types... >::CallbackFunctionObject func, TObject *object)
 Helper function to create a new callback object functor.
 

Detailed Description

template<class TCalleePtr, class... Types>
struct fge::CallbackStaticHelpers< TCalleePtr, Types >

This struct helper is used to create callbacks.

Template Parameters
TCalleePtrThe callback pointer type, can be CalleeUniquePtr or CalleeSharedPtr
TypesThe list of arguments types passed to the functor

Member Function Documentation

◆ newFunctor()

template<class TCalleePtr , class... Types>
static CalleePtr fge::CallbackStaticHelpers< TCalleePtr, Types >::newFunctor ( typename fge::CallbackFunctor< Types... >::CallbackFunction func)
inlinestaticnodiscard

Helper function to create a new callback functor.

Parameters
funcThe callback function
Returns
The callback pointer

◆ newLambda()

template<class TCalleePtr , class... Types>
template<typename TLambda >
static CalleePtr fge::CallbackStaticHelpers< TCalleePtr, Types >::newLambda ( TLambda const & lambda)
inlinestaticnodiscard

Helper function to create a new callback lambda.

Template Parameters
TLambdaThe lambda type
Parameters
lambdaThe callback lambda
Returns
The callback pointer

◆ newObjectFunctor()

template<class TCalleePtr , class... Types>
template<class TObject >
static CalleePtr fge::CallbackStaticHelpers< TCalleePtr, Types >::newObjectFunctor ( typename fge::CallbackObjectFunctor< TObject, Types... >::CallbackFunctionObject func,
TObject * object )
inlinestaticnodiscard

Helper function to create a new callback object functor.

Template Parameters
TObjectThe object type
Parameters
funcThe callback method of the object
objectThe object pointer
Returns
The callback pointer

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