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.task.dart; | 5 library analyzer.src.task.dart; |
6 | 6 |
7 import 'dart:collection'; | 7 import 'dart:collection'; |
8 | 8 |
9 import 'package:analyzer/src/context/cache.dart'; | 9 import 'package:analyzer/src/context/cache.dart'; |
10 import 'package:analyzer/src/generated/ast.dart'; | 10 import 'package:analyzer/src/generated/ast.dart'; |
(...skipping 2522 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2533 /** | 2533 /** |
2534 * A task that generates [LINTS] for a unit. | 2534 * A task that generates [LINTS] for a unit. |
2535 */ | 2535 */ |
2536 class GenerateLintsTask extends SourceBasedAnalysisTask { | 2536 class GenerateLintsTask extends SourceBasedAnalysisTask { |
2537 /** | 2537 /** |
2538 * The name of the [RESOLVED_UNIT8] input. | 2538 * The name of the [RESOLVED_UNIT8] input. |
2539 */ | 2539 */ |
2540 static const String RESOLVED_UNIT_INPUT = 'RESOLVED_UNIT'; | 2540 static const String RESOLVED_UNIT_INPUT = 'RESOLVED_UNIT'; |
2541 | 2541 |
2542 /** | 2542 /** |
2543 * The name of a list of [USED_LOCAL_ELEMENTS] for each library unit input. | |
2544 */ | |
2545 static const String USED_LOCAL_ELEMENTS_INPUT = 'USED_LOCAL_ELEMENTS'; | |
2546 | |
2547 /** | |
2548 * The name of a list of [USED_IMPORTED_ELEMENTS] for each library unit input. | |
2549 */ | |
2550 static const String USED_IMPORTED_ELEMENTS_INPUT = 'USED_IMPORTED_ELEMENTS'; | |
2551 | |
2552 /** | |
2553 * The name of the [TYPE_PROVIDER] input. | |
2554 */ | |
2555 static const String TYPE_PROVIDER_INPUT = 'TYPE_PROVIDER_INPUT'; | |
2556 | |
2557 /** | |
2558 * The task descriptor describing this kind of task. | 2543 * The task descriptor describing this kind of task. |
2559 */ | 2544 */ |
2560 static final TaskDescriptor DESCRIPTOR = new TaskDescriptor( | 2545 static final TaskDescriptor DESCRIPTOR = new TaskDescriptor( |
2561 'GenerateLintsTask', createTask, buildInputs, <ResultDescriptor>[LINTS]); | 2546 'GenerateLintsTask', createTask, buildInputs, <ResultDescriptor>[LINTS]); |
2562 | 2547 |
2563 GenerateLintsTask(InternalAnalysisContext context, AnalysisTarget target) | 2548 GenerateLintsTask(InternalAnalysisContext context, AnalysisTarget target) |
2564 : super(context, target); | 2549 : super(context, target); |
2565 | 2550 |
2566 @override | 2551 @override |
2567 TaskDescriptor get descriptor => DESCRIPTOR; | 2552 TaskDescriptor get descriptor => DESCRIPTOR; |
(...skipping 1844 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4412 | 4397 |
4413 @override | 4398 @override |
4414 bool moveNext() { | 4399 bool moveNext() { |
4415 if (_newSources.isEmpty) { | 4400 if (_newSources.isEmpty) { |
4416 return false; | 4401 return false; |
4417 } | 4402 } |
4418 currentTarget = _newSources.removeLast(); | 4403 currentTarget = _newSources.removeLast(); |
4419 return true; | 4404 return true; |
4420 } | 4405 } |
4421 } | 4406 } |
OLD | NEW |