|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.exolab.core.foundation.PersistentObject
public abstract class PersistentObject
This is the base class for all persistent objects. A persistent object is on that can be placed in a persistent store, is transactional, is lockable etc. All persistent objects, must derive from this class; with no exception. This class also has an id and version, which uniquely identifies this object within an application.
This object is also Serializable
ObjectId
,
VersionId
,
PersistentCapableIfc
,
Serializable
,
Serialized FormConstructor Summary | |
---|---|
PersistentObject()
The default constructor does nothing |
|
PersistentObject(ObjectId id,
ObjectVersion version)
Instantiate an instance of this class with the specified object id and version number. |
Method Summary | |
---|---|
java.lang.Object |
clone()
Clone this object and its base objects. |
boolean |
equals(java.lang.Object object)
Check if the two objects are equal. |
long |
getId()
Return an instance of the object identity |
int |
getMinimumObjectSize()
Return the minimum size of this object. |
ObjectId |
getObjectId()
Return the object identifier associated with this object |
ObjectVersion |
getObjectVersion()
Return the object version associated with this object |
long |
getVersion()
Return the version of the object |
void |
readExternal(java.io.ObjectInput stream)
|
void |
setId(long id)
Set the object id using the passed in identifier. |
void |
setMinimumObjectSize(int size)
Set the minimum size that the object should occurpy. |
void |
setObjectId(ObjectId id)
Set the object id for this persistent object using the specified object. |
void |
setObjectVersion(ObjectVersion version)
Set the object version for this persistent object using the specified object. |
void |
setVersion(long version)
Set the object version using the passed in identifier. |
void |
writeExternal(java.io.ObjectOutput stream)
|
Methods inherited from class java.lang.Object |
---|
finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public PersistentObject()
public PersistentObject(ObjectId id, ObjectVersion version)
id
- unique object identifierversion
- version numberMethod Detail |
---|
public void setId(long id)
id
- unique object idpublic long getId()
public void setObjectId(ObjectId id)
id
- object idpublic ObjectId getObjectId()
getObjectId
in interface PersistentCapableIfc
public void setVersion(long version)
version
- versionpublic long getVersion()
public void setObjectVersion(ObjectVersion version)
version
- object versionpublic ObjectVersion getObjectVersion()
getObjectVersion
in interface PersistentCapableIfc
public void setMinimumObjectSize(int size)
setMinimumObjectSize
in interface PersistentCapableIfc
size
- minimum object sizepublic int getMinimumObjectSize()
getMinimumObjectSize
in interface PersistentCapableIfc
public boolean equals(java.lang.Object object)
equals
in class java.lang.Object
object
- object to compare against
public java.lang.Object clone() throws java.lang.CloneNotSupportedException
clone
in class java.lang.Object
java.lang.CloneNotSupportedException
public void writeExternal(java.io.ObjectOutput stream) throws java.io.IOException
writeExternal
in interface java.io.Externalizable
java.io.IOException
public void readExternal(java.io.ObjectInput stream) throws java.io.IOException, java.lang.ClassNotFoundException
readExternal
in interface java.io.Externalizable
java.io.IOException
java.lang.ClassNotFoundException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |