WvStreams
wvsyslog.h
1 /* -*- Mode: C++ -*-
2  * Worldvisions Weaver Software:
3  * Copyright (C) 1997-2002 Net Integration Technologies, Inc.
4  *
5  */
6 #ifndef __WVSYSLOG_H
7 #define __WVSYSLOG_H
8 
9 #include "wvlogrcv.h"
10 
15 class WvSyslog : public WvLogRcv
16 {
17 public:
18  WvSyslog(WvStringParm _prefix, bool _include_appname,
19  WvLog::LogLevel _first_debug = WvLog::Debug,
20  WvLog::LogLevel _max_level = WvLog::NUM_LOGLEVELS);
21  virtual ~WvSyslog();
22 
23 protected:
24  WvLog::LogLevel first_debug;
25  WvDynBuf current;
26  WvString syslog_prefix;
27  bool include_appname;
28 
29  virtual void _begin_line();
30  virtual void _mid_line(const char *str, size_t len);
31  virtual void _end_line();
32 };
33 
34 #endif // __WVLOGBUFFER_H
WvString
WvString is an implementation of a simple and efficient printable-string class.
Definition: wvstring.h:329
WvSyslog
WvSyslog is a descendant of WvLogRcv that sends messages to the syslogd daemon.
Definition: wvsyslog.h:15
WvSyslog::_mid_line
virtual void _mid_line(const char *str, size_t len)
add text to the current log line.
Definition: wvsyslog.cc:38
WvSyslog::_begin_line
virtual void _begin_line()
Start a new log line (print prefix)
Definition: wvsyslog.cc:31
WvLogRcv
WvLogRcv adds some intelligence to WvLogRcvBase, to keep track of line-prefix-printing and other form...
Definition: wvlogrcv.h:28
WvDynBufBase< unsigned char >
WvSyslog::_end_line
virtual void _end_line()
End this (Guaranteed NonEmpty) log line.
Definition: wvsyslog.cc:44