Peano 4
Loading...
Searching...
No Matches
tarch::logging::LogFilter::FilterListEntry Struct Reference

Represents one entry of the filter list. More...

#include <LogFilter.h>

Collaboration diagram for tarch::logging::LogFilter::FilterListEntry:

Public Member Functions

bool operator< (const FilterListEntry &b) const
 
bool operator== (const FilterListEntry &b) const
 
bool operator!= (const FilterListEntry &b) const
 
 FilterListEntry (const std::string &targetName="", bool isBlackListEntry=false)
 Construct filter list entry for one target without any.
 
 FilterListEntry (const std::string &targetName, int rank, const std::string &className, bool isBlackListEntry, const std::string &programPhase)
 
std::string toString () const
 

Data Fields

std::string _targetName
 The message type target can be either "debug" or "info".
 
int _rank
 Sometimes, one wants to block all log entries of one namespace of one node (parallel case).
 
std::string _namespaceName
 Name of the namespace that should not be logged.
 
bool _isBlackEntry
 If true, filter list entry is a filter list entry, otherwise white list.
 
std::string _programPhase
 AlwaysOn if the filter entry applies for all phases.
 

Static Public Attributes

static const int AnyRank = -1
 
static const std::string TargetAll = "all"
 
static const std::string TargetInfo = "info"
 
static const std::string TargetDebug = "debug"
 
static const std::string TargetTrace = "trace"
 
static const std::string TargetWarning = "warning"
 
static const std::string AlwaysOn = "always-on"
 
static const bool BlackListEntry = true
 
static const bool WhiteListEntry = false
 

Detailed Description

Represents one entry of the filter list.

Syntax:

<log-filter target="debug" component="component-name" rank="int|*" switch="on|off" />

Definition at line 30 of file LogFilter.h.

Constructor & Destructor Documentation

◆ FilterListEntry() [1/2]

tarch::logging::LogFilter::FilterListEntry::FilterListEntry ( const std::string & targetName = "",
bool isBlackListEntry = false )

Construct filter list entry for one target without any.

Definition at line 26 of file LogFilter.cpp.

References assertion1, TargetAll, TargetDebug, TargetInfo, TargetTrace, and TargetWarning.

◆ FilterListEntry() [2/2]

tarch::logging::LogFilter::FilterListEntry::FilterListEntry ( const std::string & targetName,
int rank,
const std::string & className,
bool isBlackListEntry,
const std::string & programPhase )

Definition at line 35 of file LogFilter.cpp.

References assertion1, TargetAll, TargetDebug, TargetInfo, TargetTrace, and TargetWarning.

Member Function Documentation

◆ operator!=()

bool tarch::logging::LogFilter::FilterListEntry::operator!= ( const FilterListEntry & b) const

Definition at line 78 of file LogFilter.cpp.

References operator==().

Here is the call graph for this function:

◆ operator<()

bool tarch::logging::LogFilter::FilterListEntry::operator< ( const FilterListEntry & b) const

Definition at line 64 of file LogFilter.cpp.

◆ operator==()

bool tarch::logging::LogFilter::FilterListEntry::operator== ( const FilterListEntry & b) const

Definition at line 71 of file LogFilter.cpp.

◆ toString()

std::string tarch::logging::LogFilter::FilterListEntry::toString ( ) const

Definition at line 44 of file LogFilter.cpp.

Referenced by tarch::logging::LogFilter::addFilterListEntry().

Here is the caller graph for this function:

Field Documentation

◆ _isBlackEntry

bool tarch::logging::LogFilter::FilterListEntry::_isBlackEntry

If true, filter list entry is a filter list entry, otherwise white list.

Definition at line 68 of file LogFilter.h.

◆ _namespaceName

std::string tarch::logging::LogFilter::FilterListEntry::_namespaceName

Name of the namespace that should not be logged.

Definition at line 63 of file LogFilter.h.

◆ _programPhase

std::string tarch::logging::LogFilter::FilterListEntry::_programPhase

AlwaysOn if the filter entry applies for all phases.

Otherwise, it only applies for a specific phase.

Definition at line 74 of file LogFilter.h.

◆ _rank

int tarch::logging::LogFilter::FilterListEntry::_rank

Sometimes, one wants to block all log entries of one namespace of one node (parallel case).

In this case _rank holds the corresponding entry, if all entries from one namespace have to be blocked, the value of _rank equals AnyRank.

Definition at line 58 of file LogFilter.h.

◆ _targetName

std::string tarch::logging::LogFilter::FilterListEntry::_targetName

The message type target can be either "debug" or "info".

Only messages with corresponding target are filtered by the FilterListEntry.

If left blank, all message types are targeted.

Definition at line 50 of file LogFilter.h.

◆ AlwaysOn

const std::string tarch::logging::LogFilter::FilterListEntry::AlwaysOn = "always-on"
static

◆ AnyRank

const int tarch::logging::LogFilter::FilterListEntry::AnyRank = -1
static

◆ BlackListEntry

const bool tarch::logging::LogFilter::FilterListEntry::BlackListEntry = true
static

◆ TargetAll

const std::string tarch::logging::LogFilter::FilterListEntry::TargetAll = "all"
static

◆ TargetDebug

◆ TargetInfo

◆ TargetTrace

const std::string tarch::logging::LogFilter::FilterListEntry::TargetTrace = "trace"
static

◆ TargetWarning

const std::string tarch::logging::LogFilter::FilterListEntry::TargetWarning = "warning"
static

◆ WhiteListEntry

const bool tarch::logging::LogFilter::FilterListEntry::WhiteListEntry = false
static

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