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

#include <ElementValueFinfo.h>

+ Inheritance diagram for ReadOnlyElementValueFinfo< T, F >:
+ Collaboration diagram for ReadOnlyElementValueFinfo< T, F >:

Public Member Functions

 ReadOnlyElementValueFinfo (const string &name, const string &doc, F(T::*getFunc)(const Eref &e) const )
 
void registerFinfo (Cinfo *c)
 
string rttiType () const
 
bool strGet (const Eref &tgt, const string &field, string &returnValue) const
 
bool strSet (const Eref &tgt, const string &field, const string &arg) const
 
 ~ReadOnlyElementValueFinfo ()
 
- Public Member Functions inherited from ValueFinfoBase
DestFinfogetFinfo () const
 
vector< string > innerDest () const
 
 ValueFinfoBase (const string &name, const string &doc)
 
 ~ValueFinfoBase ()
 
- Public Member Functions inherited from Finfo
virtual bool addMsg (const Finfo *target, ObjId mid, Element *src) const
 
virtual bool checkTarget (const Finfo *target) const
 
const string & docs () const
 Returns documentation string. More...
 
 Finfo (const string &name, const string &doc)
 
virtual vector< string > innerSrc () const
 
const string & name () const
 
virtual void postCreationFunc (Id newId, Element *newElm) const
 
virtual ~Finfo ()
 

Additional Inherited Members

- Static Public Member Functions inherited from Finfo
static const CinfoinitCinfo ()
 
- Protected Attributes inherited from ValueFinfoBase
DestFinfoget_
 
DestFinfoset_
 

Detailed Description

template<class T, class F>
class ReadOnlyElementValueFinfo< T, F >

Definition at line 72 of file ElementValueFinfo.h.

Constructor & Destructor Documentation

template<class T, class F>
ReadOnlyElementValueFinfo< T, F >::~ReadOnlyElementValueFinfo ( )
inline

Definition at line 75 of file ElementValueFinfo.h.

References ValueFinfoBase::get_.

75  {
76  delete get_;
77  }
DestFinfo * get_
Definition: ValueFinfo.h:33
template<class T, class F>
ReadOnlyElementValueFinfo< T, F >::ReadOnlyElementValueFinfo ( const string &  name,
const string &  doc,
F(T::*)(const Eref &e) const  getFunc 
)
inline

Definition at line 79 of file ElementValueFinfo.h.

References ValueFinfoBase::get_, and Finfo::name().

81  : ValueFinfoBase( name, doc )
82  {
83  string getname = "get" + name;
84  getname[3] = std::toupper( getname[3] );
85  get_ = new DestFinfo(
86  getname,
87  "Requests field value. The requesting Element must "
88  "provide a handler for the returned value.",
89  new GetEpFunc< T, F >( getFunc ) );
90  }
DestFinfo * get_
Definition: ValueFinfo.h:33
ValueFinfoBase(const string &name, const string &doc)
Definition: ValueFinfo.cpp:12
const string & name() const
Definition: Finfo.cpp:80

+ Here is the call graph for this function:

Member Function Documentation

template<class T, class F>
void ReadOnlyElementValueFinfo< T, F >::registerFinfo ( Cinfo c)
inlinevirtual

Returns string-ified form to handle template expectations for name field string getName() const; Assign function Ids, bindIndex and so on.

Implements Finfo.

Definition at line 93 of file ElementValueFinfo.h.

References ValueFinfoBase::get_, and Cinfo::registerFinfo().

93  {
94  c->registerFinfo( get_ );
95  }
DestFinfo * get_
Definition: ValueFinfo.h:33
void registerFinfo(Finfo *f)
Definition: Cinfo.cpp:114

+ Here is the call graph for this function:

template<class T, class F>
string ReadOnlyElementValueFinfo< T, F >::rttiType ( ) const
inlinevirtual

Returns the documentation string for the Finfo string docs() const; Returns the RTTI type string for the finfo by referring to an internal virtual function. string type() const; Returns the list of subsidiary SrcFinfos. Used in Shared Finfos, empty otherwise. Goes via internal virtual function. vector< string > src() const; Returns the list of subsidiary destFinfos. Used in SharedFinfos and ValueFinfos, empty otherwise. Goes via internal virtual function. vector< string > dest() const; Returns an RTTI type string for this Finfo.

Reimplemented from Finfo.

Definition at line 108 of file ElementValueFinfo.h.

References Conv< T >::rttiType().

108  {
109  return Conv<F>::rttiType();
110  }
static string rttiType()
Definition: Conv.h:82

+ Here is the call graph for this function:

template<class T, class F>
bool ReadOnlyElementValueFinfo< T, F >::strGet ( const Eref tgt,
const string &  field,
string &  returnValue 
) const
inlinevirtual

Function to return value of field into a string argument. Returns true on success. Normally called only from SetGet::strGet.

Implements Finfo.

Definition at line 102 of file ElementValueFinfo.h.

References Field< A >::innerStrGet(), and Eref::objId().

103  {
105  tgt.objId(), field, returnValue );
106  }
static bool innerStrGet(const ObjId &dest, const string &field, string &str)
Definition: SetGet.h:345
ObjId objId() const
Definition: Eref.cpp:57

+ Here is the call graph for this function:

template<class T, class F>
bool ReadOnlyElementValueFinfo< T, F >::strSet ( const Eref tgt,
const string &  field,
const string &  arg 
) const
inlinevirtual

Function to set this field using a string argument. Returns true on success. Normally called only from SetGet::strSet.

Implements Finfo.

Definition at line 97 of file ElementValueFinfo.h.

98  {
99  return 0;
100  }

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