v0.14.0 |
Log manager is used to build and partition problems. More...
#include <src/interfaces/LogManager.hpp>
Classes | |
struct | InternalData |
Public Types | |
enum | SeverityLevel { noisy, verbose, inform, warning, error } |
Severity levels. More... | |
enum | LogAttributesBits { BitLineID = 1 << 0, BitScope = 1 << 1 } |
Tag attributes switches. More... | |
typedef boost::log::sources::severity_channel_logger< SeverityLevel, std::string > | LoggerType |
Definition of the channel logger. More... | |
typedef sinks::synchronous_sink< sinks::text_ostream_backend > | SinkType |
Public Member Functions | |
MoFEMErrorCode | query_interface (boost::typeindex::type_index type_index, UnknownInterface **iface) const |
LogManager (const MoFEM::Core &core) | |
virtual | ~LogManager ()=default |
Public Member Functions inherited from MoFEM::UnknownInterface | |
template<class IFACE > | |
MoFEMErrorCode | registerInterface (bool error_if_registration_failed=true) |
Register interface. More... | |
template<class IFACE > | |
MoFEMErrorCode | getInterface (IFACE *&iface) const |
Get interface reference to pointer of interface. More... | |
template<class IFACE > | |
MoFEMErrorCode | getInterface (IFACE **const iface) const |
Get interface pointer to pointer of interface. More... | |
template<class IFACE , typename boost::enable_if< boost::is_pointer< IFACE >, int >::type = 0> | |
IFACE | getInterface () const |
Get interface pointer to pointer of interface. More... | |
template<class IFACE , typename boost::enable_if< boost::is_reference< IFACE >, int >::type = 0> | |
IFACE | getInterface () const |
Get reference to interface. More... | |
template<class IFACE > | |
IFACE * | getInterface () const |
Function returning pointer to interface. More... | |
virtual | ~UnknownInterface ()=default |
Static Public Member Functions | |
static void | addAttributes (LogManager::LoggerType &lg, const int bit=0) |
Add attributes to logger. More... | |
static void | addAttributes (const std::string channel, const int bit=0) |
Add attributes to channel. More... | |
static LoggerType & | setLog (const std::string channel) |
Set ans resset chanel logger. More... | |
static LoggerType & | getLog (const std::string channel) |
Get logger by channel. More... | |
static bool | checkIfChannelExist (const std::string channel) |
Check if channel exist. More... | |
static void | addTag (LogManager::LoggerType &lg, const std::string tag) |
Add tag to logger. More... | |
static void | addTag (const std::string channel, const std::string tag) |
Add tag to channel. More... | |
static boost::shared_ptr< std::ostream > | getStrmSelf () |
Get the strm self object. More... | |
static boost::shared_ptr< std::ostream > | getStrmWorld () |
Get the strm world object. More... | |
static boost::shared_ptr< std::ostream > | getStrmSync () |
Get the strm sync object. More... | |
static boost::shared_ptr< std::ostream > | getStrmNull () |
Get the strm null object. More... | |
static boost::shared_ptr< SinkType > | createSink (boost::shared_ptr< std::ostream > stream_ptr, std::string comm_filter) |
Create a sink object. More... | |
static void | createDefaultSinks (MPI_Comm comm) |
Create default sinks. More... | |
static MoFEMErrorCode | getOptions () |
Get logger option. More... | |
static PetscErrorCode | logPetscFPrintf (FILE *fd, const char format[], va_list Argp) |
Use to handle PETSc output. More... | |
static std::string | getVLikeFormatedString (const char *fmt, va_list args) |
Converts formatted output to string. More... | |
static std::string | getCLikeFormatedString (const char *fmt,...) |
Converts formatted output to string. More... | |
static void | recordFormatterDefault (logging::record_view const &rec, logging::formatting_ostream &strm) |
Default record formatter. More... | |
Static Public Member Functions inherited from MoFEM::UnknownInterface | |
static MoFEMErrorCode | getLibVersion (Version &version) |
Get library version. More... | |
static MoFEMErrorCode | getFileVersion (moab::Interface &moab, Version &version) |
Get database major version. More... | |
static MoFEMErrorCode | setFileVersion (moab::Interface &moab, Version version=Version(MoFEM_VERSION_MAJOR, MoFEM_VERSION_MINOR, MoFEM_VERSION_BUILD)) |
Get database major version. More... | |
static MoFEMErrorCode | getInterfaceVersion (Version &version) |
Get database major version. More... | |
Static Public Attributes | |
static constexpr std::array< char *const, error+1 > | severityStrings |
static FILE * | dummy_mofem_fd = (FILE *)&dummy_file |
Dummy file pointer (DO NOT USE) More... | |
Private Attributes | |
MoFEM::Core & | cOre |
Static Private Attributes | |
static boost::shared_ptr< InternalData > | internalDataPtr |
static std::string | petscStringCache = std::string() |
Log manager is used to build and partition problems.
Definition at line 26 of file LogManager.hpp.
typedef boost::log::sources::severity_channel_logger<SeverityLevel, std::string> MoFEM::LogManager::LoggerType |
Definition of the channel logger.
Definition at line 64 of file LogManager.hpp.
typedef sinks::synchronous_sink<sinks::text_ostream_backend> MoFEM::LogManager::SinkType |
Definition at line 66 of file LogManager.hpp.
MoFEM::LogManager::LogManager | ( | const MoFEM::Core & | core | ) |
Definition at line 141 of file LogManager.cpp.
|
virtualdefault |
|
static |
Check if channel exist.
channel |
Definition at line 404 of file LogManager.cpp.
|
static |
|
static |
Create a sink object.
stream_ptr | |
comm_filter |
Definition at line 298 of file LogManager.cpp.
|
static |
Converts formatted output to string.
fmt | |
args |
Definition at line 471 of file LogManager.cpp.
|
static |
Get logger option.
This function is called by MoFEM core when this interface is registred into database.
Definition at line 152 of file LogManager.cpp.
|
static |
Get the strm null object.
Definition at line 352 of file LogManager.cpp.
|
static |
Get the strm self object.
Definition at line 340 of file LogManager.cpp.
|
static |
Get the strm sync object.
Definition at line 348 of file LogManager.cpp.
|
static |
Get the strm world object.
Definition at line 344 of file LogManager.cpp.
|
static |
Converts formatted output to string.
fmt | |
args |
Definition at line 465 of file LogManager.cpp.
|
static |
Use to handle PETSc output.
fd | |
format | |
Argp |
Definition at line 411 of file LogManager.cpp.
|
virtual |
|
static |
|
private |
Definition at line 234 of file LogManager.hpp.
|
static |
Dummy file pointer (DO NOT USE)
Definition at line 191 of file LogManager.hpp.
|
staticprivate |
Definition at line 236 of file LogManager.hpp.
|
staticprivate |
Definition at line 239 of file LogManager.hpp.
|
staticconstexpr |
Definition at line 35 of file LogManager.hpp.