|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
An I/O connection to one tab on the Output Window. To acquire an instance
to write to, call, e.g.,
IOProvider.getDefault().getInputOutput("someName", false)
.
To get actual streams to write to, call getOut()
or
getErr()
on the returned instance.
Generally it is preferable not to hold a reference to an instance of
InputOutput
, but rather to fetch it by name from IOProvider
as
needed.
Note: For historical reasons, the mechanism to clear an output tab
is via the method OutputWriter.reset()
, though it would have
made more sense implemented here.
OutputWriter
Field Summary | |
static InputOutput |
NULL
Null InputOutput |
static Reader |
nullReader
Deprecated. Use NULL instead. |
static OutputWriter |
nullWriter
Deprecated. Use NULL instead. |
Method Summary | |
void |
closeInputOutput()
Closes this tab. |
Reader |
flushReader()
Deprecated. meaningless, does nothing |
OutputWriter |
getErr()
Get an output writer to write to the tab in error mode. |
Reader |
getIn()
Get a reader to read from the tab. |
OutputWriter |
getOut()
Acquire an output writer to write to the tab. |
boolean |
isClosed()
Test whether this tab has been closed, either by a call to closeInputOutput()
or by the user closing the tab in the UI. |
boolean |
isErrSeparated()
Test whether the error output is mixed into the regular output or not. |
boolean |
isFocusTaken()
Test whether the output window takes focus when anything is written to it. |
void |
select()
Ensure this pane is visible. |
void |
setErrSeparated(boolean value)
Set whether the error output should be mixed into the regular output or not. |
void |
setErrVisible(boolean value)
Show or hide the error pane, if separated. |
void |
setFocusTaken(boolean value)
Set whether the output window should take focus when anything is written to it. |
void |
setInputVisible(boolean value)
Show or hide the input line. |
void |
setOutputVisible(boolean value)
Show or hide the standard output pane, if separated. |
Field Detail |
public static final InputOutput NULL
public static final Reader nullReader
NULL
instead.
public static final OutputWriter nullWriter
NULL
instead.
Method Detail |
public OutputWriter getOut()
public Reader getIn()
public OutputWriter getErr()
public void closeInputOutput()
closeInputOutput()
on it is undefined.
public boolean isClosed()
closeInputOutput()
or by the user closing the tab in the UI.
true
if it is closedcloseInputOutput()
public void setOutputVisible(boolean value)
value
- true
to show, false
to hidepublic void setErrVisible(boolean value)
value
- true
to show, false
to hidepublic void setInputVisible(boolean value)
value
- true
to show, false
to hidepublic void select()
public boolean isErrSeparated()
true
if separate, false
if mixed inpublic void setErrSeparated(boolean value)
value
- true
to separate, false
to mix inpublic boolean isFocusTaken()
true
if any write to the tab should cause it to gain
keyboard focus (not recommended)public void setFocusTaken(boolean value)
value
- true
to take focuspublic Reader flushReader()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |