pub fn partial_bytes_response(
resolution: &RangeResolution,
full: Bytes,
) -> Response<Body>Expand description
Build the in-memory response for a resolved range over full bytes.
Full→200 OK, the whole body,Accept-Ranges: bytes,Content-Length=full.len().Partial→206 Partial Content, the sliced body,Accept-Ranges: bytes,Content-Range: bytes start-end/total,Content-Length= slice length.Unsatisfiable→416 Range Not Satisfiable, empty body,Content-Range: bytes */total.
The caller layers Content-Type / Content-Disposition on top.