@NotStorableClass public final class DeepCopier extends AbstractDeepCopy
classInfoFactory, deepCopyServiceDelagate, HELPER_REFLECT, logger, objectCopyMap, rootSourceObject
Modifier and Type | Method and Description |
---|---|
Object |
deepCopy(Object sourceObject,
IDeepCopyServiceDelegate deepCopyServiceDelegate,
boolean forceLoad) |
protected void |
deepCopyDone() |
protected void |
forceLoadImpl(Object objectToCopy) |
static DeepCopier |
getInstance() |
protected boolean |
mustBeCopied(Object objectToCopy,
ClassInfo classInfo) |
protected Object |
newInstanceForObjectCopy(Object sourceObject,
ClassInfo sourceObjectClassInfo)
create a new instance copy of source object
the new instance must be done without calling constructor since state will be set by field value copy |
public static DeepCopier getInstance()
public Object deepCopy(Object sourceObject, IDeepCopyServiceDelegate deepCopyServiceDelegate, boolean forceLoad) throws CopierException
deepCopy
in class AbstractDeepCopy
sourceObject
- the source objectforceLoad
- true if force proxy loadCopierException
protected void deepCopyDone() throws CopierException
deepCopyDone
in class AbstractDeepCopy
CopierException
protected void forceLoadImpl(Object objectToCopy) throws ObjectIOException, ObjectIODataRecordNotFoundException, ObjectIOInvalidClassException, ObjectIOClassNotFoundException, ObjectIODataCorruptedException, ObjectIONotSerializableException, ProxyException
protected boolean mustBeCopied(Object objectToCopy, ClassInfo classInfo)
mustBeCopied
in class AbstractDeepCopy
protected Object newInstanceForObjectCopy(Object sourceObject, ClassInfo sourceObjectClassInfo) throws CopierException
AbstractDeepCopy
newInstanceForObjectCopy
in class AbstractDeepCopy
sourceObject
- the source objectsourceObjectClassInfo
- the class information of the object to createCopierException
Copyright © 2007-2012 Luc Peuvrier. All Rights Reserved.