Interface of a variable synchronization service. More...
#include <arcane/core/IVariableSynchronizer.h>
Public Member Functions | |
| virtual IParallelMng * | parallelMng ()=0 |
| Associated parallel manager. | |
| virtual const ItemGroup & | itemGroup ()=0 |
| Entity group used for synchronization. | |
| virtual void | compute ()=0 |
| Recalculates the synchronization information. | |
| virtual void | changeLocalIds (Int32ConstArrayView old_to_new_ids)=0 |
| Called when the local IDs of the entities are modified. | |
| virtual void | synchronize (IVariable *var)=0 |
| Synchronizes the variable var in blocking mode. | |
| virtual void | synchronize (IVariable *var, Int32ConstArrayView local_ids) |
| Synchronizes the variable var on the entities local_ids in blocking mode. | |
| virtual void | synchronize (VariableCollection vars)=0 |
| Synchronizes the variables vars in blocking mode. | |
| virtual void | synchronize (VariableCollection vars, Int32ConstArrayView local_ids) |
| Synchronizes the variables vars in blocking mode. | |
| virtual Int32ConstArrayView | communicatingRanks ()=0 |
| Ranks of subdomains with which communication occurs. | |
| virtual Int32ConstArrayView | sharedItems (Int32 index)=0 |
| List of local IDs of entities shared with a subdomain. | |
| virtual Int32ConstArrayView | ghostItems (Int32 index)=0 |
| List of local IDs of ghost entities with a subdomain. | |
| virtual void | synchronizeData (IData *data)=0 |
| Synchronizes the data data. | |
| virtual EventObservable< const VariableSynchronizerEventArgs & > & | onSynchronized ()=0 |
| Event sent at the beginning and end of synchronization. | |
Interface of a variable synchronization service.
This class is managed by Arcane and is generally not necessary to use directly. If you want to synchronize a variable, you just need to call the VariableRef::synchronize() method.
An instance of this class is created via IParallelMng::createVariableSynchronizer(). An instance is associated with an entity group. You must call the compute() function to calculate the synchronization information. If the entities are compacted, you must call changeLocalIds().
Definition at line 42 of file IVariableSynchronizer.h.
|
inlinevirtual |
Definition at line 46 of file IVariableSynchronizer.h.
|
pure virtual |
Called when the local IDs of the entities are modified.
Implemented in Arcane::NullVariableSynchronizer, and Arcane::VariableSynchronizer.
Referenced by Arcane::mesh::ItemFamily::compactVariablesAndGroups().
|
pure virtual |
Ranks of subdomains with which communication occurs.
Implemented in Arcane::NullVariableSynchronizer, and Arcane::VariableSynchronizer.
Referenced by Arcane::TimeLoopMng::_doMeshPartition(), Arcane::MeshUtils::dumpSynchronizerTopologyJSON(), and Arcane::Materials::MeshMaterialVariableSynchronizer::recompute().
|
pure virtual |
Recalculates the synchronization information.
This operation is collective.
This function must be called if the entities in itemGroup() change owner or if the group itself evolves. TODO: call this function automatically if needed.
Implemented in Arcane::MpiVariableSynchronizer, Arcane::NullVariableSynchronizer, and Arcane::VariableSynchronizer.
|
pure virtual |
List of local IDs of ghost entities with a subdomain.
The rank of the subdomain is that of communicatingRanks()[index].
Implemented in Arcane::NullVariableSynchronizer, and Arcane::VariableSynchronizer.
Referenced by Arcane::Materials::MeshMaterialVariableSynchronizer::recompute().
|
pure virtual |
Entity group used for synchronization.
The current implementation only supports the group of all entities of a family.
Implemented in Arcane::NullVariableSynchronizer, and Arcane::VariableSynchronizer.
Referenced by Arcane::Materials::MeshMaterialVariableSynchronizer::recompute().
|
pure virtual |
Event sent at the beginning and end of synchronization.
This event is sent during calls to the methods synchronize(IVariable* var) and synchronize(VariableCollection vars). If you wish to be notified of synchronizations for all instances of IVariableSynchronizer, you must use IVariableMng::synchronizerMng().
Implemented in Arcane::NullVariableSynchronizer, and Arcane::VariableSynchronizer.
|
pure virtual |
Associated parallel manager.
Implemented in Arcane::NullVariableSynchronizer, and Arcane::VariableSynchronizer.
Referenced by Arcane::MeshUtils::dumpSynchronizerTopologyJSON(), and Arcane::Materials::MeshMaterialVariableSynchronizer::recompute().
|
pure virtual |
List of local IDs of entities shared with a subdomain.
The rank of the subdomain is that of communicatingRanks()[index].
Implemented in Arcane::NullVariableSynchronizer, and Arcane::VariableSynchronizer.
Referenced by Arcane::MeshUtils::dumpSynchronizerTopologyJSON(), and Arcane::Materials::MeshMaterialVariableSynchronizer::recompute().
|
pure virtual |
Synchronizes the variable var in blocking mode.
Implemented in Arcane::NullVariableSynchronizer, and Arcane::VariableSynchronizer.
References synchronize().
Referenced by Arcane::Array2VariableT< T >::synchronize(), Arcane::Array2VariableT< T >::synchronize(), synchronize(), synchronize(), Arcane::VariableArrayT< T >::synchronize(), and Arcane::VariableArrayT< T >::synchronize().
|
virtual |
Synchronizes the variable var on the entities local_ids in blocking mode.
Only the entities listed in local_ids will be synchronized. Note: an entity present in this list on one subdomain must be present in this list for any other subdomain that owns this entity.
Reimplemented in Arcane::NullVariableSynchronizer, and Arcane::VariableSynchronizer.
Definition at line 313 of file InterfaceImpl.cc.
References ARCANE_THROW.
|
pure virtual |
Synchronizes the variables vars in blocking mode.
All variables must belong to the same family and this entity group.
Implemented in Arcane::NullVariableSynchronizer, and Arcane::VariableSynchronizer.
References synchronize().
|
virtual |
Synchronizes the variables vars in blocking mode.
All variables must belong to the same family and this entity group.
Only the entities listed in local_ids will be synchronized. Note: an entity present in this list on one subdomain must be present in this list for any other subdomain that owns this entity.
Reimplemented in Arcane::NullVariableSynchronizer, and Arcane::VariableSynchronizer.
Definition at line 319 of file InterfaceImpl.cc.
References ARCANE_THROW.
|
pure virtual |
Synchronizes the data data.
The data data must be associated with a variable for which it is valid to call synchronize(). This method is internal to Arcane.
Implemented in Arcane::NullVariableSynchronizer, and Arcane::VariableSynchronizer.