public interface

Terminal

jline.Terminal
Known Indirect Subclasses

Class Overview

Representation of the input terminal for a platform.

Summary

Public Methods
abstract int getHeight()
abstract String getOutputEncoding()
abstract int getWidth()
abstract boolean hasWeirdWrap()
For terminals that don't wrap when character is written in last column, only when the next character is written.
abstract void init()
abstract boolean isAnsiSupported()
abstract boolean isEchoEnabled()
abstract boolean isSupported()
abstract void reset()
abstract void restore()
abstract void setEchoEnabled(boolean enabled)
abstract InputStream wrapInIfNeeded(InputStream in)
When using native support, return the InputStream to use for reading characters else return the input stream passed as a parameter.
abstract OutputStream wrapOutIfNeeded(OutputStream out)
When ANSI is not natively handled, the output will have to be wrapped.

Public Methods

public abstract int getHeight ()

public abstract String getOutputEncoding ()

public abstract int getWidth ()

public abstract boolean hasWeirdWrap ()

For terminals that don't wrap when character is written in last column, only when the next character is written. These are the ones that have 'am' and 'xn' termcap attributes (xterm and rxvt flavors falls under that category)

public abstract void init ()

Throws
Exception

public abstract boolean isAnsiSupported ()

public abstract boolean isEchoEnabled ()

public abstract boolean isSupported ()

public abstract void reset ()

Throws
Exception

public abstract void restore ()

Throws
Exception

public abstract void setEchoEnabled (boolean enabled)

public abstract InputStream wrapInIfNeeded (InputStream in)

When using native support, return the InputStream to use for reading characters else return the input stream passed as a parameter.

Throws
IOException

public abstract OutputStream wrapOutIfNeeded (OutputStream out)

When ANSI is not natively handled, the output will have to be wrapped.