[html5] r3337 - [e] (0) Try to document the appcache model.

whatwg at whatwg.org whatwg at whatwg.org
Mon Jun 29 02:59:04 PDT 2009


Author: ianh
Date: 2009-06-29 02:59:02 -0700 (Mon, 29 Jun 2009)
New Revision: 3337

Modified:
   index
   source
Log:
[e] (0) Try to document the appcache model.

Modified: index
===================================================================
--- index	2009-06-29 00:59:25 UTC (rev 3336)
+++ index	2009-06-29 09:59:02 UTC (rev 3337)
@@ -700,7 +700,9 @@
      <li><a href=#manually-releasing-the-storage-mutex><span class=secno>6.8.3 </span>Manually releasing the storage mutex</a></ol></li>
    <li><a href=#offline><span class=secno>6.9 </span>Offline Web applications</a>
     <ol>
-     <li><a href=#introduction-4><span class=secno>6.9.1 </span>Introduction</a></li>
+     <li><a href=#introduction-4><span class=secno>6.9.1 </span>Introduction</a>
+      <ol>
+       <li><a href=#event-summary><span class=secno>6.9.1.1 </span>Event summary</a></ol></li>
      <li><a href=#appcache><span class=secno>6.9.2 </span>Application caches</a></li>
      <li><a href=#manifests><span class=secno>6.9.3 </span>The cache manifest syntax</a>
       <ol>
@@ -48865,12 +48867,117 @@
 
   <p><em>This section is non-normative.</em></p>
 
-  <p class=XXX>...</p>
+  <p>In order to enable users to continue interacting with Web
+  applications and documents even when their network connection is
+  unavailable — for instance, because they are traveling outside
+  of their ISP's coverage area — authors can provide a manifest
+  which lists the files that are needed for the Web application to
+  work offline and which causes the user's browser to keep a copy of
+  the files for use offline.</p>
 
+  <p>To illustrate this, consider a simple clock applet consisting of
+  an HTML page "<code title="">clock.html</code>", a CSS style sheet
+  "<code title="">clock.css</code>", and a JavaScript script "<code title="">clock.js</code>".</p>
 
+  <p>Before adding the manifest, three three files might look like
+  this:</p>
 
-  <div class=impl>
+  <pre><!-- clock.html -->
+<!DOCTYPE HTML>
+<html>
+ <head>
+  <title>Clock</title>
+  <script src="clock.js"></script>
+  <link rel="stylesheet" href="clock.css">
+ </head>
+ <body>
+  <p>The time is: <output id="clock"></output></p>
+ </body>
+</html></pre>
+  <pre>/* clock.css */
+output { font: 2em sans-serif; }</pre>
+  <pre>/* clock.js */
+setTimeout(function () {
+    document.getElementById('clock').value = new Date();
+}, 1000);</pre>
 
+  <p>If the user tries to open the "<code title="">clock.html</code>"
+  page while offline, though, the user agent (unless it happens to
+  have it still in the local cache) will fail with an error.</p>
+
+  <p>The author can instead provide a manifest of the three files:</p>
+
+  <pre>CACHE MANIFEST
+clock.html
+clock.css
+clock.js</pre>
+
+  <p>With a small change to the HTML file, the manifest (served as
+  <code title="">text/cache-manifest</code>) is linked to the
+  application:</p>
+
+  <pre><!-- clock.html -->
+<!DOCTYPE HTML>
+<html manifest="clock.manifest">
+ <head>
+  <title>Clock</title>
+  <script src="clock.js"></script>
+  <link rel="stylesheet" href="clock.css">
+ </head>
+ <body>
+  <p>The time is: <output id="clock"></output></p>
+ </body>
+</html></pre>
+
+  <p>Now, if the user goes to the page, the browser will cache the
+  files and make them available even when the user is offline.</p>
+
+
+  <h5 id=event-summary><span class=secno>6.9.1.1 </span>Event summary</h5>
+
+  <p>When the user visits a page that declares a manifest, the browser
+  will try to update the cache. It does this by fetching a copy of the
+  manifest and, if the manifest has changed since the user agent last
+  saw it, redownloading all the resources it mentions and caching them
+  anew.</p>
+
+  <p>As this is going on, a number of events get fired to keep the
+  script updated as to the state of the cache update, so that the user
+  can be notified appropriately. The events are as follows:</p>
+
+  <table><thead><tr><th> Event name
+     <th> Occasion
+     <th> Next events
+   <tbody><tr><td> <dfn id=event-appcache-checking title=event-appcache-checking><code>checking</code></dfn>
+     <td> The user agent is checking for an update, or attempting to download the manifest for the first time.
+     <td> <code title=event-appcache-noupdate><a href=#event-appcache-noupdate>noupdate</a></code>, <code title=event-appcache-downloading><a href=#event-appcache-downloading>downloading</a></code>, <code title=event-appcache-obsolete><a href=#event-appcache-obsolete>obsolete</a></code>, <code title=event-appcache-error><a href=#event-appcache-error>error</a></code>
+    <tr><td> <dfn id=event-appcache-noupdate title=event-appcache-noupdate><code>noupdate</code></dfn>
+     <td> The manifest hadn't changed.
+     <td> (Last event in sequence.)
+    <tr><td> <dfn id=event-appcache-downloading title=event-appcache-downloading><code>downloading</code></dfn>
+     <td> The user agent has found an update and is fetching it, or is downloading the resources listed by the manifest for the first time.
+     <td> <code title=event-appcache-progress><a href=#event-appcache-progress>progress</a></code>, <code title=event-appcache-error><a href=#event-appcache-error>error</a></code>, <code title=event-appcache-cached><a href=#event-appcache-cached>cached</a></code>, <code title=event-appcache-updateready><a href=#event-appcache-updateready>updateready</a></code>
+    <tr><td> <dfn id=event-appcache-progress title=event-appcache-progress><code>progress</code></dfn>
+     <td> The user agent is downloading resources listed by the manifest.
+     <td> <code title=event-appcache-progress><a href=#event-appcache-progress>progress</a></code>, <code title=event-appcache-error><a href=#event-appcache-error>error</a></code>, <code title=event-appcache-cached><a href=#event-appcache-cached>cached</a></code>, <code title=event-appcache-updateready><a href=#event-appcache-updateready>updateready</a></code>
+    <tr><td> <dfn id=event-appcache-cached title=event-appcache-cached><code>cached</code></dfn>
+     <td> The resources listed in the manifest have been downloaded, and the application is now cached.
+     <td> Last event in sequence.
+    <tr><td> <dfn id=event-appcache-updateready title=event-appcache-updateready><code>updateready</code></dfn>
+     <td> The resources listed in the manifest have been newly redownloaded, and the script can use <code title=dom-appcache-swapCache><a href=#dom-appcache-swapcache>swapCache()</a></code> to switch to the new cache.
+     <td> Last event in sequence.
+    <tr><td> <dfn id=event-appcache-obsolete title=event-appcache-obsolete><code>obsolete</code></dfn>
+     <td> The manifest was found to have become a 404 or 410 page, so the application cache is being deleted.
+     <td> Last event in sequence.
+    <tr><td rowspan=4> <dfn id=event-appcache-error title=event-appcache-error><code>error</code></dfn>
+     <td> The manifest was a 404 or 410 page, so the attempt to cache the application has been aborted.
+     <td rowspan=3> Last event in sequence.
+    <tr><td> The manifest hadn't changed, but the page referencing the manifest failed to download properly.
+    <tr><td> A fatal error occured while fetching the resources listed in the manifest.
+    <tr><td> The manifest changed while the update was being run.
+     <td> The user agent will try fetching the files again momentarily.
+  </table><div class=impl>
+
   <h4 id=appcache><span class=secno>6.9.2 </span>Application caches</h4>
 
   <p>An <dfn id=application-cache>application cache</dfn> is a set of cached resources
@@ -49471,7 +49578,7 @@
      <li><p>If these steps were invoked with a <a href=#cache-host>cache
      host</a>, and the <a href=#concept-appcache-status title=concept-appcache-status>status</a> of <var title="">cache group</var> is <i>checking</i> or
      <i>downloading</i>, then <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire
-     a simple event</a> called <code title=event-checking>checking</code> at the
+     a simple event</a> called <code title=event-appcache-checking><a href=#event-appcache-checking>checking</a></code> at the
      <code><a href=#applicationcache>ApplicationCache</a></code> singleton of that <a href=#cache-host>cache
      host</a>. The default action of this event should be the
      display of some sort of user interface indicating to the user
@@ -49481,7 +49588,7 @@
      <li><p>If these steps were invoked with a <a href=#cache-host>cache
      host</a>, and the <a href=#concept-appcache-status title=concept-appcache-status>status</a> of <var title="">cache group</var> is <i>downloading</i>, then also
      <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a>
