public abstract class StiltsMonitor<S extends StiltsMonitor.State> extends Object
| Modifier and Type | Class and Description |
|---|---|
static interface |
StiltsMonitor.State
Represents a STILTS command.
|
| Modifier | Constructor and Description |
|---|---|
protected |
StiltsMonitor()
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
static JComponent |
createErrorDisplay(Throwable error)
Returns a component that can display an error.
|
protected abstract S |
createState()
Returns a state object describing the content that should be
displayed in this monitor.
|
Action |
getClipboardAction()
Returns an action that copies all the current stilts command text
into the system clipboard.
|
Action |
getErrorAction()
Returns an action that will pop up the error resulting from
attempting to execute the current stilts command in a dialog window,
if an error exists.
|
S |
getState()
Returns the current state of this monitor.
|
JTextComponent |
getTextPanel()
Returns the text panel which displays the stilts command.
|
int |
getWidthCharacters()
Returns the width of the text display panel in characters.
|
protected void |
resetState()
Called if the state that defines what appears in the text pane
is changed in some way.
|
static JComponent |
wrapTextPanel(JTextComponent textPanel)
Utility method for packaging the text panel returned by this
object's
getTextPanel() method. |
protected abstract S createState()
public S getState()
public JTextComponent getTextPanel()
public Action getClipboardAction()
public Action getErrorAction()
public int getWidthCharacters()
protected void resetState()
public static JComponent wrapTextPanel(JTextComponent textPanel)
getTextPanel() method.
This puts it in a scroll pane, and makes sure the lines don't wrap.textPanel - text panel, supposed to be from this monitorpublic static JComponent createErrorDisplay(Throwable error)
error - exceptionCopyright © 2003-2025 CCLRC: Council for the Central Laboratory of the Research Councils. All Rights Reserved.