Name

xs:gYear — Period of one year.

Derived from:

xs:anySimpleType

Primary:

xs:gYear

Known subtypes:

none

Facets:

xs:enumeration, xs:maxExclusive, xs:maxInclusive, xs:minExclusive, xs:minInclusive, xs:pattern, xs:whiteSpace

<xs:simpleType name="gYear" id="gYear">
  <xs:restriction base="xs:anySimpleType">
    <xs:whiteSpace value="collapse" fixed="true"/>
  </xs:restriction>
</xs:simpleType>

Description

The value space of xs:gYear is the period of one calendar year (such as the year 2002); its lexical space follows the ISO 8601 syntax for such periods (i.e., “YYYY”) with an optional timezone.

Restrictions

The duration (one year) is fixed, and no calendars other than the Gregorian are supported.

Example

Valid values include "2001", "2001+02:00", "2001Z", "2001+00:00", "-2001", or "-20000".

The following values would be invalid: "01" (the century part is missing) or "2001-12" (month parts are forbidden).

Get XML Schema now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.