JBoss Marshalling 1.3.0.CR9

org.jboss.marshalling.cloner
Interface ObjectCloner


public interface ObjectCloner

An object cloner. Creates a (possibly deep) clone of an object. Unlike Marshallers and Unmarshallers, ObjectCloners are thread-safe and can be used to clone object graphs concurrently.


Field Summary
static ObjectCloner IDENTITY
          The identity object cloner.
 
Method Summary
 Object clone(Object orig)
          Create a deep clone of the given object.
 void reset()
          Clear the cloner state and any caches.
 

Field Detail

IDENTITY

static final ObjectCloner IDENTITY
The identity object cloner. Always returns the same object it is given.

Method Detail

reset

void reset()
Clear the cloner state and any caches.


clone

Object clone(Object orig)
             throws IOException,
                    ClassNotFoundException
Create a deep clone of the given object.

Parameters:
orig - the original object
Returns:
the deep clone
Throws:
IOException - if a serialization error occurs
ClassNotFoundException

JBoss Marshalling 1.3.0.CR9

Copyright © 2011 JBoss, a division of Red Hat, Inc.