Trait zcore_drivers::scheme::EventScheme
source · [−]pub trait EventScheme {
type Event;
fn trigger(&self, event: Self::Event);
fn subscribe(&self, handler: EventHandler<Self::Event>, once: bool);
}
Required Associated Types
Required Methods
Trigger the event manually and call its handler immediately.
fn subscribe(&self, handler: EventHandler<Self::Event>, once: bool)
fn subscribe(&self, handler: EventHandler<Self::Event>, once: bool)
Subscribe events, call the handler
when an input event occurs.
If once
is ture, unsubscribe automatically after handling.
Implementors
sourceimpl EventScheme for Mouse
impl EventScheme for Mouse
type Event = MouseState
sourceimpl EventScheme for MockKeyboard
Available on crate feature mock
only.
impl EventScheme for MockKeyboard
Available on crate feature
mock
only.type Event = InputEvent
sourceimpl EventScheme for MockMouse
Available on crate feature mock
only.
impl EventScheme for MockMouse
Available on crate feature
mock
only.type Event = InputEvent
sourceimpl EventScheme for MockUart
Available on crate feature mock
only.
impl EventScheme for MockUart
Available on crate feature
mock
only.sourceimpl EventScheme for BufferedUart
impl EventScheme for BufferedUart
sourceimpl EventScheme for Uart16550Pmio
impl EventScheme for Uart16550Pmio
sourceimpl EventScheme for UartAllwinner
impl EventScheme for UartAllwinner
sourceimpl EventScheme for VirtIoConsole<'_>
Available on crate feature virtio
only.
impl EventScheme for VirtIoConsole<'_>
Available on crate feature
virtio
only.sourceimpl EventScheme for VirtIoInput<'_>
Available on crate feature virtio
only.
impl EventScheme for VirtIoInput<'_>
Available on crate feature
virtio
only.