|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.openjpa.util.OpenJPAId org.apache.openjpa.util.Id
public final class Id
Datastore identity type. Implementations may choose to use this type, or choose to use their own datastore identity values.
Field Summary |
---|
Fields inherited from class org.apache.openjpa.util.OpenJPAId |
---|
subs, type, TYPE_VALUE_SEP |
Constructor Summary | |
---|---|
Id(Class cls,
long key)
Construct from key value. |
|
Id(Class cls,
Long key)
Construct from key value. |
|
Id(Class cls,
long key,
boolean subs)
Construct from key value. |
|
Id(Class cls,
String key)
Construct from the result of a OpenJPAId.toString() call on another
instance. |
|
Id(String str)
Create an id from the result of a OpenJPAId.toString() call on another
instance. |
|
Id(String str,
ClassLoader loader)
Create an id from the result of an OpenJPAId.toString() call on another
instance. |
|
Id(String str,
OpenJPAConfiguration conf,
ClassLoader brokerLoader)
Create an id from the result of an OpenJPAId.toString() call on another
instance. |
Method Summary | |
---|---|
long |
getId()
Primary key. |
Object |
getIdObject()
Return the identity value as an object. |
protected boolean |
idEquals(OpenJPAId other)
Compare the id to the id of the given instance. |
protected int |
idHash()
Return the id's hash code. |
static Id |
newInstance(Class cls,
Object val)
Create an id from the given type and value; the value might be an id instance, a stringified id, or a primary key value. |
Methods inherited from class org.apache.openjpa.util.OpenJPAId |
---|
compareTo, equals, getType, hashCode, hasSubclasses, setManagedInstanceType, setManagedInstanceType, toString |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Id(String str)
OpenJPAId.toString()
call on another
instance.
public Id(String str, OpenJPAConfiguration conf, ClassLoader brokerLoader)
OpenJPAId.toString()
call on another
instance.
public Id(String str, ClassLoader loader)
OpenJPAId.toString()
call on another
instance.
public Id(Class cls, String key)
OpenJPAId.toString()
call on another
instance.
public Id(Class cls, Long key)
public Id(Class cls, long key)
public Id(Class cls, long key, boolean subs)
Method Detail |
---|
public static Id newInstance(Class cls, Object val)
public long getId()
public Object getIdObject()
OpenJPAId
getIdObject
in class OpenJPAId
protected int idHash()
OpenJPAId
idHash
in class OpenJPAId
protected boolean idEquals(OpenJPAId other)
OpenJPAId
idEquals
in class OpenJPAId
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |