public class TierTableModel extends Object implements XMLMarshallable, ICatalogObject, ITagNameProvider
Java class represents a tier table as seen when it comes from the back-end database;
It is part of the master data owned by a service provider.The XML APIs specify the following XSD fragment:
XSD Fragment
<xs:element name="tierTable">
<xs:complexType>
<xs:sequence>
<xs:element ref="tierTableOutAttribute" minOccurs="1" maxOccurs="5"/>
<xs:element ref="tierTableInstance" minOccurs="0" maxOccurs="unbounded"/>
<xs:element name="tierTableInstanceChronology" minOccurs="0" maxOccurs="1">
<xs:complexType>
<xs:sequence>
<xs:element ref="chronology" minOccurs="1" maxOccurs="1"/>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
<xs:attribute name="description" type="xs:string"/>
<xs:attribute name="owner" type="xs:string" use="required"/>
<xs:attribute name="code" type="xs:string" use="required"/>
<xs:attribute name="reference" type="xs:string"/>
</xs:complexType>
</xs:element>
<xs:element name="tierTableInstanceChronology">
<xs:complexType>
<xs:sequence>
<xs:element ref="chronology" minOccurs="1" maxOccurs="1"/>
</xs:sequence>
</xs:complexType>
</xs:element>
| Modifier and Type | Field and Description |
|---|---|
static int |
MAX_OUT_ATTRIBUTES
The maximum output attribute count: 5
|
| Constructor and Description |
|---|
TierTableModel()
Builds an empty TierTableModel.
|
TierTableModel(String code,
String description)
Builds a TierTableModel from a code and a description.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addCharacterData(String cData)
Adds character data to the content element.
|
void |
addChild(String tagName,
XMLMarshallable child)
Adds a child to the object, the
child representing
the marshallable object which must be added to the element. |
void |
addOutAttribute(TierTableOutAttributeModel attribute)
Adds an out attribute.
|
boolean |
checkValidity()
Returns true if the tier table is valid.
|
String |
getCode()
Gets the code.
|
String |
getDescription()
Gets the description.
|
TierTableInstanceModel |
getInstance()
Gets the instance.
|
ChronologyModel |
getInstanceChronology()
Gets the instance chronology.
|
Vector<TierTableOutAttributeModel> |
getOutAttributes()
Gets the out attributes.
|
String |
getOwner()
Gets the owner.
|
String |
getReference()
Gets the reference.
|
String |
getTagName()
Gets the XML tag name of the HCI model.
|
void |
marshal(XMLOutputter output)
Gives an XML representation of this object, including its children.
|
void |
removeOutAttribute(int index)
Removes an out attribute.
|
void |
setAttributes(XMLAttributes atts)
Sets the attributes of the XML representation of the element being
processed.
|
void |
setCode(String c)
Sets the code.
|
void |
setDescription(String d)
Sets the description.
|
void |
setInstance(TierTableInstanceModel i)
Sets the instance.
|
void |
setOutAttributes(Vector<TierTableOutAttributeModel> outAttributes)
Sets the out attributes.
|
void |
setOwner(String p)
Sets the owner.
|
void |
setReference(String r)
Sets the reference.
|
public static final int MAX_OUT_ATTRIBUTES
public String getReference()
public void setReference(String r)
r - The referencepublic TierTableInstanceModel getInstance()
public void setInstance(TierTableInstanceModel i)
i - The instancepublic String getCode()
public void setCode(String c)
c - The codepublic String getDescription()
public void setDescription(String d)
d - The descriptionpublic void setOutAttributes(Vector<TierTableOutAttributeModel> outAttributes)
outAttributes - A Vector of TierTableOutAttributeModel representing the out attributespublic Vector<TierTableOutAttributeModel> getOutAttributes()
TierTableOutAttributeModel representing the out attributespublic void addOutAttribute(TierTableOutAttributeModel attribute)
attribute - The out attribute to addpublic void removeOutAttribute(int index)
index - The index of the out attribute to removepublic String getOwner()
getOwner in interface ICatalogObjectpublic void setOwner(String p)
p - The data ownerpublic ChronologyModel getInstanceChronology()
TierTableInstanceModel elementspublic boolean checkValidity()
true if the tier table is valid, false otherwisepublic String getTagName()
ITagNameProvidergetTagName in interface ITagNameProviderpublic void setAttributes(XMLAttributes atts)
XMLMarshallablesetAttributes in interface XMLMarshallableatts - The XML attributes of the current elementpublic void addChild(String tagName, XMLMarshallable child)
XMLMarshallablechild representing
the marshallable object which must be added to the element.addChild in interface XMLMarshallabletagName - The name of tag for the childchild - The child to be addedpublic void addCharacterData(String cData)
XMLMarshallableaddCharacterData in interface XMLMarshallablecData - The character data to be addedpublic void marshal(XMLOutputter output)
XMLMarshallablemarshal in interface XMLMarshallableoutput - The XML output to marshal the object into