java.lang.Object
org.htmlunit.corejs.javascript.tools.shell.BasicConsole
- All Implemented Interfaces:
Closeable,AutoCloseable,Console
A simple console that always works because it only relies on standard input and output. Works in
the case of an interactive shell and also in a non-interactive context.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()voidflush()getErr()getOut()voidvoidprintln()voidreadLine()voidsetErr(PrintStream err) voidsetIn(InputStream in) voidsetOut(PrintStream out)
-
Constructor Details
-
BasicConsole
public BasicConsole()
-
-
Method Details
-
close
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Throws:
IOException
-
getImplementation
- Specified by:
getImplementationin interfaceConsole
-
readLine
- Specified by:
readLinein interfaceConsole- Throws:
IOException
-
readLine
- Specified by:
readLinein interfaceConsole- Throws:
IOException
-
print
-
println
-
println
public void println() -
flush
public void flush() -
setIn
-
setOut
-
getOut
-
setErr
-
getErr
-