pub struct DeleteExecutor<E: EntityKind> { /* private fields */ }Expand description
DeleteExecutor
Stage-1 atomicity invariant: All fallible validation completes before the first stable write. After mutation begins, only infallible operations or traps remain. IC rollback semantics guarantee atomicity within this update call.
Implementations§
Source§impl<E: EntityKind> DeleteExecutor<E>
impl<E: EntityKind> DeleteExecutor<E>
pub const fn new(db: Db<E::Canister>, debug: bool) -> Self
pub const fn debug(self) -> Self
pub fn one(self, pk: impl FieldValue) -> Result<Response<E>, InternalError>
pub fn only(self) -> Result<Response<E>, InternalError>
pub fn many<I, V>(self, values: I) -> Result<Response<E>, InternalError>where
I: IntoIterator<Item = V>,
V: FieldValue,
pub fn by_unique_index(
self,
index: UniqueIndexHandle,
entity: E,
) -> Result<Response<E>, InternalError>where
E::PrimaryKey: FromKey,
pub fn explain(self, query: DeleteQuery) -> Result<QueryPlan, InternalError>
pub fn execute(self, query: DeleteQuery) -> Result<Response<E>, InternalError>
Trait Implementations§
Source§impl<E: Clone + EntityKind> Clone for DeleteExecutor<E>
impl<E: Clone + EntityKind> Clone for DeleteExecutor<E>
Source§fn clone(&self) -> DeleteExecutor<E>
fn clone(&self) -> DeleteExecutor<E>
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl<E: Copy + EntityKind> Copy for DeleteExecutor<E>
Auto Trait Implementations§
impl<E> Freeze for DeleteExecutor<E>
impl<E> RefUnwindSafe for DeleteExecutor<E>
impl<E> Send for DeleteExecutor<E>
impl<E> Sync for DeleteExecutor<E>
impl<E> Unpin for DeleteExecutor<E>
impl<E> UnwindSafe for DeleteExecutor<E>
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