| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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; | 5 part of dart.io; |
| 6 | 6 |
| 7 /** | 7 /** |
| 8 * FileMode describes the modes in which a file can be opened. | 8 * FileMode describes the modes in which a file can be opened. |
| 9 */ | 9 */ |
| 10 class FileMode { | 10 class FileMode { |
| (...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 74 * instance for the renamed file. | 74 * instance for the renamed file. |
| 75 * | 75 * |
| 76 * If [newPath] identifies an existing file, that file is | 76 * If [newPath] identifies an existing file, that file is |
| 77 * replaced. If [newPath] identifies an existing directory the | 77 * replaced. If [newPath] identifies an existing directory the |
| 78 * operation fails and an exception is thrown. | 78 * operation fails and an exception is thrown. |
| 79 */ | 79 */ |
| 80 File renameSync(String newPath); | 80 File renameSync(String newPath); |
| 81 | 81 |
| 82 /** | 82 /** |
| 83 * Get a [Directory] object for the directory containing this | 83 * Get a [Directory] object for the directory containing this |
| 84 * file. | 84 * file. Deprecated: Replaced by [FileSystemEntity.parent]. |
| 85 * Will be removed on Oct 25, 2013. |
| 85 */ | 86 */ |
| 87 @deprecated |
| 86 Directory get directory; | 88 Directory get directory; |
| 87 | 89 |
| 88 /** | 90 /** |
| 89 * Get the length of the file. Returns a [:Future<int>:] that | 91 * Get the length of the file. Returns a [:Future<int>:] that |
| 90 * completes with the length in bytes. | 92 * completes with the length in bytes. |
| 91 */ | 93 */ |
| 92 Future<int> length(); | 94 Future<int> length(); |
| 93 | 95 |
| 94 /** | 96 /** |
| 95 * Synchronously get the length of the file. | 97 * Synchronously get the length of the file. |
| (...skipping 447 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 543 } | 545 } |
| 544 } else if (osError != null) { | 546 } else if (osError != null) { |
| 545 sb.write(": osError"); | 547 sb.write(": osError"); |
| 546 if (path != null) { | 548 if (path != null) { |
| 547 sb.write(", path = $path"); | 549 sb.write(", path = $path"); |
| 548 } | 550 } |
| 549 } | 551 } |
| 550 return sb.toString(); | 552 return sb.toString(); |
| 551 } | 553 } |
| 552 } | 554 } |
| OLD | NEW |