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

Unified Diff: lib/src/stream_channel_controller.dart

Issue 1671763002: Make IsolateChannel use StreamChannelCompleter. (Closed) Base URL: git@github.com:dart-lang/stream_channel.git@master
Patch Set: Created 4 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « lib/src/isolate_channel/send_port_sink.dart ('k') | test/with_guarantees_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/src/stream_channel_controller.dart
diff --git a/lib/src/stream_channel_controller.dart b/lib/src/stream_channel_controller.dart
index ad78323effb2e9402614553ca5c6da42a6f04ac3..45b2865ed3a495a74e50ae6c04963d1d599df87f 100644
--- a/lib/src/stream_channel_controller.dart
+++ b/lib/src/stream_channel_controller.dart
@@ -15,13 +15,13 @@ import '../stream_channel.dart';
///
/// ```dart
/// StreamChannel isolateChannel(ReceivePort receivePort, SendPort sendPort) {
-/// var controller = new StreamChannelController();
+/// var controller = new StreamChannelController(allowForeignErrors: false);
///
/// // Pipe all events from the receive port into the local sink...
/// receivePort.pipe(controller.local.sink);
///
/// // ...and all events from the local stream into the send port.
-/// controller.local.listen(sendPort.add, onDone: receivePort.close);
+/// controller.local.stream.listen(sendPort.send, onDone: receivePort.close);
///
/// // Then return the foreign controller for your users to use.
/// return controller.foreign;
« no previous file with comments | « lib/src/isolate_channel/send_port_sink.dart ('k') | test/with_guarantees_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698