Chromium Code Reviews| Index: sdk/lib/io/process.dart |
| diff --git a/sdk/lib/io/process.dart b/sdk/lib/io/process.dart |
| index 2d8ecab3bba56e1471548cbce7d1398f65e6c78f..7f05c4824b655cd31a42dd6ae59da3f81a914a60 100644 |
| --- a/sdk/lib/io/process.dart |
| +++ b/sdk/lib/io/process.dart |
| @@ -433,14 +433,14 @@ abstract class Process { |
| * [ProcessResult] represents the result of running a non-interactive |
| * process started with [:Process.run:]. |
|
Lasse Reichstein Nielsen
2015/04/07 12:38:44
[:Process.run:] -> [Process.run] or [Process.runSy
Søren Gjesse
2015/04/07 13:05:35
Done.
|
| */ |
| -abstract class ProcessResult { |
| +class ProcessResult { |
| /** |
| * Exit code for the process. |
| * |
| * See [Process.exitCode] for more information in the exit code |
| * value. |
| */ |
| - int get exitCode; |
| + final int exitCode; |
| /** |
| * Standard output from the process. The value used for the |
| @@ -448,7 +448,7 @@ abstract class ProcessResult { |
| * `null` was used this value is of type `List<int> otherwise it is |
| * of type `String`. |
|
Lasse Reichstein Nielsen
2015/04/07 12:38:45
Make ProcessResult generic with the type of this a
Søren Gjesse
2015/04/07 13:05:35
One can specify different encodings for stdout and
|
| */ |
| - get stdout; |
| + final stdout; |
| /** |
| * Standard error from the process. The value used for the |
| @@ -456,12 +456,24 @@ abstract class ProcessResult { |
| * `null` was used this value is of type `List<int> |
| * otherwise it is of type `String`. |
| */ |
| - get stderr; |
| + final stderr; |
| /** |
| * Process id from the process. |
|
Lasse Reichstein Nielsen
2015/04/07 12:38:44
Process id of the process
?
Søren Gjesse
2015/04/07 13:05:35
Done.
|
| */ |
| - int get pid; |
| + final int pid; |
| + |
| + /** |
| + * Construct an instance of [ProcessResult]. |
| + * |
| + * The main use of `ProcessResult is as return value from |
| + * `Process.run` and `Process.runSync`. However for some applications |
|
Lasse Reichstein Nielsen
2015/04/07 12:38:44
Comma after "however". Maybe rewrite to something
Søren Gjesse
2015/04/07 13:05:35
I removed the comment.
|
| + * constructing it directly might be useful. |
| + */ |
| + const ProcessResult(int this.pid, |
|
Lasse Reichstein Nielsen
2015/04/07 12:38:44
Remove the `const` if possible. It makes little-to
Søren Gjesse
2015/04/07 13:05:35
Done.
|
| + int this.exitCode, |
| + this.stdout, |
| + this.stderr); |
| } |