|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.databene.benerator.util.AbstractGenerator<P>
org.databene.benerator.wrapper.MultiGeneratorWrapper<S,S[]>
org.databene.benerator.wrapper.SimpleMultiSourceArrayGenerator<S>
public class SimpleMultiSourceArrayGenerator<S>
Keeps an array of generators, of which it combines the products to an array.
Created: 26.08.2006 09:37:55
Field Summary |
---|
Fields inherited from class org.databene.benerator.wrapper.MultiGeneratorWrapper |
---|
generatedType, sources |
Fields inherited from class org.databene.benerator.util.AbstractGenerator |
---|
context, logger, state |
Constructor Summary | |
---|---|
SimpleMultiSourceArrayGenerator(java.lang.Class<S> componentType,
Generator<? extends S>... sources)
Initializes the generator to an array of source generators |
Method Summary | |
---|---|
void |
close()
Closes the generator. |
ProductWrapper<S[]> |
generate(ProductWrapper<S[]> wrapper)
Returns an instance of the generic type E, using the ProductWrapper
instance provided as argument. |
void |
reset()
|
Methods inherited from class org.databene.benerator.wrapper.MultiGeneratorWrapper |
---|
addSource, availableSourceCount, generateFromAllSources, generateFromAvailableSource, generateFromRandomSource, generateFromSource, getAvailableSource, getGeneratedType, getSource, getSources, getSourceWrapper, init, isParallelizable, isThreadSafe, setSources, toString |
Methods inherited from class org.databene.benerator.util.AbstractGenerator |
---|
assertInitialized, assertNotInitialized, getResultWrapper, wasInitialized |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public SimpleMultiSourceArrayGenerator(java.lang.Class<S> componentType, Generator<? extends S>... sources)
Method Detail |
---|
public ProductWrapper<S[]> generate(ProductWrapper<S[]> wrapper)
Generator
ProductWrapper
instance provided as argument.
The wrapper may wrap a null value as a regular generator product.
If the generator is not available (any more), it returns null instead of
the ProductWrapper instance.
public void reset()
reset
in interface org.databene.commons.Resettable
reset
in class MultiGeneratorWrapper<S,S[]>
public void close()
Generator
close
in interface java.io.Closeable
close
in interface Generator<S[]>
close
in class MultiGeneratorWrapper<S,S[]>
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |