XSDPattern

Define a regular expression the value has to match to be serialized or deserialized without any error.

Note:
  1. The regular expression is defined in the XML Schema Part 2 specification available here.
  2. Backslash characters '\' in a regular expression must be escaped by duplicating it.
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