| OLD | NEW |
| 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2011, 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 interface Directory factory _Directory { | 5 interface Directory factory _Directory { |
| 6 /** | 6 /** |
| 7 * Creates a directory object. The path is either a full path or | 7 * Creates a directory object. The path is either a full path or |
| 8 * relative to the directory in which the Dart VM was | 8 * relative to the directory in which the Dart VM was |
| 9 * started. | 9 * started. |
| 10 */ | 10 */ |
| (...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 52 void setFileHandler(void fileHandler(String file)); | 52 void setFileHandler(void fileHandler(String file)); |
| 53 | 53 |
| 54 /** | 54 /** |
| 55 * Set the done handler that is called when a directory listing is | 55 * Set the done handler that is called when a directory listing is |
| 56 * done. The handler is called with an indication of whether or not | 56 * done. The handler is called with an indication of whether or not |
| 57 * the listing operation completed. | 57 * the listing operation completed. |
| 58 */ | 58 */ |
| 59 void setDoneHandler(void doneHandler(bool completed)); | 59 void setDoneHandler(void doneHandler(bool completed)); |
| 60 | 60 |
| 61 /** | 61 /** |
| 62 * Sets the error handler that is called on errors listing | 62 * Sets the error handler that is called on error listing |
| 63 * directories. | 63 * directories. |
| 64 */ | 64 */ |
| 65 void setErrorHandler(void errorHandler(String error)); | 65 void setErrorHandler(void errorHandler(String error)); |
| 66 | 66 |
| 67 /** | 67 /** |
| 68 * Gets the path of this directory. | 68 * Gets the path of this directory. |
| 69 */ | 69 */ |
| 70 final String path; | 70 final String path; |
| 71 } | 71 } |
| 72 |
| 73 |
| 74 class DirectoryException { |
| 75 const DirectoryException(String this.message); |
| 76 String toString() => "DirectoryException: $message"; |
| 77 final String message; |
| 78 } |
| OLD | NEW |