ehcache

net.sf.ehcache.statistics.extended
Class RatioStatistic

java.lang.Object
  extended by net.sf.ehcache.statistics.extended.RatioStatistic
All Implemented Interfaces:
ExtendedStatistics.Statistic<Double>

public class RatioStatistic
extends Object

The Class RatioStatistic.

Author:
cdennis

Constructor Summary
RatioStatistic(ExtendedStatistics.Statistic<? extends Number> numerator, ExtendedStatistics.Statistic<? extends Number> denominator, ScheduledExecutorService executor, int historySize, long historyNanos)
          Instantiates a new ratio statistic.
 
Method Summary
 boolean active()
          Active.
 List<org.terracotta.statistics.archive.Timestamped<T>> history()
          History.
 Double value()
          Value.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RatioStatistic

public RatioStatistic(ExtendedStatistics.Statistic<? extends Number> numerator,
                      ExtendedStatistics.Statistic<? extends Number> denominator,
                      ScheduledExecutorService executor,
                      int historySize,
                      long historyNanos)
Instantiates a new ratio statistic.

Parameters:
numerator - the numerator
denominator - the denominator
executor - the executor
historySize - the history size
historyNanos - the history nanos
Method Detail

value

public Double value()
Description copied from interface: ExtendedStatistics.Statistic
Value.

Specified by:
value in interface ExtendedStatistics.Statistic<Double>
Returns:
the t

active

public final boolean active()
Description copied from interface: ExtendedStatistics.Statistic
Active.

Specified by:
active in interface ExtendedStatistics.Statistic<T extends Number>
Returns:
true, if successful

history

public final List<org.terracotta.statistics.archive.Timestamped<T>> history()
Description copied from interface: ExtendedStatistics.Statistic
History.

Specified by:
history in interface ExtendedStatistics.Statistic<T extends Number>
Returns:
the list

ehcache

Copyright © 2003-2013 Terracotta, Inc.. All Rights Reserved.