| 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 // This code was auto-generated, is not intended to be edited, and is subject to | 5 // This code was auto-generated, is not intended to be edited, and is subject to |
| 6 // significant change. Please see the README file for more information. | 6 // significant change. Please see the README file for more information. |
| 7 | 7 |
| 8 library services.completion; | 8 library services.completion; |
| 9 | 9 |
| 10 import 'dart:collection'; | 10 import 'dart:collection'; |
| 11 import 'package:analysis_server/src/protocol.dart' show | 11 import "dart:math" as math; |
| 12 CompletionSuggestionKind; | 12 |
| 13 import 'package:analysis_server/src/protocol.dart' |
| 14 show CompletionSuggestionKind; |
| 13 import 'package:analyzer/src/generated/java_core.dart' hide StringUtils; | 15 import 'package:analyzer/src/generated/java_core.dart' hide StringUtils; |
| 14 import 'package:analyzer/src/generated/java_engine.dart'; | 16 import 'package:analyzer/src/generated/java_engine.dart'; |
| 15 import 'package:analyzer/src/generated/java_io.dart'; | 17 import 'package:analyzer/src/generated/java_io.dart'; |
| 16 import 'package:analyzer/src/generated/ast.dart'; | 18 import 'package:analyzer/src/generated/ast.dart'; |
| 17 import 'package:analyzer/src/generated/element.dart'; | 19 import 'package:analyzer/src/generated/element.dart'; |
| 18 import 'package:analyzer/src/generated/engine.dart'; | 20 import 'package:analyzer/src/generated/engine.dart'; |
| 19 import 'package:analyzer/src/generated/error.dart'; | 21 import 'package:analyzer/src/generated/error.dart'; |
| 20 import 'package:analyzer/src/generated/resolver.dart'; | 22 import 'package:analyzer/src/generated/resolver.dart'; |
| 21 import 'package:analyzer/src/generated/scanner.dart'; | 23 import 'package:analyzer/src/generated/scanner.dart'; |
| 22 import 'package:analyzer/src/generated/sdk.dart'; | 24 import 'package:analyzer/src/generated/sdk.dart'; |
| 23 import 'package:analyzer/src/generated/source_io.dart'; | 25 import 'package:analyzer/src/generated/source_io.dart'; |
| 24 import 'package:analyzer/src/generated/utilities_dart.dart'; | 26 import 'package:analyzer/src/generated/utilities_dart.dart'; |
| 27 |
| 25 import 'stubs.dart'; | 28 import 'stubs.dart'; |
| 26 import 'util.dart'; | 29 import 'util.dart'; |
| 27 | 30 |
| 28 class AstNodeClassifier_CompletionEngine_typeOf extends CompletionEngine_AstNode
Classifier { | 31 class AstNodeClassifier_CompletionEngine_typeOf extends CompletionEngine_AstNode
Classifier { |
| 29 final CompletionEngine CompletionEngine_this; | 32 final CompletionEngine CompletionEngine_this; |
| 30 | 33 |
| 31 List<DartType> result; | 34 List<DartType> result; |
| 32 | 35 |
| 33 AstNodeClassifier_CompletionEngine_typeOf(this.CompletionEngine_this, this.res
ult) : super(); | 36 AstNodeClassifier_CompletionEngine_typeOf(this.CompletionEngine_this, this.res
ult) : super(); |
| 34 | 37 |
| (...skipping 561 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 596 prop.setRelevance(CompletionProposal.RELEVANCE_HIGH); | 599 prop.setRelevance(CompletionProposal.RELEVANCE_HIGH); |
| 597 } | 600 } |
| 598 // done | 601 // done |
| 599 _requestor.accept(prop); | 602 _requestor.accept(prop); |
| 600 } | 603 } |
| 601 } | 604 } |
| 602 | 605 |
| 603 void _namespaceReference(NamespaceDirective node, SimpleStringLiteral literal)
{ | 606 void _namespaceReference(NamespaceDirective node, SimpleStringLiteral literal)
{ |
| 604 String lit = literal.literal.lexeme; | 607 String lit = literal.literal.lexeme; |
| 605 if (!lit.isEmpty) { | 608 if (!lit.isEmpty) { |
| 606 lit = lit.substring(1, Math.max(lit.length - 1, 0)); | 609 lit = lit.substring(1, math.max(lit.length - 1, 0)); |
| 607 } | 610 } |
| 608 _filter = _createFilter(new Ident.con2(node, lit, literal.offset + 1)); | 611 _filter = _createFilter(new Ident.con2(node, lit, literal.offset + 1)); |
| 609 Set<String> packageUris = new Set(); | 612 Set<String> packageUris = new Set(); |
| 610 List<LibraryElement> libraries = new List<LibraryElement>(); | 613 List<LibraryElement> libraries = new List<LibraryElement>(); |
| 611 List<LibraryElement> librariesInLib = new List<LibraryElement>(); | 614 List<LibraryElement> librariesInLib = new List<LibraryElement>(); |
| 612 String currentLibraryName = currentLibrary.source.fullName; | 615 String currentLibraryName = currentLibrary.source.fullName; |
| 613 AnalysisContext ac = analysisContext; | 616 AnalysisContext ac = analysisContext; |
| 614 List<Source> sources = ac.librarySources; | 617 List<Source> sources = ac.librarySources; |
| 615 for (Source s in sources) { | 618 for (Source s in sources) { |
| 616 String sName = s.fullName; | 619 String sName = s.fullName; |
| (...skipping 3079 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3696 | 3699 |
| 3697 class TopLevelNamesKind extends Enum<TopLevelNamesKind> { | 3700 class TopLevelNamesKind extends Enum<TopLevelNamesKind> { |
| 3698 static const TopLevelNamesKind DECLARED_AND_IMPORTS = const TopLevelNamesKind(
'DECLARED_AND_IMPORTS', 0); | 3701 static const TopLevelNamesKind DECLARED_AND_IMPORTS = const TopLevelNamesKind(
'DECLARED_AND_IMPORTS', 0); |
| 3699 | 3702 |
| 3700 static const TopLevelNamesKind DECLARED_AND_EXPORTS = const TopLevelNamesKind(
'DECLARED_AND_EXPORTS', 1); | 3703 static const TopLevelNamesKind DECLARED_AND_EXPORTS = const TopLevelNamesKind(
'DECLARED_AND_EXPORTS', 1); |
| 3701 | 3704 |
| 3702 static const List<TopLevelNamesKind> values = const [DECLARED_AND_IMPORTS, DEC
LARED_AND_EXPORTS]; | 3705 static const List<TopLevelNamesKind> values = const [DECLARED_AND_IMPORTS, DEC
LARED_AND_EXPORTS]; |
| 3703 | 3706 |
| 3704 const TopLevelNamesKind(String name, int ordinal) : super(name, ordinal); | 3707 const TopLevelNamesKind(String name, int ordinal) : super(name, ordinal); |
| 3705 } | 3708 } |
| OLD | NEW |