Class ToolAdapterActionRegistrar
- java.lang.Object
-
- org.esa.snap.ui.tooladapter.actions.ToolAdapterActionRegistrar
-
public class ToolAdapterActionRegistrar extends Object
Helper class for creating menu entries for tool adapter operators. The inner runnable class should be invoked when the IDE starts, and will register the available adapters as menu actions.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ToolAdapterActionRegistrar.StartOp
Startup class that performs menu initialization to be invoked by NetBeans.static class
ToolAdapterActionRegistrar.StopOp
-
Constructor Summary
Constructors Constructor Description ToolAdapterActionRegistrar()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Map<String,ToolAdapterOperatorDescriptor>
getActionMap()
Returns the map of menu items (actions) and operator descriptors.static String
getDefaultMenuLocation()
static void
registerOperatorMenu(ToolAdapterOperatorDescriptor operator)
Creates a menu entry in the default menu location (Tools > External Tools) for the given adapter operator.static void
registerOperatorMenu(ToolAdapterOperatorDescriptor operator, boolean hasChanged)
Creates a menu entry in the given menu location for the given adapter operator.static void
removeOperatorMenu(ToolAdapterOperatorDescriptor operator)
-
-
-
Method Detail
-
getActionMap
public static Map<String,ToolAdapterOperatorDescriptor> getActionMap()
Returns the map of menu items (actions) and operator descriptors.- Returns:
-
getDefaultMenuLocation
public static String getDefaultMenuLocation()
-
registerOperatorMenu
public static void registerOperatorMenu(ToolAdapterOperatorDescriptor operator)
Creates a menu entry in the default menu location (Tools > External Tools) for the given adapter operator.- Parameters:
operator
- The operator descriptor
-
registerOperatorMenu
public static void registerOperatorMenu(ToolAdapterOperatorDescriptor operator, boolean hasChanged)
Creates a menu entry in the given menu location for the given adapter operator.- Parameters:
operator
- The operator descriptorhasChanged
- Flag that indicates if the descriptor has changed (true) or is new (false)
-
removeOperatorMenu
public static void removeOperatorMenu(ToolAdapterOperatorDescriptor operator)
-
-