|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectrafa.math.gen.ConstantStrategy
public class ConstantStrategy
This engine returns a constant value.
| Constructor Summary | |
|---|---|
ConstantStrategy(java.lang.Number value)
Default constructor. |
|
| Method Summary | |
|---|---|
java.util.List<? extends java.lang.Number> |
generate(int index)
Generates new numbers. |
java.lang.Number |
getValue()
|
void |
reset()
Resets the strategy to its initial state. |
void |
setValue(java.lang.Number value)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ConstantStrategy(java.lang.Number value)
value - | Method Detail |
|---|
public java.util.List<? extends java.lang.Number> generate(int index)
throws java.lang.Exception
GeneratorStrategy
generate in interface GeneratorStrategyindex - the index of the value within the strategy output. Note that
it can be ignored by the implementation, if not needed.
null if none was generated.
java.lang.Exceptionpublic java.lang.Number getValue()
public void setValue(java.lang.Number value)
value - public void reset()
GeneratorStrategy
reset in interface GeneratorStrategy
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||