org.databene.domain.address
Class AddressGenerator

java.lang.Object
  extended by org.databene.benerator.util.AbstractGenerator<E>
      extended by org.databene.benerator.wrapper.CompositeGenerator<Address>
          extended by org.databene.domain.address.AddressGenerator
All Implemented Interfaces:
java.io.Closeable, Generator<Address>, NonNullGenerator<Address>, org.databene.commons.Resettable, org.databene.commons.ThreadAware

public class AddressGenerator
extends CompositeGenerator<Address>
implements NonNullGenerator<Address>

Generates Address objects.

Created: 11.06.2006 08:07:40

Since:
0.1
Author:
Volker Bergmann

Field Summary
 
Fields inherited from class org.databene.benerator.wrapper.CompositeGenerator
components, generatedType
 
Fields inherited from class org.databene.benerator.util.AbstractGenerator
context, logger, state
 
Constructor Summary
AddressGenerator()
           
AddressGenerator(java.lang.String dataset)
           
 
Method Summary
 Address generate()
           
 ProductWrapper<Address> generate(ProductWrapper<Address> wrapper)
          Returns an instance of the generic type E, using the ProductWrapper instance provided as argument.
 void init(GeneratorContext context)
           
 void setCountry(Country country)
           
 void setDataset(java.lang.String dataset)
           
 java.lang.String toString()
           
 
Methods inherited from class org.databene.benerator.wrapper.CompositeGenerator
getGeneratedType, isParallelizable, isThreadSafe, registerComponent, registerComponent, registerComponents
 
Methods inherited from class org.databene.benerator.util.AbstractGenerator
assertInitialized, assertNotInitialized, close, getResultWrapper, reset, wasInitialized
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.databene.benerator.Generator
close, getGeneratedType, wasInitialized
 
Methods inherited from interface org.databene.commons.ThreadAware
isParallelizable, isThreadSafe
 
Methods inherited from interface org.databene.commons.Resettable
reset
 

Constructor Detail

AddressGenerator

public AddressGenerator()

AddressGenerator

public AddressGenerator(java.lang.String dataset)
Method Detail

setCountry

public void setCountry(Country country)

setDataset

public void setDataset(java.lang.String dataset)

init

public void init(GeneratorContext context)
Specified by:
init in interface Generator<Address>
Overrides:
init in class AbstractGenerator<Address>

generate

public ProductWrapper<Address> generate(ProductWrapper<Address> wrapper)
Description copied from interface: Generator
Returns an instance of the generic type E, using the 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.

Specified by:
generate in interface Generator<Address>

generate

public Address generate()
Specified by:
generate in interface NonNullGenerator<Address>

toString

public java.lang.String toString()
Overrides:
toString in class AbstractGenerator<Address>


Copyright © 2013. All Rights Reserved.