The DebugHelper class is responsible for debug output.
More...
#include <debug_helper.hpp>
|
unsigned int | getLevel () const |
| returns the debug level that is set More...
|
|
std::string | getLevelString () const |
| returns the debug levels that are set as string More...
|
|
void | setLevels () |
| sets the allowed debug levels More...
|
|
void | write (const char *text, const unsigned int &levels) const |
| writes the text to the console if it has a level that allows it More...
|
|
void | write (const std::string &text, const unsigned int &levels) const |
| writes the text to the console if it has a level that allows it More...
|
|
void | write (const std::ostream &text, const unsigned int &levels) const |
| writes the text to the console if it has a level that allows it More...
|
|
void | writeNoticeably (const char *text, const unsigned int &levels) const |
| writes the text noticeably to the console if it has a level that allows it More...
|
|
void | writeNoticeably (const std::string &text, const unsigned int &levels) const |
| writes the text noticeably to the console if it has a level that allows it More...
|
|
void | writeNoticeably (const std::ostream &text, const unsigned int &levels) const |
| writes the text noticeably to the console if it has a level that allows it More...
|
|
|
static void | addToString (std::string &s, const std::string &add) |
| adds a string to a given string s. Puts a comma between them if the string s has a size bigger than 0. More...
|
|
static int | parseLevels (const std::vector< std::string > &levels) |
| parses the level list to the corresponding integer More...
|
|
The DebugHelper class is responsible for debug output.
Definition at line 30 of file debug_helper.hpp.
Enumerator |
---|
PARAMETERS |
|
SERVICE_CALLS |
|
COMMON_INFORMATION |
|
FOUND_OBJECT |
|
VIEW_PORT |
|
COMPLETE_PATTERN |
|
Definition at line 34 of file debug_helper.hpp.
world_model::DebugHelper::DebugHelper |
( |
| ) |
|
|
private |
void world_model::DebugHelper::addToString |
( |
std::string & |
s, |
|
|
const std::string & |
add |
|
) |
| |
|
staticprivate |
adds a string to a given string s. Puts a comma between them if the string s has a size bigger than 0.
- Parameters
-
s | [in,out] the string |
add | [in] the string to add |
Definition at line 210 of file debug_helper.cpp.
bool world_model::DebugHelper::checkLevel |
( |
const unsigned int & |
levels | ) |
const |
|
private |
checks whether the given level is allowed
- Parameters
-
- Returns
- whether the given level is allowed. true if it is allowed and false if it is not.
Definition at line 142 of file debug_helper.cpp.
std::string world_model::DebugHelper::getDebugLevelString |
( |
const unsigned int & |
levels | ) |
const |
|
private |
returns the name of the given DebugLevel
- Parameters
-
- Returns
- the name of the given DebugLevel
Definition at line 122 of file debug_helper.cpp.
unsigned int world_model::DebugHelper::getLevel |
( |
| ) |
const |
returns the debug level that is set
- Returns
- the debug level that is set.
Definition at line 86 of file debug_helper.cpp.
std::string world_model::DebugHelper::getLevelString |
( |
| ) |
const |
returns the debug levels that are set as string
- Returns
- the debug levels that are set as string.
Definition at line 91 of file debug_helper.cpp.
int world_model::DebugHelper::parseLevels |
( |
const std::vector< std::string > & |
levels | ) |
|
|
staticprivate |
parses the level list to the corresponding integer
- Parameters
-
levels | the list of level strings |
- Returns
- the corresponding integer
Definition at line 171 of file debug_helper.cpp.
void world_model::DebugHelper::resetInstance |
( |
| ) |
|
|
static |
void world_model::DebugHelper::setLevels |
( |
| ) |
|
void world_model::DebugHelper::write |
( |
const char * |
text, |
|
|
const unsigned int & |
levels |
|
) |
| const |
writes the text to the console if it has a level that allows it
- Parameters
-
text | the text |
level | the debug level of the text |
Definition at line 40 of file debug_helper.cpp.
void world_model::DebugHelper::write |
( |
const std::string & |
text, |
|
|
const unsigned int & |
levels |
|
) |
| const |
writes the text to the console if it has a level that allows it
- Parameters
-
text | the text |
level | the debug level of the text |
Definition at line 47 of file debug_helper.cpp.
void world_model::DebugHelper::write |
( |
const std::ostream & |
text, |
|
|
const unsigned int & |
levels |
|
) |
| const |
writes the text to the console if it has a level that allows it
- Parameters
-
text | the text |
level | the debug level of the text |
Definition at line 53 of file debug_helper.cpp.
void world_model::DebugHelper::writeNoticeably |
( |
const char * |
text, |
|
|
const unsigned int & |
levels |
|
) |
| const |
writes the text noticeably to the console if it has a level that allows it
- Parameters
-
text | the text |
level | the debug level of the text |
Definition at line 61 of file debug_helper.cpp.
void world_model::DebugHelper::writeNoticeably |
( |
const std::string & |
text, |
|
|
const unsigned int & |
levels |
|
) |
| const |
writes the text noticeably to the console if it has a level that allows it
- Parameters
-
text | the text |
level | the debug level of the text |
Definition at line 70 of file debug_helper.cpp.
void world_model::DebugHelper::writeNoticeably |
( |
const std::ostream & |
text, |
|
|
const unsigned int & |
levels |
|
) |
| const |
writes the text noticeably to the console if it has a level that allows it
- Parameters
-
text | the text |
level | the debug level of the text |
Definition at line 77 of file debug_helper.cpp.
const int world_model::DebugHelper::ALL |
|
staticprivate |
unsigned int world_model::DebugHelper::mLevels |
|
private |
const int world_model::DebugHelper::NONE = 0 |
|
staticprivate |
The documentation for this class was generated from the following files:
asr_world_model
Author(s): Aumann Florian, Borella Jocelyn, Hutmacher Robin, Karrenbauer Oliver, Meißner Pascal, Schleicher Ralf, Stöckle Patrick, Trautmann Jeremias
autogenerated on Thu Jan 9 2020 07:20:01