java.lang.Object
it.polimi.ingsw.dataClass.GameData
public class GameData
extends java.lang.Object
A data class for Game
It can be useful to send game information over the network, without any reference to the actual game object.
Its attributes are data classes too.
-
Constructor Summary
Constructors Constructor Description GameData(java.util.List<Cell> board, java.util.List<PlayerData> players, TurnData currentTurn)
Default constructor -
Method Summary
Modifier and Type Method Description java.util.List<Cell>
getBoard()
board getterTurnData
getCurrentTurn()
currentTurn getterjava.util.List<PlayerData>
getPlayers()
players getter
-
Constructor Details
-
GameData
public GameData(java.util.List<Cell> board, java.util.List<PlayerData> players, TurnData currentTurn)Default constructor- Parameters:
board
- the gameBoardplayers
- the list of playerscurrentTurn
- the current turn information
-
-
Method Details
-
getBoard
board getter- Returns:
- the gameBoard
-
getPlayers
players getter- Returns:
- the list of players
-
getCurrentTurn
currentTurn getter- Returns:
- the current turn
-