Attributes to customize XML serialization / Mapping between simple 4GL and XML data types detail |
Define a regular expression the value has to match to be serialized or deserialized without any error.
DEFINE myStr STRING ATTRIBUTE(XSDString, XSDPattern="A.*Z", XMLName="MyString")
DEFINE myZipCode INTEGER ATTRIBUTE(XSDInt, XSDPattern="[0-9]{5}", XMLName="MyZipCode")
DEFINE myOtherZipCode INTEGER ATTRIBUTE(XSDInt, XSDPattern="\\d{5}", XMLName="myOtherZipCode") # regex is \d{5} see note