public abstract class AbstractBoundedPlot extends AbstractPlot
Copyright (c) 2013-2019 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.
DEFAULT_INITIAL_UPPER_TIME_BOUND, GRAPH_ADD_EVENT, GRAPH_REMOVE_EVENT| Constructor and Description |
|---|
AbstractBoundedPlot(OTSSimulatorInterface simulator,
String caption,
Duration updateInterval,
Duration delay)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
setAutoBoundDomain(XYPlot plot)
Overridable; activates auto bounds on domain axis from user input.
|
void |
setAutoBoundRange(XYPlot plot)
Overridable; activates auto bounds on range axis from user input.
|
protected void |
setChart(JFreeChart chart)
Sets the chart and adds menus and listeners.
|
void |
setLowerDomainBound(Double bound)
Sets the lower domain bound.
|
void |
setLowerRangeBound(Double bound)
Sets the lower range bound.
|
void |
setUpperDomainBound(Double bound)
Sets the upper domain bound.
|
void |
setUpperRangeBound(Double bound)
Sets the upper range bound.
|
addChangeListener, encodeAsPng, getCaption, getChart, getGraphType, getGroup, getId, getSimulator, getStatusLabel, getUpdateTime, increaseTime, notifyPlotChange, removeChangeListener, setGroup, setUpdateInterval, updatepublic AbstractBoundedPlot(OTSSimulatorInterface simulator, String caption, Duration updateInterval, Duration delay)
simulator - OTSSimulatorInterface; simulatorcaption - String; captionupdateInterval - Duration; regular update interval (simulation time)delay - Duration; amount of time that chart runs behind simulation to prevent gaps in the charted dataprotected void setChart(JFreeChart chart)
setChart in class AbstractPlotchart - JFreeChart; chartpublic void setLowerDomainBound(Double bound)
bound - Double; use null to disable boundpublic void setUpperDomainBound(Double bound)
bound - Double; use null to disable boundpublic void setLowerRangeBound(Double bound)
bound - Double; use null to disable boundpublic void setUpperRangeBound(Double bound)
bound - Double; use null to disable boundpublic void setAutoBoundDomain(XYPlot plot)
XYPlots,
but the auto bounds command comes from the ChartPanel that this class creates. In case the used plot is a
XYPlot, this method is then invoked. Sub classes with auto domain bounds that work with an XYPlot should
implement this. The method is not abstract as the use of XYPlot is not obligated.setAutoBoundDomain in class AbstractPlotplot - XYPlot; plotpublic void setAutoBoundRange(XYPlot plot)
XYPlots,
but the auto bounds command comes from the ChartPanel that this class creates. In case the used plot is a
XYPlot, this method is then invoked. Sub classes with auto range bounds that work with an XYPlot should
implement this. The method is not abstract as the use of XYPlot is not obligated.setAutoBoundRange in class AbstractPlotplot - XYPlot; plotCopyright © 2014–2019 Delft University of Technology. All rights reserved.