preCICE v3.1.2
|
#include <MeshConfiguration.hpp>
Public Member Functions | |
MeshConfiguration (xml::XMLTag &parent, PtrDataConfiguration config) | |
Constructor, takes a valid data configuration as argument. | |
const std::vector< PtrMesh > & | meshes () const |
Returns all configured meshes. | |
std::vector< PtrMesh > & | meshes () |
Returns all configured meshes. | |
bool | hasMeshName (const std::string &meshName) const |
Returns whether Mesh has Data with the dataName. | |
mesh::PtrMesh | getMesh (const std::string &meshName) const |
Returns the configured mesh with given name, or NULL. | |
virtual void | xmlTagCallback (const xml::ConfigurationContext &context, xml::XMLTag &callingTag) |
Callback at begin of XML tag. | |
virtual void | xmlEndTagCallback (const xml::ConfigurationContext &context, xml::XMLTag &callingTag) |
Callback at end of XML tag and at end of subtag. | |
const PtrDataConfiguration & | getDataConfiguration () const |
void | addMesh (const mesh::PtrMesh &mesh) |
std::map< std::string, std::vector< std::string > > & | getNeededMeshes () |
void | addNeededMesh (const std::string &participant, const std::string &mesh) |
std::unique_ptr< utils::ManageUniqueIDs > | extractMeshIdManager () |
void | insertMeshToMeshDimensionsMap (const std::string &mesh, int dimensions) |
Initialize the map between meshes and dimensions, for unit tests that directly create mesh objects without going through the config reading. | |
Public Member Functions inherited from precice::xml::XMLTag::Listener | |
Listener & | operator= (Listener &&)=delete |
virtual | ~Listener () |
Private Member Functions | |
int | getDataDimensions (const std::string &meshName, const Data::typeName typeName) const |
Get the number of dimensions that data values of this type (scalar/vector) have on this mesh. | |
Private Attributes | |
logging::Logger | _log {"mesh::MeshConfiguration"} |
const std::string | TAG |
const std::string | ATTR_NAME |
const std::string | ATTR_DIMENSIONS |
const std::string | TAG_DATA |
const std::string | ATTR_SIDE_INDEX |
std::map< std::string, int > | _meshDimensionsMap |
PtrDataConfiguration | _dataConfig |
Data configuration. | |
std::vector< PtrMesh > | _meshes |
Configured meshes. | |
std::map< std::string, std::vector< std::string > > | _neededMeshes |
to check later if all meshes that any coupling scheme needs are actually used by the participants | |
std::unique_ptr< utils::ManageUniqueIDs > | _meshIdManager |
utils::ManageUniqueIDs | _dataIDManager |
Definition at line 26 of file MeshConfiguration.hpp.
precice::mesh::MeshConfiguration::MeshConfiguration | ( | xml::XMLTag & | parent, |
PtrDataConfiguration | config ) |
Constructor, takes a valid data configuration as argument.
Definition at line 19 of file MeshConfiguration.cpp.
void precice::mesh::MeshConfiguration::addMesh | ( | const mesh::PtrMesh & | mesh | ) |
void precice::mesh::MeshConfiguration::addNeededMesh | ( | const std::string & | participant, |
const std::string & | mesh ) |
|
inline |
Definition at line 64 of file MeshConfiguration.hpp.
const PtrDataConfiguration & precice::mesh::MeshConfiguration::getDataConfiguration | ( | ) | const |
Definition at line 97 of file MeshConfiguration.cpp.
|
private |
Get the number of dimensions that data values of this type (scalar/vector) have on this mesh.
Definition at line 169 of file MeshConfiguration.cpp.
mesh::PtrMesh precice::mesh::MeshConfiguration::getMesh | ( | const std::string & | meshName | ) | const |
Returns the configured mesh with given name, or NULL.
Definition at line 136 of file MeshConfiguration.cpp.
|
inline |
Definition at line 55 of file MeshConfiguration.hpp.
bool precice::mesh::MeshConfiguration::hasMeshName | ( | const std::string & | meshName | ) | const |
Returns whether Mesh has Data with the dataName.
Definition at line 128 of file MeshConfiguration.cpp.
void precice::mesh::MeshConfiguration::insertMeshToMeshDimensionsMap | ( | const std::string & | mesh, |
int | dimensions ) |
Initialize the map between meshes and dimensions, for unit tests that directly create mesh objects without going through the config reading.
Definition at line 161 of file MeshConfiguration.cpp.
std::vector< PtrMesh > & precice::mesh::MeshConfiguration::meshes | ( | ) |
Returns all configured meshes.
Definition at line 123 of file MeshConfiguration.cpp.
const std::vector< PtrMesh > & precice::mesh::MeshConfiguration::meshes | ( | ) | const |
Returns all configured meshes.
Definition at line 118 of file MeshConfiguration.cpp.
|
virtual |
Callback at end of XML tag and at end of subtag.
At this callback, the attributes and all subtags of callingTag are parsed. This callback is first done for the listener, and then for the parent tag listener (if existing).
Implements precice::xml::XMLTag::Listener.
Definition at line 91 of file MeshConfiguration.cpp.
|
virtual |
Callback at begin of XML tag.
At this callback, the attributes of the callingTag are already parsed and available, while the subtags are not yet parsed.
Implements precice::xml::XMLTag::Listener.
Definition at line 61 of file MeshConfiguration.cpp.
|
private |
Data configuration.
Definition at line 85 of file MeshConfiguration.hpp.
|
private |
Definition at line 98 of file MeshConfiguration.hpp.
|
private |
Definition at line 74 of file MeshConfiguration.hpp.
|
private |
Definition at line 82 of file MeshConfiguration.hpp.
|
private |
Configured meshes.
Definition at line 91 of file MeshConfiguration.hpp.
|
private |
Definition at line 96 of file MeshConfiguration.hpp.
|
private |
to check later if all meshes that any coupling scheme needs are actually used by the participants
Definition at line 94 of file MeshConfiguration.hpp.
|
private |
Definition at line 78 of file MeshConfiguration.hpp.
|
private |
Definition at line 77 of file MeshConfiguration.hpp.
|
private |
Definition at line 80 of file MeshConfiguration.hpp.
|
private |
Definition at line 76 of file MeshConfiguration.hpp.
|
private |
Definition at line 79 of file MeshConfiguration.hpp.