Struct garage_table::data::TableData
source · pub struct TableData<F: TableSchema, R: TableReplication> {
pub instance: F,
pub replication: R,
pub store: Tree,
/* private fields */
}
Fields§
§instance: F
§replication: R
§store: Tree
Implementations§
source§impl<F: TableSchema, R: TableReplication> TableData<F, R>
impl<F: TableSchema, R: TableReplication> TableData<F, R>
pub fn new( system: Arc<System>, instance: F, replication: R, db: &Db ) -> Arc<Self>
pub fn read_entry(&self, p: &F::P, s: &F::S) -> Result<Option<ByteBuf>, Error>
pub fn read_range( &self, partition_key: &F::P, start: &Option<F::S>, filter: &Option<F::Filter>, limit: usize, enumeration_order: EnumerationOrder ) -> Result<Vec<Arc<ByteBuf>>, Error>
pub fn update_entry_with( &self, partition_key: &F::P, sort_key: &F::S, update_fn: impl Fn(&mut Transaction<'_>, Option<F::E>) -> TxOpResult<F::E> ) -> Result<Option<F::E>, Error>
pub fn tree_key(&self, p: &F::P, s: &F::S) -> Vec<u8> ⓘ
pub fn decode_entry(&self, bytes: &[u8]) -> Result<F::E, Error>
pub fn gc_todo_len(&self) -> Result<usize, Error>
Auto Trait Implementations§
impl<F, R> !Freeze for TableData<F, R>
impl<F, R> !RefUnwindSafe for TableData<F, R>
impl<F, R> Send for TableData<F, R>
impl<F, R> Sync for TableData<F, R>
impl<F, R> Unpin for TableData<F, R>
impl<F, R> !UnwindSafe for TableData<F, R>
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