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

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

Issue 834233003: Fix for issue 21398 (only send "literal like" objects across isolates spawned using spawnURI (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 5 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 | « samples/sample_extension/sample_extension.cc ('k') | tests/isolate/isolate.status » ('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 class _Directory extends FileSystemEntity implements Directory { 7 class _Directory extends FileSystemEntity implements Directory {
8 final String path; 8 final String path;
9 9
10 _Directory(this.path) { 10 _Directory(this.path) {
(...skipping 268 matching lines...) Expand 10 before | Expand all | Expand 10 after
279 } 279 }
280 280
281 Stream get stream => controller.stream; 281 Stream get stream => controller.stream;
282 282
283 void onListen() { 283 void onListen() {
284 _IOService.dispatch(_DIRECTORY_LIST_START, [path, recursive, followLinks]) 284 _IOService.dispatch(_DIRECTORY_LIST_START, [path, recursive, followLinks])
285 .then((response) { 285 .then((response) {
286 if (response is int) { 286 if (response is int) {
287 id = response; 287 id = response;
288 next(); 288 next();
289 } else if (response is Error) {
290 controller.addError(response);
291 close();
289 } else { 292 } else {
290 error(response); 293 error(response);
291 close(); 294 close();
292 } 295 }
293 }); 296 });
294 } 297 }
295 298
296 void onResume() { 299 void onResume() {
297 if (!nextRunning) next(); 300 if (!nextRunning) next();
298 } 301 }
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
377 controller.addError( 380 controller.addError(
378 new FileSystemException("Directory listing failed", 381 new FileSystemException("Directory listing failed",
379 errorPath, 382 errorPath,
380 err)); 383 err));
381 } else { 384 } else {
382 controller.addError( 385 controller.addError(
383 new FileSystemException("Internal error")); 386 new FileSystemException("Internal error"));
384 } 387 }
385 } 388 }
386 } 389 }
OLDNEW
« no previous file with comments | « samples/sample_extension/sample_extension.cc ('k') | tests/isolate/isolate.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698