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

Side by Side Diff: pkg/watcher/lib/src/directory_watcher/resubscribable.dart

Issue 69013003: Fix some analyzer warnings and hints in pkg/watcher. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 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
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 watcher.directory_watcher.resubscribable; 5 library watcher.directory_watcher.resubscribable;
6 6
7 import 'dart:async'; 7 import 'dart:async';
8 import 'dart:io';
9 8
10 import '../directory_watcher.dart'; 9 import '../directory_watcher.dart';
11 import '../utils.dart';
12 import '../watch_event.dart'; 10 import '../watch_event.dart';
13 11
14 typedef ManuallyClosedDirectoryWatcher WatcherFactory(); 12 typedef ManuallyClosedDirectoryWatcher WatcherFactory();
15 13
16 /// A wrapper for [ManuallyClosedDirectoryWatcher] that encapsulates support for 14 /// A wrapper for [ManuallyClosedDirectoryWatcher] that encapsulates support for
17 /// closing the watcher when it has no subscribers and re-opening it when it's 15 /// closing the watcher when it has no subscribers and re-opening it when it's
18 /// re-subscribed. 16 /// re-subscribed.
19 /// 17 ///
20 /// It's simpler to implement watchers without worrying about this behavior. 18 /// It's simpler to implement watchers without worrying about this behavior.
21 /// This class wraps a watcher class which can be written with the simplifying 19 /// This class wraps a watcher class which can be written with the simplifying
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 /// An interface for watchers with an explicit, manual [close] method. 68 /// An interface for watchers with an explicit, manual [close] method.
71 /// 69 ///
72 /// See [ResubscribableDirectoryWatcher]. 70 /// See [ResubscribableDirectoryWatcher].
73 abstract class ManuallyClosedDirectoryWatcher implements DirectoryWatcher { 71 abstract class ManuallyClosedDirectoryWatcher implements DirectoryWatcher {
74 /// Closes the watcher. 72 /// Closes the watcher.
75 /// 73 ///
76 /// Subclasses should close their [events] stream and release any internal 74 /// Subclasses should close their [events] stream and release any internal
77 /// resources. 75 /// resources.
78 void close(); 76 void close();
79 } 77 }
OLDNEW
« no previous file with comments | « pkg/watcher/lib/src/directory_watcher/polling.dart ('k') | pkg/watcher/test/directory_watcher/shared.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698