Class ToolboxPlugIn
- java.lang.Object
-
- org.locationtech.jts.jump.workbench.plugin.AbstractPlugIn
-
- org.locationtech.jts.jump.workbench.ui.toolbox.ToolboxPlugIn
-
- All Implemented Interfaces:
PlugIn
- Direct Known Subclasses:
BeanShellPlugIn
,EditingPlugIn
,WarpingPlugIn
,ZoomBarPlugIn
public abstract class ToolboxPlugIn extends AbstractPlugIn
-
-
Constructor Summary
Constructors Constructor Description ToolboxPlugIn()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description void
createMainMenuItem(String[] menuPath, Icon icon, WorkbenchContext context)
Creates a menu item with a checkbox beside it that appears when the toolbox is visible.boolean
execute(PlugInContext context)
Toolbox subclasses can override this method to implement their own behaviour when the plug-in is called.ToolboxDialog
getToolbox(WorkbenchContext context)
protected abstract void
initializeToolbox(ToolboxDialog toolbox)
-
Methods inherited from class org.locationtech.jts.jump.workbench.plugin.AbstractPlugIn
createName, execute, execute, getName, initialize, isRollingBackInvalidEdits, reportNothingToUndoYet, toActionListener, toString
-
-
-
-
Method Detail
-
getToolbox
public ToolboxDialog getToolbox(WorkbenchContext context)
- Returns:
- the toolbox for this plug-in class.
-
initializeToolbox
protected abstract void initializeToolbox(ToolboxDialog toolbox)
-
execute
public boolean execute(PlugInContext context) throws Exception
Toolbox subclasses can override this method to implement their own behaviour when the plug-in is called. Remember to call super.execute to make the toolbox visible.- Specified by:
execute
in interfacePlugIn
- Overrides:
execute
in classAbstractPlugIn
- Returns:
- true if the action completed, false if it was aborted. Used by ThreadedPlugIns to indicate that their #run method needn't be called next.
- Throws:
Exception
- if a problem occurs during plug-in execution- See Also:
ThreadedPlugIn
-
createMainMenuItem
public void createMainMenuItem(String[] menuPath, Icon icon, WorkbenchContext context) throws Exception
Creates a menu item with a checkbox beside it that appears when the toolbox is visible.- Parameters:
icon
- null to leave unspecified- Throws:
Exception
-
-