B2BITS FIX Antenna C++ 2.33.0
|
#include <B2BITS_LogSystem.h>
Public Types | |
typedef std::map< std::string, std::string > | LogProperties |
Public Member Functions | |
void | attach (DeviceObserver *pObserver) |
Attaches Device Observer to get report about critical errors with logging device. | |
LogCategory * | createCategory (const std::string &name) |
Creates new category. | |
LogCategory * | createFakeCategory () |
Creates new fake category. | |
void | detach () |
Detachs Device Observer. | |
void | logVersion (std::string const &text) |
Appends passed text to special category. | |
Static Public Member Functions | |
static void | create (const LogProperties &properties, DeviceObserver *pObserver=NULL) |
Creates and initializes log system. | |
static void | create (const std::string &settingsFileName, DeviceObserver *pObserver=NULL) |
Creates and initializes log system. | |
static void | create (const Utils::Properties &prop, DeviceObserver *pObserver=NULL) |
Creates and initializes log system. | |
static void | create (const Utils::Properties *prop, DeviceObserver *pObserver=NULL) |
Creates and initializes log system. | |
static void | create (std::istream &settings, DeviceObserver *pObserver=NULL) |
Creates and initializes log system. | |
static void | destroy () |
Destroys LogSystem instance. | |
static bool | isCreated () |
Returns true, if log system is initizlized. | |
static LogSystem * | singleton () |
Returns singleton. | |
Protected Member Functions | |
LogSystem () | |
Constructor. | |
virtual | ~LogSystem () |
Destructor. | |
Protected Attributes | |
::Utils::LogImpl::LogSystemImpl * | pImpl_ |
Implementation. | |
Static Protected Attributes | |
static LogSystem * | instance_ |
Singleton. | |
Log system manager.
Acts as a factory and manager for the categories. Either LogSystem::create() or FixEngine::init() method must be called before usage.
typedef std::map<std::string, std::string> Utils::Log::LogSystem::LogProperties |
|
protected |
Constructor.
|
protectedvirtual |
Destructor.
void Utils::Log::LogSystem::attach | ( | DeviceObserver * | pObserver | ) |
Attaches Device Observer to get report about critical errors with logging device.
After event processing Device can be detached from logging or continues to work (depends of the Device Observer's reaction).
pObserver | - device observer. |
|
static |
Creates and initializes log system.
settings | map of property names and values. Cannot be NULL. |
pObserver | device observer. |
Utils::Exception | if input parameter is incorrect. |
|
static |
Creates and initializes log system.
settingsFileName | file with properties. Cannot be NULL. |
pObserver | device observer. |
Utils::Exception | if input parameter is incorrect. |
|
static |
Creates and initializes log system.
prop | Set of properties. Cannot be NULL. |
pObserver | device observer. |
Utils::Exception | if input parameter is incorrect. |
|
static |
Creates and initializes log system.
prop | Set of properties. Cannot be NULL. |
pObserver | device observer. |
Utils::Exception | if input parameter is incorrect. |
|
static |
Creates and initializes log system.
settings | stream with properties. Cannot be NULL. |
pObserver | device observer. |
Utils::Exception | if input parameter is incorrect. |
LogCategory * Utils::Log::LogSystem::createCategory | ( | const std::string & | name | ) |
Creates new category.
name | Category name. |
Utils::Exception | if category properties are incorrect or none of the specified for this category devices are supported by the used platform. |
LogCategory * Utils::Log::LogSystem::createFakeCategory | ( | ) |
Creates new fake category.
All its methods are empty.
|
static |
Destroys LogSystem instance.
void Utils::Log::LogSystem::detach | ( | ) |
Detachs Device Observer.
|
static |
Returns true, if log system is initizlized.
void Utils::Log::LogSystem::logVersion | ( | std::string const & | text | ) |
Appends passed text to special category.
|
static |
Returns singleton.
|
staticprotected |
Singleton.
|
protected |
Implementation.