Runtime tools : Core components : Formatters : Concepts : Built-in FormatElements : Special Format Element
  
Special Format Element
There are two format elements that do not extend CompositeFormat, FieldFormat or BaseDecorator. The special Format Element implements are com.ibm.btt.format.impl.FormatDefine and com.ibm.btt.format.impl.ReferenceFormat. They implement com.ibm.btt.format.FormatElement directly.
Classes, attributes and sample definitions
 
ClassSample definition
Attributes
FormatDefine
(used as a root format element in the format definition)
<format id="PersonFormat">
  <record>
    <fString dataName="name" encoding="cp937"/>
     <selfLength/>
       <fInteger dataName="age" byteOrdering="host"/>
     <selfLength/>
  </record>
</format>
id:
a String that represents the id of the format definition.
ReferenceFormat
(handles the reference relationship between format definitions)
<format id="AnotherFormat">
  <record>
    <fString dataName="field1" encoding="cp937"/>
    <selfLength/>
      <refFmt dataName="field2" refId="PersonFormat"/>
    <selfLength/>
  </record>
</format>
refId:
a String that represents the id of the referenced format element.
Go up to
Built-in FormatElements