View Javadoc

1   package cz.cuni.amis.pogamut.defcon.communication.worldview.modules.grid;
2   
3   import java.util.LinkedList;
4   import java.util.List;
5   
6   import cz.cuni.amis.pogamut.base3d.worldview.object.Location;
7   
8   /**
9    * Iteator used for the experimental grid interface to traverse the map.
10   * 
11   * @author Radek 'Black_Hand' Pibil
12   * 
13   * @param <GRID_CELL>
14   * @param <GRID_CELL_ID>
15   */
16  public interface IGridIterator<GRID_CELL extends IGridCell, GRID_CELL_ID extends IGridCellId> {
17  	
18  	public GRID_CELL getTopNeighbourCell();
19  	
20  	public GRID_CELL getRightNeighbourCell();
21  	
22  	public GRID_CELL getBottomNeighbourCell();
23  	
24  	public GRID_CELL getLeftNeighbourCell();
25  	
26  	public GRID_CELL getTopLeftNeighbourCell();
27  	
28  	public GRID_CELL getTopRightNeighbourCell();
29  	
30  	public GRID_CELL getBottomLeftNeighbourCell();
31  	
32  	public GRID_CELL getBottomRightNeighbourCell();
33  	
34  	public GRID_CELL getNeighbourCellInDirection(Location direction);	
35  	
36  	public GRID_CELL moveToTopNeighbourCell();
37  	
38  	public GRID_CELL moveToRightNeighbourCell();
39  	
40  	public GRID_CELL moveToBottomNeighbourCell();
41  	
42  	public GRID_CELL moveToLeftNeighbourCell();
43  	
44  	public GRID_CELL moveToTopLeftNeighbourCell();
45  	
46  	public GRID_CELL moveToTopRightNeighbourCell();
47  	
48  	public GRID_CELL moveToBottomLeftNeighbourCell();
49  	
50  	public GRID_CELL moveToBottomRightNeighbourCell();	
51  	
52  	public GRID_CELL moveToNeighbourCellInDirection(Location direction);
53  	
54  	public List<GRID_CELL> getListOfNeighbouringCells();
55  	
56  	public GRID_CELL getCell();
57  	
58  	public LinkedList<GRID_CELL_ID> getCellsInRadiusOf(float radius);	
59  }