preCICE v3.1.2
Loading...
Searching...
No Matches
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
7namespace precice {
9extern bool syncMode;
10} // namespace precice
11
12namespace precice::profiling {
13
14constexpr int DEFAULT_SYNC_EVERY = 50;
15constexpr const char *DEFAULT_MODE = "fundamental";
16constexpr const char *DEFAULT_DIRECTORY = ".";
17constexpr const char *MODE_OFF = "off";
18constexpr const char *MODE_FUNDAMENTAL = "fundamental";
19constexpr const char *MODE_ALL = "all";
20
25public:
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
34private:
35 logging::Logger _log{"profiling::ProfilingConfiguration"};
36};
37
38void applyDefaults();
39
40} // namespace precice::profiling
This class provides a lightweight logger.
Definition Logger.hpp:16
void xmlEndTagCallback(const xml::ConfigurationContext &context, xml::XMLTag &callingTag) override
Callback at end of XML tag and at end of subtag.
void xmlTagCallback(const xml::ConfigurationContext &context, xml::XMLTag &callingTag) override
Callback at begin of XML tag.
Represents an XML tag to be configured automatically.
Definition XMLTag.hpp:31
contains profiling utilities.
constexpr const char * DEFAULT_DIRECTORY
constexpr const char * MODE_ALL
constexpr const char * MODE_OFF
constexpr const char * MODE_FUNDAMENTAL
constexpr const char * DEFAULT_MODE
Main namespace of the precice library.
bool syncMode
Enabled further inter- and intra-solver synchronisation.
Tightly coupled to the parameters of Participant()
Definition XMLTag.hpp:24
Callback interface for configuration classes using XMLTag.
Definition XMLTag.hpp:43