net.sf.borg.model.entity
Class KeyedEntity<T>

java.lang.Object
  extended by net.sf.borg.model.entity.KeyedEntity<T>
All Implemented Interfaces:
Serializable
Direct Known Subclasses:
Address, EncryptableEntity, Link, Project, Subtask, Task, Tasklog

public abstract class KeyedEntity<T>
extends Object
implements Serializable

Abstract base class for all Entities that are keyed by a simple integer key

See Also:
Serialized Form

Constructor Summary
KeyedEntity()
          Creates a new instance of KeyedEntity.
 
Method Summary
protected  T clone()
           
 T copy()
          Copy the entity
 int getKey()
          Gets the key.
 void setKey(int k)
          Sets the key.
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

KeyedEntity

public KeyedEntity()
Creates a new instance of KeyedEntity.

Method Detail

getKey

public int getKey()
Gets the key.

Returns:
the key

setKey

public void setKey(int k)
Sets the key.

Parameters:
k - the new key

copy

public T copy()
Copy the entity

Returns:
a copy

clone

protected T clone()
Overrides:
clone in class Object


Generated September 24 2010 by mbb using Apache Ant version 1.7.1 compiled on June 27 2008 and Java version 1.6.0_20 from Sun Microsystems Inc. on Linux i386 2.6.24-28-generic