org.addsimplicity.anicetus.hibernate
Class HibernateEntity

java.lang.Object
  extended by org.addsimplicity.anicetus.hibernate.HibernateEntity

public class HibernateEntity
extends java.lang.Object

A hibernate entity tracks the operation performed on a type. The entity includes the primary key of the entity so each individual entity is tracked directly.

Author:
Dan Pritchett (driveawedge@yahoo.com)

Constructor Summary
HibernateEntity()
          Construct an empty hibernate entity.
HibernateEntity(java.lang.String type, java.lang.String identifier, HibernateOperation operation)
          Construct an entity of the specified type, instance, and operation.
 
Method Summary
 java.lang.String getIdentifier()
          Get the primary key of the entity.
 HibernateOperation getOperation()
          Get the operation performed upon the entity.
 java.lang.String getType()
          Get the name of the type of the entity.
 void setIdentifier(java.lang.String identifier)
          Set the primary key of the entity.
 void setOperation(HibernateOperation operation)
          Set the operation performed upon the entity.
 void setType(java.lang.String type)
          Set the type of the entity.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HibernateEntity

public HibernateEntity()
Construct an empty hibernate entity.


HibernateEntity

public HibernateEntity(java.lang.String type,
                       java.lang.String identifier,
                       HibernateOperation operation)
Construct an entity of the specified type, instance, and operation.

Parameters:
type - The name of the type. Typically the fully qualified class name.
identifier - The primary key of the instance.
operation - The operation being performed upon the instance.
Method Detail

getIdentifier

public java.lang.String getIdentifier()
Get the primary key of the entity.

Returns:
the primary key.

getOperation

public HibernateOperation getOperation()
Get the operation performed upon the entity.

Returns:
the operation performed upon the entity.

getType

public java.lang.String getType()
Get the name of the type of the entity.

Returns:
the type of the entity.

setIdentifier

public void setIdentifier(java.lang.String identifier)
Set the primary key of the entity.

Parameters:
identifier - The primary key of the entity.

setOperation

public void setOperation(HibernateOperation operation)
Set the operation performed upon the entity.

Parameters:
operation - The operation performed upon the entity.

setType

public void setType(java.lang.String type)
Set the type of the entity. Typically the fully qualified class name.

Parameters:
type - The type name.


Copyright © 2009 Add Simplicity. All Rights Reserved.