|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.sf.beanlib.provider.replicator.ReplicatorTemplate net.sf.beanlib.provider.BeanTransformer
@NotThreadSafe public class BeanTransformer
Bean Transformer.
Nested Class Summary | |
---|---|
private static class |
BeanTransformer.Factory
Bean Transformer Factory. |
Field Summary | |
---|---|
private ArrayReplicatorSpi |
arrayReplicatable
|
private BeanPopulatorBaseConfig |
baseConfig
|
private BeanPopulatorSpi.Factory |
beanPopulatorFactory
|
private BeanReplicatorSpi |
beanReplicatable
|
private BlobReplicatorSpi |
blobReplicatable
|
private Map<Object,Object> |
clonedMap
|
private CollectionReplicatorSpi |
collectionReplicatable
|
private CustomBeanTransformerSpi |
customTransformer
Custom Transformer. |
private DateReplicatorSpi |
dateReplicatable
|
private static BeanTransformer.Factory |
factory
|
private ImmutableReplicatorSpi |
immutableReplicatable
|
private MapReplicatorSpi |
mapReplicatable
|
Fields inherited from class net.sf.beanlib.provider.replicator.ReplicatorTemplate |
---|
log |
Constructor Summary | |
---|---|
protected |
BeanTransformer(BeanPopulatorSpi.Factory beanPopulatorFactory)
|
Methods inherited from class net.sf.beanlib.provider.replicator.ReplicatorTemplate |
---|
chooseClass, createToInstance, createToInstance, createToInstanceWithComparator, getTargetCloned, newInstanceAsPrivileged, populateBean, putTargetCloned, replicate, replicate, replicateByBeanReplicatable |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private static final BeanTransformer.Factory factory
private final BeanPopulatorSpi.Factory beanPopulatorFactory
private Map<Object,Object> clonedMap
private BeanPopulatorBaseConfig baseConfig
private CustomBeanTransformerSpi customTransformer
private ImmutableReplicatorSpi immutableReplicatable
private CollectionReplicatorSpi collectionReplicatable
private MapReplicatorSpi mapReplicatable
private ArrayReplicatorSpi arrayReplicatable
private BlobReplicatorSpi blobReplicatable
private DateReplicatorSpi dateReplicatable
private BeanReplicatorSpi beanReplicatable
Constructor Detail |
---|
protected BeanTransformer(BeanPopulatorSpi.Factory beanPopulatorFactory)
Method Detail |
---|
public static BeanTransformer newBeanTransformer(BeanPopulatorSpi.Factory beanPopulatorFactory)
public static BeanTransformer newBeanTransformer()
BeanPopulator.factory
.
public BeanPopulatorSpi.Factory getBeanPopulatorSpiFactory()
getBeanPopulatorSpiFactory
in interface BeanTransformerSpi
public final void reset()
reset
in interface BeanTransformerSpi
public final <T> T transform(Object from, Class<T> toClass, PropertyInfo propertyInfo)
Transformable
transform
in interface Transformable
transform
in class ReplicatorTemplate
from
- the input object to be transformed.
If propertyInfo is non-null, the input object is a JavaBean property value.toClass
- the target class to be transformed to.propertyInfo
- If null, it means the in object is a root level object.
Otherwise, propertyInfo contains information about the input object
as a java bean property value to be transformed.
public final BeanTransformer initCustomTransformer(CustomBeanTransformerSpi.Factory customTransformer)
initCustomTransformer
in interface BeanTransformerSpi
public final BeanTransformer initBeanPopulatable(BeanPopulatable beanPopulatable)
BeanTransformerSpi
initBeanPopulatable
in interface BeanPopulatorBaseSpi
initBeanPopulatable
in interface BeanTransformerSpi
public final BeanTransformer initBeanSourceHandler(BeanSourceHandler beanSourceHandler)
BeanTransformerSpi
initBeanSourceHandler
in interface BeanPopulatorBaseSpi
initBeanSourceHandler
in interface BeanTransformerSpi
public final BeanTransformer initDebug(boolean debug)
BeanTransformerSpi
initDebug
in interface BeanPopulatorBaseSpi
initDebug
in interface BeanTransformerSpi
public final BeanTransformer initDetailedBeanPopulatable(DetailedBeanPopulatable detailedBeanPopulatable)
BeanTransformerSpi
initDetailedBeanPopulatable
in interface BeanPopulatorBaseSpi
initDetailedBeanPopulatable
in interface BeanTransformerSpi
public final BeanTransformer initReaderMethodFinder(BeanMethodFinder readerMethodFinder)
BeanTransformerSpi
initReaderMethodFinder
in interface BeanPopulatorBaseSpi
initReaderMethodFinder
in interface BeanTransformerSpi
public final BeanTransformer initSetterMethodCollector(BeanMethodCollector setterMethodCollector)
BeanTransformerSpi
initSetterMethodCollector
in interface BeanPopulatorBaseSpi
initSetterMethodCollector
in interface BeanTransformerSpi
public BeanTransformer initCollectionReplicatable(CollectionReplicatorSpi.Factory factory)
initCollectionReplicatable
in interface BeanTransformerSpi
public CollectionReplicatorSpi getCollectionReplicatable()
getCollectionReplicatable
in interface BeanTransformerSpi
public BeanTransformer initMapReplicatable(MapReplicatorSpi.Factory factory)
initMapReplicatable
in interface BeanTransformerSpi
public MapReplicatorSpi getMapReplicatable()
getMapReplicatable
in interface BeanTransformerSpi
public <K,V> Map<K,V> getClonedMap()
getClonedMap
in interface BeanTransformerSpi
public BeanTransformer initImmutableReplicatable(ImmutableReplicatorSpi.Factory immutableReplicatableFactory)
initImmutableReplicatable
in interface BeanTransformerSpi
public ImmutableReplicatorSpi getImmutableReplicatable()
getImmutableReplicatable
in interface BeanTransformerSpi
public BeanTransformer initArrayReplicatable(ArrayReplicatorSpi.Factory arrayReplicatableFactory)
initArrayReplicatable
in interface BeanTransformerSpi
public ArrayReplicatorSpi getArrayReplicatable()
getArrayReplicatable
in interface BeanTransformerSpi
public BeanTransformer initBlobReplicatable(BlobReplicatorSpi.Factory blobReplicatableFactory)
initBlobReplicatable
in interface BeanTransformerSpi
public BlobReplicatorSpi getBlobReplicatable()
getBlobReplicatable
in interface BeanTransformerSpi
public BeanTransformer initBeanReplicatable(BeanReplicatorSpi.Factory objectReplicatableFactory)
initBeanReplicatable
in interface BeanTransformerSpi
public BeanReplicatorSpi getBeanReplicatable()
getBeanReplicatable
in interface BeanTransformerSpi
public BeanTransformerSpi initDateReplicatable(DateReplicatorSpi.Factory dateReplicatableFactory)
initDateReplicatable
in interface BeanTransformerSpi
public DateReplicatorSpi getDateReplicatable()
getDateReplicatable
in interface BeanTransformerSpi
public BeanTransformer initBeanPopulationExceptionHandler(BeanPopulationExceptionHandler beanPopulationExceptionHandler)
BeanTransformerSpi
initBeanPopulationExceptionHandler
in interface BeanPopulatorBaseSpi
initBeanPopulationExceptionHandler
in interface BeanTransformerSpi
public BeanTransformerSpi initBeanPopulatorBaseConfig(BeanPopulatorBaseConfig baseConfig)
BeanTransformerSpi
initBeanPopulatorBaseConfig
in interface BeanPopulatorBaseSpi
initBeanPopulatorBaseConfig
in interface BeanTransformerSpi
public BeanPopulatorBaseConfig getBeanPopulatorBaseConfig()
BeanTransformerSpi
getBeanPopulatorBaseConfig
in interface BeanTransformerSpi
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |