pub struct HashCm<K, S = RandomState> { /* private fields */ }
Trait Implementations§
Source§impl<K, S> Cm for HashCm<K, S>
impl<K, S> Cm for HashCm<K, S>
Source§type Error = Infallible
type Error = Infallible
The error type returned by the conflict manager.
Source§type Options = HashCmOptions<S>
type Options = HashCmOptions<S>
The options type used to create the conflict manager.
Source§fn new(
options: <HashCm<K, S> as Cm>::Options,
) -> Result<HashCm<K, S>, <HashCm<K, S> as Cm>::Error>
fn new( options: <HashCm<K, S> as Cm>::Options, ) -> Result<HashCm<K, S>, <HashCm<K, S> as Cm>::Error>
Create a new conflict manager with the given options.
Source§fn has_conflict(&self, other: &HashCm<K, S>) -> bool
fn has_conflict(&self, other: &HashCm<K, S>) -> bool
Returns true if we have a conflict.
Source§impl<K, S> CmEquivalent for HashCm<K, S>
impl<K, S> CmEquivalent for HashCm<K, S>
Source§fn mark_read_equivalent<Q>(&mut self, key: &Q)
fn mark_read_equivalent<Q>(&mut self, key: &Q)
Optimized version of [
mark_read
] that accepts borrowed keys. Optional to implement.Auto Trait Implementations§
impl<K, S> Freeze for HashCm<K, S>where
S: Freeze,
impl<K, S> RefUnwindSafe for HashCm<K, S>where
K: RefUnwindSafe,
S: RefUnwindSafe,
impl<K, S> Send for HashCm<K, S>
impl<K, S> Sync for HashCm<K, S>
impl<K, S> Unpin for HashCm<K, S>
impl<K, S> UnwindSafe for HashCm<K, S>where
K: UnwindSafe,
S: UnwindSafe,
Blanket Implementations§
Source§impl<T> AsyncCm for Twhere
T: Cm,
impl<T> AsyncCm for Twhere
T: Cm,
Source§async fn new(
options: <T as AsyncCm>::Options,
) -> Result<T, <T as AsyncCm>::Error>
async fn new( options: <T as AsyncCm>::Options, ) -> Result<T, <T as AsyncCm>::Error>
Create a new conflict manager with the given options.
Source§async fn mark_conflict(&mut self, key: &<T as AsyncCm>::Key)
async fn mark_conflict(&mut self, key: &<T as AsyncCm>::Key)
Mark the key is .
Source§async fn has_conflict(&self, other: &T) -> bool
async fn has_conflict(&self, other: &T) -> bool
Returns true if we have a conflict.
Source§impl<T> AsyncCmEquivalent for Twhere
T: CmEquivalent,
impl<T> AsyncCmEquivalent for Twhere
T: CmEquivalent,
Source§async fn mark_read_equivalent<Q>(&mut self, key: &Q)
async fn mark_read_equivalent<Q>(&mut self, key: &Q)
Optimized version of [
mark_read
] that accepts borrowed keys. Optional to implement.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