pub enum PlayerChatUpdate {
Variant0 {
destination: PlayerChatUpdateVariant0Destination,
message: String,
type_: Value,
user_id: UserId,
},
Variant1 {
destination: Value,
message: String,
to_user_id: UserId,
type_: Value,
user_id: UserId,
},
}Expand description
PlayerChatUpdate
JSON schema
{
"title": "PlayerChatUpdate",
"anyOf": [
{
"type": "object",
"required": [
"destination",
"message",
"type",
"userId"
],
"properties": {
"destination": {
"enum": [
"allies",
"all",
"spectators"
]
},
"message": {
"type": "string"
},
"type": {
"const": "player_chat"
},
"userId": {
"$ref": "#/definitions/userId"
}
}
},
{
"type": "object",
"required": [
"destination",
"message",
"toUserId",
"type",
"userId"
],
"properties": {
"destination": {
"const": "player"
},
"message": {
"type": "string"
},
"toUserId": {
"$ref": "#/definitions/userId"
},
"type": {
"const": "player_chat"
},
"userId": {
"$ref": "#/definitions/userId"
}
}
}
]
}Variants§
Trait Implementations§
Source§impl Clone for PlayerChatUpdate
impl Clone for PlayerChatUpdate
Source§fn clone(&self) -> PlayerChatUpdate
fn clone(&self) -> PlayerChatUpdate
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for PlayerChatUpdate
impl Debug for PlayerChatUpdate
Source§impl<'de> Deserialize<'de> for PlayerChatUpdate
impl<'de> Deserialize<'de> for PlayerChatUpdate
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for PlayerChatUpdate
impl RefUnwindSafe for PlayerChatUpdate
impl Send for PlayerChatUpdate
impl Sync for PlayerChatUpdate
impl Unpin for PlayerChatUpdate
impl UnsafeUnpin for PlayerChatUpdate
impl UnwindSafe for PlayerChatUpdate
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