|
JET | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.text.JTextComponent
javax.swing.JTextArea
edu.utep.cs.et.gui.OutputTextArea
edu.utep.cs.et.gui.output.DefaultOutputer
public class DefaultOutputer
A special text area to implement an output console. The console
output can display text messages and recognize error messages
produced by external command-line based tools, such as
javac and jmlc. It uses an associated
Editor object to locate and
highlight the corresponding source code line.
| Nested Class Summary | |
|---|---|
private static class |
DefaultOutputer.TextAreaOutputStream
A specialized output stream class to turn a text area into an output stream. |
| Nested classes/interfaces inherited from class javax.swing.JTextArea |
|---|
JTextArea.AccessibleJTextArea |
| Nested classes/interfaces inherited from class javax.swing.text.JTextComponent |
|---|
JTextComponent.AccessibleJTextComponent, JTextComponent.DropLocation, JTextComponent.KeyBinding |
| Nested classes/interfaces inherited from class javax.swing.JComponent |
|---|
JComponent.AccessibleJComponent |
| Nested classes/interfaces inherited from class java.awt.Container |
|---|
Container.AccessibleAWTContainer |
| Nested classes/interfaces inherited from class java.awt.Component |
|---|
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy |
| Field Summary | |
|---|---|
private List<ContentsChangeListener> |
contentsChangeListeners
Registered contents change listeners. |
private OutputStream |
outputStream
Abstraction of this pane into an output stream. |
private JTabbedPane |
theView
The GUI pane of this outputer. |
| Fields inherited from class javax.swing.text.JTextComponent |
|---|
DEFAULT_KEYMAP, FOCUS_ACCELERATOR_KEY |
| Fields inherited from class javax.swing.JComponent |
|---|
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
| Fields inherited from class java.awt.Component |
|---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
| Fields inherited from interface java.awt.image.ImageObserver |
|---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
| Constructor Summary | |
|---|---|
DefaultOutputer()
Creates a new instance. |
|
| Method Summary | |
|---|---|
void |
addContentsChangeListener(ContentsChangeListener l)
Registers the given contents change listener. |
void |
append(String msg)
Appends the given message to this text area. |
private JComponent |
createOutputPane()
Creates and returns a tabbed pane containing a scrollable pane for the console output. |
protected JPopupMenu |
createPopupMenu(Action copy)
Creates a popup menu for this output pane. |
JComponent |
getView()
Returns the output pane that can be added to the main GUI. |
private void |
notifyContentsChanged()
Notifies to the registered change listeners that the contents of this output console has been changed. |
OutputStream |
outputStream()
Returns an output stream view of the output text area. |
void |
println(String msg)
Appends the given message msg to this output
area. |
| Methods inherited from class edu.utep.cs.et.gui.OutputTextArea |
|---|
parseErrorMessage, removeHighlights, setSourceCodeViewer |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface edu.utep.cs.et.gui.output.Outputer |
|---|
setSourceCodeViewer |
| Field Detail |
|---|
private final List<ContentsChangeListener> contentsChangeListeners
private OutputStream outputStream
private JTabbedPane theView
| Constructor Detail |
|---|
public DefaultOutputer()
| Method Detail |
|---|
public JComponent getView()
getView in interface Outputerpublic void println(String msg)
msg to this output
area. A newline character is automatically appended to the end
of the message.
println in interface Outputerpublic OutputStream outputStream()
outputStream in interface Outputerpublic void addContentsChangeListener(ContentsChangeListener l)
addContentsChangeListener in interface Outputerpublic void append(String msg)
append in class JTextAreaprivate void notifyContentsChanged()
private JComponent createOutputPane()
protected JPopupMenu createPopupMenu(Action copy)
clear menu item.
createPopupMenu in class OutputTextArea
|
JET | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||