Class ShellConsole.JLineShellConsoleV2
- java.lang.Object
-
- org.htmlunit.corejs.javascript.tools.shell.ShellConsole
-
- org.htmlunit.corejs.javascript.tools.shell.ShellConsole.JLineShellConsoleV2
-
- Enclosing class:
- ShellConsole
private static class ShellConsole.JLineShellConsoleV2 extends ShellConsole
ShellConsole
implementation for JLine v2
-
-
Constructor Summary
Constructors Constructor Description JLineShellConsoleV2(java.lang.Object reader, java.nio.charset.Charset cs)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
flush()
Flushes the console's outputjava.io.InputStream
getIn()
Returns the underlyingInputStream
void
print(java.lang.String s)
Prints a single string to the consolevoid
println()
Prints the newline character-sequence to the consolevoid
println(java.lang.String s)
Prints a string and the newline character-sequence to the consolejava.lang.String
readLine()
Reads a single line from the consolejava.lang.String
readLine(java.lang.String prompt)
Reads a single line from the console and sets the console's prompt toprompt
-
Methods inherited from class org.htmlunit.corejs.javascript.tools.shell.ShellConsole
getConsole, getConsole
-
-
-
-
Method Detail
-
getIn
public java.io.InputStream getIn()
Description copied from class:ShellConsole
Returns the underlyingInputStream
- Specified by:
getIn
in classShellConsole
-
readLine
public java.lang.String readLine() throws java.io.IOException
Description copied from class:ShellConsole
Reads a single line from the console- Specified by:
readLine
in classShellConsole
- Throws:
java.io.IOException
-
readLine
public java.lang.String readLine(java.lang.String prompt) throws java.io.IOException
Description copied from class:ShellConsole
Reads a single line from the console and sets the console's prompt toprompt
- Specified by:
readLine
in classShellConsole
- Throws:
java.io.IOException
-
flush
public void flush() throws java.io.IOException
Description copied from class:ShellConsole
Flushes the console's output- Specified by:
flush
in classShellConsole
- Throws:
java.io.IOException
-
print
public void print(java.lang.String s) throws java.io.IOException
Description copied from class:ShellConsole
Prints a single string to the console- Specified by:
print
in classShellConsole
- Throws:
java.io.IOException
-
println
public void println() throws java.io.IOException
Description copied from class:ShellConsole
Prints the newline character-sequence to the console- Specified by:
println
in classShellConsole
- Throws:
java.io.IOException
-
println
public void println(java.lang.String s) throws java.io.IOException
Description copied from class:ShellConsole
Prints a string and the newline character-sequence to the console- Specified by:
println
in classShellConsole
- Throws:
java.io.IOException
-
-