pub struct SpellLock { /* private fields */ }Expand description
SpellLock is a struct which represents a window lock. It can be run and initialised on a custom lockscreen implementation with slint. Know limitations include the abscence to verify from fingerprints and unideal issues on multi-monitor setup. You can add the path of binary of your lock in your compositor config and idle manager config to use the program. It will be linked to spell-cli directly in coming releases.
§Example
Here is a minimal example of rust side, for complete code of slint, check the codebase of young-shell.
use spell_framework::cast_spell;
use std::{error::Error, sync::{Arc, RwLock}};
use slint::ComponentHandle;
use spell_framework::{layer_properties::ForeignController, wayland_adapter::SpellLock};
slint::include_modules!();
fn main() -> Result<(), Box<dyn Error>> {
let lock = SpellLock::invoke_lock_spell();
let lock_ui = LockScreen::new().unwrap();
let looop_handle = lock.get_handler();
lock_ui.on_check_pass({
let lock_handle = lock_ui.as_weak();
move |string_val| {
let lock_handle_a = lock_handle.clone().unwrap();
let lock_handle_b = lock_handle.clone().unwrap();
looop_handle.unlock(
None,
string_val.to_string(),
Box::new(move || {
lock_handle_a.set_lock_error(true);
}),
Box::new(move || {
lock_handle_b.set_is_lock_activated(false);
}),
);
}
});
lock_ui.set_is_lock_activated(true);
cast_spell(
lock,
None,
None::<fn(Arc<RwLock<Box<dyn ForeignController>>>)>,
)
}Implementations§
Source§impl SpellLock
impl SpellLock
Sourcepub fn invoke_lock_spell() -> Self
pub fn invoke_lock_spell() -> Self
This function creates an instance of SpellLock which can be combined with slint windows to create a lockscreen.
Sourcepub fn get_handler(&self) -> LockHandle
pub fn get_handler(&self) -> LockHandle
Provides a lockscreen handler used to invoke the unlock
callback with the user entered password.For more details
view LockHandle.
Trait Implementations§
Source§impl CompositorHandler for SpellLock
impl CompositorHandler for SpellLock
Source§fn scale_factor_changed(
&mut self,
_conn: &Connection,
_qh: &QueueHandle<Self>,
_surface: &WlSurface,
_new_factor: i32,
)
fn scale_factor_changed( &mut self, _conn: &Connection, _qh: &QueueHandle<Self>, _surface: &WlSurface, _new_factor: i32, )
Source§fn transform_changed(
&mut self,
_conn: &Connection,
_qh: &QueueHandle<Self>,
_surface: &WlSurface,
_new_transform: Transform,
)
fn transform_changed( &mut self, _conn: &Connection, _qh: &QueueHandle<Self>, _surface: &WlSurface, _new_transform: Transform, )
Source§fn frame(
&mut self,
_conn: &Connection,
qh: &QueueHandle<Self>,
_surface: &WlSurface,
_time: u32,
)
fn frame( &mut self, _conn: &Connection, qh: &QueueHandle<Self>, _surface: &WlSurface, _time: u32, )
Source§fn surface_enter(
&mut self,
_conn: &Connection,
_qh: &QueueHandle<Self>,
_surface: &WlSurface,
_output: &WlOutput,
)
fn surface_enter( &mut self, _conn: &Connection, _qh: &QueueHandle<Self>, _surface: &WlSurface, _output: &WlOutput, )
Source§fn surface_leave(
&mut self,
_conn: &Connection,
_qh: &QueueHandle<Self>,
_surface: &WlSurface,
_output: &WlOutput,
)
fn surface_leave( &mut self, _conn: &Connection, _qh: &QueueHandle<Self>, _surface: &WlSurface, _output: &WlOutput, )
Source§impl Dispatch<ExtSessionLockManagerV1, GlobalData> for SpellLock
impl Dispatch<ExtSessionLockManagerV1, GlobalData> for SpellLock
Source§fn event(
state: &mut Self,
proxy: &ExtSessionLockManagerV1,
event: <ExtSessionLockManagerV1 as Proxy>::Event,
data: &GlobalData,
conn: &Connection,
qhandle: &QueueHandle<Self>,
)
fn event( state: &mut Self, proxy: &ExtSessionLockManagerV1, event: <ExtSessionLockManagerV1 as Proxy>::Event, data: &GlobalData, conn: &Connection, qhandle: &QueueHandle<Self>, )
Source§fn event_created_child(
opcode: u16,
qhandle: &QueueHandle<Self>,
) -> Arc<dyn ObjectData>
fn event_created_child( opcode: u16, qhandle: &QueueHandle<Self>, ) -> Arc<dyn ObjectData>
Source§impl Dispatch<ExtSessionLockSurfaceV1, SessionLockSurfaceData> for SpellLock
impl Dispatch<ExtSessionLockSurfaceV1, SessionLockSurfaceData> for SpellLock
Source§fn event(
state: &mut Self,
proxy: &ExtSessionLockSurfaceV1,
event: <ExtSessionLockSurfaceV1 as Proxy>::Event,
data: &SessionLockSurfaceData,
conn: &Connection,
qhandle: &QueueHandle<Self>,
)
fn event( state: &mut Self, proxy: &ExtSessionLockSurfaceV1, event: <ExtSessionLockSurfaceV1 as Proxy>::Event, data: &SessionLockSurfaceData, conn: &Connection, qhandle: &QueueHandle<Self>, )
Source§fn event_created_child(
opcode: u16,
qhandle: &QueueHandle<Self>,
) -> Arc<dyn ObjectData>
fn event_created_child( opcode: u16, qhandle: &QueueHandle<Self>, ) -> Arc<dyn ObjectData>
Source§impl Dispatch<ExtSessionLockV1, SessionLockData> for SpellLock
impl Dispatch<ExtSessionLockV1, SessionLockData> for SpellLock
Source§fn event(
state: &mut Self,
proxy: &ExtSessionLockV1,
event: <ExtSessionLockV1 as Proxy>::Event,
data: &SessionLockData,
conn: &Connection,
qhandle: &QueueHandle<Self>,
)
fn event( state: &mut Self, proxy: &ExtSessionLockV1, event: <ExtSessionLockV1 as Proxy>::Event, data: &SessionLockData, conn: &Connection, qhandle: &QueueHandle<Self>, )
Source§fn event_created_child(
opcode: u16,
qhandle: &QueueHandle<Self>,
) -> Arc<dyn ObjectData>
fn event_created_child( opcode: u16, qhandle: &QueueHandle<Self>, ) -> Arc<dyn ObjectData>
Source§impl Dispatch<WlCallback, WlSurface> for SpellLock
impl Dispatch<WlCallback, WlSurface> for SpellLock
Source§fn event(
state: &mut Self,
proxy: &WlCallback,
event: <WlCallback as Proxy>::Event,
data: &WlSurface,
conn: &Connection,
qhandle: &QueueHandle<Self>,
)
fn event( state: &mut Self, proxy: &WlCallback, event: <WlCallback as Proxy>::Event, data: &WlSurface, conn: &Connection, qhandle: &QueueHandle<Self>, )
Source§fn event_created_child(
opcode: u16,
qhandle: &QueueHandle<Self>,
) -> Arc<dyn ObjectData>
fn event_created_child( opcode: u16, qhandle: &QueueHandle<Self>, ) -> Arc<dyn ObjectData>
Source§impl Dispatch<WlCompositor, GlobalData> for SpellLock
impl Dispatch<WlCompositor, GlobalData> for SpellLock
Source§fn event(
state: &mut Self,
proxy: &WlCompositor,
event: <WlCompositor as Proxy>::Event,
data: &GlobalData,
conn: &Connection,
qhandle: &QueueHandle<Self>,
)
fn event( state: &mut Self, proxy: &WlCompositor, event: <WlCompositor as Proxy>::Event, data: &GlobalData, conn: &Connection, qhandle: &QueueHandle<Self>, )
Source§fn event_created_child(
opcode: u16,
qhandle: &QueueHandle<Self>,
) -> Arc<dyn ObjectData>
fn event_created_child( opcode: u16, qhandle: &QueueHandle<Self>, ) -> Arc<dyn ObjectData>
Source§impl Dispatch<WlKeyboard, KeyboardData<SpellLock>> for SpellLock
impl Dispatch<WlKeyboard, KeyboardData<SpellLock>> for SpellLock
Source§fn event(
state: &mut Self,
proxy: &WlKeyboard,
event: <WlKeyboard as Proxy>::Event,
data: &KeyboardData<SpellLock>,
conn: &Connection,
qhandle: &QueueHandle<Self>,
)
fn event( state: &mut Self, proxy: &WlKeyboard, event: <WlKeyboard as Proxy>::Event, data: &KeyboardData<SpellLock>, conn: &Connection, qhandle: &QueueHandle<Self>, )
Source§fn event_created_child(
opcode: u16,
qhandle: &QueueHandle<Self>,
) -> Arc<dyn ObjectData>
fn event_created_child( opcode: u16, qhandle: &QueueHandle<Self>, ) -> Arc<dyn ObjectData>
Source§impl Dispatch<WlOutput, OutputData> for SpellLock
impl Dispatch<WlOutput, OutputData> for SpellLock
Source§fn event(
state: &mut Self,
proxy: &WlOutput,
event: <WlOutput as Proxy>::Event,
data: &OutputData,
conn: &Connection,
qhandle: &QueueHandle<Self>,
)
fn event( state: &mut Self, proxy: &WlOutput, event: <WlOutput as Proxy>::Event, data: &OutputData, conn: &Connection, qhandle: &QueueHandle<Self>, )
Source§fn event_created_child(
opcode: u16,
qhandle: &QueueHandle<Self>,
) -> Arc<dyn ObjectData>
fn event_created_child( opcode: u16, qhandle: &QueueHandle<Self>, ) -> Arc<dyn ObjectData>
Source§impl Dispatch<WlPointer, PointerData> for SpellLock
impl Dispatch<WlPointer, PointerData> for SpellLock
Source§fn event(
state: &mut Self,
proxy: &WlPointer,
event: <WlPointer as Proxy>::Event,
data: &PointerData,
conn: &Connection,
qhandle: &QueueHandle<Self>,
)
fn event( state: &mut Self, proxy: &WlPointer, event: <WlPointer as Proxy>::Event, data: &PointerData, conn: &Connection, qhandle: &QueueHandle<Self>, )
Source§fn event_created_child(
opcode: u16,
qhandle: &QueueHandle<Self>,
) -> Arc<dyn ObjectData>
fn event_created_child( opcode: u16, qhandle: &QueueHandle<Self>, ) -> Arc<dyn ObjectData>
Source§impl Dispatch<WlRegistry, GlobalListContents> for SpellLock
impl Dispatch<WlRegistry, GlobalListContents> for SpellLock
Source§fn event(
state: &mut Self,
proxy: &WlRegistry,
event: <WlRegistry as Proxy>::Event,
data: &GlobalListContents,
conn: &Connection,
qhandle: &QueueHandle<Self>,
)
fn event( state: &mut Self, proxy: &WlRegistry, event: <WlRegistry as Proxy>::Event, data: &GlobalListContents, conn: &Connection, qhandle: &QueueHandle<Self>, )
Source§fn event_created_child(
opcode: u16,
qhandle: &QueueHandle<Self>,
) -> Arc<dyn ObjectData>
fn event_created_child( opcode: u16, qhandle: &QueueHandle<Self>, ) -> Arc<dyn ObjectData>
Source§impl Dispatch<WlSeat, SeatData> for SpellLock
impl Dispatch<WlSeat, SeatData> for SpellLock
Source§fn event(
state: &mut Self,
proxy: &WlSeat,
event: <WlSeat as Proxy>::Event,
data: &SeatData,
conn: &Connection,
qhandle: &QueueHandle<Self>,
)
fn event( state: &mut Self, proxy: &WlSeat, event: <WlSeat as Proxy>::Event, data: &SeatData, conn: &Connection, qhandle: &QueueHandle<Self>, )
Source§fn event_created_child(
opcode: u16,
qhandle: &QueueHandle<Self>,
) -> Arc<dyn ObjectData>
fn event_created_child( opcode: u16, qhandle: &QueueHandle<Self>, ) -> Arc<dyn ObjectData>
Source§impl Dispatch<WlShm, GlobalData> for SpellLock
impl Dispatch<WlShm, GlobalData> for SpellLock
Source§fn event(
state: &mut Self,
proxy: &WlShm,
event: <WlShm as Proxy>::Event,
data: &GlobalData,
conn: &Connection,
qhandle: &QueueHandle<Self>,
)
fn event( state: &mut Self, proxy: &WlShm, event: <WlShm as Proxy>::Event, data: &GlobalData, conn: &Connection, qhandle: &QueueHandle<Self>, )
Source§fn event_created_child(
opcode: u16,
qhandle: &QueueHandle<Self>,
) -> Arc<dyn ObjectData>
fn event_created_child( opcode: u16, qhandle: &QueueHandle<Self>, ) -> Arc<dyn ObjectData>
Source§impl Dispatch<WlSurface, SurfaceData> for SpellLock
impl Dispatch<WlSurface, SurfaceData> for SpellLock
Source§fn event(
state: &mut Self,
proxy: &WlSurface,
event: <WlSurface as Proxy>::Event,
data: &SurfaceData,
conn: &Connection,
qhandle: &QueueHandle<Self>,
)
fn event( state: &mut Self, proxy: &WlSurface, event: <WlSurface as Proxy>::Event, data: &SurfaceData, conn: &Connection, qhandle: &QueueHandle<Self>, )
Source§fn event_created_child(
opcode: u16,
qhandle: &QueueHandle<Self>,
) -> Arc<dyn ObjectData>
fn event_created_child( opcode: u16, qhandle: &QueueHandle<Self>, ) -> Arc<dyn ObjectData>
Source§impl Dispatch<WpCursorShapeDeviceV1, GlobalData> for SpellLock
impl Dispatch<WpCursorShapeDeviceV1, GlobalData> for SpellLock
Source§fn event(
state: &mut Self,
proxy: &WpCursorShapeDeviceV1,
event: <WpCursorShapeDeviceV1 as Proxy>::Event,
data: &GlobalData,
conn: &Connection,
qhandle: &QueueHandle<Self>,
)
fn event( state: &mut Self, proxy: &WpCursorShapeDeviceV1, event: <WpCursorShapeDeviceV1 as Proxy>::Event, data: &GlobalData, conn: &Connection, qhandle: &QueueHandle<Self>, )
Source§fn event_created_child(
opcode: u16,
qhandle: &QueueHandle<Self>,
) -> Arc<dyn ObjectData>
fn event_created_child( opcode: u16, qhandle: &QueueHandle<Self>, ) -> Arc<dyn ObjectData>
Source§impl Dispatch<WpCursorShapeManagerV1, GlobalData> for SpellLock
impl Dispatch<WpCursorShapeManagerV1, GlobalData> for SpellLock
Source§fn event(
state: &mut Self,
proxy: &WpCursorShapeManagerV1,
event: <WpCursorShapeManagerV1 as Proxy>::Event,
data: &GlobalData,
conn: &Connection,
qhandle: &QueueHandle<Self>,
)
fn event( state: &mut Self, proxy: &WpCursorShapeManagerV1, event: <WpCursorShapeManagerV1 as Proxy>::Event, data: &GlobalData, conn: &Connection, qhandle: &QueueHandle<Self>, )
Source§fn event_created_child(
opcode: u16,
qhandle: &QueueHandle<Self>,
) -> Arc<dyn ObjectData>
fn event_created_child( opcode: u16, qhandle: &QueueHandle<Self>, ) -> Arc<dyn ObjectData>
Source§impl Dispatch<ZxdgOutputManagerV1, GlobalData> for SpellLock
impl Dispatch<ZxdgOutputManagerV1, GlobalData> for SpellLock
Source§fn event(
state: &mut Self,
proxy: &ZxdgOutputManagerV1,
event: <ZxdgOutputManagerV1 as Proxy>::Event,
data: &GlobalData,
conn: &Connection,
qhandle: &QueueHandle<Self>,
)
fn event( state: &mut Self, proxy: &ZxdgOutputManagerV1, event: <ZxdgOutputManagerV1 as Proxy>::Event, data: &GlobalData, conn: &Connection, qhandle: &QueueHandle<Self>, )
Source§fn event_created_child(
opcode: u16,
qhandle: &QueueHandle<Self>,
) -> Arc<dyn ObjectData>
fn event_created_child( opcode: u16, qhandle: &QueueHandle<Self>, ) -> Arc<dyn ObjectData>
Source§impl Dispatch<ZxdgOutputV1, OutputData> for SpellLock
impl Dispatch<ZxdgOutputV1, OutputData> for SpellLock
Source§fn event(
state: &mut Self,
proxy: &ZxdgOutputV1,
event: <ZxdgOutputV1 as Proxy>::Event,
data: &OutputData,
conn: &Connection,
qhandle: &QueueHandle<Self>,
)
fn event( state: &mut Self, proxy: &ZxdgOutputV1, event: <ZxdgOutputV1 as Proxy>::Event, data: &OutputData, conn: &Connection, qhandle: &QueueHandle<Self>, )
Source§fn event_created_child(
opcode: u16,
qhandle: &QueueHandle<Self>,
) -> Arc<dyn ObjectData>
fn event_created_child( opcode: u16, qhandle: &QueueHandle<Self>, ) -> Arc<dyn ObjectData>
Source§impl KeyboardHandler for SpellLock
impl KeyboardHandler for SpellLock
Source§fn enter(
&mut self,
_conn: &Connection,
_qh: &QueueHandle<Self>,
_keyboard: &WlKeyboard,
_surface: &WlSurface,
_serial: u32,
_raw: &[u32],
_keysyms: &[Keysym],
)
fn enter( &mut self, _conn: &Connection, _qh: &QueueHandle<Self>, _keyboard: &WlKeyboard, _surface: &WlSurface, _serial: u32, _raw: &[u32], _keysyms: &[Keysym], )
Source§fn leave(
&mut self,
_conn: &Connection,
_qh: &QueueHandle<Self>,
_keyboard: &WlKeyboard,
_surface: &WlSurface,
_serial: u32,
)
fn leave( &mut self, _conn: &Connection, _qh: &QueueHandle<Self>, _keyboard: &WlKeyboard, _surface: &WlSurface, _serial: u32, )
Source§fn press_key(
&mut self,
_conn: &Connection,
_qh: &QueueHandle<Self>,
_keyboard: &WlKeyboard,
_serial: u32,
event: KeyEvent,
)
fn press_key( &mut self, _conn: &Connection, _qh: &QueueHandle<Self>, _keyboard: &WlKeyboard, _serial: u32, event: KeyEvent, )
Source§fn release_key(
&mut self,
_conn: &Connection,
_qh: &QueueHandle<Self>,
_keyboard: &WlKeyboard,
_serial: u32,
event: KeyEvent,
)
fn release_key( &mut self, _conn: &Connection, _qh: &QueueHandle<Self>, _keyboard: &WlKeyboard, _serial: u32, event: KeyEvent, )
Source§fn update_modifiers(
&mut self,
_conn: &Connection,
_qh: &QueueHandle<Self>,
_keyboard: &WlKeyboard,
_serial: u32,
_modifiers: Modifiers,
_raw_modifiers: RawModifiers,
_layout: u32,
)
fn update_modifiers( &mut self, _conn: &Connection, _qh: &QueueHandle<Self>, _keyboard: &WlKeyboard, _serial: u32, _modifiers: Modifiers, _raw_modifiers: RawModifiers, _layout: u32, )
Source§fn repeat_key(
&mut self,
_conn: &Connection,
_qh: &QueueHandle<Self>,
_keyboard: &WlKeyboard,
_serial: u32,
_event: KeyEvent,
)
fn repeat_key( &mut self, _conn: &Connection, _qh: &QueueHandle<Self>, _keyboard: &WlKeyboard, _serial: u32, _event: KeyEvent, )
Source§fn update_repeat_info(
&mut self,
_conn: &Connection,
_qh: &QueueHandle<Self>,
_keyboard: &WlKeyboard,
_info: RepeatInfo,
)
fn update_repeat_info( &mut self, _conn: &Connection, _qh: &QueueHandle<Self>, _keyboard: &WlKeyboard, _info: RepeatInfo, )
Source§fn update_keymap(
&mut self,
_conn: &Connection,
_qh: &QueueHandle<Self>,
_keyboard: &WlKeyboard,
_keymap: Keymap<'_>,
)
fn update_keymap( &mut self, _conn: &Connection, _qh: &QueueHandle<Self>, _keyboard: &WlKeyboard, _keymap: Keymap<'_>, )
Source§impl OutputHandler for SpellLock
impl OutputHandler for SpellLock
fn output_state(&mut self) -> &mut OutputState
Source§fn new_output(
&mut self,
_conn: &Connection,
_qh: &QueueHandle<Self>,
_output: WlOutput,
)
fn new_output( &mut self, _conn: &Connection, _qh: &QueueHandle<Self>, _output: WlOutput, )
Source§fn update_output(
&mut self,
_conn: &Connection,
_qh: &QueueHandle<Self>,
_output: WlOutput,
)
fn update_output( &mut self, _conn: &Connection, _qh: &QueueHandle<Self>, _output: WlOutput, )
Source§fn output_destroyed(
&mut self,
_conn: &Connection,
_qh: &QueueHandle<Self>,
_output: WlOutput,
)
fn output_destroyed( &mut self, _conn: &Connection, _qh: &QueueHandle<Self>, _output: WlOutput, )
Source§impl PointerHandler for SpellLock
impl PointerHandler for SpellLock
Source§fn pointer_frame(
&mut self,
_conn: &Connection,
qh: &QueueHandle<Self>,
_pointer: &WlPointer,
events: &[PointerEvent],
)
fn pointer_frame( &mut self, _conn: &Connection, qh: &QueueHandle<Self>, _pointer: &WlPointer, events: &[PointerEvent], )
Source§impl ProvidesRegistryState for SpellLock
impl ProvidesRegistryState for SpellLock
Source§fn registry(&mut self) -> &mut RegistryState
fn registry(&mut self) -> &mut RegistryState
Source§fn runtime_add_global(
&mut self,
conn: &Connection,
qh: &QueueHandle<Self>,
name: u32,
interface: &str,
version: u32,
)
fn runtime_add_global( &mut self, conn: &Connection, qh: &QueueHandle<Self>, name: u32, interface: &str, version: u32, )
Source§fn runtime_remove_global(
&mut self,
conn: &Connection,
qh: &QueueHandle<Self>,
name: u32,
interface: &str,
)
fn runtime_remove_global( &mut self, conn: &Connection, qh: &QueueHandle<Self>, name: u32, interface: &str, )
Source§impl SeatHandler for SpellLock
impl SeatHandler for SpellLock
fn seat_state(&mut self) -> &mut SeatState
Source§fn new_seat(&mut self, _: &Connection, _: &QueueHandle<Self>, _: WlSeat)
fn new_seat(&mut self, _: &Connection, _: &QueueHandle<Self>, _: WlSeat)
Source§fn new_capability(
&mut self,
_conn: &Connection,
qh: &QueueHandle<Self>,
seat: WlSeat,
capability: Capability,
)
fn new_capability( &mut self, _conn: &Connection, qh: &QueueHandle<Self>, seat: WlSeat, capability: Capability, )
Source§fn remove_capability(
&mut self,
_conn: &Connection,
_: &QueueHandle<Self>,
_: WlSeat,
capability: Capability,
)
fn remove_capability( &mut self, _conn: &Connection, _: &QueueHandle<Self>, _: WlSeat, capability: Capability, )
Source§fn remove_seat(&mut self, _: &Connection, _: &QueueHandle<Self>, _: WlSeat)
fn remove_seat(&mut self, _: &Connection, _: &QueueHandle<Self>, _: WlSeat)
Source§impl SessionLockHandler for SpellLock
impl SessionLockHandler for SpellLock
Source§fn locked(
&mut self,
_conn: &Connection,
_qh: &QueueHandle<Self>,
_session_lock: SessionLock,
)
fn locked( &mut self, _conn: &Connection, _qh: &QueueHandle<Self>, _session_lock: SessionLock, )
Source§fn finished(
&mut self,
_conn: &Connection,
_qh: &QueueHandle<Self>,
_session_lock: SessionLock,
)
fn finished( &mut self, _conn: &Connection, _qh: &QueueHandle<Self>, _session_lock: SessionLock, )
Source§fn configure(
&mut self,
_conn: &Connection,
qh: &QueueHandle<Self>,
_surface: SessionLockSurface,
_configure: SessionLockSurfaceConfigure,
_serial: u32,
)
fn configure( &mut self, _conn: &Connection, qh: &QueueHandle<Self>, _surface: SessionLockSurface, _configure: SessionLockSurfaceConfigure, _serial: u32, )
Auto Trait Implementations§
impl !Freeze for SpellLock
impl !RefUnwindSafe for SpellLock
impl !Send for SpellLock
impl !Sync for SpellLock
impl Unpin for SpellLock
impl !UnwindSafe for SpellLock
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
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.