pub struct Script { /* private fields */ }
Expand description
A script abstraction
Implementations§
Source§impl Script
impl Script
Sourcepub fn metadata(&self) -> &ScriptInfo
pub fn metadata(&self) -> &ScriptInfo
Returns the script metadata
Sourcepub fn deactivate(&mut self)
pub fn deactivate(&mut self)
Deactivate a script, inactive scripts will not react to hooks
Sourcepub fn is_listening_for<H: Hook>(&self) -> bool
pub fn is_listening_for<H: Hook>(&self) -> bool
Check if a script is listening for a hook
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Script
impl RefUnwindSafe for Script
impl Send for Script
impl Sync for Script
impl Unpin for Script
impl UnwindSafe for Script
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