pub struct ServerState {
pub players: DashMap<String, ConnectedPlayer>,
pub rooms: DashMap<String, Room>,
pub server_key: String,
pub max_rooms: usize,
pub official_key: Option<String>,
pub analytics: AnalyticsHandle,
pub deck_play_events: DeckPlayEventHandle,
pub identity: IdentityVerifier,
}Fields§
§players: DashMap<String, ConnectedPlayer>§rooms: DashMap<String, Room>§server_key: String§max_rooms: usize§official_key: Option<String>§analytics: AnalyticsHandle§deck_play_events: DeckPlayEventHandle§identity: IdentityVerifierImplementations§
Source§impl ServerState
impl ServerState
pub fn new( server_key: String, max_rooms: usize, official_key: Option<String>, analytics: AnalyticsHandle, deck_play_events: DeckPlayEventHandle, hub_jwks_url: Option<String>, ) -> Self
pub fn session_by_username(&self, username: &str) -> Option<UsernameSession>
Auto Trait Implementations§
impl !Freeze for ServerState
impl !RefUnwindSafe for ServerState
impl !UnwindSafe for ServerState
impl Send for ServerState
impl Sync for ServerState
impl Unpin for ServerState
impl UnsafeUnpin for ServerState
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