Tizen Native API  6.0

Callback base class to hold the data for callback function and member function calls. More...

Inheritance diagram for Dali::CallbackBase:
Dali::Callback< T > Dali::CallbackFunction Dali::CallbackFunctor0< T > Dali::CallbackFunctor1< T, P1 > Dali::CallbackFunctor2< T, P1, P2 > Dali::CallbackFunctor3< T, P1, P2, P3 > Dali::CallbackFunctorDelegate0 Dali::CallbackFunctorDelegate1< P1 > Dali::CallbackFunctorDelegate2< P1, P2 > Dali::CallbackFunctorDelegate3< P1, P2, P3 > Dali::CallbackFunctorDelegateReturn0< R > Dali::CallbackFunctorDelegateReturn1< P1, R > Dali::CallbackFunctorDelegateReturn2< P1, P2, R > Dali::CallbackFunctorDelegateReturn3< P1, P2, P3, R > Dali::CallbackFunctorReturn0< T, R > Dali::CallbackFunctorReturn1< T, P1, R > Dali::CallbackFunctorReturn2< T, P1, P2, R > Dali::CallbackFunctorReturn3< T, P1, P2, P3, R > Dali::Constraint::Function< P >

Classes

struct  Impl
 Struct to hold the extra data needed for member functions. More...

Public Member Functions

 CallbackBase ()
 Default constructor.
 ~CallbackBase ()
 Destructor.
void Reset ()
 Resets the object pointer so that we know not to call methods of this object any more.

Static Public Member Functions

static void Execute (CallbackBase &callback)
 Function to call the function or member function dispatcher.
template<typename R >
static R ExecuteReturn (CallbackBase &callback)
 Function to call the function or member function dispatcher.
template<typename P1 >
static void Execute (CallbackBase &callback, P1 param1)
 Function to call the function or member function dispatcher.
template<typename R , typename P1 >
static R ExecuteReturn (CallbackBase &callback, P1 param1)
 Function to call the function or member function dispatcher.
template<typename P1 , typename P2 >
static void Execute (CallbackBase &callback, P1 param1, P2 param2)
 Function to call the function or member function dispatcher.
template<typename R , typename P1 , typename P2 >
static R ExecuteReturn (CallbackBase &callback, P1 param1, P2 param2)
 Function to call the function or member function dispatcher.
template<typename P1 , typename P2 , typename P3 >
static void Execute (CallbackBase &callback, P1 param1, P2 param2, P3 param3)
 Function to call the function or member function dispatcher.
template<typename R , typename P1 , typename P2 , typename P3 >
static R ExecuteReturn (CallbackBase &callback, P1 param1, P2 param2, P3 param3)
 Function to call the function or member function dispatcher.

Public Attributes

ImplmImpl
 Implementation pointer.
MemberFunction mMemberFunction
 Pointer to member function.
Function mFunction
 Static function.

Protected Types

typedef void(* Function )(void)
 Function with static linkage.
typedef void(CallbackBase::* MemberFunction )(void)
 Member function.
typedef void(* Dispatcher )(CallbackBase &base)
 Used to call the correct member function.
typedef void(* Destructor )(void *object)
 Used to destroy mObjectPointer (NULL if not mObjectPointer is not owned).

Protected Member Functions

 CallbackBase (const CallbackBase &rhs)
 Copy constructor operator not declared.
CallbackBaseoperator= (const CallbackBase &rhs)
 Assignment operator not declared.
 CallbackBase (Function function)
 Constructor for function with static linkage.
 CallbackBase (void *object, MemberFunction function, Dispatcher dispatcher)
 Constructor for member function.
 CallbackBase (void *object, MemberFunction function, Dispatcher dispatcher, Destructor destructor)
 Constructor for member function.

Detailed Description

Callback base class to hold the data for callback function and member function calls.

Since:
3.0, DALi version 1.0.0

Member Typedef Documentation

typedef void(* Dali::CallbackBase::Destructor)(void *object) [protected]

Used to destroy mObjectPointer (NULL if not mObjectPointer is not owned).

Since:
3.0, DALi version 1.0.0
typedef void(* Dali::CallbackBase::Dispatcher)(CallbackBase &base) [protected]

Used to call the correct member function.

Since:
3.0, DALi version 1.0.0
typedef void(* Dali::CallbackBase::Function)(void) [protected]

Function with static linkage.

Since:
3.0, DALi version 1.0.0
typedef void(CallbackBase::* Dali::CallbackBase::MemberFunction)(void) [protected]

Member function.

Since:
3.0, DALi version 1.0.0

Constructor & Destructor Documentation

Default constructor.

Since:
3.0, DALi version 1.0.0

Destructor.

