DEFLines

TheDEFlines control the generation of the XML document.

The syntax of the XML DEF line is:

 _DEF <表名> \ [<属性名称> <属性类型>] *

The valid values for are: xml_char(width), xml_int32, xml_real32, xml_decimal(width, decimal), xml_boolean, xml_real64, and xml_xml.

ADEFline specifies the form an element takes in the output XML document that represents a table row. The element type is defined in the generated XML Schema document as a Complex Type definition.

例如,下面的DEF线:

XML_DEF row \ area xml_real64 \ code xml_char(5) \ num xml_decimal(3,0) fragment xml_xml

generates in the XML Schema document the following XML Schema Complex Type:

                

对应的FME功能DEFline, that is, a feature with feature type, will be written in the outputDATASET文档:

 28002.325 MX02 345  _  

Note:该示例假设TARGET_NS_PREFIX已被设置为fme这是默认值。

The “fragment” attribute with “xml_xml” type assumes an XML document as its value. Note that in the example gml prefix must’ve also been bound to a namespace URI in a namespace declaration in the root element, the XML_NAMESPACE_DECLARATIONS directive may be used to add namespace declarations on the root element.

如果XML_DEF行包含被设置为xml_xml类型则其对应的复杂类型定义将与被定义的多个属性“的xs:任何”通配符,例如,给定的DEF行:

XML_DEF行\一个xml_xml \ b xml_char(5)\ C xml_xml

所述的.xsd文档中的对应的复杂类型定义就变成: