Skip to content

Commit

Permalink
[gwr] (2) Make the online whitelist a prefix match feature, not an ex…
Browse files Browse the repository at this point in the history
…act match feature.

git-svn-id: http://svn.whatwg.org/webapps@2337 340c8d12-0b0e-0410-8428-c7bf67bfef74
  • Loading branch information
Hixie committed Oct 15, 2008
1 parent 8434cf8 commit 10f664f
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 23 deletions.
29 changes: 19 additions & 10 deletions index
Expand Up @@ -210,7 +210,7 @@
<li><a href=#features-defined-in-other-specifications><span class=secno>2.2.2 </span>Features defined in other specifications</a></li>
<li><a href=#common-conformance-requirements-for-apis-exposed-to-javascript><span class=secno>2.2.3 </span>Common conformance requirements for APIs exposed to
JavaScript</a></ol></li>
<li><a href=#case-sensitivity><span class=secno>2.3 </span>Case-sensitivity</a></li>
<li><a href=#case-sensitivity-and-string-comparison><span class=secno>2.3 </span>Case-sensitivity and string comparison</a></li>
<li><a href=#common-microsyntaxes><span class=secno>2.4 </span>Common microsyntaxes</a>
<ol>
<li><a href=#common-parser-idioms><span class=secno>2.4.1 </span>Common parser idioms</a></li>
Expand Down Expand Up @@ -1892,7 +1892,7 @@



<h3 id=case-sensitivity><span class=secno>2.3 </span>Case-sensitivity</h3>
<h3 id=case-sensitivity-and-string-comparison><span class=secno>2.3 </span>Case-sensitivity and string comparison</h3>

<p>This specification defines several comparison operators for
strings.</p>
Expand Down Expand Up @@ -1924,6 +1924,11 @@
with the corresponding characters in the range U+0061 .. U+007A
(i.e. LATIN SMALL LETTER A to LATIN SMALL LETTER Z).</p>

<p>A string <var title="">pattern</var> is a <dfn id=prefix-match>prefix match</dfn>
for a string <var title="">s</var> when <var title="">pattern</var>
is not longer than <var title="">s</var> and truncating <var title="">s</var> to <var title="">pattern</var>'s length leaves the
two strings as matches of each other.</p>



<h3 id=common-microsyntaxes><span class=secno>2.4 </span>Common microsyntaxes</h3>
Expand Down Expand Up @@ -34817,23 +34822,27 @@ style/default.css</pre>
mechanism or equivalent, then <a href=#fetch>fetch</a> the resource
normally and abort these steps.</li>

<li><p>If the resource's URL, ignoring its fragment identifier if
any, is listed in the <a href=#application-cache>application cache</a>'s <a href=#concept-appcache-onlinewhitelist title=concept-appcache-onlinewhitelist>online whitelist</a>,
then <a href=#fetch>fetch</a> the resource normally and abort these
steps.</li>

<li><p>If the resource's URL is <a href=#concept-appcache-implicit title=concept-appcache-implicit>an implicit entry</a>, <a href=#concept-appcache-manifest title=concept-appcache-manifest>the manifest</a>, <a href=#concept-appcache-explicit title=concept-appcache-explicit>an explicit entry</a>, <a href=#concept-appcache-fallback title=concept-appcache-fallback>a fallback entry</a>, <a href=#concept-appcache-oppcache title=concept-appcache-oppcache>an opportunistically cached
entry</a>, or a <a href=#concept-appcache-dynamic title=concept-appcache-dynamic>dynamic
entry</a> in the <a href=#application-cache>application cache</a>, then get the
resource from the cache (instead of fetching it), and abort these
steps.</li>

<li><p>If there is an entry in the <a href=#application-cache>application cache</a>'s
<a href=#concept-appcache-onlinewhitelist title=concept-appcache-onlinewhitelist>online
whitelist</a> that has the <a href=#same-origin>same origin</a> as the
resource's URL and that is a <a href=#prefix-match>prefix match</a> for the
resource's URL, then <a href=#fetch>fetch</a> the resource normally and
abort these steps.</li>

<li>

<p>If the resource's URL has the <a href=#same-origin>same origin</a> as the
manifest's URL, and the start of the resource's URL's <a href=#url-path title=url-path>&lt;path&gt;</a> component is exactly matched
by the &lt;path&gt; component of an <a href=#concept-appcache-oppcache-ns title=concept-appcache-oppcache-ns>opportunistic caching
namespace</a> in the <a href=#application-cache>application cache</a>, then:
manifest's URL, and there is an <a href=#concept-appcache-oppcache-ns title=concept-appcache-oppcache-ns>opportunistic caching
namespace</a> in the <a href=#application-cache>application cache</a> whose
&lt;path&gt; component is a <a href=#prefix-match>prefix match</a> for the
resource's URL's <a href=#url-path title=url-path>&lt;path&gt;</a>
component, then:

<p><a href=#fetch>Fetch</a> the resource normally. If this results 4xx
or 5xx status codes or equivalent, or if there were network errors
Expand Down
32 changes: 19 additions & 13 deletions source
Expand Up @@ -985,7 +985,7 @@



<h3>Case-sensitivity</h3>
<h3>Case-sensitivity and string comparison</h3>

<p>This specification defines several comparison operators for
strings.</p>
Expand Down Expand Up @@ -1018,6 +1018,12 @@
with the corresponding characters in the range U+0061 .. U+007A
(i.e. LATIN SMALL LETTER A to LATIN SMALL LETTER Z).</p>

<p>A string <var title="">pattern</var> is a <dfn>prefix match</dfn>
for a string <var title="">s</var> when <var title="">pattern</var>
is not longer than <var title="">s</var> and truncating <var
title="">s</var> to <var title="">pattern</var>'s length leaves the
two strings as matches of each other.</p>



<h3>Common microsyntaxes</h3>
Expand Down Expand Up @@ -3487,8 +3493,6 @@





<h4>Interfaces for URL manipulation</h4>

<p>An interface that has a complement of <dfn>URL decomposition
Expand Down Expand Up @@ -39552,12 +39556,6 @@ style/default.css</pre>
mechanism or equivalent, then <span>fetch</span> the resource
normally and abort these steps.</p></li>

<li><p>If the resource's URL, ignoring its fragment identifier if
any, is listed in the <span>application cache</span>'s <span
title="concept-appcache-onlinewhitelist">online whitelist</span>,
then <span>fetch</span> the resource normally and abort these
steps.</p></li>

<li><p>If the resource's URL is <span
title="concept-appcache-implicit">an implicit entry</span>, <span
title="concept-appcache-manifest">the manifest</span>, <span
Expand All @@ -39569,14 +39567,22 @@ style/default.css</pre>
resource from the cache (instead of fetching it), and abort these
steps.</p></li>

<li><p>If there is an entry in the <span>application cache</span>'s
<span title="concept-appcache-onlinewhitelist">online
whitelist</span> that has the <span>same origin</span> as the
resource's URL and that is a <span>prefix match</span> for the
resource's URL, then <span>fetch</span> the resource normally and
abort these steps.</p></li>

<li>

<p>If the resource's URL has the <span>same origin</span> as the
manifest's URL, and the start of the resource's URL's <span
title="url-path">&lt;path&gt;</span> component is exactly matched
by the &lt;path&gt; component of an <span
manifest's URL, and there is an <span
title="concept-appcache-oppcache-ns">opportunistic caching
namespace</span> in the <span>application cache</span>, then:
namespace</span> in the <span>application cache</span> whose
&lt;path&gt; component is a <span>prefix match</span> for the
resource's URL's <span title="url-path">&lt;path&gt;</span>
component, then:

<p><span>Fetch</span> the resource normally. If this results 4xx
or 5xx status codes or equivalent, or if there were network errors
Expand Down

0 comments on commit 10f664f

Please sign in to comment.