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

Side by Side Diff: lib/src/stream_sink_transformer.dart

Issue 1777453002: Modernize the package's style. (Closed) Base URL: git@github.com:dart-lang/async.git@master
Patch Set: Code review changes Created 4 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
OLDNEW
1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2016, 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 async.stream_sink_transformer;
6
7 import 'dart:async'; 5 import 'dart:async';
8 6
9 import 'stream_sink_transformer/handler_transformer.dart'; 7 import 'stream_sink_transformer/handler_transformer.dart';
10 import 'stream_sink_transformer/stream_transformer_wrapper.dart'; 8 import 'stream_sink_transformer/stream_transformer_wrapper.dart';
11 9
12 /// A [StreamSinkTransformer] transforms the events being passed to a sink. 10 /// A [StreamSinkTransformer] transforms the events being passed to a sink.
13 /// 11 ///
14 /// This works on the same principle as a [StreamTransformer]. Each transformer 12 /// This works on the same principle as a [StreamTransformer]. Each transformer
15 /// defines a [bind] method that takes in the original [StreamSink] and returns 13 /// defines a [bind] method that takes in the original [StreamSink] and returns
16 /// the transformed version. However, where a [StreamTransformer] transforms 14 /// the transformed version. However, where a [StreamTransformer] transforms
(...skipping 24 matching lines...) Expand all
41 void handleDone(EventSink<T> sink)}) { 39 void handleDone(EventSink<T> sink)}) {
42 return new HandlerTransformer<S, T>(handleData, handleError, handleDone); 40 return new HandlerTransformer<S, T>(handleData, handleError, handleDone);
43 } 41 }
44 42
45 /// Transforms the events passed to [sink]. 43 /// Transforms the events passed to [sink].
46 /// 44 ///
47 /// Creates a new sink. When events are passed to the returned sink, it will 45 /// Creates a new sink. When events are passed to the returned sink, it will
48 /// transform them and pass the transformed versions to [sink]. 46 /// transform them and pass the transformed versions to [sink].
49 StreamSink<S> bind(StreamSink<T> sink); 47 StreamSink<S> bind(StreamSink<T> sink);
50 } 48 }
OLDNEW
« no previous file with comments | « lib/src/stream_sink_completer.dart ('k') | lib/src/stream_sink_transformer/handler_transformer.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698