Struct salvo::http::headers::Allow [−][src]
pub struct Allow(_);
Expand description
Allow
header, defined in RFC7231
The Allow
header field lists the set of methods advertised as
supported by the target resource. The purpose of this field is
strictly to inform the recipient of valid request methods associated
with the resource.
ABNF
Allow = #method
Example values
GET, HEAD, PUT
OPTIONS, GET, PUT, POST, DELETE, HEAD, TRACE, CONNECT, PATCH, fOObAr
- ``
Examples
extern crate http;
use headers::Allow;
use http::Method;
let allow = vec![Method::GET, Method::POST]
.into_iter()
.collect::<Allow>();
Implementations
Trait Implementations
The name of this header.
Decode this type from an iterator of HeaderValue
s.
Auto Trait Implementations
impl RefUnwindSafe for Allow
impl UnwindSafe for Allow
Blanket Implementations
Mutably borrows from an owned value. Read more
Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
type Output = T
type Output = T
Should always be Self