Modified JavaDocs and Added error throws in JD

This commit is contained in:
Matthis FAUVET 2024-10-09 10:34:37 +02:00
parent 5d698e0cc7
commit 5b39fd139d

View File

@ -10,6 +10,8 @@ public interface Plateau {
/**
* Return the current player
*
* @throws NullPointerException if the game is over
*
* @return the player
*/
Player getPlayer();
@ -29,29 +31,36 @@ public interface Plateau {
* - if the move is a draw : 0
* - if its a defeat move : -1
*
* @throws NullPointerException if game is not over
*
* @return the result
*/
Result getResult();
/**
* Gives previous played plies
* List next legals moves
*
* @throws NullPointerException if the game is over
* @return the iterator
*/
Iterator<Ply> givePlies();
/**
* Play a ply
* Play a future ply
*
* @throws IllegalArgumentException if the given ply is coming from wrong game
*
* @param ply the ply
*/
void doo(Ply ply);
void doPly(Ply ply);
/**
* Removed a ply.
* Removed a previous ply.
*
* @throws IllegalStateException if not allowed to come back on previous statement
*
* @param ply the ply
*/
void undo(Ply ply);
void undoPly(Ply ply);
}