RePast
v. 2.0

uchicago.src.sim.gui
Class DrawableLineString

java.lang.Object
  |
  +--uchicago.src.sim.network.DefaultEdge
        |
        +--uchicago.src.sim.gis.LineStringAdapter
              |
              +--uchicago.src.sim.gui.DrawableLineString
All Implemented Interfaces:
DrawableGisFeature, DrawableMultiFeature, Edge, RepastGisFeature

public class DrawableLineString
extends LineStringAdapter
implements DrawableGisFeature, DrawableMultiFeature


Field Summary
 
Fields inherited from class uchicago.src.sim.gis.LineStringAdapter
attributes, geometry, multi, points
 
Fields inherited from class uchicago.src.sim.network.DefaultEdge
from, label, strength, to, type
 
Constructor Summary
DrawableLineString(org.geotools.feature.Feature f)
           
DrawableLineString(com.vividsolutions.jts.geom.Geometry geo, Hashtable attr)
           
DrawableLineString(SpatialNode from, SpatialNode to)
           
 
Method Summary
 boolean contains(double x, double y)
           
 void draw(SimGraphics g)
           
 Color getColor()
           
 com.vividsolutions.jts.geom.Coordinate[] getCoords()
           
 int[] getFeatures()
           
 String getLabel()
          Gets the label for this Edge
 void setColor(Color c)
           
 void setLabel(String label)
          Sets the label for this Edge
 
Methods inherited from class uchicago.src.sim.gis.LineStringAdapter
addAttribute, crosses, disjoint, getAttribute, getAttributeNames, getGeometry, getLength, intersects, isMulti, overlaps, setAttributes, setFeature, setGeometry, touches, within
 
Methods inherited from class uchicago.src.sim.network.DefaultEdge
getFrom, getStrength, getTo, getType, setFrom, setStrength, setTo, setType
 
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

DrawableLineString

public DrawableLineString(SpatialNode from,
                          SpatialNode to)

DrawableLineString

public DrawableLineString(org.geotools.feature.Feature f)
                   throws Exception

DrawableLineString

public DrawableLineString(com.vividsolutions.jts.geom.Geometry geo,
                          Hashtable attr)
                   throws Exception
Method Detail

setLabel

public void setLabel(String label)
Description copied from class: DefaultEdge
Sets the label for this Edge

Specified by:
setLabel in interface Edge
Overrides:
setLabel in class DefaultEdge
Parameters:
label - the label for this edge

getLabel

public String getLabel()
Description copied from class: DefaultEdge
Gets the label for this Edge

Specified by:
getLabel in interface Edge
Overrides:
getLabel in class DefaultEdge

getColor

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

setColor

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

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

draw

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

getFeatures

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

RePast
v. 2.0

Bug reports and feature requests to RePast