pub struct Server { /* private fields */ }
Implementations§
source§impl Server
impl Server
pub fn new( id: ServerId, app_state: Arc<AppState>, executor: Executor ) -> Arc<Self>
pub async fn start(&self) -> Result<()>
pub fn teardown(&self)
pub fn handle_connection( self: &Arc<Self>, connection: Connection, address: String, user: User, send_connection_id: Option<Sender<ConnectionId>>, executor: Executor ) -> impl Future<Output = Result<()>>
pub async fn invite_code_redeemed( self: &Arc<Self>, inviter_id: UserId, invitee_id: UserId ) -> Result<()>
pub async fn invite_count_updated( self: &Arc<Self>, user_id: UserId ) -> Result<()>
pub async fn snapshot<'a>(self: &'a Arc<Self>) -> ServerSnapshot<'a>
Auto Trait Implementations§
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