23 #ifndef _GEMA_VALUE_SET_EVAL_CONTEXT_H_ 24 #define _GEMA_VALUE_SET_EVAL_CONTEXT_H_ 59 int dataIndex()
const {
return _data.localData()._dataIndex; }
64 int ipIndex()
const {
return _data.localData()._ipIndex; }
81 void setDataIndex(
int dataIndex) { assert(dataIndex >= 0); _data.localData()._dataIndex = dataIndex; }
113 CacheAlignedData() : _dataIndex(-1), _ipIndex(-1), _cacheKey(NULL), _cacheEval(NULL) {}
Auxiliar class used to store the definition of a value. It can be used to store informations about st...
Definition: gmValueInfo.h:126
GmUserFunctionEvaluator * _cacheEval
Last used evaluator.
Definition: gmValueSetEvalContext.h:111
A structure to merge cache aligned data since they combined fit inside a cache lign.
Definition: gmValueSetEvalContext.h:106
bool _ghostData
Is this context tied to a ghost value set?
Definition: gmValueSetEvalContext.h:118
Declaration of the GmTLS class.
Class responsible for evaluating a UserFunction over a node / cell.
Definition: gmUserFunction.h:148
GmSimulationData * simulationData() const
Returns the simulationData object.
Definition: gmValueSetEvalContext.h:56
int _ipIndex
The integration point.
Definition: gmValueSetEvalContext.h:109
Declaration of usefull configuration definitions for the Core library.
void setCell(const GmCell *cell, int ip)
Sets the cell / integration point over which values will be calculated.
Definition: gmValueSetEvalContext.h:78
Base interface for mesh cells.
Definition: gmCell.h:81
void setDataIndex(int dataIndex)
Saves the node / cell over which values will be calculated. Ghost indices should be linear indices.
Definition: gmValueSetEvalContext.h:81
const GmMesh * mesh() const
Returns the mesh bound to this EvalContext. Can be NULL for 'incomplete' evaluators.
Definition: gmValueSetEvalContext.h:53
GmTLS< CacheAlignedData, true > _data
Per thread data.
Definition: gmValueSetEvalContext.h:119
A class that works together with GmThreadManager to provide thread local storage.
Definition: gmThreadLocalStorage.h:131
virtual int cellId() const =0
Returns a number identifying the cell. It should be possible to use this id as an index to GmCellMesh...
const GmMesh * _mesh
Bound mesh used to evaluate function params.
Definition: gmValueSetEvalContext.h:116
Auxiliar class used to store the complete set of simulation data.
Definition: gmSimulationData.h:51
const QMap< GmUserFunction *, GmUserFunctionEvaluator * > & evaluatorMap() const
Returns a reference to the evaluator map. Must be called from the main thread only,...
Definition: gmValueSetEvalContext.h:96
bool ghostData() const
Returns a flag set to true if this context is tied to a ghost value set.
Definition: gmValueSetEvalContext.h:67
QMutex _mapMutex
A mutex protecting access to _evalMap.
Definition: gmValueSetEvalContext.h:120
void setGhostData(bool mode)
Changes the flag that states if this context is tied to a ghost value set or not.
Definition: gmValueSetEvalContext.h:84
#define GMC_API_EXPORT
Macro for controling if the class is being exported (GEMA_CORE_LIB defined) or imported (GEMA_CORE_LI...
Definition: gmCoreConfig.h:35
int ipIndex() const
Returns the integration point index equivalent to the coordinate passed to function evaluation or -1 ...
Definition: gmValueSetEvalContext.h:64
Auxiliar class used to store the needed information to translate an user function id / user function ...
Definition: gmValueSetEvalContext.h:45
Class representing a category with multiple logging levels.
Definition: gmLog.h:58
GmUserFunction * _cacheKey
Key describing the last used evaluator.
Definition: gmValueSetEvalContext.h:110
static bool inMainThread()
Is the current thread the main thread? Equivalent to comparing the currentId() with 0.
Definition: gmThreadManager.h:169
int _dataIndex
The node / cell index over which values will be calculated (needed by property sets / boundary condit...
Definition: gmValueSetEvalContext.h:108
GmSimulationData * _simData
Simulation data.
Definition: gmValueSetEvalContext.h:117
Declaration of the GmCell class.
int dataIndex() const
Returns the node/cell index over which the calculation will be made (-1 if not set by the accessor)
Definition: gmValueSetEvalContext.h:59
Base interface class for Mesh type plugins.
Definition: gmMesh.h:44
Class used to store the definition of a user function and its parameters.
Definition: gmUserFunction.h:78