pub struct StorageContext { /* private fields */ }Implementations§
Source§impl StorageContext
impl StorageContext
pub fn new(platform: Option<PlatformCapabilities>) -> Self
pub async fn insert( &self, collection: &str, document: Value, allocate_code: Option<Value>, ) -> Result<Value>
pub async fn find( &self, collection: &str, filter: Option<Value>, limit: Option<u64>, sort: Option<Value>, ) -> Result<Value>
pub async fn get(&self, collection: &str, id: &str) -> Result<Value>
pub async fn update( &self, collection: &str, id: &str, patch: Value, ) -> Result<Value>
pub async fn delete(&self, collection: &str, id: &str) -> Result<Value>
Trait Implementations§
Source§impl Clone for StorageContext
impl Clone for StorageContext
Source§fn clone(&self) -> StorageContext
fn clone(&self) -> StorageContext
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Default for StorageContext
impl Default for StorageContext
Source§fn default() -> StorageContext
fn default() -> StorageContext
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for StorageContext
impl RefUnwindSafe for StorageContext
impl Send for StorageContext
impl Sync for StorageContext
impl Unpin for StorageContext
impl UnsafeUnpin for StorageContext
impl UnwindSafe for StorageContext
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