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 // This code was auto-generated, is not intended to be edited, and is subject to | 5 // This code was auto-generated, is not intended to be edited, and is subject to |
6 // significant change. Please see the README file for more information. | 6 // significant change. Please see the README file for more information. |
7 | 7 |
8 library engine.testing.element_factory; | 8 library engine.testing.element_factory; |
9 | 9 |
10 import 'dart:collection'; | 10 import 'dart:collection'; |
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
121 HashMap<String, DartObjectImpl> fieldMap = new HashMap<String, DartObjectI
mpl>(); | 121 HashMap<String, DartObjectImpl> fieldMap = new HashMap<String, DartObjectI
mpl>(); |
122 fieldMap[indexFieldName] = new DartObjectImpl(intType, new IntState(i)); | 122 fieldMap[indexFieldName] = new DartObjectImpl(intType, new IntState(i)); |
123 fieldMap[nameFieldName] = new DartObjectImpl(stringType, new StringState(c
onstantName)); | 123 fieldMap[nameFieldName] = new DartObjectImpl(stringType, new StringState(c
onstantName)); |
124 DartObjectImpl value = new DartObjectImpl(enumType, new GenericState(field
Map)); | 124 DartObjectImpl value = new DartObjectImpl(enumType, new GenericState(field
Map)); |
125 constantElement.evaluationResult = new EvaluationResultImpl.con1(value); | 125 constantElement.evaluationResult = new EvaluationResultImpl.con1(value); |
126 fields.add(constantElement); | 126 fields.add(constantElement); |
127 } | 127 } |
128 // | 128 // |
129 // Finish building the enum. | 129 // Finish building the enum. |
130 // | 130 // |
131 enumElement.fields = new List.from(fields); | 131 enumElement.fields = fields; |
132 // Client code isn't allowed to invoke the constructor, so we do not model i
t. | 132 // Client code isn't allowed to invoke the constructor, so we do not model i
t. |
133 return enumElement; | 133 return enumElement; |
134 } | 134 } |
135 | 135 |
136 static ExportElementImpl exportFor(LibraryElement exportedLibrary, List<Namesp
aceCombinator> combinators) { | 136 static ExportElementImpl exportFor(LibraryElement exportedLibrary, List<Namesp
aceCombinator> combinators) { |
137 ExportElementImpl spec = new ExportElementImpl(); | 137 ExportElementImpl spec = new ExportElementImpl(); |
138 spec.exportedLibrary = exportedLibrary; | 138 spec.exportedLibrary = exportedLibrary; |
139 spec.combinators = combinators; | 139 spec.combinators = combinators; |
140 return spec; | 140 return spec; |
141 } | 141 } |
(...skipping 281 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
423 setter.synthetic = true; | 423 setter.synthetic = true; |
424 setter.variable = variable; | 424 setter.variable = variable; |
425 setter.parameters = <ParameterElement> [requiredParameter2("_${name}", typ
e)]; | 425 setter.parameters = <ParameterElement> [requiredParameter2("_${name}", typ
e)]; |
426 setter.returnType = VoidTypeImpl.instance; | 426 setter.returnType = VoidTypeImpl.instance; |
427 setter.type = new FunctionTypeImpl.con1(setter); | 427 setter.type = new FunctionTypeImpl.con1(setter); |
428 variable.setter = setter; | 428 variable.setter = setter; |
429 } | 429 } |
430 return variable; | 430 return variable; |
431 } | 431 } |
432 } | 432 } |
OLD | NEW |