| 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 engine; | 8 library engine; |
| 9 | 9 |
| 10 import "dart:math" as math; | 10 import "dart:math" as math; |
| (...skipping 1056 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1067 */ | 1067 */ |
| 1068 AnalysisContextImpl_AnalysisTaskResultRecorder _resultRecorder; | 1068 AnalysisContextImpl_AnalysisTaskResultRecorder _resultRecorder; |
| 1069 | 1069 |
| 1070 /** | 1070 /** |
| 1071 * Cached information used in incremental analysis or `null` if none. Synchron
ize against | 1071 * Cached information used in incremental analysis or `null` if none. Synchron
ize against |
| 1072 * [cacheLock] before accessing this field. | 1072 * [cacheLock] before accessing this field. |
| 1073 */ | 1073 */ |
| 1074 IncrementalAnalysisCache _incrementalAnalysisCache; | 1074 IncrementalAnalysisCache _incrementalAnalysisCache; |
| 1075 | 1075 |
| 1076 /** | 1076 /** |
| 1077 * The [TypeProvider] for this context, `null` if not yet created. |
| 1078 */ |
| 1079 TypeProvider _typeProvider; |
| 1080 |
| 1081 /** |
| 1077 * The object used to manage the list of sources that need to be analyzed. | 1082 * The object used to manage the list of sources that need to be analyzed. |
| 1078 */ | 1083 */ |
| 1079 WorkManager _workManager = new WorkManager(); | 1084 WorkManager _workManager = new WorkManager(); |
| 1080 | 1085 |
| 1081 /** | 1086 /** |
| 1082 * The [Stopwatch] of the current "perform tasks cycle". | 1087 * The [Stopwatch] of the current "perform tasks cycle". |
| 1083 */ | 1088 */ |
| 1084 Stopwatch _performAnalysisTaskStopwatch; | 1089 Stopwatch _performAnalysisTaskStopwatch; |
| 1085 | 1090 |
| 1086 /** | 1091 /** |
| (...skipping 424 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1511 } | 1516 } |
| 1512 | 1517 |
| 1513 set test_incrementalAnalysisCache(IncrementalAnalysisCache value) { | 1518 set test_incrementalAnalysisCache(IncrementalAnalysisCache value) { |
| 1514 _incrementalAnalysisCache = value; | 1519 _incrementalAnalysisCache = value; |
| 1515 } | 1520 } |
| 1516 | 1521 |
| 1517 List<Source> get test_priorityOrder => _priorityOrder; | 1522 List<Source> get test_priorityOrder => _priorityOrder; |
| 1518 | 1523 |
| 1519 @override | 1524 @override |
| 1520 TypeProvider get typeProvider { | 1525 TypeProvider get typeProvider { |
| 1526 if (_typeProvider != null) { |
| 1527 return _typeProvider; |
| 1528 } |
| 1521 Source coreSource = sourceFactory.forUri(DartSdk.DART_CORE); | 1529 Source coreSource = sourceFactory.forUri(DartSdk.DART_CORE); |
| 1522 if (coreSource == null) { | 1530 if (coreSource == null) { |
| 1523 throw new AnalysisException("Could not create a source for dart:core"); | 1531 throw new AnalysisException("Could not create a source for dart:core"); |
| 1524 } | 1532 } |
| 1525 LibraryElement coreElement = computeLibraryElement(coreSource); | 1533 LibraryElement coreElement = computeLibraryElement(coreSource); |
| 1526 if (coreElement == null) { | 1534 if (coreElement == null) { |
| 1527 throw new AnalysisException("Could not create an element for dart:core"); | 1535 throw new AnalysisException("Could not create an element for dart:core"); |
| 1528 } | 1536 } |
| 1529 Source asyncSource = sourceFactory.forUri(DartSdk.DART_ASYNC); | 1537 Source asyncSource = sourceFactory.forUri(DartSdk.DART_ASYNC); |
| 1530 if (asyncSource == null) { | 1538 if (asyncSource == null) { |
| 1531 throw new AnalysisException("Could not create a source for dart:async"); | 1539 throw new AnalysisException("Could not create a source for dart:async"); |
| 1532 } | 1540 } |
| 1533 LibraryElement asyncElement = computeLibraryElement(asyncSource); | 1541 LibraryElement asyncElement = computeLibraryElement(asyncSource); |
| 1534 if (asyncElement == null) { | 1542 if (asyncElement == null) { |
| 1535 throw new AnalysisException("Could not create an element for dart:async"); | 1543 throw new AnalysisException("Could not create an element for dart:async"); |
| 1536 } | 1544 } |
| 1537 return new TypeProviderImpl(coreElement, asyncElement); | 1545 _typeProvider = new TypeProviderImpl(coreElement, asyncElement); |
| 1546 return _typeProvider; |
| 1547 } |
| 1548 |
| 1549 /** |
| 1550 * Sets the [TypeProvider] for this context. |
| 1551 */ |
| 1552 void set typeProvider(TypeProvider typeProvider) { |
| 1553 _typeProvider = typeProvider; |
| 1538 } | 1554 } |
| 1539 | 1555 |
| 1540 @override | 1556 @override |
| 1541 void addListener(AnalysisListener listener) { | 1557 void addListener(AnalysisListener listener) { |
| 1542 if (!_listeners.contains(listener)) { | 1558 if (!_listeners.contains(listener)) { |
| 1543 _listeners.add(listener); | 1559 _listeners.add(listener); |
| 1544 } | 1560 } |
| 1545 } | 1561 } |
| 1546 | 1562 |
| 1547 @override | 1563 @override |
| (...skipping 7988 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 9536 List<Source> get prioritySources; | 9552 List<Source> get prioritySources; |
| 9537 | 9553 |
| 9538 /** A factory to override how [ResolverVisitor] is created. */ | 9554 /** A factory to override how [ResolverVisitor] is created. */ |
| 9539 ResolverVisitorFactory get resolverVisitorFactory; | 9555 ResolverVisitorFactory get resolverVisitorFactory; |
| 9540 | 9556 |
| 9541 /** | 9557 /** |
| 9542 * Returns a statistics about this context. | 9558 * Returns a statistics about this context. |
| 9543 */ | 9559 */ |
| 9544 AnalysisContextStatistics get statistics; | 9560 AnalysisContextStatistics get statistics; |
| 9545 | 9561 |
| 9562 /** |
| 9563 * Sets the [TypeProvider] for this context. |
| 9564 */ |
| 9565 void set typeProvider(TypeProvider typeProvider); |
| 9566 |
| 9546 /** A factory to override how [TypeResolverVisitor] is created. */ | 9567 /** A factory to override how [TypeResolverVisitor] is created. */ |
| 9547 TypeResolverVisitorFactory get typeResolverVisitorFactory; | 9568 TypeResolverVisitorFactory get typeResolverVisitorFactory; |
| 9548 | 9569 |
| 9549 /** | 9570 /** |
| 9550 * Add the given source with the given information to this context. | 9571 * Add the given source with the given information to this context. |
| 9551 * | 9572 * |
| 9552 * @param source the source to be added | 9573 * @param source the source to be added |
| 9553 * @param info the information about the source | 9574 * @param info the information about the source |
| 9554 */ | 9575 */ |
| 9555 void addSourceInfo(Source source, SourceEntry info); | 9576 void addSourceInfo(Source source, SourceEntry info); |
| (...skipping 2663 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 12219 visitElement(Element element) { | 12240 visitElement(Element element) { |
| 12220 if (element.id == _id) { | 12241 if (element.id == _id) { |
| 12221 result = element; | 12242 result = element; |
| 12222 throw new _ElementByIdFinderException(); | 12243 throw new _ElementByIdFinderException(); |
| 12223 } | 12244 } |
| 12224 super.visitElement(element); | 12245 super.visitElement(element); |
| 12225 } | 12246 } |
| 12226 } | 12247 } |
| 12227 | 12248 |
| 12228 class _ElementByIdFinderException {} | 12249 class _ElementByIdFinderException {} |
| OLD | NEW |