Class: JustChess::InvalidPromotionError
- Defined in:
- lib/just_chess/errors/invalid_promotion_error.rb
Overview
InvalidPromotionError
An invalid promotion error with a message
Instance Method Summary collapse
-
#initialize(message = "Promotion is invalid.") ⇒ InvalidPromotionError
constructor
New invalid promotion errors can be instantiated with.
Constructor Details
#initialize(message = "Promotion is invalid.") ⇒ InvalidPromotionError
New invalid promotion errors can be instantiated with
Example:
# Instantiates a new InvalidPromotionError
JustChess::InvalidPromotionError.new("Custom Message")
18 19 20 |
# File 'lib/just_chess/errors/invalid_promotion_error.rb', line 18 def initialize(="Promotion is invalid.") super end |