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

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

Issue 2557543002: Implement search for direct subtypes and enable `search.getTypeHierarchy` request. (Closed)
Patch Set: Created 4 years 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/services/search/search_engine_internal2.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analysis_server/lib/src/search/search_domain.dart
diff --git a/pkg/analysis_server/lib/src/search/search_domain.dart b/pkg/analysis_server/lib/src/search/search_domain.dart
index 903132576b9eefdbaf4cfcfc24d808f395a863d8..3dffbad43496db4cc3203e763e21e2857cdb2b47 100644
--- a/pkg/analysis_server/lib/src/search/search_domain.dart
+++ b/pkg/analysis_server/lib/src/search/search_domain.dart
@@ -141,21 +141,15 @@ class SearchDomainHandler implements protocol.RequestHandler {
* Implement the `search.getTypeHierarchy` request.
*/
Future getTypeHierarchy(protocol.Request request) async {
- if (server.options.enableNewAnalysisDriver) {
- // TODO(scheglov) implement for the new analysis driver
- protocol.Response response =
- new protocol.SearchGetTypeHierarchyResult(hierarchyItems: [])
- .toResponse(request.id);
- server.sendResponse(response);
- return;
- }
var params = new protocol.SearchGetTypeHierarchyParams.fromRequest(request);
String file = params.file;
// wait for analysis
- if (params.superOnly == true) {
- await server.onFileAnalysisComplete(file);
- } else {
- await server.onAnalysisComplete;
+ if (!server.options.enableNewAnalysisDriver) {
+ if (params.superOnly == true) {
+ await server.onFileAnalysisComplete(file);
+ } else {
+ await server.onAnalysisComplete;
+ }
}
// prepare element
Element element = await server.getElementAtOffset(file, params.offset);
« no previous file with comments | « no previous file | pkg/analysis_server/lib/src/services/search/search_engine_internal2.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698