If an annotation is \e not a POD type (more
specifically, if it's constructor or destructor is not
- trivial), the \a Annotation type \e must inherit from
+ trivial including base classes and members), the \a
+ Annotation type \e must inherit from
senf::ComplexAnnotation. Failing to follow this rule
will result in undefined behavior and will probably
lead to a program crash.
std::string value;
};
\endcode
+ (This type is not POD since \c std::string is not POD)
\implementation The annotation system is implemented
quite efficiently since annotations are stored
namespace senf {
+ /** \brief Marker base-class for complex annotations
+
+ This class is used as a base class to mark an annotation type as complex. A complex
+ annotation will have it's constructor/destructor called. Non-complex annotations will not
+ have their constructor called, they will be zero initialized. The destructor of non-complex
+ annotations is never called.
+
+ An annotation must be marked as complex if it is not <a
+ href="http://en.wikipedia.org/wiki/Plain_Old_Data_Structures">POD</a>. Simplified, an
+ annotation must be marked as ComplexAnnotation, if
+
+ \li it has a (user defined) constructor or destructor
+ \li it has any data members which have (user defined) constructors or destructors
+
+ \see \ref packet_usage_annotation
+ */
struct ComplexAnnotation {};
namespace detail {
The default facility is <tt>LOG_USER</tt>.
+ The SENF log levels are mapped to syslog levels in the following way:
+
+ <table class="senf fixedcolumn">
+ <tr><td>senf::log::VERBOSE</td> <td>\c LOG_DEBUG</td></tr>
+ <tr><td>senf::log::NOTICE</td> <td>\c LOG_INFO</td></tr>
+ <tr><td>senf::log::MESSAGE</td> <td>\c LOG_NOTICE</td></tr>
+ <tr><td>senf::log::IMPORTANT</td> <td>\c LOG_WARNING</td></tr>
+ <tr><td>senf::log::CRITICAL</td> <td>\c LOG_CRIT</td></tr>
+ <tr><td>senf::log::FATAL</td> <td>\c LOG_EMERG</td></tr>
+ </table>
+
\ingroup targets
*/
class SyslogTarget
async
attr
Augustin
+AUTHPRIV
autoadd
autoparse
autoThrottling
createAfter
createBefore
cref
+CRON
ct
cti
CXXFLAGS
localAddr
localhost
loopback
+LPR
mac
MACAddress
MACAddressParser
svnroot
SyntaxErrorException
SyntaxException
+syslog
+SyslogTarget
SystemException
TapSocketHandle
td