Event Logger Interface


1. General

Event logger interface was introduced to define generic API to application event logger. Component-based design of the application requires that particular component has minimal knowledge about surrounding framework. Event logging functionality is specific to particular application and platform. Hence generic interface is required to hide an implementation.

2. Design goals

Interface was designed to generalize the following functionality and concepts:

Logging parameters substitution. One of important requirements for event logger is ability to dynamically modify output string, depending on number of formal parameters. Interface includes partial implementation of this via printf-like interface; but this functionality is left only for backward compatibility with existing applications. The choice was made to decouple parameter substitution functionality from event logger interface. Currently existing functionality is based on custom stream-based implementation, providing type-safety and convenient usage via overloaded shift operator. So all parameters are expected to be substituted before passing resulting buffer to event logger interface implementation.

Back to the top ↑

3. Interface

Event logger interface defines the following types internally:

These methods return textual representation of event categories as defined by implementation:

This method performs mapping between textual representation of event categories and their binary representation. Additionally it registers allocated bit mask. If no more free bit masks available, zero is returned.

Following entry points define final logging functions:

Back to the top ↑

4. Dependencies

There is no special requirements for this component, only C++ standard-compliant headers should be available.

5. Revisions

Last modified: Fri May 24 11:04:51 Tokyo Standard Time 2002 © Orchid Technology K.K. 2002 All rights reserved