Class ExternalTerminal

All Implemented Interfaces:
Closeable, Flushable, AutoCloseable, TerminalExt, Terminal

public class ExternalTerminal extends LineDisciplineTerminal
Terminal implementation designed for external connections with embedded line discipline.

The ExternalTerminal class provides a terminal implementation that is well-suited for supporting incoming external connections, such as those from network sources (telnet, SSH, or other protocols). It extends the LineDisciplineTerminal class, inheriting its line discipline functionality while adding features specific to external connection handling.

This terminal implementation starts consuming input in a separate thread to generate interruption events promptly, ensuring that signals like Ctrl+C are processed immediately rather than waiting for the application to read the input. This is particularly important for network-based terminals where latency could otherwise affect the responsiveness of signal handling.

Key features of this implementation include:

  • Support for external connections over various protocols
  • Prompt signal handling through background input processing
  • Configurable terminal type and attributes
  • Support for dynamic size changes

This terminal is commonly used in server applications that need to provide terminal access to remote clients, such as SSH servers, telnet servers, or custom network protocols that require terminal emulation.

See Also: