edu.ksu.cis.macr.simulator.display
Class AgentGObject

java.lang.Object
  extended by no.geosoft.cc.graphics.GObject
      extended by edu.ksu.cis.macr.simulator.display.AgentGObject

public class AgentGObject
extends no.geosoft.cc.graphics.GObject


Field Summary
private  java.util.HashMap<java.lang.Integer,no.geosoft.cc.graphics.GSegment> agentList
           
private  java.util.HashMap<java.lang.Integer,edu.ksu.cis.macr.simulator.remote.DisplayData> agents
           
private  no.geosoft.cc.graphics.GStyle[] agentStyle
           
private  no.geosoft.cc.graphics.GSegment board
           
private  java.util.HashMap<java.lang.String,java.awt.Color> colors
           
private  java.util.HashSet<java.lang.String> forbid
           
private  SimDisplay grandParent
           
private  java.util.HashMap<java.lang.String,java.lang.String> icons
           
private  no.geosoft.cc.graphics.GImage image
           
private  no.geosoft.cc.graphics.GSegment meh
           
private  int old_lite
           
private  no.geosoft.cc.graphics.GStyle oldStyle
           
private  GPanel parent
           
private  int pheight
           
private  int pwidth
           
 
Fields inherited from class no.geosoft.cc.graphics.GObject
ANNOTATION_INVISIBLE, ANNOTATION_VISIBLE, DATA_INVISIBLE, DATA_VISIBLE, INVISIBLE, SYMBOLS_INVISIBLE, SYMBOLS_VISIBLE, VISIBLE, WIDGETS_INVISIBLE, WIDGETS_VISIBLE
 
Constructor Summary
AgentGObject(GPanel _parent, SimDisplay _grandParent, java.util.HashSet<java.lang.String> _forbid, java.util.HashMap<java.lang.String,java.lang.String> _icons, java.util.HashMap<java.lang.String,java.awt.Color> _colors, int width, int height)
          Constructor for AgentGObject.
 
Method Summary
 void draw()
          Necessary Drawing/redrawing method.
 void lite(int x)
          Highlights the selected agent on the gframe.
 
Methods inherited from class no.geosoft.cc.graphics.GObject
add, add, addSegment, back, backward, behind, find, find, find, find, findAll, findAll, findAllInside, findInside, findSegment, findSegment, findSegment, findSegmentInside, findSegments, findSegments, findSegmentsInside, forward, front, getChild, getChildren, getName, getNChildren, getNSegments, getObjectBehind, getObjectInFront, getParent, getScene, getSegment, getSegment, getSegments, getStyle, getTransformer, getUserData, getVisibility, getWindow, inFrontOf, isInBack, isInFront, redraw, redraw, refresh, remove, remove, removeAll, removeSegment, removeSegment, removeSegments, removeSegments, removeSegments, reposition, setName, setStyle, setUserData, setVisibility, styleChanged, toBack, toFront, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

parent

private GPanel parent

grandParent

private SimDisplay grandParent

board

private no.geosoft.cc.graphics.GSegment board

agentList

private java.util.HashMap<java.lang.Integer,no.geosoft.cc.graphics.GSegment> agentList

agentStyle

private no.geosoft.cc.graphics.GStyle[] agentStyle

agents

private java.util.HashMap<java.lang.Integer,edu.ksu.cis.macr.simulator.remote.DisplayData> agents

forbid

private java.util.HashSet<java.lang.String> forbid

icons

private java.util.HashMap<java.lang.String,java.lang.String> icons

colors

private java.util.HashMap<java.lang.String,java.awt.Color> colors

meh

private no.geosoft.cc.graphics.GSegment meh

pwidth

private final int pwidth

pheight

private final int pheight

image

private no.geosoft.cc.graphics.GImage image

oldStyle

private no.geosoft.cc.graphics.GStyle oldStyle

old_lite

private int old_lite
Constructor Detail

AgentGObject

public AgentGObject(GPanel _parent,
                    SimDisplay _grandParent,
                    java.util.HashSet<java.lang.String> _forbid,
                    java.util.HashMap<java.lang.String,java.lang.String> _icons,
                    java.util.HashMap<java.lang.String,java.awt.Color> _colors,
                    int width,
                    int height)
Constructor for AgentGObject. @param _parent: GPanel that owns this * GObject @param _grandparent: SimDisplay that owns the parent @param forbid: HashSet of Objects to not be displayed @param icons: HashMap of which images go with which Objects @param colors: HashMap of whish Colors go with which Objects

Method Detail

lite

public void lite(int x)
Highlights the selected agent on the gframe. Swaps out one style for another


draw

public void draw()
Necessary Drawing/redrawing method. Auto called by parent sets segment display options, image, color, shape, position, etc

Overrides:
draw in class no.geosoft.cc.graphics.GObject