Legger til manglende kommentarer for metoder krevd av kryo

This commit is contained in:
Kristian Knarvik 2020-04-07 22:30:51 +02:00
parent b3fee7494f
commit cb9841ecf9

View File

@ -6,9 +6,8 @@ import java.util.ArrayList;
import java.util.List; import java.util.List;
/** /**
* This Class represents a player * This class represents a player
*/ */
public class Player { public class Player {
private RobotID robotID; private RobotID robotID;
private String name; private String name;
@ -26,14 +25,27 @@ public class Player {
this.robotID = robotID; this.robotID = robotID;
this.name = name; this.name = name;
} }
/**
* Empty constructor required by kryo
*/
public Player(){} public Player(){}
public void setRobotID(RobotID robotID){
this.robotID=robotID; /**
} * Sets the robot id of the robot
public void setName(String name){ * @param robotID The new id of the robot
this.name=name; */
public void setRobotID(RobotID robotID) {
this.robotID = robotID;
} }
/**
* Sets the name of the robot
* @param name The new name of the robot
*/
public void setName(String name) {
this.name = name;
}
/** /**
* Gives you the RobotID of a player * Gives you the RobotID of a player