W3cubDocs

/Dart 2

openRead method

Stream<List<int>> openRead ([int start, int end ])

Create a new independent Stream for the contents of this file.

If start is present, the file will be read from byte-offset start. Otherwise from the beginning (index 0).

If end is present, only up to byte-index end will be read. Otherwise, until end of file.

In order to make sure that system resources are freed, the stream must be read to completion or the subscription on the stream must be cancelled.

Implementation

Stream<List<int>> openRead([int start, int end]);

© 2012 the Dart project authors
Licensed under the Creative Commons Attribution-ShareAlike License v4.0.
https://api.dartlang.org/stable/2.0.0/dart-io/File/openRead.html