-     called <code title=event-downloading>downloading</code> that is
+     called <code title=event-appcache-downloading><a href=#event-appcache-downloading>downloading</a></code> that is
      cancelable at the <code><a href=#applicationcache>ApplicationCache</a></code> singleton of that
      <a href=#cache-host>cache host</a>. The default action of this event should
      be the display of some sort of user interface indicating to the
@@ -49497,7 +49604,7 @@
      <li><p>For each <a href=#cache-host>cache host</a> associated with an
      <a href=#application-cache>application cache</a> in <var title="">cache
      group</var>, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple
-     event</a> that is cancelable called <code title=event-checking>checking</code> at the
+     event</a> that is cancelable called <code title=event-appcache-checking><a href=#event-appcache-checking>checking</a></code> at the
      <code><a href=#applicationcache>ApplicationCache</a></code> singleton of the <a href=#cache-host>cache
      host</a>. The default action of these events should be the
      display of some sort of user interface indicating to the user
@@ -49516,7 +49623,7 @@
    <li><p>If this is a <a href=#concept-appcache-cache title=concept-appcache-cache>cache
    attempt</a>, then this algorithm was invoked with a <a href=#cache-host>cache
    host</a>; <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple
-   event</a> called <code title=event-checking>checking</code>
+   event</a> called <code title=event-appcache-checking><a href=#event-appcache-checking>checking</a></code>
    that is cancelable at the <code><a href=#applicationcache>ApplicationCache</a></code> singleton
    of that <a href=#cache-host>cache host</a>. The default action of this event
    should be the display of some sort of user interface indicating to
@@ -49551,7 +49658,7 @@
      <li><p>For each <a href=#cache-host>cache host</a> associated with an
      <a href=#application-cache>application cache</a> in <var title="">cache
      group</var>, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple
-     event</a> called <code title=event-obsolete>obsolete</code>
+     event</a> called <code title=event-appcache-obsolete><a href=#event-appcache-obsolete>obsolete</a></code>
      that is cancelable at the <code><a href=#applicationcache>ApplicationCache</a></code> singleton
      of the <a href=#cache-host>cache host</a>. The default action of these
      events should be the display of some sort of user interface
@@ -49560,7 +49667,7 @@
 
      <li><p>For each entry in <var title="">cache group</var>'s <a href=#concept-appcache-pending-masters title=concept-appcache-pending-masters>list of pending master
      entries</a>, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple
-     event</a> that is cancelable called <code title=event-error><a href=#event-error>error</a></code> (not <code title=event-obsolete>obsolete</code>!) at the
+     event</a> that is cancelable called <code title=event-appcache-error><a href=#event-appcache-error>error</a></code> (not <code title=event-appcache-obsolete><a href=#event-appcache-obsolete>obsolete</a></code>!) at the
      <code><a href=#applicationcache>ApplicationCache</a></code> singleton of the <a href=#cache-host>cache
      host</a> the <code>Document</code> for this entry, if there
      still is one. The default action of this event should be the
@@ -49615,7 +49722,7 @@
 
       <p>If the download failed (e.g. the connection times out, or the
       user cancels the download), then <a href=#queue-a-task>queue a task</a> to
-      <a href=#fire-a-simple-event>fire a simple event</a> that is cancelable called <code title=event-error><a href=#event-error>error</a></code> at the
+      <a href=#fire-a-simple-event>fire a simple event</a> that is cancelable called <code title=event-appcache-error><a href=#event-appcache-error>error</a></code> at the
       <code><a href=#applicationcache>ApplicationCache</a></code> singleton of the <a href=#cache-host>cache
       host</a> the <code>Document</code> for this entry, if there
       still is one. The default action of this event should be the
@@ -49637,7 +49744,7 @@
      <li><p>For each <a href=#cache-host>cache host</a> associated with an
      <a href=#application-cache>application cache</a> in <var title="">cache
      group</var>, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple
-     event</a> that is cancelable called <code title=event-noupdate>noupdate</code> at the
+     event</a> that is cancelable called <code title=event-appcache-noupdate><a href=#event-appcache-noupdate>noupdate</a></code> at the
      <code><a href=#applicationcache>ApplicationCache</a></code> singleton of the <a href=#cache-host>cache
      host</a>. The default action of these events should be the
      display of some sort of user interface indicating to the user
@@ -49670,7 +49777,7 @@
    <li><p>For each <a href=#cache-host>cache host</a> associated with an
    <a href=#application-cache>application cache</a> in <var title="">cache group</var>,
    <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that
