public class Position
extends java.lang.Object
Constructor and Description |
---|
Position(int xCoordinate,
int yCoordinate)
Initializes the position
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object obj) |
int |
getXCoordinate()
Gets the x coordinate of the position
|
int |
getYCoordinate()
Gets the y coordinate of the position
|
java.lang.String |
toString() |
public Position(int xCoordinate, int yCoordinate)
xCoordinate
- The x coordinate of the positionyCoordinate
- The y coordinate of the positionpublic int getXCoordinate()
public int getYCoordinate()
public java.lang.String toString()
toString
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object