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

Side by Side Diff: pkg/analysis_server/lib/src/generated/service_interfaces.dart

Issue 361713005: Remove server/generated folder. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 5 months 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 | « pkg/analysis_server/lib/src/generated/service_computers.dart ('k') | 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
(Empty)
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
3 // BSD-style license that can be found in the LICENSE file.
4
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.
7
8 library service.interfaces;
9
10 import 'package:analyzer/src/generated/java_core.dart' show Enum, StringUtils;
11 import 'package:analyzer/src/generated/source.dart' show Source;
12
13 ///**
14 // * The interface `AssistsConsumer` defines the behavior of objects that consum e assists
15 // * [SourceChange]s.
16 // */
17 //abstract class AssistsConsumer implements Consumer {
18 // /**
19 // * A set of [SourceChange]s that have been computed.
20 // *
21 // * @param proposals an array of computed [SourceChange]s
22 // * @param isLastResult is `true` if this is the last set of results
23 // */
24 // void computedSourceChanges(List<SourceChange> sourceChanges, bool isLastResu lt);
25 //}
26
27 /**
28 * The interface `CompletionSuggestion` defines the behavior of objects represen ting a
29 * completion suggestions.
30 */
31 abstract class CompletionSuggestion {
32 static final int RELEVANCE_LOW = 0;
33
34 static final int RELEVANCE_DEFAULT = 10;
35
36 static final int RELEVANCE_HIGH = 20;
37
38 /**
39 * An empty array of suggestions.
40 */
41 static final List<CompletionSuggestion> EMPTY_ARRAY = new List<CompletionSugge stion>(0);
42
43 /**
44 * This character is used to specify location of the cursor after completion.
45 */
46 static final int CURSOR_MARKER = 0x2758;
47
48 String get completion;
49
50 String get declaringType;
51
52 String get elementDocDetails;
53
54 String get elementDocSummary;
55
56 CompletionSuggestionKind get kind;
57
58 int get location;
59
60 String get parameterName;
61
62 List<String> get parameterNames;
63
64 String get parameterType;
65
66 List<String> get parameterTypes;
67
68 int get positionalParameterCount;
69
70 int get relevance;
71
72 int get replacementLength;
73
74 int get replacementLengthIdentifier;
75
76 String get returnType;
77
78 bool get hasNamed;
79
80 bool get hasPositional;
81
82 bool get isDeprecated;
83
84 bool get isPotentialMatch;
85 }
86
87 /**
88 * The various kinds of completion proposals. Each specifies the kind of complet ion to be created,
89 * corresponding to different syntactical elements.
90 */
91 class CompletionSuggestionKind extends Enum<CompletionSuggestionKind> {
92 static const CompletionSuggestionKind NONE = const CompletionSuggestionKind('N ONE', 0);
93
94 static const CompletionSuggestionKind CLASS = const CompletionSuggestionKind(' CLASS', 1);
95
96 static const CompletionSuggestionKind CLASS_ALIAS = const CompletionSuggestion Kind('CLASS_ALIAS', 2);
97
98 static const CompletionSuggestionKind CONSTRUCTOR = const CompletionSuggestion Kind('CONSTRUCTOR', 3);
99
100 static const CompletionSuggestionKind FIELD = const CompletionSuggestionKind(' FIELD', 4);
101
102 static const CompletionSuggestionKind FUNCTION = const CompletionSuggestionKin d('FUNCTION', 5);
103
104 static const CompletionSuggestionKind FUNCTION_ALIAS = const CompletionSuggest ionKind('FUNCTION_ALIAS', 6);
105
106 static const CompletionSuggestionKind GETTER = const CompletionSuggestionKind( 'GETTER', 7);
107
108 static const CompletionSuggestionKind IMPORT = const CompletionSuggestionKind( 'IMPORT', 8);
109
110 static const CompletionSuggestionKind LIBRARY_PREFIX = const CompletionSuggest ionKind('LIBRARY_PREFIX', 9);
111
112 static const CompletionSuggestionKind METHOD = const CompletionSuggestionKind( 'METHOD', 10);
113
114 static const CompletionSuggestionKind METHOD_NAME = const CompletionSuggestion Kind('METHOD_NAME', 11);
115
116 static const CompletionSuggestionKind PARAMETER = const CompletionSuggestionKi nd('PARAMETER', 12);
117
118 static const CompletionSuggestionKind SETTER = const CompletionSuggestionKind( 'SETTER', 13);
119
120 static const CompletionSuggestionKind VARIABLE = const CompletionSuggestionKin d('VARIABLE', 14);
121
122 static const CompletionSuggestionKind TYPE_PARAMETER = const CompletionSuggest ionKind('TYPE_PARAMETER', 15);
123
124 static const CompletionSuggestionKind ARGUMENT_LIST = const CompletionSuggesti onKind('ARGUMENT_LIST', 16);
125
126 static const CompletionSuggestionKind OPTIONAL_ARGUMENT = const CompletionSugg estionKind('OPTIONAL_ARGUMENT', 17);
127
128 static const CompletionSuggestionKind NAMED_ARGUMENT = const CompletionSuggest ionKind('NAMED_ARGUMENT', 18);
129
130 static const List<CompletionSuggestionKind> values = const [
131 NONE,
132 CLASS,
133 CLASS_ALIAS,
134 CONSTRUCTOR,
135 FIELD,
136 FUNCTION,
137 FUNCTION_ALIAS,
138 GETTER,
139 IMPORT,
140 LIBRARY_PREFIX,
141 METHOD,
142 METHOD_NAME,
143 PARAMETER,
144 SETTER,
145 VARIABLE,
146 TYPE_PARAMETER,
147 ARGUMENT_LIST,
148 OPTIONAL_ARGUMENT,
149 NAMED_ARGUMENT];
150
151 const CompletionSuggestionKind(String name, int ordinal) : super(name, ordinal );
152 }
153
154 /**
155 * The interface `Consumer` is a marker interface for all consumers interfaces.
156 */
157 abstract class Consumer {
158 }
159
160 /**
161 * The interface `Element` defines the behavior of objects that represent an inf ormation for
162 * an element.
163 */
164 abstract class Element {
165 /**
166 * An empty array of elements.
167 */
168 static final List<Element> EMPTY_ARRAY = new List<Element>(0);
169
170 /**
171 * Return the id of the context this element is created in.
172 *
173 * @return the id of the context
174 */
175 String get contextId;
176
177 /**
178 * Return the id of the element, may be `null` if there is no resolution infor mation
179 * associated with this element.
180 *
181 * @return the id of the element
182 */
183 String get id;
184
185 /**
186 * Return the kind of the element.
187 *
188 * @return the kind of the element
189 */
190 ElementKind get kind;
191
192 /**
193 * Return the length of the element's name.
194 *
195 * @return the length of the element's name
196 */
197 int get length;
198
199 /**
200 * Return the name of the element.
201 *
202 * @return the name of the element
203 */
204 String get name;
205
206 /**
207 * Return the offset to the beginning of the element's name.
208 *
209 * @return the offset to the beginning of the element's name
210 */
211 int get offset;
212
213 /**
214 * Return the parameter list for the element, or `null` if the element is not a constructor,
215 * method or function. If the element has zero arguments, the string `"()"` wi ll be
216 * returned.
217 *
218 * @return the parameter list for the element
219 */
220 String get parameters;
221
222 /**
223 * Return the return type of the element, or `null` if the element is not a me thod or
224 * function. If the element does not have a declared return type then an empty string will be
225 * returned.
226 *
227 * @return the return type of the element
228 */
229 String get returnType;
230
231 /**
232 * Return the source containing the element, not `null`.
233 *
234 * @return the source containing the element
235 */
236 Source get source;
237
238 /**
239 * Return `true` if the element is abstract.
240 *
241 * @return `true` if the element is abstract
242 */
243 bool get isAbstract;
244
245 /**
246 * Return `true` if the element is private.
247 *
248 * @return `true` if the element is private
249 */
250 bool get isPrivate;
251
252 /**
253 * Return `true` if the element is a class member and is a static element.
254 *
255 * @return `true` if the element is a static element
256 */
257 bool get isStatic;
258 }
259
260 /**
261 * The enumeration `ElementKind` defines the various kinds of [Element]s.
262 */
263 class ElementKind extends Enum<ElementKind> {
264 static const ElementKind CLASS = const ElementKind('CLASS', 0);
265
266 static const ElementKind CLASS_TYPE_ALIAS = const ElementKind('CLASS_TYPE_ALIA S', 1);
267
268 static const ElementKind COMPILATION_UNIT = const ElementKind('COMPILATION_UNI T', 2);
269
270 static const ElementKind CONSTRUCTOR = const ElementKind('CONSTRUCTOR', 3);
271
272 static const ElementKind GETTER = const ElementKind('GETTER', 4);
273
274 static const ElementKind FIELD = const ElementKind('FIELD', 5);
275
276 static const ElementKind FUNCTION = const ElementKind('FUNCTION', 6);
277
278 static const ElementKind FUNCTION_TYPE_ALIAS = const ElementKind('FUNCTION_TYP E_ALIAS', 7);
279
280 static const ElementKind LIBRARY = const ElementKind('LIBRARY', 8);
281
282 static const ElementKind METHOD = const ElementKind('METHOD', 9);
283
284 static const ElementKind SETTER = const ElementKind('SETTER', 10);
285
286 static const ElementKind TOP_LEVEL_VARIABLE = const ElementKind('TOP_LEVEL_VAR IABLE', 11);
287
288 static const ElementKind UNKNOWN = const ElementKind('UNKNOWN', 12);
289
290 static const ElementKind UNIT_TEST_CASE = const ElementKind('UNIT_TEST_CASE', 13);
291
292 static const ElementKind UNIT_TEST_GROUP = const ElementKind('UNIT_TEST_GROUP' , 14);
293
294 static const List<ElementKind> values = const [
295 CLASS,
296 CLASS_TYPE_ALIAS,
297 COMPILATION_UNIT,
298 CONSTRUCTOR,
299 GETTER,
300 FIELD,
301 FUNCTION,
302 FUNCTION_TYPE_ALIAS,
303 LIBRARY,
304 METHOD,
305 SETTER,
306 TOP_LEVEL_VARIABLE,
307 UNKNOWN,
308 UNIT_TEST_CASE,
309 UNIT_TEST_GROUP];
310
311 const ElementKind(String name, int ordinal) : super(name, ordinal);
312 }
313
314 /**
315 * The interface `HighlightRegion` defines the behavior of objects representing a particular
316 * syntactic or semantic meaning associated with a source region.
317 */
318 abstract class HighlightRegion implements SourceRegion {
319 /**
320 * Return the type of highlight associated with the region.
321 *
322 * @return the type of highlight associated with the region
323 */
324 HighlightType get type;
325 }
326
327 /**
328 * The enumeration `HighlightType` defines the kinds of highlighting that can be associated
329 * with a region of text.
330 */
331 class HighlightType extends Enum<HighlightType> {
332 static const HighlightType ANNOTATION = const HighlightType('ANNOTATION', 0);
333
334 static const HighlightType BUILT_IN = const HighlightType('BUILT_IN', 1);
335
336 static const HighlightType CLASS = const HighlightType('CLASS', 2);
337
338 static const HighlightType COMMENT_BLOCK = const HighlightType('COMMENT_BLOCK' , 3);
339
340 static const HighlightType COMMENT_DOCUMENTATION = const HighlightType('COMMEN T_DOCUMENTATION', 4);
341
342 static const HighlightType COMMENT_END_OF_LINE = const HighlightType('COMMENT_ END_OF_LINE', 5);
343
344 static const HighlightType CONSTRUCTOR = const HighlightType('CONSTRUCTOR', 6) ;
345
346 static const HighlightType DIRECTIVE = const HighlightType('DIRECTIVE', 7);
347
348 static const HighlightType DYNAMIC_TYPE = const HighlightType('DYNAMIC_TYPE', 8);
349
350 static const HighlightType FIELD = const HighlightType('FIELD', 9);
351
352 static const HighlightType FIELD_STATIC = const HighlightType('FIELD_STATIC', 10);
353
354 static const HighlightType FUNCTION_DECLARATION = const HighlightType('FUNCTIO N_DECLARATION', 11);
355
356 static const HighlightType FUNCTION = const HighlightType('FUNCTION', 12);
357
358 static const HighlightType FUNCTION_TYPE_ALIAS = const HighlightType('FUNCTION _TYPE_ALIAS', 13);
359
360 static const HighlightType GETTER_DECLARATION = const HighlightType('GETTER_DE CLARATION', 14);
361
362 static const HighlightType KEYWORD = const HighlightType('KEYWORD', 15);
363
364 static const HighlightType IDENTIFIER_DEFAULT = const HighlightType('IDENTIFIE R_DEFAULT', 16);
365
366 static const HighlightType IMPORT_PREFIX = const HighlightType('IMPORT_PREFIX' , 17);
367
368 static const HighlightType LITERAL_BOOLEAN = const HighlightType('LITERAL_BOOL EAN', 18);
369
370 static const HighlightType LITERAL_DOUBLE = const HighlightType('LITERAL_DOUBL E', 19);
371
372 static const HighlightType LITERAL_INTEGER = const HighlightType('LITERAL_INTE GER', 20);
373
374 static const HighlightType LITERAL_LIST = const HighlightType('LITERAL_LIST', 21);
375
376 static const HighlightType LITERAL_MAP = const HighlightType('LITERAL_MAP', 22 );
377
378 static const HighlightType LITERAL_STRING = const HighlightType('LITERAL_STRIN G', 23);
379
380 static const HighlightType LOCAL_VARIABLE_DECLARATION = const HighlightType('L OCAL_VARIABLE_DECLARATION', 24);
381
382 static const HighlightType LOCAL_VARIABLE = const HighlightType('LOCAL_VARIABL E', 25);
383
384 static const HighlightType METHOD_DECLARATION = const HighlightType('METHOD_DE CLARATION', 26);
385
386 static const HighlightType METHOD_DECLARATION_STATIC = const HighlightType('ME THOD_DECLARATION_STATIC', 27);
387
388 static const HighlightType METHOD = const HighlightType('METHOD', 28);
389
390 static const HighlightType METHOD_STATIC = const HighlightType('METHOD_STATIC' , 29);
391
392 static const HighlightType PARAMETER = const HighlightType('PARAMETER', 30);
393
394 static const HighlightType SETTER_DECLARATION = const HighlightType('SETTER_DE CLARATION', 31);
395
396 static const HighlightType TOP_LEVEL_VARIABLE = const HighlightType('TOP_LEVEL _VARIABLE', 32);
397
398 static const HighlightType TYPE_NAME_DYNAMIC = const HighlightType('TYPE_NAME_ DYNAMIC', 33);
399
400 static const HighlightType TYPE_PARAMETER = const HighlightType('TYPE_PARAMETE R', 34);
401
402 static const List<HighlightType> values = const [
403 ANNOTATION,
404 BUILT_IN,
405 CLASS,
406 COMMENT_BLOCK,
407 COMMENT_DOCUMENTATION,
408 COMMENT_END_OF_LINE,
409 CONSTRUCTOR,
410 DIRECTIVE,
411 DYNAMIC_TYPE,
412 FIELD,
413 FIELD_STATIC,
414 FUNCTION_DECLARATION,
415 FUNCTION,
416 FUNCTION_TYPE_ALIAS,
417 GETTER_DECLARATION,
418 KEYWORD,
419 IDENTIFIER_DEFAULT,
420 IMPORT_PREFIX,
421 LITERAL_BOOLEAN,
422 LITERAL_DOUBLE,
423 LITERAL_INTEGER,
424 LITERAL_LIST,
425 LITERAL_MAP,
426 LITERAL_STRING,
427 LOCAL_VARIABLE_DECLARATION,
428 LOCAL_VARIABLE,
429 METHOD_DECLARATION,
430 METHOD_DECLARATION_STATIC,
431 METHOD,
432 METHOD_STATIC,
433 PARAMETER,
434 SETTER_DECLARATION,
435 TOP_LEVEL_VARIABLE,
436 TYPE_NAME_DYNAMIC,
437 TYPE_PARAMETER];
438
439 const HighlightType(String name, int ordinal) : super(name, ordinal);
440 }
441
442 /**
443 * A [SourceSetKind#LIST] implementation of [SourceSet].
444 */
445 class ListSourceSet implements SourceSet {
446 /**
447 * Creates a new list-based [SourceSet] instance.
448 */
449 static SourceSet create(Iterable<Source> sourceCollection) {
450 List<Source> sources = new List.from(sourceCollection);
451 return new ListSourceSet(sources);
452 }
453
454 /**
455 * Creates a new list-based [SourceSet] instance.
456 */
457 static SourceSet create2(List<Source> sources) => new ListSourceSet(sources);
458
459 final List<Source> sources;
460
461 ListSourceSet(this.sources);
462
463 @override
464 SourceSetKind get kind => SourceSetKind.LIST;
465
466 @override
467 String toString() => "[${StringUtils.join(sources, ", ")}]";
468 }
469
470 /**
471 * The interface `NavigationRegion` defines the behavior of objects representing a list of
472 * elements with which a source region is associated.
473 */
474 abstract class NavigationRegion implements SourceRegion {
475 /**
476 * An empty array of navigation regions.
477 */
478 static final List<NavigationRegion> EMPTY_ARRAY = new List<NavigationRegion>(0 );
479
480 /**
481 * Return the elements associated with the region.
482 *
483 * @return the elements associated with the region
484 */
485 List<Element> get targets;
486 }
487
488 /**
489 * The enumeration `NotificationKind` defines the kinds of notification clients may subscribe
490 * for.
491 */
492 class NotificationKind extends Enum<NotificationKind> {
493 static const NotificationKind ERRORS = const NotificationKind('ERRORS', 0);
494
495 static const NotificationKind HIGHLIGHTS = const NotificationKind('HIGHLIGHTS' , 1);
496
497 static const NotificationKind NAVIGATION = const NotificationKind('NAVIGATION' , 2);
498
499 static const NotificationKind OUTLINE = const NotificationKind('OUTLINE', 3);
500
501 static const List<NotificationKind> values = const [ERRORS, HIGHLIGHTS, NAVIGA TION, OUTLINE];
502
503 const NotificationKind(String name, int ordinal) : super(name, ordinal);
504 }
505
506 /**
507 * The interface `Outline` defines the behavior of objects that represent an out line for an
508 * element.
509 */
510 abstract class Outline {
511 /**
512 * An empty array of outlines.
513 */
514 static final List<Outline> EMPTY_ARRAY = new List<Outline>(0);
515
516 /**
517 * Return an array containing the children outline. The array will be empty if the outline has no
518 * children.
519 *
520 * @return an array containing the children of the element
521 */
522 List<Outline> get children;
523
524 /**
525 * Return the information about the element.
526 *
527 * @return the information about the element
528 */
529 Element get element;
530
531 /**
532 * Return the outline that either physically or logically encloses this outlin e. This will be
533 * `null` if this outline is a unit outline.
534 *
535 * @return the outline that encloses this outline
536 */
537 Outline get parent;
538
539 /**
540 * Return the source range associated with this outline.
541 *
542 * @return the source range associated with this outline
543 */
544 SourceRegion get sourceRegion;
545 }
546
547 /**
548 * The interface `SearchResult` defines the behavior of objects that represent a search
549 * result.
550 */
551 abstract class SearchResult {
552 /**
553 * An empty array of [SearchResult]s.
554 */
555 static final List<SearchResult> EMPTY_ARRAY = new List<SearchResult>(0);
556
557 /**
558 * Return the kind to this result.
559 *
560 * @return the kind of this result
561 */
562 SearchResultKind get kind;
563
564 /**
565 * Return the length of the result.
566 *
567 * @return the length of the result
568 */
569 int get length;
570
571 /**
572 * Return the offset to the beginning of the result in [getSource].
573 *
574 * @return the offset to the beginning of the result
575 */
576 int get offset;
577
578 /**
579 * Return the path to this result starting with the element that encloses it, then for its
580 * enclosing element, etc up to the library.
581 *
582 * @return the path to this result
583 */
584 List<Element> get path;
585
586 /**
587 * Return the source containing the result.
588 *
589 * @return the source containing the result
590 */
591 Source get source;
592
593 /**
594 * Return `true` is this search result is a potential reference to a class mem ber.
595 *
596 * @return `true` is this search result is a potential reference to a class me mber
597 */
598 bool get isPotential;
599 }
600
601 /**
602 * The enumeration `SearchResultKind` defines the various kinds of [SearchResult ].
603 */
604 class SearchResultKind extends Enum<SearchResultKind> {
605 /**
606 * A declaration of a class.
607 */
608 static const SearchResultKind CLASS_DECLARATION = const SearchResultKind('CLAS S_DECLARATION', 0);
609
610 /**
611 * A declaration of a class member.
612 */
613 static const SearchResultKind CLASS_MEMBER_DECLARATION = const SearchResultKin d('CLASS_MEMBER_DECLARATION', 1);
614
615 /**
616 * A reference to a constructor.
617 */
618 static const SearchResultKind CONSTRUCTOR_REFERENCE = const SearchResultKind(' CONSTRUCTOR_REFERENCE', 2);
619
620 /**
621 * A reference to a field (from field formal parameter).
622 */
623 static const SearchResultKind FIELD_REFERENCE = const SearchResultKind('FIELD_ REFERENCE', 3);
624
625 /**
626 * A reference to a field in which it is read.
627 */
628 static const SearchResultKind FIELD_READ = const SearchResultKind('FIELD_READ' , 4);
629
630 /**
631 * A reference to a field in which it is read and written.
632 */
633 static const SearchResultKind FIELD_READ_WRITE = const SearchResultKind('FIELD _READ_WRITE', 5);
634
635 /**
636 * A reference to a field in which it is written.
637 */
638 static const SearchResultKind FIELD_WRITE = const SearchResultKind('FIELD_WRIT E', 6);
639
640 /**
641 * A declaration of a function.
642 */
643 static const SearchResultKind FUNCTION_DECLARATION = const SearchResultKind('F UNCTION_DECLARATION', 7);
644
645 /**
646 * A reference to a function in which it is invoked.
647 */
648 static const SearchResultKind FUNCTION_INVOCATION = const SearchResultKind('FU NCTION_INVOCATION', 8);
649
650 /**
651 * A reference to a function in which it is referenced.
652 */
653 static const SearchResultKind FUNCTION_REFERENCE = const SearchResultKind('FUN CTION_REFERENCE', 9);
654
655 /**
656 * A declaration of a function type.
657 */
658 static const SearchResultKind FUNCTION_TYPE_DECLARATION = const SearchResultKi nd('FUNCTION_TYPE_DECLARATION', 10);
659
660 /**
661 * A reference to a method in which it is invoked.
662 */
663 static const SearchResultKind METHOD_INVOCATION = const SearchResultKind('METH OD_INVOCATION', 11);
664
665 /**
666 * A reference to a method in which it is referenced.
667 */
668 static const SearchResultKind METHOD_REFERENCE = const SearchResultKind('METHO D_REFERENCE', 12);
669
670 /**
671 * A reference to a name, resolved.
672 */
673 static const SearchResultKind NAME_REFERENCE_RESOLVED = const SearchResultKind ('NAME_REFERENCE_RESOLVED', 13);
674
675 /**
676 * A reference to a name, unresolved.
677 */
678 static const SearchResultKind NAME_REFERENCE_UNRESOLVED = const SearchResultKi nd('NAME_REFERENCE_UNRESOLVED', 14);
679
680 /**
681 * A reference to a property accessor.
682 */
683 static const SearchResultKind PROPERTY_ACCESSOR_REFERENCE = const SearchResult Kind('PROPERTY_ACCESSOR_REFERENCE', 15);
684
685 /**
686 * A reference to a type.
687 */
688 static const SearchResultKind TYPE_REFERENCE = const SearchResultKind('TYPE_RE FERENCE', 16);
689
690 /**
691 * A declaration of a variable.
692 */
693 static const SearchResultKind VARIABLE_DECLARATION = const SearchResultKind('V ARIABLE_DECLARATION', 17);
694
695 /**
696 * A reference to a variable in which it is read.
697 */
698 static const SearchResultKind VARIABLE_READ = const SearchResultKind('VARIABLE _READ', 18);
699
700 /**
701 * A reference to a variable in which it is both read and written.
702 */
703 static const SearchResultKind VARIABLE_READ_WRITE = const SearchResultKind('VA RIABLE_READ_WRITE', 19);
704
705 /**
706 * A reference to a variable in which it is written.
707 */
708 static const SearchResultKind VARIABLE_WRITE = const SearchResultKind('VARIABL E_WRITE', 20);
709
710 static const List<SearchResultKind> values = const [
711 CLASS_DECLARATION,
712 CLASS_MEMBER_DECLARATION,
713 CONSTRUCTOR_REFERENCE,
714 FIELD_REFERENCE,
715 FIELD_READ,
716 FIELD_READ_WRITE,
717 FIELD_WRITE,
718 FUNCTION_DECLARATION,
719 FUNCTION_INVOCATION,
720 FUNCTION_REFERENCE,
721 FUNCTION_TYPE_DECLARATION,
722 METHOD_INVOCATION,
723 METHOD_REFERENCE,
724 NAME_REFERENCE_RESOLVED,
725 NAME_REFERENCE_UNRESOLVED,
726 PROPERTY_ACCESSOR_REFERENCE,
727 TYPE_REFERENCE,
728 VARIABLE_DECLARATION,
729 VARIABLE_READ,
730 VARIABLE_READ_WRITE,
731 VARIABLE_WRITE];
732
733 const SearchResultKind(String name, int ordinal) : super(name, ordinal);
734 }
735
736 /**
737 * The interface `SearchReferencesConsumer` defines the behavior of objects that consume
738 * [SearchResult]s.
739 */
740 abstract class SearchResultsConsumer implements Consumer {
741 /**
742 * [SearchResult]s have been computed.
743 *
744 * @param contextId the identifier of the context to search within
745 * @param searchResults an array of [SearchResult]s computed so far
746 * @param isLastResult is `true` if this is the last set of results
747 */
748 void computed(List<SearchResult> searchResults, bool isLastResult);
749 }
750
751 /**
752 * The interface `SourceRegion` defines the behavior of objects representing a r ange of
753 * characters within a [Source].
754 */
755 abstract class SourceRegion {
756 /**
757 * Check if <code>x</code> is in [offset, offset + length] interval.
758 */
759 bool containsInclusive(int x);
760
761 /**
762 * Return the length of the region.
763 *
764 * @return the length of the region
765 */
766 int get length;
767
768 /**
769 * Return the offset to the beginning of the region.
770 *
771 * @return the offset to the beginning of the region
772 */
773 int get offset;
774 }
775
776 /**
777 * The interface `SourceSet` defines the behavior of objects that represent a se t of
778 * [Source]s.
779 */
780 abstract class SourceSet {
781 /**
782 * An instance of [SourceSet] for [SourceSetKind#ALL].
783 */
784 static final SourceSet ALL = new _ImplicitSourceSet(SourceSetKind.ALL);
785
786 /**
787 * An instance of [SourceSet] for [SourceSetKind#NON_SDK].
788 */
789 static final SourceSet NON_SDK = new _ImplicitSourceSet(SourceSetKind.NON_SDK) ;
790
791 /**
792 * An instance of [SourceSet] for [SourceSetKind#EXPLICITLY_ADDED].
793 */
794 static final SourceSet EXPLICITLY_ADDED = new _ImplicitSourceSet(SourceSetKind .EXPLICITLY_ADDED);
795
796 /**
797 * Return the kind of the this source set.
798 */
799 SourceSetKind get kind;
800
801 /**
802 * Returns [Source]s that belong to this source set, if [SourceSetKind#LIST] i s used;
803 * an empty array otherwise.
804 */
805 List<Source> get sources;
806 }
807
808 /**
809 * The enumeration `SourceSetKind` defines the kinds of [SourceSet]s.
810 */
811 class SourceSetKind extends Enum<SourceSetKind> {
812 static const SourceSetKind ALL = const SourceSetKind('ALL', 0);
813
814 static const SourceSetKind NON_SDK = const SourceSetKind('NON_SDK', 1);
815
816 static const SourceSetKind EXPLICITLY_ADDED = const SourceSetKind('EXPLICITLY_ ADDED', 2);
817
818 static const SourceSetKind LIST = const SourceSetKind('LIST', 3);
819
820 static const List<SourceSetKind> values = const [ALL, NON_SDK, EXPLICITLY_ADDE D, LIST];
821
822 const SourceSetKind(String name, int ordinal) : super(name, ordinal);
823 }
824
825 /**
826 * The interface `TypeHierarchyItem` defines the behavior of objects representin g an item in a
827 * type hierarchy.
828 */
829 abstract class TypeHierarchyItem {
830 /**
831 * An empty array of hierarchy items.
832 */
833 static final List<TypeHierarchyItem> EMPTY_ARRAY = new List<TypeHierarchyItem> (0);
834
835 /**
836 * Return the class element associated with this item. Not `null`.
837 *
838 * @return the class element associated with this item
839 */
840 Element get classElement;
841
842 /**
843 * Return the type that is extended by this type, `null` if this item is `Obje ct`.
844 *
845 * @return the type that is extended by this type
846 */
847 TypeHierarchyItem get extendedType;
848
849 /**
850 * Return the types that are implemented by this type, `null` if not a super i tem.
851 *
852 * @return the types that are implemented by this type
853 */
854 List<TypeHierarchyItem> get implementedTypes;
855
856 /**
857 * Return the member element associated with this item. May be `null` if this type does not
858 * define the member which hierarchy is requested.
859 *
860 * @return the member element associated with this item
861 */
862 Element get memberElement;
863
864 /**
865 * Return the types that are mixed into this type, `null` if not a super item.
866 *
867 * @return the types that are mixed into this type
868 */
869 List<TypeHierarchyItem> get mixedTypes;
870
871 /**
872 * Return the display name of this item.
873 *
874 * @return the display name of this item
875 */
876 String get name;
877
878 /**
879 * Return the subtypes of this type, may be empty, but not `null`.
880 *
881 * @return the subtypes of this type
882 */
883 List<TypeHierarchyItem> get subTypes;
884 }
885
886 /**
887 * An implementation of [SourceSet] for some [SourceSetKind].
888 */
889 class _ImplicitSourceSet implements SourceSet {
890 final SourceSetKind kind;
891
892 _ImplicitSourceSet(this.kind);
893
894 @override
895 List<Source> get sources => Source.EMPTY_ARRAY;
896
897 @override
898 String toString() => kind.toString();
899 }
OLDNEW
« no previous file with comments | « pkg/analysis_server/lib/src/generated/service_computers.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698