Skip to main content

SessionDeleteQuery

Struct SessionDeleteQuery 

Source
pub struct SessionDeleteQuery<'a, C: CanisterKind, E: EntityKind<Canister = C>> { /* private fields */ }
Expand description

SessionDeleteQuery

Fluent, session-bound delete query wrapper that keeps intent pure while routing execution through the DbSession boundary.

Implementations§

Source§

impl<'a, C: CanisterKind, E: EntityKind<Canister = C>> SessionDeleteQuery<'a, C, E>

Source

pub const fn intent(&self) -> &Query<E>

Return a reference to the underlying intent.

Source

pub fn filter(self, predicate: Predicate) -> Self

Add a predicate, implicitly AND-ing with any existing predicate.

Source

pub fn order_by(self, field: &'static str) -> Self

Append an ascending sort key.

Source

pub fn order_by_desc(self, field: &'static str) -> Self

Append a descending sort key.

Source

pub fn limit(self, limit: u32) -> Self

Apply a delete limit to bound mutation size.

Source

pub fn explain(&self) -> Result<ExplainPlan, QueryError>

Explain this intent without executing it.

Source

pub fn plan(&self) -> Result<ExecutablePlan<E>, QueryError>

Plan this intent into an executor-ready plan.

Source

pub fn execute(&self) -> Result<Response<E>, QueryError>

Execute this intent using the session’s policy settings.

Source

pub fn delete_rows(&self) -> Result<Response<E>, QueryError>

Execute a delete intent and return the deleted rows.

Auto Trait Implementations§

§

impl<'a, C, E> Freeze for SessionDeleteQuery<'a, C, E>

§

impl<'a, C, E> !RefUnwindSafe for SessionDeleteQuery<'a, C, E>

§

impl<'a, C, E> !Send for SessionDeleteQuery<'a, C, E>

§

impl<'a, C, E> !Sync for SessionDeleteQuery<'a, C, E>

§

impl<'a, C, E> Unpin for SessionDeleteQuery<'a, C, E>
where E: Unpin,

§

impl<'a, C, E> UnsafeUnpin for SessionDeleteQuery<'a, C, E>

§

impl<'a, C, E> !UnwindSafe for SessionDeleteQuery<'a, C, E>

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> 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> Same for T

Source§

type Output = T

Should always be Self
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.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V