pub struct Builder { /* private fields */ }
Expand description
Builder for the Server type
Implementations
sourceimpl Builder
impl Builder
sourcepub fn configure_router<F>(self, config_fn: F) -> Selfwhere
F: Fn(RouterBuilder) -> RouterBuilder,
pub fn configure_router<F>(self, config_fn: F) -> Selfwhere
F: Fn(RouterBuilder) -> RouterBuilder,
This method will call the provided closure with a mutable ref of the router Once into the closure it is possible to add controllers to the router.
sourcepub fn configure_middlewares<F>(self, config_fn: F) -> Selfwhere
F: Fn(MidStackBuilder) -> MidStackBuilder,
pub fn configure_middlewares<F>(self, config_fn: F) -> Selfwhere
F: Fn(MidStackBuilder) -> MidStackBuilder,
This method will call the provided closure with a mutable ref of the middleware_stack Once into the closure it is possible to add middlewares to the middleware_stack.
sourcepub fn configure_listener<F>(self, config_fn: F) -> Selfwhere
F: Fn(ListenerBuilder) -> ListenerBuilder,
pub fn configure_listener<F>(self, config_fn: F) -> Selfwhere
F: Fn(ListenerBuilder) -> ListenerBuilder,
This method will call the provided closure with a mutable ref of the listener configurations Once into the closure it is possible to set the uri and ssl file paths.
Auto Trait Implementations
impl !RefUnwindSafe for Builder
impl Send for Builder
impl Sync for Builder
impl Unpin for Builder
impl !UnwindSafe for Builder
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more