#[non_exhaustive]pub enum ClientPacket {
}Expand description
All possible client packets.
This contains all valid packets that the client can send to the server (in the current version of the airmash protocol).
Some packets don’t contain any data, these packets do not have an associated struct and as such are just empty variants within this enum.
The From trait has been implemented
for all the structs that correspond to the
variants of this enum. This means that instead
of directly constructing an instance of
ClientPacket, into() can be called
instead.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Login(Login)
Backup(Backup)
Horizon(Horizon)
Ack
Pong(Pong)
Key(Key)
Command(Command)
ScoreDetailed
Chat(Chat)
TeamChat(TeamChat)
Whisper(Whisper)
Say(Say)
VoteMute(VoteMute)
LocalPing(LocalPing)
Trait Implementations§
Source§impl Clone for ClientPacket
impl Clone for ClientPacket
Source§fn clone(&self) -> ClientPacket
fn clone(&self) -> ClientPacket
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 ClientPacket
impl Debug for ClientPacket
Source§impl<'de> DeserializeV5<'de> for ClientPacket
impl<'de> DeserializeV5<'de> for ClientPacket
fn deserialize(de: &mut AirmashDeserializerV5<'de>) -> Result<Self>
Source§impl From<Ack> for ClientPacket
impl From<Ack> for ClientPacket
Source§impl From<Backup> for ClientPacket
impl From<Backup> for ClientPacket
Source§impl From<Chat> for ClientPacket
impl From<Chat> for ClientPacket
Source§impl From<Command> for ClientPacket
impl From<Command> for ClientPacket
Source§impl From<Horizon> for ClientPacket
impl From<Horizon> for ClientPacket
Source§impl From<Key> for ClientPacket
impl From<Key> for ClientPacket
Source§impl From<LocalPing> for ClientPacket
impl From<LocalPing> for ClientPacket
Source§impl From<Login> for ClientPacket
impl From<Login> for ClientPacket
Source§impl From<Pong> for ClientPacket
impl From<Pong> for ClientPacket
Source§impl From<Say> for ClientPacket
impl From<Say> for ClientPacket
Source§impl From<ScoreDetailed> for ClientPacket
impl From<ScoreDetailed> for ClientPacket
Source§fn from(_: ScoreDetailed) -> Self
fn from(_: ScoreDetailed) -> Self
Converts to this type from the input type.
Source§impl From<TeamChat> for ClientPacket
impl From<TeamChat> for ClientPacket
Source§impl From<VoteMute> for ClientPacket
impl From<VoteMute> for ClientPacket
Source§impl From<Whisper> for ClientPacket
impl From<Whisper> for ClientPacket
Source§impl SerializeV5 for ClientPacket
impl SerializeV5 for ClientPacket
fn serialize(&self, ser: &mut AirmashSerializerV5<'_>) -> Result
Auto Trait Implementations§
impl Freeze for ClientPacket
impl RefUnwindSafe for ClientPacket
impl Send for ClientPacket
impl Sync for ClientPacket
impl Unpin for ClientPacket
impl UnwindSafe for ClientPacket
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