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

Side by Side Diff: utils/pub/error_group.dart

Issue 12610006: Renamed StreamSink to EventSink. Renamed signalError to addError. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Changed inheritance back! Now create StreamSink instead of EventSink where we create them. Created 7 years, 9 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
OLDNEW
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 library error_group; 5 library error_group;
6 6
7 import 'dart:async'; 7 import 'dart:async';
8 8
9 import 'utils.dart'; 9 import 'utils.dart';
10 10
(...skipping 254 matching lines...) Expand 10 before | Expand all | Expand 10 after
265 } 265 }
266 266
267 /// Signal that an error from [_group] should be propagated through [this], 267 /// Signal that an error from [_group] should be propagated through [this],
268 /// unless it's already complete. 268 /// unless it's already complete.
269 void _signalError(AsyncError e) { 269 void _signalError(AsyncError e) {
270 if (_isDone) return; 270 if (_isDone) return;
271 _cancelled = true; 271 _cancelled = true;
272 _subscription.cancel(); 272 _subscription.cancel();
273 // Call these asynchronously to work around issue 7913. 273 // Call these asynchronously to work around issue 7913.
274 defer(() { 274 defer(() {
275 _controller.signalError(e.error, e.stackTrace); 275 _controller.addError(e.error, e.stackTrace);
276 _controller.close(); 276 _controller.close();
277 }); 277 });
278 } 278 }
279 } 279 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698