| 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.task.model; | 5 library analyzer.task.model; |
| 6 | 6 |
| 7 import 'dart:collection'; | 7 import 'dart:collection'; |
| 8 | 8 |
| 9 import 'package:analyzer/src/generated/engine.dart' hide AnalysisTask; | 9 import 'package:analyzer/src/generated/engine.dart' hide AnalysisTask; |
| 10 import 'package:analyzer/src/generated/java_engine.dart'; | 10 import 'package:analyzer/src/generated/java_engine.dart'; |
| (...skipping 229 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 240 */ | 240 */ |
| 241 factory ResultDescriptor(String name, V defaultValue, | 241 factory ResultDescriptor(String name, V defaultValue, |
| 242 {ContributionPoint<V> contributesTo}) = ResultDescriptorImpl; | 242 {ContributionPoint<V> contributesTo}) = ResultDescriptorImpl; |
| 243 | 243 |
| 244 /** | 244 /** |
| 245 * Return the default value for results described by this descriptor. | 245 * Return the default value for results described by this descriptor. |
| 246 */ | 246 */ |
| 247 V get defaultValue; | 247 V get defaultValue; |
| 248 | 248 |
| 249 /** | 249 /** |
| 250 * Return the name of this descriptor. |
| 251 */ |
| 252 String get name; |
| 253 |
| 254 /** |
| 250 * Return a task input that can be used to compute this result for the given | 255 * Return a task input that can be used to compute this result for the given |
| 251 * [target]. | 256 * [target]. |
| 252 */ | 257 */ |
| 253 TaskInput<V> inputFor(AnalysisTarget target); | 258 TaskInput<V> inputFor(AnalysisTarget target); |
| 254 } | 259 } |
| 255 | 260 |
| 256 /** | 261 /** |
| 257 * A description of an [AnalysisTask]. | 262 * A description of an [AnalysisTask]. |
| 258 */ | 263 */ |
| 259 abstract class TaskDescriptor { | 264 abstract class TaskDescriptor { |
| (...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 354 * be computed, or `false` if the inputs have been computed. | 359 * be computed, or `false` if the inputs have been computed. |
| 355 * | 360 * |
| 356 * It is safe to invoke [moveNext] after it has returned `false`. In this case | 361 * It is safe to invoke [moveNext] after it has returned `false`. In this case |
| 357 * [moveNext] has no effect and will again return `false`. | 362 * [moveNext] has no effect and will again return `false`. |
| 358 * | 363 * |
| 359 * Throws a [StateError] if the value of the current result has not been | 364 * Throws a [StateError] if the value of the current result has not been |
| 360 * provided using [currentValue]. | 365 * provided using [currentValue]. |
| 361 */ | 366 */ |
| 362 bool moveNext(); | 367 bool moveNext(); |
| 363 } | 368 } |
| OLD | NEW |