#[non_exhaustive]pub struct CreateOrJoinLobby {
pub secret: CompactString,
pub idle_timeout_seconds: Option<u32>,
pub lobby_metadata: Option<LobbyMetadata>,
pub member_metadata: Option<LobbyMetadata>,
}Expand description
The body of Create or Join Lobby.
The secret is redacted in the Debug output: anyone who knows it can join the lobby.
discord.js counterpart: none (lobbies are not in discord.js v14 or discord-api-types).
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.secret: CompactStringIdentifies the lobby among the application’s lobbies (up to 250 characters).
idle_timeout_seconds: Option<u32>How many seconds an idle lobby lives before it is shut down (5 to 604 800).
lobby_metadata: Option<LobbyMetadata>Replaces the lobby’s metadata.
member_metadata: Option<LobbyMetadata>Sets the calling user’s member metadata.
Implementations§
Source§impl CreateOrJoinLobby
impl CreateOrJoinLobby
Sourcepub fn new(secret: impl Into<CompactString>) -> Self
pub fn new(secret: impl Into<CompactString>) -> Self
Creates the lobby with secret, or joins it if it exists.
discord.js counterpart: none (lobbies are not in discord.js v14 or discord-api-types).
Trait Implementations§
Source§impl Clone for CreateOrJoinLobby
impl Clone for CreateOrJoinLobby
Source§impl Debug for CreateOrJoinLobby
impl Debug for CreateOrJoinLobby
impl Eq for CreateOrJoinLobby
Source§impl PartialEq for CreateOrJoinLobby
impl PartialEq for CreateOrJoinLobby
Source§impl Serialize for CreateOrJoinLobby
impl Serialize for CreateOrJoinLobby
impl StructuralPartialEq for CreateOrJoinLobby
Auto Trait Implementations§
impl Forget for CreateOrJoinLobby
impl Freeze for CreateOrJoinLobby
impl Move for CreateOrJoinLobby
impl RefUnwindSafe for CreateOrJoinLobby
impl Send for CreateOrJoinLobby
impl Sync for CreateOrJoinLobby
impl Unpin for CreateOrJoinLobby
impl UnsafeUnpin for CreateOrJoinLobby
impl UnwindSafe for CreateOrJoinLobby
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