world
Class PathKey
java.lang.Object
|
+--world.PathKey
- All Implemented Interfaces:
- Comparable
- Direct Known Subclasses:
- Path
- public class PathKey
- extends Object
- implements Comparable
Class to record paths through tiles.
- Version:
- $Revision: 1.1 $
- Author:
- Allen D. Ball
Constructor Summary |
protected |
PathKey(Tile start,
Tile end)
Creates a path key. |
Methods inherited from class java.lang.Object |
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
start
protected final Tile start
end
protected final Tile end
PathKey
protected PathKey(Tile start,
Tile end)
- Creates a path key.
getStart
public Tile getStart()
getEnd
public Tile getEnd()
compareTo
public int compareTo(Object object)
- Compares this object with the specified object for order.
Returns a negative integer, zero, or a positive integer as this
object is less than, equal to, or greater than the specified
object.
- Specified by:
compareTo
in interface Comparable
- Parameters:
object
- The object to be compared.- See Also:
Comparable
getOrdinal
public int getOrdinal()
- Method to get an ordinal ordering for this path with the other
paths in its board.
Copyright 2002 Allen D. Ball. All rights reserved.