-   is cancelable called <code title=event-downloading>downloading</code> at the
+   is cancelable called <code title=event-appcache-downloading><a href=#event-appcache-downloading>downloading</a></code> at the
    <code><a href=#applicationcache>ApplicationCache</a></code> singleton of the <a href=#cache-host>cache
    host</a>. The default action of these events should be the
    display of some sort of user interface indicating to the user that
@@ -49719,7 +49826,7 @@
      <li><p>For each <a href=#cache-host>cache host</a> associated with an
      <a href=#application-cache>application cache</a> in <var title="">cache
      group</var>, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple
-     event</a> that is cancelable called <code title=event-progress><a href=#event-progress>progress</a></code> at the
+     event</a> that is cancelable called <code title=event-appcache-progress><a href=#event-appcache-progress>progress</a></code> at the
      <code><a href=#applicationcache>ApplicationCache</a></code> singleton of the <a href=#cache-host>cache
      host</a>. The default action of these events should be the
      display of some sort of user interface indicating to the user
@@ -49855,7 +49962,7 @@
      <var title="">new cache</var>.</li>
 
      <li><p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple
-     event</a> that is cancelable called <code title=event-error><a href=#event-error>error</a></code> at the
+     event</a> that is cancelable called <code title=event-appcache-error><a href=#event-appcache-error>error</a></code> at the
      <code><a href=#applicationcache>ApplicationCache</a></code> singleton of the
      <code>Document</code> for this entry, if there still is one. The
      default action of this event should be the display of some sort
@@ -49923,7 +50030,7 @@
     attempt</a>, then for each <a href=#cache-host>cache host</a> associated
     with an <a href=#application-cache>application cache</a> in <var title="">cache
     group</var>, <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple
-    event</a> that is cancelable called <code title=event-cached>cached</code> at the
+    event</a> that is cancelable called <code title=event-appcache-cached><a href=#event-appcache-cached>cached</a></code> at the
     <code><a href=#applicationcache>ApplicationCache</a></code> singleton of the <a href=#cache-host>cache
     host</a>. The default action of these events should be the
     display of some sort of user interface indicating to the user that
@@ -49934,7 +50041,7 @@
     <a href=#cache-host>cache host</a> associated with an <a href=#application-cache>application
     cache</a> in <var title="">cache group</var>, <a href=#queue-a-task>queue a
     task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that is cancelable
-    called <code title=event-updateready>updateready</code> at the
+    called <code title=event-appcache-updateready><a href=#event-appcache-updateready>updateready</a></code> at the
     <code><a href=#applicationcache>ApplicationCache</a></code> singleton of the <a href=#cache-host>cache
     host</a>. The default action of these events should be the
     display of some sort of user interface indicating to the user that
@@ -49965,7 +50072,7 @@
      its <a href=#application-cache>application cache</a>, if it has one.</li>
 
      <li><p><a href=#queue-a-task>Queue a task</a> to <a href=#fire-a-simple-event>fire a simple
-     event</a> that is cancelable called <code title=event-error><a href=#event-error>error</a></code> at the
+     event</a> that is cancelable called <code title=event-appcache-error><a href=#event-appcache-error>error</a></code> at the
      <code><a href=#applicationcache>ApplicationCache</a></code> singleton of the
      <code>Document</code> for this entry, if there still is one. The
      default action of these events should be the display of some sort
@@ -49977,7 +50084,7 @@
    <li><p>For each <a href=#cache-host>cache host</a> still associated with an
    <a href=#application-cache>application cache</a> in <var title="">cache group</var>,
    <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> that
-   is cancelable called <code title=event-error><a href=#event-error>error</a></code> at the
+   is cancelable called <code title=event-appcache-error><a href=#event-appcache-error>error</a></code> at the
    <code><a href=#applicationcache>ApplicationCache</a></code> singleton of the <a href=#cache-host>cache
    host</a>. The default action of these events should be the
    display of some sort of user interface indicating to the user that
@@ -50397,14 +50504,14 @@
   <code><a href=#applicationcache>ApplicationCache</a></code> interface:</p>
 
   <table><thead><tr><th><a href=#event-handler-attributes-0 title="event handler attributes">event handler attribute</a> <th><a href=#event-handler-event-type>Event handler event type</a>
