Trait ObjectMapOpEnvCache

Source
pub trait ObjectMapOpEnvCache: Send + Sync {
    // Required methods
    fn get_object_map_ex<'life0, 'life1, 'async_trait>(
        &'life0 self,
        object_id: &'life1 ObjectId,
    ) -> Pin<Box<dyn Future<Output = BuckyResult<Option<ObjectMapRefCacheItem>>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn exists<'life0, 'life1, 'async_trait>(
        &'life0 self,
        object_id: &'life1 ObjectId,
    ) -> Pin<Box<dyn Future<Output = BuckyResult<bool>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn put_object_map(
        &self,
        object_id: &ObjectId,
        object: ObjectMap,
        access: Option<AccessString>,
    ) -> BuckyResult<ObjectMapRef>;
    fn remove_object_map(
        &self,
        object_id: &ObjectId,
    ) -> BuckyResult<ObjectMapRef>;
    fn commit<'life0, 'async_trait>(
        &'life0 self,
    ) -> Pin<Box<dyn Future<Output = BuckyResult<()>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn gc<'life0, 'life1, 'async_trait>(
        &'life0 self,
        single: bool,
        target: &'life1 ObjectId,
    ) -> Pin<Box<dyn Future<Output = BuckyResult<()>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn abort(&self);

    // Provided method
    fn get_object_map<'life0, 'life1, 'async_trait>(
        &'life0 self,
        object_id: &'life1 ObjectId,
    ) -> Pin<Box<dyn Future<Output = BuckyResult<Option<ObjectMapRef>>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait { ... }
}
Expand description

ObjectMap op_env操作粒度的cache

Required Methods§

Source

fn get_object_map_ex<'life0, 'life1, 'async_trait>( &'life0 self, object_id: &'life1 ObjectId, ) -> Pin<Box<dyn Future<Output = BuckyResult<Option<ObjectMapRefCacheItem>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Source

fn exists<'life0, 'life1, 'async_trait>( &'life0 self, object_id: &'life1 ObjectId, ) -> Pin<Box<dyn Future<Output = BuckyResult<bool>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Source

fn put_object_map( &self, object_id: &ObjectId, object: ObjectMap, access: Option<AccessString>, ) -> BuckyResult<ObjectMapRef>

Source

fn remove_object_map(&self, object_id: &ObjectId) -> BuckyResult<ObjectMapRef>

Source

fn commit<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = BuckyResult<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source

fn gc<'life0, 'life1, 'async_trait>( &'life0 self, single: bool, target: &'life1 ObjectId, ) -> Pin<Box<dyn Future<Output = BuckyResult<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Source

fn abort(&self)

Provided Methods§

Source

fn get_object_map<'life0, 'life1, 'async_trait>( &'life0 self, object_id: &'life1 ObjectId, ) -> Pin<Box<dyn Future<Output = BuckyResult<Option<ObjectMapRef>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Implementors§