public class IO extends Object
Container for input/output handles.
| Modifiers | Name | Description |
|---|---|---|
static class |
IO.Verbosity |
| Modifiers | Name | Description |
|---|---|---|
PrintWriter |
err |
Prefered error output writer. |
OutputStream |
errorStream |
Raw error output stream. |
Reader |
in |
Prefered input reader. |
InputStream |
inputStream |
Raw input stream. |
PrintWriter |
out |
Prefered output writer. |
OutputStream |
outputStream |
Raw output stream. |
| Constructor and description |
|---|
IO
(InputStream inputStream, OutputStream outputStream, OutputStream errorStream)Construct a new IO container. |
IO
()Construct a new IO container using system streams. |
| Type Params | Return Type | Name and description |
|---|---|---|
|
void |
close()Close all streams. |
|
void |
flush()Flush both output streams. |
|
IO.Verbosity |
getVerbosity()Returns the verbosity level. |
|
boolean |
isDebug()Check if the verbosity level is set to Verbosity#DEBUG#DEBUG. |
|
boolean |
isInfo()Check if the verbosity level is set to Verbosity#INFO#INFO. |
|
boolean |
isQuiet()Check if the verbosity level is set to Verbosity#QUIET#QUIET. |
|
boolean |
isVerbose()Check if the verbosity level is set to Verbosity#VERBOSE#VERBOSE. |
|
void |
setVerbosity(IO.Verbosity verbosity)Set the verbosity level. |
Prefered error output writer.
Raw error output stream.
Prefered input reader.
Raw input stream.
Prefered output writer.
Raw output stream.
Construct a new IO container.
Construct a new IO container using system streams.
Close all streams.
Flush both output streams.
Returns the verbosity level.
Check if the verbosity level is set to Verbosity#DEBUG#DEBUG.
For general usage, when debug output is required, it is better to use the logging facility instead.
Check if the verbosity level is set to Verbosity#INFO#INFO.
Check if the verbosity level is set to Verbosity#QUIET#QUIET.
Check if the verbosity level is set to Verbosity#VERBOSE#VERBOSE.
Set the verbosity level.
Copyright © 2003-2017 The Apache Software Foundation. All rights reserved.