com.anasoft.os.daofusion.entity
Class PersistentEntity<ID extends java.io.Serializable>

java.lang.Object
  extended by com.anasoft.os.daofusion.entity.PersistentEntity<ID>
Type Parameters:
ID - Java type of the primary key column.
All Implemented Interfaces:
Persistable<ID>, java.io.Serializable
Direct Known Subclasses:
ImmutablePersistentEntity, MutablePersistentEntity, PersistentEnumeration

public abstract class PersistentEntity<ID extends java.io.Serializable>
extends java.lang.Object
implements Persistable<ID>

Base class for persistent entities managed within the JPA persistence context.

Note that this class does NOT provide any special Object.hashCode() and Object.equals(Object) implementation - this is a task left to be done, depending on the chosen method implementation pattern.

This class implicitly supports the clone operation. Subclasses can implement Cloneable interface if they wish to add explicit clone operation support.

Author:
vojtech.szocs
See Also:
Persistable, Serialized Form

Field Summary
static java.lang.String _ID
           
 
Constructor Summary
PersistentEntity()
           
 
Method Summary
protected  java.lang.Object clone()
           
 ID getId()
           
protected  void setId(ID id)
           
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_ID

public static final java.lang.String _ID
See Also:
Constant Field Values
Constructor Detail

PersistentEntity

public PersistentEntity()
Method Detail

getId

public ID getId()

setId

protected void setId(ID id)

clone

protected java.lang.Object clone()
                          throws java.lang.CloneNotSupportedException
Overrides:
clone in class java.lang.Object
Throws:
java.lang.CloneNotSupportedException


Copyright © 2008-2009 ANASOFT and contributors. All Rights Reserved.