TerminalPtyLibrary class
TerminalPtyLibrary represents a process running in a pseudo-terminal.
To create a TerminalPtyLibrary, use TerminalPtyLibrary.start
.
- Inheritance
-
- Object
- TerminalPtyLibraryBase
- TerminalPtyLibrary
Constructors
-
TerminalPtyLibrary.new({String executable = "sh", String? workingDirectory, String? libraryPtyPath, List<
String> ? arguments, int columns = 80, Map? environment, bool isAckRead = false, int rows = 25}) - Spawns a process in a pseudo-terminal. The arguments have the same meaning as in Process.start. ackRead indicates if the pty should wait for a call to TerminalPtyLibrary.ackRead before sending the next data.
Properties
-
arguments
↔ List<
String> -
latefinalinherited
- columns → int
-
finalinherited
- environment → Map?
-
finalinherited
- event_emitter → EventEmitter
-
finalinherited
- event_input → String
-
finalinherited
- event_output → String
-
finalinherited
- executable → String
-
finalinherited
-
exit_code_completer
→ Completer<
int> -
final
- exit_receive_port → ReceivePort
-
final
-
exitCode
→ Future<
int> -
The output stream from the pseudo-terminal. Note that pseudo-terminals
A
Future
which completes with the exit code of the process when the process completes.no setteroverride - hashCode → int
-
The hash code for this object.
no setterinherited
- isAckRead → bool
-
finalinherited
- isInitialized ↔ bool
-
getter/setter pairinherited
- libraryPtyPath ↔ String
-
latefinalinherited
- pid → int
-
The process id of the process running in the pseudo-terminal.
no setteroverride
- rows → int
-
finalinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- stdout_receive_port → ReceivePort
-
final
- workingDirectory → String?
-
finalinherited
Methods
-
ackRead(
) → void -
indicates that a data chunk has been processed.
This is needed when ackRead is set to true as the pty will wait for this signal to happen
before any additional data is sent.
override
-
ensureInitialized(
) → void -
override
-
kill(
[ProcessSignal signal = ProcessSignal.sigterm]) → bool -
Kill the process running in the pseudo-terminal.
override
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
on(
{required String eventName, required FutureOr onCallback(dynamic update, TerminalPtyLibraryBase terminalPtyLibraryBase)}) → EventEmitterListener -
inherited
-
resize(
int rows, int cols) → void -
Resize the pseudo-terminal.
override
-
toString(
) → String -
A string representation of this object.
inherited
-
write(
Uint8List data) → void -
Write data to the pseudo-terminal.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Properties
- defaultShell → String
-
no setter
- dynamic_library_pty ↔ DynamicLibrary
-
latefinal
- is_dynamic_library_pty_initialized ↔ bool
-
getter/setter pair
- pty_library ↔ TerminalPtyBindings
-
latefinal
- pty_library_init ↔ int
-
latefinal
Static Methods
-
openLibrary(
{required String libraryPath}) → void