pub struct DiskManager { /* private fields */ }Implementations§
Source§impl DiskManager
impl DiskManager
pub fn new(path: impl AsRef<Path>) -> Result<Self>
pub fn read_page(&self, page_id: PageId, page: &mut Page) -> Result<()>
pub fn write_page(&self, page_id: PageId, page: &Page) -> Result<()>
pub fn allocate_page(&self) -> Result<PageId>
pub fn deallocate_page(&self, page_id: PageId) -> Result<()>
pub fn num_pages(&self) -> u32
pub fn db_path(&self) -> &Path
pub fn sync(&self) -> Result<()>
Auto Trait Implementations§
impl !Freeze for DiskManager
impl !RefUnwindSafe for DiskManager
impl Send for DiskManager
impl Sync for DiskManager
impl Unpin for DiskManager
impl UnsafeUnpin for DiskManager
impl UnwindSafe for DiskManager
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