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

Side by Side Diff: pkg/front_end/lib/src/fasta/uri_translator.dart

Issue 2982593002: Rename TranslateUri to UriTranslator, rename files, extract Impl. (Closed)
Patch Set: Created 3 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
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 library fasta.uri_translator;
6
7 import 'package:front_end/file_system.dart' show FileSystem;
8
9 /// Instances of [UriTranslator] translate absolute URIs into corresponding
10 /// file URIs in a [FileSystem]. Translated URIs are typically `file:` URIs,
11 /// but may use a different scheme depending on the used custom file system.
12 abstract class UriTranslator {
13 /// Return the URIs of patches that should be applied to the platform library
14 /// with the given [libraryName], or `null` if there are no patches to apply.
Siggi Cherem (dart-lang) 2017/07/12 17:55:23 alternatively, we could drop the "or `null`..." an
scheglov 2017/07/12 18:53:14 Yeah, I thought about this. But then there is TODO
15 List<Uri> getDartPatches(String libraryName);
16
17 /// Returns `true` if [uri] is private to the platform libraries (and thus
18 /// not accessible from user code).
19 bool isPlatformImplementation(Uri uri);
20
21 /// Return the corresponding file URI for the given absolute [uri], or `null`
22 /// if there is no corresponding file URI, or the given [uri] is already a
23 /// file URI.
24 ///
25 /// This is the URIs only transformation, there is no guarantee that the
Siggi Cherem (dart-lang) 2017/07/12 17:55:24 nit: just to make it easier to read: "This is the
scheglov 2017/07/12 18:53:14 Done.
26 /// corresponding file exists in the file system.
27 Uri translate(Uri uri);
28 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698