Struct exocore_chain::chain::directory::DirectoryChainStore [−][src]
Directory based chain persistence. The chain is split in segments with configurable maximum size. This maximum size allows using mmap on 32bit systems by preventing segments from growing over 4gb.
Implementations
impl DirectoryChainStore
[src]
pub fn create_or_open(
config: DirectoryChainStoreConfig,
directory_path: &Path
) -> Result<DirectoryChainStore, Error>
[src]
config: DirectoryChainStoreConfig,
directory_path: &Path
) -> Result<DirectoryChainStore, Error>
pub fn create(
config: DirectoryChainStoreConfig,
directory_path: &Path
) -> Result<DirectoryChainStore, Error>
[src]
config: DirectoryChainStoreConfig,
directory_path: &Path
) -> Result<DirectoryChainStore, Error>
pub fn open(
config: DirectoryChainStoreConfig,
directory_path: &Path
) -> Result<DirectoryChainStore, Error>
[src]
config: DirectoryChainStoreConfig,
directory_path: &Path
) -> Result<DirectoryChainStore, Error>
Trait Implementations
impl ChainStore for DirectoryChainStore
[src]
fn segments(&self) -> Segments
[src]
fn write_block<B: Block>(&mut self, block: &B) -> Result<BlockOffset, Error>
[src]
fn blocks_iter(
&self,
from_offset: BlockOffset
) -> Result<Box<dyn Iterator<Item = BlockRef<'_>> + '_>, Error>
[src]
&self,
from_offset: BlockOffset
) -> Result<Box<dyn Iterator<Item = BlockRef<'_>> + '_>, Error>
fn blocks_iter_reverse(
&self,
from_next_offset: BlockOffset
) -> Result<Box<dyn Iterator<Item = BlockRef<'_>> + '_>, Error>
[src]
&self,
from_next_offset: BlockOffset
) -> Result<Box<dyn Iterator<Item = BlockRef<'_>> + '_>, Error>
fn get_block(&self, offset: BlockOffset) -> Result<BlockRef<'_>, Error>
[src]
fn get_block_from_next_offset(
&self,
next_offset: BlockOffset
) -> Result<BlockRef<'_>, Error>
[src]
&self,
next_offset: BlockOffset
) -> Result<BlockRef<'_>, Error>
fn get_last_block(&self) -> Result<Option<BlockRef<'_>>, Error>
[src]
fn get_block_by_operation_id(
&self,
operation_id: OperationId
) -> Result<Option<BlockRef<'_>>, Error>
[src]
&self,
operation_id: OperationId
) -> Result<Option<BlockRef<'_>>, Error>
fn truncate_from_offset(&mut self, offset: BlockOffset) -> Result<(), Error>
[src]
Auto Trait Implementations
impl RefUnwindSafe for DirectoryChainStore
[src]
impl Send for DirectoryChainStore
[src]
impl Sync for DirectoryChainStore
[src]
impl Unpin for DirectoryChainStore
[src]
impl UnwindSafe for DirectoryChainStore
[src]
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T> Instrument for T
[src]
pub fn instrument(self, span: Span) -> Instrumented<Self>
[src]
pub fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T> Instrument for T
[src]
pub fn instrument(self, span: Span) -> Instrumented<Self>
[src]
pub fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Pointable for T
pub const ALIGN: usize
type Init = T
The type for initializers.
pub unsafe fn init(init: <T as Pointable>::Init) -> usize
pub unsafe fn deref<'a>(ptr: usize) -> &'a T
pub unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T
pub unsafe fn drop(ptr: usize)
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> UnsafeAny for T where
T: Any,
T: Any,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,