StatsTarget Class Reference

StatsTarget defines an interface implemented by classes which consume performance/activity statistics. More...

#include <StatsTarget.h>

Inheritance diagram for StatsTarget:

FileStatsTarget JavaTraceTarget List of all members.

Public Member Functions

virtual ~StatsTarget ()
virtual void onThreadStart ()
 Receives notification that stats polling is starting via a TimerThread.
virtual void onThreadEnd ()
 Receives notification that stats polling via a TimerThread is ending.
virtual void beginSnapshot ()=0
 Begins recording a snapshot.
virtual void endSnapshot ()=0
 Finishes recording a snapshot.
virtual void writeCounter (std::string name, int64_t value)=0
 Writes one int counter.

Detailed Description

StatsTarget defines an interface implemented by classes which consume performance/activity statistics.

Definition at line 33 of file StatsTarget.h.


Constructor & Destructor Documentation

StatsTarget::~StatsTarget (  )  [virtual]

Definition at line 66 of file FileStatsTarget.cpp.

00067 {
00068 }


Member Function Documentation

void StatsTarget::onThreadStart (  )  [virtual]

Receives notification that stats polling is starting via a TimerThread.

Reimplemented in JavaTraceTarget.

Definition at line 111 of file StatsTimer.cpp.

Referenced by StatsTimer::onThreadStart().

00112 {
00113     // by default do nothing
00114 }

void StatsTarget::onThreadEnd (  )  [virtual]

Receives notification that stats polling via a TimerThread is ending.

Reimplemented in JavaTraceTarget.

Definition at line 116 of file StatsTimer.cpp.

Referenced by StatsTimer::onThreadEnd().

00117 {
00118     // by default do nothing
00119 }

virtual void StatsTarget::beginSnapshot (  )  [pure virtual]

Begins recording a snapshot.

Called before all writeCounter invocations for the snapshot.

Implemented in FileStatsTarget, and JavaTraceTarget.

Referenced by StatsTimer::onTimerInterval(), and StatsTimer::stop().

virtual void StatsTarget::endSnapshot (  )  [pure virtual]

Finishes recording a snapshot.

Called after all writeCounter invocations for the snapshot.

Implemented in FileStatsTarget, and JavaTraceTarget.

Referenced by StatsTimer::onTimerInterval(), and StatsTimer::stop().

virtual void StatsTarget::writeCounter ( std::string  name,
int64_t  value 
) [pure virtual]

Writes one int counter.

This is called from a StatsSource implementation in response to writeStats().

Parameters:
name name of counter
value snapshot value

Implemented in FileStatsTarget, and JavaTraceTarget.

Referenced by ExecStreamGovernor::writeStats(), Database::writeStats(), and Cache::writeStats().


The documentation for this class was generated from the following files:
Generated on Mon Jun 22 04:00:47 2009 for Fennel by  doxygen 1.5.1