PISM, A Parallel Ice Sheet Model  stable v2.1.1 committed by Constantine Khrulev on 2024-12-04 13:36:58 -0900
Classes | Public Member Functions | Protected Member Functions | Private Attributes | List of all members
pism::StringLogger Class Reference

A logger that accumulates messages and reports them as a string. More...

#include <Logger.hh>

+ Inheritance diagram for pism::StringLogger:

Classes

struct  Impl
 

Public Member Functions

 StringLogger (MPI_Comm com, int threshold)
 
virtual ~StringLogger ()
 
void reset ()
 
std::string get () const
 
- Public Member Functions inherited from pism::Logger
 Logger (MPI_Comm com, int threshold)
 
virtual ~Logger ()
 
void message (int threshold, const char format[],...) const __attribute__((format(printf
 Print a message to the log. More...
 
void void message (int threshold, const std::string &text) const
 
void error (const char format[],...) const __attribute__((format(printf
 Print an error message to the log. More...
 
void void set_threshold (int level)
 Set verbosity threshold. More...
 
int get_threshold () const
 Get verbosity threshold. More...
 
void disable () const
 Silence the logger. More...
 
void enable () const
 (Re-)enable the logger. More...
 

Protected Member Functions

virtual void message_impl (const char buffer[]) const
 Do the hard work. Override this in a derived class to customize. More...
 
virtual void error_impl (const char buffer[]) const
 

Private Attributes

Implm_impl
 

Additional Inherited Members

- Public Types inherited from pism::Logger
typedef std::shared_ptr< LoggerPtr
 
typedef std::shared_ptr< const LoggerConstPtr
 

Detailed Description

A logger that accumulates messages and reports them as a string.

Definition at line 87 of file Logger.hh.


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