Scalar variable on a mesh entity type. More...
#include <arcane/core/MeshVariableScalarRef.h>
Public Types | |
| typedef DataTypeT | DataType |
| typedef UniqueArray< DataTypeT > | ValueType |
| typedef const DataTypeT & | ConstReturnReferenceType |
| typedef DataTypeT & | ReturnReferenceType |
| typedef ArrayView< DataTypeT > | ArrayBase |
| typedef PrivateVariableScalarT< DataTypeT > | BaseClass |
| typedef BaseClass::PrivatePartType | PrivatePartType |
| typedef BaseClass::DataTypeReturnReference | DataTypeReturnReference |
Public Member Functions | |
| ItemVariableScalarRefT (const VariableBuildInfo &b, eItemKind ik) | |
| Constructs a reference to the variable specified in vb. | |
| ItemVariableScalarRefT (IVariable *var) | |
| Constructs a reference from var. | |
| ItemVariableScalarRefT (const ItemVariableScalarRefT< DataTypeT > &rhs) | |
| Constructs a reference from rhs. | |
| void | add (const ItemVariableScalarRefT< DataTypeT > &v) |
| void | sub (const ItemVariableScalarRefT< DataTypeT > &v) |
| void | mult (const ItemVariableScalarRefT< DataTypeT > &v) |
| void | mult (const DataTypeT &v) |
| void | copy (const ItemVariableScalarRefT< DataTypeT > &v) |
| void | power (const DataTypeT &v) |
| void | add (const ItemVariableScalarRefT< DataTypeT > &v, const ItemGroup &group) |
| void | sub (const ItemVariableScalarRefT< DataTypeT > &v, const ItemGroup &group) |
| void | mult (const ItemVariableScalarRefT< DataTypeT > &v, const ItemGroup &group) |
| void | mult (const DataTypeT &v, const ItemGroup &group) |
| void | power (const DataTypeT &v, const ItemGroup &group) |
| void | copy (const ItemVariableScalarRefT< DataTypeT > &v, const ItemGroup &group) |
| Copies the values of v into this variable for the entities in group. | |
| void | fill (const DataTypeT &value) |
| void | fill (const DataTypeT &value, const ItemGroup &group) |
| void | copy (const ItemVariableScalarRefT< DataTypeT > &v, RunQueue *queue) |
| Copies the values of v into this variable via the queue. | |
| void | fill (const DataTypeT &value, RunQueue *queue) |
| Fills the instance values with value via the queue. | |
| const DataType & | operator[] (ItemLocalId item) const |
| Read-only value of entity item. | |
| DataTypeReturnReference | operator[] (ItemLocalId item) |
| Read/write value of entity item. | |
| const DataType & | operator() (ItemLocalId item) const |
| Read-only value of entity item. | |
| DataTypeReturnReference | operator() (ItemLocalId item) |
| Read/write value of entity item. | |
| Public Member Functions inherited from Arcane::PrivateVariableScalarT< DataTypeT > | |
| ArrayView< DataTypeT > | asArray () |
| ConstArrayView< DataTypeT > | asArray () const |
| Integer | arraySize () const |
| If the variable is an array, returns its dimension, otherwise returns 0. | |
| void | updateFromInternal () |
| Updates from the internal part. | |
| ItemGroup | itemGroup () const |
| SmallSpan< DataTypeT > | _internalSpan () |
| SmallSpan< const DataTypeT > | _internalSpan () const |
| SmallSpan< const DataTypeT > | _internalConstSpan () const |
| Public Member Functions inherited from Arcane::MeshVariableRef | |
| MeshVariableRef (const VariableBuildInfo &vb) | |
| Constructs a reference linked to the module. | |
| void | synchronize () |
| void | synchronize (Int32ConstArrayView local_ids) |
| Public Member Functions inherited from Arcane::VariableRef | |
| virtual | ~VariableRef () |
| Releases resources. | |
| ISubDomain * | subDomain () const |
| Sub-domain associated with the variable (TODO deprecate end of 2023). | |
| IVariableMng * | variableMng () const |
| Variable manager associated with the variable. | |
| String | name () const |
| Variable name. | |
| virtual eDataType | dataType () const |
| Variable type (Real, Integer, ...). | |
| virtual void | print (std::ostream &o) const |
| Prints the variable value. | |
| virtual IModule * | module () const |
| Module associated with the variable (or nullptr, if none). | |
| virtual int | property () const |
| Variable properties. | |
| virtual int | referenceProperty () const |
| Reference properties (internal). | |
| virtual void | setProperty (int property) |
| Sets the property property. | |
| virtual void | unsetProperty (int property) |
| Unsets the property property. | |
| virtual void | registerVariable () |
| Registers the variable (internal). | |
| virtual void | unregisterVariable () |
| Unregisters the variable (internal). | |
| IVariable * | variable () const |
| Associated variable. | |
| virtual Integer | checkIfSync (int max_print=0) |
| Checks if the variable is synchronized. | |
| virtual Integer | checkIfSameOnAllReplica (int max_print=0) |
| Checks if the variable has the same values on all replicas. | |
| void | setUsed (bool v) |
| bool | isUsed () const |
| virtual void | internalSetUsed (bool) |
| const String & | assignmentStackTrace () const |
| Call stack at the time of assigning this instance. | |
| void | addTag (const String &tagname, const String &tagvalue) |
| Adds the tag tagname with the value tagvalue. | |
| void | removeTag (const String &tagname) |
| Removes the tag tagname. | |
| bool | hasTag (const String &tagname) const |
| true if the variable has the tag tagname | |
| String | tagValue (const String &tagname) const |
| Value of the tag tagname. The string is null if the tag does not exist. | |
| void | update () |
| Recalculates the variable if necessary. | |
| void | setUpToDate () |
| Indicates that the variable has just been updated. | |
| Int64 | modifiedTime () |
| Time when the variable was updated. | |
| void | addDependCurrentTime (const VariableRef &var) |
| Adds var to the dependency list at the current time. | |
| void | addDependCurrentTime (const VariableRef &var, const TraceInfo &tinfo) |
| Adds var to the dependency list at the current time with trace info tinfo. | |
| void | addDependPreviousTime (const VariableRef &var) |
| Adds var to the dependency list at the previous time. | |
| void | addDependPreviousTime (const VariableRef &var, const TraceInfo &tinfo) |
| Adds var to the dependency list at the previous time with trace info tinfo. | |
| void | removeDepend (const VariableRef &var) |
| Removes var from the dependency list. | |
| template<typename ClassType> | |
| void | setComputeFunction (ClassType *instance, void(ClassType::*func)()) |
| Sets the variable's recalculation function. | |
| template<typename ClassType> | |
| void | setComputeFunction (ClassType *instance, void(ClassType::*func)(), const TraceInfo &tinfo) |
| Sets the variable's recalculation function. | |
| VariableRef * | previousReference () |
| Previous reference (or null) to variable(). | |
| VariableRef * | nextReference () |
| Next reference (or null) to variable(). | |
| void | setPreviousReference (VariableRef *v) |
| void | setNextReference (VariableRef *v) |
Static Public Member Functions | |
| static VariableInfo | _internalVariableInfo (const VariableBuildInfo &vbi, eItemKind ik) |
| static VariableTypeInfo | _internalVariableTypeInfo (eItemKind ik) |
| static void | setTraceCreation (bool v) |
| static bool | hasTraceCreation () |
Protected Member Functions | |
| void | operator= (const ItemVariableScalarRefT< DataTypeT > &rhs) |
| Positions the instance reference to the variable rhs. | |
| ItemVariableScalarRefT () | |
| Default constructor. | |
| Protected Member Functions inherited from Arcane::PrivateVariableScalarT< DataTypeT > | |
| PrivateVariableScalarT (const VariableBuildInfo &vb, const VariableInfo &vi) | |
| Constructs a reference linked to the module. | |
| PrivateVariableScalarT (const PrivateVariableScalarT &rhs) | |
| PrivateVariableScalarT (IVariable *var) | |
| void | operator= (const PrivateVariableScalarT &rhs) |
| void | _internalInit () |
| const DataTypeT & | _value (Integer local_id) const |
| DataTypeReturnReference | _value (Integer local_id) |
| const DataTypeT & | _putValue (Integer index, const DataTypeT &v) |
| Protected Member Functions inherited from Arcane::MeshVariableRef | |
| MeshVariableRef (const MeshVariableRef &rhs) | |
| MeshVariableRef (IVariable *var) | |
| void | operator= (const MeshVariableRef &rhs) |
| void | _internalInit (IVariable *) |
| Protected Member Functions inherited from Arcane::VariableRef | |
| VariableRef (const VariableBuildInfo &vbi) | |
| Constructs a reference to a variable with the infos vbi. | |
| VariableRef (const VariableRef &from) | |
| Copy constructor. | |
| VariableRef (IVariable *var) | |
| Constructs a reference to a variable var. | |
| VariableRef & | operator= (const VariableRef &from) |
| Copy assignment operator. | |
| VariableRef () | |
| Default constructor. | |
| void | _setComputeFunction (IVariableComputeFunction *v) |
| void | _internalInit (IVariable *) |
| Internal initialization of the variable. | |
| IVariable * | _variable () const |
| Referenced variable. | |
| void | _executeUpdateFunctors () |
| void | _internalAssignVariable (const VariableRef &var) |
Additional Inherited Members | |
| Protected Types inherited from Arcane::PrivateVariableScalarT< DataTypeT > | |
| typedef DataTypeT & | DataTypeReturnReference |
| typedef VariableArrayT< DataTypeT > | PrivatePartType |
| Protected Attributes inherited from Arcane::PrivateVariableScalarT< DataTypeT > | |
| PrivatePartType * | m_private_part |
| ArrayView< DataTypeT > | m_view |
| IMemoryAccessTrace * | m_memory_trace |
| bool | m_has_trace = false |
Scalar variable on a mesh entity type.
Definition at line 81 of file MeshVariableScalarRef.h.
| typedef ArrayView<DataTypeT> Arcane::ItemVariableScalarRefT< DataTypeT >::ArrayBase |
Definition at line 91 of file MeshVariableScalarRef.h.
| typedef PrivateVariableScalarT<DataTypeT> Arcane::ItemVariableScalarRefT< DataTypeT >::BaseClass |
Definition at line 92 of file MeshVariableScalarRef.h.
| typedef const DataTypeT& Arcane::ItemVariableScalarRefT< DataTypeT >::ConstReturnReferenceType |
Definition at line 88 of file MeshVariableScalarRef.h.
| typedef DataTypeT Arcane::ItemVariableScalarRefT< DataTypeT >::DataType |
Definition at line 86 of file MeshVariableScalarRef.h.
| typedef BaseClass::DataTypeReturnReference Arcane::ItemVariableScalarRefT< DataTypeT >::DataTypeReturnReference |
Definition at line 94 of file MeshVariableScalarRef.h.
| typedef BaseClass::PrivatePartType Arcane::ItemVariableScalarRefT< DataTypeT >::PrivatePartType |
Definition at line 93 of file MeshVariableScalarRef.h.
| typedef DataTypeT& Arcane::ItemVariableScalarRefT< DataTypeT >::ReturnReferenceType |
Definition at line 89 of file MeshVariableScalarRef.h.
| typedef UniqueArray<DataTypeT> Arcane::ItemVariableScalarRefT< DataTypeT >::ValueType |
Definition at line 87 of file MeshVariableScalarRef.h.
| Arcane::ItemVariableScalarRefT< DataTypeT >::ItemVariableScalarRefT | ( | const VariableBuildInfo & | b, |
| eItemKind | ik ) |
Constructs a reference to the variable specified in vb.
Definition at line 58 of file MeshVariableScalarRef.inst.h.
References Arcane::PrivateVariableScalarT< DataTypeT >::PrivateVariableScalarT().
Referenced by copy(), copy(), fill(), ItemVariableScalarRefT(), Arcane::MeshVariableScalarRefT< ItemTypeT, DataTypeT >::MeshVariableScalarRefT(), Arcane::MeshVariableScalarRefT< ItemTypeT, DataTypeT >::MeshVariableScalarRefT(), Arcane::MeshVariableScalarRefT< ItemTypeT, DataTypeT >::MeshVariableScalarRefT(), and operator=().
|
explicit |
Constructs a reference from var.
Definition at line 73 of file MeshVariableScalarRef.inst.h.
References ARCANE_FATAL, and Arcane::PrivateVariableScalarT< DataTypeT >::PrivateVariableScalarT().
| Arcane::ItemVariableScalarRefT< DataTypeT >::ItemVariableScalarRefT | ( | const ItemVariableScalarRefT< DataTypeT > & | rhs | ) |
Constructs a reference from rhs.
Definition at line 86 of file MeshVariableScalarRef.inst.h.
References ItemVariableScalarRefT(), and Arcane::PrivateVariableScalarT< DataTypeT >::PrivateVariableScalarT().
|
inlineprotected |
Default constructor.
Definition at line 120 of file MeshVariableScalarRef.h.
|
static |
Definition at line 46 of file MeshVariableScalarRef.inst.h.
|
static |
Definition at line 35 of file MeshVariableScalarRef.inst.h.
|
inline |
Definition at line 124 of file MeshVariableScalarRef.h.
|
inline |
Definition at line 149 of file MeshVariableScalarRef.h.
|
inline |
Definition at line 140 of file MeshVariableScalarRef.h.
| void Arcane::ItemVariableScalarRefT< DataTypeT >::copy | ( | const ItemVariableScalarRefT< DataTypeT > & | v, |
| const ItemGroup & | group ) |
Copies the values of v into this variable for the entities in group.
Definition at line 118 of file MeshVariableScalarRef.inst.h.
References ENUMERATE_ITEM, ItemVariableScalarRefT(), and operator[]().
| void Arcane::ItemVariableScalarRefT< DataTypeT >::copy | ( | const ItemVariableScalarRefT< DataTypeT > & | v, |
| RunQueue * | queue ) |
Copies the values of v into this variable via the queue.
queue may be null.
Definition at line 130 of file MeshVariableScalarRef.inst.h.
References Arcane::VariableArrayT< T >::data(), and ItemVariableScalarRefT().
| void Arcane::ItemVariableScalarRefT< DataTypeT >::fill | ( | const DataTypeT & | value | ) |
Definition at line 96 of file MeshVariableScalarRef.inst.h.
| void Arcane::ItemVariableScalarRefT< DataTypeT >::fill | ( | const DataTypeT & | value, |
| const ItemGroup & | group ) |
Definition at line 106 of file MeshVariableScalarRef.inst.h.
| void Arcane::ItemVariableScalarRefT< DataTypeT >::fill | ( | const DataTypeT & | value, |
| RunQueue * | queue ) |
Fills the instance values with value via the queue.
queue may be null.
Definition at line 144 of file MeshVariableScalarRef.inst.h.
References ItemVariableScalarRefT().
|
inline |
Definition at line 136 of file MeshVariableScalarRef.h.
|
inline |
Definition at line 161 of file MeshVariableScalarRef.h.
|
inline |
Definition at line 132 of file MeshVariableScalarRef.h.
|
inline |
Definition at line 157 of file MeshVariableScalarRef.h.
|
inline |
Read/write value of entity item.
Definition at line 200 of file MeshVariableScalarRef.h.
|
inline |
Read-only value of entity item.
Definition at line 197 of file MeshVariableScalarRef.h.
|
protected |
Positions the instance reference to the variable rhs.
Definition at line 158 of file MeshVariableScalarRef.inst.h.
References ItemVariableScalarRefT(), and Arcane::PrivateVariableScalarT< DataTypeT >::updateFromInternal().
Referenced by Arcane::MeshVariableScalarRefT< ItemTypeT, DataTypeT >::refersTo().
|
inline |
Read/write value of entity item.
Definition at line 194 of file MeshVariableScalarRef.h.
|
inline |
Read-only value of entity item.
Definition at line 191 of file MeshVariableScalarRef.h.
Referenced by copy().
|
inline |
Definition at line 144 of file MeshVariableScalarRef.h.
|
inline |
Definition at line 165 of file MeshVariableScalarRef.h.
|
inline |
Definition at line 128 of file MeshVariableScalarRef.h.
|
inline |
Definition at line 153 of file MeshVariableScalarRef.h.