pub struct SatCountCache<N: SatCountNumber, S: BuildHasher> {
pub map: HashMap<NodeID, N, S>,
/* private fields */
}
Expand description
Cache for counting satisfying assignments
Fields§
§map: HashMap<NodeID, N, S>
Main map from NodeID
s to their model count
Implementations§
Source§impl<N: SatCountNumber, S: BuildHasher> SatCountCache<N, S>
impl<N: SatCountNumber, S: BuildHasher> SatCountCache<N, S>
Sourcepub fn with_hasher(hash_builder: S) -> Self
pub fn with_hasher(hash_builder: S) -> Self
Create a new satisfiability counting cache
Sourcepub fn clear_if_invalid<M: Manager>(&mut self, manager: &M, vars: LevelNo)
pub fn clear_if_invalid<M: Manager>(&mut self, manager: &M, vars: LevelNo)
Clear the cache if it has become invalid due to garbage collections or a change in the number of variables
Trait Implementations§
Source§impl<N: SatCountNumber, S: BuildHasher + Default> Default for SatCountCache<N, S>
impl<N: SatCountNumber, S: BuildHasher + Default> Default for SatCountCache<N, S>
Auto Trait Implementations§
impl<N, S> Freeze for SatCountCache<N, S>where
S: Freeze,
impl<N, S> RefUnwindSafe for SatCountCache<N, S>where
S: RefUnwindSafe,
N: RefUnwindSafe,
impl<N, S> Send for SatCountCache<N, S>
impl<N, S> Sync for SatCountCache<N, S>
impl<N, S> Unpin for SatCountCache<N, S>
impl<N, S> UnwindSafe for SatCountCache<N, S>where
N: UnwindSafe,
S: UnwindSafe,
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