pub struct Server { /* private fields */ }Implementations§
Source§impl Server
impl Server
pub fn new( serving_url: &str, pool_size: u8, routes_list: Option<HashMap<(Rt, String), Rh>>, ) -> Result<Server, Error>
pub fn set_auto_close(&mut self, active: bool)
pub fn add_route(&mut self, path: &str, rt: Rt, rh: fn(&Request) -> Response)
pub fn add_files_source<S>(&mut self, base: S)
pub fn run(&self)
pub fn stop(&self)
Auto Trait Implementations§
impl Freeze for Server
impl RefUnwindSafe for Server
impl Send for Server
impl Sync for Server
impl Unpin for Server
impl UnwindSafe for Server
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