be.madoka.aardbei.sokoban
Class Position

java.lang.Object
  |
  +--be.madoka.aardbei.sokoban.Position

public class Position
extends java.lang.Object

Represents a Position.

Author:
Tim Van Wassenhove

Constructor Summary
Position(int posX, int posY)
          Default constructor.
 
Method Summary
 boolean equals(Position position)
          Compares with a given Position.
 int getX()
          Gives the X-position.
 int getY()
          Gives the Y-position.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Position

public Position(int posX,
                int posY)
Default constructor.

Parameters:
posX - the X-position
posY - the Y-position
Method Detail

getX

public int getX()
Gives the X-position.

Returns:
an int giving the position on the X-axis

getY

public int getY()
Gives the Y-position.

Returns:
an int giving the position on the Y-axis

equals

public boolean equals(Position position)
Compares with a given Position.

Parameters:
position - the Position to compare with
Returns:
a boolean specifying whether the Positions are equal or not