[−][src]Struct hycon_rust::database::state_db::StateDB
Methods
impl<DatabaseType, EntryType, OptionType> StateDB<DatabaseType, EntryType> where
DatabaseType: IDB<OptionType = OptionType>,
[src]
DatabaseType: IDB<OptionType = OptionType>,
pub fn new(
path: PathBuf,
options: Option<OptionType>
) -> Result<StateDB<DatabaseType, EntryType>, Box<dyn Error>>
[src]
path: PathBuf,
options: Option<OptionType>
) -> Result<StateDB<DatabaseType, EntryType>, Box<dyn Error>>
Trait Implementations
impl<DBType> Database for StateDB<DBType> where
DBType: IDB,
[src]
DBType: IDB,
type NodeType = DBState
type EntryType = (Vec<u8>, Self::NodeType)
fn open(
_path: &PathBuf
) -> Result<StateDB<DBType, Self::EntryType>, Box<dyn Error>>
[src]
_path: &PathBuf
) -> Result<StateDB<DBType, Self::EntryType>, Box<dyn Error>>
fn get_node(&self, key: &[u8]) -> Result<Option<Self::NodeType>, Box<dyn Error>>
[src]
fn insert(
&mut self,
key: &[u8],
value: &Self::NodeType
) -> Result<(), Box<dyn Error>>
[src]
&mut self,
key: &[u8],
value: &Self::NodeType
) -> Result<(), Box<dyn Error>>
fn remove(&mut self, key: &[u8]) -> Result<(), Box<dyn Error>>
[src]
fn batch_write(&mut self) -> Result<(), Box<dyn Error>>
[src]
Auto Trait Implementations
impl<DatabaseType, EntryType> Send for StateDB<DatabaseType, EntryType> where
DatabaseType: Send,
EntryType: Send,
DatabaseType: Send,
EntryType: Send,
impl<DatabaseType, EntryType> Sync for StateDB<DatabaseType, EntryType> where
DatabaseType: Sync,
EntryType: Sync,
DatabaseType: Sync,
EntryType: Sync,
Blanket Implementations
impl<T> From for T
[src]
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T, U> TryInto 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.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> SendSyncUnwindSafe for T where
T: Send + Sync + UnwindSafe + ?Sized,
T: Send + Sync + UnwindSafe + ?Sized,
impl<T> Erased for T
impl<T> Same for T
type Output = T
Should always be Self