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

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

Issue 923103004: Return RequestErrorCode.NO_INDEX_GENERATED for search/refactoring requests. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: 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
Index: pkg/analysis_server/lib/src/server/driver.dart
diff --git a/pkg/analysis_server/lib/src/server/driver.dart b/pkg/analysis_server/lib/src/server/driver.dart
index f161c54eff7cac47494f5eb7a0d36e137ee9e05e..504589c8e1ee7d079488909bf5bfe3cc1c801e47 100644
--- a/pkg/analysis_server/lib/src/server/driver.dart
+++ b/pkg/analysis_server/lib/src/server/driver.dart
@@ -132,6 +132,11 @@ class Driver implements ServerStarter {
static const String NO_ERROR_NOTIFICATION = "no-error-notification";
/**
+ * The name of the flag used to disable the index.
+ */
+ static const String NO_INDEX = "no-index";
+
+ /**
* The name of the option used to set the file read mode.
*/
static const String FILE_READ_MODE = "file-read-mode";
@@ -218,6 +223,7 @@ class Driver implements ServerStarter {
analysisServerOptions.enableIncrementalResolutionValidation =
results[INCREMENTAL_RESOLUTION_VALIDATION];
analysisServerOptions.noErrorNotification = results[NO_ERROR_NOTIFICATION];
+ analysisServerOptions.noIndex = results[NO_INDEX];
analysisServerOptions.fileReadMode = results[FILE_READ_MODE];
_initIncrementalLogger(results[INCREMENTAL_RESOLUTION_LOG]);
@@ -347,6 +353,11 @@ class Driver implements ServerStarter {
help: "disable sending all analysis error notifications to the server",
defaultsTo: false,
negatable: false);
+ parser.addFlag(
+ NO_INDEX,
+ help: "disable indexing sources",
+ defaultsTo: false,
+ negatable: false);
parser.addOption(
FILE_READ_MODE,
help: "an option of the ways files can be read from disk, " +

Powered by Google App Engine
This is Rietveld 408576698