Name
xs:gDay
Synopsis
The xs:gDay
type represents a certain day of the month such as
the 14th or the 23rd in no particular month. The format used is
—- DD
plus an
optional time zone suffix in the form
hh:mm
or Z
to indicate Coordinated Universal Time
(UTC). These are all valid xs:gDay
values:
---01
---28
---29Z
---31+02:00
---15-11:00
The g indicates that the day is given
in the Gregorian calendar. Schema date types are not
localizable to non-Gregorian calendars. If you need a different
calendar, you’ll need to derive from xs:string
using the pattern
facet.
Constraining facets that apply to xs:gDay
are minInclusive
, maxInclusive
, minExclusive
, maxExclusive
, pattern
, enumeration
, and whiteSpace
. However, if the time zones
are not specified, it may not be possible to conclusively
determine whether one day is greater than or less than another. If
time zones are specified, days are compared by when they start.
Thus ---29-05:00
is greater
than ---29Z
, which is greater
than ---29+02:00
.
Get XML in a Nutshell, 3rd Edition 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.