| 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 analyzer.src.generated.testing.element_factory; | 5 library analyzer.src.generated.testing.element_factory; |
| 6 | 6 |
| 7 import 'dart:collection'; | 7 import 'dart:collection'; |
| 8 | 8 |
| 9 import 'package:analyzer/dart/ast/ast.dart'; | 9 import 'package:analyzer/dart/ast/ast.dart'; |
| 10 import 'package:analyzer/dart/element/element.dart'; | 10 import 'package:analyzer/dart/element/element.dart'; |
| (...skipping 216 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 227 ]; | 227 ]; |
| 228 setter.returnType = VoidTypeImpl.instance; | 228 setter.returnType = VoidTypeImpl.instance; |
| 229 setter.type = new FunctionTypeImpl(setter); | 229 setter.type = new FunctionTypeImpl(setter); |
| 230 field.setter = setter; | 230 field.setter = setter; |
| 231 } | 231 } |
| 232 return field; | 232 return field; |
| 233 } | 233 } |
| 234 | 234 |
| 235 static FieldFormalParameterElementImpl fieldFormalParameter( | 235 static FieldFormalParameterElementImpl fieldFormalParameter( |
| 236 Identifier name) => | 236 Identifier name) => |
| 237 new FieldFormalParameterElementImpl(name); | 237 new FieldFormalParameterElementImpl.forNode(name); |
| 238 | 238 |
| 239 static FunctionElementImpl functionElement(String functionName) => | 239 static FunctionElementImpl functionElement(String functionName) => |
| 240 functionElement4(functionName, null, null, null, null); | 240 functionElement4(functionName, null, null, null, null); |
| 241 | 241 |
| 242 static FunctionElementImpl functionElement2( | 242 static FunctionElementImpl functionElement2( |
| 243 String functionName, TypeDefiningElement returnElement) => | 243 String functionName, TypeDefiningElement returnElement) => |
| 244 functionElement3(functionName, returnElement, null, null); | 244 functionElement3(functionName, returnElement, null, null); |
| 245 | 245 |
| 246 static FunctionElementImpl functionElement3( | 246 static FunctionElementImpl functionElement3( |
| 247 String functionName, | 247 String functionName, |
| (...skipping 377 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 625 } | 625 } |
| 626 | 626 |
| 627 static TypeParameterElementImpl typeParameterWithType(String name, | 627 static TypeParameterElementImpl typeParameterWithType(String name, |
| 628 [DartType bound]) { | 628 [DartType bound]) { |
| 629 TypeParameterElementImpl typeParameter = typeParameterElement(name); | 629 TypeParameterElementImpl typeParameter = typeParameterElement(name); |
| 630 typeParameter.type = new TypeParameterTypeImpl(typeParameter); | 630 typeParameter.type = new TypeParameterTypeImpl(typeParameter); |
| 631 typeParameter.bound = bound; | 631 typeParameter.bound = bound; |
| 632 return typeParameter; | 632 return typeParameter; |
| 633 } | 633 } |
| 634 } | 634 } |
| OLD | NEW |