uk.ac.starlink.ttools.example
Class EnvPlanePlotter
java.lang.Object
uk.ac.starlink.ttools.example.EnvPlanePlotter
- All Implemented Interfaces:
- SinePlot.PlanePlotter
public class EnvPlanePlotter
- extends Object
- implements SinePlot.PlanePlotter
PlanePlotter implementation that uses the name/value pairs in the
same way as the STILTS application command-line interface to set
up a plot.
This is much easier to do than the alternative, since the large
majority of the options will assume sensible defaults if not set.
It allows pretty much the same capabilities. However, it does
not offer compile-time safety: there is no guarantee that a plot
set up like this will not generate a run-time error.
- Since:
- 12 Jun 2014
- Author:
- Mark Taylor
Method Summary |
PlotDisplay |
createPlotComponent(uk.ac.starlink.table.StarTable table,
boolean dataMayChange)
Creates a JComponent holding a plot of the data in the first two
columns of the supplied table. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
EnvPlanePlotter
public EnvPlanePlotter()
createPlotComponent
public PlotDisplay createPlotComponent(uk.ac.starlink.table.StarTable table,
boolean dataMayChange)
throws InterruptedException,
IOException,
uk.ac.starlink.task.TaskException
- Description copied from interface:
SinePlot.PlanePlotter
- Creates a JComponent holding a plot of the data in the first two
columns of the supplied table.
This plot is live, and can be resized (as required by Swing)
and panned and zoomed (by various mouse drag and wheel gestures).
The dataMayChange
parameter is used to determine
whether the plot positions should be cached or not for repaints,
either as required by Swing move/resize actions or
as the result of the user navigating around the plot.
It's always safe to set it true, but if the data is static,
setting it false will give better performance.
- Specified by:
createPlotComponent
in interface SinePlot.PlanePlotter
- Parameters:
table
- table to plotdataMayChange
- true if the table data may change during
the lifetime of the plot
- Throws:
InterruptedException
IOException
uk.ac.starlink.task.TaskException
Copyright © 2018 Central Laboratory of the Research Councils. All Rights Reserved.