Class JansiWinSysTerminal
java.lang.Object
org.jline.terminal.impl.AbstractTerminal
org.jline.terminal.impl.AbstractWindowsTerminal<Long>
org.jline.terminal.impl.jansi.win.JansiWinSysTerminal
- All Implemented Interfaces:
Closeable
,Flushable
,AutoCloseable
,TerminalExt
,Terminal
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.jline.terminal.Terminal
Terminal.MouseTracking, Terminal.Signal, Terminal.SignalHandler
-
Field Summary
Fields inherited from class org.jline.terminal.impl.AbstractWindowsTerminal
attributes, closer, ENABLE_ECHO_INPUT, ENABLE_INSERT_MODE, ENABLE_LINE_INPUT, ENABLE_MOUSE_INPUT, ENABLE_PROCESSED_INPUT, ENABLE_QUICK_EDIT_MODE, ENABLE_VIRTUAL_TERMINAL_PROCESSING, ENABLE_WINDOW_INPUT, focusTracking, inConsole, input, lock, nativeHandlers, originalInConsoleMode, originalOutConsoleMode, outConsole, output, paused, pump, reader, skipNextLf, slaveInputPipe, tracking, TYPE_WINDOWS, TYPE_WINDOWS_256_COLOR, TYPE_WINDOWS_CONEMU, TYPE_WINDOWS_VTP, writer
Fields inherited from class org.jline.terminal.impl.AbstractTerminal
bools, encoding, handlers, ints, name, onClose, palette, status, strings, type
Fields inherited from interface org.jline.terminal.Terminal
TYPE_DUMB, TYPE_DUMB_COLOR
-
Method Summary
Modifier and TypeMethodDescriptionstatic JansiWinSysTerminal
createTerminal
(TerminalProvider provider, SystemStream systemStream, String name, String type, boolean ansiPassThrough, Charset encoding, boolean nativeSignals, Terminal.SignalHandler signalHandler, boolean paused) void
Retrieve the size of the window buffer.static long
getConsole
(SystemStream systemStream) protected int
getConsoleMode
(Long console) getCursorPosition
(IntConsumer discarded) Query the terminal to report the cursor position.getSize()
Retrieve the size of the visible windowstatic boolean
isWindowsSystemStream
(SystemStream stream) protected boolean
Read a single input event from the input buffer and process it.protected void
setConsoleMode
(Long console, int mode) Methods inherited from class org.jline.terminal.impl.AbstractWindowsTerminal
canPauseResume, ctrl, doClose, getAttributes, getEscapeSequence, getProvider, getRawSequence, getSystemStream, handle, hasFocusSupport, input, output, pause, pause, paused, processInputChar, processKeyEvent, pump, reader, resume, setAttributes, setSize, trackFocus, trackMouse, updateConsoleMode, writer
Methods inherited from class org.jline.terminal.impl.AbstractTerminal
checkInterrupted, close, echo, echo, echoSignal, encoding, enterRawMode, flush, getBooleanCapability, getKind, getName, getNumericCapability, getPalette, getStatus, getStatus, getStringCapability, getType, hasMouseSupport, parseInfoCmp, puts, raise, readMouseEvent, readMouseEvent, setOnClose
-
Method Details
-
createTerminal
public static JansiWinSysTerminal createTerminal(TerminalProvider provider, SystemStream systemStream, String name, String type, boolean ansiPassThrough, Charset encoding, boolean nativeSignals, Terminal.SignalHandler signalHandler, boolean paused) throws IOException - Throws:
IOException
-
getConsole
-
isWindowsSystemStream
-
getConsoleMode
- Specified by:
getConsoleMode
in classAbstractWindowsTerminal<Long>
-
setConsoleMode
- Specified by:
setConsoleMode
in classAbstractWindowsTerminal<Long>
-
getSize
Description copied from interface:Terminal
Retrieve the size of the visible window- Returns:
- the visible terminal size
- See Also:
-
getBufferSize
Description copied from interface:Terminal
Retrieve the size of the window buffer. Some terminals can be configured to have a buffer size larger than the visible window size and provide scroll bars. In such cases, this method should attempt to return the size of the whole buffer. ThegetBufferSize()
method can be used to avoid wrapping when using the terminal in a line editing mode, while theTerminal.getSize()
method should be used when using full screen mode.- Returns:
- the terminal buffer size
- See Also:
-
processConsoleInput
Description copied from class:AbstractWindowsTerminal
Read a single input event from the input buffer and process it.- Specified by:
processConsoleInput
in classAbstractWindowsTerminal<Long>
- Returns:
- true if new input was generated from the event
- Throws:
IOException
- if anything wrong happens
-
getCursorPosition
Description copied from interface:Terminal
Query the terminal to report the cursor position. As the response is read from the input stream, some characters may be read before the cursor position is actually read. Those characters can be given back usingorg.jline.keymap.BindingReader#runMacro(String)
- Specified by:
getCursorPosition
in interfaceTerminal
- Overrides:
getCursorPosition
in classAbstractTerminal
- Parameters:
discarded
- a consumer receiving discarded characters- Returns:
null
if cursor position reporting is not supported or a valid cursor position
-
disableScrolling
public void disableScrolling()
-