pub struct Store<T> { /* private fields */ }
Implementations§
Source§impl<T: Queryable + Serialize + DeserializeOwned> Store<T>
impl<T: Queryable + Serialize + DeserializeOwned> Store<T>
pub fn transaction<A, F>(&self, f: F) -> TransactionResult<A, Error>
pub fn new(&self, inner: T) -> Result<Object<T>>
pub fn create(&self, inner: &T) -> Result<u64>
pub fn create_multi(&self, inners: &[T]) -> Result<Vec<u64>>
pub fn update(&self, object: &Object<T>) -> Result<()>
pub fn update_multi(&self, objects: &[Object<T>]) -> Result<()>
pub fn delete(&self, id: u64) -> Result<()>
pub fn delete_multi(&self, ids: &[u64]) -> Result<()>
pub fn all(&self) -> Result<Vec<Object<T>>>
pub fn find(&self, id: u64) -> Result<Option<Object<T>>>
pub fn filter<Q: Query>(&self, query: Q) -> Result<Results<'_, T>>
pub fn delete_all(&self) -> Result<()>
Auto Trait Implementations§
impl<T> Freeze for Store<T>
impl<T> !RefUnwindSafe for Store<T>
impl<T> Send for Store<T>
impl<T> Sync for Store<T>
impl<T> Unpin for Store<T>
impl<T> !UnwindSafe for Store<T>
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