public class ZeroOperationStatistic<T extends Enum<T>> extends Object implements OperationStatistic<T>
| Constructor and Description |
|---|
ZeroOperationStatistic() |
| Modifier and Type | Method and Description |
|---|---|
void |
addDerivedStatistic(ChainedOperationObserver<? super T> derived)
Register the given
Observer to be called by this SourceStatistic |
void |
begin()
Called immediately prior to the operation beginning.
|
long |
count(T type)
Return the count of operations with the given type.
|
void |
end(T result)
Called immediately after the operation completes with no interesting parameters, and with the same thread the called {
OperationObserver.begin()} before. |
static <T extends Enum<T>> |
get() |
Collection<ChainedOperationObserver<? super T>> |
getDerivedStatistics()
Retrieve all registered statistics.
|
void |
removeDerivedStatistic(ChainedOperationObserver<? super T> derived)
Remove the given registered
Observer from this SourceStatistic. |
long |
sum() |
long |
sum(Set<T> types) |
Class<T> |
type() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitstatistic, statisticpublic static <T extends Enum<T>> OperationStatistic<T> get()
public long count(T type)
OperationStatisticcount in interface OperationStatistic<T extends Enum<T>>type - the result typepublic long sum(Set<T> types)
sum in interface OperationStatistic<T extends Enum<T>>public long sum()
sum in interface OperationStatistic<T extends Enum<T>>public void addDerivedStatistic(ChainedOperationObserver<? super T> derived)
SourceStatisticObserver to be called by this SourceStatisticaddDerivedStatistic in interface SourceStatistic<ChainedOperationObserver<? super T extends Enum<T>>>derived - statistic to be registeredpublic void removeDerivedStatistic(ChainedOperationObserver<? super T> derived)
SourceStatisticObserver from this SourceStatistic.removeDerivedStatistic in interface SourceStatistic<ChainedOperationObserver<? super T extends Enum<T>>>derived - statistic to be removedpublic Collection<ChainedOperationObserver<? super T>> getDerivedStatistics()
SourceStatisticgetDerivedStatistics in interface SourceStatistic<ChainedOperationObserver<? super T extends Enum<T>>>public void begin()
OperationObserverbegin in interface OperationObserver<T extends Enum<T>>public void end(T result)
OperationObserverOperationObserver.begin()} before.end in interface OperationObserver<T extends Enum<T>>result - the operation resultCopyright © 2018. All rights reserved.