Struct headers::common::accept_ranges::AcceptRanges
source · pub struct AcceptRanges(FlatCsv);
Expand description
Accept-Ranges
header, defined in RFC7233
The Accept-Ranges
header field allows a server to indicate that it
supports range requests for the target resource.
ABNF
Accept-Ranges = acceptable-ranges
acceptable-ranges = 1#range-unit / \"none\"
# Example values
* `bytes`
* `none`
* `unknown-unit`
Examples
use headers::{AcceptRanges, HeaderMap, HeaderMapExt};
let mut headers = HeaderMap::new();
headers.typed_insert(AcceptRanges::bytes());
Tuple Fields§
§0: FlatCsv
Implementations§
source§impl AcceptRanges
impl AcceptRanges
Trait Implementations§
source§impl Clone for AcceptRanges
impl Clone for AcceptRanges
source§fn clone(&self) -> AcceptRanges
fn clone(&self) -> AcceptRanges
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for AcceptRanges
impl Debug for AcceptRanges
source§impl Header for AcceptRanges
impl Header for AcceptRanges
source§impl PartialEq<AcceptRanges> for AcceptRanges
impl PartialEq<AcceptRanges> for AcceptRanges
source§fn eq(&self, other: &AcceptRanges) -> bool
fn eq(&self, other: &AcceptRanges) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl StructuralPartialEq for AcceptRanges
Auto Trait Implementations§
impl RefUnwindSafe for AcceptRanges
impl Send for AcceptRanges
impl Sync for AcceptRanges
impl Unpin for AcceptRanges
impl UnwindSafe for AcceptRanges
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more