<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body><p><anchor-end xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:anchor="2" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:">[2]</anchor-end> <anchor xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:">XML Schema</anchor> の <dfn><code class="XML" xml:lang="en"><anchor xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:">xs:duration</anchor></code></dfn>
は、 <anchor xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:">ISO 8601</anchor> をベースに定義された<anchor xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:">時間</anchor>を表す<anchor xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:">データ型</anchor>です。</p><section><h1>仕様書</h1><refs xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:"><ul xmlns="http://www.w3.org/1999/xhtml"><li><anchor-end xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:anchor="3" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:">[3]</anchor-end> <cite xml:lang="EN">W3C XML Schema Definition Language (XSD) 1.1 Part 2: Datatypes</cite> (<time>2012-04-04 21:34:51 +09:00</time> 版) <anchor-external xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resScheme="URI" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resParameter="http://www.w3.org/TR/xmlschema11-2/#duration">http://www.w3.org/TR/xmlschema11-2/#duration</anchor-external></li></ul></refs></section><section><h1>値空間</h1><p><anchor-end xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:anchor="4" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:">[4]</anchor-end> 値は、<dfn><rubyb xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:">月数<rt xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">months</rt></rubyb></dfn>と<dfn><rubyb xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:">秒数<rt xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">seconds</rt></rubyb></dfn>で構成されます。
それぞれ<anchor xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:">整数</anchor>と<anchor xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:">十進数</anchor>で、両者の<anchor xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:">符号</anchor>は一致していなければ<anchor xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:"><strong xmlns="http://www.w3.org/1999/xhtml">なりません</strong></anchor>。 <src xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:10:"><anchor-internal xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:anchor="3" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:">&gt;&gt;3</anchor-internal></src></p></section><section><h1>字句空間</h1><p><anchor-end xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:anchor="5" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:">[5]</anchor-end> <anchor xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:">字句空間</anchor>は、次の<anchor xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:">正規表現</anchor>に<anchor xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:">一致</anchor>する<anchor xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:">文字列</anchor>です <src xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:10:"><anchor-internal xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:anchor="3" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:">&gt;&gt;3</anchor-internal></src>。</p><blockquote><pre class="regexp code">-?P( ( ( [0-9]+Y([0-9]+M)?([0-9]+D)?
       | ([0-9]+M)([0-9]+D)?
       | ([0-9]+D)
       )
       (T ( ([0-9]+H)([0-9]+M)?([0-9]+(\.[0-9]+)?S)?
          | ([0-9]+M)([0-9]+(\.[0-9]+)?S)?
          | ([0-9]+(\.[0-9]+)?S)
          )
       )?
    )
  | (T ( ([0-9]+H)([0-9]+M)?([0-9]+(\.[0-9]+)?S)?
       | ([0-9]+M)([0-9]+(\.[0-9]+)?S)?
       | ([0-9]+(\.[0-9]+)?S)
       )
    )
  )</pre></blockquote></section><section><h1>関連</h1><p><sw-see xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:"> <anchor>XML Schema暦</anchor> </sw-see></p><p><anchor-end xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:anchor="6" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:">[6]</anchor-end> <anchor xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:">HTMLの時間形式</anchor>と同じく <anchor xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:">ISO 8601の時間形式</anchor>をベースにしていますが、
<anchor xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:">HTML</anchor> とは違って、<ul><li>全体を負にできます</li><li>Y や M による指定ができます</li></ul></p><p><anchor-end xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:anchor="7" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:">[7]</anchor-end> <anchor xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:">妥当なvEvent時間文字列</anchor>もやはり <anchor xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:">ISO 8601の時間形式</anchor>ですが、
<anchor xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:">vEvent</anchor> とは違って<ul><li>全体を負にできます</li><li>Y や M による指定ができます</li><li>H と S だけで M なしの指定ができます</li><li>W による指定ができません</li><li>小数以下の秒を指定できます</li></ul></p><p><anchor-end xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:anchor="8" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:">[8]</anchor-end> <anchor xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:">派生型</anchor>として <code><anchor xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:">xs:dayTimeDuration</anchor></code> と <code><anchor xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:">xs:yearMonthDuration</anchor></code> があります。</p></section><section><h1>歴史</h1><refs xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:"><ul xmlns="http://www.w3.org/1999/xhtml"><li><anchor-end xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:anchor="1" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:">[1]</anchor-end> <cite xml:lang="EN">W3C XML Schema Definition Language (XSD) 1.1 Part 2: Datatypes</cite>
( (<time>2012-04-05 06:34:51 +09:00</time> 版))
<anchor-external xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resScheme="URI" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resParameter="http://www.w3.org/TR/2012/REC-xmlschema11-2-20120405/#duration">http://www.w3.org/TR/2012/REC-xmlschema11-2-20120405/#duration</anchor-external></li></ul></refs><p><anchor-end xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:anchor="9" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:">[9]</anchor-end> <cite xml:lang="EN">W3C XML Schema Definition Language (XSD) 1.1 Part 2: Datatypes</cite>
( (<time>2012-04-04 21:34:51 +09:00</time> 版))
<anchor-external xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resScheme="URI" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resParameter="http://www.w3.org/TR/xmlschema11-2/#partial-implementation">http://www.w3.org/TR/xmlschema11-2/#partial-implementation</anchor-external></p><p><anchor-end xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:anchor="10" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:">[10]</anchor-end> <cite xml:lang="EN">W3C XML Schema Definition Language (XSD) 1.1 Part 2: Datatypes</cite>
( (<time>2012-04-04 21:34:51 +09:00</time> 版))
<anchor-external xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resScheme="URI" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resParameter="http://www.w3.org/TR/xmlschema11-2/#sec-dt-arith">http://www.w3.org/TR/xmlschema11-2/#sec-dt-arith</anchor-external></p><p><anchor-end xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:anchor="11" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:">[11]</anchor-end> <cite xml:lang="en">README.md | master | Chris Lord / gaia-navigator | GitLab</cite>
(<time>2015-06-10 21:26:19 +09:00</time> 版)
<anchor-external xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resScheme="URI" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resParameter="https://gitlab.com/Cwiiis/gaia-navigator/blob/master/README.md">https://gitlab.com/Cwiiis/gaia-navigator/blob/master/README.md</anchor-external></p><p><anchor-end xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:anchor="12" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:">[12]</anchor-end> <cite xml:lang="EN">XPath and XQuery Functions and Operators 3.1</cite>
(<time>2017-03-21 16:02:06 +09:00</time>)
<anchor-external xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resScheme="URI" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resParameter="https://www.w3.org/TR/2017/REC-xpath-functions-31-20170321/#duration-subtypes">https://www.w3.org/TR/2017/REC-xpath-functions-31-20170321/#duration-subtypes</anchor-external></p><figure class="quote"><figcaption><anchor-end xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:anchor="13" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:">[13]</anchor-end> <cite xml:lang="en">Activity Vocabulary</cite>
(<time>2017-05-21 23:50:36 +09:00</time>)
<anchor-external xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resScheme="URI" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resParameter="https://w3c.github.io/activitystreams/vocabulary/#dfn-duration">https://w3c.github.io/activitystreams/vocabulary/#dfn-duration</anchor-external></figcaption><blockquote><p>The value must be expressed as an xsd:duration as defined by <strong>[</strong> xmlschema11-2<strong>]</strong>, section 3.3.6 (e.g. a period of 5 seconds is represented as &quot;PT5S&quot;).</p></blockquote></figure><figure class="quote"><figcaption><anchor-end xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:anchor="14" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:">[14]</anchor-end> <cite xml:lang="ja">データ コントラクト スキーマの参照</cite>
(<time>2017-06-01 22:06:11 +09:00</time>)
<anchor-external xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resScheme="URI" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resParameter="https://msdn.microsoft.com/ja-jp/library/ms733112(v=vs.110).aspx">https://msdn.microsoft.com/ja-jp/library/ms733112(v=vs.110).aspx</anchor-external></figcaption><blockquote><p>&lt;!-- xs:duration is restricted to an ordered value space, </p><p>to map to System.TimeSpan --&gt;</p><p><anchor-external xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resScheme="URI" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resParameter="xs:element name=&quot;duration&quot; nillable=&quot;true&quot; type=&quot;tns:duration&quot;/">xs:element name=&quot;duration&quot; nillable=&quot;true&quot; type=&quot;tns:duration&quot;/</anchor-external></p><p><anchor-external xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resScheme="URI" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resParameter="xs:simpleType name=&quot;duration&quot;">xs:simpleType name=&quot;duration&quot;</anchor-external></p><p><anchor-external xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resScheme="URI" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resParameter="xs:restriction base=&quot;xs:duration&quot;">xs:restriction base=&quot;xs:duration&quot;</anchor-external></p><p><anchor-external xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resScheme="URI" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resParameter="xs:pattern ">xs:pattern </anchor-external></p><p>value=&quot;\-?P(\d*D)?(T(\d*H)?(\d*M)?(\d*(\.\d*)?S)?)?&quot;/&gt;</p><p><anchor-external xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resScheme="URI" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resParameter="xs:minInclusive value=&quot;-P10675199DT2H48M5.4775808S&quot;/">xs:minInclusive value=&quot;-P10675199DT2H48M5.4775808S&quot;/</anchor-external></p><p><anchor-external xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resScheme="URI" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resParameter="xs:maxInclusive value=&quot;P10675199DT2H48M5.4775807S&quot;/">xs:maxInclusive value=&quot;P10675199DT2H48M5.4775807S&quot;/</anchor-external></p><p>&lt;/xs:restriction&gt;</p><p>&lt;/xs:simpleType&gt;</p></blockquote></figure><figure class="quote"><figcaption><anchor-end xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:anchor="15" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:">[15]</anchor-end> <cite xml:lang="en">Compose file version 3 reference | Docker Documentation</cite>
( (<time>2017-06-10 02:19:31 +09:00</time>))
<anchor-external xmlns="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resScheme="URI" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:resParameter="https://docs.docker.com/compose/compose-file/#specifying-durations">https://docs.docker.com/compose/compose-file/#specifying-durations</anchor-external></figcaption><blockquote><p>Some configuration options, such as the interval and timeout sub-options for healthcheck, accept a duration as a string in a format that looks like this:</p><p>2.5s</p><p>10s</p><p>1m30s</p><p>2h32m</p><p>5h34m56s</p><p>The supported units are us, ms, s, m and h.</p></blockquote></figure></section></body></html>