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

Unified Diff: pkg/scheduled_test/lib/src/descriptor/async.dart

Issue 12853005: Change the way Patterns work in scheduled_test/descriptor. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Code review changes. 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « pkg/scheduled_test/lib/descriptor.dart ('k') | pkg/scheduled_test/lib/src/descriptor/async_descriptor.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/scheduled_test/lib/src/descriptor/async.dart
diff --git a/pkg/scheduled_test/lib/src/descriptor/async.dart b/pkg/scheduled_test/lib/src/descriptor/async.dart
deleted file mode 100644
index c33a68cb7532faa337544d15ddb8cc024915bdee..0000000000000000000000000000000000000000
--- a/pkg/scheduled_test/lib/src/descriptor/async.dart
+++ /dev/null
@@ -1,42 +0,0 @@
-// Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
-// for details. All rights reserved. Use of this source code is governed by a
-// BSD-style license that can be found in the LICENSE file.
-
-library descriptor.async;
-
-import 'dart:async';
-import 'dart:io' as io;
-
-import '../../descriptor.dart' as descriptor;
-import '../../scheduled_test.dart';
-import '../utils.dart';
-import 'utils.dart';
-
-/// A descriptor that wraps a [Future<Entry>] and forwards all asynchronous
-/// operations to the result of the future. It's designed for use when the
-/// full filesystem description isn't known when initializing the schedule.
-///
-/// Async descriptors don't support [load], since their names aren't
-/// synchronously available.
-class Async extends descriptor.Entry {
- /// The [Future] that will complete to the [Entry] this descriptor is
- /// wrapping.
- final Future<descriptor.Entry> future;
-
- Async(this.future)
- : super('<async descriptor>');
-
- Future create([String parent]) =>
- schedule(() => future.then((entry) => entry.create(parent)));
-
- Future validate([String parent]) =>
- schedule(() => future.then((entry) => entry.validate(parent)));
-
- Stream<List<int>> load(String path) => errorStream("Async descriptors don't "
- "support load().");
-
- Stream<List<int>> read() => errorStream("Async descriptors don't support "
- "read().");
-
- String describe() => "async descriptor";
-}
« no previous file with comments | « pkg/scheduled_test/lib/descriptor.dart ('k') | pkg/scheduled_test/lib/src/descriptor/async_descriptor.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698