OLD | NEW |
1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2015, 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 analysis_server.src.provisional.completion.completion_dart; | 5 library analysis_server.src.provisional.completion.completion_dart; |
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/provisional/completion/completion_core.dart'
; | 10 import 'package:analysis_server/src/provisional/completion/completion_core.dart'
; |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
64 * Return a [Future] that completes with the library element | 64 * Return a [Future] that completes with the library element |
65 * which contains the unit in which the completion is occurring. | 65 * which contains the unit in which the completion is occurring. |
66 * The [Future] may return `null` if the library cannot be determined | 66 * The [Future] may return `null` if the library cannot be determined |
67 * (e.g. unlinked part file). | 67 * (e.g. unlinked part file). |
68 * Any information obtained from [target] prior to calling this method | 68 * Any information obtained from [target] prior to calling this method |
69 * should be discarded as it may have changed. | 69 * should be discarded as it may have changed. |
70 */ | 70 */ |
71 Future<LibraryElement> get libraryElement; | 71 Future<LibraryElement> get libraryElement; |
72 | 72 |
73 /** | 73 /** |
| 74 * Answer the [DartType] for Object in dart:core |
| 75 */ |
| 76 DartType get objectType; |
| 77 |
| 78 /** |
74 * Return the completion target. This determines what part of the parse tree | 79 * Return the completion target. This determines what part of the parse tree |
75 * will receive the newly inserted text. | 80 * will receive the newly inserted text. |
76 */ | 81 */ |
77 CompletionTarget get target; | 82 CompletionTarget get target; |
78 | 83 |
79 /** | 84 /** |
80 * Return a [Future] that completes with a compilation unit in which | 85 * Return a [Future] that completes with a compilation unit in which |
81 * all declarations in all scopes containing [target] have been resolved. | 86 * all declarations in all scopes containing [target] have been resolved. |
82 * The [Future] may return `null` if the unit cannot be resolved | 87 * The [Future] may return `null` if the unit cannot be resolved |
83 * (e.g. unlinked part file). | 88 * (e.g. unlinked part file). |
84 * Any information obtained from [target] prior to calling this method | 89 * Any information obtained from [target] prior to calling this method |
85 * should be discarded as it may have changed. | 90 * should be discarded as it may have changed. |
86 */ | 91 */ |
87 Future<CompilationUnit> resolveDeclarationsInScope(); | 92 Future<CompilationUnit> resolveDeclarationsInScope(); |
88 | 93 |
89 /** | 94 /** |
90 * Return a [Future] that completes when the element associated with | 95 * Return a [Future] that completes when the element associated with |
91 * the given [expression] in the target compilation unit is available. | 96 * the given [expression] in the target compilation unit is available. |
92 * It may also complete if the expression cannot be resolved | 97 * It may also complete if the expression cannot be resolved |
93 * (e.g. unknown identifier, completion aborted, etc). | 98 * (e.g. unknown identifier, completion aborted, etc). |
94 * Any information obtained from [target] prior to calling this method | 99 * Any information obtained from [target] prior to calling this method |
95 * should be discarded as it may have changed. | 100 * should be discarded as it may have changed. |
96 */ | 101 */ |
97 Future resolveExpression(Expression expression); | 102 Future resolveExpression(Expression expression); |
98 } | 103 } |
OLD | NEW |