Package uk.ac.starlink.topcat.plot2
Class SingleZoneLayerControl
java.lang.Object
uk.ac.starlink.topcat.plot2.TabberControl
uk.ac.starlink.topcat.plot2.ConfigControl
uk.ac.starlink.topcat.plot2.SingleZoneLayerControl
- All Implemented Interfaces:
Configger
,Control
,LayerControl
- Direct Known Subclasses:
BasicCoordLayerControl
,DatalessLayerControl
,FunctionLayerControl
Partial LayerControl implementation for single-zone plots.
- Since:
- 18 Aug 2023
- Author:
- Mark Taylor
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
SingleZoneLayerControl
(String label, Icon icon, uk.ac.starlink.ttools.plot2.config.Specifier<ZoneId> zsel) Constructor. -
Method Summary
Modifier and TypeMethodDescriptiongetLayers
(uk.ac.starlink.ttools.plot2.Ganger<?, ?> ganger) Returns the layers contributed by this control.protected abstract SingleZoneLayer
Returns the layer produced by this control.boolean
Indicates whether this control will yield any layers in its current state.void
submitReports
(Map<LayerId, uk.ac.starlink.ttools.plot2.ReportMap> reports, uk.ac.starlink.ttools.plot2.Ganger<?, ?> ganger) Accepts report information generated by plotting layers.Methods inherited from class uk.ac.starlink.topcat.plot2.ConfigControl
addSpecifierTab, getConfig, getConfigSpecifiers
Methods inherited from class uk.ac.starlink.topcat.plot2.TabberControl
addActionListener, addControlTab, addZoneTab, getActionForwarder, getControlIcon, getControlLabel, getPanel, getTabber, removeActionListener
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface uk.ac.starlink.topcat.plot2.Control
addActionListener, getControlIcon, getControlLabel, getPanel, removeActionListener
Methods inherited from interface uk.ac.starlink.topcat.plot2.LayerControl
getCoordLabel, getLegendEntries, getPlotters, getTableSelector, getZoneSpecifier
-
Constructor Details
-
Method Details
-
getSingleZoneLayer
Returns the layer produced by this control.- Returns:
- single zone layer, or null if none is active
-
hasLayers
public boolean hasLayers()Description copied from interface:LayerControl
Indicates whether this control will yield any layers in its current state. It returns true ifgetLayers
will return a non-empty array. False positives are best avoided, but permitted.- Specified by:
hasLayers
in interfaceLayerControl
- Returns:
- true if there is a non-zero number of layers
-
getLayers
Description copied from interface:LayerControl
Returns the layers contributed by this control.- Specified by:
getLayers
in interfaceLayerControl
- Parameters:
ganger
- ganger within which layers will be used- Returns:
- layers
-
submitReports
public void submitReports(Map<LayerId, uk.ac.starlink.ttools.plot2.ReportMap> reports, uk.ac.starlink.ttools.plot2.Ganger<?, ?> ganger) Description copied from interface:LayerControl
Accepts report information generated by plotting layers. The submitted map may contain entries unrelated to this layer. Null map values are permitted, with the same meaning as an empty map.- Specified by:
submitReports
in interfaceLayerControl
- Parameters:
reports
- per-layer plot reports for layers generated on behalf of this and possibly other controlsganger
- ganger within which layers will be used
-