|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object WatorWorld.AbstractGrid<E> WatorWorld.BoundedGrid<E> WatorWorld.WrappedBoundedGrid<E>
public class WrappedBoundedGrid<E>
Constructor Summary | |
---|---|
WrappedBoundedGrid(int rows,
int cols)
|
Method Summary | |
---|---|
ArrayList<Location> |
getValidAdjacentLocations(Location loc)
Gets the valid locations adjacent to a given location in all eight compass directions (north, northeast, east, southeast, south, southwest, west, and northwest). |
Methods inherited from class WatorWorld.BoundedGrid |
---|
get, getNumCols, getNumRows, getOccupiedLocations, isValid, put, remove |
Methods inherited from class WatorWorld.AbstractGrid |
---|
getEmptyAdjacentLocations, getNeighbors, getOccupiedAdjacentLocations, toString |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public WrappedBoundedGrid(int rows, int cols)
Method Detail |
---|
public ArrayList<Location> getValidAdjacentLocations(Location loc)
Grid
loc
is valid in this grid
getValidAdjacentLocations
in interface Grid<E>
getValidAdjacentLocations
in class AbstractGrid<E>
loc
- a location in this grid
loc
in this grid
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |