org.apache.ojb.otm.copy
Class SerializeObjectCopyStrategy

java.lang.Object
  extended byorg.apache.ojb.otm.copy.SerializeObjectCopyStrategy
All Implemented Interfaces:
ObjectCopyStrategy

public final class SerializeObjectCopyStrategy
extends java.lang.Object
implements ObjectCopyStrategy

Does in-memory serialization to achieve a copy of the object graph.

Author:
matthew.baird
See Also:
ObjectCopyStrategy

Constructor Summary
SerializeObjectCopyStrategy()
           
 
Method Summary
 java.lang.Object copy(java.lang.Object obj)
          This implementation will probably be slower than the metadata object copy, but this was easier to implement.
 java.lang.Object copy(java.lang.Object src, java.lang.Object dest)
          copy src object into dest object
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SerializeObjectCopyStrategy

public SerializeObjectCopyStrategy()
Method Detail

copy

public java.lang.Object copy(java.lang.Object obj)
                      throws ObjectCopyException
This implementation will probably be slower than the metadata object copy, but this was easier to implement.

Specified by:
copy in interface ObjectCopyStrategy
Parameters:
obj - object to be copied
Returns:
Object the copy of the object
Throws:
ObjectCopyException
See Also:
ObjectCopyStrategy.copy(Object)

copy

public java.lang.Object copy(java.lang.Object src,
                             java.lang.Object dest)
Description copied from interface: ObjectCopyStrategy
copy src object into dest object

Specified by:
copy in interface ObjectCopyStrategy
Parameters:
src -
dest -
Returns:


Authors: Thomas Mahler and others. (C) 2000 - 2003 Apache Software Foundation
All rights reserved. Published under the Apache License.
http://db.apache.org/ojb
Version: 1.0.rc5, 2003-12-14