Struct solana_runtime::tiered_storage::file::TieredStorageFile
source · pub struct TieredStorageFile(pub File);
Tuple Fields§
§0: File
Implementations§
source§impl TieredStorageFile
impl TieredStorageFile
pub fn new_readonly(file_path: impl AsRef<Path>) -> Self
pub fn new_writable(file_path: impl AsRef<Path>) -> Self
pub fn write_type<T>(&self, value: &T) -> Result<usize, Error>
pub fn read_type<T>(&self, value: &mut T) -> Result<(), Error>
pub fn seek(&self, offset: u64) -> Result<u64, Error>
pub fn seek_from_end(&self, offset: i64) -> Result<u64, Error>
pub fn write_bytes(&self, bytes: &[u8]) -> Result<usize, Error>
pub fn read_bytes(&self, buffer: &mut [u8]) -> Result<(), Error>
Trait Implementations§
Auto Trait Implementations§
impl RefUnwindSafe for TieredStorageFile
impl Send for TieredStorageFile
impl Sync for TieredStorageFile
impl Unpin for TieredStorageFile
impl UnwindSafe for TieredStorageFile
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