Class BaseStatistic
java.lang.Object
com.arpnetworking.metrics.mad.model.statistics.BaseStatistic
- All Implemented Interfaces:
Statistic
,Serializable
- Direct Known Subclasses:
CountStatistic
,ExpressionStatistic
,HistogramStatistic
,MaxStatistic
,MeanStatistic
,MinStatistic
,SumStatistic
,TPStatistic
A statistic base class.
- Author:
- Brandon Arp (brandon dot arp at inscopemetrics dot io)
- See Also:
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected static void
assertUnit
(Optional<Unit> newUnit, Optional<Unit> existingUnit, boolean hasData) Assert that the new unit is compatible with the existing unit.boolean
Accessor for any aliases of the statistic.Accessor for any dependencies.int
hashCode()
toString()
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface com.arpnetworking.metrics.mad.model.statistics.Statistic
createCalculator, getName
-
Constructor Details
-
BaseStatistic
public BaseStatistic()
-
-
Method Details
-
getAliases
Description copied from interface:Statistic
Accessor for any aliases of the statistic.- Specified by:
getAliases
in interfaceStatistic
- Returns:
- The aliases of the statistic.
-
getDependencies
Description copied from interface:Statistic
Accessor for any dependencies.- Specified by:
getDependencies
in interfaceStatistic
- Returns:
- The
Set
ofStatistic
dependencies.
-
hashCode
public int hashCode() -
equals
-
toString
-
assertUnit
protected static void assertUnit(Optional<Unit> newUnit, Optional<Unit> existingUnit, boolean hasData) Assert that the new unit is compatible with the existing unit.- Parameters:
newUnit
- the new unit under considerationexistingUnit
- the unit encountered previouslyhasData
- whether data has been processed
-