Optionalchecktrue to throw an ERR_HTTP_RESOURCE_CHANGED error when the ETag, Last-Modified or total size headers
returned by a range request differ from the ones returned by the first range request, i.e. when the resource has
been modified while being read. Headers missing from the responses are ignored, note that Access-Control-Expose-Headers
must include them when the resource is fetched cross-origin.
OptionalheadersThe HTTP headers.
OptionalmaximumThe maximum size in bytes of the range requests sent to read the data of an entry. The data is read with as many range requests as necessary, each response body being streamed, so that the size of a request never depends on the size of the entry.
Because response bodies are streamed with backpressure, this value does not bound how much data
is buffered in memory; it bounds the byte span, and therefore the lifetime, of each individual
range request. Smaller windows keep each request short-lived, which avoids the idle or duration
timeouts enforced by servers, CDNs and proxies when a slow consumer holds a connection open, and
avoids relying on the server honoring very large ranges. Set it to Infinity to disable windowing
and read each entry with a single range request covering its whole remaining length.
Optionalusetrue to rely XMLHttpRequest instead of fetch to fetch data.
OptionalfetchThe function used to fetch the data. It takes precedence over HttpRangeOptions#useXHR
when set. The returned object must expose the status, statusText and headers properties,
and the arrayBuffer() method of the Response class.
Optionalinit: RequestInit
Represents options passed to the constructor of HttpRangeReader and HttpReader.