Struct chess::ChessMove [] [src]

pub struct ChessMove { /* fields omitted */ }

Represent a ChessMove in memory

Methods

impl ChessMove
[src]

[src]

Create a new chess move, given a source Square, a destination Square, and an optional promotion Piece

[src]

Get the source square (square the piece is currently on).

[src]

Get the destination square (square the piece is going to).

[src]

Get the promotion piece (maybe).

Trait Implementations

impl Clone for ChessMove
[src]

[src]

Returns a copy of the value. Read more

1.0.0
[src]

Performs copy-assignment from source. Read more

impl Copy for ChessMove
[src]

impl Eq for ChessMove
[src]

impl PartialOrd for ChessMove
[src]

[src]

This method returns an ordering between self and other values if one exists. Read more

[src]

This method tests less than (for self and other) and is used by the < operator. Read more

[src]

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more

[src]

This method tests greater than (for self and other) and is used by the > operator. Read more

[src]

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more

impl PartialEq for ChessMove
[src]

[src]

This method tests for self and other values to be equal, and is used by ==. Read more

[src]

This method tests for !=.

impl Display for ChessMove
[src]

[src]

Formats the value using the given formatter. Read more

impl Ord for ChessMove
[src]

[src]

This method returns an Ordering between self and other. Read more

1.22.0
[src]

Compares and returns the maximum of two values. Read more

1.22.0
[src]

Compares and returns the minimum of two values. Read more