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

Side by Side Diff: runtime/bin/directory.dart

Issue 11238035: Make isEmpty a getter. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Update status file with co19 issue number. Created 8 years, 1 month 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/common.dart ('k') | runtime/bin/file.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 /** 5 /**
6 * [Directory] objects are used for working with directories. 6 * [Directory] objects are used for working with directories.
7 */ 7 */
8 abstract class Directory { 8 abstract class Directory {
9 /** 9 /**
10 * Creates a directory object. The path is either an absolute path, 10 * Creates a directory object. The path is either an absolute path,
(...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after
175 } 175 }
176 176
177 177
178 class DirectoryIOException implements Exception { 178 class DirectoryIOException implements Exception {
179 const DirectoryIOException([String this.message = "", 179 const DirectoryIOException([String this.message = "",
180 String this.path = "", 180 String this.path = "",
181 OSError this.osError = null]); 181 OSError this.osError = null]);
182 String toString() { 182 String toString() {
183 StringBuffer sb = new StringBuffer(); 183 StringBuffer sb = new StringBuffer();
184 sb.add("DirectoryIOException"); 184 sb.add("DirectoryIOException");
185 if (!message.isEmpty()) { 185 if (!message.isEmpty) {
186 sb.add(": $message"); 186 sb.add(": $message");
187 if (path != null) { 187 if (path != null) {
188 sb.add(", path = $path"); 188 sb.add(", path = $path");
189 } 189 }
190 if (osError != null) { 190 if (osError != null) {
191 sb.add(" ($osError)"); 191 sb.add(" ($osError)");
192 } 192 }
193 } else if (osError != null) { 193 } else if (osError != null) {
194 sb.add(": $osError"); 194 sb.add(": $osError");
195 if (path != null) { 195 if (path != null) {
196 sb.add(", path = $path"); 196 sb.add(", path = $path");
197 } 197 }
198 } 198 }
199 return sb.toString(); 199 return sb.toString();
200 } 200 }
201 final String message; 201 final String message;
202 final String path; 202 final String path;
203 final OSError osError; 203 final OSError osError;
204 } 204 }
OLDNEW
« no previous file with comments | « runtime/bin/common.dart ('k') | runtime/bin/file.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698