public class MappingTableColumnModel extends HCIModelAdapter
Java class is a generic model that represents a data value in a row of
a mapping table or subscriber mapping table.
The data value can be a number, a string, or a currency depending
on the definition of the corresponding column in the mapping table class.
Note
It can contain any type of values, so it can be used as a value in an input or output column.
The XML APIs specify the following XSD fragment:
XSD Fragment
<xs:complexType name="MappingTableColumn">
<xs:sequence>
<xs:choice>
<xs:element ref="string" />
<xs:element name="currency" type="CurrencyType" />
<xs:element ref="number" />
</xs:choice>
</xs:sequence>
<xs:attribute name="name" type="xs:string" use="required"/> <!-- the name of the input or output column as declared in the mapping table class -->
</xs:complexType>
<xs:element name="column" type="MappingTableColumn" />
| Modifier and Type | Class and Description |
|---|---|
static class |
MappingTableColumnModel.MappingTableType
This
enumeration lists all the possible type values of a column in a mapping table class (in and out columns). |
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
TAG_NAME
The XML tag name of a generic column of a row: "column"
|
| Constructor and Description |
|---|
MappingTableColumnModel() |
| Modifier and Type | Method and Description |
|---|---|
void |
addCharacterData(java.lang.String cData)
Adds character data to the content element.
|
void |
addChild(java.lang.String tagName,
XMLMarshallable child)
Adds a child to the object, the
child representing
the marshallable object which must be added to the element. |
java.lang.String |
getName()
Gets the name of the column.
|
java.math.BigDecimal |
getNumberValue()
Gets the value as a
BigDecimal if the column type is Number. |
java.lang.String |
getStringValue()
Gets the value as a
String if the column type is String or Currency. |
java.lang.String |
getTagName()
Gets the XML tag name of the HCI model.
|
MappingTableColumnModel.MappingTableType |
getType()
Gets the column type.
|
void |
marshalAttributes(XMLOutputter output)
Gives an XML representation of the attributes of an object.
|
void |
marshalChildren(XMLOutputter output)
Gives an XML representation of the child objects of an object.
|
void |
setAttributes(XMLAttributes atts)
Sets the attributes of the XML representation of the element being
processed.
|
void |
setCurrencyValue(java.lang.String value)
Sets a
String value and sets the type of the column to MappingTableColumnModel.MappingTableType.CURRENCY. |
void |
setName(java.lang.String name)
Sets the name of the column.
|
void |
setNumberValue(java.math.BigDecimal value)
Sets a
BigDecimal value and sets the type of the column to MappingTableColumnModel.MappingTableType.NUMBER. |
void |
setStringValue(java.lang.String value)
Sets a
String value and sets the type of the column to MappingTableColumnModel.MappingTableType.STRING. |
void |
setType(MappingTableColumnModel.MappingTableType newType)
Sets the type of the column.
|
marshalpublic static final java.lang.String TAG_NAME
public java.lang.String getName()
public void setName(java.lang.String name)
name - The name of the column to set uppublic MappingTableColumnModel.MappingTableType getType()
MappingTableColumnModel.MappingTableTypepublic void setType(MappingTableColumnModel.MappingTableType newType)
type of column,
then the object value is set to null.newType - The type of the column to setMappingTableColumnModel.MappingTableTypepublic java.lang.String getStringValue()
String if the column type is String or Currency.String value of the column if the type is String or Currency,
null otherwisepublic void setStringValue(java.lang.String value)
String value and sets the type of the column to MappingTableColumnModel.MappingTableType.STRING.value - The String value to set in the columnpublic void setCurrencyValue(java.lang.String value)
String value and sets the type of the column to MappingTableColumnModel.MappingTableType.CURRENCY.value - The String value to set in the columnpublic java.math.BigDecimal getNumberValue()
BigDecimal if the column type is Number.BigDecimal value of the column if the type is Number,
null otherwisepublic void setNumberValue(java.math.BigDecimal value)
BigDecimal value and sets the type of the column to MappingTableColumnModel.MappingTableType.NUMBER.value - The BigDecimal value to set in the columnpublic java.lang.String getTagName()
ITagNameProviderpublic void addChild(java.lang.String tagName,
XMLMarshallable child)
XMLMarshallablechild representing
the marshallable object which must be added to the element.tagName - The name of tag for the childchild - The child to be addedpublic void setAttributes(XMLAttributes atts)
XMLMarshallableatts - The XML attributes of the current elementpublic void addCharacterData(java.lang.String cData)
XMLMarshallablecData - The character data to be addedpublic void marshalAttributes(XMLOutputter output)
IXMLMarshallableoutput - The XML output to marshal the object attributes intopublic void marshalChildren(XMLOutputter output)
IXMLMarshallableoutput - The XML output to marshal the child objects into