MOOSE - Multiscale Object Oriented Simulation Environment
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
GetOpFunc< T, A > Class Template Reference

#include <OpFunc.h>

+ Inheritance diagram for GetOpFunc< T, A >:
+ Collaboration diagram for GetOpFunc< T, A >:

Public Member Functions

 GetOpFunc (A(T::*func)() const )
 
void op (const Eref &e, vector< A > *ret) const
 
returnOp (const Eref &e) const
 
- Public Member Functions inherited from GetOpFuncBase< A >
const OpFuncmakeHopFunc (HopIndex hopIndex) const
 
void opBuffer (const Eref &e, double *buf) const
 Executes the OpFunc by converting args. More...
 
- Public Member Functions inherited from OpFunc1Base< vector< A > * >
bool checkFinfo (const Finfo *s) const
 
const OpFuncmakeHopFunc (HopIndex hopIndex) const
 
void opBuffer (const Eref &e, double *buf) const
 Executes the OpFunc by converting args. More...
 
virtual void opVec (const Eref &e, const vector< vector< A > * > &arg, const OpFunc1Base< vector< A > * > *op) const
 
void opVecBuffer (const Eref &e, double *buf) const
 Executes the OpFunc for all data by converting a vector of args. More...
 
string rttiType () const
 
- Public Member Functions inherited from OpFunc
 OpFunc ()
 
unsigned int opIndex () const
 
bool setIndex (unsigned int i)
 Used when rebuilding the Fid->OpFunc mapping. More...
 
virtual ~OpFunc ()
 

Private Attributes

A(T::* func_ )() const
 

Additional Inherited Members

- Static Public Member Functions inherited from OpFunc
static const OpFunclookop (unsigned int opIndex)
 
static unsigned int rebuildOpIndex ()
 cleans out the entire Ops vector. Returns size of orig vector. More...
 

Detailed Description

template<class T, class A>
class GetOpFunc< T, A >

This specialized OpFunc is for returning a single field value It generates an opFunc that takes a single argument, a reference to a vector into which the return value should be appended. It manages the 'get' function that retrieves the return value. Note that the 'get' function must be blocking in case the request goes off node.

Definition at line 134 of file OpFunc.h.

Constructor & Destructor Documentation

template<class T, class A>
GetOpFunc< T, A >::GetOpFunc ( A(T::*)() const  func)
inline

Definition at line 137 of file OpFunc.h.

138  : func_( func )
139  {;}
A(T::* func_)() const
Definition: OpFunc.h:150

Member Function Documentation

template<class T, class A>
void GetOpFunc< T, A >::op ( const Eref e,
vector< A > *  ret 
) const
inlinevirtual

Implements OpFunc1Base< vector< A > * >.

Definition at line 141 of file OpFunc.h.

References GetOpFunc< T, A >::returnOp().

141  {
142  ret->push_back( returnOp( e ) );
143  }
A returnOp(const Eref &e) const
Definition: OpFunc.h:145

+ Here is the call graph for this function:

template<class T, class A>
A GetOpFunc< T, A >::returnOp ( const Eref e) const
inlinevirtual

Implements GetOpFuncBase< A >.

Definition at line 145 of file OpFunc.h.

References Eref::data(), and GetOpFunc< T, A >::func_.

Referenced by GetOpFunc< T, A >::op().

145  {
146  return ( reinterpret_cast< T* >( e.data() )->*func_)();
147  }
char * data() const
Definition: Eref.cpp:41
A(T::* func_)() const
Definition: OpFunc.h:150

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Member Data Documentation

template<class T, class A>
A( T::* GetOpFunc< T, A >::func_)() const
private

Definition at line 150 of file OpFunc.h.

Referenced by GetOpFunc< T, A >::returnOp().


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