Fix: all JavaDOC completed
This commit is contained in:
@@ -31,7 +31,7 @@ public class Player implements Serializable {
|
||||
// region Getters
|
||||
/**
|
||||
* Unique string identifier for players; must not be {@code null} and must not
|
||||
* exceed {@link #MAX_VALUE} otherwise an {@link IllegalArgumentException} will be thrown
|
||||
* exceed {@link #MAX_USERNAME_LENGTH} otherwise an {@link IllegalArgumentException} will be thrown
|
||||
* when the {@link #Player(String) constructor} is called.
|
||||
*/
|
||||
private final String userName;
|
||||
@@ -224,7 +224,13 @@ public class Player implements Serializable {
|
||||
|
||||
// region Functions
|
||||
|
||||
// TODO
|
||||
/**
|
||||
* Checks equality between this {@code Player} and another object.
|
||||
* Two players are equal if and only if they share the same {@code userName}.
|
||||
*
|
||||
* @param obj the object to compare with.
|
||||
* @return {@code true} if {@code obj} is a {@code Player} with the same username; {@code false} otherwise.
|
||||
*/
|
||||
@Override
|
||||
public boolean equals(Object obj) {
|
||||
if (this == obj) return true;
|
||||
|
||||
Reference in New Issue
Block a user