Package org.aesh.terminal.tty.impl
Interface Pty
- All Superinterfaces:
AutoCloseable,Closeable
Represents a pseudo-terminal (PTY) providing master/slave input and output streams.
A PTY allows a program to interact with a terminal device, providing both
the master side (for the controlling process) and the slave side (for the terminal).
-
Method Summary
Modifier and TypeMethodDescriptiongetAttr()Returns the current terminal attributes.Returns the master side input stream.Returns the master side output stream.getSize()Returns the current terminal size.Returns the slave side input stream.Returns the slave side output stream.voidsetAttr(Attributes attr) Sets the terminal attributes.
-
Method Details
-
getMasterInput
Returns the master side input stream.- Returns:
- the master input stream
- Throws:
IOException- if an I/O error occurs
-
getMasterOutput
Returns the master side output stream.- Returns:
- the master output stream
- Throws:
IOException- if an I/O error occurs
-
getSlaveInput
Returns the slave side input stream.- Returns:
- the slave input stream
- Throws:
IOException- if an I/O error occurs
-
getSlaveOutput
Returns the slave side output stream.- Returns:
- the slave output stream
- Throws:
IOException- if an I/O error occurs
-
getAttr
Returns the current terminal attributes.- Returns:
- the terminal attributes
- Throws:
IOException- if an I/O error occurs
-
setAttr
Sets the terminal attributes.- Parameters:
attr- the attributes to set- Throws:
IOException- if an I/O error occurs
-
getSize
Returns the current terminal size.- Returns:
- the terminal size
- Throws:
IOException- if an I/O error occurs
-