Struct ascom_alpaca::BoundServer
source · pub struct BoundServer { /* private fields */ }
Available on crate feature
server
only.Expand description
Alpaca servers bound to their respective ports and ready to listen.
Implementations§
source§impl BoundServer
impl BoundServer
sourcepub fn listen_addr(&self) -> SocketAddr
pub fn listen_addr(&self) -> SocketAddr
Returns the address the main Alpaca server is listening on.
sourcepub fn discovery_listen_addr(&self) -> SocketAddr
pub fn discovery_listen_addr(&self) -> SocketAddr
Returns the address the discovery server is listening on.
sourcepub async fn start(self) -> Result<Infallible>
pub async fn start(self) -> Result<Infallible>
Starts the Alpaca and discovery servers.
Note: this function starts an infinite async loop and it’s your responsibility to spawn it off
via tokio::spawn
if necessary.
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for BoundServer
impl Send for BoundServer
impl !Sync for BoundServer
impl Unpin for BoundServer
impl !UnwindSafe for BoundServer
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