pub struct IdxBinary { /* private fields */ }Implementations§
Source§impl IdxBinary
impl IdxBinary
Sourcepub fn new<P>(directory: P, allocation_lot: u32) -> IdxBinary
pub fn new<P>(directory: P, allocation_lot: u32) -> IdxBinary
Opens the file and creates the IdxBinary.
§Arguments
path- Path of directory to save data.allocation_lot- Extends the specified size when the file size becomes insufficient due to data addition. If you expect to add a lot of data, specifying a larger size will improve performance.
Sourcepub fn new_ext<P>(path: P, allocation_lot: u32) -> IdxBinary
pub fn new_ext<P>(path: P, allocation_lot: u32) -> IdxBinary
Opens the file and creates the IdxBinary.
§Arguments
path- Path of part of filename without extension to save data.allocation_lot- Extends the specified size when the file size becomes insufficient due to data addition. If you expect to add a lot of data, specifying a larger size will improve performance.
Sourcepub fn row_or_insert(&mut self, content: &[u8]) -> NonZero<u32>
pub fn row_or_insert(&mut self, content: &[u8]) -> NonZero<u32>
Finds a sequence of bytes, inserts it if it doesn’t exist, and returns a row.
Trait Implementations§
Source§impl AsMut<Avltriee<DataAddress, [u8], IdxFileAllocator<DataAddress>>> for IdxBinary
impl AsMut<Avltriee<DataAddress, [u8], IdxFileAllocator<DataAddress>>> for IdxBinary
Source§fn as_mut(
&mut self,
) -> &mut Avltriee<DataAddress, [u8], IdxFileAllocator<DataAddress>>
fn as_mut( &mut self, ) -> &mut Avltriee<DataAddress, [u8], IdxFileAllocator<DataAddress>>
Converts this type into a mutable reference of the (usually inferred) input type.
Source§impl AsRef<Avltriee<DataAddress, [u8], IdxFileAllocator<DataAddress>>> for IdxBinary
impl AsRef<Avltriee<DataAddress, [u8], IdxFileAllocator<DataAddress>>> for IdxBinary
Source§fn as_ref(&self) -> &Avltriee<DataAddress, [u8], IdxFileAllocator<DataAddress>>
fn as_ref(&self) -> &Avltriee<DataAddress, [u8], IdxFileAllocator<DataAddress>>
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl AvltrieeSearch<DataAddress, [u8], IdxFileAllocator<DataAddress>> for IdxBinary
impl AvltrieeSearch<DataAddress, [u8], IdxFileAllocator<DataAddress>> for IdxBinary
Source§fn value(&self, row: NonZero<u32>) -> Option<&[u8]>
fn value(&self, row: NonZero<u32>) -> Option<&[u8]>
Returns the value of the specified row. Returns None if the row does not exist.
Source§unsafe fn value_unchecked(&self, row: NonZero<u32>) -> &[u8] ⓘ
unsafe fn value_unchecked(&self, row: NonZero<u32>) -> &[u8] ⓘ
Returns the value of the specified row.
Source§unsafe fn node_value_unchecked(
&self,
row: NonZero<u32>,
) -> (&AvltrieeNode<DataAddress>, &[u8])
unsafe fn node_value_unchecked( &self, row: NonZero<u32>, ) -> (&AvltrieeNode<DataAddress>, &[u8])
Returns node and value of the specified row.
fn cmp(left: &[u8], right: &[u8]) -> Ordering
Source§impl AvltrieeUpdate<DataAddress, [u8], IdxFileAllocator<DataAddress>> for IdxBinary
impl AvltrieeUpdate<DataAddress, [u8], IdxFileAllocator<DataAddress>> for IdxBinary
fn convert_on_insert_unique(&mut self, input: &[u8]) -> DataAddress
fn on_delete(&mut self, row: NonZero<u32>)
Source§fn insert(&mut self, value: &I) -> NonZero<u32>where
T: Clone,
fn insert(&mut self, value: &I) -> NonZero<u32>where
T: Clone,
Creates a new row and assigns a value to it.
Auto Trait Implementations§
impl Freeze for IdxBinary
impl RefUnwindSafe for IdxBinary
impl Send for IdxBinary
impl Sync for IdxBinary
impl Unpin for IdxBinary
impl UnwindSafe for IdxBinary
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