Attributes to customize XML serialization / Mapping between simple 4GL and XML data types detail |
Define the namespace of a variable in an XML document.
DEFINE myVar RECORD ATTRIBUTE(XMLName="Root", XMLNamespace="http://tempuri.org") attr1 INTEGER ATTRIBUTE(XMLAttribute,XMLName="Attr1"), val1 FLOAT ATTRIBUTE(XMLName="Val1", XMLNamespace="http://www.mycompany.com"), val2 INTEGER ATTRIBUTE(XMLName="Val2"), attr2 STRING ATTRIBUTE(XMLAttribute, XMLName="Attr2", XMLNamespace="http://anyuri.org") END RECORD
<fjs1:Root xmlns:fjs1="http://tempuri.org" Attr1="158" xmlns:fjs3="http://anyuri.org" fjs3:Attr2="Hello"> <fjs2:Val1 xmlns:fjs2="http://www.mycompany.com">0.5</fjs2:Val1> <fjs1:Val2>-18547</fjs1:Val2> </fjs1:Root>