PrivCommandEvent class sealed
A single event emitted while consuming a command as a stream.
PrivCommandExit is always the last event of a stream, emitted after both
output streams have reached EOF.
- Available extensions
- Annotations
-
- @freezed
Constructors
- PrivCommandEvent.exit({required int exitCode})
-
The final event, emitted after both output streams reach EOF.
constfactory
- PrivCommandEvent.stderr({required Uint8List bytes})
-
A chunk read from standard error.
constfactory
- PrivCommandEvent.stdout({required Uint8List bytes})
-
A chunk read from standard output.
constfactory
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
map<
TResult extends Object?> ({required TResult stdout(PrivCommandStdout value), required TResult stderr(PrivCommandStderr value), required TResult exit(PrivCommandExit value)}) → TResult -
Available on PrivCommandEvent, provided by the PrivCommandEventPatterns extension
Aswitch-like method, using callbacks. -
mapOrNull<
TResult extends Object?> ({TResult? stdout(PrivCommandStdout value)?, TResult? stderr(PrivCommandStderr value)?, TResult? exit(PrivCommandExit value)?}) → TResult? -
Available on PrivCommandEvent, provided by the PrivCommandEventPatterns extension
A variant ofmapthat fallback to returningnull. -
maybeMap<
TResult extends Object?> ({TResult stdout(PrivCommandStdout value)?, TResult stderr(PrivCommandStderr value)?, TResult exit(PrivCommandExit value)?, required TResult orElse()}) → TResult -
Available on PrivCommandEvent, provided by the PrivCommandEventPatterns extension
A variant ofmapthat fallback to returningorElse. -
maybeWhen<
TResult extends Object?> ({TResult stdout(Uint8List bytes)?, TResult stderr(Uint8List bytes)?, TResult exit(int exitCode)?, required TResult orElse()}) → TResult -
Available on PrivCommandEvent, provided by the PrivCommandEventPatterns extension
A variant ofwhenthat fallback to anorElsecallback. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
-
when<
TResult extends Object?> ({required TResult stdout(Uint8List bytes), required TResult stderr(Uint8List bytes), required TResult exit(int exitCode)}) → TResult -
Available on PrivCommandEvent, provided by the PrivCommandEventPatterns extension
Aswitch-like method, using callbacks. -
whenOrNull<
TResult extends Object?> ({TResult? stdout(Uint8List bytes)?, TResult? stderr(Uint8List bytes)?, TResult? exit(int exitCode)?}) → TResult? -
Available on PrivCommandEvent, provided by the PrivCommandEventPatterns extension
A variant ofwhenthat fallback to returningnull
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited