jenes.statistics
Class StatisticsLogger.LoggableStatistics

java.lang.Object
  extended by jenes.statistics.StatisticsLogger.LoggableStatistics
Direct Known Subclasses:
Population.Statistics
Enclosing class:
StatisticsLogger

public abstract static class StatisticsLogger.LoggableStatistics
extends java.lang.Object

This class provides the support for making a statistics loggable. It is simply required to make the own statistics class extending LoggableStatistics.

Author:
Luigi Troiano

Constructor Summary
protected StatisticsLogger.LoggableStatistics()
          Constructs a new LoggableStatistics, retriving the names of figures by reflection.
 
Method Summary
 java.util.Collection<java.lang.String> getFigures()
          Provides the collection of figures made available by the subclass instance.
 double getValue(java.lang.String figure)
          Returns the figure value.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StatisticsLogger.LoggableStatistics

protected StatisticsLogger.LoggableStatistics()
Constructs a new LoggableStatistics, retriving the names of figures by reflection.

Method Detail

getFigures

public final java.util.Collection<java.lang.String> getFigures()
Provides the collection of figures made available by the subclass instance.

Returns:
the collection of figures

getValue

public final double getValue(java.lang.String figure)
Returns the figure value.

Parameters:
figure - - the figure to retrieve
Returns:
the value if the figure exists, Double.NaN otherwise