public class PlanarGraphPlugIn extends ThreadedBasePlugIn
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
CALCULATE_FACES |
static java.lang.String |
CALCULATE_NODES |
static java.lang.String |
CALCULATE_RELATIONS |
static java.lang.String |
CATEGORY |
static java.lang.String |
EDGE |
java.util.Collection |
edges |
static java.lang.String |
FACE |
static java.lang.String |
KEEP_ATTRIBUTES |
static java.lang.String |
MAPPING |
static java.lang.Integer |
MINUS_ONE |
static java.lang.String |
NODE |
static java.lang.String |
SELECT_LAYER |
static java.lang.String |
TITLE |
shortcutKeys, shortcutModifiers
Constructor and Description |
---|
PlanarGraphPlugIn() |
Modifier and Type | Method and Description |
---|---|
FeatureCollection |
createEdgeLayer(FeatureCollection fc,
boolean nodeb,
boolean faceb,
boolean relations,
PlugInContext context) |
FeatureCollection |
createFaceLayer(FeatureCollection fcEdge,
PlugInContext context,
boolean relations) |
FeatureCollection |
createNodeLayer(FeatureCollection fcEdge,
PlugInContext context,
boolean relations) |
boolean |
execute(PlugInContext context)
Performs the action for this plugin.
|
java.util.List |
getLines(FeatureCollection fc) |
java.lang.String |
getName()
Returns a very brief description of this PlugIn e.g. for display as a menu item
|
void |
initialize(PlugInContext context)
Called when Workbench starts up to allow plugins to initialize themselves.
|
void |
run(TaskMonitor monitor,
PlugInContext context)
Calculations take place here
|
main
addParameter, createName, execute, execute, fetchShortcutEnabledPlugins, getBooleanParam, getDoubleParam, getEnableCheck, getEnableCheck, getIcon, getIcon, getIntegerParam, getParameter, getParameters, getShortcutKeys, getShortcutKeyStroke, getShortcutModifiers, getStringParam, isRollingBackInvalidEdits, isShortcutEnabled, registerShortcuts, reportNothingToUndoYet, setParameters, setShortcutKeys, setShortcutModifiers, toActionListener, toString
public static final java.lang.String EDGE
public static final java.lang.String FACE
public static final java.lang.String NODE
public static final java.lang.String CATEGORY
public static final java.lang.String MAPPING
public static final java.lang.String TITLE
public static final java.lang.String SELECT_LAYER
public static final java.lang.String CALCULATE_NODES
public static final java.lang.String CALCULATE_FACES
public static final java.lang.String CALCULATE_RELATIONS
public static final java.lang.String KEEP_ATTRIBUTES
public static final java.lang.Integer MINUS_ONE
public java.util.Collection edges
public void run(TaskMonitor monitor, PlugInContext context) throws java.lang.Exception
monitor
- context to which this task can report its progress and
check whether a party has requested its cancellationjava.lang.Exception
public void initialize(PlugInContext context) throws java.lang.Exception
PlugIn
initialize
in interface PlugIn
initialize
in class AbstractPlugIn
context
- java.lang.Exception
public boolean execute(PlugInContext context) throws java.lang.Exception
PlugIn
false
to prevent the run method
from being called.execute
in interface PlugIn
execute
in class AbstractPlugIn
java.lang.Exception
- if a problem occurs during plug-in executionThreadedPlugIn
public java.lang.String getName()
PlugIn
getName
in interface PlugIn
getName
in class AbstractPlugIn
public java.util.List getLines(FeatureCollection fc)
public FeatureCollection createEdgeLayer(FeatureCollection fc, boolean nodeb, boolean faceb, boolean relations, PlugInContext context)
public FeatureCollection createNodeLayer(FeatureCollection fcEdge, PlugInContext context, boolean relations)
public FeatureCollection createFaceLayer(FeatureCollection fcEdge, PlugInContext context, boolean relations)