|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.torque.om.ObjectKey
public abstract class ObjectKey
This class can be used to uniquely identify an object within an application. There are four subclasses: StringKey, NumberKey, and DateKey, and ComboKey which is a Key made up of a combination ofthe first three.
| Field Summary | |
|---|---|
protected Object |
key
The underlying key value. |
| Constructor Summary | |
|---|---|
protected |
ObjectKey()
Initializes the internal key value to null. |
| Method Summary | |
|---|---|
void |
appendTo(StringBuffer sb)
Appends a String representation of the key to a buffer. |
int |
compareTo(Object obj)
Implements the compareTo method. |
boolean |
equals(Object obj)
Returns whether this ObjekctKey is equal to another Object. |
abstract int |
getJdbcType()
Returns the JDBC type of the key as defined in java.sql.Types. |
Object |
getValue()
Get the underlying object. |
int |
hashCode()
Returns the hashcode of the underlying value (key), if key is not null. |
abstract void |
setValue(String s)
Reset the underlying object using a String. |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected Object key
| Constructor Detail |
|---|
protected ObjectKey()
null.
| Method Detail |
|---|
public int hashCode()
hashCode in class Objectint valuepublic boolean equals(Object obj)
equals in class Objectobj - the comparison value.
public Object getValue()
public abstract int getJdbcType()
java.sql.Types.
public void appendTo(StringBuffer sb)
sb - a StringBufferpublic int compareTo(Object obj)
compareTo in interface Comparable<Object>obj - the object to compare to this object
public abstract void setValue(String s)
throws TorqueException
s - a String value
TorqueException - if an error occurs
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||