pub enum EvalType {
Centipawn,
Mate,
}Expand description
The category of evaluation returned by stockfish. Either Centipawns or Mate.
Variants§
Implementations§
Source§impl EvalType
impl EvalType
Sourcepub fn from_descriptor(str: &str) -> EvalType
pub fn from_descriptor(str: &str) -> EvalType
Creates an EvalType from a string descriptor. The valid descriptors are:
"cp", which translates toEvalType::Centipawn"mate", which translates toEvalType::Mate
§Panics
This function panics when given a string descriptor that doesn’t match those listed above.
Trait Implementations§
impl Copy for EvalType
impl StructuralPartialEq for EvalType
Auto Trait Implementations§
impl Freeze for EvalType
impl RefUnwindSafe for EvalType
impl Send for EvalType
impl Sync for EvalType
impl Unpin for EvalType
impl UnwindSafe for EvalType
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