Since:
3.0, DALi version 1.0.0
Dali::CallbackBase::CallbackBase ( const CallbackBase rhs) [protected]

Copy constructor operator not declared.

Since:
3.0, DALi version 1.0.0
Parameters:
[in]rhsHandle to an object
Dali::CallbackBase::CallbackBase ( Function  function) [protected]

Constructor for function with static linkage.

Since:
3.0, DALi version 1.0.0
Parameters:
[in]functionThe function to call
Dali::CallbackBase::CallbackBase ( void *  object,
MemberFunction  function,
Dispatcher  dispatcher 
) [protected]

Constructor for member function.

Since:
3.0, DALi version 1.0.0
Parameters:
[in]objectThe object to call (not owned)
[in]functionThe member function of the object
[in]dispatcherUsed to call the actual object
Dali::CallbackBase::CallbackBase ( void *  object,
MemberFunction  function,
Dispatcher  dispatcher,
Destructor  destructor 
) [protected]

Constructor for member function.

Since:
3.0, DALi version 1.0.0
Parameters:
[in]objectThe object to call (owned)
[in]functionThe member function of the object
dispatcherUsed to call the actual object
destructorUsed to delete the owned object

Member Function Documentation

static void Dali::CallbackBase::Execute ( CallbackBase callback) [static]

Function to call the function or member function dispatcher.

Since:
3.0, DALi version 1.0.0
Parameters:
[in]callbackThe callback to call
template<typename P1 >
static void Dali::CallbackBase::Execute ( CallbackBase callback,
P1  param1 
) [static]

Function to call the function or member function dispatcher.

This function template gets instantiated at the call site.

Since:
3.0, DALi version 1.0.0
Parameters:
[in]callbackThe callback to call
[in]param1The first parameter to pass into the function
template<typename P1 , typename P2 >
static void Dali::CallbackBase::Execute ( CallbackBase callback,
P1  param1,
P2  param2 
) [static]

Function to call the function or member function dispatcher.

This function template gets instantiated at the call site.

Since:
3.0, DALi version 1.0.0
Parameters:
[in]callbackThe callback to call
[in]param1The first parameter to pass into the function
[in]param2The second parameter to pass into the function
template<typename P1 , typename P2 , typename P3 >
static void Dali::CallbackBase::Execute ( CallbackBase callback,
P1  param1,
P2  param2,
P3  param3 
) [static]

Function to call the function or member function dispatcher.

This function template gets instantiated at the call site.

Since:
3.0, DALi version 1.0.0
Parameters:
[in]callbackThe callback to call
[in]param1The first parameter to pass into the function
[in]param2The second parameter to pass into the function
[in]param3The third parameter to pass into the function
template<typename R >
static R Dali::CallbackBase::ExecuteReturn ( CallbackBase callback) [static]

Function to call the function or member function dispatcher.

Since:
3.0, DALi version 1.0.0
Parameters:
[in]callbackThe callback to call
Returns:
The value from the function
template<typename R , typename P1 >
static R Dali::CallbackBase::ExecuteReturn ( CallbackBase callback,
P1  param1 
) [static]

Function to call the function or member function dispatcher.

This function template gets instantiated at the call site.

Since:
3.0, DALi version 1.0.0
Parameters:
[in]callbackThe callback to call
[in]param1The first parameter to pass into the function
Returns:
The value from the function
template<typename R , typename P1 , typename P2 >
static R Dali::CallbackBase::ExecuteReturn ( CallbackBase callback,
P1  param1,
P2  param2 
) [static]

Function to call the function or member function dispatcher.

This function template gets instantiated at the call site.

Since:
3.0, DALi version 1.0.0
Parameters:
[in]callbackThe callback to call
[in]param1The first parameter to pass into the function
[in]param2The second parameter to pass into the function
Returns:
The return value from the function
template<typename R , typename P1 , typename P2 , typename P3 >
static R Dali::CallbackBase::ExecuteReturn ( CallbackBase callback,
P1  param1,
P2  param2,
P3  param3 
) [static]

Function to call the function or member function dispatcher.

This function template gets instantiated at the call site.

Since:
3.0, DALi version 1.0.0
Parameters:
[in]callbackThe callback to call
[in]param1The first parameter to pass into the function
[in]param2The second parameter to pass into the function
[in]param3The third parameter to pass into the function
Returns:
The return value from the function
CallbackBase& Dali::CallbackBase::operator= ( const CallbackBase rhs) [protected]

Assignment operator not declared.

Since:
3.0, DALi version 1.0.0
Parameters:
[in]rhsHandle to an object
Returns:
A reference to this

Resets the object pointer so that we know not to call methods of this object any more.

Since:
3.0, DALi version 1.0.0