Shell constructor

const Shell({
  1. @Deprecated("Will be removed in the next major version.") String? name,
  2. required String program,
  3. required List<String> arguments,
  4. ProcessInterfaceOptions options = const ProcessInterfaceOptions(),
  5. FutureOr<void> onStdout(
    1. FlowContext context,
    2. List<int> chars
    )?,
  6. FutureOr<void> onStderr(
    1. FlowContext context,
    2. List<int> chars
    )?,
  7. @Deprecated("Will be removed in the next major version. " "Switch over to Shell.options to specify if the program should be run as admin.") bool? runAsAdministrator,
  8. @Deprecated("Will be removed in the next major version. " "Switch over to Shell.options to specify if the program should be run in shell.") bool? runInShell,
  9. @Deprecated("Will be removed in the next major version. " "Switch over to Shell.options to specify the working directory.") String? workingDirectory,
})

Default const constructor.

The default values of runAsAdministrator and runInShell are false.

Implementation

const Shell({
  @Deprecated("Will be removed in the next major version.") this.name,
  required this.program,
  required this.arguments,
  this.options = const ProcessInterfaceOptions(),
  this.onStdout,
  this.onStderr,
  @Deprecated("Will be removed in the next major version. "
      "Switch over to Shell.options to specify if the program should be run as admin.")
  this.runAsAdministrator,
  @Deprecated("Will be removed in the next major version. "
      "Switch over to Shell.options to specify if the program should be run in shell.")
  this.runInShell,
  @Deprecated("Will be removed in the next major version. "
      "Switch over to Shell.options to specify the working directory.")
  this.workingDirectory,
});