Class: JustBackgammon::NotPlayersTurnError

Inherits:
Object
  • Object
show all
Defined in:
lib/just_backgammon/errors/not_players_turn_error.rb

Overview

NotPlayersTurnError

A not player’s turn error with a message

Instance Method Summary collapse

Constructor Details

#initialize(message = "It is not the player's turn yet.") ⇒ NotPlayersTurnError

A new instance of NotPlayersTurnError.

Example:

# Instantiates a new NotPlayersTurnError
JustBackgammon::NotPlayersTurnError.new("Custom Message")

Parameters:

  • [String] (Hash)

    a customizable set of options



16
17
18
# File 'lib/just_backgammon/errors/not_players_turn_error.rb', line 16

def initialize(message="It is not the player's turn yet.")
  @message = message
end