Struct Builder
pub struct Builder { /* private fields */ }Expand description
A builder for Uris.
This type can be used to construct an instance of Uri
through a builder pattern.
Implementations§
§impl Builder
 
impl Builder
pub fn new() -> Builder
pub fn new() -> Builder
Creates a new default instance of Builder to construct a Uri.
§Examples
let uri = uri::Builder::new()
    .scheme("https")
    .authority("hyper.rs")
    .path_and_query("/")
    .build()
    .unwrap();pub fn scheme<T>(self, scheme: T) -> Builder
pub fn scheme<T>(self, scheme: T) -> Builder
Set the Scheme for this URI.
§Examples
let mut builder = uri::Builder::new();
builder.scheme("https");