jline
Class TerminalSupport
java.lang.Object
jline.TerminalSupport
- All Implemented Interfaces:
- Terminal
- Direct Known Subclasses:
- UnixTerminal, UnsupportedTerminal, WindowsTerminal
public abstract class TerminalSupport
- extends Object
- implements Terminal
Provides support for Terminal
instances.
- Since:
- 2.0
- Author:
- Jason Dillon
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DEFAULT_KEYBINDINGS_PROPERTIES
public static String DEFAULT_KEYBINDINGS_PROPERTIES
DEFAULT_WIDTH
public static final int DEFAULT_WIDTH
- See Also:
- Constant Field Values
DEFAULT_HEIGHT
public static final int DEFAULT_HEIGHT
- See Also:
- Constant Field Values
TerminalSupport
protected TerminalSupport(boolean supported)
init
public void init()
throws Exception
- Specified by:
init
in interface Terminal
- Throws:
Exception
restore
public void restore()
throws Exception
- Specified by:
restore
in interface Terminal
- Throws:
Exception
reset
public void reset()
throws Exception
- Specified by:
reset
in interface Terminal
- Throws:
Exception
installShutdownHook
protected void installShutdownHook(Thread hook)
removeShutdownHook
protected void removeShutdownHook()
isSupported
public final boolean isSupported()
- Specified by:
isSupported
in interface Terminal
isAnsiSupported
public boolean isAnsiSupported()
- Specified by:
isAnsiSupported
in interface Terminal
setAnsiSupported
protected void setAnsiSupported(boolean supported)
getWidth
public int getWidth()
- Specified by:
getWidth
in interface Terminal
getHeight
public int getHeight()
- Specified by:
getHeight
in interface Terminal
isEchoEnabled
public boolean isEchoEnabled()
- Specified by:
isEchoEnabled
in interface Terminal
setEchoEnabled
public void setEchoEnabled(boolean enabled)
- Specified by:
setEchoEnabled
in interface Terminal
readCharacter
public int readCharacter(InputStream in)
throws IOException
- Specified by:
readCharacter
in interface Terminal
- Throws:
IOException
readVirtualKey
public int readVirtualKey(InputStream in)
throws IOException
- Specified by:
readVirtualKey
in interface Terminal
- Throws:
IOException
getDefaultBindings
public InputStream getDefaultBindings()
- Specified by:
getDefaultBindings
in interface Terminal
Copyright © 2008-2011 Sonatype. All Rights Reserved.