pub struct ServerBuilder { /* private fields */ }
Implementations§
source§impl ServerBuilder
impl ServerBuilder
sourcepub fn new() -> ServerBuilder
pub fn new() -> ServerBuilder
Constructs a new ServerBuilder
.
source§impl ServerBuilder
impl ServerBuilder
sourcepub fn description<S: Into<String>>(self, description: Option<S>) -> Self
pub fn description<S: Into<String>>(self, description: Option<S>) -> Self
Add or change description of the Server
.
sourcepub fn parameter<N: Into<String>, V: Into<ServerVariable>>(
self,
name: N,
variable: V,
) -> Self
pub fn parameter<N: Into<String>, V: Into<ServerVariable>>( self, name: N, variable: V, ) -> Self
Add parameter to Server
which is used to substitute values in Server::url
.
name
Defines name of the parameter which is being substituted within the url. If url has{username}
substitution then the name should beusername
.parameter
UseServerVariableBuilder
to define how the parameter is being substituted within the url.
Trait Implementations§
source§impl Default for ServerBuilder
impl Default for ServerBuilder
source§impl From<Server> for ServerBuilder
impl From<Server> for ServerBuilder
source§impl From<ServerBuilder> for Server
impl From<ServerBuilder> for Server
source§fn from(value: ServerBuilder) -> Self
fn from(value: ServerBuilder) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for ServerBuilder
impl RefUnwindSafe for ServerBuilder
impl Send for ServerBuilder
impl Sync for ServerBuilder
impl Unpin for ServerBuilder
impl UnwindSafe for ServerBuilder
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more