public abstract class ScriptAction extends AbstractAction
Modifier and Type | Class and Description |
---|---|
protected class |
ScriptAction.ScriptRunner
Use a SwingWorker to run the script in the background.
|
Modifier and Type | Field and Description |
---|---|
protected CliGuiContext |
cliGuiCtx |
changeSupport, enabled
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor and Description |
---|
ScriptAction(ScriptMenu menu,
String name,
CliGuiContext cliGuiCtx) |
Modifier and Type | Method and Description |
---|---|
abstract void |
actionPerformed(ActionEvent e)
Subclasses should override this method and then call runScript() when a script File
is determined.
|
protected void |
runScript(File script)
Run a CLI script from a File.
|
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
protected CliGuiContext cliGuiCtx
public ScriptAction(ScriptMenu menu, String name, CliGuiContext cliGuiCtx)
public abstract void actionPerformed(ActionEvent e)
protected void runScript(File script)
script
- The script file.Copyright © 2023 JBoss by Red Hat. All rights reserved.