| 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 _File { | 5 patch class _File { |
| 6 /* patch */ static _exists(String path) native "File_Exists"; | 6 /* patch */ static _exists(String path) native "File_Exists"; |
| 7 /* patch */ static _create(String path) native "File_Create"; | 7 /* patch */ static _create(String path) native "File_Create"; |
| 8 /* patch */ static _createLink(String path, String target) | 8 /* patch */ static _createLink(String path, String target) |
| 9 native "File_CreateLink"; | 9 native "File_CreateLink"; |
| 10 /* patch */ static _linkTarget(String path) native "File_LinkTarget"; | 10 /* patch */ static _linkTarget(String path) native "File_LinkTarget"; |
| 11 /* patch */ static _deleteNative(String path) native "File_Delete"; | 11 /* patch */ static _deleteNative(String path) native "File_Delete"; |
| 12 /* patch */ static _deleteLinkNative(String path) native "File_DeleteLink"; | 12 /* patch */ static _deleteLinkNative(String path) native "File_DeleteLink"; |
| 13 /* patch */ static _rename(String oldPath, String newPath) | 13 /* patch */ static _rename(String oldPath, String newPath) |
| 14 native "File_Rename"; | 14 native "File_Rename"; |
| 15 /* patch */ static _renameLink(String oldPath, String newPath) | 15 /* patch */ static _renameLink(String oldPath, String newPath) |
| 16 native "File_RenameLink"; | 16 native "File_RenameLink"; |
| 17 /* patch */ static _copy(String oldPath, String newPath) native "File_Copy"; | 17 /* patch */ static _copy(String oldPath, String newPath) native "File_Copy"; |
| 18 /* patch */ static _lengthFromPath(String path) native "File_LengthFromPath"; | 18 /* patch */ static _lengthFromPath(String path) native "File_LengthFromPath"; |
| 19 /* patch */ static _lastModified(String path) native "File_LastModified"; | 19 /* patch */ static _lastModified(String path) native "File_LastModified"; |
| 20 /* patch */ static _open(String path, int mode) native "File_Open"; | 20 /* patch */ static _open(String path, int mode) native "File_Open"; |
| 21 /* patch */ static int _openStdio(int fd) native "File_OpenStdio"; | 21 /* patch */ static int _openStdio(int fd) native "File_OpenStdio"; |
| 22 } | 22 } |
| 23 | 23 |
| 24 | 24 |
| 25 patch class _RandomAccessFile { | 25 patch class _RandomAccessFile { |
| 26 /* patch */ static int _close(int id) native "File_Close"; | 26 /* patch */ static int _close(int id) native "File_Close"; |
| 27 /* patch */ static int _getFD(int id) native "File_GetFD"; |
| 27 /* patch */ static _readByte(int id) native "File_ReadByte"; | 28 /* patch */ static _readByte(int id) native "File_ReadByte"; |
| 28 /* patch */ static _read(int id, int bytes) native "File_Read"; | 29 /* patch */ static _read(int id, int bytes) native "File_Read"; |
| 29 /* patch */ static _readInto(int id, List<int> buffer, int start, int end) | 30 /* patch */ static _readInto(int id, List<int> buffer, int start, int end) |
| 30 native "File_ReadInto"; | 31 native "File_ReadInto"; |
| 31 /* patch */ static _writeByte(int id, int value) native "File_WriteByte"; | 32 /* patch */ static _writeByte(int id, int value) native "File_WriteByte"; |
| 32 /* patch */ static _writeFrom(int id, List<int> buffer, int start, int end) | 33 /* patch */ static _writeFrom(int id, List<int> buffer, int start, int end) |
| 33 native "File_WriteFrom"; | 34 native "File_WriteFrom"; |
| 34 /* patch */ static _position(int id) native "File_Position"; | 35 /* patch */ static _position(int id) native "File_Position"; |
| 35 /* patch */ static _setPosition(int id, int position) | 36 /* patch */ static _setPosition(int id, int position) |
| 36 native "File_SetPosition"; | 37 native "File_SetPosition"; |
| (...skipping 321 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 358 void _pathWatchedEnd() { | 359 void _pathWatchedEnd() { |
| 359 _subscription.cancel(); | 360 _subscription.cancel(); |
| 360 _controller.close(); | 361 _controller.close(); |
| 361 } | 362 } |
| 362 } | 363 } |
| 363 | 364 |
| 364 | 365 |
| 365 Uint8List _makeUint8ListView(Uint8List source, int offsetInBytes, int length) { | 366 Uint8List _makeUint8ListView(Uint8List source, int offsetInBytes, int length) { |
| 366 return new Uint8List.view(source.buffer, offsetInBytes, length); | 367 return new Uint8List.view(source.buffer, offsetInBytes, length); |
| 367 } | 368 } |
| OLD | NEW |