Struct hyper::header::Location
[−]
[src]
pub struct Location(pub String);
Location
header, defined in
RFC7231
The Location
header field is used in some responses to refer to a
specific resource in relation to the response. The type of
relationship is defined by the combination of request method and
status code semantics.
ABNF
Location = URI-reference
Example values
/People.html#tim
http://www.example.net/index.html
Examples
use hyper::header::{Headers, Location}; let mut headers = Headers::new(); headers.set(Location("/People.html#tim".to_owned()));
use hyper::header::{Headers, Location}; let mut headers = Headers::new(); headers.set(Location("http://www.example.com/index.html".to_owned()));