OLD | NEW |
1 // Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2017, 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 import 'package:analyzer/src/codegen/tools.dart'; | 5 import 'package:analyzer/src/codegen/tools.dart'; |
6 import 'package:front_end/src/codegen/tools.dart'; | |
7 import 'package:path/path.dart' as path; | 6 import 'package:path/path.dart' as path; |
8 | 7 |
9 import 'api.dart'; | 8 import 'api.dart'; |
10 import 'codegen_dart_protocol.dart'; | 9 import 'codegen_dart_protocol.dart'; |
11 import 'from_html.dart'; | 10 import 'from_html.dart'; |
12 import 'implied_types.dart'; | 11 import 'implied_types.dart'; |
13 | 12 |
14 GeneratedFile target(bool responseRequiresRequestTime) => | 13 GeneratedFile target(bool responseRequiresRequestTime) => |
15 new GeneratedFile('lib/protocol/protocol_common.dart', (String pkgPath) { | 14 new GeneratedFile('lib/protocol/protocol_common.dart', (String pkgPath) { |
16 CodegenCommonVisitor visitor = new CodegenCommonVisitor( | 15 CodegenCommonVisitor visitor = new CodegenCommonVisitor( |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
48 List<ImpliedType> getClassesToEmit() { | 47 List<ImpliedType> getClassesToEmit() { |
49 List<ImpliedType> types = impliedTypes.values.where((ImpliedType type) { | 48 List<ImpliedType> types = impliedTypes.values.where((ImpliedType type) { |
50 ApiNode node = type.apiNode; | 49 ApiNode node = type.apiNode; |
51 return node is TypeDefinition && node.isExternal; | 50 return node is TypeDefinition && node.isExternal; |
52 }).toList(); | 51 }).toList(); |
53 types.sort((first, second) => | 52 types.sort((first, second) => |
54 capitalize(first.camelName).compareTo(capitalize(second.camelName))); | 53 capitalize(first.camelName).compareTo(capitalize(second.camelName))); |
55 return types; | 54 return types; |
56 } | 55 } |
57 } | 56 } |
OLD | NEW |