Package com.luciad.lucy.map.action
Class TLcyCreateGXYLayerAction
java.lang.Object
com.luciad.gui.ALcdAction
com.luciad.lucy.map.action.ALcyCreateLayersAction<ILcdGXYView,ILcdGXYLayer>
com.luciad.lucy.map.action.TLcyCreateGXYLayerAction
- All Implemented Interfaces:
ILcdAction,ILcdUndoableSource,ILcdPropertyChangeSource,ActionListener,Serializable,EventListener
Implementation of ALcyCreateLayersAction for ILcdGXYLayer and
ILcdGXYView instances.
Consult the class javadoc of the super class for more information on how to use this class.
- See Also:
-
Field Summary
Fields inherited from class com.luciad.gui.ALcdAction
changeSupportFields inherited from interface com.luciad.gui.ILcdAction
DEFAULT, LONG_DESCRIPTION, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SHOW_ACTION_NAME, SMALL_ICON, VISIBLE -
Constructor Summary
ConstructorsConstructorDescriptionTLcyCreateGXYLayerAction(ALcyFormat aFormat, ILcyMapComponent aMapComponent) Creates a new action capable of creating and adding anILcdGXYLayerof the specifiedALcyFormatto theILcdGXYViewofaMapComponent.TLcyCreateGXYLayerAction(ILcyLucyEnv aLucyEnv, ILcyMapComponent aMapComponent) Creates a new action capable of creating and adding anILcdGXYLayerto theILcdGXYViewofaMapComponent -
Method Summary
Modifier and TypeMethodDescriptionvoidactionPerformed(ActionEvent aEvent) Behaves equivalent tocreateAndInsertGXYLayer(java.awt.Component).createAndInsertGXYLayer(Component aParentComponent) Creates and inserts a newILcdGXYLayerinto theILcyMapComponent.protected ILcdGXYLayercreateGXYLayer(Component aParentComponent, ILcdModel aModel) Creates theILcdGXYLayer.protected List<ILcdGXYLayer> createLayersForModel(ILcdModel aModel, Component aParentComponent) Create a list of layers foraModelReturns the Lucy back-endReturns theILcyGenericMapComponentto which the created layers will be added.Methods inherited from class com.luciad.lucy.map.action.ALcyCreateLayersAction
addUndoableListener, createAndInsertLayers, createModel, fireUndoableHappened, getDefaultModelDescriptorFactory, removeUndoableListener, setDefaultModelDescriptorFactoryMethods inherited from class com.luciad.gui.ALcdAction
addPropertyChangeListener, firePropertyChange, getDisplayName, getIcon, getLongDescription, getName, getShortDescription, getValue, isEnabled, isTraceOn, putValue, registerInstance, removePropertyChangeListener, setClassTraceOn, setDisplayName, setEnabled, setIcon, setLongDescription, setName, setShortDescription, setTraceOn
-
Constructor Details
-
TLcyCreateGXYLayerAction
Creates a new action capable of creating and adding anILcdGXYLayerto theILcdGXYViewofaMapComponent- Parameters:
aLucyEnv- The Lucy back-endaMapComponent- The map component to which the created layers will be added
-
TLcyCreateGXYLayerAction
Creates a new action capable of creating and adding anILcdGXYLayerof the specifiedALcyFormatto theILcdGXYViewofaMapComponent.- Parameters:
aFormat- The format. This format should return a singleALcyDefaultModelDescriptorFactoryinstance from itsALcyFormat.getDefaultModelDescriptorFactories()method.aMapComponent- The map component to which the created layers will be added- Since:
- 2019.0
-
-
Method Details
-
getLucyEnv
Description copied from class:ALcyCreateLayersActionReturns the Lucy back-end- Overrides:
getLucyEnvin classALcyCreateLayersAction<ILcdGXYView,ILcdGXYLayer> - Returns:
- the Lucy back-end
-
getMapComponent
Returns theILcyGenericMapComponentto which the created layers will be added.- Overrides:
getMapComponentin classALcyCreateLayersAction<ILcdGXYView,ILcdGXYLayer> - Returns:
- the
ILcyGenericMapComponentto which the created layers will be added.
-
actionPerformed
Behaves equivalent tocreateAndInsertGXYLayer(java.awt.Component).- Specified by:
actionPerformedin interfaceActionListener- Overrides:
actionPerformedin classALcyCreateLayersAction<ILcdGXYView,ILcdGXYLayer> - Parameters:
aEvent- The event object.
-
createAndInsertGXYLayer
Creates and inserts a newILcdGXYLayerinto theILcyMapComponent. Please refer to the class comment for more details about how the layer is created.- Parameters:
aParentComponent- The parent component, used to parent dialogs.- Returns:
- The layer that was created and inserted, or
nullif the end-user canceled the operation. - Throws:
IllegalArgumentException- If noALcyDefaultModelDescriptorFactorycould be found inILcyLucyEnv, and none was set. Or if noILcdModelFactorywas found, or if noILcdGXYLayerFactorywas found.
-
createLayersForModel
Create a list of layers foraModelThis method is just a wrapper around the
createGXYLayer(java.awt.Component, com.luciad.model.ILcdModel)method which wraps the result in aList.- Specified by:
createLayersForModelin classALcyCreateLayersAction<ILcdGXYView,ILcdGXYLayer> - Parameters:
aModel- The model to create the layers foraParentComponent- The parent component, used to parent dialogs.- Returns:
- A list containing the layers that were created for
aModel. This list should not be empty, nor should it containnull. Can benullin case the end-user cancelled the operation.
-
createGXYLayer
Creates theILcdGXYLayer. Please refer to the class comment for more details about how the layer is created.- Parameters:
aParentComponent- The parent component, used to parent dialogs.aModel- The model to create a layer for.- Returns:
- The created
ILcdGXYLayer, ornullif the end-user canceled the operation.
-