Package org.esa.snap.ui.layer
Class DefaultLayerSourceDescriptor
java.lang.Object
org.esa.snap.ui.layer.DefaultLayerSourceDescriptor
- All Implemented Interfaces:
LayerSourceDescriptor
The
DefaultLayerSourceDescriptor provides metadata and
a factory method for a LayerSource.
Instances of this class are created by reading the extension configuration of
the extension point "layerSources" in the module.xml.
<extension point="beam-visat-rcp:layerSources">
<layerSource>
<id>shapefile-layer-source</id>
<name>ESRI Shapefile</name>
<description>Displays shapes from an ESRI Shapefile</description>
<class>org.esa.snap.visat.toolviews.layermanager.layersrc.shapefile.ShapefileLayerSource</class>
</layerSource>
</extension>
Example 2:
<extension point="beam-visat-rcp:layerSources">
<layerSource>
<id>bluemarble-layer-source</id>
<name>NASA Blue Marble;/name>
<description>Adds NASA Blue Marble image layer to the background.</description>
<layerType>org.esa.snap.worldmap.BlueMarbleLayerType</class>
</layerSource>
</extension>
Note: This API is not public yet and may significantly change in the future. Use it at your own risk.
-
Constructor Summary
ConstructorsConstructorDescriptionDefaultLayerSourceDescriptor(String id, String name, String description, Class<? extends LayerSource> layerSourceClass) DefaultLayerSourceDescriptor(String id, String name, String description, String layerTypeClassName) -
Method Summary
Modifier and TypeMethodDescriptionCreates theLayerSourcewhich is used in the graphical user interface to addLayerto a view.A text describing what theLayerSource, created by thisLayerSourceDescriptor, does.getId()A unique ID.TheLayerType.getName()A human readable name.toString()
-
Constructor Details
-
DefaultLayerSourceDescriptor
public DefaultLayerSourceDescriptor(String id, String name, String description, Class<? extends LayerSource> layerSourceClass) -
DefaultLayerSourceDescriptor
-
-
Method Details
-
getId
Description copied from interface:LayerSourceDescriptorA unique ID.- Specified by:
getIdin interfaceLayerSourceDescriptor- Returns:
- The unique ID.
-
getName
Description copied from interface:LayerSourceDescriptorA human readable name.- Specified by:
getNamein interfaceLayerSourceDescriptor- Returns:
- The name.
-
getDescription
Description copied from interface:LayerSourceDescriptorA text describing what theLayerSource, created by thisLayerSourceDescriptor, does.- Specified by:
getDescriptionin interfaceLayerSourceDescriptor- Returns:
- A description.
-
toString
-
createLayerSource
Description copied from interface:LayerSourceDescriptorCreates theLayerSourcewhich is used in the graphical user interface to addLayerto a view.- Specified by:
createLayerSourcein interfaceLayerSourceDescriptor- Returns:
- The
LayerSource.
-
getLayerType
Description copied from interface:LayerSourceDescriptorTheLayerType.- Specified by:
getLayerTypein interfaceLayerSourceDescriptor- Returns:
- the type of the layer which is added to a view, or
nullif multiple layers are added.
-