Skip to main content

ExecutionStore

Struct ExecutionStore 

Source
pub struct ExecutionStore { /* private fields */ }
Expand description

ExecutionStore - Main store class for managing execution records

Implementations§

Source§

impl ExecutionStore

Source

pub fn new() -> Self

Create a new ExecutionStore with default options

Source

pub fn with_options(options: ExecutionStoreOptions) -> Self

Create a new ExecutionStore with options

Source

pub fn read_lino_records(&self) -> Vec<ExecutionRecord>

Read all execution records from lino file

Source

pub fn save(&self, record: &ExecutionRecord) -> Result<(), String>

Save an execution record (creates or updates)

Source

pub fn get(&self, identifier: &str) -> Option<ExecutionRecord>

Get an execution record by UUID or session name (falls back to options.sessionName)

Source

pub fn get_all(&self) -> Vec<ExecutionRecord>

Get all execution records

Source

pub fn get_by_status(&self, status: ExecutionStatus) -> Vec<ExecutionRecord>

Get records filtered by status

Source

pub fn get_executing(&self) -> Vec<ExecutionRecord>

Get currently executing commands

Source

pub fn get_recent(&self, limit: usize) -> Vec<ExecutionRecord>

Get recently executed commands (sorted by start_time descending)

Source

pub fn cleanup_stale(&self, options: CleanupOptions) -> CleanupResult

Clean up stale “executing” records (processes no longer running or aged out)

Source

pub fn delete(&self, uuid: &str) -> Result<bool, String>

Delete an execution record

Source

pub fn clear(&self) -> Result<(), String>

Delete all records

Source

pub fn verify_consistency(&self) -> ConsistencyResult

Verify that both databases have consistent data

Source

pub fn get_stats(&self) -> ExecutionStats

Get database statistics

Source

pub fn app_folder(&self) -> &Path

Get the app folder path

Trait Implementations§

Source§

impl Clone for ExecutionStore

Source§

fn clone(&self) -> ExecutionStore

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Default for ExecutionStore

Source§

fn default() -> Self

Returns the “default value” for a type. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.