RePast
v. 2.0

uchicago.src.sim.gui
Class DrawablePolygon

java.lang.Object
  |
  +--uchicago.src.sim.network.DefaultNode
        |
        +--uchicago.src.sim.gis.PolygonAdapter
              |
              +--uchicago.src.sim.gui.DrawablePolygon
All Implemented Interfaces:
DrawableGisFeature, DrawableMultiFeature, Node, RepastGisFeature
Direct Known Subclasses:
SchellingPolygon

public class DrawablePolygon
extends PolygonAdapter
implements DrawableMultiFeature, DrawableGisFeature


Nested Class Summary
 
Nested classes inherited from class uchicago.src.sim.network.DefaultNode
DefaultNode.OrderedHashMap
 
Field Summary
 
Fields inherited from class uchicago.src.sim.gis.PolygonAdapter
attributes, geometry, label, multi, points
 
Fields inherited from class uchicago.src.sim.network.DefaultNode
inEdges, inMap, outEdges, outMap
 
Constructor Summary
DrawablePolygon(org.geotools.feature.Feature f)
           
DrawablePolygon(com.vividsolutions.jts.geom.Geometry geo, Hashtable attr)
           
 
Method Summary
 boolean contains(double x, double y)
           
 void draw(SimGraphics g)
           
 Color getColor()
           
 com.vividsolutions.jts.geom.Coordinate[] getCoords()
           
 int[] getFeatures()
           
 String getLabel()
           
 void setColor(Color color)
           
 void setLabel(String label)
           
 
Methods inherited from class uchicago.src.sim.gis.PolygonAdapter
addAttribute, crosses, disjoint, getAttribute, getAttributeNames, getAttributes, getGeometry, intersects, isMulti, overlaps, setAttributes, setFeature, setGeometry, touches, within
 
Methods inherited from class uchicago.src.sim.network.DefaultNode
addInEdge, addInEdges, addOutEdge, addOutEdges, clearInEdges, clearOutEdges, getEdgesFrom, getEdgesTo, getFromNodes, getId, getInDegree, getInEdges, getInNodes, getNode, getNodeLabel, getNumInEdges, getNumOutEdges, getOutDegree, getOutEdges, getOutNodes, getRandomFromNode, getRandomNodeIn, getRandomNodeOut, getRandomToNode, getToNodes, hasEdgeFrom, hasEdgeTo, hasEdgeToOrFrom, makeRandomInEdge, makeRandomOutEdge, removeEdgesFrom, removeEdgesTo, removeInEdge, removeOutEdge, setNodeLabel
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface uchicago.src.sim.gis.RepastGisFeature
addAttribute, crosses, disjoint, getAttribute, getAttributeNames, getGeometry, intersects, isMulti, overlaps, setAttributes, setFeature, setGeometry, touches, within
 

Constructor Detail

DrawablePolygon

public DrawablePolygon(org.geotools.feature.Feature f)

DrawablePolygon

public DrawablePolygon(com.vividsolutions.jts.geom.Geometry geo,
                       Hashtable attr)
Method Detail

getLabel

public String getLabel()

setLabel

public void setLabel(String label)

getCoords

public com.vividsolutions.jts.geom.Coordinate[] getCoords()
Specified by:
getCoords in interface DrawableGisFeature

contains

public boolean contains(double x,
                        double y)
Specified by:
contains in interface DrawableGisFeature

getColor

public Color getColor()
Specified by:
getColor in interface DrawableGisFeature

setColor

public void setColor(Color color)
Specified by:
setColor in interface DrawableGisFeature

getFeatures

public int[] getFeatures()
Specified by:
getFeatures in interface DrawableMultiFeature

draw

public void draw(SimGraphics g)
Specified by:
draw in interface DrawableGisFeature

RePast
v. 2.0

Bug reports and feature requests to RePast