pub struct Server { /* private fields */ }Expand description
A server ready to run: bound, with its tokens resolved.
Implementations§
Source§impl Server
impl Server
Sourcepub async fn bind(config: ServerConfig, engine: Engine) -> Result<Self, Error>
pub async fn bind(config: ServerConfig, engine: Engine) -> Result<Self, Error>
Validates the exposure, resolves tokens and binds. Fails before binding anything if the configuration is unsafe.
Sourcepub fn address(&self) -> String
pub fn address(&self) -> String
Where the server is listening, e.g. unix:/run/user/1000/loqui/loqui.sock.
pub fn token_source(&self) -> &TokenSource
pub fn listen(&self) -> &Listen
Auto Trait Implementations§
impl !Freeze for Server
impl !RefUnwindSafe for Server
impl !UnwindSafe for Server
impl Send for Server
impl Sync for Server
impl Unpin for Server
impl UnsafeUnpin 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