[−][src]Struct headers::Pragma
The Pragma
header defined by HTTP/1.0.
The "Pragma" header field allows backwards compatibility with HTTP/1.0 caches, so that clients can specify a "no-cache" request that they will understand (as Cache-Control was not defined until HTTP/1.1). When the Cache-Control header field is also present and understood in a request, Pragma is ignored. In HTTP/1.0, Pragma was defined as an extensible field for implementation-specified directives for recipients. This specification deprecates such extensions to improve interoperability.
Spec: https://tools.ietf.org/html/rfc7234#section-5.4
Examples
use headers::Pragma; let pragma = Pragma::no_cache();
Methods
impl Pragma
[src]
pub fn no_cache() -> Pragma
[src]
Construct the literal no-cache
Pragma header.
pub fn is_no_cache(&self) -> bool
[src]
Return whether this pragma is no-cache
.
Trait Implementations
impl Clone for Pragma
[src]
fn clone(&self) -> Pragma
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl PartialEq<Pragma> for Pragma
[src]
impl Debug for Pragma
[src]
impl Header for Pragma
[src]
fn name() -> &'static HeaderName
[src]
fn decode<'i, I>(values: &mut I) -> Result<Self, Error> where
I: Iterator<Item = &'i HeaderValue>,
[src]
I: Iterator<Item = &'i HeaderValue>,
fn encode<E: Extend<HeaderValue>>(&self, values: &mut E)
[src]
Auto Trait Implementations
Blanket Implementations
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
impl<T> From for T
[src]
impl<T, U> TryFrom for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = !
try_from
)The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
try_from
)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Same for T
type Output = T
Should always be Self