A record that calculates the min, max, and average from integer samples. More...
Instance Methods | |
(void) | - addSampleWithLongSample: |
Adds a new sample to the calculation. More... | |
(double) | - average |
Gets the average of all samples. More... | |
(long long) | - count |
Gets how many samples this record has used. More... | |
(instancetype) | - init |
Creates a new instance of the DiagnosticRecord. More... | |
(instancetype) | - initWithAverageSampleCount: |
Creates a new instance of the DiagnosticRecord. More... | |
(instancetype) | - initWithAverageSampleCount:label: |
Creates a new instance of the DiagnosticRecord. More... | |
(instancetype) | - initWithLabel: |
Creates a new instance of the DiagnosticRecord. More... | |
(NSString *) | - label |
Gets the label for this sampler. More... | |
(long long) | - lastValue |
Gets the value of the last sample recorded. More... | |
(long long) | - max |
Gets the maximum sample ever recorded. More... | |
(long long) | - min |
Gets the minimum sample ever recorded. More... | |
(int) | - samplesInAverage |
Gets how many samples are included in the average. More... | |
(long long) | - sum |
Gets the sum of all values. More... | |
Class Methods | |
(FMLiveSwitchDiagnosticSampler *) | + diagnosticSampler |
Creates a new instance of the DiagnosticRecord. More... | |
(FMLiveSwitchDiagnosticSampler *) | + diagnosticSamplerWithAverageSampleCount: |
Creates a new instance of the DiagnosticRecord. More... | |
(FMLiveSwitchDiagnosticSampler *) | + diagnosticSamplerWithAverageSampleCount:label: |
Creates a new instance of the DiagnosticRecord. More... | |
(FMLiveSwitchDiagnosticSampler *) | + diagnosticSamplerWithLabel: |
Creates a new instance of the DiagnosticRecord. More... | |
A record that calculates the min, max, and average from integer samples.
- (void) addSampleWithLongSample: | (long long) | longSample |
Adds a new sample to the calculation.
longSample | The sample to add. |
- (double) average |
Gets the average of all samples.
- (long long) count |
Gets how many samples this record has used.
+ (FMLiveSwitchDiagnosticSampler*) diagnosticSampler |
Creates a new instance of the DiagnosticRecord.
+ (FMLiveSwitchDiagnosticSampler*) diagnosticSamplerWithAverageSampleCount: | (int) | averageSampleCount |
Creates a new instance of the DiagnosticRecord.
averageSampleCount | How many samples to include in the average. |
+ (FMLiveSwitchDiagnosticSampler*) diagnosticSamplerWithAverageSampleCount: | (int) | averageSampleCount | |
label: | (NSString *) | label | |
Creates a new instance of the DiagnosticRecord.
averageSampleCount | How many samples to include in the average. |
label | The label for this sampler. |
+ (FMLiveSwitchDiagnosticSampler*) diagnosticSamplerWithLabel: | (NSString *) | label |
Creates a new instance of the DiagnosticRecord.
label | The label for this sampler. |
- (instancetype) init |
Creates a new instance of the DiagnosticRecord.
- (instancetype) initWithAverageSampleCount: | (int) | averageSampleCount |
Creates a new instance of the DiagnosticRecord.
averageSampleCount | How many samples to include in the average. |
- (instancetype) initWithAverageSampleCount: | (int) | averageSampleCount | |
label: | (NSString *) | label | |
Creates a new instance of the DiagnosticRecord.
averageSampleCount | How many samples to include in the average. |
label | The label for this sampler. |
- (instancetype) initWithLabel: | (NSString *) | label |
Creates a new instance of the DiagnosticRecord.
label | The label for this sampler. |
- (NSString*) label |
Gets the label for this sampler.
- (long long) lastValue |
Gets the value of the last sample recorded.
- (long long) max |
Gets the maximum sample ever recorded.
- (long long) min |
Gets the minimum sample ever recorded.
- (int) samplesInAverage |
Gets how many samples are included in the average.
- (long long) sum |
Gets the sum of all values.