Package com.highdeal.pnr.hci
Class InAttributeModel
java.lang.Object
com.highdeal.pnr.hci.InAttributeModel
- All Implemented Interfaces:
XMLMarshallable
This class represents an input attribute of a translation table
and contains a name and a description.
- See Also:
XML API for HCI
The XML APIs specify the following XSD fragment:
XSD Fragment
<xs:element name="inAttribute">
<xs:complexType>
<xs:attribute name="name" type="xs:string" use="required"/>
<xs:attribute name="description" type="xs:string"/>
</xs:complexType>
</xs:element>
-
Constructor Summary
ConstructorsConstructorDescriptionConstructs an empty input attribute model.InAttributeModel(String name, String description) Constructs an input attribute with a name, and a description. -
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.booleanReturns true if the name is valid.Returns the description of the input attribute.getName()Returns the name of the input attribute.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 description of the input attribute.voidSets the name of the input attribute.
-
Constructor Details
-
InAttributeModel
public InAttributeModel()Constructs an empty input attribute model. -
InAttributeModel
Constructs an input attribute with a name, and a description.- Parameters:
name- the name of the attribute.description- the description of the attribute.
-
-
Method Details
-
getName
Returns the name of the input attribute.- Returns:
- the name of the input attribute.
-
setName
Sets the name of the input attribute.- Parameters:
n- the name of the input attribute.
-
getDescription
Returns the description of the input attribute.- Returns:
- the description of the input attribute.
-
setDescription
Sets the description of the input attribute.- Parameters:
d- the description of the input attribute.
-
checkValidity
public boolean checkValidity()Returns true if the name is valid. Name is valid if it is not null or empty .- Returns:
- true if the name is valid, false otherwise.
-
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
-
addCharacterData
Description copied from interface:XMLMarshallableAdds character data to the content element.- Specified by:
addCharacterDatain interfaceXMLMarshallable- Parameters:
cData- The character data 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
-