Package org.eclipse.ecf.core.identity
Class UuID
- java.lang.Object
-
- org.eclipse.ecf.core.identity.BaseID
-
- org.eclipse.ecf.core.identity.UuID
-
- All Implemented Interfaces:
Serializable
,Comparable
,Principal
,org.eclipse.core.runtime.IAdaptable
,ID
public class UuID extends BaseID
- Since:
- 3.5
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
UuID.UuIDNamespace
-
Constructor Summary
Constructors Modifier Constructor Description UuID()
protected
UuID(UuID.UuIDNamespace ns, UUID uuid)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description UUID
getUUID()
protected int
namespaceCompareTo(BaseID obj)
protected boolean
namespaceEquals(BaseID obj)
Called byNamespace.testIDEquals(BaseID, BaseID)
.protected String
namespaceGetName()
Called byNamespace.getNameForID(BaseID)
.protected int
namespaceHashCode()
Called byNamespace.getHashCodeForID(BaseID)
.String
toString()
-
Methods inherited from class org.eclipse.ecf.core.identity.BaseID
compareTo, equals, getAdapter, getName, getNamespace, hashCode, namespaceToExternalForm, toExternalForm
-
-
-
-
Field Detail
-
uuid
protected UUID uuid
-
-
Constructor Detail
-
UuID
public UuID()
- Since:
- 3.9
-
UuID
protected UuID(UuID.UuIDNamespace ns, UUID uuid)
-
-
Method Detail
-
namespaceCompareTo
protected int namespaceCompareTo(BaseID obj)
Description copied from class:BaseID
- Specified by:
namespaceCompareTo
in classBaseID
- Parameters:
obj
- the other ID to compare to. Will not benull
.- Returns:
- the appropriate value as per
Comparable
contract.
-
namespaceEquals
protected boolean namespaceEquals(BaseID obj)
Description copied from class:BaseID
Called byNamespace.testIDEquals(BaseID, BaseID)
.- Specified by:
namespaceEquals
in classBaseID
- Parameters:
obj
- the other ID to test against. May benull
.- Returns:
true
if this ID is equal to the given ID.false
otherwise.
-
namespaceGetName
protected String namespaceGetName()
Description copied from class:BaseID
Called byNamespace.getNameForID(BaseID)
.- Specified by:
namespaceGetName
in classBaseID
- Returns:
- String name for this ID. Must not be
null
. Value returned should be unique within this Namespace.
-
namespaceHashCode
protected int namespaceHashCode()
Description copied from class:BaseID
Called byNamespace.getHashCodeForID(BaseID)
.- Specified by:
namespaceHashCode
in classBaseID
- Returns:
- int hashCode for this ID. Returned value must be unique within this process.
-
getUUID
public UUID getUUID()
-
-