-   <tbody><tr><td><dfn id=handler-appcache-onchecking title=handler-appcache-onchecking><code>onchecking</code></dfn> <td> <code title=event-checking>checking</code>
-    <tr><td><dfn id=handler-appcache-onerror title=handler-appcache-onerror><code>onerror</code></dfn> <td> <code title=event-error><a href=#event-error>error</a></code>
-    <tr><td><dfn id=handler-appcache-onnoupdate title=handler-appcache-onnoupdate><code>onnoupdate</code></dfn> <td> <code title=event-noupdate>noupdate</code>
-    <tr><td><dfn id=handler-appcache-ondownloading title=handler-appcache-ondownloading><code>ondownloading</code></dfn> <td> <code title=event-downloading>downloading</code>
-    <tr><td><dfn id=handler-appcache-onprogress title=handler-appcache-onprogress><code>onprogress</code></dfn> <td> <code title=event-progress><a href=#event-progress>progress</a></code>
-    <tr><td><dfn id=handler-appcache-onupdateready title=handler-appcache-onupdateready><code>onupdateready</code></dfn> <td> <code title=event-updateready>updateready</code>
-    <tr><td><dfn id=handler-appcache-oncached title=handler-appcache-oncached><code>oncached</code></dfn> <td> <code title=event-cached>cached</code>
-    <tr><td><dfn id=handler-appcache-onobsolete title=handler-appcache-onobsolete><code>onobsolete</code></dfn> <td> <code title=event-obsolete>obsolete</code>
+   <tbody><tr><td><dfn id=handler-appcache-onchecking title=handler-appcache-onchecking><code>onchecking</code></dfn> <td> <code title=event-appcache-checking><a href=#event-appcache-checking>checking</a></code>
+    <tr><td><dfn id=handler-appcache-onerror title=handler-appcache-onerror><code>onerror</code></dfn> <td> <code title=event-appcache-error><a href=#event-appcache-error>error</a></code>
+    <tr><td><dfn id=handler-appcache-onnoupdate title=handler-appcache-onnoupdate><code>onnoupdate</code></dfn> <td> <code title=event-appcache-noupdate><a href=#event-appcache-noupdate>noupdate</a></code>
+    <tr><td><dfn id=handler-appcache-ondownloading title=handler-appcache-ondownloading><code>ondownloading</code></dfn> <td> <code title=event-appcache-downloading><a href=#event-appcache-downloading>downloading</a></code>
+    <tr><td><dfn id=handler-appcache-onprogress title=handler-appcache-onprogress><code>onprogress</code></dfn> <td> <code title=event-appcache-progress><a href=#event-appcache-progress>progress</a></code>
+    <tr><td><dfn id=handler-appcache-onupdateready title=handler-appcache-onupdateready><code>onupdateready</code></dfn> <td> <code title=event-appcache-updateready><a href=#event-appcache-updateready>updateready</a></code>
+    <tr><td><dfn id=handler-appcache-oncached title=handler-appcache-oncached><code>oncached</code></dfn> <td> <code title=event-appcache-cached><a href=#event-appcache-cached>cached</a></code>
+    <tr><td><dfn id=handler-appcache-onobsolete title=handler-appcache-onobsolete><code>onobsolete</code></dfn> <td> <code title=event-appcache-obsolete><a href=#event-appcache-obsolete>obsolete</a></code>
   </table></div>
 
 

Modified: source
===================================================================
--- source	2009-06-29 00:59:25 UTC (rev 3336)
+++ source	2009-06-29 09:59:02 UTC (rev 3337)
@@ -55686,10 +55686,106 @@
 
   <p><em>This section is non-normative.</em></p>
 
-  <p class="XXX">...</p>
+  <p>In order to enable users to continue interacting with Web
+  applications and documents even when their network connection is
+  unavailable — for instance, because they are traveling outside
+  of their ISP's coverage area — authors can provide a manifest
+  which lists the files that are needed for the Web application to
+  work offline and which causes the user's browser to keep a copy of
+  the files for use offline.</p>
 
+  <p>To illustrate this, consider a simple clock applet consisting of
+  an HTML page "<code title="">clock.html</code>", a CSS style sheet
+  "<code title="">clock.css</code>", and a JavaScript script "<code
+  title="">clock.js</code>".</p>
 
+  <p>Before adding the manifest, three three files might look like
+  this:</p>
 
