public class TextAreaStreams
extends java.lang.Object
InputStream
and OutputStream
that affect the content
of a JTextArea
. Specifically, this code is used to instantiate a GUI for the EnvironmentShell
used by a VisualExplorer
.Modifier and Type | Class and Description |
---|---|
class |
TextAreaStreams.TextIn |
class |
TextAreaStreams.TextOut |
Modifier and Type | Field and Description |
---|---|
protected javax.swing.JTextArea |
area |
protected int |
bufIndex |
protected java.lang.StringBuffer |
inputBuf |
protected TextAreaStreams.TextIn |
tin |
protected TextAreaStreams.TextOut |
tout |
Constructor and Description |
---|
TextAreaStreams(javax.swing.JTextArea area) |
Modifier and Type | Method and Description |
---|---|
TextAreaStreams.TextIn |
getTin()
Returns the
InputStream for the JTextArea . |
TextAreaStreams.TextOut |
getTout()
Returns the
OutputStream for the JTextArea |
void |
receiveInput(java.lang.String input)
Adds data to the
InputStream |
protected javax.swing.JTextArea area
protected java.lang.StringBuffer inputBuf
protected int bufIndex
protected TextAreaStreams.TextOut tout
protected TextAreaStreams.TextIn tin
public TextAreaStreams.TextOut getTout()
OutputStream
for the JTextArea
TextAreaStreams.TextOut
OutputStream
public TextAreaStreams.TextIn getTin()
InputStream
for the JTextArea
.TextAreaStreams.TextIn
InputStream
public void receiveInput(java.lang.String input)
InputStream
input
- the string data to add.