|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.sonatype.gshell.command.IO
public class IO
Provides access to input/output handles.
| Nested Class Summary | |
|---|---|
static class |
IO.Verbosity
Defines the valid values of the IO containers verbosity settings. |
| Field Summary | |
|---|---|
PrintWriter |
err
Error output writer. |
Reader |
in
Input reader. |
PrintWriter |
out
Output writer. |
StreamSet |
streams
|
| Constructor Summary | |
|---|---|
IO()
Helper which uses current values from StreamSet.system(). |
|
IO(StreamSet streams,
boolean autoFlush)
|
|
IO(StreamSet streams,
Reader in,
PrintWriter out,
PrintWriter err,
boolean autoFlush)
|
|
| Method Summary | |
|---|---|
void |
close()
Close all streams. |
protected Reader |
createReader(InputStream in)
|
protected PrintWriter |
createWriter(PrintStream out,
boolean autoFlush)
|
void |
error(Object msg)
|
void |
error(String format,
Object... args)
|
void |
flush()
Flush both output streams. |
jline.Terminal |
getTerminal()
|
IO.Verbosity |
getVerbosity()
Returns the verbosity level. |
boolean |
isNormal()
|
boolean |
isQuiet()
|
boolean |
isSilent()
|
void |
println(Object msg)
|
void |
println(String format,
Object... args)
|
void |
setVerbosity(IO.Verbosity verbosity)
Set the verbosity level. |
void |
warn(Object msg)
|
void |
warn(String format,
Object... args)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public final StreamSet streams
public final Reader in
public final PrintWriter out
public final PrintWriter err
| Constructor Detail |
|---|
public IO(StreamSet streams,
boolean autoFlush)
public IO(StreamSet streams,
Reader in,
PrintWriter out,
PrintWriter err,
boolean autoFlush)
public IO()
StreamSet.system().
| Method Detail |
|---|
protected Reader createReader(InputStream in)
protected PrintWriter createWriter(PrintStream out,
boolean autoFlush)
public void flush()
public void close()
throws IOException
IOExceptionpublic jline.Terminal getTerminal()
public void setVerbosity(IO.Verbosity verbosity)
public IO.Verbosity getVerbosity()
public boolean isNormal()
public boolean isQuiet()
public boolean isSilent()
public void println(Object msg)
public void println(String format,
Object... args)
public void warn(Object msg)
public void warn(String format,
Object... args)
public void error(Object msg)
public void error(String format,
Object... args)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||