Class R_OSGiID
java.lang.Object
org.eclipse.ecf.core.identity.BaseID
org.eclipse.ecf.provider.r_osgi.identity.R_OSGiID
- All Implemented Interfaces:
Serializable,Comparable,Principal,org.eclipse.core.runtime.IAdaptable,ID
- Direct Known Subclasses:
R_OSGiWSID
The ID implementation of R-OSGi URIs. Currently only works with the R-OSGi
namespace and hence with the R-OSGi default transport (persistent tcp
connections).
- See Also:
-
Field Summary
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionch.ethz.iks.r_osgi.URIgetURI()get the internal URI.protected intcompare in the context of the namespace.protected booleancheck for equality in the context of the namespace.protected Stringget the name.protected intget the hash code.Get this ID instance in String form.toString()get a string representation.Methods inherited from class org.eclipse.ecf.core.identity.BaseID
compareTo, equals, getAdapter, getName, getNamespace, hashCode, namespaceToExternalForm
-
Constructor Details
-
R_OSGiID
create a new R-OSGi ID from an URI string.- Parameters:
uriString- the URI of a remote service.
-
R_OSGiID
- Parameters:
ns- namespace- Since:
- 3.5
-
-
Method Details
-
namespaceCompareTo
compare in the context of the namespace.- Specified by:
namespaceCompareToin classBaseID- Parameters:
id- anotherBaseIDto compare to.- Returns:
- -1 if smaller, 1 if larger, and 0 for equality.
- See Also:
-
namespaceEquals
check for equality in the context of the namespace.- Specified by:
namespaceEqualsin classBaseID- Parameters:
id- anotherBaseIDto check with.- Returns:
trueiff the two IDs are equal within the given namespace.- See Also:
-
getURI
public ch.ethz.iks.r_osgi.URI getURI()get the internal URI.- Returns:
- the internal R-OSGi URI.
-
namespaceGetName
get the name.- Specified by:
namespaceGetNamein classBaseID- Returns:
- the name as a String.
-
namespaceHashCode
protected int namespaceHashCode()get the hash code.- Specified by:
namespaceHashCodein classBaseID- Returns:
- the hash code.
-
toString
get a string representation. -
toExternalForm
Description copied from interface:IDGet this ID instance in String form. Will not return null.- Specified by:
toExternalFormin interfaceID- Overrides:
toExternalFormin classBaseID- Returns:
- String that is external representation of this ID
- Since:
- 3.0
- See Also:
-