pub struct Date(pub Vec<u8>);Expand description
The Date header (RFC 3261 §20.17).
SIP narrows HTTP’s three date formats to one: RFC 1123 with the zone spelled GMT and
nothing else. RFC 4475 §3.1.2.12 sends EST and expects it to be refused, so the zone is
not cosmetic — accepting it would mean accepting a time that is wrong by hours.
Tuple Fields§
§0: Vec<u8>Trait Implementations§
Source§impl TypedHeader for Date
impl TypedHeader for Date
Source§const NAME: HeaderName = HeaderName::Date
const NAME: HeaderName = HeaderName::Date
The header this type reads.
Source§fn decode(value: &[u8]) -> Result<Self, HeaderError>
fn decode(value: &[u8]) -> Result<Self, HeaderError>
Parse one header value. The value arrives unfolded and trimmed.
Source§const VALIDATE_LIST: bool = false
const VALIDATE_LIST: bool = false
Whether
Headers::typed_all must collect and validate the complete field before yielding. Read moreSource§fn decode_list(value: &[u8]) -> Result<Vec<Self>, HeaderError>
fn decode_list(value: &[u8]) -> Result<Vec<Self>, HeaderError>
Parse every value in one header row. Read more
Source§fn validate_list(_values: &[&Self]) -> Result<(), HeaderError>
fn validate_list(_values: &[&Self]) -> Result<(), HeaderError>
Validate all decoded values of this field across the complete message. Read more
impl Eq for Date
impl StructuralPartialEq for Date
Auto Trait Implementations§
impl Freeze for Date
impl RefUnwindSafe for Date
impl Send for Date
impl Sync for Date
impl Unpin for Date
impl UnsafeUnpin for Date
impl UnwindSafe for Date
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