| 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 part of dart.io; | |
| 6 | |
| 7 /** | 5 /** |
| 8 * Basic input stream which supplies binary data. | 6 * Basic input stream which supplies binary data. |
| 9 * | 7 * |
| 10 * Input streams are used to read data sequentially from some data | 8 * Input streams are used to read data sequentially from some data |
| 11 * source. All input streams are non-blocking. They each have a number | 9 * source. All input streams are non-blocking. They each have a number |
| 12 * of read calls which will always return without any IO related | 10 * of read calls which will always return without any IO related |
| 13 * blocking. If the requested data is not available a read call will | 11 * blocking. If the requested data is not available a read call will |
| 14 * return `null`. All input streams have one or more handlers which | 12 * return `null`. All input streams have one or more handlers which |
| 15 * will trigger when data is available. | 13 * will trigger when data is available. |
| 16 * | 14 * |
| (...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 249 void set onError(void callback(e)); | 247 void set onError(void callback(e)); |
| 250 } | 248 } |
| 251 | 249 |
| 252 | 250 |
| 253 class StreamException implements Exception { | 251 class StreamException implements Exception { |
| 254 const StreamException([String this.message = ""]); | 252 const StreamException([String this.message = ""]); |
| 255 const StreamException.streamClosed() : message = "Stream closed"; | 253 const StreamException.streamClosed() : message = "Stream closed"; |
| 256 String toString() => "StreamException: $message"; | 254 String toString() => "StreamException: $message"; |
| 257 final String message; | 255 final String message; |
| 258 } | 256 } |
| OLD | NEW |