C++ Reference: class Stat

This documentation is automatically generated.

Base class for a statistic that can be pretty-printed.
Method
Name

Return type: std::string

Only used for display purposes.

Priority

Return type: virtual int

At display, stats are displayed by decreasing priority, then decreasing Sum(), then alphabetical order. Used to group the stats per category (timing, ratio, etc..,).

Reset

Return type: virtual void

Reset this statistic to the same state as if it was newly created.

Stat

Return type: explicit

Arguments: const std::string& name

Stat

Arguments: const std::string& name, StatsGroup* group

Also add this stat to the given group.

~Stat

Return type: virtual

StatString

Return type: std::string

Returns a human-readable formatted line of the form "name: ValueAsString()".

Sum

Return type: virtual double

By default return 0 for the sum. This makes it possible to sort stats by decreasing total time.

ValueAsString

Return type: virtual std::string

Prints information about this statistic.

WorthPrinting

Return type: virtual bool

Is this stat worth printing? Usually false if nothing was measured.

Send feedback about...