Struct tiny_http::Header [] [src]

pub struct Header {
    pub field: HeaderField,
    pub value: AsciiString,
}

Represents a HTTP header.

Fields

Methods

impl Header
[src]

Builds a Header from two Vec<u8>s or two &[u8]s.

Example:

let header = tiny_http::Header::from_bytes(&b"Content-Type"[..], &b"text/plain"[..]).unwrap();Run

Trait Implementations

impl Debug for Header
[src]

Formats the value using the given formatter.

impl Clone for Header
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl FromStr for Header
[src]

The associated error which can be returned from parsing.

Parses a string s to return a value of this type. Read more

impl Display for Header
[src]

Formats the value using the given formatter.