XML Tutorial/XML Schema/duration
The duration datatype represents a duration
<source lang="xml">
<xsd:element name="vacation">
<xsd:simpleType> <xsd:restriction base="xsd:duration"> <xsd:pattern value="P\d+D\d+H\d+M\d+S"/> </xsd:restriction> </xsd:simpleType>
</xsd:element>
<vacation>P10D2H30M45S</vacation></source>