Package com.highdeal.pnr.hci
Class PrepaidTransactionFieldMappingModel
java.lang.Object
com.highdeal.pnr.hci.PrepaidTransactionFieldMappingModel
- All Implemented Interfaces:
XMLMarshallable
This class represents how a detail of a prepaid transaction can be mapped to a constant, or to a property
of the rating context.
XML API for HCI
The XML APIs specify the following XSD fragment:
XSD Fragment
<xs:element name="fieldMapping">
<xs:complexType>
<xs:attribute name="transactionField" type="PrepaidTransactionFieldType" use="required"/>
<xs:attribute name="propertyName" type="xs:string" use="optional"/>
<xs:attribute name="value" type="xs:string" use="optional"/>
</xs:complexType>
</xs:element>
-
Constructor Summary
ConstructorsConstructorDescriptionBuilds a new prepaid transaction detail mapping.PrepaidTransactionFieldMappingModel(PrepaidTransactionField transactionField, String propertyName, String stringValue, BigDecimal numberValue, Date dateValue) Builds a full prepaid transaction detail mapping. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddCharacterData(String data) 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.Returns the constant value that is mapped if it is a date.Returns the constant value that is mapped if it is a number.Gets the property name of the rating context that is mapped.Returns the constant value that is mapped if it is a string.Gets the transaction field of the prepaid transaction that is mapped.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.voidsetDateValue(Date date) Sets the constant value that is mapped if it is a date.voidsetNumberValue(BigDecimal number) Sets the constant value that is mapped if it is a number.voidsetPropertyName(String propertyName) Sets the property name of the rating context that is mapped.voidsetStringValue(String string) Sets the constant value that is mapped if it is a string.voidSets the transaction field of the prepaid transaction that is mapped.
-
Constructor Details
-
PrepaidTransactionFieldMappingModel
public PrepaidTransactionFieldMappingModel()Builds a new prepaid transaction detail mapping. -
PrepaidTransactionFieldMappingModel
public PrepaidTransactionFieldMappingModel(PrepaidTransactionField transactionField, String propertyName, String stringValue, BigDecimal numberValue, Date dateValue) Builds a full prepaid transaction detail mapping.- Parameters:
transactionField-propertyName-stringValue-numberValue-dateValue-
-
-
Method Details
-
getPropertyName
Gets the property name of the rating context that is mapped.- Returns:
- the mapped property name
-
setPropertyName
Sets the property name of the rating context that is mapped.- Parameters:
propertyName- the name of the property to map.
-
getTransactionField
Gets the transaction field of the prepaid transaction that is mapped.- Returns:
- the transaction field of the prepaid transaction that is mapped.
-
setTransactionField
Sets the transaction field of the prepaid transaction that is mapped.- Parameters:
field- the transaction field of the prepaid transaction that is mapped.
-
getStringValue
Returns the constant value that is mapped if it is a string.- Returns:
- the constant value that is mapped if it is a string.
-
setStringValue
Sets the constant value that is mapped if it is a string.- Parameters:
string- the constant value that is mapped if it is a string.
-
getNumberValue
Returns the constant value that is mapped if it is a number.- Returns:
- the constant value that is mapped if it is a number.
-
setNumberValue
Sets the constant value that is mapped if it is a number.- Parameters:
number- the constant value that is mapped if it is a number.
-
getDateValue
Returns the constant value that is mapped if it is a date.- Returns:
- the constant value that is mapped if it is a date.
-
setDateValue
Sets the constant value that is mapped if it is a date.- Parameters:
date- the constant value that is mapped if it is a date.
-
addCharacterData
Adds character data to the content element.- Specified by:
addCharacterDatain interfaceXMLMarshallable- Parameters:
data- The character data to be added
-
addChild
Adds 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
Gives an XML representation of this object, including its children.- Specified by:
marshalin interfaceXMLMarshallable- Parameters:
output- TheXML outputto marshal the object into
-
setAttributes
Sets the attributes of the XML representation of the element being processed.- Specified by:
setAttributesin interfaceXMLMarshallable- Parameters:
atts- TheXML attributesof the current element
-