Ignore:
Timestamp:
Jan 1, 2008, 9:15:17 AM (12 years ago)
Author:
julian.reschke@…
Message:

Consistent indentation for all ABNF rules (addresses #36)

File:
1 edited

Legend:

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

    r131 r135  
    537537         uses range units in the Range (<a href="#header.range" id="rfc.xref.header.range.1" title="Range">Section&nbsp;5.4</a>) and Content-Range (<a href="#header.content-range" id="rfc.xref.header.content-range.1" title="Content-Range">Section&nbsp;5.2</a>) header fields. An entity can be broken down into subranges according to various structural units.
    538538      </p>
    539       <div id="rfc.figure.u.1"></div><pre class="inline"><span id="rfc.iref.g.1"></span><span id="rfc.iref.g.2"></span><span id="rfc.iref.g.3"></span>   range-unit       = bytes-unit | other-range-unit
    540    bytes-unit       = "bytes"
    541    other-range-unit = token
     539      <div id="rfc.figure.u.1"></div><pre class="inline"><span id="rfc.iref.g.1"></span><span id="rfc.iref.g.2"></span><span id="rfc.iref.g.3"></span>  range-unit       = bytes-unit | other-range-unit
     540  bytes-unit       = "bytes"
     541  other-range-unit = token
    542542</pre><p id="rfc.section.2.p.3">The only range unit defined by HTTP/1.1 is "bytes". HTTP/1.1 implementations <em class="bcp14">MAY</em> ignore ranges specified using other units.
    543543      </p>
     
    602602      <h2 id="rfc.section.5.1"><a href="#rfc.section.5.1">5.1</a>&nbsp;<a id="header.accept-ranges" href="#header.accept-ranges">Accept-Ranges</a></h2>
    603603      <p id="rfc.section.5.1.p.1">The Accept-Ranges response-header field allows the server to indicate its acceptance of range requests for a resource:</p>
    604       <div id="rfc.figure.u.2"></div><pre class="inline"><span id="rfc.iref.g.4"></span><span id="rfc.iref.g.5"></span>       Accept-Ranges     = "Accept-Ranges" ":" acceptable-ranges
    605        acceptable-ranges = 1#range-unit | "none"
     604      <div id="rfc.figure.u.2"></div><pre class="inline"><span id="rfc.iref.g.4"></span><span id="rfc.iref.g.5"></span>  Accept-Ranges     = "Accept-Ranges" ":" acceptable-ranges
     605  acceptable-ranges = 1#range-unit | "none"
    606606</pre><p id="rfc.section.5.1.p.3">Origin servers that accept byte-range requests <em class="bcp14">MAY</em> send
    607607      </p>
     
    619619         should be applied. Range units are defined in <a href="#range.units" title="Range Units">Section&nbsp;2</a>.
    620620      </p>
    621       <div id="rfc.figure.u.5"></div><pre class="inline"><span id="rfc.iref.g.6"></span><span id="rfc.iref.g.7"></span><span id="rfc.iref.g.8"></span><span id="rfc.iref.g.9"></span><span id="rfc.iref.g.10"></span>    Content-Range = "Content-Range" ":" content-range-spec
    622 
    623     content-range-spec      = byte-content-range-spec
    624     byte-content-range-spec = bytes-unit SP
    625                               byte-range-resp-spec "/"
    626                               ( instance-length | "*" )
    627 
    628     byte-range-resp-spec = (first-byte-pos "-" last-byte-pos)
    629                                    | "*"
    630     instance-length           = 1*DIGIT
     621      <div id="rfc.figure.u.5"></div><pre class="inline"><span id="rfc.iref.g.6"></span><span id="rfc.iref.g.7"></span><span id="rfc.iref.g.8"></span><span id="rfc.iref.g.9"></span><span id="rfc.iref.g.10"></span>  Content-Range = "Content-Range" ":" content-range-spec
     622 
     623  content-range-spec      = byte-content-range-spec
     624  byte-content-range-spec = bytes-unit SP
     625                            byte-range-resp-spec "/"
     626                            ( instance-length | "*" )
     627 
     628  byte-range-resp-spec = (first-byte-pos "-" last-byte-pos)
     629                                 | "*"
     630  instance-length           = 1*DIGIT
    631631</pre><p id="rfc.section.5.2.p.3">The header <em class="bcp14">SHOULD</em> indicate the total length of the full entity-body, unless this length is unknown or difficult to determine. The asterisk "*"
    632632         character means that the instance-length is unknown at the time when the response was generated.
     
    696696         send me the part(s) that I am missing; otherwise, send me the entire new entity'.
    697697      </p>
    698       <div id="rfc.figure.u.11"></div><pre class="inline"><span id="rfc.iref.g.11"></span>     If-Range = "If-Range" ":" ( entity-tag | HTTP-date )
     698      <div id="rfc.figure.u.11"></div><pre class="inline"><span id="rfc.iref.g.11"></span>  If-Range = "If-Range" ":" ( entity-tag | HTTP-date )
    699699</pre><p id="rfc.section.5.3.p.4">If the client has no entity tag for an entity, but does have a Last-Modified date, it <em class="bcp14">MAY</em> use that date in an If-Range header. (The server can distinguish between a valid HTTP-date and any form of entity-tag by examining
    700700         no more than two characters.) The If-Range header <em class="bcp14">SHOULD</em> only be used together with a Range header, and <em class="bcp14">MUST</em> be ignored if the request does not include a Range header, or if the server does not support the sub-range operation.
     
    713713      <p id="rfc.section.5.4.1.p.3">A byte range operation <em class="bcp14">MAY</em> specify a single range of bytes, or a set of ranges within a single entity.
    714714      </p>
    715       <div id="rfc.figure.u.12"></div><pre class="inline"><span id="rfc.iref.g.12"></span><span id="rfc.iref.g.13"></span><span id="rfc.iref.g.14"></span><span id="rfc.iref.g.15"></span><span id="rfc.iref.g.16"></span><span id="rfc.iref.g.17"></span>    ranges-specifier = byte-ranges-specifier
    716     byte-ranges-specifier = bytes-unit "=" byte-range-set
    717     byte-range-set  = 1#( byte-range-spec | suffix-byte-range-spec )
    718     byte-range-spec = first-byte-pos "-" [last-byte-pos]
    719     first-byte-pos  = 1*DIGIT
    720     last-byte-pos   = 1*DIGIT
     715      <div id="rfc.figure.u.12"></div><pre class="inline"><span id="rfc.iref.g.12"></span><span id="rfc.iref.g.13"></span><span id="rfc.iref.g.14"></span><span id="rfc.iref.g.15"></span><span id="rfc.iref.g.16"></span><span id="rfc.iref.g.17"></span>  ranges-specifier = byte-ranges-specifier
     716  byte-ranges-specifier = bytes-unit "=" byte-range-set
     717  byte-range-set  = 1#( byte-range-spec | suffix-byte-range-spec )
     718  byte-range-spec = first-byte-pos "-" [last-byte-pos]
     719  first-byte-pos  = 1*DIGIT
     720  last-byte-pos   = 1*DIGIT
    721721</pre><p id="rfc.section.5.4.1.p.5">The first-byte-pos value in a byte-range-spec gives the byte-offset of the first byte in a range. The last-byte-pos value
    722722         gives the byte-offset of the last byte in the range; that is, the byte positions specified are inclusive. Byte offsets start
     
    730730      </p>
    731731      <p id="rfc.section.5.4.1.p.8">By its choice of last-byte-pos, a client can limit the number of bytes retrieved without knowing the size of the entity.</p>
    732       <div id="rfc.figure.u.13"></div><pre class="inline"><span id="rfc.iref.g.18"></span><span id="rfc.iref.g.19"></span>    suffix-byte-range-spec = "-" suffix-length
    733     suffix-length = 1*DIGIT
     732      <div id="rfc.figure.u.13"></div><pre class="inline"><span id="rfc.iref.g.18"></span><span id="rfc.iref.g.19"></span>  suffix-byte-range-spec = "-" suffix-length
     733  suffix-length = 1*DIGIT
    734734</pre><p id="rfc.section.5.4.1.p.10">A suffix-byte-range-spec is used to specify the suffix of the entity-body, of a length given by the suffix-length value. (That
    735735         is, this form specifies the last N bytes of an entity-body.) If the entity is shorter than the specified suffix-length, the
     
    754754         to the entity returned as the result of the request:
    755755      </p>
    756       <div id="rfc.figure.u.14"></div><pre class="inline"><span id="rfc.iref.g.20"></span>   Range = "Range" ":" ranges-specifier
     756      <div id="rfc.figure.u.14"></div><pre class="inline"><span id="rfc.iref.g.20"></span>  Range = "Range" ":" ranges-specifier
    757757</pre><p id="rfc.section.5.4.2.p.3">A server <em class="bcp14">MAY</em> ignore the Range header. However, HTTP/1.1 origin servers and intermediate caches ought to support byte ranges when possible,
    758758         since Range supports efficient recovery from partially failed transfers, and supports efficient partial retrieval of large
Note: See TracChangeset for help on using the changeset viewer.