/// <summary> /// Subs the grid. /// </summary> /// <returns>The grid.</returns> /// <param name="row">Row.</param> /// <param name="col">Col.</param> public ZGrid <T> SubGrid(int row, int col, int width, int height) { if (row + height >= this.Height) { return(null); } if (col + width >= this.Width) { return(null); } ZGrid <T> ret = new ZGrid <T> (width, height); for (int i = 0; i < height; i++) { for (int j = 0; j < width; j++) { ret.Datas [i, j] = Datas [i + row, j + col]; } } return(ret); }
internal ZRowIterator(ZGrid <T> grid, int curRow) { _grid = grid; cur = curRow; }
internal ZRowsEnumerator(ZGrid <T> grid) { _grid = grid; }
internal ZGridIterator(ZGrid <T> grid) { _grid = grid; }
internal ZRowEnumerator(ZGrid <T> grid, int curRow) { _grid = grid; this.curRow = curRow; }