com.lutris.appserver.server.sql
Class CloneableDO
java.lang.Object
|
+--com.lutris.appserver.server.sql.CoreDO
|
+--com.lutris.appserver.server.sql.CloneableDO
- All Implemented Interfaces:
- java.lang.Cloneable, java.io.Serializable, Transaction
- Direct Known Subclasses:
- GenericDO
- public abstract class CloneableDO
- extends CoreDO
- implements java.lang.Cloneable
Base class from which the data objects are created.
Provides functionality for cloning data objects. The cloned
data object will have a unique object identifier.
- Since:
- LBS1.8
- Version:
- $Revision: 1.2 $
- Author:
- Kyle Clark
- See Also:
- Serialized Form
Method Summary |
protected java.lang.Object |
clone()
Will clone the existing object keeping a fields
the same, including the object id. |
java.lang.Object |
cloneUnique()
Creates a clone of the object, but ensures that
a new and unique object id is created for the object
and that the version number is set to zero. |
Methods inherited from class com.lutris.appserver.server.sql.CoreDO |
addToCache, deleteFromCache, disableVersioning, evict, executeDelete, executeInsert, executeUpdate, finalizeDelete, finalizeInsert, finalizeUpdate, getDeleteStatement, getInsertStatement, getNewVersion, getOId, getOIdColumnName, getTableName, getUpdateStatement, getVersion, getVersionColumnName, isPersistent, refresh, setNewVersion, setOId, setOIdColumnName, setPersistent, setVersion, setVersionColumnName, updateCache |
Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CloneableDO
public CloneableDO()
- Public constructor.
CloneableDO
public CloneableDO(java.sql.ResultSet rs)
throws java.sql.SQLException,
ObjectIdException
- Public constructor.
- Parameters:
rs
- a result set.
- Throws:
java.sql.SQLException
- if an error occurs while instantiating this
object from the result set.
ObjectIdException
- if the object id for this object is
invalid.
cloneUnique
public java.lang.Object cloneUnique()
throws DatabaseManagerException,
ObjectIdException
- Creates a clone of the object, but ensures that
a new and unique object id is created for the object
and that the version number is set to zero.
- Throws:
DatabaseManagerException
- if an error occurs while
allocation a new object id from the default logical database.
ObjectIdException
- if a new object id could not be
allocated.
clone
protected java.lang.Object clone()
- Will clone the existing object keeping a fields
the same, including the object id.
- Overrides:
clone
in class java.lang.Object