LOCAL0:
reserved for local use. LOCAL1 through LOCAL7 are
available as well.
LPR:
line printer subsystem
MAIL:
mail subsystem
NEWS: USENET news subsystem
SYSLOGBUF:
messages generated internally by syslogbufd
USER: :
generic user-level messages
UUCP:
UUCP subsystem
CONSTRUCTOR
SyslogStream(char *ident,
FBB::Priority priority = FBB::NOTICE,
FBB::Facility facility = FBB::USER,
int option = 0):
This Syslogstream() constructor initializes the streamstream. The
ident parameter is usually the name of the program. Its contents are
prepended to syslog messages. Use value 0 if no text needs to be
prepended.
The priority parameter determines the importance of the message. By
default FBB::NOTICE is used.
The facility parameter determines the type of program doing the
logging. By default FBB::USER is used.
The option parameter may be used to specify various options (use the
binary `bitor' (`|') operator to combine options):
LOG_CONS:
write directly to system console if there is an
error while sending to system logger LOG_NDELAY:
open the connection immediately (normally, the con-
nection is opened when the first message is logged) LOG_PERROR:
print to stderr as well LOG__PID:
include PID with each message
By default no options are used.
The copy constructor is not available.
MEMBER FUNCTIONS
All members of std::streamstream are available, as
FBB::SyslogStream inherits from this class.
Priority defaultPriority() const:
Returns the default priority. I.e., the priority that will be used for
the messages after inserting endl, unless altered by
setDefaultPriority().
Priority priority() const:
Returns the next priority. I.e., the priority that will be used for
the next message, unless altered by setPriority().
Priority setDefaultPriority(Priority priority):
Changes the default priority of the next syslog-message after
inserting std::eoln. Initially, the priority is determined as the value
passed to the constructor. The previously active default priority is returned.
Priority setPriority(Priority priority):
Changes the priority for the next syslog message (after std::eoln
has been inserted). Subsequent messages will use the default priority
again. The previously active priority setting is returned.
MANIPULATORS
The following set of manipulators are all defined as (static) members of
the class FBB::SyslogStream. They may be inserted into an
FBB::SyslogStream. Except for the last manipulator
(strerrno), they have the following characteristics in common:
They will change the priority of the messages that are subsequently
inserted by the FBB::SyslogStream object.
When inserting multiple manipulators before the inserted message is
flushed (e.g., using the ios::flush or the ios::endl manipulators) the
last inserted FBB::SyslogStream manipulator will be used.
Nothing happens if the manipulators are not inserted into an
FBB::SyslogStream object.
Here are the available manipulators:
SyslogStream::alert:
Messages are inserted with priority LOG_ALERT.
SyslogStream::crit:
Message are inserted with priority LOG_CRIT.
SyslogStream::debug:
Messages are inserted with priority LOG_DEBUG.
SyslogStream::emerg:
Messages are inserted with priority LOG_EMERG.
SyslogStream::err:
Messages are inserted with priority LOG_ERR.
SyslogStream::info:
Messages are inserted with priority LOG_INFO.
SyslogStream::notice:
Messages are inserted with priority LOG_NOTICE.
SyslogStream::strerrno:
This manipulator inserts the textual interpretation of
std::errno's current value into a std::ostream. Note that the object
into which the manipulator is inserted does not have to be a
FBB::SyslogStream object.
SyslogStream::warning:
Messages are inserted with priority LOG_WARNING.
The constructor's option parameter is an int. Because of this,
int values rather than enumeration values are passed to the
constructor. It is the responsibility of the programmer to pass defined option
values only.
DISTRIBUTION FILES
bobcat_2.02.03-x.dsc: detached signature;
bobcat_2.02.03-x.tar.gz: source archive;
bobcat_2.02.03-x_i386.changes: change log;
libbobcat1_2.02.03-x_*.deb: debian package holding the
libraries;
libbobcat1-dev_2.02.03-x_*.deb: debian package holding the
libraries, headers and manual pages;
http://sourceforge.net/projects/bobcat: public archive location;
BOBCAT
Bobcat is an acronym of `Brokken's Own Base Classes And Templates'.
COPYRIGHT
This is free software, distributed under the terms of the
GNU General Public License (GPL).