+  <pre>EXAMPLE offline/clock/clock1.html</pre>
+  <pre>EXAMPLE offline/clock/clock1.css</pre>
+  <pre>EXAMPLE offline/clock/clock1.js</pre>
+
+  <p>If the user tries to open the "<code title="">clock.html</code>"
+  page while offline, though, the user agent (unless it happens to
+  have it still in the local cache) will fail with an error.</p>
+
+  <p>The author can instead provide a manifest of the three files:</p>
+
+  <pre>EXAMPLE offline/clock/clock2.manifest</pre>
+
+  <p>With a small change to the HTML file, the manifest (served as
+  <code title="">text/cache-manifest</code>) is linked to the
+  application:</p>
+
+  <pre>EXAMPLE offline/clock/clock2.html</pre>
+
+  <p>Now, if the user goes to the page, the browser will cache the
+  files and make them available even when the user is offline.</p>
+
+
+  <h5>Event summary</h5>
+
+  <p>When the user visits a page that declares a manifest, the browser
+  will try to update the cache. It does this by fetching a copy of the
+  manifest and, if the manifest has changed since the user agent last
+  saw it, redownloading all the resources it mentions and caching them
+  anew.</p>
+
+  <p>As this is going on, a number of events get fired to keep the
+  script updated as to the state of the cache update, so that the user
+  can be notified appropriately. The events are as follows:</p>
+
+  <table>
+   <thead>
+    <tr>
+     <th> Event name
+     <th> Occasion
+     <th> Next events
+   <tbody>
+    <tr>
+     <td> <dfn title="event-appcache-checking"><code>checking</code></dfn>
+     <td> The user agent is checking for an update, or attempting to download the manifest for the first time.
+     <td> <code title="event-appcache-noupdate">noupdate</code>, <code title="event-appcache-downloading">downloading</code>, <code title="event-appcache-obsolete">obsolete</code>, <code title="event-appcache-error">error</code>
+    <tr>
+     <td> <dfn title="event-appcache-noupdate"><code>noupdate</code></dfn>
+     <td> The manifest hadn't changed.
+     <td> (Last event in sequence.)
+    <tr>
+     <td> <dfn title="event-appcache-downloading"><code>downloading</code></dfn>
+     <td> The user agent has found an update and is fetching it, or is downloading the resources listed by the manifest for the first time.
+     <td> <code title="event-appcache-progress">progress</code>, <code title="event-appcache-error">error</code>, <code title="event-appcache-cached">cached</code>, <code title="event-appcache-updateready">updateready</code>
+    <tr>
+     <td> <dfn title="event-appcache-progress"><code>progress</code></dfn>
+     <td> The user agent is downloading resources listed by the manifest.
+     <td> <code title="event-appcache-progress">progress</code>, <code title="event-appcache-error">error</code>, <code title="event-appcache-cached">cached</code>, <code title="event-appcache-updateready">updateready</code>
+    <tr>
+     <td> <dfn title="event-appcache-cached"><code>cached</code></dfn>
+     <td> The resources listed in the manifest have been downloaded, and the application is now cached.
+     <td> Last event in sequence.
+    <tr>
+     <td> <dfn title="event-appcache-updateready"><code>updateready</code></dfn>
+     <td> The resources listed in the manifest have been newly redownloaded, and the script can use <code title="dom-appcache-swapCache">swapCache()</code> to switch to the new cache.
+     <td> Last event in sequence.
+    <tr>
+     <td> <dfn title="event-appcache-obsolete"><code>obsolete</code></dfn>
+     <td> The manifest was found to have become a 404 or 410 page, so the application cache is being deleted.
+     <td> Last event in sequence.
+    <tr>
+     <td rowspan=4> <dfn title="event-appcache-error"><code>error</code></dfn>
+     <td> The manifest was a 404 or 410 page, so the attempt to cache the application has been aborted.
+     <td rowspan=3> Last event in sequence.
+    <tr>
+     <td> The manifest hadn't changed, but the page referencing the manifest failed to download properly.
+    <tr>
+     <td> A fatal error occured while fetching the resources listed in the manifest.
+    <tr>
+     <td> The manifest changed while the update was being run.
+     <td> The user agent will try fetching the files again momentarily.
+  </table>
+
+
+
   <div class="impl">
 
   <h4 id="appcache">Application caches</h4>
@@ -56407,7 +56503,7 @@
      title="">cache group</var> is <i>checking</i> or
      <i>downloading</i>, then <span>queue a task</span> to <span>fire
      a simple event</span> called <code
-     title="event-checking">checking</code> at the
+     title="event-appcache-checking">checking</code> at the
      <code>ApplicationCache</code> singleton of that <span>cache
      host</span>. The default action of this event should be the
      display of some sort of user interface indicating to the user
@@ -56419,7 +56515,7 @@
      title="concept-appcache-status">status</span> of <var
      title="">cache group</var> is <i>downloading</i>, then also
      <span>queue a task</span> to <span>fire a simple event</span>
