| 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 analyzer.src.context.context; | 5 library analyzer.src.context.context; |
| 6 | 6 |
| 7 import 'dart:async'; | 7 import 'dart:async'; |
| 8 import 'dart:collection'; | 8 import 'dart:collection'; |
| 9 | 9 |
| 10 import 'package:analyzer/instrumentation/instrumentation.dart'; | 10 import 'package:analyzer/instrumentation/instrumentation.dart'; |
| (...skipping 238 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 249 new StreamController<ImplicitAnalysisEvent>.broadcast(); | 249 new StreamController<ImplicitAnalysisEvent>.broadcast(); |
| 250 } | 250 } |
| 251 | 251 |
| 252 @override | 252 @override |
| 253 AnalysisCache get analysisCache => _cache; | 253 AnalysisCache get analysisCache => _cache; |
| 254 | 254 |
| 255 @override | 255 @override |
| 256 AnalysisOptions get analysisOptions => _options; | 256 AnalysisOptions get analysisOptions => _options; |
| 257 | 257 |
| 258 @override | 258 @override |
| 259 EmbedderYamlLocator get embedderYamlLocator => _embedderYamlLocator; | |
| 260 | |
| 261 @override | |
| 262 void set analysisOptions(AnalysisOptions options) { | 259 void set analysisOptions(AnalysisOptions options) { |
| 263 bool needsRecompute = this._options.analyzeFunctionBodiesPredicate != | 260 bool needsRecompute = this._options.analyzeFunctionBodiesPredicate != |
| 264 options.analyzeFunctionBodiesPredicate || | 261 options.analyzeFunctionBodiesPredicate || |
| 265 this._options.generateImplicitErrors != | 262 this._options.generateImplicitErrors != |
| 266 options.generateImplicitErrors || | 263 options.generateImplicitErrors || |
| 267 this._options.generateSdkErrors != options.generateSdkErrors || | 264 this._options.generateSdkErrors != options.generateSdkErrors || |
| 268 this._options.dart2jsHint != options.dart2jsHint || | 265 this._options.dart2jsHint != options.dart2jsHint || |
| 269 (this._options.hint && !options.hint) || | 266 (this._options.hint && !options.hint) || |
| 270 (this._options.lint && !options.lint) || | 267 (this._options.lint && !options.lint) || |
| 271 this._options.preserveComments != options.preserveComments || | 268 this._options.preserveComments != options.preserveComments || |
| (...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 322 | 319 |
| 323 @override | 320 @override |
| 324 set contentCache(ContentCache value) { | 321 set contentCache(ContentCache value) { |
| 325 _contentCache = value; | 322 _contentCache = value; |
| 326 } | 323 } |
| 327 | 324 |
| 328 @override | 325 @override |
| 329 DeclaredVariables get declaredVariables => _declaredVariables; | 326 DeclaredVariables get declaredVariables => _declaredVariables; |
| 330 | 327 |
| 331 @override | 328 @override |
| 329 EmbedderYamlLocator get embedderYamlLocator => _embedderYamlLocator; |
| 330 |
| 331 @override |
| 332 List<AnalysisTarget> get explicitTargets { | 332 List<AnalysisTarget> get explicitTargets { |
| 333 List<AnalysisTarget> targets = <AnalysisTarget>[]; | 333 List<AnalysisTarget> targets = <AnalysisTarget>[]; |
| 334 MapIterator<AnalysisTarget, CacheEntry> iterator = _cache.iterator(); | 334 MapIterator<AnalysisTarget, CacheEntry> iterator = _cache.iterator(); |
| 335 while (iterator.moveNext()) { | 335 while (iterator.moveNext()) { |
| 336 if (iterator.value.explicitlyAdded) { | 336 if (iterator.value.explicitlyAdded) { |
| 337 targets.add(iterator.key); | 337 targets.add(iterator.key); |
| 338 } | 338 } |
| 339 } | 339 } |
| 340 return targets; | 340 return targets; |
| 341 } | 341 } |
| (...skipping 1814 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2156 DartSdk sdk = factory.dartSdk; | 2156 DartSdk sdk = factory.dartSdk; |
| 2157 if (sdk == null) { | 2157 if (sdk == null) { |
| 2158 throw new IllegalArgumentException( | 2158 throw new IllegalArgumentException( |
| 2159 "The source factory for an SDK analysis context must have a DartUriRes
olver"); | 2159 "The source factory for an SDK analysis context must have a DartUriRes
olver"); |
| 2160 } | 2160 } |
| 2161 return new AnalysisCache(<CachePartition>[ | 2161 return new AnalysisCache(<CachePartition>[ |
| 2162 AnalysisEngine.instance.partitionManager_new.forSdk(sdk) | 2162 AnalysisEngine.instance.partitionManager_new.forSdk(sdk) |
| 2163 ]); | 2163 ]); |
| 2164 } | 2164 } |
| 2165 } | 2165 } |
| OLD | NEW |