| 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 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 92 Future<int> length(); | 92 Future<int> length(); |
| 93 | 93 |
| 94 /** | 94 /** |
| 95 * Synchronously get the length of the file. | 95 * Synchronously get the length of the file. |
| 96 * | 96 * |
| 97 * Throws a [FileException] if the operation fails. | 97 * Throws a [FileException] if the operation fails. |
| 98 */ | 98 */ |
| 99 int lengthSync(); | 99 int lengthSync(); |
| 100 | 100 |
| 101 /** | 101 /** |
| 102 * Returns a [File] instance whose path is the absolute path to [this]. |
| 103 * |
| 104 * The absolute path is computed by prefixing |
| 105 * a relative path with the current working directory, and returning |
| 106 * an absolute path unchanged. |
| 107 */ |
| 108 File get absolute; |
| 109 |
| 110 /** |
| 102 * Get the last-modified time of the file. Returns a | 111 * Get the last-modified time of the file. Returns a |
| 103 * [:Future<DateTime>:] that completes with a [DateTime] object for the | 112 * [:Future<DateTime>:] that completes with a [DateTime] object for the |
| 104 * modification date. | 113 * modification date. |
| 105 */ | 114 */ |
| 106 Future<DateTime> lastModified(); | 115 Future<DateTime> lastModified(); |
| 107 | 116 |
| 108 /** | 117 /** |
| 109 * Get the last-modified time of the file. Throws an exception | 118 * Get the last-modified time of the file. Throws an exception |
| 110 * if the file does not exist. | 119 * if the file does not exist. |
| 111 * | 120 * |
| (...skipping 413 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 525 } | 534 } |
| 526 } else if (osError != null) { | 535 } else if (osError != null) { |
| 527 sb.write(": osError"); | 536 sb.write(": osError"); |
| 528 if (path != null) { | 537 if (path != null) { |
| 529 sb.write(", path = $path"); | 538 sb.write(", path = $path"); |
| 530 } | 539 } |
| 531 } | 540 } |
| 532 return sb.toString(); | 541 return sb.toString(); |
| 533 } | 542 } |
| 534 } | 543 } |
| OLD | NEW |