CernVM-FS  2.12.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Callback< ParamT > Class Template Reference

#include <async.h>

Inheritance diagram for Callback< ParamT >:
Collaboration diagram for Callback< ParamT >:

Public Types

typedef void(* CallbackFunction )(const ParamT &value)

Public Member Functions

 Callback (CallbackFunction function)
void operator() (const ParamT &value) const
- Public Member Functions inherited from CallbackBase< ParamT >
virtual ~CallbackBase ()

Private Attributes

CallbackFunction function_

Detailed Description

template<typename ParamT>
class Callback< ParamT >

This callback function object can be used to call static members or global functions with the following signature: void <name>(ParamT <parameter>);

TODO: One might use varidic templates once C++11 will be supported, in order to allow for more than one parameter to be passed to the callback.

ParamTthe type of the parameter to be passed to the callback

Definition at line 45 of file async.h.

Member Typedef Documentation

template<typename ParamT>
typedef void(* Callback< ParamT >::CallbackFunction)(const ParamT &value)

Definition at line 47 of file async.h.

Constructor & Destructor Documentation

template<typename ParamT>
Callback< ParamT >::Callback ( CallbackFunction  function)

Definition at line 49 of file async.h.

Member Function Documentation

template<typename ParamT>
void Callback< ParamT >::operator() ( const ParamT &  value) const

Implements CallbackBase< ParamT >.

Definition at line 50 of file async.h.

Member Data Documentation

template<typename ParamT>
CallbackFunction Callback< ParamT >::function_

Definition at line 53 of file async.h.

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