preCICE v3.2.0
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Classes | Public Types | Public Member Functions | Private Member Functions | Private Attributes | List of all members
precice::m2n::M2NConfiguration Class Reference

Configuration for communication channels between solvers. More...

#include <M2NConfiguration.hpp>

Inheritance diagram for precice::m2n::M2NConfiguration:
[legend]
Collaboration diagram for precice::m2n::M2NConfiguration:
[legend]

Classes

struct  ConfiguredM2N
 

Public Types

using SharedPointer = std::shared_ptr<M2NConfiguration>
 

Public Member Functions

 M2NConfiguration (xml::XMLTag &parent)
 
 ~M2NConfiguration () override=default
 
m2n::PtrM2N getM2N (const std::string &acceptor, const std::string &connector)
 Returns the communication object for the given user names.
 
std::vector< ConfiguredM2N > & m2ns ()
 Returns all configured communication objects.
 
bool isM2NConfigured (const std::string &acceptor, const std::string &connector)
 
void xmlTagCallback (const xml::ConfigurationContext &context, xml::XMLTag &callingTag) override
 Callback at begin of XML tag.
 
void xmlEndTagCallback (const xml::ConfigurationContext &context, xml::XMLTag &callingTag) override
 Callback at end of XML tag and at end of subtag.
 
- Public Member Functions inherited from precice::xml::XMLTag::Listener
Listeneroperator= (Listener &&)=delete
 
virtual ~Listener ()=default
 

Private Member Functions

void checkDuplicates (const std::string &acceptor, const std::string &connector)
 

Private Attributes

logging::Logger _log {"m2n::M2NConfiguration"}
 
const std::string TAG = "m2n"
 
const std::string ATTR_EXCHANGE_DIRECTORY = "exchange-directory"
 
const std::string ATTR_ENFORCE_GATHER_SCATTER = "enforce-gather-scatter"
 
const std::string ATTR_USE_TWO_LEVEL_INIT = "use-two-level-initialization"
 
std::vector< ConfiguredM2N_m2ns
 

Detailed Description

Configuration for communication channels between solvers.

Definition at line 16 of file M2NConfiguration.hpp.

Member Typedef Documentation

◆ SharedPointer

Definition at line 18 of file M2NConfiguration.hpp.

Constructor & Destructor Documentation

◆ M2NConfiguration()

precice::m2n::M2NConfiguration::M2NConfiguration ( xml::XMLTag & parent)
explicit

Definition at line 26 of file M2NConfiguration.cpp.

Here is the call graph for this function:

◆ ~M2NConfiguration()

precice::m2n::M2NConfiguration::~M2NConfiguration ( )
overridedefault

Member Function Documentation

◆ checkDuplicates()

void precice::m2n::M2NConfiguration::checkDuplicates ( const std::string & acceptor,
const std::string & connector )
private

Definition at line 207 of file M2NConfiguration.cpp.

◆ getM2N()

m2n::PtrM2N precice::m2n::M2NConfiguration::getM2N ( const std::string & acceptor,
const std::string & connector )

Returns the communication object for the given user names.

Exits with an error message, when no object is configured for the given user names.

Definition at line 112 of file M2NConfiguration.cpp.

◆ isM2NConfigured()

bool precice::m2n::M2NConfiguration::isM2NConfigured ( const std::string & acceptor,
const std::string & connector )

Definition at line 123 of file M2NConfiguration.cpp.

Here is the call graph for this function:

◆ m2ns()

std::vector< ConfiguredM2N > & precice::m2n::M2NConfiguration::m2ns ( )
inline

Returns all configured communication objects.

Definition at line 44 of file M2NConfiguration.hpp.

◆ xmlEndTagCallback()

void precice::m2n::M2NConfiguration::xmlEndTagCallback ( const xml::ConfigurationContext & context,
xml::XMLTag & callingTag )
inlineoverridevirtual

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 53 of file M2NConfiguration.hpp.

◆ xmlTagCallback()

void precice::m2n::M2NConfiguration::xmlTagCallback ( const xml::ConfigurationContext & context,
xml::XMLTag & callingTag )
overridevirtual

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 131 of file M2NConfiguration.cpp.

Here is the call graph for this function:

Member Data Documentation

◆ _log

logging::Logger precice::m2n::M2NConfiguration::_log {"m2n::M2NConfiguration"}
private

Definition at line 56 of file M2NConfiguration.hpp.

◆ _m2ns

std::vector<ConfiguredM2N> precice::m2n::M2NConfiguration::_m2ns
private

Definition at line 63 of file M2NConfiguration.hpp.

◆ ATTR_ENFORCE_GATHER_SCATTER

const std::string precice::m2n::M2NConfiguration::ATTR_ENFORCE_GATHER_SCATTER = "enforce-gather-scatter"
private

Definition at line 60 of file M2NConfiguration.hpp.

◆ ATTR_EXCHANGE_DIRECTORY

const std::string precice::m2n::M2NConfiguration::ATTR_EXCHANGE_DIRECTORY = "exchange-directory"
private

Definition at line 59 of file M2NConfiguration.hpp.

◆ ATTR_USE_TWO_LEVEL_INIT

const std::string precice::m2n::M2NConfiguration::ATTR_USE_TWO_LEVEL_INIT = "use-two-level-initialization"
private

Definition at line 61 of file M2NConfiguration.hpp.

◆ TAG

const std::string precice::m2n::M2NConfiguration::TAG = "m2n"
private

Definition at line 58 of file M2NConfiguration.hpp.


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