java.lang.Object
com.pervasive.datarush.monitoring.StatisticDefinition<CounterSupplier>
com.pervasive.datarush.monitoring.CounterDefinition
- All Implemented Interfaces:
Serializable
Definition associated with a
CounterSupplier. Counters may aggregate
by either CounterAggregator.SUM, CounterAggregator.MIN, or
CounterAggregator.MAX.- See Also:
-
Field Summary
Fields inherited from class com.pervasive.datarush.monitoring.StatisticDefinition
CATEGORY_GENERAL, CATEGORY_IO -
Constructor Summary
ConstructorsConstructorDescriptionCounterDefinition(String id, String displayName) Creates a definition with default values. -
Method Summary
Modifier and TypeMethodDescriptionaggregate(List<? extends StatisticSupplier> values) Performs aggregation across statistics.Returns the aggregator to use for counter aggregation.aggregator(CounterAggregator aggregator) Sets the aggregator to use for aggregationcast(StatisticSupplier value) Casts theStatisticSupplierto this definition, substituting a default value for null.Sets the categorydoFinalSnapshot(StatisticSupplier supplier) nonPartitioned(boolean nonPartitioned) Indicates that this statistic refers to a concept that is inherently non-parallel.Returns a shortened name that can be used in some ui display contexts.Sets a shortened name that can be used in some ui display contexts.Returns the unit of measure.unitOfMeasure(UnitOfMeasure unitOfMeasure) Sets the unit of measure.Methods inherited from class com.pervasive.datarush.monitoring.StatisticDefinition
category, cpuTime, displayName, duration, equals, finalSnapshot, hashCode, id, ioBytes, ioCount, nonPartitioned, toString
-
Constructor Details
-
CounterDefinition
Creates a definition with default values. This definition aggregates byCounterAggregator.SUMand an unspecified unit of measure.- Parameters:
id- the id for the statisticdisplayName- the display name of this statistic
-
-
Method Details
-
aggregator
Returns the aggregator to use for counter aggregation.- Returns:
- the aggregator to use for counter aggregation.
-
unitOfMeasure
Returns the unit of measure.- Returns:
- the unit of measure.
-
shortName
Returns a shortened name that can be used in some ui display contexts. By default this is the same asStatisticDefinition.displayName().- Returns:
- a short name
-
category
Description copied from class:StatisticDefinitionSets the category- Specified by:
categoryin classStatisticDefinition<CounterSupplier>- Parameters:
category- the category- Returns:
- a newly-created
StatisticDefinition.
-
unitOfMeasure
Sets the unit of measure.- Parameters:
unitOfMeasure- the unit of measure- Returns:
- a newly-created
CounterStatisticDefinition.
-
shortName
Sets a shortened name that can be used in some ui display contexts. By default this is the same asStatisticDefinition.displayName().- Parameters:
shortName- a short name- Returns:
- a newly-created
CounterStatisticDefinition.
-
aggregator
Sets the aggregator to use for aggregation- Parameters:
aggregator- the aggregator- Returns:
- a newly-created
CounterStatisticDefinition.
-
aggregate
Description copied from class:StatisticDefinitionPerforms aggregation across statistics. Statistics will be aggregated in a manner specific to the concrete definition.- Specified by:
aggregatein classStatisticDefinition<CounterSupplier>- Parameters:
values- the values to aggregate- Returns:
- the aggregated value
-
doFinalSnapshot
-
cast
Description copied from class:StatisticDefinitionCasts theStatisticSupplierto this definition, substituting a default value for null.- Specified by:
castin classStatisticDefinition<CounterSupplier>- Parameters:
value- the value- Returns:
- a casted value or default if null.
-
nonPartitioned
Description copied from class:StatisticDefinitionIndicates that this statistic refers to a concept that is inherently non-parallel. An example would be planning statistics.- Specified by:
nonPartitionedin classStatisticDefinition<CounterSupplier>- Parameters:
nonPartitioned- whether this statistic refers to a non-partitioned concept- Returns:
- a newly-created
StatisticDefinition.
-