Struct chess_move_gen::CastlingRights
[−]
[src]
pub struct CastlingRights(pub usize);
Represents the right to castle in a particular director for a particular side
Methods
impl CastlingRights
[src]
fn to_usize(&self) -> usize
fn has(&self, right: CastlingRights) -> bool
fn add(&mut self, castle: Castle, side: Side)
fn set(&mut self, rights: CastlingRights)
fn clear_side(&mut self, side: Side)
fn clear(&mut self, rights: CastlingRights)
fn side_can(&self, side: Side) -> bool
fn any(&self) -> bool
fn to_string(&self) -> String
fn from(castle: Castle, side: Side) -> CastlingRights
fn parse(chr: char) -> Result<CastlingRights, String>
Trait Implementations
impl PartialEq for CastlingRights
[src]
fn eq(&self, __arg_0: &CastlingRights) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &CastlingRights) -> bool
This method tests for !=
.
impl Copy for CastlingRights
[src]
impl Clone for CastlingRights
[src]
fn clone(&self) -> CastlingRights
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more