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

Side by Side Diff: pkg/analysis_server/lib/src/services/completion/dart_completion_manager.dart

Issue 785393003: Rollback r42232. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 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. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 library services.completion.dart; 5 library services.completion.dart;
6 6
7 import 'dart:async'; 7 import 'dart:async';
8 8
9 import 'package:analysis_server/src/protocol.dart'; 9 import 'package:analysis_server/src/protocol.dart';
10 import 'package:analysis_server/src/services/completion/arglist_computer.dart'; 10 import 'package:analysis_server/src/services/completion/arglist_computer.dart';
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 */ 68 */
69 factory DartCompletionManager.create(AnalysisContext context, 69 factory DartCompletionManager.create(AnalysisContext context,
70 SearchEngine searchEngine, Source source) { 70 SearchEngine searchEngine, Source source) {
71 return new DartCompletionManager( 71 return new DartCompletionManager(
72 context, 72 context,
73 searchEngine, 73 searchEngine,
74 source, 74 source,
75 new DartCompletionCache(context, source)); 75 new DartCompletionCache(context, source));
76 } 76 }
77 77
78 // @override 78 @override
79 // void computeCache() { 79 void computeCache() {
80 // waitForAnalysis().then((CompilationUnit unit) { 80 waitForAnalysis().then((CompilationUnit unit) {
81 // if (unit != null && !cache.isImportInfoCached(unit)) { 81 if (unit != null && !cache.isImportInfoCached(unit)) {
82 // cache.computeImportInfo(unit, searchEngine); 82 cache.computeImportInfo(unit, searchEngine);
83 // } 83 }
84 // }); 84 });
85 // } 85 }
86 86
87 /** 87 /**
88 * Compute suggestions based upon cached information only 88 * Compute suggestions based upon cached information only
89 * then send an initial response to the client. 89 * then send an initial response to the client.
90 * Return a list of computers for which [computeFull] should be called 90 * Return a list of computers for which [computeFull] should be called
91 */ 91 */
92 List<DartCompletionComputer> computeFast(DartCompletionRequest request) { 92 List<DartCompletionComputer> computeFast(DartCompletionRequest request) {
93 return request.performance.logElapseTime('computeFast', () { 93 return request.performance.logElapseTime('computeFast', () {
94 CompilationUnit unit = context.parseCompilationUnit(source); 94 CompilationUnit unit = context.parseCompilationUnit(source);
95 request.unit = unit; 95 request.unit = unit;
(...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after
280 _ReplacementOffsetBuilder(this.request) { 280 _ReplacementOffsetBuilder(this.request) {
281 request.replacementOffset = request.offset; 281 request.replacementOffset = request.offset;
282 request.replacementLength = 0; 282 request.replacementLength = 0;
283 } 283 }
284 284
285 visitSimpleIdentifier(SimpleIdentifier node) { 285 visitSimpleIdentifier(SimpleIdentifier node) {
286 request.replacementOffset = node.offset; 286 request.replacementOffset = node.offset;
287 request.replacementLength = node.length; 287 request.replacementLength = node.length;
288 } 288 }
289 } 289 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698