| 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 patch class _FileUtils { | 5 patch class _FileUtils { |
| 6 /* patch */ static SendPort _newServicePort() native "File_NewServicePort"; | 6 /* patch */ static SendPort _newServicePort() native "File_NewServicePort"; |
| 7 } | 7 } |
| 8 | 8 |
| 9 patch class _File { | 9 patch class _File { |
| 10 /* patch */ static _exists(String path) native "File_Exists"; | 10 /* patch */ static _exists(String path) native "File_Exists"; |
| (...skipping 17 matching lines...) Expand all Loading... |
| 28 /* patch */ static _writeList(int id, List<int> buffer, int offset, int bytes) | 28 /* patch */ static _writeList(int id, List<int> buffer, int offset, int bytes) |
| 29 native "File_WriteList"; | 29 native "File_WriteList"; |
| 30 /* patch */ static _position(int id) native "File_Position"; | 30 /* patch */ static _position(int id) native "File_Position"; |
| 31 /* patch */ static _setPosition(int id, int position) | 31 /* patch */ static _setPosition(int id, int position) |
| 32 native "File_SetPosition"; | 32 native "File_SetPosition"; |
| 33 /* patch */ static _truncate(int id, int length) native "File_Truncate"; | 33 /* patch */ static _truncate(int id, int length) native "File_Truncate"; |
| 34 /* patch */ static _length(int id) native "File_Length"; | 34 /* patch */ static _length(int id) native "File_Length"; |
| 35 /* patch */ static _flush(int id) native "File_Flush"; | 35 /* patch */ static _flush(int id) native "File_Flush"; |
| 36 } | 36 } |
| 37 | 37 |
| 38 List<int> _makeUint8ListView(List<int> source, int from, int to) { | 38 Uint8List _makeUint8ListView(Uint8List source, int offsetInBytes, int length) { |
| 39 return new Uint8List.view(source.asByteArray(), from, to); | 39 return new Uint8List.view(source.buffer, offsetInBytes, length); |
| 40 } | 40 } |
| OLD | NEW |