pub struct TranspositionTable { /* private fields */ }Implementations§
Source§impl TranspositionTable
impl TranspositionTable
pub fn print_info(&self)
pub fn new(cache_table_size: CacheTableSize) -> Self
pub fn read( &self, key: u64, depth: Depth, ply: Ply, ) -> (Option<(Score, EntryFlagHash)>, Option<Move>)
pub fn read_best_move(&self, key: u64) -> Option<Move>
pub fn write( &self, key: u64, depth: Depth, ply: Ply, score: Score, flag: EntryFlagHash, best_move: Option<Move>, )
pub fn clear_best_moves(&self)
Methods from Deref<Target = CacheTable<TranspositionTableEntry>>§
pub fn get(&self, hash: u64) -> Option<T>
pub fn add(&self, hash: u64, entry: T)
pub fn replace_if<F: Fn(T) -> bool>(&self, hash: u64, entry: T, replace: F)
pub fn clear(&self)
pub fn get_table(&self) -> &RwLock<Box<[Option<CacheTableEntry<T>>]>>
pub fn get_num_cells_filled(&self) -> usize
pub fn get_num_overwrites(&self) -> usize
pub fn get_num_collisions(&self) -> usize
pub fn get_zero_hit(&self) -> usize
pub fn reset_num_cells_filled(&self)
pub fn reset_num_overwrites(&self)
pub fn reset_num_collisions(&self)
pub fn reset_zero_hit(&self)
Sourcepub fn reset_variables(&self)
pub fn reset_variables(&self)
Variable needed to be reset per search
pub fn get_hash_full(&self) -> f64
pub fn len(&self) -> usize
pub fn is_empty(&self) -> bool
pub fn get_size(&self) -> CacheTableSize
pub fn set_size(&self, size: CacheTableSize)
Trait Implementations§
Source§impl Clone for TranspositionTable
impl Clone for TranspositionTable
Source§fn clone(&self) -> TranspositionTable
fn clone(&self) -> TranspositionTable
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for TranspositionTable
impl Debug for TranspositionTable
Source§impl Default for TranspositionTable
impl Default for TranspositionTable
Source§impl Deref for TranspositionTable
impl Deref for TranspositionTable
Source§type Target = CacheTable<TranspositionTableEntry>
type Target = CacheTable<TranspositionTableEntry>
The resulting type after dereferencing.
Source§impl<'de> Deserialize<'de> for TranspositionTable
impl<'de> Deserialize<'de> for TranspositionTable
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl !Freeze for TranspositionTable
impl RefUnwindSafe for TranspositionTable
impl Send for TranspositionTable
impl Sync for TranspositionTable
impl Unpin for TranspositionTable
impl UnwindSafe for TranspositionTable
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> FromQuery for Twhere
T: DeserializeOwned,
impl<T> FromQuery for Twhere
T: DeserializeOwned,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more