pub struct Dao<D> { /* private fields */ }Expand description
Represents a data object that will be represented as one or more events on the redo-log and validated in the chain-of-trust.
Reading this object using none-mutable behavior will incur no IO
on the redo-log however if you edit the object you must commit it
to the Dio before it goes out of scope or the data will be lost
(in Debug mode this will even trigger an assert).
Metadata about the data object can also be accessed via this object which allows you to read access rights, etc.
If you wish to actually modify the data you must first call the ‘mut’ function on an open transaction, which will give you an object you can modify
Implementations
Trait Implementations
sourceimpl<D> DaoObj for Dao<D>
impl<D> DaoObj for Dao<D>
fn auth(&self) -> &MetaAuthorization
fn dio(&self) -> &Arc<Dio>
fn key(&self) -> &PrimaryKey
fn when_created(&self) -> u64
fn when_updated(&self) -> u64
impl<D> Eq for Dao<D> where
D: Eq + PartialEq<Dao<D>>,
Auto Trait Implementations
impl<D> !RefUnwindSafe for Dao<D>
impl<D> Send for Dao<D> where
D: Send,
impl<D> Sync for Dao<D> where
D: Sync,
impl<D> Unpin for Dao<D> where
D: Unpin,
impl<D> !UnwindSafe for Dao<D>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<Q, K> Equivalent<K> for Q where
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Q where
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
sourcefn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to key and return true if they are equal.
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Instruments this type with the provided Span, returning an
Instrumented wrapper. Read more
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
fn vzip(self) -> V
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber to this type, returning a
WithDispatch wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber to this type, returning a
WithDispatch wrapper. Read more
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber to this type, returning a
WithDispatch wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber to this type, returning a
WithDispatch wrapper. Read more