-     called <code title="event-downloading">downloading</code> that is
+     called <code title="event-appcache-downloading">downloading</code> that is
      cancelable at the <code>ApplicationCache</code> singleton of that
      <span>cache host</span>. The default action of this event should
      be the display of some sort of user interface indicating to the
@@ -56438,7 +56534,7 @@
      <span>application cache</span> in <var title="">cache
      group</var>, <span>queue a task</span> to <span>fire a simple
      event</span> that is cancelable called <code
-     title="event-checking">checking</code> at the
+     title="event-appcache-checking">checking</code> at the
      <code>ApplicationCache</code> singleton of the <span>cache
      host</span>. The default action of these events should be the
      display of some sort of user interface indicating to the user
@@ -56460,7 +56556,7 @@
    <li><p>If this is a <span title="concept-appcache-cache">cache
    attempt</span>, then this algorithm was invoked with a <span>cache
    host</span>; <span>queue a task</span> to <span>fire a simple
-   event</span> called <code title="event-checking">checking</code>
+   event</span> called <code title="event-appcache-checking">checking</code>
    that is cancelable at the <code>ApplicationCache</code> singleton
    of that <span>cache host</span>. The default action of this event
    should be the display of some sort of user interface indicating to
@@ -56504,7 +56600,7 @@
      <li><p>For each <span>cache host</span> associated with an
      <span>application cache</span> in <var title="">cache
      group</var>, <span>queue a task</span> to <span>fire a simple
-     event</span> called <code title="event-obsolete">obsolete</code>
+     event</span> called <code title="event-appcache-obsolete">obsolete</code>
      that is cancelable at the <code>ApplicationCache</code> singleton
      of the <span>cache host</span>. The default action of these
      events should be the display of some sort of user interface
@@ -56515,8 +56611,8 @@
      title="concept-appcache-pending-masters">list of pending master
      entries</span>, <span>queue a task</span> to <span>fire a simple
      event</span> that is cancelable called <code
-     title="event-error">error</code> (not <code
-     title="event-obsolete">obsolete</code>!) at the
+     title="event-appcache-error">error</code> (not <code
+     title="event-appcache-obsolete">obsolete</code>!) at the
      <code>ApplicationCache</code> singleton of the <span>cache
      host</span> the <code>Document</code> for this entry, if there
      still is one. The default action of this event should be the
@@ -56584,7 +56680,7 @@
       <p>If the download failed (e.g. the connection times out, or the
       user cancels the download), then <span>queue a task</span> to
       <span>fire a simple event</span> that is cancelable called <code
-      title="event-error">error</code> at the
+      title="event-appcache-error">error</code> at the
       <code>ApplicationCache</code> singleton of the <span>cache
       host</span> the <code>Document</code> for this entry, if there
       still is one. The default action of this event should be the
@@ -56609,7 +56705,7 @@
      <span>application cache</span> in <var title="">cache
      group</var>, <span>queue a task</span> to <span>fire a simple
      event</span> that is cancelable called <code
-     title="event-noupdate">noupdate</code> at the
+     title="event-appcache-noupdate">noupdate</code> at the
      <code>ApplicationCache</code> singleton of the <span>cache
      host</span>. The default action of these events should be the
      display of some sort of user interface indicating to the user
@@ -56650,7 +56746,7 @@
    <span>application cache</span> in <var title="">cache group</var>,
    <span>queue a task</span> to <span>fire a simple event</span> that
    is cancelable called <code
-   title="event-downloading">downloading</code> at the
+   title="event-appcache-downloading">downloading</code> at the
    <code>ApplicationCache</code> singleton of the <span>cache
    host</span>. The default action of these events should be the
    display of some sort of user interface indicating to the user that
@@ -56707,7 +56803,7 @@
      <span>application cache</span> in <var title="">cache
      group</var>, <span>queue a task</span> to <span>fire a simple
      event</span> that is cancelable called <code
-     title="event-progress">progress</code> at the
+     title="event-appcache-progress">progress</code> at the
      <code>ApplicationCache</code> singleton of the <span>cache
      host</span>. The default action of these events should be the
      display of some sort of user interface indicating to the user
@@ -56861,7 +56957,7 @@
 
      <li><p><span>Queue a task</span> to <span>fire a simple
      event</span> that is cancelable called <code
-     title="event-error">error</code> at the
+     title="event-appcache-error">error</code> at the
      <code>ApplicationCache</code> singleton of the
      <code>Document</code> for this entry, if there still is one. The
      default action of this event should be the display of some sort
@@ -56943,7 +57039,7 @@
     with an <span>application cache</span> in <var title="">cache
     group</var>, <span>queue a task</span> to <span>fire a simple
     event</span> that is cancelable called <code
-    title="event-cached">cached</code> at the
+    title="event-appcache-cached">cached</code> at the
     <code>ApplicationCache</code> singleton of the <span>cache
     host</span>. The default action of these events should be the
     display of some sort of user interface indicating to the user that
@@ -56955,7 +57051,7 @@
     <span>cache host</span> associated with an <span>application
     cache</span> in <var title="">cache group</var>, <span>queue a
     task</span> to <span>fire a simple event</span> that is cancelable
-    called <code title="event-updateready">updateready</code> at the
+    called <code title="event-appcache-updateready">updateready</code> at the
     <code>ApplicationCache</code> singleton of the <span>cache
     host</span>. The default action of these events should be the
     display of some sort of user interface indicating to the user that
@@ -56994,7 +57090,7 @@
 
      <li><p><span>Queue a task</span> to <span>fire a simple
      event</span> that is cancelable called <code
-     title="event-error">error</code> at the
+     title="event-appcache-error">error</code> at the
      <code>ApplicationCache</code> singleton of the
      <code>Document</code> for this entry, if there still is one. The
      default action of these events should be the display of some sort
@@ -57008,7 +57104,7 @@
    <li><p>For each <span>cache host</span> still associated with an
    <span>application cache</span> in <var title="">cache group</var>,
    <span>queue a task</span> to <span>fire a simple event</span> that
-   is cancelable called <code title="event-error">error</code> at the
+   is cancelable called <code title="event-appcache-error">error</code> at the
    <code>ApplicationCache</code> singleton of the <span>cache
    host</span>. The default action of these events should be the
    display of some sort of user interface indicating to the user that
@@ -57497,14 +57593,14 @@
    <thead>
     <tr><th><span title="event handler attributes">event handler attribute</span> <th><span>Event handler event type</span>
    <tbody>
-    <tr><td><dfn title="handler-appcache-onchecking"><code>onchecking</code></dfn> <td> <code title="event-checking">checking</code>
-    <tr><td><dfn title="handler-appcache-onerror"><code>onerror</code></dfn> <td> <code title="event-error">error</code>
-    <tr><td><dfn title="handler-appcache-onnoupdate"><code>onnoupdate</code></dfn> <td> <code title="event-noupdate">noupdate</code>
-    <tr><td><dfn title="handler-appcache-ondownloading"><code>ondownloading</code></dfn> <td> <code title="event-downloading">downloading</code>
-    <tr><td><dfn title="handler-appcache-onprogress"><code>onprogress</code></dfn> <td> <code title="event-progress">progress</code>
-    <tr><td><dfn title="handler-appcache-onupdateready"><code>onupdateready</code></dfn> <td> <code title="event-updateready">updateready</code>
-    <tr><td><dfn title="handler-appcache-oncached"><code>oncached</code></dfn> <td> <code title="event-cached">cached</code>
-    <tr><td><dfn title="handler-appcache-onobsolete"><code>onobsolete</code></dfn> <td> <code title="event-obsolete">obsolete</code>
+    <tr><td><dfn title="handler-appcache-onchecking"><code>onchecking</code></dfn> <td> <code title="event-appcache-checking">checking</code>
+    <tr><td><dfn title="handler-appcache-onerror"><code>onerror</code></dfn> <td> <code title="event-appcache-error">error</code>
+    <tr><td><dfn title="handler-appcache-onnoupdate"><code>onnoupdate</code></dfn> <td> <code title="event-appcache-noupdate">noupdate</code>
+    <tr><td><dfn title="handler-appcache-ondownloading"><code>ondownloading</code></dfn> <td> <code title="event-appcache-downloading">downloading</code>
+    <tr><td><dfn title="handler-appcache-onprogress"><code>onprogress</code></dfn> <td> <code title="event-appcache-progress">progress</code>
+    <tr><td><dfn title="handler-appcache-onupdateready"><code>onupdateready</code></dfn> <td> <code title="event-appcache-updateready">updateready</code>
+    <tr><td><dfn title="handler-appcache-oncached"><code>oncached</code></dfn> <td> <code title="event-appcache-cached">cached</code>
+    <tr><td><dfn title="handler-appcache-onobsolete"><code>onobsolete</code></dfn> <td> <code title="event-appcache-obsolete">obsolete</code>
   </table>
 
   </div>




More information about the Commit-Watchers mailing list