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

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

Issue 2132443003: Add package implementation. (Closed) Base URL: git@github.com:dart-lang/package_resolver@master
Patch Set: Code review changes Created 4 years, 5 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
« no previous file with comments | « lib/package_resolver.dart ('k') | lib/src/current_isolate_resolver.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
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
3 // BSD-style license that can be found in the LICENSE file.
4
5 import 'dart:async';
6
7 import 'package_resolver.dart';
8 import 'sync_package_resolver.dart';
9
10 /// An implementation of [PackageResolver] that wraps a [SyncPackageResolver].
11 class AsyncPackageResolver implements PackageResolver {
12 /// The wrapped [SyncPackageResolver].
13 final SyncPackageResolver _inner;
14
15 AsyncPackageResolver(this._inner);
16
17 Future<Map<String, Uri>> get packageConfigMap async =>
18 _inner.packageConfigMap;
19
20 Future<Uri> get packageConfigUri async => _inner.packageConfigUri;
21 Future<Uri> get packageRoot async => _inner.packageRoot;
22 Future<SyncPackageResolver> get asSync async => _inner;
23 Future<String> get processArgument async => _inner.processArgument;
24
25 Future<Uri> resolveUri(packageUri) async => _inner.resolveUri(packageUri);
26 Future<Uri> urlFor(String package, [String path]) async =>
27 _inner.urlFor(package, path);
28 Future<Uri> packageUriFor(url) async => _inner.packageUriFor(url);
29 Future<String> packagePath(String package) async =>
30 _inner.packagePath(package);
31 }
OLDNEW
« no previous file with comments | « lib/package_resolver.dart ('k') | lib/src/current_isolate_resolver.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698