Class AbstractPty

java.lang.Object
org.jline.terminal.impl.AbstractPty
All Implemented Interfaces:
Closeable, AutoCloseable, Pty
Direct Known Subclasses:
ExecPty, JniNativePty

public abstract class AbstractPty extends Object implements Pty
Base implementation of the Pty interface.

The AbstractPty class provides a common foundation for pseudoterminal (PTY) implementations. It handles common functionality such as system stream management and provider access, while leaving platform-specific PTY operations to be implemented by concrete subclasses.

This class serves as the base for various PTY implementations, including:

  • Native PTY implementations (JNI, JNA, FFM) for direct access to system PTYs
  • Exec PTY implementation that uses external commands

The AbstractPty maintains information about the associated system stream and terminal provider, which are common to all PTY implementations regardless of the underlying mechanism used to interact with the terminal.

See Also: