Class RowMajorGridIterator
java.lang.Object
|
+--GridIterator
|
+--RowMajorGridIterator
- All Implemented Interfaces:
- java.util.Iterator
- public class RowMajorGridIterator
- extends GridIterator
Grid Iterator Lab:
A RowMajorGridIterator object provides an iterator that
steps through the locations of a BoundedGrid object in
row-major order. It iterates through the locations and
processes the rows of the grid, from 0 to R - 1, where
R is the number of rows in the grid. As part of processing
each row, it traverses through the columns of that row,
from 0 to C - 1, where C is the number of columns in the
grid.
- Version:
- 24 March 2004
- Author:
- Alyce Brady
- See Also:
Grid
,
Location
Constructor Summary |
RowMajorGridIterator(edu.kzoo.grid.BoundedGrid grid)
Constructs an iterator object that steps through a
grid. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
RowMajorGridIterator
public RowMajorGridIterator(edu.kzoo.grid.BoundedGrid grid)
- Constructs an iterator object that steps through a
grid.
- Parameters:
grid
- grid to iterate through