GlobalNavigation
Class Grid.Cell

java.lang.Object
  extended by GlobalNavigation.Grid.Cell
Enclosing class:
Grid

public class Grid.Cell
extends java.lang.Object


Method Summary
 double getCenterX()
          Get the x coordinate of the center of this cell.
 double getCenterY()
          Get the y coordinate of the center of this cell.
 boolean hasPathToGoal()
          Check whether this cell has a path to the goal.
 java.awt.geom.Point2D.Double makeCenterPoint()
          Return the center point of this cell.
 java.lang.String toString()
          Return a human-readable string representation of this cell.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

getCenterX

public double getCenterX()

Get the x coordinate of the center of this cell.

Returns:
the x coordinate of the center of this cell

getCenterY

public double getCenterY()

Get the y coordinate of the center of this cell.

Returns:
the y coordinate of the center of this cell

makeCenterPoint

public java.awt.geom.Point2D.Double makeCenterPoint()

Return the center point of this cell.

Returns:
the center point of this cell as a new point

hasPathToGoal

public boolean hasPathToGoal()

Check whether this cell has a path to the goal.

Returns true even if this cell contains the goal (i.e. toGoalNext is null).

Returns:
true iff this cell has a path to the goal

toString

public java.lang.String toString()

Return a human-readable string representation of this cell.

Overrides:
toString in class java.lang.Object