LookupField< L, A > Class Template Reference

#include <SetGet.h>

Inheritance diagram for LookupField< L, A >:
Inheritance graph
[legend]
Collaboration diagram for LookupField< L, A >:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 LookupField (const ObjId &dest)

Static Public Member Functions

static bool set (const ObjId &dest, const string &field, L index, A arg)
static bool setVec (Id destId, const string &field, const vector< L > &index, const vector< A > &arg)
static bool setVec (ObjId dest, const string &field, const vector< L > &index, const vector< A > &arg)
static bool setRepeat (Id destId, const string &field, const vector< L > &index, A arg)
static bool innerStrSet (const ObjId &dest, const string &field, const string &indexStr, const string &val)
static A get (const ObjId &dest, const string &field, L index)
static void getVec (Id dest, const string &field, vector< L > &index, vector< A > &vec)
static bool innerStrGet (const ObjId &dest, const string &field, const string &indexStr, string &str)

Detailed Description

template<class L, class A>
class LookupField< L, A >

LookupField handles fields that have an index arguments. Examples include arrays and maps. The first argument in the 'Set' is the index, the second the value. The first and only argument in the 'get' is the index. Here A is the type of the value, and L the lookup index.


Constructor & Destructor Documentation

template<class L, class A>
LookupField< L, A >::LookupField ( const ObjId dest  )  [inline]

Member Function Documentation

template<class L, class A>
static A LookupField< L, A >::get ( const ObjId dest,
const string &  field,
index 
) [inline, static]

Gets a value on a specific object, looking it up using the provided index.

References SetGet::checkSet(), ObjId::eref(), ObjId::isDataHere(), and LookupGetOpFuncBase< L, A >::returnOp().

Referenced by lookupVolumeFromMesh(), testGetMsg(), testLookupSetGet(), and testTable().

Here is the call graph for this function:

template<class L, class A>
static void LookupField< L, A >::getVec ( Id  dest,
const string &  field,
vector< L > &  index,
vector< A > &  vec 
) [inline, static]

Blocking call that returns a vector of values in vec. This variant goes through each target object entry on dest, and passes in the same lookup index to each one. The results are put together in the vector vec.

References SetGet::checkSet(), Id::element(), Id::path(), Element::resize(), and LookupGetOpFuncBase< L, A >::returnOp().

Here is the call graph for this function:

template<class L, class A>
static bool LookupField< L, A >::innerStrGet ( const ObjId dest,
const string &  field,
const string &  indexStr,
string &  str 
) [inline, static]

Blocking virtual call for finding a value and returning in a string.

template<class L, class A>
static bool LookupField< L, A >::innerStrSet ( const ObjId dest,
const string &  field,
const string &  indexStr,
const string &  val 
) [inline, static]

Blocking call using string conversion

template<class L, class A>
static bool LookupField< L, A >::set ( const ObjId dest,
const string &  field,
index,
arg 
) [inline, static]

Blocking, typed 'Set' call. Identical to SetGet2::set.

Reimplemented from SetGet2< L, A >.

Referenced by testClock(), and testLookupSetGet().

template<class L, class A>
static bool LookupField< L, A >::setRepeat ( Id  destId,
const string &  field,
const vector< L > &  index,
arg 
) [inline, static]

Faking setRepeat too. Just plugs into setVec.

References LookupField< L, A >::setVec().

Here is the call graph for this function:

template<class L, class A>
static bool LookupField< L, A >::setVec ( ObjId  dest,
const string &  field,
const vector< L > &  index,
const vector< A > &  arg 
) [inline, static]

This setVec takes a specific object entry, presumably one with an array of values within it. The it goes through each specified index and assigns the corresponding argument. This is a brute-force assignment.

References LookupField< L, A >::setVec().

Here is the call graph for this function:

template<class L, class A>
static bool LookupField< L, A >::setVec ( Id  destId,
const string &  field,
const vector< L > &  index,
const vector< A > &  arg 
) [inline, static]

This setVec assigns goes through each object entry in the destId, and assigns the corresponding index and argument to it.

Reimplemented from SetGet2< L, A >.

Referenced by LookupField< L, A >::setRepeat(), and LookupField< L, A >::setVec().


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

Generated on 1 Jul 2015 for MOOSE by  doxygen 1.6.1