preCICE
v3.1.2
Loading...
Searching...
No Matches
src
profiling
config
ProfilingConfiguration.hpp
Go to the documentation of this file.
1
#pragma once
2
3
#include <
string
>
4
#include "
logging/Logger.hpp
"
5
#include "
xml/XMLTag.hpp
"
6
7
namespace
precice
{
9
extern
bool
syncMode
;
10
}
// namespace precice
11
12
namespace
precice::profiling
{
13
14
constexpr
int
DEFAULT_SYNC_EVERY
= 50;
15
constexpr
const
char
*
DEFAULT_MODE
=
"fundamental"
;
16
constexpr
const
char
*
DEFAULT_DIRECTORY
=
"."
;
17
constexpr
const
char
*
MODE_OFF
=
"off"
;
18
constexpr
const
char
*
MODE_FUNDAMENTAL
=
"fundamental"
;
19
constexpr
const
char
*
MODE_ALL
=
"all"
;
20
24
class
ProfilingConfiguration
final :
public
xml::XMLTag::Listener
{
25
public
:
26
ProfilingConfiguration
(
xml::XMLTag
&parent);
27
28
~ProfilingConfiguration
()
override
=
default
;
29
30
void
xmlTagCallback
(
const
xml::ConfigurationContext
&context,
xml::XMLTag
&callingTag)
override
;
31
32
void
xmlEndTagCallback
(
const
xml::ConfigurationContext
&context,
xml::XMLTag
&callingTag)
override
{};
33
34
private
:
35
logging::Logger
_log
{
"profiling::ProfilingConfiguration"
};
36
};
37
38
void
applyDefaults
();
39
40
}
// namespace precice::profiling
Logger.hpp
XMLTag.hpp
precice::logging::Logger
This class provides a lightweight logger.
Definition
Logger.hpp:16
precice::profiling::ProfilingConfiguration
Configuration class for exports.
Definition
ProfilingConfiguration.hpp:24
precice::profiling::ProfilingConfiguration::ProfilingConfiguration
ProfilingConfiguration(xml::XMLTag &parent)
Definition
ProfilingConfiguration.cpp:31
precice::profiling::ProfilingConfiguration::~ProfilingConfiguration
~ProfilingConfiguration() override=default
precice::profiling::ProfilingConfiguration::_log
logging::Logger _log
Definition
ProfilingConfiguration.hpp:35
precice::profiling::ProfilingConfiguration::xmlEndTagCallback
void xmlEndTagCallback(const xml::ConfigurationContext &context, xml::XMLTag &callingTag) override
Callback at end of XML tag and at end of subtag.
Definition
ProfilingConfiguration.hpp:32
precice::profiling::ProfilingConfiguration::xmlTagCallback
void xmlTagCallback(const xml::ConfigurationContext &context, xml::XMLTag &callingTag) override
Callback at begin of XML tag.
Definition
ProfilingConfiguration.cpp:66
precice::xml::XMLTag
Represents an XML tag to be configured automatically.
Definition
XMLTag.hpp:31
precice::profiling
contains profiling utilities.
Definition
ParticipantImpl.hpp:26
precice::profiling::DEFAULT_DIRECTORY
constexpr const char * DEFAULT_DIRECTORY
Definition
ProfilingConfiguration.hpp:16
precice::profiling::MODE_ALL
constexpr const char * MODE_ALL
Definition
ProfilingConfiguration.hpp:19
precice::profiling::MODE_OFF
constexpr const char * MODE_OFF
Definition
ProfilingConfiguration.hpp:17
precice::profiling::MODE_FUNDAMENTAL
constexpr const char * MODE_FUNDAMENTAL
Definition
ProfilingConfiguration.hpp:18
precice::profiling::DEFAULT_SYNC_EVERY
constexpr int DEFAULT_SYNC_EVERY
Definition
ProfilingConfiguration.hpp:14
precice::profiling::applyDefaults
void applyDefaults()
Definition
ProfilingConfiguration.cpp:88
precice::profiling::DEFAULT_MODE
constexpr const char * DEFAULT_MODE
Definition
ProfilingConfiguration.hpp:15
precice
Main namespace of the precice library.
Definition
Acceleration.cpp:5
precice::syncMode
bool syncMode
Enabled further inter- and intra-solver synchronisation.
Definition
PartitionOfUnityMapping.hpp:17
string
precice::xml::ConfigurationContext
Tightly coupled to the parameters of Participant()
Definition
XMLTag.hpp:24
precice::xml::XMLTag::Listener
Callback interface for configuration classes using XMLTag.
Definition
XMLTag.hpp:43