| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 _exit(int status) native "Exit"; | 5 _exit(int status) native "Exit"; |
| 6 | 6 |
| 7 class _ProcessStartStatus { | 7 class _ProcessStartStatus { |
| 8 int _errorCode; // Set to OS error code if process start failed. | 8 int _errorCode; // Set to OS error code if process start failed. |
| 9 String _errorMessage; // Set to OS error message if process start failed. | 9 String _errorMessage; // Set to OS error message if process start failed. |
| 10 } | 10 } |
| 11 | 11 |
| 12 | 12 |
| 13 class _Process extends Process { | 13 class _Process extends Process { |
| 14 static Process start(String path, | |
| 15 List<String> arguments, | |
| 16 [ProcessOptions options]) { | |
| 17 return new _Process.start(path, arguments, options); | |
| 18 } | |
| 19 | |
| 20 static Future<ProcessResult> run(String path, | 14 static Future<ProcessResult> run(String path, |
| 21 List<String> arguments, | 15 List<String> arguments, |
| 22 [ProcessOptions options]) { | 16 [ProcessOptions options]) { |
| 23 return new _NonInteractiveProcess._start(path, arguments, options)._result; | 17 return new _NonInteractiveProcess._start(path, arguments, options)._result; |
| 24 } | 18 } |
| 25 | 19 |
| 26 _Process.start(String path, | 20 _Process.start(String path, |
| 27 List<String> arguments, | 21 List<String> arguments, |
| 28 ProcessOptions options) { | 22 ProcessOptions options) { |
| 29 if (path is !String) { | 23 if (path is !String) { |
| (...skipping 362 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 392 | 386 |
| 393 class _ProcessResult implements ProcessResult { | 387 class _ProcessResult implements ProcessResult { |
| 394 const _ProcessResult(int this.exitCode, | 388 const _ProcessResult(int this.exitCode, |
| 395 String this.stdout, | 389 String this.stdout, |
| 396 String this.stderr); | 390 String this.stderr); |
| 397 | 391 |
| 398 final int exitCode; | 392 final int exitCode; |
| 399 final String stdout; | 393 final String stdout; |
| 400 final String stderr; | 394 final String stderr; |
| 401 } | 395 } |
| OLD | NEW |