| OLD | NEW |
| 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 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 | 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 services.correction.fix; | 5 library services.correction.fix; |
| 6 | 6 |
| 7 import 'package:analysis_server/src/protocol.dart' show SourceChange; | 7 import 'package:analysis_server/src/protocol.dart' show SourceChange; |
| 8 import 'package:analysis_server/src/services/correction/fix_internal.dart'; | 8 import 'package:analysis_server/src/services/correction/fix_internal.dart'; |
| 9 import 'package:analyzer/src/generated/ast.dart'; | 9 import 'package:analyzer/src/generated/ast.dart'; |
| 10 import 'package:analyzer/src/generated/error.dart'; | 10 import 'package:analyzer/src/generated/error.dart'; |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 49 static const ADD_SUPER_CONSTRUCTOR_INVOCATION = const FixKind( | 49 static const ADD_SUPER_CONSTRUCTOR_INVOCATION = const FixKind( |
| 50 'ADD_SUPER_CONSTRUCTOR_INVOCATION', 50, | 50 'ADD_SUPER_CONSTRUCTOR_INVOCATION', 50, |
| 51 "Add super constructor {0} invocation"); | 51 "Add super constructor {0} invocation"); |
| 52 static const CHANGE_TO = const FixKind('CHANGE_TO', 49, "Change to '{0}'"); | 52 static const CHANGE_TO = const FixKind('CHANGE_TO', 49, "Change to '{0}'"); |
| 53 static const CHANGE_TO_STATIC_ACCESS = const FixKind( | 53 static const CHANGE_TO_STATIC_ACCESS = const FixKind( |
| 54 'CHANGE_TO_STATIC_ACCESS', 50, "Change access to static using '{0}'"); | 54 'CHANGE_TO_STATIC_ACCESS', 50, "Change access to static using '{0}'"); |
| 55 static const CREATE_CLASS = | 55 static const CREATE_CLASS = |
| 56 const FixKind('CREATE_CLASS', 50, "Create class '{0}'"); | 56 const FixKind('CREATE_CLASS', 50, "Create class '{0}'"); |
| 57 static const CREATE_CONSTRUCTOR = | 57 static const CREATE_CONSTRUCTOR = |
| 58 const FixKind('CREATE_CONSTRUCTOR', 50, "Create constructor '{0}'"); | 58 const FixKind('CREATE_CONSTRUCTOR', 50, "Create constructor '{0}'"); |
| 59 static const CREATE_CONSTRUCTOR_FOR_FINAL_FIELDS = const FixKind( |
| 60 'CREATE_CONSTRUCTOR_FOR_FINAL_FIELDS', 50, |
| 61 "Create constructor for final fields"); |
| 59 static const CREATE_CONSTRUCTOR_SUPER = const FixKind( | 62 static const CREATE_CONSTRUCTOR_SUPER = const FixKind( |
| 60 'CREATE_CONSTRUCTOR_SUPER', 50, "Create constructor to call {0}"); | 63 'CREATE_CONSTRUCTOR_SUPER', 50, "Create constructor to call {0}"); |
| 61 static const CREATE_FIELD = | 64 static const CREATE_FIELD = |
| 62 const FixKind('CREATE_FIELD', 51, "Create field '{0}'"); | 65 const FixKind('CREATE_FIELD', 51, "Create field '{0}'"); |
| 63 static const CREATE_FILE = | 66 static const CREATE_FILE = |
| 64 const FixKind('CREATE_FILE', 50, "Create file '{0}'"); | 67 const FixKind('CREATE_FILE', 50, "Create file '{0}'"); |
| 65 static const CREATE_FUNCTION = | 68 static const CREATE_FUNCTION = |
| 66 const FixKind('CREATE_FUNCTION', 51, "Create function '{0}'"); | 69 const FixKind('CREATE_FUNCTION', 51, "Create function '{0}'"); |
| 67 static const CREATE_GETTER = | 70 static const CREATE_GETTER = |
| 68 const FixKind('CREATE_GETTER', 50, "Create getter '{0}'"); | 71 const FixKind('CREATE_GETTER', 50, "Create getter '{0}'"); |
| (...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 116 | 119 |
| 117 final name; | 120 final name; |
| 118 final int relevance; | 121 final int relevance; |
| 119 final String message; | 122 final String message; |
| 120 | 123 |
| 121 const FixKind(this.name, this.relevance, this.message); | 124 const FixKind(this.name, this.relevance, this.message); |
| 122 | 125 |
| 123 @override | 126 @override |
| 124 String toString() => name; | 127 String toString() => name; |
| 125 } | 128 } |
| OLD | NEW |