Enum actix_web::http::header::ContentRangeSpec [−][src]
pub enum ContentRangeSpec {
Bytes {
range: Option<(u64, u64)>,
instance_length: Option<u64>,
},
Unregistered {
unit: String,
resp: String,
},
}
Expand description
Content-Range, described in RFC7233
ABNF
Content-Range = byte-content-range
/ other-content-range
byte-content-range = bytes-unit SP
( byte-range-resp / unsatisfied-range )
byte-range-resp = byte-range "/" ( complete-length / "*" )
byte-range = first-byte-pos "-" last-byte-pos
unsatisfied-range = "*/" complete-length
complete-length = 1*DIGIT
other-content-range = other-range-unit SP other-range-resp
other-range-resp = *CHAR
Variants
Bytes
Fields
Byte range
Unregistered
Custom range, with unit not registered at IANA
Trait Implementations
type Err = ParseError
type Err = ParseError
The associated error which can be returned from parsing.
Parses a string s
to return a value of this type. Read more
type Error = InvalidHeaderValue
type Error = InvalidHeaderValue
The type returned in the event of a conversion error.
Try to convert value to a Header value.
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
This method tests for !=
.
Auto Trait Implementations
impl RefUnwindSafe for ContentRangeSpec
impl Send for ContentRangeSpec
impl Sync for ContentRangeSpec
impl Unpin for ContentRangeSpec
impl UnwindSafe for ContentRangeSpec
Blanket Implementations
Mutably borrows from an owned value. Read more
Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more