rafa.math.gen
Interface GeneratorStrategy

All Known Implementing Classes:
ConstantStrategy, DiscontinuousFunctionStrategy, FilterStrategy, FunctionStrategy, RandomStrategy, SerialStrategy

public interface GeneratorStrategy

The strategy used by a generator to produce values.

Author:
rafa

Method Summary
 java.util.List<? extends java.lang.Number> generate(int index)
          Generates new numbers.
 void reset()
          Resets the strategy to its initial state.
 

Method Detail

generate

java.util.List<? extends java.lang.Number> generate(int index)
                                                    throws java.lang.Exception
Generates new numbers.

Parameters:
index - the index of the value within the strategy output. Note that it can be ignored by the implementation, if not needed.
Returns:
A list of numbers, or null if none was generated.
Throws:
java.lang.Exception

reset

void reset()
Resets the strategy to its initial state.



Copyright © 2008-2009. All Rights Reserved.