Package com.highdeal.pnr.hci
Class UniqueIdentifier
java.lang.Object
com.highdeal.pnr.hci.UniqueIdentifier
- All Implemented Interfaces:
XMLMarshallable
This object represents a unique identifier with a type and a value.
XML API for HCI
The XML APIs specify the following XSD fragment:
XSD Fragment
<xs:element name="uid">
<xs:complexType>
<xs:attribute name="type" type="xs:string" use="required" />
<xs:attribute name="value" type="xs:string" use="required" />
</xs:complexType>
</xs:element>
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddCharacterData(String cData) Adds character data to the content element.voidaddChild(String tagName, XMLMarshallable child) Adds a child to the object, thechildrepresenting the marshallable object which must be added to the element.getType()Gets the type of the unique identifier.getValue()Gets the value of the unique identifier.voidmarshal(XMLOutputter output) Gives an XML representation of this object, including its children.voidsetAttributes(XMLAttributes atts) Sets the attributes of the XML representation of the element being processed.voidSets the type of the unique identifier.voidSets the value of the unique identifier.toString()static UniqueIdentifierReturns a unique identifier based on its string representation.
-
Field Details
-
TAG_NAME
The XML tag name of this object.- See Also:
-
-
Constructor Details
-
UniqueIdentifier
public UniqueIdentifier()Builds an empty unique identifier object.
-
-
Method Details
-
getType
Gets the type of the unique identifier.- Returns:
- the type of the unique identifier
-
setType
Sets the type of the unique identifier.- Parameters:
type- the type of the unique identifier
-
getValue
Gets the value of the unique identifier.- Returns:
- the value of the unique identifier
-
setValue
Sets the value of the unique identifier.- Parameters:
value- the value of the unique identifier
-
addCharacterData
Description copied from interface:XMLMarshallableAdds character data to the content element.- Specified by:
addCharacterDatain interfaceXMLMarshallable- Parameters:
cData- The character data to be added
-
setAttributes
Description copied from interface:XMLMarshallableSets the attributes of the XML representation of the element being processed.- Specified by:
setAttributesin interfaceXMLMarshallable- Parameters:
atts- TheXML attributesof the current element
-
addChild
Description copied from interface:XMLMarshallableAdds a child to the object, thechildrepresenting the marshallable object which must be added to the element.- Specified by:
addChildin interfaceXMLMarshallable- Parameters:
tagName- The name of tag for the childchild- The child to be added
-
marshal
Description copied from interface:XMLMarshallableGives an XML representation of this object, including its children.- Specified by:
marshalin interfaceXMLMarshallable- Parameters:
output- TheXML outputto marshal the object into
-
toString
-
valueOf
Returns a unique identifier based on its string representation.- Parameters:
input- an input string representing the unique identifier and following the format of thetoString()method- Returns:
- a unique identifier objects corresponding to the input string
-