pub struct PolyglotBookMemoryMappedReader { /* private fields */ }Implementations§
Source§impl PolyglotBookMemoryMappedReader
impl PolyglotBookMemoryMappedReader
pub fn from_file_path(file_path: &str) -> Result<Self>
pub const fn new(file: Arc<File>) -> Self
pub fn get_file(&self) -> Arc<File> ⓘ
pub fn get_all_weighted_moves(&self, board: &Board) -> Result<Vec<WeightedMove>>
pub fn to_polyglot_hashmap(&self) -> Result<PolyglotBookHashMap>
Trait Implementations§
Source§impl Clone for PolyglotBookMemoryMappedReader
impl Clone for PolyglotBookMemoryMappedReader
Source§fn clone(&self) -> PolyglotBookMemoryMappedReader
fn clone(&self) -> PolyglotBookMemoryMappedReader
Returns a duplicate 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 PolyglotBook for PolyglotBookMemoryMappedReader
impl PolyglotBook for PolyglotBookMemoryMappedReader
fn read_from_path(book_path: &str) -> Result<Self>
fn get_best_weighted_move(&self, board: &Board) -> Option<WeightedMove>
Source§impl TryFrom<&PolyglotBookMemoryMappedReader> for PolyglotBookHashMap
impl TryFrom<&PolyglotBookMemoryMappedReader> for PolyglotBookHashMap
Source§type Error = TimecatError
type Error = TimecatError
The type returned in the event of a conversion error.
Source§impl TryFrom<PolyglotBookMemoryMappedReader> for PolyglotBookHashMap
impl TryFrom<PolyglotBookMemoryMappedReader> for PolyglotBookHashMap
Source§type Error = TimecatError
type Error = TimecatError
The type returned in the event of a conversion error.
Auto Trait Implementations§
impl Freeze for PolyglotBookMemoryMappedReader
impl RefUnwindSafe for PolyglotBookMemoryMappedReader
impl Send for PolyglotBookMemoryMappedReader
impl Sync for PolyglotBookMemoryMappedReader
impl Unpin for PolyglotBookMemoryMappedReader
impl UnsafeUnpin for PolyglotBookMemoryMappedReader
impl UnwindSafe for PolyglotBookMemoryMappedReader
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> 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