pub struct PlayTrace {
pub board: Board,
pub cards: ArrayVec<Card, 52>,
}Expand description
A starting board and a sequence of cards played from it
Input to Solver::analyse_play. The two
fields split the position and the play-trace cleanly:
boardis the snapshot from which analysis begins. It encodes the state at the start of a trick — possibly with up to three cards already on the table inBoard::current_cards— andBoard::remainingholds only the cards still in each hand. Cards from previously completed tricks are not represented individually; they are simply absent fromremaining.cardsis the play trace to replay from that snapshot, in chronological order. The first card incardsis whichever card comes after any already inboard.current_cards— it does not restart the trick or repeat prior history. Each card must be legal (follow suit when possible and be held by the player on turn).
cards may span trick boundaries; DDS tracks trick completion and whose
lead follows internally. The trace length may be any value from 0 to
52.
Fields§
§board: BoardSnapshot at the start of analysis: state at the start of the current
trick, plus any 0–3 cards already played to it via
Board::current_cards
cards: ArrayVec<Card, 52>Cards played after board, in chronological order; may cross tricks
Trait Implementations§
impl Eq for PlayTrace
impl StructuralPartialEq for PlayTrace
Auto Trait Implementations§
impl Freeze for PlayTrace
impl RefUnwindSafe for PlayTrace
impl Send for PlayTrace
impl Sync for PlayTrace
impl Unpin for PlayTrace
impl UnsafeUnpin for PlayTrace
impl UnwindSafe for PlayTrace
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