Struct hyper_scripter_historian::Historian
source · pub struct Historian { /* private fields */ }
Implementations§
source§impl Historian
impl Historian
pub async fn close(self)
pub async fn new(dir_path: PathBuf) -> Result<Self, DBError>
pub async fn do_migrate(dir_path: &Path) -> Result<(), MigrateError>
pub async fn remove(&self, script_id: i64) -> Result<(), DBError>
pub async fn record(&self, event: &Event<'_>) -> Result<i64, DBError>
pub async fn previous_args( &self, id: i64, dir: Option<&Path> ) -> Result<Option<(String, String)>, DBError>
pub async fn previous_args_list( &self, ids: &[i64], limit: u32, offset: u32, no_humble: bool, dir: Option<&Path> ) -> Result<impl ExactSizeIterator<Item = (i64, String)>, DBError>
pub async fn previous_args_list_with_envs( &self, ids: &[i64], limit: u32, offset: u32, no_humble: bool, dir: Option<&Path> ) -> Result<impl ExactSizeIterator<Item = (i64, String, String)>, DBError>
pub async fn ignore_args_by_id( &self, event_id: NonZeroU64 ) -> Result<Option<LastTimeRecord>, DBError>
pub async fn humble_args_by_id( &self, event_id: NonZeroU64 ) -> Result<Option<LastTimeRecord>, DBError>
pub async fn ignore_args_range( &self, ids: &[i64], dir: Option<&Path>, no_humble: bool, show_env: bool, min: NonZeroU64, max: Option<NonZeroU64> ) -> Result<Vec<LastTimeRecord>, DBError>
pub async fn amend_args_by_id( &self, event_id: NonZeroU64, args: &str, envs: Option<&str> ) -> Result<(), DBError>
sourcepub async fn clear_except_script_ids(
&self,
script_ids: &[i64]
) -> Result<(), DBError>
pub async fn clear_except_script_ids( &self, script_ids: &[i64] ) -> Result<(), DBError>
除了輸入進來的 script id 外,其它事件通通砍除
pub async fn tidy(&self, script_id: i64) -> Result<(), DBError>
Trait Implementations§
Auto Trait Implementations§
impl RefUnwindSafe for Historian
impl Send for Historian
impl Sync for Historian
impl Unpin for Historian
impl UnwindSafe for Historian
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