Struct parallel_processor::memory_fs::file::internal::MemoryFileInternal
source · pub struct MemoryFileInternal { /* private fields */ }
Implementations
sourceimpl MemoryFileInternal
impl MemoryFileInternal
pub fn create_new(
path: impl AsRef<Path>,
memory_mode: MemoryFileMode
) -> Arc<RwLock<Self>>
pub fn create_from_fs(path: impl AsRef<Path>) -> Option<Arc<RwLock<Self>>>
pub fn debug_dump_files()
pub fn is_on_disk(&self) -> bool
pub fn is_memory_preferred(&self) -> bool
pub fn get_chunk(&self, index: usize) -> Arc<RwLock<FileChunk>>
pub fn get_chunks_count(&self) -> usize
pub fn retrieve_reference(path: impl AsRef<Path>) -> Option<Arc<RwLock<Self>>>
pub fn active_files_count() -> usize
pub fn delete(path: impl AsRef<Path>, remove_fs: bool) -> bool
pub fn open(&mut self, mode: OpenMode) -> Result<(), String>
pub fn close(&mut self)
pub fn reserve_space(
self_: &Arc<RwLock<Self>>,
last_chunk: AllocatedChunk,
out_chunks: &mut Vec<(Option<ArcRwLockReadGuard<RawRwLock, FileChunk>>, &mut [u8])>,
size: usize,
el_size: usize
) -> AllocatedChunk
pub fn get_underlying_file(&self) -> &UnderlyingFile
pub fn add_chunk(self_: &Arc<RwLock<Self>>, chunk: AllocatedChunk)
pub fn flush_chunks(&mut self, limit: usize) -> usize
pub fn flush_pending_chunks_count(&self) -> usize
pub fn has_flush_pending_chunks(&self) -> bool
pub fn change_to_disk_only(&mut self)
pub fn has_only_one_chunk(&self) -> bool
pub fn get_path(&self) -> &Path
pub fn len(&self) -> usize
Trait Implementations
impl Send for MemoryFileInternal
impl Sync for MemoryFileInternal
Auto Trait Implementations
impl !RefUnwindSafe for MemoryFileInternal
impl Unpin for MemoryFileInternal
impl !UnwindSafe for MemoryFileInternal
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more