Exception: Chess::BadNotationError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/chess/exceptions.rb

Overview

This exception will be raised when an invalid short algebraic chess notation string is passed to the Game#move function.

Instance Method Summary collapse

Constructor Details

#initialize(notation) ⇒ BadNotationError

:nodoc: Create a new exception.



8
9
10
# File 'lib/chess/exceptions.rb', line 8

def initialize(notation)
  super("The notation '#{notation}' is invalid")
end