org.databene.benerator.distribution.sequence
Class PredefinedSequenceGenerator<E extends java.lang.Number>

java.lang.Object
  extended by org.databene.benerator.util.AbstractGenerator<E>
      extended by org.databene.benerator.util.ThreadSafeGenerator<E>
          extended by org.databene.benerator.distribution.sequence.PredefinedSequenceGenerator<E>
All Implemented Interfaces:
java.io.Closeable, Generator<E>, org.databene.commons.Resettable, org.databene.commons.ThreadAware

public class PredefinedSequenceGenerator<E extends java.lang.Number>
extends ThreadSafeGenerator<E>

Generator class for use by the LiteralSequence.

Created: 03.06.2010 08:48:44

Since:
0.6.3
Author:
Volker Bergmann

Field Summary
 
Fields inherited from class org.databene.benerator.util.AbstractGenerator
context, state
 
Constructor Summary
PredefinedSequenceGenerator(E... numbers)
           
 
Method Summary
 E generate()
          Returns an instance of the generic type E.
 java.lang.Class<E> getGeneratedType()
          Declares the type of the objects returned by the generate() method.
 void reset()
           
 
Methods inherited from class org.databene.benerator.util.ThreadSafeGenerator
isParallelizable, isThreadSafe
 
Methods inherited from class org.databene.benerator.util.AbstractGenerator
assertInitialized, assertNotInitialized, close, init, toString, wasInitialized
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

PredefinedSequenceGenerator

public PredefinedSequenceGenerator(E... numbers)
Method Detail

getGeneratedType

public java.lang.Class<E> getGeneratedType()
Description copied from interface: Generator
Declares the type of the objects returned by the generate() method.


generate

public E generate()
Description copied from interface: Generator
Returns an instance of the generic type E.


reset

public void reset()
Specified by:
reset in interface org.databene.commons.Resettable
Overrides:
reset in class AbstractGenerator<E extends java.lang.Number>


Copyright © 2011. All Rights Reserved.