|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.speckled.specksim.statistics.StatisticsModule
public abstract class StatisticsModule
The abstract superclass for statistics modules. Implementors need only concern themselves with generating and naming the statistics.
| Field Summary | |
|---|---|
static int |
DEFAULT_HISTORY
The default history length |
| Constructor Summary | |
|---|---|
StatisticsModule()
|
|
| Method Summary | |
|---|---|
protected abstract float[] |
generateStatistics(StateSink state)
Generate a statistics set for the supplied state. |
float[][] |
getHistory()
Gets the history of this module |
int |
getHistoryLength()
Gets the history length of this module |
float[] |
getHistoryTimes()
Gets the simulator times at which each historical record was generated. |
abstract java.lang.String |
getName()
Gets a name for this module |
java.lang.String[] |
getStatisticDescriptions()
Gets descriptions for each of the statistics generated by this module |
java.lang.String[] |
getStatisticNames()
Gets the names of the statistics in this module |
float[] |
getStatistics()
Gets the statistics |
protected boolean |
isIncluded(int index)
Subclasses should use this method, instead of state.isIncluded( index ). |
void |
setHistoryLength(int length)
Sets the history length of this StatisticModule |
protected java.lang.String[] |
statisticDescriptions()
Override this method to return an array of descriptive Strings for the statistics calculated by this
StatisticsModule. |
protected abstract java.lang.String[] |
statisticNames()
Get the names of the statistics that will be generated by this module |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int DEFAULT_HISTORY
| Constructor Detail |
|---|
public StatisticsModule()
| Method Detail |
|---|
public final java.lang.String[] getStatisticNames()
public final java.lang.String[] getStatisticDescriptions()
public final float[] getStatistics()
public final float[][] getHistory()
public final float[] getHistoryTimes()
public final void setHistoryLength(int length)
length - The new length of the historypublic final int getHistoryLength()
protected final boolean isIncluded(int index)
index - The index of the speck element to query
public abstract java.lang.String getName()
protected abstract float[] generateStatistics(StateSink state)
state - The Simulator state on which to operate
protected abstract java.lang.String[] statisticNames()
protected java.lang.String[] statisticDescriptions()
Strings for the statistics calculated by this
StatisticsModule.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||