static class GUIRunner.StackTraceLister extends Object implements ListSelectionListener
thrw
currently selected in the error list.
The representation consists in
the string representation thrwMessager
and in the stack trace given by stacktrace.
This class is also a ListSelectionListener
which opens emacsclient
with the source file and the line number
given by the selected stack trace element.
| Modifier and Type | Field and Description |
|---|---|
private ListSelectionModel |
stackElemSelection
The selection of this stack trace:
This is either empty
(which is mandatory for empty
thrwMessager)
or selects a single stack element. |
private DefaultListModel<String> |
stacktrace
Is either empty or contains the stacktrace
of the represented throwable
thrw. |
private Throwable |
thrw
Represents a throwable or is
null
if no throwable is represented. |
private JLabel |
thrwMessager
|
| Constructor and Description |
|---|
StackTraceLister()
Creates a new StackTraceLister with empty throwable.
|
| Modifier and Type | Method and Description |
|---|---|
(package private) void |
clearStack()
Clears the represented stack including
thrw and text. |
(package private) Component |
getStackTraceBox()
Returns a graphical representation of this StackTraceLister.
|
(package private) void |
setStack(Throwable thrw)
Represents the throwable
thrw
if this is not null;
otherwise just clears this stack trace lister
as is done by clearStack(). |
void |
valueChanged(ListSelectionEvent lse)
If an entry is selected, move with emacs to the according place.
|
private Throwable thrw
null
if no throwable is represented.
This is also the initial value.private final JLabel thrwMessager
private final DefaultListModel<String> stacktrace
thrw.private final ListSelectionModel stackElemSelection
thrwMessager)
or selects a single stack element.
If so, by selection emacsclient is started
at the place the stack element points to.StackTraceLister()
Component getStackTraceBox()
void clearStack()
thrw and text.void setStack(Throwable thrw)
thrw
if this is not null;
otherwise just clears this stack trace lister
as is done by clearStack().
The selection is cleared anyway.public void valueChanged(ListSelectionEvent lse)
valueChanged in interface ListSelectionListenerCopyright © 2012–2018 Simuline Organization (l2r). All rights reserved.