CMS 3D CMS Logo

List of all members | Public Member Functions | Private Member Functions | Private Attributes
edm::LogPrint Class Reference

#include <MessageLogger.h>

Public Member Functions

template<typename F >
LogPrintlog (F &&iF)
 
 LogPrint (std::string const &id)
 
LogPrintoperator<< (std::ios_base &(*f)(std::ios_base &))
 
LogPrintoperator<< (std::ostream &(*f)(std::ostream &))
 
template<class T >
LogPrintoperator<< (T const &t)
 
 ~LogPrint ()
 

Private Member Functions

 LogPrint (LogPrint const &)=delete
 
LogPrintoperator= (LogPrint const &)=delete
 

Private Attributes

MessageSender ap
 

Detailed Description

Definition at line 342 of file MessageLogger.h.

Constructor & Destructor Documentation

◆ LogPrint() [1/2]

edm::LogPrint::LogPrint ( std::string const &  id)
inlineexplicit

Definition at line 345 of file MessageLogger.h.

346  : ap(ELwarning,
347  id,
348  true,
349  (MessageDrop::warningAlwaysSuppressed || !MessageDrop::instance()->warningEnabled)) // Change log 21
350  {}

◆ ~LogPrint()

edm::LogPrint::~LogPrint ( )

Definition at line 60 of file MessageLogger.cc.

60 {}

◆ LogPrint() [2/2]

edm::LogPrint::LogPrint ( LogPrint const &  )
privatedelete

Member Function Documentation

◆ log()

template<typename F >
LogPrint& edm::LogPrint::log ( F &&  iF)
inline

Definition at line 372 of file MessageLogger.h.

372  {
373  if (ap.valid()) {
374  iF(ap);
375  }
376  return *this;
377  }

References ap, and edm::MessageSender::valid().

◆ operator<<() [1/3]

LogPrint& edm::LogPrint::operator<< ( std::ios_base &(*)(std::ios_base &)  f)
inline

Definition at line 365 of file MessageLogger.h.

365  {
366  if (ap.valid())
367  ap << f;
368  return *this;
369  }

References ap, f, and edm::MessageSender::valid().

◆ operator<<() [2/3]

LogPrint& edm::LogPrint::operator<< ( std::ostream &(*)(std::ostream &)  f)
inline

Definition at line 360 of file MessageLogger.h.

360  {
361  if (ap.valid())
362  ap << f;
363  return *this;
364  }

References ap, f, and edm::MessageSender::valid().

◆ operator<<() [3/3]

template<class T >
LogPrint& edm::LogPrint::operator<< ( T const &  t)
inline

Definition at line 354 of file MessageLogger.h.

354  {
355  if (ap.valid())
356  ap << t;
357  return *this;
358  }

References ap, OrderedSet::t, and edm::MessageSender::valid().

◆ operator=()

LogPrint& edm::LogPrint::operator= ( LogPrint const &  )
privatedelete

Member Data Documentation

◆ ap

MessageSender edm::LogPrint::ap
private

Definition at line 380 of file MessageLogger.h.

Referenced by log(), and operator<<().

edm::ELwarning
const ELslProxy< ELwarningGen > ELwarning
Definition: ELseverityLevel.cc:302
edm::MessageDrop::warningAlwaysSuppressed
static bool warningAlwaysSuppressed
Definition: MessageDrop.h:112
f
double f[11][100]
Definition: MuScleFitUtils.cc:78
edm::MessageSender::valid
bool valid()
Definition: MessageSender.h:45
OrderedSet.t
t
Definition: OrderedSet.py:90
edm::LogPrint::ap
MessageSender ap
Definition: MessageLogger.h:380
edm::MessageDrop::instance
static MessageDrop * instance()
Definition: MessageDrop.cc:60