log4cpp::CategoryStream Class Reference

#include <CategoryStream.hh>

List of all members.

Public Types

typedef CategoryStream &(* cspf )(CategoryStream &)
typedef CategoryStream &(* cspf )(CategoryStream &)

Public Member Functions

 CategoryStream (Category &category, Priority::Value priority)
 CategoryStream (Category &category, Priority::Value priority)
void flush ()
void flush ()
CategorygetCategory () const
CategorygetCategory () const
Priority::Value getPriority () const throw ()
Priority::Value getPriority () const throw ()
CategoryStreamoperator<< (cspf)
template<typename T >
CategoryStreamoperator<< (const std::string &t)
template<typename T >
CategoryStreamoperator<< (const T &t)
CategoryStreamoperator<< (cspf)
template<typename T >
CategoryStreamoperator<< (const std::string &t)
template<typename T >
CategoryStreamoperator<< (const T &t)
std::streamsize width (std::streamsize wide)
std::streamsize width (std::streamsize wide)
 ~CategoryStream ()
 ~CategoryStream ()

Private Attributes

union {
   std::ostringstream *   _buffer
}; 
union {
   std::ostringstream *   _buffer
}; 
Category_category
Priority::Value _priority

Friends

LOG4CPP_EXPORT friend
CategoryStream
eol (CategoryStream &os)
LOG4CPP_EXPORT friend
CategoryStream
eol (CategoryStream &os)
LOG4CPP_EXPORT friend
CategoryStream
left (CategoryStream &os)
LOG4CPP_EXPORT friend
CategoryStream
left (CategoryStream &os)

Detailed Description

This class enables streaming simple types and objects to a category. Use category.errorStream(), etc. to obtain a CategoryStream class.

Definition at line 39 of file include/log4cpp/CategoryStream.hh.


Member Typedef Documentation

Definition at line 135 of file install/include/log4cpp/CategoryStream.hh.

Definition at line 135 of file include/log4cpp/CategoryStream.hh.


Constructor & Destructor Documentation

log4cpp::CategoryStream::CategoryStream ( Category category,
Priority::Value  priority 
)

Construct a CategoryStream for given Category with given priority.

Parameters:
category The category this stream will send log messages to.
priority The priority the log messages will get or Priority::NOTSET to silently discard any streamed in messages.

Definition at line 21 of file CategoryStream.cpp.

log4cpp::CategoryStream::~CategoryStream (  ) 

Destructor for CategoryStream

Definition at line 27 of file CategoryStream.cpp.

log4cpp::CategoryStream::CategoryStream ( Category category,
Priority::Value  priority 
)

Construct a CategoryStream for given Category with given priority.

Parameters:
category The category this stream will send log messages to.
priority The priority the log messages will get or Priority::NOTSET to silently discard any streamed in messages.
log4cpp::CategoryStream::~CategoryStream (  ) 

Destructor for CategoryStream


Member Function Documentation

void log4cpp::CategoryStream::flush (  ) 

Flush the contents of the stream buffer to the Category and empties the buffer.

void log4cpp::CategoryStream::flush (  ) 

Flush the contents of the stream buffer to the Category and empties the buffer.

Definition at line 31 of file CategoryStream.cpp.

Category& log4cpp::CategoryStream::getCategory (  )  const [inline]

Returns the destination Category for this stream.

Returns:
The Category.

Definition at line 59 of file install/include/log4cpp/CategoryStream.hh.

Category& log4cpp::CategoryStream::getCategory (  )  const [inline]

Returns the destination Category for this stream.

Returns:
The Category.

Definition at line 59 of file include/log4cpp/CategoryStream.hh.

Priority::Value log4cpp::CategoryStream::getPriority (  )  const throw () [inline]

Returns the priority for this stream.

Returns:
The priority.

Definition at line 65 of file install/include/log4cpp/CategoryStream.hh.

Priority::Value log4cpp::CategoryStream::getPriority (  )  const throw () [inline]

Returns the priority for this stream.

Returns:
The priority.

Definition at line 65 of file include/log4cpp/CategoryStream.hh.

CategoryStream& log4cpp::CategoryStream::operator<< ( cspf   ) 
template<typename T >
CategoryStream& log4cpp::CategoryStream::operator<< ( const std::string &  t  )  [inline]

Definition at line 93 of file install/include/log4cpp/CategoryStream.hh.

template<typename T >
CategoryStream& log4cpp::CategoryStream::operator<< ( const T &  t  )  [inline]

Stream in arbitrary types and objects.

Parameters:
t The value or object to stream in.
Returns:
A reference to itself.

Definition at line 80 of file install/include/log4cpp/CategoryStream.hh.

CategoryStream & log4cpp::CategoryStream::operator<< ( cspf  pf  ) 

Definition at line 48 of file CategoryStream.cpp.

template<typename T >
CategoryStream& log4cpp::CategoryStream::operator<< ( const std::string &  t  )  [inline]

Definition at line 93 of file include/log4cpp/CategoryStream.hh.

template<typename T >
CategoryStream& log4cpp::CategoryStream::operator<< ( const T &  t  )  [inline]

Stream in arbitrary types and objects.

Parameters:
t The value or object to stream in.
Returns:
A reference to itself.

Definition at line 80 of file include/log4cpp/CategoryStream.hh.

std::streamsize log4cpp::CategoryStream::width ( std::streamsize  wide  ) 

Set the width output on CategoryStream

std::streamsize log4cpp::CategoryStream::width ( std::streamsize  wide  ) 

Set the width output on CategoryStream

Definition at line 38 of file CategoryStream.cpp.


Friends And Related Function Documentation

LOG4CPP_EXPORT friend CategoryStream& eol ( CategoryStream os  )  [friend]

eol manipulator

Definition at line 51 of file CategoryStream.cpp.

LOG4CPP_EXPORT friend CategoryStream& eol ( CategoryStream os  )  [friend]

eol manipulator

Definition at line 51 of file CategoryStream.cpp.

LOG4CPP_EXPORT friend CategoryStream& left ( CategoryStream os  )  [friend]

left manipulator

Definition at line 57 of file CategoryStream.cpp.

LOG4CPP_EXPORT friend CategoryStream& left ( CategoryStream os  )  [friend]

left manipulator

Definition at line 57 of file CategoryStream.cpp.


Member Data Documentation

union { ... } [private]
union { ... } [private]

Definition at line 128 of file include/log4cpp/CategoryStream.hh.

Definition at line 125 of file include/log4cpp/CategoryStream.hh.

Definition at line 126 of file include/log4cpp/CategoryStream.hh.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines


log4cpp
Author(s): Stephen Roderick
autogenerated on Fri Jan 11 09:51:54 2013