gui.playfield
Class NodeGraphic

java.lang.Object
  extended by gui.playfield.PlayFieldGraphic
      extended by gui.playfield.NodeGraphic

public class NodeGraphic
extends PlayFieldGraphic

Visualization of a DTN Node


Field Summary
 
Fields inherited from class gui.playfield.PlayFieldGraphic
scale
 
Constructor Summary
NodeGraphic(DTNHost node)
           
 
Method Summary
 void draw(java.awt.Graphics2D g2)
          Draws the graphic component to the graphics context g2
static void setDrawConnections(boolean draw)
          Sets whether node's connections to other nodes should be drawn
static void setDrawCoverage(boolean draw)
          Sets whether radio coverage of nodes should be drawn
static void setDrawNodeName(boolean draw)
          Sets whether node's name should be displayed
 
Methods inherited from class gui.playfield.PlayFieldGraphic
getScale, invScale, scale, scale, setScale
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NodeGraphic

public NodeGraphic(DTNHost node)
Method Detail

draw

public void draw(java.awt.Graphics2D g2)
Description copied from class: PlayFieldGraphic
Draws the graphic component to the graphics context g2

Specified by:
draw in class PlayFieldGraphic
Parameters:
g2 - The context to draw the graphics to

setDrawCoverage

public static void setDrawCoverage(boolean draw)
Sets whether radio coverage of nodes should be drawn

Parameters:
draw - If true, radio coverage is drawn

setDrawNodeName

public static void setDrawNodeName(boolean draw)
Sets whether node's name should be displayed

Parameters:
draw - If true, node's name is displayed

setDrawConnections

public static void setDrawConnections(boolean draw)
Sets whether node's connections to other nodes should be drawn

Parameters:
draw - If true, node's connections to other nodes is drawn