public abstract class ComponentID extends Object implements Comparable, Serializable, Cloneable
ComponentID
class is the common base class for all component
identifiers. All deployable components installed in the SLEE have some
component identity, specified as a derivitive class of ComponentID
.Modifier | Constructor and Description |
---|---|
protected |
ComponentID(String name,
String vendor,
String version)
Create a new component identifier.
|
Modifier and Type | Method and Description |
---|---|
abstract int |
compareTo(Object obj)
Compare this component identifier with the specified object for order.
|
protected int |
compareTo(String thisClassName,
ComponentID that)
Compare this component identifier with the specified component identifier
for order.
|
boolean |
equals(Object obj)
Compare this component identifier for equality with another object.
|
protected abstract String |
getClassName()
Get the class name of this component identifier.
|
String |
getName()
Get the name of the component.
|
String |
getVendor()
Get the vendor of the component.
|
String |
getVersion()
Get the version of the component.
|
int |
hashCode()
Get a hash code value for this component identifier.
|
String |
toString()
Get a string representation for this component identifier.
|
protected ComponentID(String name, String vendor, String version)
name
- the name of the component.vendor
- the vendor of the component.version
- the version of the component.NullPointerException
- if any argument is null
.public final String getName()
public final String getVendor()
public final String getVersion()
public final boolean equals(Object obj)
equals
in class Object
obj
- the object to compare this with.true
if obj
is a component identifier
of the same class as this, and has the same name, vendor, and
version as this, false
otherwise.Object.equals(Object)
public final int hashCode()
hashCode
in class Object
Object.hashCode()
public final String toString()
toString
in class Object
Object.toString()
public abstract int compareTo(Object obj)
Component ordering is determined by comparing the component identifier attributes in the following order:
ComponentID
may
be safely compared without causing a ClassCastException
)
compareTo
in interface Comparable
obj
- the object to compare this with.Comparable.compareTo(Object)
protected final int compareTo(String thisClassName, ComponentID that)
Component ordering is determined by comparing the component identifier attributes in the following order:
ComponentID
may
be safely compared without causing a ClassCastException
)
thisClassName
- the class name of this component identifier.that
- the component identifier to compare this with.Comparable.compareTo(Object)
protected abstract String getClassName()
getClass().getName()
.