nidas v1.2.3
|
#include "Logger.h"
#include "ThreadSupport.h"
#include "Thread.h"
#include "UTime.h"
#include <string>
#include <cerrno>
#include <cstring>
#include <cstdarg>
#include <vector>
#include <map>
#include <algorithm>
#include <stdexcept>
#include <cctype>
#include <cstdlib>
#include <execinfo.h>
Classes | |
class | nidas::util::LoggerPrivate |
Namespaces | |
namespace | nidas |
Root namespace for the NCAR In-Situ Data Acquisition Software. | |
namespace | nidas::util |
General utility classes. nidas::util contains classes of general utility, like Socket, Thread, etc. The classes use only the standard Unix system libraries and libstdc++, and have no dependency on other external packages such as an XML parser, or a logging package. | |
Macros | |
#define | DEBUG_LOGGER 0 |
Typedefs | |
typedef vector< LogContext * > | log_points_v |
typedef map< string, LogScheme > | log_schemes_t |
Functions | |
static LogScheme | get_scheme (const std::string &name) |
Get a scheme with the name, or return a default. | |
static LogScheme * | lookup_scheme (const std::string &name) |
This must be called while the mutex is locked, since it accesses the shared LogScheme map, and it returns a pointer which might change once the lock is released. | |
static void | stream_backtrace (std::ostream &out) |
static string | fillError (string fmt) |
bool | parse_log_level (int &level_out, const std::string &text) |
int | nidas::util::stringToLogLevel (const std::string &slevel) |
Convert the name of a log level to its integer value. | |
string | nidas::util::logLevelToString (int) |
Convert an integral log level to a string name. | |
Variables | |
static log_points_v | log_points |
Vector of pointers to all the LogContext instances initialized so far. | |
static log_schemes_t | log_schemes |
Map of all the known LogScheme instances. | |
static LogScheme | current_scheme = get_scheme("") |
static LogScheme::LogField | default_fields [] |
static LogContext | show_point (LOG_STATIC_CONTEXT(LOGGER_INFO), "show_log_points") |
#define DEBUG_LOGGER 0 |
Referenced by nidas::util::LoggerPrivate::get_active_flag(), and nidas::util::LoggerPrivate::reconfig().
typedef vector<LogContext*> log_points_v |
typedef map<string,LogScheme> log_schemes_t |
|
static |
References err.
Referenced by nidas::util::LogMessage::format(), and nidas::util::Logger::log().
|
static |
Get a scheme with the name, or return a default.
Must be called with the mutex locked.
References nidas::util::LogConfig::level, log_schemes, nidas::util::LOGGER_WARNING, and lookup_scheme().
Referenced by nidas::util::Logger::clearSchemes(), nidas::util::Logger::getScheme(), and nidas::util::Logger::setScheme().
|
static |
This must be called while the mutex is locked, since it accesses the shared LogScheme map, and it returns a pointer which might change once the lock is released.
References log_schemes.
Referenced by get_scheme(), and nidas::util::Logger::knownScheme().
bool parse_log_level | ( | int & | level_out, |
const std::string & | text ) |
References nidas::util::LOGGER_NONE, nidas::util::LOGGER_VERBOSE, and nidas::util::stringToLogLevel().
Referenced by nidas::util::LogConfig::parse().
|
static |
Referenced by nidas::util::LoggerPrivate::reconfig().
|
static |
|
static |
|
static |
Vector of pointers to all the LogContext instances initialized so far.
Referenced by nidas::util::Logger::clearSchemes(), nidas::util::LogContext::LogContext(), nidas::util::Logger::setScheme(), nidas::util::Logger::setScheme(), nidas::util::LogScheme::showLogPoints(), nidas::util::Logger::updateScheme(), and nidas::util::LogContext::~LogContext().
|
static |
Map of all the known LogScheme instances.
Referenced by nidas::util::Logger::clearSchemes(), get_scheme(), lookup_scheme(), nidas::util::Logger::setScheme(), and nidas::util::Logger::updateScheme().
|
static |
Referenced by nidas::util::LogScheme::show_log_point().