| OLD | NEW |
| 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 domain.completion; | 5 library domain.completion; |
| 6 | 6 |
| 7 import 'dart:async'; | 7 import 'dart:async'; |
| 8 | 8 |
| 9 import 'package:analysis_server/plugin/protocol/protocol.dart'; | 9 import 'package:analysis_server/plugin/protocol/protocol.dart'; |
| 10 import 'package:analysis_server/src/analysis_server.dart'; | 10 import 'package:analysis_server/src/analysis_server.dart'; |
| 11 import 'package:analysis_server/src/constants.dart'; | 11 import 'package:analysis_server/src/constants.dart'; |
| 12 import 'package:analysis_server/src/provisional/completion/completion_core.dart'
; | 12 import 'package:analysis_server/src/provisional/completion/completion_core.dart'
; |
| 13 import 'package:analysis_server/src/services/completion/completion_core.dart'; | 13 import 'package:analysis_server/src/services/completion/completion_core.dart'; |
| 14 import 'package:analysis_server/src/services/completion/completion_performance.d
art'; | 14 import 'package:analysis_server/src/services/completion/completion_performance.d
art'; |
| 15 import 'package:analyzer/src/dart/analysis/driver.dart'; | 15 import 'package:analyzer/src/dart/analysis/driver.dart'; |
| 16 import 'package:analyzer/src/generated/engine.dart' hide AnalysisResult; | 16 import 'package:analyzer/src/generated/engine.dart' hide AnalysisResult; |
| 17 import 'package:analyzer/src/source/source_resource.dart'; | 17 import 'package:analyzer/src/source/source_resource.dart'; |
| 18 import 'package:analyzer/src/generated/source.dart'; | 18 import 'package:analyzer/src/generated/source.dart'; |
| 19 | 19 |
| 20 /** | 20 /** |
| 21 * Instances of the class [CompletionDomainHandler] implement a [RequestHandler] | 21 * Instances of the class [CompletionDomainHandler] implement a [RequestHandler] |
| 22 * that handles requests in the search domain. | 22 * that handles requests in the completion domain. |
| 23 */ | 23 */ |
| 24 class CompletionDomainHandler implements RequestHandler { | 24 class CompletionDomainHandler implements RequestHandler { |
| 25 /** | 25 /** |
| 26 * The maximum number of performance measurements to keep. | 26 * The maximum number of performance measurements to keep. |
| 27 */ | 27 */ |
| 28 static const int performanceListMaxLength = 50; | 28 static const int performanceListMaxLength = 50; |
| 29 | 29 |
| 30 /** | 30 /** |
| 31 * The analysis server that is using this handler to process requests. | 31 * The analysis server that is using this handler to process requests. |
| 32 */ | 32 */ |
| (...skipping 244 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 277 final int replacementOffset; | 277 final int replacementOffset; |
| 278 | 278 |
| 279 /** | 279 /** |
| 280 * The suggested completions. | 280 * The suggested completions. |
| 281 */ | 281 */ |
| 282 final List<CompletionSuggestion> suggestions; | 282 final List<CompletionSuggestion> suggestions; |
| 283 | 283 |
| 284 CompletionResult( | 284 CompletionResult( |
| 285 this.replacementOffset, this.replacementLength, this.suggestions); | 285 this.replacementOffset, this.replacementLength, this.suggestions); |
| 286 } | 286 } |
| OLD | NEW |