uchicago.src.sim.gui
Interface Drawable2DGridNode

All Known Implementing Classes:
AsynchAgent, Births, Boss, Boss, Boss, Competitor, Consultant, Consultant, Consultant, DeathMultiplier, Deaths, DefaultDrawableNode, Employee, Employee, Employee, HyperCell, JainNode, JiggleNode, JinGirNewNode, Judge, PopulationDensity, RabbitPopulation, Stapler, TrainedEmployee

public interface Drawable2DGridNode

Interface for a drawable 2 dimensional node that occupies a cell in a grid. Nodes to be displayed in a Network2DGridDisplay should implement this interface.

Version:
$Revision: 1.5 $ $Date: 2004/11/03 19:50:59 $
Author:
Nick Collier

Method Summary
 void draw(SimGraphics g)
          Draws this Drawable2DGridNode.
 java.util.ArrayList getOutEdges()
          Returns an ArrayList of DrawableEdges as the outgoing edges from this Drawable2DGridNode.
 double getX()
          Returns the x (column) coordinate of the cell in which this node resides.
 double getY()
          Returns the y (row) coordinate of the cell in which this node resides.
 

Method Detail

getOutEdges

java.util.ArrayList getOutEdges()
Returns an ArrayList of DrawableEdges as the outgoing edges from this Drawable2DGridNode.


getX

double getX()
Returns the x (column) coordinate of the cell in which this node resides. This coordinate will be an int. The method returns a double for compatibility between Grid and non-Grid nodes.


getY

double getY()
Returns the y (row) coordinate of the cell in which this node resides. This coordinate will be an int. The method returns a double for compatibility between Grid and non-Grid nodes.


draw

void draw(SimGraphics g)
Draws this Drawable2DGridNode.

Parameters:
g - the SimGraphics object used for drawing