Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
authorRich Tibbett <richt@opera.com>
Thu, 29 Aug 2013 11:01:15 +0200
changeset 4475e36d90b8960
parent 446 fdf57e69bf2b
child 448 865b6f93faac
Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
discovery-api/Overview.html
discovery-api/Overview.src.html
     1.1 --- a/discovery-api/Overview.html	Tue Aug 20 23:36:58 2013 +0300
     1.2 +++ b/discovery-api/Overview.html	Thu Aug 29 11:01:15 2013 +0200
     1.3 @@ -204,8 +204,12 @@
     1.4      <link rel="stylesheet"
     1.5            href="https://www.w3.org/StyleSheets/TR/W3C-ED">
     1.6    </head>
     1.7 -  <body class="h-entry">
     1.8 -    <div class="head">
     1.9 +  <body class="h-entry"
    1.10 +        role="document"
    1.11 +        id="respecDocument">
    1.12 +    <div class="head"
    1.13 +         role="contentinfo"
    1.14 +         id="respecHeader">
    1.15        <p>
    1.16          <a href="http://www.w3.org/"><img width="72"
    1.17               height="48"
    1.18 @@ -219,10 +223,10 @@
    1.19        </h1>
    1.20        <h2 property="dcterms:issued"
    1.21            datatype="xsd:dateTime"
    1.22 -          content="2013-08-11T22:14:32.000Z"
    1.23 -          id="w3c-editor-s-draft-12-august-2013">
    1.24 +          content="2013-08-29T06:58:44.000Z"
    1.25 +          id="w3c-editor-s-draft-29-august-2013">
    1.26          <abbr title="World Wide Web Consortium">W3C</abbr> Editor's Draft <time class="dt-published"
    1.27 -            datetime="2013-08-12">12 August 2013</time>
    1.28 +            datetime="2013-08-29">29 August 2013</time>
    1.29        </h2>
    1.30        <dl>
    1.31          <dt>
    1.32 @@ -279,7 +283,9 @@
    1.33               typeof="bibo:Chapter"
    1.34               resource="#abstract"
    1.35               rel="bibo:chapter">
    1.36 -      <h2>
    1.37 +      <h2 aria-level="1"
    1.38 +          role="heading"
    1.39 +          id="h2_abstract">
    1.40          Abstract
    1.41        </h2>
    1.42        <p>
    1.43 @@ -293,7 +299,9 @@
    1.44               typeof="bibo:Chapter"
    1.45               resource="#sotd"
    1.46               rel="bibo:chapter">
    1.47 -      <h2>
    1.48 +      <h2 aria-level="1"
    1.49 +          role="heading"
    1.50 +          id="h2_sotd">
    1.51          Status of This Document
    1.52        </h2>
    1.53        <p>
    1.54 @@ -336,10 +344,15 @@
    1.55        </p>
    1.56      </section>
    1.57      <section id="toc">
    1.58 -      <h2 class="introductory">
    1.59 +      <h2 class="introductory"
    1.60 +          aria-level="1"
    1.61 +          role="heading"
    1.62 +          id="h2_toc">
    1.63          Table of Contents
    1.64        </h2>
    1.65 -      <ul class="toc">
    1.66 +      <ul class="toc"
    1.67 +          role="directory"
    1.68 +          id="respecContents">
    1.69          <li class="tocline">
    1.70            <a href="#introduction"
    1.71                class="tocxref"><span class="secno">1.</span> Introduction</a>
    1.72 @@ -483,7 +496,9 @@
    1.73      </section>
    1.74      <section class="informative"
    1.75               id="introduction">
    1.76 -      <h2>
    1.77 +      <h2 aria-level="1"
    1.78 +          role="heading"
    1.79 +          id="h2_introduction">
    1.80          <span class="secno">1.</span> Introduction
    1.81        </h2>
    1.82        <p>
    1.83 @@ -513,8 +528,8 @@
    1.84        <p>
    1.85          If a service connectivity request is successful then the Web page is provided with a promise-based success
    1.86          callback with the all necessary information to communicate with the authorized Local-networked Service. If the
    1.87 -        request fails then the Web page will receive a promise-based error callback containing an error code describing
    1.88 -        the cause of Local-networked Service connectivity failure.
    1.89 +        request fails then the Web page will receive a promise-based error callback containing an error string
    1.90 +        describing the cause of Local-networked Service connectivity failure.
    1.91        </p>
    1.92        <p>
    1.93          Once connected to a Local-networked Service the Web page can send requests and receive responses to the
    1.94 @@ -579,7 +594,7 @@
    1.95  "pln"> e </span><span class="pun">)</span><span class="pln"> </span><span class="pun">{</span><span class="pln">
    1.96    console</span><span class="pun">.</span><span class="pln">log</span><span class="pun">(</span><span class=
    1.97  "pln"> </span><span class="str">"Error occurred: "</span><span class="pln"> </span><span class=
    1.98 -"pun">+</span><span class="pln"> e</span><span class="pun">.</span><span class="pln">code </span><span class=
    1.99 +"pun">+</span><span class="pln"> e</span><span class="pun">.</span><span class="pln">name </span><span class=
   1.100  "pun">);</span><span class="pln">
   1.101  </span><span class="pun">}</span><span class="pln">
   1.102  
   1.103 @@ -631,7 +646,9 @@
   1.104               typeof="bibo:Chapter"
   1.105               resource="#conformance"
   1.106               rel="bibo:chapter">
   1.107 -      <h2>
   1.108 +      <h2 aria-level="1"
   1.109 +          role="heading"
   1.110 +          id="h2_conformance">
   1.111          <span class="secno">2.</span> Conformance
   1.112        </h2>
   1.113        <p>
   1.114 @@ -684,7 +701,9 @@
   1.115             leaving the attribute on the object but making it return null or throw an exception is insufficient.
   1.116        </p>
   1.117        <section id="dependencies">
   1.118 -        <h3>
   1.119 +        <h3 aria-level="2"
   1.120 +            role="heading"
   1.121 +            id="h3_dependencies">
   1.122            <span class="secno">2.1</span> Dependencies
   1.123          </h3>This specification relies on several other underlying specifications.
   1.124          <dl>
   1.125 @@ -707,7 +726,9 @@
   1.126        </section>
   1.127      </section>
   1.128      <section id="terminology">
   1.129 -      <h2>
   1.130 +      <h2 aria-level="1"
   1.131 +          role="heading"
   1.132 +          id="h2_terminology">
   1.133          <span class="secno">3.</span> Terminology
   1.134        </h2>
   1.135        <p>
   1.136 @@ -773,7 +794,9 @@
   1.137        </ul>
   1.138      </section>
   1.139      <section id="security-and-privacy-considerations">
   1.140 -      <h2>
   1.141 +      <h2 aria-level="1"
   1.142 +          role="heading"
   1.143 +          id="h2_security-and-privacy-considerations">
   1.144          <span class="secno">4.</span> Security and privacy considerations
   1.145        </h2>
   1.146        <p>
   1.147 @@ -789,7 +812,9 @@
   1.148             express permission.
   1.149        </p>
   1.150        <section id="privacy-considerations-for-api-implementations">
   1.151 -        <h3>
   1.152 +        <h3 aria-level="2"
   1.153 +            role="heading"
   1.154 +            id="h3_privacy-considerations-for-api-implementations">
   1.155            <span class="secno">4.1</span> Privacy considerations for <abbr title=
   1.156            "Application Programming Interface">API</abbr> implementations
   1.157          </h3>
   1.158 @@ -828,7 +853,9 @@
   1.159        </section>
   1.160        <section class="informative"
   1.161                 id="additional-api-implementation-considerations">
   1.162 -        <h3>
   1.163 +        <h3 aria-level="2"
   1.164 +            role="heading"
   1.165 +            id="h3_additional-api-implementation-considerations">
   1.166            <span class="secno">4.2</span> Additional <abbr title="Application Programming Interface">API</abbr>
   1.167            implementation considerations
   1.168          </h3>
   1.169 @@ -854,7 +881,9 @@
   1.170        </section>
   1.171      </section>
   1.172      <section id="requesting-networked-services">
   1.173 -      <h2>
   1.174 +      <h2 aria-level="1"
   1.175 +          role="heading"
   1.176 +          id="h2_requesting-networked-services">
   1.177          <span class="secno">5.</span> Requesting networked services
   1.178        </h2>
   1.179        <pre class="widl">
   1.180 @@ -864,20 +893,16 @@
   1.181       href="http://dom.spec.whatwg.org/#promise">Promise</a> <a href=
   1.182       "#dom-navigator-getnetworkservices">getNetworkServices</a>( in any type );
   1.183  };
   1.184 +
   1.185  <a class="externalDFN"
   1.186       href=
   1.187       "http://www.whatwg.org/specs/web-apps/current-work/complete/timers.html#navigator">Navigator</a> implements <a href=
   1.188       "#navigatornetworkservice">NavigatorNetworkService</a>;
   1.189 -
   1.190 -[NoInterfaceObject]
   1.191 -interface <dfn id="navigatornetworkserviceerror">NavigatorNetworkServiceError</dfn> {
   1.192 -  const unsigned short <a href="#dom-navigatornetworkserviceerror-permission_denied">PERMISSION_DENIED_ERR</a> = 1;
   1.193 -  const unsigned short <a href="#dom-navigatornetworkserviceerror-unknown_type_prefix">UNKNOWN_TYPE_PREFIX_ERR</a> = 2;
   1.194 -  readonly attribute unsigned short <a href="#dom-navigatornetworkserviceerror-code">code</a>;
   1.195 -};
   1.196  </pre>
   1.197        <section id="methods">
   1.198 -        <h3>
   1.199 +        <h3 aria-level="2"
   1.200 +            role="heading"
   1.201 +            id="h3_methods">
   1.202            <span class="secno">5.1</span> Methods
   1.203          </h3>
   1.204          <dl class="domintro">
   1.205 @@ -945,12 +970,12 @@
   1.206                    below. Otherwise, reject <var>Network Service Promise</var> by running the <a href=
   1.207                    "http://dom.spec.whatwg.org/#concept-resolver-reject"
   1.208                    class="externalDFN">resolver reject algorithm</a> against the <var>Network Service Promise's
   1.209 -                  Resolver</var>, passing in a new <a href=
   1.210 -                  "#navigatornetworkserviceerror"><code>NavigatorNetworkServiceError</code></a> object whose <a href=
   1.211 -                  "#dom-navigatornetworkserviceerror-code"><code>code</code></a> attribute has the numeric value 2
   1.212 -                  (<a href=
   1.213 -                  "#dom-navigatornetworkserviceerror-unknown_type_prefix"><code>UNKNOWN_TYPE_PREFIX_ERR</code></a>) as
   1.214 -                  its argument, abort any remaining steps and return.
   1.215 +                  Resolver</var>, passing in a newly constructed <a href="http://dom.spec.whatwg.org/#domerror"
   1.216 +                  class="externalDFN"><code>DOMError</code></a> object whose <code>name</code> attribute has the string
   1.217 +                  value "UnknownTypePrefixError" (<a href=
   1.218 +                  "#dom-domerror-extensions-unknown_type_prefix"><code>UNKNOWN_TYPE_PREFIX_ERR</code></a>) and whose
   1.219 +                  <code>message</code> attribute has a helpful implementation-dependent message that explains this
   1.220 +                  error, abort any remaining steps and return.
   1.221              </li>
   1.222              <li>
   1.223                <em>Process</em>: Let <var>services found</var> be an empty array.
   1.224 @@ -984,12 +1009,12 @@
   1.225                    title="MAY">MAY</em> reject <var>Network Service Promise</var> by running the <a href=
   1.226                    "http://dom.spec.whatwg.org/#concept-resolver-reject"
   1.227                    class="externalDFN">resolver reject algorithm</a> against the <var>Network Service Promise's
   1.228 -                  Resolver</var>, passing in a new <a href=
   1.229 -                  "#navigatornetworkserviceerror"><code>NavigatorNetworkServiceError</code></a> object whose <a href=
   1.230 -                  "#dom-navigatornetworkserviceerror-code"><code>code</code></a> attribute has the numeric value 1
   1.231 -                  (<a href=
   1.232 -                  "#dom-navigatornetworkserviceerror-permission_denied"><code>PERMISSION_DENIED_ERR</code></a>) as its
   1.233 -                  argument, abort any remaining steps and return.
   1.234 +                  Resolver</var>, passing in a newly constructed <a href="http://dom.spec.whatwg.org/#domerror"
   1.235 +                  class="externalDFN"><code>DOMError</code></a> object whose <code>name</code> attribute has the string
   1.236 +                  value "PermissionDeniedError" (<a href=
   1.237 +                  "#dom-domerror-extensions-permission_denied"><code>PERMISSION_DENIED_ERR</code></a>) and whose
   1.238 +                  <code>message</code> attribute has a helpful implementation-dependent message that explains this
   1.239 +                  error, abort any remaining steps and return.
   1.240              </li>
   1.241              <li>The user agent <em class="rfc2119"
   1.242                    title="MUST NOT">MUST NOT</em> provide the entry script's origin with a <a href=
   1.243 @@ -1030,12 +1055,12 @@
   1.244                     title="MUST">MUST</em> reject <var>Network Service Promise</var> by running the <a href=
   1.245                     "http://dom.spec.whatwg.org/#concept-resolver-reject"
   1.246                     class="externalDFN">resolver reject algorithm</a> against the <var>Network Service Promise's
   1.247 -                   Resolver</var>, passing in a new <a href=
   1.248 -                   "#navigatornetworkserviceerror"><code>NavigatorNetworkServiceError</code></a> object whose <a href=
   1.249 -                   "#dom-navigatornetworkserviceerror-code"><code>code</code></a> attribute has the numeric value 1
   1.250 -                   (<a href=
   1.251 -                   "#dom-navigatornetworkserviceerror-permission_denied"><code>PERMISSION_DENIED_ERR</code></a>) as its
   1.252 -                   argument, abort any remaining steps and return.
   1.253 +                   Resolver</var>, passing in a newly constructed <a href="http://dom.spec.whatwg.org/#domerror"
   1.254 +                   class="externalDFN"><code>DOMError</code></a> object whose <code>name</code> attribute has the
   1.255 +                   string value "PermissionDeniedError" (<a href=
   1.256 +                   "#dom-domerror-extensions-permission_denied"><code>PERMISSION_DENIED_ERR</code></a>) and whose
   1.257 +                   <code>message</code> attribute has a helpful implementation-dependent message that explains this
   1.258 +                   error, abort any remaining steps and return.
   1.259                </p>
   1.260                <p>
   1.261                  If the user never responds or no previously-established user preference has been met, this algorithm
   1.262 @@ -1157,44 +1182,46 @@
   1.263          </div>
   1.264        </section>
   1.265        <section id="error-handling">
   1.266 -        <h3>
   1.267 +        <h3 aria-level="2"
   1.268 +            role="heading"
   1.269 +            id="h3_error-handling">
   1.270            <span class="secno">5.2</span> Error Handling
   1.271          </h3>
   1.272          <dl class="domintro">
   1.273            <dt>
   1.274 -            <var title="">error</var> . <code title="dom-NavigatorNetworkServiceError-code"><a href=
   1.275 -            "#dom-navigatornetworkserviceerror-code">code</a></code>
   1.276 +            <var title="">error</var> . <code title="dom-NavigatorNetworkServiceError-name"><a href=
   1.277 +            "#dom-domerror-extensions-name">name</a></code>
   1.278            </dt>
   1.279            <dd>
   1.280              <p>
   1.281 -              Returns the current error's error code. At the current time, this will be <code>1</code> or
   1.282 -              <code>2</code>, for which the corresponding error constants <a href=
   1.283 -              "#dom-navigatornetworkserviceerror-permission_denied"><code>PERMISSION_DENIED_ERR</code></a> and <a href=
   1.284 -              "#dom-navigatornetworkserviceerror-unknown_type_prefix"><code>UNKNOWN_TYPE_PREFIX_ERR</code></a> are
   1.285 -              defined.
   1.286 +              Returns the current error's error name. At the current time, this will be "PermissionDeniedError" or
   1.287 +              "UnknownTypePrefixError", for which the corresponding error constants <a href=
   1.288 +              "#dom-domerror-extensions-permission_denied"><code>PERMISSION_DENIED_ERR</code></a> and <a href=
   1.289 +              "#dom-domerror-extensions-unknown_type_prefix"><code>UNKNOWN_TYPE_PREFIX_ERR</code></a> are defined.
   1.290              </p>
   1.291            </dd>
   1.292          </dl>
   1.293          <p>
   1.294 -          The <dfn id="dom-navigatornetworkserviceerror-code"
   1.295 -             title="dom-navigatornetworkserviceerror-code"><code>code</code></dfn> attribute of a <a href=
   1.296 -             "#navigatornetworkserviceerror"><code>NavigatorNetworkServiceError</code></a> object <em class=
   1.297 -             "ct"><em class="rfc2119"
   1.298 -              title="MUST">MUST</em></em> return the code for the error, which will be one of the following:
   1.299 +          The <dfn id="dom-domerror-extensions-name"
   1.300 +             title="dom-domerror-extensions-name"><code>name</code></dfn> attribute of a <a href=
   1.301 +             "http://dom.spec.whatwg.org/#domerror"
   1.302 +             class="externalDFN"><code>DOMError</code></a> object returned from this <abbr title=
   1.303 +             "Application Programming Interface">API</abbr> <em class="ct"><em class="rfc2119"
   1.304 +              title="MUST">MUST</em></em> return the name for the error, which will be one of the following:
   1.305          </p>
   1.306          <dl>
   1.307            <dt>
   1.308 -            <dfn id="dom-navigatornetworkserviceerror-permission_denied"
   1.309 -                title="dom-navigatornetworkserviceerror-permission_denied"><code>PERMISSION_DENIED_ERR</code></dfn>
   1.310 -                (numeric value 1)
   1.311 +            <dfn id="dom-domerror-extensions-permission_denied"
   1.312 +                title="dom-domerror-extensions-permission_denied"><code>PERMISSION_DENIED_ERR</code></dfn> (DOMString
   1.313 +                value "PermissionDeniedError")
   1.314            </dt>
   1.315            <dd>
   1.316              The user or user agent denied the page permission to access any services.
   1.317            </dd>
   1.318            <dt>
   1.319 -            <dfn id="dom-navigatornetworkserviceerror-unknown_type_prefix"
   1.320 -                title="dom-navigatornetworkserviceerror-unknown_type_prefix"><code>UNKNOWN_TYPE_PREFIX_ERR</code></dfn>
   1.321 -                (numeric value 2)
   1.322 +            <dfn id="dom-domerror-extensions-unknown_type_prefix"
   1.323 +                title="dom-domerror-extensions-unknown_type_prefix"><code>UNKNOWN_TYPE_PREFIX_ERR</code></dfn>
   1.324 +                (DOMString value "UnknownTypePrefixError")
   1.325            </dt>
   1.326            <dd>
   1.327              No <a href="#dfn-valid-service-type"
   1.328 @@ -1204,7 +1231,9 @@
   1.329        </section>
   1.330      </section>
   1.331      <section id="obtaining-networked-services">
   1.332 -      <h2>
   1.333 +      <h2 aria-level="1"
   1.334 +          role="heading"
   1.335 +          id="h2_obtaining-networked-services">
   1.336          <span class="secno">6.</span> Obtaining networked services
   1.337        </h2>
   1.338        <p>
   1.339 @@ -1242,7 +1271,9 @@
   1.340       class="externalDFN">EventTarget</a>;
   1.341  </pre>
   1.342        <section id="attributes">
   1.343 -        <h3>
   1.344 +        <h3 aria-level="2"
   1.345 +            role="heading"
   1.346 +            id="h3_attributes">
   1.347            <span class="secno">6.1</span> Attributes
   1.348          </h3>
   1.349          <dl class="domintro">
   1.350 @@ -1287,7 +1318,9 @@
   1.351          </div>
   1.352        </section>
   1.353        <section id="methods-1">
   1.354 -        <h3>
   1.355 +        <h3 aria-level="2"
   1.356 +            role="heading"
   1.357 +            id="h3_methods-1">
   1.358            <span class="secno">6.2</span> Methods
   1.359          </h3>
   1.360          <dl class="domintro">
   1.361 @@ -1334,8 +1367,9 @@
   1.362          </p>
   1.363          <div class="note">
   1.364            <div class="note-title"
   1.365 +               aria-level="3"
   1.366                 role="heading"
   1.367 -               aria-level="4">
   1.368 +               id="h_note_1">
   1.369              <span>Note</span>
   1.370            </div>
   1.371            <p class="">
   1.372 @@ -1363,7 +1397,9 @@
   1.373          </p>
   1.374        </section>
   1.375        <section id="events">
   1.376 -        <h3>
   1.377 +        <h3 aria-level="2"
   1.378 +            role="heading"
   1.379 +            id="h3_events">
   1.380            <span class="secno">6.3</span> Events
   1.381          </h3>
   1.382          <p>
   1.383 @@ -1407,7 +1443,9 @@
   1.384        </section>
   1.385      </section>
   1.386      <section id="communicating-with-a-networked-service">
   1.387 -      <h2>
   1.388 +      <h2 aria-level="1"
   1.389 +          role="heading"
   1.390 +          id="h2_communicating-with-a-networked-service">
   1.391          <span class="secno">7.</span> Communicating with a networked service
   1.392        </h2>
   1.393        <p>
   1.394 @@ -1441,7 +1479,9 @@
   1.395       class="externalDFN">EventTarget</a>;
   1.396  </pre>
   1.397        <section id="attributes-1">
   1.398 -        <h3>
   1.399 +        <h3 aria-level="2"
   1.400 +            role="heading"
   1.401 +            id="h3_attributes-1">
   1.402            <span class="secno">7.1</span> Attributes
   1.403          </h3>
   1.404          <dl class="domintro">
   1.405 @@ -1526,7 +1566,9 @@
   1.406          </p>
   1.407        </section>
   1.408        <section id="states">
   1.409 -        <h3>
   1.410 +        <h3 aria-level="2"
   1.411 +            role="heading"
   1.412 +            id="h3_states">
   1.413            <span class="secno">7.2</span> States
   1.414          </h3>
   1.415          <dl class="domintro">
   1.416 @@ -1552,7 +1594,9 @@
   1.417          </p>
   1.418        </section>
   1.419        <section id="events-1">
   1.420 -        <h3>
   1.421 +        <h3 aria-level="2"
   1.422 +            role="heading"
   1.423 +            id="h3_events-1">
   1.424            <span class="secno">7.3</span> Events
   1.425          </h3>
   1.426          <p>
   1.427 @@ -1605,7 +1649,9 @@
   1.428        </section>
   1.429      </section>
   1.430      <section id="service-discovery">
   1.431 -      <h2>
   1.432 +      <h2 aria-level="1"
   1.433 +          role="heading"
   1.434 +          id="h2_service-discovery">
   1.435          <span class="secno">8.</span> Service Discovery
   1.436        </h2>
   1.437        <p>
   1.438 @@ -1831,7 +1877,9 @@
   1.439             <code>id</code> attribute as the only argument.
   1.440        </p>
   1.441        <section id="zeroconf-mdns-dns-sd">
   1.442 -        <h3>
   1.443 +        <h3 aria-level="2"
   1.444 +            role="heading"
   1.445 +            id="h3_zeroconf-mdns-dns-sd">
   1.446            <span class="secno">8.1</span> Zeroconf (<abbr title="Multicast DNS">mDNS</abbr> + <abbr title=
   1.447            "Domain Name System">DNS</abbr>-<abbr title="Service Discovery">SD</abbr>)
   1.448          </h3>
   1.449 @@ -1896,7 +1944,9 @@
   1.450          </ol>
   1.451        </section>
   1.452        <section id="simple-service-discovery-protocol-ssdp">
   1.453 -        <h3>
   1.454 +        <h3 aria-level="2"
   1.455 +            role="heading"
   1.456 +            id="h3_simple-service-discovery-protocol-ssdp">
   1.457            <span class="secno">8.2</span> Simple Service Discovery Protocol (<abbr title=
   1.458            "Simple Service Discovery Protocol">SSDP</abbr>)
   1.459          </h3>
   1.460 @@ -2289,7 +2339,9 @@
   1.461          </p>
   1.462        </section>
   1.463        <section id="discovery-and-launch-protocol-dial">
   1.464 -        <h3>
   1.465 +        <h3 aria-level="2"
   1.466 +            role="heading"
   1.467 +            id="h3_discovery-and-launch-protocol-dial">
   1.468            <span class="secno">8.3</span> Discovery and Launch Protocol (<abbr title=
   1.469            "Discovery and Launch Protocol">DIAL</abbr>)
   1.470          </h3>
   1.471 @@ -2444,7 +2496,9 @@
   1.472          </ol>
   1.473        </section>
   1.474        <section id="network-topology-monitoring">
   1.475 -        <h3>
   1.476 +        <h3 aria-level="2"
   1.477 +            role="heading"
   1.478 +            id="h3_network-topology-monitoring">
   1.479            <span class="secno">8.4</span> Network Topology Monitoring
   1.480          </h3>
   1.481          <div>
   1.482 @@ -2472,7 +2526,9 @@
   1.483        </section>
   1.484      </section>
   1.485      <section id="events-summary">
   1.486 -      <h2>
   1.487 +      <h2 aria-level="1"
   1.488 +          role="heading"
   1.489 +          id="h2_events-summary">
   1.490          <span class="secno">9.</span> Events Summary
   1.491        </h2>
   1.492        <p>
   1.493 @@ -2568,7 +2624,9 @@
   1.494        </table>
   1.495      </section>
   1.496      <section id="garbage-collection">
   1.497 -      <h2>
   1.498 +      <h2 aria-level="1"
   1.499 +          role="heading"
   1.500 +          id="h2_garbage-collection">
   1.501          <span class="secno">10.</span> Garbage collection
   1.502        </h2>
   1.503        <p>
   1.504 @@ -2578,8 +2636,9 @@
   1.505        </p>
   1.506        <div class="note">
   1.507          <div class="note-title"
   1.508 +             aria-level="2"
   1.509               role="heading"
   1.510 -             aria-level="3">
   1.511 +             id="h_note_2">
   1.512            <span>Note</span>
   1.513          </div>
   1.514          <p class="">
   1.515 @@ -2609,7 +2668,9 @@
   1.516        </p>
   1.517      </section>
   1.518      <section id="use-cases-and-requirements">
   1.519 -      <h2>
   1.520 +      <h2 aria-level="1"
   1.521 +          role="heading"
   1.522 +          id="h2_use-cases-and-requirements">
   1.523          <span class="secno">11.</span> Use Cases and Requirements
   1.524        </h2>
   1.525        <p>
   1.526 @@ -2685,7 +2746,9 @@
   1.527      </section>
   1.528      <section class="informative appendix"
   1.529               id="examples">
   1.530 -      <h2>
   1.531 +      <h2 aria-level="1"
   1.532 +          role="heading"
   1.533 +          id="h2_examples">
   1.534          <span class="secno">A.</span> Examples
   1.535        </h2>
   1.536        <p>
   1.537 @@ -3120,7 +3183,7 @@
   1.538  "pln"> error </span><span class="pun">)</span><span class="pln"> </span><span class="pun">{</span><span class="pln">
   1.539      debug</span><span class="pun">.</span><span class="pln">innerHTML </span><span class="pun">+=</span><span class=
   1.540  "pln"> </span><span class="str">"&lt;br&gt;An error occurred: "</span><span class="pln"> </span><span class=
   1.541 -"pun">+</span><span class="pln"> error</span><span class="pun">.</span><span class="pln">code</span><span class=
   1.542 +"pun">+</span><span class="pln"> error</span><span class="pun">.</span><span class="pln">name</span><span class=
   1.543  "pun">;</span><span class="pln">
   1.544    </span><span class="pun">}</span><span class="pln">
   1.545  </span><span class="tag">&lt;/script&gt;</span>
   1.546 @@ -3128,7 +3191,9 @@
   1.547        </div>
   1.548      </section>
   1.549      <section id="acknowledgements">
   1.550 -      <h2>
   1.551 +      <h2 aria-level="1"
   1.552 +          role="heading"
   1.553 +          id="h2_acknowledgements">
   1.554          <span class="secno">B.</span> Acknowledgements
   1.555        </h2>
   1.556        <p>
   1.557 @@ -3154,14 +3219,18 @@
   1.558               typeof="bibo:Chapter"
   1.559               resource="#references"
   1.560               rel="bibo:chapter">
   1.561 -      <h2>
   1.562 +      <h2 aria-level="1"
   1.563 +          role="heading"
   1.564 +          id="h2_references">
   1.565          <span class="secno">C.</span> References
   1.566        </h2>
   1.567        <section id="normative-references"
   1.568                 typeof="bibo:Chapter"
   1.569                 resource="#normative-references"
   1.570                 rel="bibo:chapter">
   1.571 -        <h3>
   1.572 +        <h3 aria-level="2"
   1.573 +            role="heading"
   1.574 +            id="h3_normative-references">
   1.575            <span class="secno">C.1</span> Normative references
   1.576          </h3>
   1.577          <dl class="bibliography"
   1.578 @@ -3186,8 +3255,9 @@
   1.579              [HTML5]
   1.580            </dt>
   1.581            <dd rel="dcterms:requires">
   1.582 -            Robin Berjon et al. <a href="http://www.w3.org/TR/html5/"><cite>HTML5</cite></a>. 17 December 2012. W3C
   1.583 -            Candidate Recommendation. URL: <a href="http://www.w3.org/TR/html5/">http://www.w3.org/TR/html5/</a>
   1.584 +            Robin Berjon; Steve Faulkner; Travis Leithead; Erika Doyle Navara; Edward O'Connor; Silvia Pfeiffer.
   1.585 +            <a href="http://www.w3.org/TR/html5/"><cite>HTML5</cite></a>. 6 August 2013. W3C Candidate Recommendation.
   1.586 +            URL: <a href="http://www.w3.org/TR/html5/">http://www.w3.org/TR/html5/</a>
   1.587            </dd>
   1.588            <dt id="bib-MDNS">
   1.589              [MDNS]
     2.1 --- a/discovery-api/Overview.src.html	Tue Aug 20 23:36:58 2013 +0300
     2.2 +++ b/discovery-api/Overview.src.html	Thu Aug 29 11:01:15 2013 +0200
     2.3 @@ -145,8 +145,8 @@
     2.4        <p>
     2.5          If a service connectivity request is successful then the Web page is provided with a promise-based success
     2.6          callback with the all necessary information to communicate with the authorized Local-networked Service. If the
     2.7 -        request fails then the Web page will receive a promise-based error callback containing an error code describing
     2.8 -        the cause of Local-networked Service connectivity failure.
     2.9 +        request fails then the Web page will receive a promise-based error callback containing an error string
    2.10 +        describing the cause of Local-networked Service connectivity failure.
    2.11        </p>
    2.12        <p>
    2.13          Once connected to a Local-networked Service the Web page can send requests and receive responses to the
    2.14 @@ -189,7 +189,7 @@
    2.15  }
    2.16  
    2.17  function error( e ) {
    2.18 -  console.log( "Error occurred: " + e.code );
    2.19 +  console.log( "Error occurred: " + e.name );
    2.20  }
    2.21  
    2.22  navigator.getNetworkServices('upnp:urn:schemas-upnp-org:service:ContentDirectory:1').then(showServices, error);
    2.23 @@ -397,17 +397,11 @@
    2.24       href="http://dom.spec.whatwg.org/#promise">Promise</a> <a href=
    2.25       "#dom-navigator-getnetworkservices">getNetworkServices</a>( in any type );
    2.26  };
    2.27 +
    2.28  <a class="externalDFN"
    2.29       href=
    2.30       "http://www.whatwg.org/specs/web-apps/current-work/complete/timers.html#navigator">Navigator</a> implements <a href=
    2.31       "#navigatornetworkservice">NavigatorNetworkService</a>;
    2.32 -
    2.33 -[NoInterfaceObject]
    2.34 -interface <dfn id="navigatornetworkserviceerror">NavigatorNetworkServiceError</dfn> {
    2.35 -  const unsigned short <a href="#dom-navigatornetworkserviceerror-permission_denied">PERMISSION_DENIED_ERR</a> = 1;
    2.36 -  const unsigned short <a href="#dom-navigatornetworkserviceerror-unknown_type_prefix">UNKNOWN_TYPE_PREFIX_ERR</a> = 2;
    2.37 -  readonly attribute unsigned short <a href="#dom-navigatornetworkserviceerror-code">code</a>;
    2.38 -};
    2.39  </pre>
    2.40        <section>
    2.41          <h2>
    2.42 @@ -472,12 +466,12 @@
    2.43              below. Otherwise, reject <var>Network Service Promise</var> by running the <a href=
    2.44              "http://dom.spec.whatwg.org/#concept-resolver-reject"
    2.45                    class="externalDFN">resolver reject algorithm</a> against the <var>Network Service Promise's
    2.46 -                  Resolver</var>, passing in a new <a href=
    2.47 -                  "#navigatornetworkserviceerror"><code>NavigatorNetworkServiceError</code></a> object whose <a href=
    2.48 -                  "#dom-navigatornetworkserviceerror-code"><code>code</code></a> attribute has the numeric value 2
    2.49 -                  (<a href=
    2.50 -                  "#dom-navigatornetworkserviceerror-unknown_type_prefix"><code>UNKNOWN_TYPE_PREFIX_ERR</code></a>) as
    2.51 -                  its argument, abort any remaining steps and return.
    2.52 +                  Resolver</var>, passing in a newly constructed <a href="http://dom.spec.whatwg.org/#domerror"
    2.53 +                  class="externalDFN"><code>DOMError</code></a> object whose <code>name</code> attribute has the string
    2.54 +                  value "UnknownTypePrefixError" (<a href=
    2.55 +                  "#dom-domerror-extensions-unknown_type_prefix"><code>UNKNOWN_TYPE_PREFIX_ERR</code></a>) and whose
    2.56 +                  <code>message</code> attribute has a helpful implementation-dependent message that explains this
    2.57 +                  error, abort any remaining steps and return.
    2.58              </li>
    2.59              <li>
    2.60                <em>Process</em>: Let <var>services found</var> be an empty array.
    2.61 @@ -509,12 +503,12 @@
    2.62              platform limitations, the <a>user agent</a> MAY reject <var>Network Service Promise</var> by running the
    2.63              <a href="http://dom.spec.whatwg.org/#concept-resolver-reject"
    2.64                    class="externalDFN">resolver reject algorithm</a> against the <var>Network Service Promise's
    2.65 -                  Resolver</var>, passing in a new <a href=
    2.66 -                  "#navigatornetworkserviceerror"><code>NavigatorNetworkServiceError</code></a> object whose <a href=
    2.67 -                  "#dom-navigatornetworkserviceerror-code"><code>code</code></a> attribute has the numeric value 1
    2.68 -                  (<a href=
    2.69 -                  "#dom-navigatornetworkserviceerror-permission_denied"><code>PERMISSION_DENIED_ERR</code></a>) as its
    2.70 -                  argument, abort any remaining steps and return.
    2.71 +                  Resolver</var>, passing in a newly constructed <a href="http://dom.spec.whatwg.org/#domerror"
    2.72 +                  class="externalDFN"><code>DOMError</code></a> object whose <code>name</code> attribute has the string
    2.73 +                  value "PermissionDeniedError" (<a href=
    2.74 +                  "#dom-domerror-extensions-permission_denied"><code>PERMISSION_DENIED_ERR</code></a>) and whose
    2.75 +                  <code>message</code> attribute has a helpful implementation-dependent message that explains this
    2.76 +                  error, abort any remaining steps and return.
    2.77              </li>
    2.78              <li>The user agent MUST NOT provide the entry script's origin with a <a href=
    2.79              "#networkservices"><code>NetworkServices</code></a> object without prior permission given by the user.
    2.80 @@ -543,12 +537,12 @@
    2.81                  MUST reject <var>Network Service Promise</var> by running the <a href=
    2.82                  "http://dom.spec.whatwg.org/#concept-resolver-reject"
    2.83                     class="externalDFN">resolver reject algorithm</a> against the <var>Network Service Promise's
    2.84 -                   Resolver</var>, passing in a new <a href=
    2.85 -                   "#navigatornetworkserviceerror"><code>NavigatorNetworkServiceError</code></a> object whose <a href=
    2.86 -                   "#dom-navigatornetworkserviceerror-code"><code>code</code></a> attribute has the numeric value 1
    2.87 -                   (<a href=
    2.88 -                   "#dom-navigatornetworkserviceerror-permission_denied"><code>PERMISSION_DENIED_ERR</code></a>) as its
    2.89 -                   argument, abort any remaining steps and return.
    2.90 +                   Resolver</var>, passing in a newly constructed <a href="http://dom.spec.whatwg.org/#domerror"
    2.91 +                   class="externalDFN"><code>DOMError</code></a> object whose <code>name</code> attribute has the
    2.92 +                   string value "PermissionDeniedError" (<a href=
    2.93 +                   "#dom-domerror-extensions-permission_denied"><code>PERMISSION_DENIED_ERR</code></a>) and whose
    2.94 +                   <code>message</code> attribute has a helpful implementation-dependent message that explains this
    2.95 +                   error, abort any remaining steps and return.
    2.96                </p>
    2.97                <p>
    2.98                  If the user never responds or no previously-established user preference has been met, this algorithm
    2.99 @@ -656,38 +650,38 @@
   2.100          </h3>
   2.101          <dl class="domintro">
   2.102            <dt>
   2.103 -            <var title="">error</var> . <code title="dom-NavigatorNetworkServiceError-code"><a href=
   2.104 -            "#dom-navigatornetworkserviceerror-code">code</a></code>
   2.105 +            <var title="">error</var> . <code title="dom-NavigatorNetworkServiceError-name"><a href=
   2.106 +            "#dom-domerror-extensions-name">name</a></code>
   2.107            </dt>
   2.108            <dd>
   2.109              <p>
   2.110 -              Returns the current error's error code. At the current time, this will be <code>1</code> or
   2.111 -              <code>2</code>, for which the corresponding error constants <a href=
   2.112 -              "#dom-navigatornetworkserviceerror-permission_denied"><code>PERMISSION_DENIED_ERR</code></a> and <a href=
   2.113 -              "#dom-navigatornetworkserviceerror-unknown_type_prefix"><code>UNKNOWN_TYPE_PREFIX_ERR</code></a> are
   2.114 -              defined.
   2.115 +              Returns the current error's error name. At the current time, this will be "PermissionDeniedError" or
   2.116 +              "UnknownTypePrefixError", for which the corresponding error constants <a href=
   2.117 +              "#dom-domerror-extensions-permission_denied"><code>PERMISSION_DENIED_ERR</code></a> and <a href=
   2.118 +              "#dom-domerror-extensions-unknown_type_prefix"><code>UNKNOWN_TYPE_PREFIX_ERR</code></a> are defined.
   2.119              </p>
   2.120            </dd>
   2.121          </dl>
   2.122          <p>
   2.123 -          The <dfn id="dom-navigatornetworkserviceerror-code"
   2.124 -             title="dom-navigatornetworkserviceerror-code"><code>code</code></dfn> attribute of a <a href=
   2.125 -             "#navigatornetworkserviceerror"><code>NavigatorNetworkServiceError</code></a> object <em class=
   2.126 -             "ct">MUST</em> return the code for the error, which will be one of the following:
   2.127 +          The <dfn id="dom-domerror-extensions-name"
   2.128 +             title="dom-domerror-extensions-name"><code>name</code></dfn> attribute of a <a href=
   2.129 +             "http://dom.spec.whatwg.org/#domerror"
   2.130 +             class="externalDFN"><code>DOMError</code></a> object returned from this API <em class="ct">MUST</em>
   2.131 +             return the name for the error, which will be one of the following:
   2.132          </p>
   2.133          <dl>
   2.134            <dt>
   2.135 -            <dfn id="dom-navigatornetworkserviceerror-permission_denied"
   2.136 -                title="dom-navigatornetworkserviceerror-permission_denied"><code>PERMISSION_DENIED_ERR</code></dfn>
   2.137 -                (numeric value 1)
   2.138 +            <dfn id="dom-domerror-extensions-permission_denied"
   2.139 +                title="dom-domerror-extensions-permission_denied"><code>PERMISSION_DENIED_ERR</code></dfn> (DOMString
   2.140 +                value "PermissionDeniedError")
   2.141            </dt>
   2.142            <dd>
   2.143              The user or user agent denied the page permission to access any services.
   2.144            </dd>
   2.145            <dt>
   2.146 -            <dfn id="dom-navigatornetworkserviceerror-unknown_type_prefix"
   2.147 -                title="dom-navigatornetworkserviceerror-unknown_type_prefix"><code>UNKNOWN_TYPE_PREFIX_ERR</code></dfn>
   2.148 -                (numeric value 2)
   2.149 +            <dfn id="dom-domerror-extensions-unknown_type_prefix"
   2.150 +                title="dom-domerror-extensions-unknown_type_prefix"><code>UNKNOWN_TYPE_PREFIX_ERR</code></dfn>
   2.151 +                (DOMString value "UnknownTypePrefixError")
   2.152            </dt>
   2.153            <dd>
   2.154              No <a>valid service type</a> tokens were provided in the method invocation.
   2.155 @@ -2091,7 +2085,7 @@
   2.156    }
   2.157  
   2.158    function errorCallback( error ) {
   2.159 -    debug.innerHTML += "&lt;br&gt;An error occurred: " + error.code;
   2.160 +    debug.innerHTML += "&lt;br&gt;An error occurred: " + error.name;
   2.161    }
   2.162  &lt;/script&gt;
   2.163  </pre>