pub struct LuaScriptRegistry { /* private fields */ }Implementations§
Source§impl LuaScriptRegistry
impl LuaScriptRegistry
pub async fn execute( &self, script_id: &str, context: LuaContext, ) -> Result<LuaExecutionResult, LuaRegistryError>
pub async fn execute_with_cancellation( &self, script_id: &str, context: LuaContext, cancellation: LuaCancellationToken, ) -> Result<LuaExecutionResult, LuaRegistryError>
Source§impl LuaScriptRegistry
impl LuaScriptRegistry
pub fn new() -> Result<Self, LuaRegistryError>
pub fn from_config(config: &LuaEngineConfig) -> Result<Self, LuaRegistryError>
pub fn register(&self, script: LuaScript) -> Result<(), LuaRegistryError>
pub fn get( &self, script_id: &str, ) -> Result<Option<LuaScriptManifest>, LuaRegistryError>
pub fn list_all(&self) -> Result<Vec<LuaScriptManifest>, LuaRegistryError>
pub fn list_enabled(&self) -> Result<Vec<LuaScriptManifest>, LuaRegistryError>
pub fn list_by_category( &self, category: ScriptCategory, ) -> Result<Vec<LuaScriptManifest>, LuaRegistryError>
pub fn get_history( &self, script_id: &str, ) -> Result<Vec<LuaExecutionReceipt>, LuaRegistryError>
pub fn get_recent_history( &self, script_id: &str, count: usize, ) -> Result<Vec<LuaExecutionReceipt>, LuaRegistryError>
pub fn count(&self) -> Result<usize, LuaRegistryError>
pub fn enabled_count(&self) -> Result<usize, LuaRegistryError>
pub fn set_enabled( &self, script_id: &str, enabled: bool, ) -> Result<(), LuaRegistryError>
pub fn unregister(&self, script_id: &str) -> Result<(), LuaRegistryError>
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for LuaScriptRegistry
impl !UnwindSafe for LuaScriptRegistry
impl Freeze for LuaScriptRegistry
impl Send for LuaScriptRegistry
impl Sync for LuaScriptRegistry
impl Unpin for LuaScriptRegistry
impl UnsafeUnpin for LuaScriptRegistry
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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