Page Speed Optimization Libraries  1.13.35.1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Protected Member Functions | List of all members
net_instaweb::SplitStatistics Class Reference
Inheritance diagram for net_instaweb::SplitStatistics:
net_instaweb::StatisticsTemplate< SplitVariable, SplitUpDownCounter, SplitHistogram, SplitTimedVariable > net_instaweb::Statistics

Public Member Functions

 SplitStatistics (ThreadSystem *thread_system, Statistics *local, Statistics *global)
 
virtual StatisticsLoggerconsole_logger ()
 
- Public Member Functions inherited from net_instaweb::StatisticsTemplate< SplitVariable, SplitUpDownCounter, SplitHistogram, SplitTimedVariable >
virtual SplitVariableAddVariable (const StringPiece &name)
 
virtual SplitUpDownCounterAddUpDownCounter (const StringPiece &name)
 
virtual SplitUpDownCounterAddGlobalUpDownCounter (const StringPiece &name)
 
virtual SplitVariableFindVariable (const StringPiece &name) const
 Find a variable from a name, returning NULL if not found.
 
virtual SplitUpDownCounterFindUpDownCounter (const StringPiece &name) const
 Find a variable from a name, returning NULL if not found.
 
virtual SplitHistogramAddHistogram (const StringPiece &name)
 
virtual SplitHistogramFindHistogram (const StringPiece &name) const
 Find a histogram from a name, returning NULL if not found.
 
virtual SplitTimedVariableAddTimedVariable (const StringPiece &name, const StringPiece &group)
 
virtual SplitTimedVariableFindTimedVariable (const StringPiece &name) const
 Find a TimedVariable from a name, returning NULL if not found.
 
virtual const StringVector & HistogramNames ()
 Return the names of all the histograms for render.
 
virtual const std::map
< GoogleString, StringVector > & 
TimedVariableMap ()
 Return the map of groupnames and names of all timedvariables for render.
 
virtual void Dump (Writer *writer, MessageHandler *message_handler)
 Dump the variable-values to a writer.
 
virtual void DumpJson (Writer *writer, MessageHandler *message_handler)
 
virtual void Clear ()
 
- Public Member Functions inherited from net_instaweb::Statistics
UpDownCounterGetUpDownCounter (const StringPiece &name) const
 Find a variable from a name, aborting if not found.
 
VariableGetVariable (const StringPiece &name) const
 Find a variable from a name, aborting if not found.
 
HistogramGetHistogram (const StringPiece &name) const
 Find a histogram from a name, aborting if not found.
 
TimedVariableGetTimedVariable (const StringPiece &name) const
 Find a TimedVariable from a name, aborting if not found.
 
virtual void RenderTimedVariables (Writer *writer, MessageHandler *handler)
 
virtual void RenderHistograms (Writer *writer, MessageHandler *handler)
 Write all the histograms in this Statistic object to a writer.
 
int64 LookupValue (StringPiece stat_name)
 

Protected Member Functions

virtual SplitUpDownCounterNewUpDownCounter (StringPiece name)
 Interface to subclass.
 
virtual SplitVariableNewVariable (StringPiece name)
 Interface to subclass.
 
virtual SplitUpDownCounterNewGlobalUpDownCounter (StringPiece name)
 Default implementation just calls NewUpDownCounter.
 
virtual SplitHistogramNewHistogram (StringPiece name)
 
virtual SplitTimedVariableNewTimedVariable (StringPiece name)
 
- Protected Member Functions inherited from net_instaweb::StatisticsTemplate< SplitVariable, SplitUpDownCounter, SplitHistogram, SplitTimedVariable >
size_t variables_size () const
 
SplitVariablevariables (size_t pos)
 
size_t up_down_size () const
 
SplitUpDownCounterup_downs (size_t pos)
 
size_t histograms_size () const
 
SplitHistogramhistograms (size_t pos)
 
const GoogleStringhistogram_names (size_t pos) const
 

Additional Inherited Members

- Static Public Attributes inherited from net_instaweb::Statistics
static const char kDefaultGroup []
 Default group for use with AddTimedVariable.
 

Constructor & Destructor Documentation

net_instaweb::SplitStatistics::SplitStatistics ( ThreadSystem thread_system,
Statistics local,
Statistics global 
)

Initializes a statistics splitter which proxies 'local' but also forwards writes to 'global' for aggregation with other SplitStatistics instances. Takes ownership of 'local', but not thread_system or global.

Note that before AddUpDownCounter or similar methods are invoked on this object (which is usually done by static ::InitStats(Statistics* methods) they must have been invoked on both local and global statistics objects for the same object names.

Member Function Documentation

virtual StatisticsLogger* net_instaweb::SplitStatistics::console_logger ( )
inlinevirtual

This is implemented as NULL here because most Statistics don't need it. In the context in which it is needed we only have access to a Statistics*, rather than the specific subclass, hence its being here. Return the StatisticsLogger associated with this Statistics.

console_logger() is only used for read access, so just provide the local version.

Reimplemented from net_instaweb::Statistics.


The documentation for this class was generated from the following file: