XML Schema list
Element
Definition and Usage
The list
element defines a collection of single simpleType
definitions.
Element Information
- Parent element:
simpleType
Syntax
(? The question mark indicates that the element can occur zero or one time within the list
element.)
Attribute | Description |
---|---|
id | Optional. Specifies a unique ID for the element. |
itemType | The name of a built-in data type or simpleType element defined in this schema (or in another schema indicated by the specified namespace). The simpleType element containing the list element is derived from the simple type specified by the list value. The list value must be a qualified name (QName). This attribute is required unless the content includes a simpleType element, in which case it is not allowed. |
any attributes | Optional. Specifies any other attributes with non-schema namespaces. |
Example 1
The following example shows a simple type for a list of integers:
Note: Spaces are used as separators for list items.
Example 2
The following example shows a simple type for a list of strings: