Ignore:
Timestamp:
Nov 13, 2008, 10:01:19 AM (11 years ago)
Author:
julian.reschke@…
Message:

Rewrite header ABNFs to spell out whitespace rules, factor out value format definitions. (related to #36)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • draft-ietf-httpbis/latest/p5-range.xml

    r359 r363  
    255255  <x:anchor-alias value="SP"/>
    256256  <x:anchor-alias value="token"/>
     257  <x:anchor-alias value="BWS"/>
     258  <x:anchor-alias value="OWS"/>
     259  <x:anchor-alias value="RWS"/>
    257260<t>
    258261  This specification uses the ABNF syntax defined in &notation-abnf; and
     
    267270<figure><artwork type="abnf2616">
    268271  <x:ref>token</x:ref>      = &lt;token, defined in &basic-rules;&gt;
     272  <x:ref>BWS</x:ref>        = &lt;BWS, defined in &basic-rules;&gt;
     273  <x:ref>OWS</x:ref>        = &lt;OWS, defined in &basic-rules;&gt;
     274  <x:ref>RWS</x:ref>        = &lt;RWS, defined in &basic-rules;&gt;
    269275</artwork></figure>
    270276<t anchor="abnf.dependencies">
     
    422428  <iref primary="true" item="Headers" subitem="Accept-Ranges" x:for-anchor=""/>
    423429  <x:anchor-alias value="Accept-Ranges"/>
     430  <x:anchor-alias value="Accept-Ranges-v"/>
    424431  <x:anchor-alias value="acceptable-ranges"/>
    425432<t>
    426       The Accept-Ranges response-header field allows the server to
     433      The response-header "Accept-Ranges" field allows the server to
    427434      indicate its acceptance of range requests for a resource:
    428435</t>
    429 <figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="Accept-Ranges"/><iref primary="true" item="Grammar" subitem="acceptable-ranges"/>
    430   <x:ref>Accept-Ranges</x:ref>     = "Accept-Ranges" ":" <x:ref>acceptable-ranges</x:ref>
     436<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="Accept-Ranges"/><iref primary="true" item="Grammar" subitem="Accept-Ranges-v"/><iref primary="true" item="Grammar" subitem="acceptable-ranges"/>
     437  <x:ref>Accept-Ranges</x:ref>     = "Accept-Ranges" <x:ref>BWS</x:ref> ":" <x:ref>OWS</x:ref> <x:ref>Accept-Ranges-v</x:ref>
     438  <x:ref>Accept-Ranges-v</x:ref>   = <x:ref>acceptable-ranges</x:ref>
    431439  <x:ref>acceptable-ranges</x:ref> = 1#<x:ref>range-unit</x:ref> / "none"
    432440</artwork></figure>
     
    435443</t>
    436444<figure><artwork type="example">
    437        Accept-Ranges: bytes
     445  Accept-Ranges: bytes
    438446</artwork></figure>
    439447<t>
     
    447455</t>
    448456<figure><artwork type="example">
    449        Accept-Ranges: none
     457  Accept-Ranges: none
    450458</artwork></figure>
    451459<t>
     
    460468  <x:anchor-alias value="byte-range-resp-spec"/>
    461469  <x:anchor-alias value="Content-Range"/>
     470  <x:anchor-alias value="Content-Range-v"/>
    462471  <x:anchor-alias value="content-range-spec"/>
    463472  <x:anchor-alias value="instance-length"/>
    464473<t>
    465    The Content-Range entity-header is sent with a partial entity-body to
     474   The entity-header "Content-Range" is sent with a partial entity-body to
    466475   specify where in the full entity-body the partial body should be
    467476   applied. Range units are defined in <xref target="range.units"/>.
    468477</t>
    469 <figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="Content-Range"/><iref primary="true" item="Grammar" subitem="content-range-spec"/><iref primary="true" item="Grammar" subitem="byte-content-range-spec"/><iref primary="true" item="Grammar" subitem="byte-range-resp-spec"/><iref primary="true" item="Grammar" subitem="instance-length"/>
    470   <x:ref>Content-Range</x:ref> = "Content-Range" ":" <x:ref>content-range-spec</x:ref>
     478<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="Content-Range"/><iref primary="true" item="Grammar" subitem="Content-Range-v"/><iref primary="true" item="Grammar" subitem="content-range-spec"/><iref primary="true" item="Grammar" subitem="byte-content-range-spec"/><iref primary="true" item="Grammar" subitem="byte-range-resp-spec"/><iref primary="true" item="Grammar" subitem="instance-length"/>
     479  <x:ref>Content-Range</x:ref> = "Content-Range" <x:ref>BWS</x:ref> ":" <x:ref>OWS</x:ref> <x:ref>Content-Range-v</x:ref>
     480  <x:ref>Content-Range-v</x:ref> = <x:ref>content-range-spec</x:ref>
    471481 
    472482  <x:ref>content-range-spec</x:ref>      = <x:ref>byte-content-range-spec</x:ref>
     
    544554</t>
    545555<figure><artwork type="example">
    546     HTTP/1.1 206 Partial Content
    547     Date: Wed, 15 Nov 1995 06:25:24 GMT
    548     Last-Modified: Wed, 15 Nov 1995 04:58:08 GMT
    549     Content-Range: bytes 21010-47021/47022
    550     Content-Length: 26012
    551     Content-Type: image/gif
     556  HTTP/1.1 206 Partial Content
     557  Date: Wed, 15 Nov 1995 06:25:24 GMT
     558  Last-Modified: Wed, 15 Nov 1995 04:58:08 GMT
     559  Content-Range: bytes 21010-47021/47022
     560  Content-Length: 26012
     561  Content-Type: image/gif
    552562</artwork></figure>
    553563<t>
     
    597607  <iref primary="true" item="Headers" subitem="If-Range" x:for-anchor=""/>
    598608  <x:anchor-alias value="If-Range"/>
     609  <x:anchor-alias value="If-Range-v"/>
    599610<t>
    600611   If a client has a partial copy of an entity in its cache, and wishes
     
    607618</t>
    608619<t>
    609    The If-Range header allows a client to "short-circuit" the second
     620   The request header "If-Range" allows a client to "short-circuit" the second
    610621   request. Informally, its meaning is `if the entity is unchanged, send
    611622   me the part(s) that I am missing; otherwise, send me the entire new
    612623   entity'.
    613624</t>
    614 <figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="If-Range"/>
    615   <x:ref>If-Range</x:ref> = "If-Range" ":" ( <x:ref>entity-tag</x:ref> / <x:ref>HTTP-date</x:ref> )
     625<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="If-Range"/><iref primary="true" item="Grammar" subitem="If-Range-v"/>
     626  <x:ref>If-Range</x:ref>   = "If-Range" <x:ref>BWS</x:ref> ":" <x:ref>OWS</x:ref> <x:ref>If-Range-v</x:ref>
     627  <x:ref>If-Range-v</x:ref> = <x:ref>entity-tag</x:ref> / <x:ref>HTTP-date</x:ref>
    616628</artwork></figure>
    617629<t>
     
    740752<section title="Range Retrieval Requests" anchor="range.retrieval.requests">
    741753  <x:anchor-alias value="Range"/>
     754  <x:anchor-alias value="Range-v"/>
    742755<t>
    743756   HTTP retrieval requests using conditional or unconditional GET
     
    746759   the entity returned as the result of the request:
    747760</t>
    748 <figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="Range"/>
    749   <x:ref>Range</x:ref> = "Range" ":" <x:ref>ranges-specifier</x:ref>
     761<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="Range"/><iref primary="true" item="Grammar" subitem="Range-v"/>
     762  <x:ref>Range</x:ref>   = "Range" <x:ref>BWS</x:ref> ":" <x:ref>OWS</x:ref> <x:ref>Range-v</x:ref>
     763  <x:ref>Range-v</x:ref> = <x:ref>ranges-specifier</x:ref>
    750764</artwork></figure>
    751765<t>
     
    13781392      Use "/" instead of "|" for alternatives.
    13791393    </t>
     1394    <t>
     1395      Introduce new ABNF rules for "bad" whitespace ("BWS"), optional
     1396      whitespace ("OWS") and required whitespace ("RWS").
     1397    </t>
     1398    <t>
     1399      Rewrite ABNFs to spell out whitespace rules, factor out
     1400      header value format definitions.
     1401    </t>
    13801402  </list>
    13811403</t>
Note: See TracChangeset for help on using the changeset viewer.