C# Class Icing.Diagnostics.Stats

Calculates and formats running totals, averages, etc, for an arbitrary statistic.
显示文件 Open project: benallred/Icing Class Usage Examples

Public Methods

Method Description
Report ( double current ) : void

Adds the current value to the statistics.

ReportAndGetSummary ( double current ) : string

Adds the current value to the statistics and returns a summary of the current state.

Stats ( int expectedIterations, Formatter formatter, Formatter averageFormatter )

Initializes a new instance of the Stats class.

ToString ( ) : string

Returns a string that represents the current object.

Method Details

Report() public method

Adds the current value to the statistics.
public Report ( double current ) : void
current double The current value.
return void

ReportAndGetSummary() public method

Adds the current value to the statistics and returns a summary of the current state.
public ReportAndGetSummary ( double current ) : string
current double The current value.
return string

Stats() public method

Initializes a new instance of the Stats class.
public Stats ( int expectedIterations, Formatter formatter, Formatter averageFormatter )
expectedIterations int The number of expected iterations.
formatter Formatter The value formatter.
averageFormatter Formatter The average value formatter.

ToString() public method

Returns a string that represents the current object.
public ToString ( ) : string
return string