Package com.highdeal.pnr.hci
Class PreTableComponentModel
java.lang.Object
com.highdeal.pnr.hci.RateComponentModel
com.highdeal.pnr.hci.PreTableComponentModel
- All Implemented Interfaces:
XMLMarshallable,ContextualNode
This class represents a rate component which
executes a translation table.
-
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.booleanReturns true if the component is valid.getContext(ContextualNode child) Gets the context description for the specified child; The context description contains all the context properties.Gets the in mapping.intGets the maximum child count (1).intGets the operator.Gets the out mapping.List<com.highdeal.pnr.hci.PropertyReference>Returns the list of the properties that are used in this component.Gets the reference date.getTable()Gets the translation table.Gets the code of the translation table used in this component.voidmarshal(XMLOutputter output) Gives an XML representation of this object, including its children.voidsetInMapping(Vector<String> m) Sets the in mapping.voidsetOperator(int o) Sets the operator.voidSets the out mapping.voidsetReferenceDate(String refDate) Sets the reference date.voidSets the translation table.voidSets the code of the translation table used in this component.Methods inherited from class com.highdeal.pnr.hci.RateComponentModel
findRootRateModel, getChildAt, getChildCount, getChildren, getDescription, getName, getParent, getPropertyNames, inheritedContext, isRemoveChildAllowed, isSetChildAllowed, remove, removeChild, setAttributes, setChild, setChildren, setDescription, setName, setParent
-
Constructor Details
-
PreTableComponentModel
public PreTableComponentModel()Builds an empty PreTableComponentModel.
-
-
Method Details
-
setTable
Sets the translation table.- Parameters:
t- the translation table.
-
getTable
Gets the translation table.- Returns:
- the translation table.
-
getTableCode
Gets the code of the translation table used in this component.- Returns:
- the code of the translation table used in this component.
-
setTableCode
Sets the code of the translation table used in this component.- Parameters:
c- the code of the translation table used in this component.
-
setInMapping
Sets the in mapping.- Parameters:
m- a Vector ofStringcontaining the in property names.
-
getInMapping
Gets the in mapping.- Returns:
- a Vector of
Stringcontaining the in property names.
-
setOutMapping
Sets the out mapping.- Parameters:
m- a Vector ofStringcontaining the out property names.
-
getOutMapping
Gets the out mapping.- Returns:
- a Vector of
Stringcontaining the out property names.
-
setReferenceDate
Sets the reference date.- Parameters:
refDate- a String ofStringcontaining the in property names.
-
getReferenceDate
Gets the reference date.- Returns:
- the property name of the reference date.
-
setOperator
public void setOperator(int o) Sets the operator. Allowed operators are : SeeTranslationTableModelfor complete operators list.- Parameters:
o- the operator.
-
getOperator
public int getOperator()Gets the operator. SeesetOperatorfor returned values.- Returns:
- the operator.
-
getMaxChildCount
public int getMaxChildCount()Gets the maximum child count (1). Only one child is allowed for this component.- Specified by:
getMaxChildCountin classRateComponentModel- Returns:
- the maximum child count.
-
checkValidity
public boolean checkValidity()Returns true if the component is valid.- Specified by:
checkValidityin classRateComponentModel- Returns:
- true if the component is valid, false otherwise.
-
getPropertyReferences
Description copied from class:RateComponentModelReturns the list of the properties that are used in this component.- Specified by:
getPropertyReferencesin classRateComponentModel- Returns:
- the list of the properties that are used in this component
-
getContext
Description copied from interface:ContextualNodeGets the context description for the specified child; The context description contains all the context properties.- Specified by:
getContextin interfaceContextualNode- Overrides:
getContextin classRateComponentModel- Parameters:
child- The child node- Returns:
- The context description
-
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- Overrides:
addChildin classRateComponentModel- 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- Overrides:
addCharacterDatain classRateComponentModel- 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- Overrides:
marshalin classRateComponentModel- Parameters:
output- TheXML outputto marshal the object into
-