org.glassfish.pfl.dynamic.copyobject.impl
Class ClassCopierOrdinaryImpl

java.lang.Object
  extended by org.glassfish.pfl.dynamic.copyobject.impl.ClassCopierBase
      extended by org.glassfish.pfl.dynamic.copyobject.impl.ClassCopierOrdinaryImpl
All Implemented Interfaces:
ClassCopier

public class ClassCopierOrdinaryImpl
extends ClassCopierBase


Nested Class Summary
static interface ClassCopierOrdinaryImpl.ClassFieldCopier
           
 
Constructor Summary
ClassCopierOrdinaryImpl(PipelineClassCopierFactory ccf, java.lang.Class<?> cls)
           
 
Method Summary
 java.lang.Object createCopy(java.lang.Object source)
          Create a copy of source.
 java.lang.Object doCopy(java.util.Map<java.lang.Object,java.lang.Object> oldToNew, java.lang.Object source, java.lang.Object result)
          Do the copying of data from source to result.
static void setCodegenCopierAllowed(boolean flag)
           
 
Methods inherited from class org.glassfish.pfl.dynamic.copyobject.impl.ClassCopierBase
copy, equals, hashCode, isReflectiveClassCopier, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ClassCopierOrdinaryImpl

public ClassCopierOrdinaryImpl(PipelineClassCopierFactory ccf,
                               java.lang.Class<?> cls)
                        throws ReflectiveCopyException
Throws:
ReflectiveCopyException
Method Detail

setCodegenCopierAllowed

public static void setCodegenCopierAllowed(boolean flag)

createCopy

public java.lang.Object createCopy(java.lang.Object source)
                            throws ReflectiveCopyException
Description copied from class: ClassCopierBase
Create a copy of source. The copy may or may not be fully initialized. This method must always be overridden in a subclass.

Specified by:
createCopy in class ClassCopierBase
Throws:
ReflectiveCopyException

doCopy

public java.lang.Object doCopy(java.util.Map<java.lang.Object,java.lang.Object> oldToNew,
                               java.lang.Object source,
                               java.lang.Object result)
                        throws ReflectiveCopyException
Description copied from class: ClassCopierBase
Do the copying of data from source to result. This just returns the result by default, but it may be overrideden in a subclass. When this method completes, result must be fully initialized.

Overrides:
doCopy in class ClassCopierBase
Throws:
ReflectiveCopyException