[][src]Struct legal_chess::board::Board

pub struct Board { /* fields omitted */ }

Implementations

impl Board[src]

pub fn empty() -> Self[src]

pub fn initial() -> Self[src]

pub fn iter(&self) -> Iter<'_, Vec<Option<Box<dyn Piece>>>>[src]

pub fn get_square(&self, position: Position) -> &Option<Box<dyn Piece>>[src]

pub fn take_piece(&mut self, position: Position) -> Box<dyn Piece>[src]

pub fn is_empty(&self, pos: Position) -> bool[src]

pub fn set_square(&mut self, square: Option<Box<dyn Piece>>, position: Position)[src]

pub fn to_u8_board(&self) -> [u8; 64][src]

pub fn from_u8_board(board_arr: &[u8; 64]) -> (Self, Position, Position)[src]

pub fn pieces_of_color_except_king(&self, color: Color) -> Vec<&Box<dyn Piece>>[src]

Trait Implementations

impl Debug for Board[src]

Auto Trait Implementations

impl !RefUnwindSafe for Board

impl !Send for Board

impl !Sync for Board

impl Unpin for Board

impl !UnwindSafe for Board

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.