This document describes the namespace
http://www.w3.org/2005/xpath-datatypes of the
XQuery 1.0
and XPath 2.0 Data Model specification
(September 2005 version).
For updated information, please refer to the latest version of the XQuery 1.0 and XPath 2.0 Data Model specification.
This document describes the names that are defined in this namespace at the time of publication. The W3C reserves the right to define additional names in this namespace in the future. XQuery 1.0 and XPath 2.0 Data Model is the only specification which may amend this namespace.
An XML Schema document describes this namespace.
The following names are defined:
untypedThe datatype xdt:untyped denotes the dynamic type of an element node that has not been validated, or has been validated in skip mode. No predefined types are derived from xdt:untyped.
untypedAtomicThe datatype xdt:untypedAtomic denotes untyped atomic
data, such as text that has not been assigned a more specific type. An
attribute that has been validated in skip mode is represented in the Data
Model by an attribute node with the type xdt:untypedAtomic. No
predefined types are derived from xdt:untypedAtomic.
anyAtomicTypeThe datatype xdt:anyAtomicType is an atomic type that
includes all atomic values (and no values that are not atomic). Its
base type is xs:anySimpleType from which all simple
types, including atomic, list, and union types are derived. All
primitive atomic types, such as xs:integer and
xs:string, have xdt:anyAtomicType
as their base type.
dayTimeDurationThe type xdt:dayTimeDuration is derived from
xs:duration by restricting its lexical representation to
contain only the days, hours, minutes and seconds components. The
value space of xdt:dayTimeDuration is the set of
fractional second values. The components of
xdt:dayTimeDuration correspond to the day, hour, minute
and second components defined in Section 5.5.3.2 of ISO 8601,
, respectively. xdt:dayTimeDuration is
derived from xs:duration as follows:
<xs:simpleType name='dayTimeDuration'>
<xs:restriction base='xs:duration'>
<xs:pattern value="[^YM]*[DT].*"/>
</xs:restriction>
</xs:simpleType>yearMonthDurationThe type xdt:yearMonthDuration is derived from
xs:duration by restricting its lexical representation to
contain only the year and month components. The value space of
xdt:yearMonthDuration is the set of
xs:integer month values. The year and month components of
xdt:yearMonthDuration correspond to the Gregorian year
and month components defined in section 5.5.3.2 of ISO 8601,
respectively.
The type yearMonthDuration is derived from
xs:duration as follows:
<xs:simpleType name='yearMonthDuration'>
<xs:restriction base='xs:duration'>
<xs:pattern value="[^DT]*"/>
</xs:restriction>
</xs:simpleType>