InvalidPieceInFile

class InvalidPieceInFile(message: String = "The piece in the file is invalid", type: ErrorType) : ReversiException

Thrown when a piece line in the persisted game file is malformed or contains values that cannot be converted into a valid pt.isel.reversi.core.board.Piece.

Typical causes:

  • Wrong number of tokens in the line

  • Non-integer row/column values

  • Unknown piece symbol

Constructors

Link copied to clipboard
constructor(message: String = "The piece in the file is invalid", type: ErrorType)