commit | 3b1ee7b6abf6ce80877421067360ce7ed64eccb0 | [log] [tgz] |
---|---|---|
author | Lasse Reichstein Holst Nielsen <lrn@google.com> | Mon Feb 06 11:10:28 2017 +0100 |
committer | Lasse Reichstein Holst Nielsen <lrn@google.com> | Mon Feb 06 11:10:28 2017 +0100 |
tree | ba89882718953591ce35367b32448a8e00c35a34 | |
parent | 15728b5ef6b978848e211a90b9db54c8aa67cc34 [diff] |
Fix bug in readAsString when charset is LATIN-1 and content-length is set. BUG= https://github.com/dart-lang/resource/issues/21 R=floitsch@google.com Review-Url: https://codereview.chromium.org//2671243002 .
Reading data from package contents and files.
A resource is data that can be read into a Dart program at runtime. A resource is identified by a URI. It can be loaded as bytes or data. The resource URI may be a package: URI.
Example:
import 'package:resource/resource.dart' show Resource; import 'dart:convert' show UTF8; main() async { var resource = new Resource("package:foo/foo_data.txt"); var string = await resource.readAsString(encoding: UTF8); print(string); }
Please check out the API docs.
Please file feature requests and bugs at the issue tracker.