Class SISComponentID
- java.lang.Object
-
- javax.slee.ComponentID
-
- com.opencloud.slee.resources.sis.components.SISComponentID
-
- All Implemented Interfaces:
SISComponent,Serializable,Cloneable,Comparable
- Direct Known Subclasses:
CompositionID,InterceptorID,MacroID,TriggerID
public abstract class SISComponentID extends ComponentID implements SISComponent
- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface com.opencloud.slee.resources.sis.components.SISComponent
SISComponent.ComponentType
-
-
Field Summary
Fields Modifier and Type Field Description static PatternCOMPONENT_ID_PATTERNstatic PatternCOMPONENT_ID_PATTERN_NOTYPE
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static <T extends ComponentID>
TfromString(Class<T> type, String s)Obtain aComponentIDfrom a string, with no type prefix, for example:name=Foo,vendor=Bar,version=1.0.static SISComponentIDfromString(String s)Obtain aSISComponentIDfrom a string with a type prefix, for example:MacroID[name=Foo,vendor=Bar,version=1.0].voidtoStream(DataOutput out)-
Methods inherited from class javax.slee.ComponentID
compareTo, equals, getName, getVendor, getVersion, hashCode, toString
-
Methods inherited from interface java.lang.Comparable
compareTo
-
Methods inherited from interface com.opencloud.slee.resources.sis.components.SISComponent
getComponentType, getName
-
-
-
-
Method Detail
-
toStream
public final void toStream(DataOutput out) throws IOException
- Throws:
IOException
-
fromString
public static SISComponentID fromString(String s) throws IllegalArgumentException
Obtain aSISComponentIDfrom a string with a type prefix, for example:MacroID[name=Foo,vendor=Bar,version=1.0].- Parameters:
s- the string to parse, must be of the formType[name=X,vendor=Y,version=Z], or "null".- Returns:
- an object of the type implied by the prefix, or
nullif the string equalled the literal "null". - Throws:
IllegalArgumentException- if the string could not be parsed, or the type was unknown.
-
fromString
public static <T extends ComponentID> T fromString(Class<T> type, String s) throws IllegalArgumentException
Obtain aComponentIDfrom a string, with no type prefix, for example:name=Foo,vendor=Bar,version=1.0.- Parameters:
type- the desiredComponentIDconcrete class to return. The concrete class must have a public constructor with 3 string args (name, vendor, version).s- the string to parse, must be of the formname=x,vendor=y,version=z, or "null".- Returns:
- an object of the given
type, ornullif the string equalled the literal "null". - Throws:
IllegalArgumentException- if the string could not be parsed, or an instance of the class could not be created.
-
-