pub enum EventResult {
Action {
event_name: String,
context: HashMap<String, Value>,
want_response: bool,
response_path: Option<String>,
},
DataUpdate {
path: String,
value: Value,
},
Toggle {
path: String,
},
Consumed,
}Expand description
Result produced by a component handling an input event.
Variants§
Action
Dispatch an action to the server.
Fields
DataUpdate
Write a value back to the data model at the given path.
Toggle
Toggle a boolean value in the data model.
Consumed
Component consumed the event; no further processing needed.
Trait Implementations§
Source§impl Clone for EventResult
impl Clone for EventResult
Source§fn clone(&self) -> EventResult
fn clone(&self) -> EventResult
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for EventResult
impl RefUnwindSafe for EventResult
impl Send for EventResult
impl Sync for EventResult
impl Unpin for EventResult
impl UnsafeUnpin for EventResult
impl UnwindSafe for EventResult
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