Enum vexide_simulator_protocol::Event
source · pub enum Event {
Show 16 variants
Handshake {
version: i32,
extensions: Vec<String>,
},
ScreenDraw {
command: DrawCommand,
color: Color,
background: Color,
},
ScreenClear {
color: Color,
},
ScreenDoubleBufferMode {
enable: bool,
},
ScreenRender,
VCodeSig(VCodeSig),
Ready,
Exited,
Serial {
channel: i32,
data: Vec<u8>,
},
DeviceUpdate {
status: DeviceStatus,
port: Port,
},
Battery(Battery),
RobotPose {
x: f64,
y: f64,
},
RobotState(RobotState),
Log {
level: LogLevel,
message: String,
},
VEXLinkConnect {
port: SmartPort,
id: String,
mode: LinkMode,
override: bool,
},
VEXLinkDisconnect {
port: SmartPort,
},
}Expand description
A message sent from the simulator to the frontend.
Variants§
Handshake
ScreenDraw
ScreenClear
ScreenDoubleBufferMode
ScreenRender
VCodeSig(VCodeSig)
Ready
Exited
Serial
DeviceUpdate
Battery(Battery)
RobotPose
RobotState(RobotState)
Log
VEXLinkConnect
VEXLinkDisconnect
Trait Implementations§
source§impl<'de> Deserialize<'de> for Event
impl<'de> Deserialize<'de> for Event
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
source§impl PartialEq for Event
impl PartialEq for Event
source§impl PartialOrd for Event
impl PartialOrd for Event
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self and other) and is used by the <=
operator. Read moreimpl StructuralPartialEq for Event
Auto Trait Implementations§
impl Freeze for Event
impl RefUnwindSafe for Event
impl Send for Event
impl Sync for Event
impl Unpin for Event
impl UnwindSafe for Event
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