Struct http_stub::header::AccessControlExposeHeaders [] [src]

pub struct AccessControlExposeHeaders(pub Vec<UniCase<String>>);

Access-Control-Expose-Headers header, part of CORS

The Access-Control-Expose-Headers header indicates which headers are safe to expose to the API of a CORS API specification.

ABNF

Access-Control-Expose-Headers = "Access-Control-Expose-Headers" ":" #field-name

Example values

Examples

// extern crate unicase;

use hyper::header::{Headers, AccessControlExposeHeaders};
use unicase::UniCase;

let mut headers = Headers::new();
headers.set(
    AccessControlExposeHeaders(vec![
        UniCase("etag".to_owned()),
        UniCase("content-length".to_owned())
    ])
);
// extern crate unicase;

use hyper::header::{Headers, AccessControlExposeHeaders};
use unicase::UniCase;

let mut headers = Headers::new();
headers.set(
    AccessControlExposeHeaders(vec![
        UniCase("etag".to_owned()),
        UniCase("content-length".to_owned())
    ])
);

Trait Implementations

impl Display for AccessControlExposeHeaders

fn fmt(&self, f: &mut Formatter) -> Result<(), Error>

impl HeaderFormat for AccessControlExposeHeaders

fn fmt_header(&self, f: &mut Formatter) -> Result<(), Error>

impl Header for AccessControlExposeHeaders

fn header_name() -> &'static str

fn parse_header(raw: &[Vec<u8>]) -> Result<AccessControlExposeHeaders, Error>

impl DerefMut for AccessControlExposeHeaders

fn deref_mut(&mut self) -> &mut Vec<UniCase<String>>

impl Deref for AccessControlExposeHeaders

type Target = Vec<UniCase<String>>

fn deref(&self) -> &Vec<UniCase<String>>

Derived Implementations

impl Clone for AccessControlExposeHeaders

fn clone(&self) -> AccessControlExposeHeaders

impl Debug for AccessControlExposeHeaders

fn fmt(&self, __arg_0: &mut Formatter) -> Result<(), Error>

impl PartialEq<AccessControlExposeHeaders> for AccessControlExposeHeaders

fn eq(&self, __arg_0: &AccessControlExposeHeaders) -> bool

fn ne(&self, __arg_0: &AccessControlExposeHeaders) -> bool