org.databene.benerator.wrapper
Class ValidatingGeneratorProxy<E>
java.lang.Object
org.databene.benerator.util.AbstractGenerator<P>
org.databene.benerator.util.ValidatingGenerator<E>
org.databene.benerator.wrapper.ValidatingGeneratorProxy<E>
- All Implemented Interfaces:
- java.io.Closeable, Generator<E>, org.databene.commons.Resettable, org.databene.commons.ThreadAware
public class ValidatingGeneratorProxy<E>
- extends ValidatingGenerator<E>
Generator proxy that uses another generator for creating values and filters out invalid ones.
Created: 29.08.2006 08:27:11
- See Also:
ValidatingGenerator
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
ValidatingGeneratorProxy
public ValidatingGeneratorProxy(Generator<E> source,
org.databene.commons.Validator<E> validator)
- Constructor with the source generator and the validator to use
getGeneratedType
public java.lang.Class<E> getGeneratedType()
- Description copied from interface:
Generator
- Declares the type of the objects returned by the generate() method.
doGenerate
protected ProductWrapper<E> doGenerate(ProductWrapper<E> wrapper)
- Callback method implementation from ValidatingGenerator.
This calls the source's generate() method and returns its result.
- Specified by:
doGenerate
in class ValidatingGenerator<E>
init
public void init(GeneratorContext context)
- Specified by:
init
in interface Generator<E>
- Overrides:
init
in class AbstractGenerator<E>
reset
public void reset()
- Calls the reset() method on the source generator
- Specified by:
reset
in interface org.databene.commons.Resettable
- Overrides:
reset
in class AbstractGenerator<E>
close
public void close()
- Calls the close() method on the source generator
- Specified by:
close
in interface java.io.Closeable
- Specified by:
close
in interface Generator<E>
- Overrides:
close
in class AbstractGenerator<E>
isThreadSafe
public boolean isThreadSafe()
isParallelizable
public boolean isParallelizable()
toString
public java.lang.String toString()
- Overrides:
toString
in class AbstractGenerator<E>
Copyright © 2013. All Rights Reserved.