Back to index

salome-gui  6.5.0
Public Types | Public Member Functions | Public Attributes | Private Attributes
TMemFunEvent< TObject, TRes > Class Template Reference

Template class for event which calls the function without arguments and returning result. More...

#include <SALOME_Event.h>

Inheritance diagram for TMemFunEvent< TObject, TRes >:
Inheritance graph
[legend]
Collaboration diagram for TMemFunEvent< TObject, TRes >:
Collaboration graph
[legend]

List of all members.

Public Types

typedef TRes TResult
typedef TResult(TObject::* TAction )()

Public Member Functions

 TMemFunEvent (TObject *theObject, TAction theAction, TResult theResult=TResult())
virtual void Execute ()

Public Attributes

TResult myResult

Private Attributes

TObject * myObject
TAction myAction

Detailed Description

template<class TObject, typename TRes>
class TMemFunEvent< TObject, TRes >

Template class for event which calls the function without arguments and returning result.

Definition at line 69 of file SALOME_Event.h.


Member Typedef Documentation

template<class TObject , typename TRes >
typedef TResult(TObject::* TMemFunEvent< TObject, TRes >::TAction)()

Definition at line 74 of file SALOME_Event.h.

template<class TObject , typename TRes >
typedef TRes TMemFunEvent< TObject, TRes >::TResult

Definition at line 72 of file SALOME_Event.h.


Constructor & Destructor Documentation

template<class TObject , typename TRes >
TMemFunEvent< TObject, TRes >::TMemFunEvent ( TObject *  theObject,
TAction  theAction,
TResult  theResult = TResult() 
) [inline]

Definition at line 75 of file SALOME_Event.h.

                                             :
    myObject(theObject),
    myAction(theAction),
    myResult(theResult)
  {}

Member Function Documentation

template<class TObject , typename TRes >
virtual void TMemFunEvent< TObject, TRes >::Execute ( ) [inline, virtual]

Definition at line 81 of file SALOME_Event.h.

  {
    myResult = (myObject->*myAction)();
  }

Member Data Documentation

template<class TObject , typename TRes >
TAction TMemFunEvent< TObject, TRes >::myAction [private]

Definition at line 87 of file SALOME_Event.h.

template<class TObject , typename TRes >
TObject* TMemFunEvent< TObject, TRes >::myObject [private]

Definition at line 86 of file SALOME_Event.h.

template<class TObject , typename TRes >
TResult TMemFunEvent< TObject, TRes >::myResult

Definition at line 73 of file SALOME_Event.h.


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