| OLD | NEW |
| 1 import 'dart:io' as io; | 1 import 'dart:io' as io; |
| 2 | 2 |
| 3 import 'package:analyzer/dart/element/element.dart'; | 3 import 'package:analyzer/dart/element/element.dart'; |
| 4 import 'package:analyzer/src/context/cache.dart'; | 4 import 'package:analyzer/src/context/cache.dart'; |
| 5 import 'package:analyzer/src/context/context.dart'; | 5 import 'package:analyzer/src/context/context.dart'; |
| 6 import 'package:analyzer/src/generated/engine.dart'; | 6 import 'package:analyzer/src/generated/engine.dart'; |
| 7 import 'package:analyzer/src/generated/java_io.dart'; | 7 import 'package:analyzer/src/generated/java_io.dart'; |
| 8 import 'package:analyzer/src/generated/resolver.dart'; | 8 import 'package:analyzer/src/generated/resolver.dart'; |
| 9 import 'package:analyzer/src/generated/source.dart'; | 9 import 'package:analyzer/src/generated/source.dart'; |
| 10 import 'package:analyzer/src/generated/source_io.dart'; | 10 import 'package:analyzer/src/generated/source_io.dart'; |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 56 } | 56 } |
| 57 // Provide known results. | 57 // Provide known results. |
| 58 if (result == LIBRARY_ELEMENT1 || | 58 if (result == LIBRARY_ELEMENT1 || |
| 59 result == LIBRARY_ELEMENT2 || | 59 result == LIBRARY_ELEMENT2 || |
| 60 result == LIBRARY_ELEMENT3 || | 60 result == LIBRARY_ELEMENT3 || |
| 61 result == LIBRARY_ELEMENT4 || | 61 result == LIBRARY_ELEMENT4 || |
| 62 result == LIBRARY_ELEMENT5 || | 62 result == LIBRARY_ELEMENT5 || |
| 63 result == LIBRARY_ELEMENT6 || | 63 result == LIBRARY_ELEMENT6 || |
| 64 result == LIBRARY_ELEMENT7 || | 64 result == LIBRARY_ELEMENT7 || |
| 65 result == LIBRARY_ELEMENT8 || | 65 result == LIBRARY_ELEMENT8 || |
| 66 result == LIBRARY_ELEMENT9 || |
| 66 result == LIBRARY_ELEMENT || | 67 result == LIBRARY_ELEMENT || |
| 67 false) { | 68 false) { |
| 68 LibraryElement libraryElement = | 69 LibraryElement libraryElement = |
| 69 _resynthesizer.getLibraryElement(uriString); | 70 _resynthesizer.getLibraryElement(uriString); |
| 70 entry.setValue(result, libraryElement, TargetedResult.EMPTY_LIST); | 71 entry.setValue(result, libraryElement, TargetedResult.EMPTY_LIST); |
| 71 return true; | 72 return true; |
| 72 } else if (result == READY_LIBRARY_ELEMENT2 || | 73 } else if (result == READY_LIBRARY_ELEMENT2 || |
| 73 result == READY_LIBRARY_ELEMENT5 || | 74 result == READY_LIBRARY_ELEMENT6 || |
| 74 result == READY_LIBRARY_ELEMENT6) { | 75 result == READY_LIBRARY_ELEMENT7) { |
| 75 entry.setValue(result, true, TargetedResult.EMPTY_LIST); | 76 entry.setValue(result, true, TargetedResult.EMPTY_LIST); |
| 76 return true; | 77 return true; |
| 77 } else if (result == SOURCE_KIND) { | 78 } else if (result == SOURCE_KIND) { |
| 78 if (_resynthesizer._dataStore.linkedMap.containsKey(uriString)) { | 79 if (_resynthesizer._dataStore.linkedMap.containsKey(uriString)) { |
| 79 entry.setValue(result, SourceKind.LIBRARY, TargetedResult.EMPTY_LIST); | 80 entry.setValue(result, SourceKind.LIBRARY, TargetedResult.EMPTY_LIST); |
| 80 return true; | 81 return true; |
| 81 } | 82 } |
| 82 if (_resynthesizer._dataStore.unlinkedMap.containsKey(uriString)) { | 83 if (_resynthesizer._dataStore.unlinkedMap.containsKey(uriString)) { |
| 83 entry.setValue(result, SourceKind.PART, TargetedResult.EMPTY_LIST); | 84 entry.setValue(result, SourceKind.PART, TargetedResult.EMPTY_LIST); |
| 84 return true; | 85 return true; |
| (...skipping 177 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 262 * also provides [summaryPath]. | 263 * also provides [summaryPath]. |
| 263 */ | 264 */ |
| 264 class _InSummaryFallbackSource extends FileBasedSource | 265 class _InSummaryFallbackSource extends FileBasedSource |
| 265 implements InSummarySource { | 266 implements InSummarySource { |
| 266 @override | 267 @override |
| 267 final String summaryPath; | 268 final String summaryPath; |
| 268 | 269 |
| 269 _InSummaryFallbackSource(JavaFile file, Uri uri, this.summaryPath) | 270 _InSummaryFallbackSource(JavaFile file, Uri uri, this.summaryPath) |
| 270 : super(file, uri); | 271 : super(file, uri); |
| 271 } | 272 } |
| OLD | NEW |