|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.eclipse.ecf.core.identity.BaseID org.eclipse.ecf.core.identity.StringID
public class StringID
A string-based identity
Nested Class Summary | |
---|---|
static class |
StringID.StringIDNamespace
|
Field Summary | |
---|---|
protected java.lang.String |
value
|
Fields inherited from class org.eclipse.ecf.core.identity.BaseID |
---|
namespace |
Constructor Summary | |
---|---|
protected |
StringID(Namespace n,
java.lang.String s)
Protected constructor for factory-based construction |
Method Summary | |
---|---|
int |
compareTo(java.lang.Object o)
|
boolean |
equals(java.lang.Object o)
|
java.lang.String |
getName()
Get the unique name of this identity. |
Namespace |
getNamespace()
Get the Namespace instance associated with this identity |
int |
hashCode()
|
protected int |
namespaceCompareTo(BaseID obj)
Called by Namespace.getCompareToForObject(BaseID, BaseID) . |
protected boolean |
namespaceEquals(BaseID obj)
Called by Namespace.testIDEquals(BaseID, BaseID) . |
protected java.lang.String |
namespaceGetName()
Called by Namespace.getNameForID(BaseID) . |
protected int |
namespaceHashCode()
Called by Namespace.getHashCodeForID(BaseID) . |
protected void |
setEmptyNamespace()
|
java.lang.String |
toExternalForm()
Get this ID instance in String form. |
java.lang.String |
toString()
|
Methods inherited from class org.eclipse.ecf.core.identity.BaseID |
---|
getAdapter, namespaceToExternalForm |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected java.lang.String value
Constructor Detail |
---|
protected StringID(Namespace n, java.lang.String s)
n
- the Namespace this identity will belong tos
- the String defining this StringIDMethod Detail |
---|
public int compareTo(java.lang.Object o)
compareTo
in interface java.lang.Comparable
compareTo
in class BaseID
public boolean equals(java.lang.Object o)
equals
in interface java.security.Principal
equals
in interface ID
equals
in class BaseID
public java.lang.String getName()
ID
getName
in interface java.security.Principal
getName
in interface ID
getName
in class BaseID
public int hashCode()
hashCode
in interface java.security.Principal
hashCode
in interface ID
hashCode
in class BaseID
public Namespace getNamespace()
ID
getNamespace
in interface ID
getNamespace
in class BaseID
public java.lang.String toExternalForm()
ID
toExternalForm
in interface ID
toExternalForm
in class BaseID
public java.lang.String toString()
toString
in interface java.security.Principal
toString
in class java.lang.Object
protected int namespaceCompareTo(BaseID obj)
BaseID
Namespace.getCompareToForObject(BaseID, BaseID)
.
namespaceCompareTo
in class BaseID
obj
- the other ID to compare to. Will not be null
.
Comparable
contract.protected boolean namespaceEquals(BaseID obj)
BaseID
Namespace.testIDEquals(BaseID, BaseID)
.
namespaceEquals
in class BaseID
obj
- the other ID to test against. May be null
.
true
if this ID is equal to the given ID.
false
otherwise.protected java.lang.String namespaceGetName()
BaseID
Namespace.getNameForID(BaseID)
.
namespaceGetName
in class BaseID
null
. Value
returned should be unique within this Namespace.protected int namespaceHashCode()
BaseID
Namespace.getHashCodeForID(BaseID)
.
namespaceHashCode
in class BaseID
protected void setEmptyNamespace()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |