Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(246)

Side by Side Diff: sdk/lib/io/directory.dart

Issue 11748017: Add synchronous directory listing to dart:io Directory. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address comments, move tests that fail on Windows due to VM bug 7157 to a separate test file. Created 7 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « runtime/bin/directory_patch.dart ('k') | sdk/lib/io/directory_impl.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 part of dart.io; 5 part of dart.io;
6 6
7 /** 7 /**
8 * [Directory] objects are used for working with directories. 8 * [Directory] objects are used for working with directories.
9 */ 9 */
10 abstract class Directory { 10 abstract class Directory {
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after
133 /** 133 /**
134 * List the sub-directories and files of this 134 * List the sub-directories and files of this
135 * [Directory]. Optionally recurse into sub-directories. Returns a 135 * [Directory]. Optionally recurse into sub-directories. Returns a
136 * [DirectoryLister] object representing the active listing 136 * [DirectoryLister] object representing the active listing
137 * operation. Handlers for files and directories should be 137 * operation. Handlers for files and directories should be
138 * registered on this DirectoryLister object. 138 * registered on this DirectoryLister object.
139 */ 139 */
140 DirectoryLister list({bool recursive: false}); 140 DirectoryLister list({bool recursive: false});
141 141
142 /** 142 /**
143 * List the sub-directories and files of this
144 * [Directory]. Optionally recurse into sub-directories. Returns a
145 * List containing Directory and File objects.
146 */
147 List listSync({bool recursive: false});
148
149 /**
143 * Returns a human readable string for this Directory instance. 150 * Returns a human readable string for this Directory instance.
144 */ 151 */
145 String toString(); 152 String toString();
146 153
147 /** 154 /**
148 * Gets the path of this directory. 155 * Gets the path of this directory.
149 */ 156 */
150 final String path; 157 final String path;
151 } 158 }
152 159
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
214 if (path != null) { 221 if (path != null) {
215 sb.add(", path = $path"); 222 sb.add(", path = $path");
216 } 223 }
217 } 224 }
218 return sb.toString(); 225 return sb.toString();
219 } 226 }
220 final String message; 227 final String message;
221 final String path; 228 final String path;
222 final OSError osError; 229 final OSError osError;
223 } 230 }
OLDNEW
« no previous file with comments | « runtime/bin/directory_patch.dart ('k') | sdk/lib/io/directory_impl.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698