tartan 1.2.2.1
Chess API
Loading...
Searching...
No Matches
tt::ex::tile_is_empty Class Reference

Thrown when selected Piece location is empty of the Board. More...

#include <exceptions.hpp>

Inheritance diagram for tt::ex::tile_is_empty:
[legend]
Collaboration diagram for tt::ex::tile_is_empty:
[legend]

Public Member Functions

 tile_is_empty (const Piece::Position &from, const Piece::Position &to, const std::string &what_arg="Selected tile is empty")
 
const Piece * piece ()=delete
 
const Piece::Position & from () const
 Get empli tile Position.
 
- Public Member Functions inherited from tt::ex::illegal_move
 illegal_move (const Piece *p, const Piece::Position &to, const std::string &what_arg="Illegal move")
 
const Piece * piece () const
 Get Piece object.
 
const Piece::Position & to () const
 Get move target location.
 
- Public Member Functions inherited from std::logic_error
T logic_error (T... args)
 
T what (T... args)
 
- Public Member Functions inherited from std::exception
T what (T... args)
 
T ~exception (T... args)
 
T operator= (T... args)
 
T exception (T... args)
 

Detailed Description

Thrown when selected Piece location is empty of the Board.

Constructor & Destructor Documentation

◆ tile_is_empty()

tt::ex::tile_is_empty::tile_is_empty ( const Piece::Position &  from,
const Piece::Position &  to,
const std::string &  what_arg = "Selected tile is empty" 
)
inline
Parameters
fromPosition turn were performed from
toPosition turn were performed to
what_argmessage string

Member Function Documentation

◆ from()

const Piece::Position & tt::ex::tile_is_empty::from ( ) const
inline

Get empli tile Position.

Returns
empty tile Position

The documentation for this class was generated from the following file: