makeSan method

(Position<T>, String) makeSan(
  1. Move move
)

Returns the SAN of this Move and the updated Position.

Throws a PlayError if the move is not legal.

Implementation

(Position<T>, String) makeSan(Move move) {
  if (isLegal(move)) {
    return makeSanUnchecked(move);
  } else {
    throw PlayError('Invalid move $move');
  }
}