| OLD | NEW |
| (Empty) |
| 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 | |
| 3 // BSD-style license that can be found in the LICENSE file. | |
| 4 | |
| 5 library computer.error; | |
| 6 | |
| 7 import 'package:analysis_server/src/protocol.dart'; | |
| 8 import 'package:analyzer/src/generated/engine.dart' as engine; | |
| 9 import 'package:analyzer/src/generated/error.dart' as engine; | |
| 10 import 'package:analyzer/src/generated/source.dart' as engine; | |
| 11 | |
| 12 | |
| 13 /** | |
| 14 * Returns a JSON correponding to the given list of Engine errors. | |
| 15 */ | |
| 16 List<Map<String, Object>> engineErrorsToJson(engine.LineInfo lineInfo, | |
| 17 List<engine.AnalysisError> errors) { | |
| 18 return errors.map((engine.AnalysisError error) { | |
| 19 return new AnalysisError.fromEngine(lineInfo, error).toJson(); | |
| 20 }).toList(); | |
| 21 } | |
| OLD | NEW |