Struct email::Header
[−]
[src]
pub struct Header { pub name: String, // some fields omitted }
Represents an RFC 822 Header [unstable]
Fields
name: String
The name of this header
Methods
impl Header
[src]
fn new(name: String, value: String) -> Header
Creates a new Header for the given name
and value
[unstable]
fn new_with_value<T: ToFoldedHeader>(
name: String,
value: T
) -> ParsingResult<Header>
name: String,
value: T
) -> ParsingResult<Header>
Creates a new Header for the given name
and value
,
as converted through the ToHeader
or ToFoldedHeader
trait.
Returns None if the value failed to be converted. [unstable]
fn get_value<T: FromHeader>(&self) -> ParsingResult<T>
Get the value represented by this header, as parsed
into whichever type T
[unstable]
Trait Implementations
impl PartialEq for Header
[src]
fn eq(&self, __arg_0: &Header) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &Header) -> bool
This method tests for !=
.
impl Eq for Header
[src]
impl Clone for Header
[src]
fn clone(&self) -> Header
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more
impl Debug for Header
[src]
impl Hash for Header
[src]
fn hash<__H: Hasher>(&self, __arg_0: &mut __H)
Feeds this value into the given [Hasher
]. Read more
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0
H: Hasher,
Feeds a slice of this type into the given [Hasher
]. Read more