Txn

Struct Txn 

Source
pub struct Txn<'conn>(/* private fields */);

Implementations§

Source§

impl<'conn> Txn<'conn>

Source

pub fn new(tx: Transaction<'conn>) -> Self

Trait Implementations§

Source§

impl<'conn> AdminEdgeByDest for Txn<'conn>

Source§

fn find_edges_by_dest(&self, dest: Id) -> Result<Vec<Edge>, DatabaseError>

Source§

fn remove_edges_by_dest(&self, dest: Id) -> Result<(), DatabaseError>

Source§

fn audit_ent_edges<E>(&self, id: u64) -> Result<(), AuditError>
where E: Ent, Self: Sized,

Source§

fn fix_ent_edges<E>(self, id: u64) -> Result<(), AuditError>
where E: Ent, Self: Sized,

Source§

impl<'conn> QueryEdge for Txn<'conn>

Source§

fn find_edges( &self, source: Id, query: EdgeQuery<'_>, ) -> Result<Vec<Edge>, DatabaseError>

Find edges with flexible filtering and ordering options. Read more
Source§

impl<'conn> ReadEnt for Txn<'conn>

Source§

fn get(&self, id: Id) -> Result<Option<Box<dyn Ent>>, DatabaseError>

Source§

impl<'conn> Transactional for Txn<'conn>

Source§

fn create_edge(&self, edge: EdgeValue) -> Result<(), DatabaseError>

Source§

fn delete<E: Ent>(&self, id: Id) -> Result<(), DatabaseError>

Source§

fn update<T: Ent, F: FnOnce(&mut T), B: BorrowMut<T>>( &self, ent0: B, mutator: F, ) -> Result<bool, DatabaseError>

Source§

fn create<E: Ent>(&self, ent: E) -> Result<Id, DatabaseError>

Source§

fn commit(self) -> Result<(), DatabaseError>

Auto Trait Implementations§

§

impl<'conn> Freeze for Txn<'conn>

§

impl<'conn> !RefUnwindSafe for Txn<'conn>

§

impl<'conn> !Send for Txn<'conn>

§

impl<'conn> !Sync for Txn<'conn>

§

impl<'conn> Unpin for Txn<'conn>

§

impl<'conn> !UnwindSafe for Txn<'conn>

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, 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