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.

Example

DEFINE myStr STRING ATTRIBUTES(XSDString, XSDPattern="A.*Z",
  XMLName="MyString")
DEFINE myZipCode INTEGER ATTRIBUTES(XSDInt, XSDPattern="[0-9]{5}",
  XMLName="MyZipCode")
DEFINE myOtherZipCode INTEGER ATTRIBUTES(XSDInt,
 XSDPattern="\\d{5}", XMLName="myOtherZipCode") # regex is \d{5} see note