Examples of simple type and complex type parameters |
Example Suppose the XML of a Person complex type looks like the following:
The corresponding XML schema definition looks like the following:
In this case, the Person XML element is of the Persons complexType. You can define your own simpleType element, but a simpleType cannot contain multiple elements or attributes. The simpleType element is usually defined to represent a restriction on the data type. Example Here is the definition for an Age simpleType with valid values between 1 and 120:
|