SFrame 3.6
|
Go to the source code of this file.
Classes | |
class | SLogger |
Universal message logging class. More... | |
Defines | |
#define | SLOGGER_FNAME "" |
#define | SLOGGER_REPORT_PREFIX __FILE__ << ":" << __LINE__ << " (" << SLOGGER_FNAME << "): " |
Common prefix for the non-usual messages. | |
#define | REPORT_VERBOSE(MESSAGE) m_logger << VERBOSE << SLOGGER_REPORT_PREFIX << MESSAGE << SLogger::endmsg |
Convenience macro for reporting VERBOSE messages in the code. | |
#define | REPORT_ERROR(MESSAGE) m_logger << ERROR << SLOGGER_REPORT_PREFIX << MESSAGE << SLogger::endmsg |
Convenience macro for reporting ERROR messages in the code. | |
#define | REPORT_FATAL(MESSAGE) m_logger << FATAL << SLOGGER_REPORT_PREFIX << MESSAGE << SLogger::endmsg |
Convenience macro for reporting FATAL messages in the code. |
#define REPORT_ERROR | ( | MESSAGE | ) | m_logger << ERROR << SLOGGER_REPORT_PREFIX << MESSAGE << SLogger::endmsg |
Convenience macro for reporting ERROR messages in the code.
This macro is very similar to the REPORT_MESSAGE macros of Athena. It prints a nicely formatted output that specifies both the exact function name where the message was printed, and also the filename:line combination. It can be used like a regular function inside cycles:
REPORT_ERROR( "A serious error message" );
Definition at line 210 of file SLogger.h.
Referenced by SFileMerger::AddFile(), SCycleBaseNTuple::ConnectVariable(), SCycleBaseNTuple::DeclareVariable(), SCycleBaseConfig::DecodeEnvVar(), SCycleController::ExecuteNextCycle(), SCycleBaseNTuple::GetMetadataTree(), SToolBaseT< Type >::GetParent(), SCycleController::Initialize(), SProofManager::IsConfigured(), ProofSummedVar< Type >::Merge(), SH1< Type >::Merge(), SFileMerger::Merge(), SCycleOutput::Merge(), SProofManager::Open(), operator+(), SFileMerger::OutputFile(), SCycleBaseExec::Process(), SCycleBaseHist::Retrieve(), SCycleBaseHist::RetrieveAll(), and SCycleOutput::Write().
#define REPORT_FATAL | ( | MESSAGE | ) | m_logger << FATAL << SLOGGER_REPORT_PREFIX << MESSAGE << SLogger::endmsg |
Convenience macro for reporting FATAL messages in the code.
This macro is very similar to the REPORT_MESSAGE macros of Athena. It prints a nicely formatted output that specifies both the exact function name where the message was printed, and also the filename:line combination. It can be used like a regular function inside cycles:
REPORT_FATAL( "A very serious error message" );
Definition at line 224 of file SLogger.h.
Referenced by SCycleBaseExec::Begin(), SH1< Type >::Fill(), SCycleBaseExec::Notify(), SCycleBaseExec::Process(), SProofManager::SetConfigured(), SCycleBaseExec::SlaveBegin(), SCycleBaseExec::SlaveTerminate(), and SCycleBaseExec::Terminate().
#define REPORT_VERBOSE | ( | MESSAGE | ) | m_logger << VERBOSE << SLOGGER_REPORT_PREFIX << MESSAGE << SLogger::endmsg |
Convenience macro for reporting VERBOSE messages in the code.
This macro is very similar to the REPORT_MESSAGE macros of Athena. It prints a nicely formatted output that specifies both the exact function name where the message was printed, and also the filename:line combination. It can be used like a regular function inside cycles:
REPORT_VERBOSE( "This is a verbose message with a number: " << number );
Definition at line 196 of file SLogger.h.
Referenced by SFileMerger::AddFile(), SCycleBaseExec::Begin(), SCycleBaseHist::Book(), SCycleBaseNTuple::CalculateWeight(), SCycleBaseNTuple::ConnectVariable(), SCycleBaseNTuple::CreateOutputTrees(), SCycleBaseNTuple::DeclareVariable(), SCycleController::ExecuteNextCycle(), SCycleBaseNTuple::GetInputMetadataTree(), SCycleBaseNTuple::GetInputTree(), SCycleBaseNTuple::GetMetadataTree(), SCycleBaseNTuple::GetOutputMetadataTree(), SCycleBaseNTuple::GetOutputTree(), SCycleBaseHist::Hist(), SCycleBaseExec::Init(), SCycleController::Initialize(), SCycleBaseConfig::Initialize(), SCycleBaseConfig::InitializeInputData(), SCycleBaseConfig::InitializeUserConfig(), SCycleBaseNTuple::LoadInputTrees(), SFileMerger::Merge(), SCycleBaseExec::Notify(), SProofManager::Open(), SFileMerger::OutputFile(), SCycleBaseExec::Process(), SCycleBaseHist::Retrieve(), SCycleBase::SCycleBase(), SCycleBaseBase::SCycleBaseBase(), SCycleBaseConfig::SCycleBaseConfig(), SCycleBaseExec::SCycleBaseExec(), SCycleBaseHist::SCycleBaseHist(), SCycleBaseNTuple::SCycleBaseNTuple(), SInputData::SInputData(), SCycleBaseExec::SlaveBegin(), SCycleBaseExec::SlaveTerminate(), SCycleBaseExec::Terminate(), SCycleOutput::Write(), SCycleBase::~SCycleBase(), SCycleBaseNTuple::~SCycleBaseNTuple(), and SInputData::~SInputData().
#define SLOGGER_REPORT_PREFIX __FILE__ << ":" << __LINE__ << " (" << SLOGGER_FNAME << "): " |
Common prefix for the non-usual messages.
The idea is that a regular user usually only wants to see DEBUG, INFO and some WARNING messages. So those should be reasonably short. On the other hand serious warnings (ERROR, FATAL) or VERBOSE messages should be as precise as possible.
So I stole the idea from Athena (what a surprise...) to have a few macros which produce messages with a common formatting. This macro provides the prefix for all the messages.