pub struct Event {
pub event_type: String,
pub data: EventData,
}Expand description
事件:分发按 event_type 精确匹配,data 直传 handler。
Fields§
§event_type: String事件类型串,如 "eTick." / "eTick.600000" / crate::EVENT_TIMER。
data: EventData载荷;无载荷事件(如 TIMER)默认 EventData 指向 ()。
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for Event
impl !UnwindSafe for Event
impl Freeze for Event
impl Send for Event
impl Sync for Event
impl Unpin for Event
impl UnsafeUnpin 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