pion::plugins::LogOutputReactor Class Reference

#include <LogOutputReactor.hpp>

Inherits pion::platform::Reactor.

List of all members.


Detailed Description

LogOutputReactor: creates log files that are populated with events

Definition at line 39 of file LogOutputReactor.hpp.

Public Member Functions

 LogOutputReactor (void)
 constructs a new LogOutputReactor object
virtual ~LogOutputReactor ()
 virtual destructor: this class is meant to be extended
virtual void setConfig (const pion::platform::Vocabulary &v, const xmlNodePtr config_ptr)
virtual void updateVocabulary (const pion::platform::Vocabulary &v)
virtual void updateCodecs (void)
virtual void process (const pion::platform::EventPtr &e)
virtual void query (std::ostream &out, const QueryBranches &branches, const QueryParams &qp)
virtual void start (void)
 called by the ReactorEngine to start Event processing
virtual void stop (void)
 called by the ReactorEngine to stop Event processing
void setLogger (PionLogger log_ptr)
 sets the logger to be used
PionLogger getLogger (void)
 returns the logger currently in use

Classes

class  EmptyCodecException
 exception thrown if the Reactor configuration does not define a Codec More...
class  EmptyFilenameException
 exception thrown if the Reactor configuration does not define a Filename More...
class  LogRotationException
 exception thrown if the Reactor is unable to rotate the log file More...
class  OpenLogException
 exception thrown if the Reactor is unable to open a log file for writing More...
class  WriteToLogException
 exception thrown if the Reactor is unable to write an Event to the log file More...


Member Function Documentation

void pion::plugins::LogOutputReactor::process ( const pion::platform::EventPtr e  )  [virtual]

processes an Event by writing it to a log file

Parameters:
e pointer to the Event to process

Reimplemented from pion::platform::Reactor.

Definition at line 97 of file LogOutputReactor.cpp.

References pion::platform::Reactor::deliverEvent().

void pion::plugins::LogOutputReactor::query ( std::ostream &  out,
const QueryBranches branches,
const QueryParams qp 
) [virtual]

handle an HTTP query (from QueryService)

Parameters:
out the ostream to write the statistics info into
branches URI stem path branches for the HTTP request
qp query parameters or pairs passed in the HTTP request

Definition at line 121 of file LogOutputReactor.cpp.

References pion::platform::Reactor::ConfigWriteLock, pion::platform::Reactor::isRunning(), and pion::PionTimeFacet::toString().

void pion::plugins::LogOutputReactor::setConfig ( const pion::platform::Vocabulary v,
const xmlNodePtr  config_ptr 
) [virtual]

sets configuration parameters for this Reactor

Parameters:
v the Vocabulary that this Reactor will use to describe Terms
config_ptr pointer to a list of XML nodes containing Reactor configuration parameters

Reimplemented from pion::platform::Reactor.

Definition at line 42 of file LogOutputReactor.cpp.

References pion::platform::Reactor::ConfigWriteLock, pion::platform::CodecFactory::getCodec(), pion::platform::PlatformPlugin::getCodecFactory(), pion::platform::PlatformPlugin::getId(), pion::platform::PlatformPlugin::getReactionEngine(), pion::platform::Reactor::m_is_running, and pion::platform::ConfigManager::resolveRelativeDataPath().

void pion::plugins::LogOutputReactor::updateCodecs ( void   )  [virtual]

this updates the Codecs that are used by this Reactor; it should be called whenever any Codec's configuration is updated

Reimplemented from pion::platform::Reactor.

Definition at line 84 of file LogOutputReactor.cpp.

References pion::platform::Reactor::ConfigWriteLock, pion::platform::CodecFactory::getCodec(), pion::platform::PlatformPlugin::getCodecFactory(), and stop().

void pion::plugins::LogOutputReactor::updateVocabulary ( const pion::platform::Vocabulary v  )  [virtual]

this updates the Vocabulary information used by this Reactor; it should be called whenever the global Vocabulary is updated

Parameters:
v the Vocabulary that this Reactor will use to describe Terms

Reimplemented from pion::platform::Reactor.

Definition at line 75 of file LogOutputReactor.cpp.

References pion::platform::Reactor::ConfigWriteLock.


The documentation for this class was generated from the following files:
Generated on Wed Apr 13 16:38:36 2011 for pion-platform by  doxygen 1.4.7