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

Unified Diff: pkg/analysis_server/lib/src/analysis_server.dart

Issue 914373004: Use package: URIs for files in lib (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Added test and fixed URI usage Created 5 years, 10 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 | « no previous file | pkg/analysis_server/lib/src/context_manager.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analysis_server/lib/src/analysis_server.dart
diff --git a/pkg/analysis_server/lib/src/analysis_server.dart b/pkg/analysis_server/lib/src/analysis_server.dart
index 397390b91a8b5769eed5bd7f09b2997c356affb2..b434d622809f6daedb5da9bc2ffb23e69be56ad5 100644
--- a/pkg/analysis_server/lib/src/analysis_server.dart
+++ b/pkg/analysis_server/lib/src/analysis_server.dart
@@ -335,21 +335,6 @@ class AnalysisServer {
}
/**
- * Performs all scheduled analysis operations.
- */
- void test_performAllAnalysisOperations() {
- while (true) {
- ServerOperation operation = operationQueue.takeIf((operation) {
- return operation is PerformAnalysisOperation;
- });
- if (operation == null) {
- break;
- }
- operation.perform(this);
- }
- }
-
- /**
* If the given notice applies to a file contained within an analysis root,
* notify interested parties that the file has been (at least partially)
* analyzed.
@@ -475,23 +460,6 @@ class AnalysisServer {
return context.getErrors(source);
}
-// TODO(brianwilkerson) Add the following method after 'prioritySources' has
-// been added to InternalAnalysisContext.
-// /**
-// * Return a list containing the full names of all of the sources that are
-// * priority sources.
-// */
-// List<String> getPriorityFiles() {
-// List<String> priorityFiles = new List<String>();
-// folderMap.values.forEach((ContextDirectory directory) {
-// InternalAnalysisContext context = directory.context;
-// context.prioritySources.forEach((Source source) {
-// priorityFiles.add(source.fullName);
-// });
-// });
-// return priorityFiles;
-// }
-
/**
* Returns resolved [AstNode]s at the given [offset] of the given [file].
*
@@ -509,6 +477,23 @@ class AnalysisServer {
return nodes;
}
+// TODO(brianwilkerson) Add the following method after 'prioritySources' has
+// been added to InternalAnalysisContext.
+// /**
+// * Return a list containing the full names of all of the sources that are
+// * priority sources.
+// */
+// List<String> getPriorityFiles() {
+// List<String> priorityFiles = new List<String>();
+// folderMap.values.forEach((ContextDirectory directory) {
+// InternalAnalysisContext context = directory.context;
+// context.prioritySources.forEach((Source source) {
+// priorityFiles.add(source.fullName);
+// });
+// });
+// return priorityFiles;
+// }
+
/**
* Returns resolved [CompilationUnit]s of the Dart file with the given [path].
*
@@ -970,6 +955,21 @@ class AnalysisServer {
}
/**
+ * Performs all scheduled analysis operations.
+ */
+ void test_performAllAnalysisOperations() {
+ while (true) {
+ ServerOperation operation = operationQueue.takeIf((operation) {
+ return operation is PerformAnalysisOperation;
+ });
+ if (operation == null) {
+ break;
+ }
+ operation.perform(this);
+ }
+ }
+
+ /**
* Implementation for `analysis.updateContent`.
*/
void updateContent(String id, Map<String, dynamic> changes) {
@@ -1170,7 +1170,7 @@ class ServerContextManager extends ContextManager {
_onContextsChangedController.stream;
@override
- void addContext(Folder folder, UriResolver packageUriResolver) {
+ AnalysisContext addContext(Folder folder, UriResolver packageUriResolver) {
InternalAnalysisContext context =
AnalysisEngine.instance.createAnalysisContext();
context.contentCache = analysisServer._overlayState;
@@ -1180,6 +1180,7 @@ class ServerContextManager extends ContextManager {
_onContextsChangedController.add(
new ContextsChangedEvent(added: [context]));
analysisServer.schedulePerformAnalysisOperation(context);
+ return context;
}
@override
« no previous file with comments | « no previous file | pkg/analysis_server/lib/src/context_manager.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698