Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(444)

Side by Side Diff: mojo/dart/packages/mojo/lib/mojo/bindings/types/mojom_types.mojom.dart

Issue 1539673003: Generate Mojom Types in Dart (Take 2) (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Merge with master Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 library mojom_types_mojom; 5 library mojom_types_mojom;
6 6
7 import 'dart:async'; 7 import 'dart:async';
8 8
9 import 'package:mojo/bindings.dart' as bindings; 9 import 'package:mojo/bindings.dart' as bindings;
10 import 'package:mojo/core.dart' as core; 10 import 'package:mojo/core.dart' as core;
11 11
12
13
12 class SimpleType extends bindings.MojoEnum { 14 class SimpleType extends bindings.MojoEnum {
13 static const SimpleType bool = const SimpleType._(0); 15 static const SimpleType bool = const SimpleType._(0);
14 static const SimpleType double = const SimpleType._(1); 16 static const SimpleType double = const SimpleType._(1);
15 static const SimpleType float = const SimpleType._(2); 17 static const SimpleType float = const SimpleType._(2);
16 static const SimpleType int8 = const SimpleType._(3); 18 static const SimpleType int8 = const SimpleType._(3);
17 static const SimpleType int16 = const SimpleType._(4); 19 static const SimpleType int16 = const SimpleType._(4);
18 static const SimpleType int32 = const SimpleType._(5); 20 static const SimpleType int32 = const SimpleType._(5);
19 static const SimpleType int64 = const SimpleType._(6); 21 static const SimpleType int64 = const SimpleType._(6);
20 static const SimpleType uint8 = const SimpleType._(7); 22 static const SimpleType uint8 = const SimpleType._(7);
21 static const SimpleType uint16 = const SimpleType._(8); 23 static const SimpleType uint16 = const SimpleType._(8);
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after
109 case int64: 111 case int64:
110 return 'SimpleType.int64'; 112 return 'SimpleType.int64';
111 case uint8: 113 case uint8:
112 return 'SimpleType.uint8'; 114 return 'SimpleType.uint8';
113 case uint16: 115 case uint16:
114 return 'SimpleType.uint16'; 116 return 'SimpleType.uint16';
115 case uint32: 117 case uint32:
116 return 'SimpleType.uint32'; 118 return 'SimpleType.uint32';
117 case uint64: 119 case uint64:
118 return 'SimpleType.uint64'; 120 return 'SimpleType.uint64';
121 default:
122 return null;
119 } 123 }
120 } 124 }
121 125
122 int toJson() => mojoEnumValue; 126 int toJson() => mojoEnumValue;
123 } 127 }
124 128
129
130
125 class BuiltinConstantValue extends bindings.MojoEnum { 131 class BuiltinConstantValue extends bindings.MojoEnum {
126 static const BuiltinConstantValue doubleInfinity = const BuiltinConstantValue. _(0); 132 static const BuiltinConstantValue doubleInfinity = const BuiltinConstantValue. _(0);
127 static const BuiltinConstantValue doubleNegativeInfinity = const BuiltinConsta ntValue._(1); 133 static const BuiltinConstantValue doubleNegativeInfinity = const BuiltinConsta ntValue._(1);
128 static const BuiltinConstantValue doubleNan = const BuiltinConstantValue._(2); 134 static const BuiltinConstantValue doubleNan = const BuiltinConstantValue._(2);
129 static const BuiltinConstantValue floatInfinity = const BuiltinConstantValue._ (3); 135 static const BuiltinConstantValue floatInfinity = const BuiltinConstantValue._ (3);
130 static const BuiltinConstantValue floatNegativeInfinity = const BuiltinConstan tValue._(4); 136 static const BuiltinConstantValue floatNegativeInfinity = const BuiltinConstan tValue._(4);
131 static const BuiltinConstantValue floatNan = const BuiltinConstantValue._(5); 137 static const BuiltinConstantValue floatNan = const BuiltinConstantValue._(5);
132 138
133 const BuiltinConstantValue._(int v) : super(v); 139 const BuiltinConstantValue._(int v) : super(v);
134 140
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
187 case doubleNegativeInfinity: 193 case doubleNegativeInfinity:
188 return 'BuiltinConstantValue.doubleNegativeInfinity'; 194 return 'BuiltinConstantValue.doubleNegativeInfinity';
189 case doubleNan: 195 case doubleNan:
190 return 'BuiltinConstantValue.doubleNan'; 196 return 'BuiltinConstantValue.doubleNan';
191 case floatInfinity: 197 case floatInfinity:
192 return 'BuiltinConstantValue.floatInfinity'; 198 return 'BuiltinConstantValue.floatInfinity';
193 case floatNegativeInfinity: 199 case floatNegativeInfinity:
194 return 'BuiltinConstantValue.floatNegativeInfinity'; 200 return 'BuiltinConstantValue.floatNegativeInfinity';
195 case floatNan: 201 case floatNan:
196 return 'BuiltinConstantValue.floatNan'; 202 return 'BuiltinConstantValue.floatNan';
203 default:
204 return null;
197 } 205 }
198 } 206 }
199 207
200 int toJson() => mojoEnumValue; 208 int toJson() => mojoEnumValue;
201 } 209 }
202 210
203 211
204 212
213
214
205 class StringType extends bindings.Struct { 215 class StringType extends bindings.Struct {
206 static const List<bindings.StructDataHeader> kVersions = const [ 216 static const List<bindings.StructDataHeader> kVersions = const [
207 const bindings.StructDataHeader(16, 0) 217 const bindings.StructDataHeader(16, 0)
208 ]; 218 ];
209 bool nullable = false; 219 bool nullable = false;
210 220
211 StringType() : super(kVersions.last.size); 221 StringType() : super(kVersions.last.size);
212 222
213 static StringType deserialize(bindings.Message message) { 223 static StringType deserialize(bindings.Message message) {
214 var decoder = new bindings.Decoder(message); 224 var decoder = new bindings.Decoder(message);
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
262 } 272 }
263 273
264 Map toJson() { 274 Map toJson() {
265 Map map = new Map(); 275 Map map = new Map();
266 map["nullable"] = nullable; 276 map["nullable"] = nullable;
267 return map; 277 return map;
268 } 278 }
269 } 279 }
270 280
271 281
282
283
272 class HandleTypeKind extends bindings.MojoEnum { 284 class HandleTypeKind extends bindings.MojoEnum {
273 static const HandleTypeKind unspecified = const HandleTypeKind._(0); 285 static const HandleTypeKind unspecified = const HandleTypeKind._(0);
274 static const HandleTypeKind messagePipe = const HandleTypeKind._(1); 286 static const HandleTypeKind messagePipe = const HandleTypeKind._(1);
275 static const HandleTypeKind dataPipeConsumer = const HandleTypeKind._(2); 287 static const HandleTypeKind dataPipeConsumer = const HandleTypeKind._(2);
276 static const HandleTypeKind dataPipeProducer = const HandleTypeKind._(3); 288 static const HandleTypeKind dataPipeProducer = const HandleTypeKind._(3);
277 static const HandleTypeKind sharedBuffer = const HandleTypeKind._(4); 289 static const HandleTypeKind sharedBuffer = const HandleTypeKind._(4);
278 290
279 const HandleTypeKind._(int v) : super(v); 291 const HandleTypeKind._(int v) : super(v);
280 292
281 static const Map<String, HandleTypeKind> valuesMap = const { 293 static const Map<String, HandleTypeKind> valuesMap = const {
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
327 case unspecified: 339 case unspecified:
328 return 'HandleTypeKind.unspecified'; 340 return 'HandleTypeKind.unspecified';
329 case messagePipe: 341 case messagePipe:
330 return 'HandleTypeKind.messagePipe'; 342 return 'HandleTypeKind.messagePipe';
331 case dataPipeConsumer: 343 case dataPipeConsumer:
332 return 'HandleTypeKind.dataPipeConsumer'; 344 return 'HandleTypeKind.dataPipeConsumer';
333 case dataPipeProducer: 345 case dataPipeProducer:
334 return 'HandleTypeKind.dataPipeProducer'; 346 return 'HandleTypeKind.dataPipeProducer';
335 case sharedBuffer: 347 case sharedBuffer:
336 return 'HandleTypeKind.sharedBuffer'; 348 return 'HandleTypeKind.sharedBuffer';
349 default:
350 return null;
337 } 351 }
338 } 352 }
339 353
340 int toJson() => mojoEnumValue; 354 int toJson() => mojoEnumValue;
341 } 355 }
342 356
357
358
343 class HandleType extends bindings.Struct { 359 class HandleType extends bindings.Struct {
344 static const List<bindings.StructDataHeader> kVersions = const [ 360 static const List<bindings.StructDataHeader> kVersions = const [
345 const bindings.StructDataHeader(16, 0) 361 const bindings.StructDataHeader(16, 0)
346 ]; 362 ];
347 bool nullable = false; 363 bool nullable = false;
348 HandleTypeKind kind = new HandleTypeKind(0); 364 HandleTypeKind kind = new HandleTypeKind(0);
349 365
350 HandleType() : super(kVersions.last.size); 366 HandleType() : super(kVersions.last.size);
351 367
352 static HandleType deserialize(bindings.Message message) { 368 static HandleType deserialize(bindings.Message message) {
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
413 429
414 Map toJson() { 430 Map toJson() {
415 Map map = new Map(); 431 Map map = new Map();
416 map["nullable"] = nullable; 432 map["nullable"] = nullable;
417 map["kind"] = kind; 433 map["kind"] = kind;
418 return map; 434 return map;
419 } 435 }
420 } 436 }
421 437
422 438
439
440
423 class ArrayType extends bindings.Struct { 441 class ArrayType extends bindings.Struct {
424 static const List<bindings.StructDataHeader> kVersions = const [ 442 static const List<bindings.StructDataHeader> kVersions = const [
425 const bindings.StructDataHeader(32, 0) 443 const bindings.StructDataHeader(32, 0)
426 ]; 444 ];
427 bool nullable = false; 445 bool nullable = false;
428 int fixedLength = -1; 446 int fixedLength = -1;
429 Type elementType = null; 447 Type elementType = null;
430 448
431 ArrayType() : super(kVersions.last.size); 449 ArrayType() : super(kVersions.last.size);
432 450
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
502 Map toJson() { 520 Map toJson() {
503 Map map = new Map(); 521 Map map = new Map();
504 map["nullable"] = nullable; 522 map["nullable"] = nullable;
505 map["fixedLength"] = fixedLength; 523 map["fixedLength"] = fixedLength;
506 map["elementType"] = elementType; 524 map["elementType"] = elementType;
507 return map; 525 return map;
508 } 526 }
509 } 527 }
510 528
511 529
530
531
512 class MapType extends bindings.Struct { 532 class MapType extends bindings.Struct {
513 static const List<bindings.StructDataHeader> kVersions = const [ 533 static const List<bindings.StructDataHeader> kVersions = const [
514 const bindings.StructDataHeader(48, 0) 534 const bindings.StructDataHeader(48, 0)
515 ]; 535 ];
516 bool nullable = false; 536 bool nullable = false;
517 Type keyType = null; 537 Type keyType = null;
518 Type valueType = null; 538 Type valueType = null;
519 539
520 MapType() : super(kVersions.last.size); 540 MapType() : super(kVersions.last.size);
521 541
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
595 Map toJson() { 615 Map toJson() {
596 Map map = new Map(); 616 Map map = new Map();
597 map["nullable"] = nullable; 617 map["nullable"] = nullable;
598 map["keyType"] = keyType; 618 map["keyType"] = keyType;
599 map["valueType"] = valueType; 619 map["valueType"] = valueType;
600 return map; 620 return map;
601 } 621 }
602 } 622 }
603 623
604 624
625
626
605 class TypeReference extends bindings.Struct { 627 class TypeReference extends bindings.Struct {
606 static const List<bindings.StructDataHeader> kVersions = const [ 628 static const List<bindings.StructDataHeader> kVersions = const [
607 const bindings.StructDataHeader(32, 0) 629 const bindings.StructDataHeader(32, 0)
608 ]; 630 ];
609 bool nullable = false; 631 bool nullable = false;
610 bool isInterfaceRequest = false; 632 bool isInterfaceRequest = false;
611 String identifier = null; 633 String identifier = null;
612 String typeKey = null; 634 String typeKey = null;
613 635
614 TypeReference() : super(kVersions.last.size); 636 TypeReference() : super(kVersions.last.size);
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
689 Map map = new Map(); 711 Map map = new Map();
690 map["nullable"] = nullable; 712 map["nullable"] = nullable;
691 map["isInterfaceRequest"] = isInterfaceRequest; 713 map["isInterfaceRequest"] = isInterfaceRequest;
692 map["identifier"] = identifier; 714 map["identifier"] = identifier;
693 map["typeKey"] = typeKey; 715 map["typeKey"] = typeKey;
694 return map; 716 return map;
695 } 717 }
696 } 718 }
697 719
698 720
721
722
699 class StructField extends bindings.Struct { 723 class StructField extends bindings.Struct {
700 static const List<bindings.StructDataHeader> kVersions = const [ 724 static const List<bindings.StructDataHeader> kVersions = const [
701 const bindings.StructDataHeader(56, 0) 725 const bindings.StructDataHeader(56, 0)
702 ]; 726 ];
703 DeclarationData declData = null; 727 DeclarationData declData = null;
704 Type type = null; 728 Type type = null;
705 DefaultFieldValue defaultValue = null; 729 DefaultFieldValue defaultValue = null;
706 int offset = 0; 730 int offset = 0;
707 731
708 StructField() : super(kVersions.last.size); 732 StructField() : super(kVersions.last.size);
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
788 Map map = new Map(); 812 Map map = new Map();
789 map["declData"] = declData; 813 map["declData"] = declData;
790 map["type"] = type; 814 map["type"] = type;
791 map["defaultValue"] = defaultValue; 815 map["defaultValue"] = defaultValue;
792 map["offset"] = offset; 816 map["offset"] = offset;
793 return map; 817 return map;
794 } 818 }
795 } 819 }
796 820
797 821
822
823
798 class DefaultKeyword extends bindings.Struct { 824 class DefaultKeyword extends bindings.Struct {
799 static const List<bindings.StructDataHeader> kVersions = const [ 825 static const List<bindings.StructDataHeader> kVersions = const [
800 const bindings.StructDataHeader(8, 0) 826 const bindings.StructDataHeader(8, 0)
801 ]; 827 ];
802 828
803 DefaultKeyword() : super(kVersions.last.size); 829 DefaultKeyword() : super(kVersions.last.size);
804 830
805 static DefaultKeyword deserialize(bindings.Message message) { 831 static DefaultKeyword deserialize(bindings.Message message) {
806 var decoder = new bindings.Decoder(message); 832 var decoder = new bindings.Decoder(message);
807 var result = decode(decoder); 833 var result = decode(decoder);
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
846 return "DefaultKeyword("")"; 872 return "DefaultKeyword("")";
847 } 873 }
848 874
849 Map toJson() { 875 Map toJson() {
850 Map map = new Map(); 876 Map map = new Map();
851 return map; 877 return map;
852 } 878 }
853 } 879 }
854 880
855 881
882
883
856 class StructVersion extends bindings.Struct { 884 class StructVersion extends bindings.Struct {
857 static const List<bindings.StructDataHeader> kVersions = const [ 885 static const List<bindings.StructDataHeader> kVersions = const [
858 const bindings.StructDataHeader(24, 0) 886 const bindings.StructDataHeader(24, 0)
859 ]; 887 ];
860 int versionNumber = 0; 888 int versionNumber = 0;
861 int numFields = 0; 889 int numFields = 0;
862 int numBytes = 0; 890 int numBytes = 0;
863 891
864 StructVersion() : super(kVersions.last.size); 892 StructVersion() : super(kVersions.last.size);
865 893
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
931 Map toJson() { 959 Map toJson() {
932 Map map = new Map(); 960 Map map = new Map();
933 map["versionNumber"] = versionNumber; 961 map["versionNumber"] = versionNumber;
934 map["numFields"] = numFields; 962 map["numFields"] = numFields;
935 map["numBytes"] = numBytes; 963 map["numBytes"] = numBytes;
936 return map; 964 return map;
937 } 965 }
938 } 966 }
939 967
940 968
969
970
941 class MojomStruct extends bindings.Struct { 971 class MojomStruct extends bindings.Struct {
942 static const List<bindings.StructDataHeader> kVersions = const [ 972 static const List<bindings.StructDataHeader> kVersions = const [
943 const bindings.StructDataHeader(32, 0) 973 const bindings.StructDataHeader(32, 0)
944 ]; 974 ];
945 DeclarationData declData = null; 975 DeclarationData declData = null;
946 List<StructField> fields = null; 976 List<StructField> fields = null;
947 List<StructVersion> versionInfo = null; 977 List<StructVersion> versionInfo = null;
948 978
949 MojomStruct() : super(kVersions.last.size); 979 MojomStruct() : super(kVersions.last.size);
950 980
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
1053 Map toJson() { 1083 Map toJson() {
1054 Map map = new Map(); 1084 Map map = new Map();
1055 map["declData"] = declData; 1085 map["declData"] = declData;
1056 map["fields"] = fields; 1086 map["fields"] = fields;
1057 map["versionInfo"] = versionInfo; 1087 map["versionInfo"] = versionInfo;
1058 return map; 1088 return map;
1059 } 1089 }
1060 } 1090 }
1061 1091
1062 1092
1093
1094
1063 class UnionField extends bindings.Struct { 1095 class UnionField extends bindings.Struct {
1064 static const List<bindings.StructDataHeader> kVersions = const [ 1096 static const List<bindings.StructDataHeader> kVersions = const [
1065 const bindings.StructDataHeader(40, 0) 1097 const bindings.StructDataHeader(40, 0)
1066 ]; 1098 ];
1067 DeclarationData declData = null; 1099 DeclarationData declData = null;
1068 Type type = null; 1100 Type type = null;
1069 int tag = 0; 1101 int tag = 0;
1070 1102
1071 UnionField() : super(kVersions.last.size); 1103 UnionField() : super(kVersions.last.size);
1072 1104
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
1143 Map toJson() { 1175 Map toJson() {
1144 Map map = new Map(); 1176 Map map = new Map();
1145 map["declData"] = declData; 1177 map["declData"] = declData;
1146 map["type"] = type; 1178 map["type"] = type;
1147 map["tag"] = tag; 1179 map["tag"] = tag;
1148 return map; 1180 return map;
1149 } 1181 }
1150 } 1182 }
1151 1183
1152 1184
1185
1186
1153 class MojomUnion extends bindings.Struct { 1187 class MojomUnion extends bindings.Struct {
1154 static const List<bindings.StructDataHeader> kVersions = const [ 1188 static const List<bindings.StructDataHeader> kVersions = const [
1155 const bindings.StructDataHeader(24, 0) 1189 const bindings.StructDataHeader(24, 0)
1156 ]; 1190 ];
1157 DeclarationData declData = null; 1191 DeclarationData declData = null;
1158 List<UnionField> fields = null; 1192 List<UnionField> fields = null;
1159 1193
1160 MojomUnion() : super(kVersions.last.size); 1194 MojomUnion() : super(kVersions.last.size);
1161 1195
1162 static MojomUnion deserialize(bindings.Message message) { 1196 static MojomUnion deserialize(bindings.Message message) {
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
1237 1271
1238 Map toJson() { 1272 Map toJson() {
1239 Map map = new Map(); 1273 Map map = new Map();
1240 map["declData"] = declData; 1274 map["declData"] = declData;
1241 map["fields"] = fields; 1275 map["fields"] = fields;
1242 return map; 1276 return map;
1243 } 1277 }
1244 } 1278 }
1245 1279
1246 1280
1281
1282
1247 class EnumValue extends bindings.Struct { 1283 class EnumValue extends bindings.Struct {
1248 static const List<bindings.StructDataHeader> kVersions = const [ 1284 static const List<bindings.StructDataHeader> kVersions = const [
1249 const bindings.StructDataHeader(48, 0) 1285 const bindings.StructDataHeader(48, 0)
1250 ]; 1286 ];
1251 DeclarationData declData = null; 1287 DeclarationData declData = null;
1252 String enumTypeKey = null; 1288 String enumTypeKey = null;
1253 Value initializerValue = null; 1289 Value initializerValue = null;
1254 int intValue = 0; 1290 int intValue = 0;
1255 1291
1256 EnumValue() : super(kVersions.last.size); 1292 EnumValue() : super(kVersions.last.size);
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
1332 Map map = new Map(); 1368 Map map = new Map();
1333 map["declData"] = declData; 1369 map["declData"] = declData;
1334 map["enumTypeKey"] = enumTypeKey; 1370 map["enumTypeKey"] = enumTypeKey;
1335 map["initializerValue"] = initializerValue; 1371 map["initializerValue"] = initializerValue;
1336 map["intValue"] = intValue; 1372 map["intValue"] = intValue;
1337 return map; 1373 return map;
1338 } 1374 }
1339 } 1375 }
1340 1376
1341 1377
1378
1379
1342 class MojomEnum extends bindings.Struct { 1380 class MojomEnum extends bindings.Struct {
1343 static const List<bindings.StructDataHeader> kVersions = const [ 1381 static const List<bindings.StructDataHeader> kVersions = const [
1344 const bindings.StructDataHeader(24, 0) 1382 const bindings.StructDataHeader(24, 0)
1345 ]; 1383 ];
1346 DeclarationData declData = null; 1384 DeclarationData declData = null;
1347 List<EnumValue> values = null; 1385 List<EnumValue> values = null;
1348 1386
1349 MojomEnum() : super(kVersions.last.size); 1387 MojomEnum() : super(kVersions.last.size);
1350 1388
1351 static MojomEnum deserialize(bindings.Message message) { 1389 static MojomEnum deserialize(bindings.Message message) {
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
1426 1464
1427 Map toJson() { 1465 Map toJson() {
1428 Map map = new Map(); 1466 Map map = new Map();
1429 map["declData"] = declData; 1467 map["declData"] = declData;
1430 map["values"] = values; 1468 map["values"] = values;
1431 return map; 1469 return map;
1432 } 1470 }
1433 } 1471 }
1434 1472
1435 1473
1474
1475
1436 class MojomMethod extends bindings.Struct { 1476 class MojomMethod extends bindings.Struct {
1437 static const List<bindings.StructDataHeader> kVersions = const [ 1477 static const List<bindings.StructDataHeader> kVersions = const [
1438 const bindings.StructDataHeader(40, 0) 1478 const bindings.StructDataHeader(40, 0)
1439 ]; 1479 ];
1440 DeclarationData declData = null; 1480 DeclarationData declData = null;
1441 MojomStruct parameters = null; 1481 MojomStruct parameters = null;
1442 MojomStruct responseParams = null; 1482 MojomStruct responseParams = null;
1443 int ordinal = 0; 1483 int ordinal = 0;
1444 1484
1445 MojomMethod() : super(kVersions.last.size); 1485 MojomMethod() : super(kVersions.last.size);
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after
1523 Map map = new Map(); 1563 Map map = new Map();
1524 map["declData"] = declData; 1564 map["declData"] = declData;
1525 map["parameters"] = parameters; 1565 map["parameters"] = parameters;
1526 map["responseParams"] = responseParams; 1566 map["responseParams"] = responseParams;
1527 map["ordinal"] = ordinal; 1567 map["ordinal"] = ordinal;
1528 return map; 1568 return map;
1529 } 1569 }
1530 } 1570 }
1531 1571
1532 1572
1573
1574
1533 class MojomInterface extends bindings.Struct { 1575 class MojomInterface extends bindings.Struct {
1534 static const List<bindings.StructDataHeader> kVersions = const [ 1576 static const List<bindings.StructDataHeader> kVersions = const [
1535 const bindings.StructDataHeader(32, 0) 1577 const bindings.StructDataHeader(32, 0)
1536 ]; 1578 ];
1537 DeclarationData declData = null; 1579 DeclarationData declData = null;
1538 String interfaceName = null; 1580 String interfaceName = null;
1539 Map<int, MojomMethod> methods = null; 1581 Map<int, MojomMethod> methods = null;
1540 1582
1541 MojomInterface() : super(kVersions.last.size); 1583 MojomInterface() : super(kVersions.last.size);
1542 1584
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after
1650 Map toJson() { 1692 Map toJson() {
1651 Map map = new Map(); 1693 Map map = new Map();
1652 map["declData"] = declData; 1694 map["declData"] = declData;
1653 map["interfaceName"] = interfaceName; 1695 map["interfaceName"] = interfaceName;
1654 map["methods"] = methods; 1696 map["methods"] = methods;
1655 return map; 1697 return map;
1656 } 1698 }
1657 } 1699 }
1658 1700
1659 1701
1702
1703
1660 class UserValueReference extends bindings.Struct { 1704 class UserValueReference extends bindings.Struct {
1661 static const List<bindings.StructDataHeader> kVersions = const [ 1705 static const List<bindings.StructDataHeader> kVersions = const [
1662 const bindings.StructDataHeader(40, 0) 1706 const bindings.StructDataHeader(40, 0)
1663 ]; 1707 ];
1664 String identifier = null; 1708 String identifier = null;
1665 String valueKey = null; 1709 String valueKey = null;
1666 Value resolvedConcreteValue = null; 1710 Value resolvedConcreteValue = null;
1667 1711
1668 UserValueReference() : super(kVersions.last.size); 1712 UserValueReference() : super(kVersions.last.size);
1669 1713
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
1735 Map toJson() { 1779 Map toJson() {
1736 Map map = new Map(); 1780 Map map = new Map();
1737 map["identifier"] = identifier; 1781 map["identifier"] = identifier;
1738 map["valueKey"] = valueKey; 1782 map["valueKey"] = valueKey;
1739 map["resolvedConcreteValue"] = resolvedConcreteValue; 1783 map["resolvedConcreteValue"] = resolvedConcreteValue;
1740 return map; 1784 return map;
1741 } 1785 }
1742 } 1786 }
1743 1787
1744 1788
1789
1790
1745 class DeclaredConstant extends bindings.Struct { 1791 class DeclaredConstant extends bindings.Struct {
1746 static const List<bindings.StructDataHeader> kVersions = const [ 1792 static const List<bindings.StructDataHeader> kVersions = const [
1747 const bindings.StructDataHeader(48, 0) 1793 const bindings.StructDataHeader(48, 0)
1748 ]; 1794 ];
1749 DeclarationData declData = null; 1795 DeclarationData declData = null;
1750 Type type = null; 1796 Type type = null;
1751 Value value = null; 1797 Value value = null;
1752 1798
1753 DeclaredConstant() : super(kVersions.last.size); 1799 DeclaredConstant() : super(kVersions.last.size);
1754 1800
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
1829 Map toJson() { 1875 Map toJson() {
1830 Map map = new Map(); 1876 Map map = new Map();
1831 map["declData"] = declData; 1877 map["declData"] = declData;
1832 map["type"] = type; 1878 map["type"] = type;
1833 map["value"] = value; 1879 map["value"] = value;
1834 return map; 1880 return map;
1835 } 1881 }
1836 } 1882 }
1837 1883
1838 1884
1885
1886
1839 class Attribute extends bindings.Struct { 1887 class Attribute extends bindings.Struct {
1840 static const List<bindings.StructDataHeader> kVersions = const [ 1888 static const List<bindings.StructDataHeader> kVersions = const [
1841 const bindings.StructDataHeader(32, 0) 1889 const bindings.StructDataHeader(32, 0)
1842 ]; 1890 ];
1843 String key = null; 1891 String key = null;
1844 LiteralValue value = null; 1892 LiteralValue value = null;
1845 1893
1846 Attribute() : super(kVersions.last.size); 1894 Attribute() : super(kVersions.last.size);
1847 1895
1848 static Attribute deserialize(bindings.Message message) { 1896 static Attribute deserialize(bindings.Message message) {
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
1909 1957
1910 Map toJson() { 1958 Map toJson() {
1911 Map map = new Map(); 1959 Map map = new Map();
1912 map["key"] = key; 1960 map["key"] = key;
1913 map["value"] = value; 1961 map["value"] = value;
1914 return map; 1962 return map;
1915 } 1963 }
1916 } 1964 }
1917 1965
1918 1966
1967
1968
1919 class DeclarationData extends bindings.Struct { 1969 class DeclarationData extends bindings.Struct {
1920 static const List<bindings.StructDataHeader> kVersions = const [ 1970 static const List<bindings.StructDataHeader> kVersions = const [
1921 const bindings.StructDataHeader(72, 0) 1971 const bindings.StructDataHeader(72, 0)
1922 ]; 1972 ];
1923 List<Attribute> attributes = null; 1973 List<Attribute> attributes = null;
1924 int minVersion = -1; 1974 int minVersion = -1;
1925 int declaredOrdinal = -1; 1975 int declaredOrdinal = -1;
1926 String shortName = null; 1976 String shortName = null;
1927 String fullIdentifier = null; 1977 String fullIdentifier = null;
1928 int declarationOrder = -1; 1978 int declarationOrder = -1;
(...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after
2069 map["fullIdentifier"] = fullIdentifier; 2119 map["fullIdentifier"] = fullIdentifier;
2070 map["declarationOrder"] = declarationOrder; 2120 map["declarationOrder"] = declarationOrder;
2071 map["sourceFileInfo"] = sourceFileInfo; 2121 map["sourceFileInfo"] = sourceFileInfo;
2072 map["containedDeclarations"] = containedDeclarations; 2122 map["containedDeclarations"] = containedDeclarations;
2073 map["containerTypeKey"] = containerTypeKey; 2123 map["containerTypeKey"] = containerTypeKey;
2074 return map; 2124 return map;
2075 } 2125 }
2076 } 2126 }
2077 2127
2078 2128
2129
2130
2079 class SourceFileInfo extends bindings.Struct { 2131 class SourceFileInfo extends bindings.Struct {
2080 static const List<bindings.StructDataHeader> kVersions = const [ 2132 static const List<bindings.StructDataHeader> kVersions = const [
2081 const bindings.StructDataHeader(24, 0) 2133 const bindings.StructDataHeader(24, 0)
2082 ]; 2134 ];
2083 String fileName = null; 2135 String fileName = null;
2084 int lineNumber = 0; 2136 int lineNumber = 0;
2085 int columnNumber = 0; 2137 int columnNumber = 0;
2086 2138
2087 SourceFileInfo() : super(kVersions.last.size); 2139 SourceFileInfo() : super(kVersions.last.size);
2088 2140
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
2154 Map toJson() { 2206 Map toJson() {
2155 Map map = new Map(); 2207 Map map = new Map();
2156 map["fileName"] = fileName; 2208 map["fileName"] = fileName;
2157 map["lineNumber"] = lineNumber; 2209 map["lineNumber"] = lineNumber;
2158 map["columnNumber"] = columnNumber; 2210 map["columnNumber"] = columnNumber;
2159 return map; 2211 return map;
2160 } 2212 }
2161 } 2213 }
2162 2214
2163 2215
2216
2217
2164 class ContainedDeclarations extends bindings.Struct { 2218 class ContainedDeclarations extends bindings.Struct {
2165 static const List<bindings.StructDataHeader> kVersions = const [ 2219 static const List<bindings.StructDataHeader> kVersions = const [
2166 const bindings.StructDataHeader(24, 0) 2220 const bindings.StructDataHeader(24, 0)
2167 ]; 2221 ];
2168 List<String> enums = null; 2222 List<String> enums = null;
2169 List<String> constants = null; 2223 List<String> constants = null;
2170 2224
2171 ContainedDeclarations() : super(kVersions.last.size); 2225 ContainedDeclarations() : super(kVersions.last.size);
2172 2226
2173 static ContainedDeclarations deserialize(bindings.Message message) { 2227 static ContainedDeclarations deserialize(bindings.Message message) {
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after
2267 Map toJson() { 2321 Map toJson() {
2268 Map map = new Map(); 2322 Map map = new Map();
2269 map["enums"] = enums; 2323 map["enums"] = enums;
2270 map["constants"] = constants; 2324 map["constants"] = constants;
2271 return map; 2325 return map;
2272 } 2326 }
2273 } 2327 }
2274 2328
2275 2329
2276 2330
2331
2332
2277 enum TypeTag { 2333 enum TypeTag {
2278 simpleType, 2334 simpleType,
2279 stringType, 2335 stringType,
2280 arrayType, 2336 arrayType,
2281 mapType, 2337 mapType,
2282 handleType, 2338 handleType,
2283 typeReference, 2339 typeReference,
2284 unknown 2340 unknown
2285 } 2341 }
2286 2342
(...skipping 194 matching lines...) Expand 10 before | Expand all | Expand 10 after
2481 break; 2537 break;
2482 default: 2538 default:
2483 result += "unknown"; 2539 result += "unknown";
2484 } 2540 }
2485 result += ": $_data)"; 2541 result += ": $_data)";
2486 return result; 2542 return result;
2487 } 2543 }
2488 } 2544 }
2489 2545
2490 2546
2547
2548
2491 enum UserDefinedTypeTag { 2549 enum UserDefinedTypeTag {
2492 enumType, 2550 enumType,
2493 structType, 2551 structType,
2494 unionType, 2552 unionType,
2495 interfaceType, 2553 interfaceType,
2496 unknown 2554 unknown
2497 } 2555 }
2498 2556
2499 class UserDefinedType extends bindings.Union { 2557 class UserDefinedType extends bindings.Union {
2500 static final _tag_to_int = const { 2558 static final _tag_to_int = const {
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
2640 break; 2698 break;
2641 default: 2699 default:
2642 result += "unknown"; 2700 result += "unknown";
2643 } 2701 }
2644 result += ": $_data)"; 2702 result += ": $_data)";
2645 return result; 2703 return result;
2646 } 2704 }
2647 } 2705 }
2648 2706
2649 2707
2708
2709
2650 enum DefaultFieldValueTag { 2710 enum DefaultFieldValueTag {
2651 value, 2711 value,
2652 defaultKeyword, 2712 defaultKeyword,
2653 unknown 2713 unknown
2654 } 2714 }
2655 2715
2656 class DefaultFieldValue extends bindings.Union { 2716 class DefaultFieldValue extends bindings.Union {
2657 static final _tag_to_int = const { 2717 static final _tag_to_int = const {
2658 DefaultFieldValueTag.value: 0, 2718 DefaultFieldValueTag.value: 0,
2659 DefaultFieldValueTag.defaultKeyword: 1, 2719 DefaultFieldValueTag.defaultKeyword: 1,
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
2745 break; 2805 break;
2746 default: 2806 default:
2747 result += "unknown"; 2807 result += "unknown";
2748 } 2808 }
2749 result += ": $_data)"; 2809 result += ": $_data)";
2750 return result; 2810 return result;
2751 } 2811 }
2752 } 2812 }
2753 2813
2754 2814
2815
2816
2755 enum ValueTag { 2817 enum ValueTag {
2756 literalValue, 2818 literalValue,
2757 userValueReference, 2819 userValueReference,
2758 builtinValue, 2820 builtinValue,
2759 unknown 2821 unknown
2760 } 2822 }
2761 2823
2762 class Value extends bindings.Union { 2824 class Value extends bindings.Union {
2763 static final _tag_to_int = const { 2825 static final _tag_to_int = const {
2764 ValueTag.literalValue: 0, 2826 ValueTag.literalValue: 0,
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
2879 break; 2941 break;
2880 default: 2942 default:
2881 result += "unknown"; 2943 result += "unknown";
2882 } 2944 }
2883 result += ": $_data)"; 2945 result += ": $_data)";
2884 return result; 2946 return result;
2885 } 2947 }
2886 } 2948 }
2887 2949
2888 2950
2951
2952
2889 enum LiteralValueTag { 2953 enum LiteralValueTag {
2890 boolValue, 2954 boolValue,
2891 doubleValue, 2955 doubleValue,
2892 floatValue, 2956 floatValue,
2893 int8Value, 2957 int8Value,
2894 int16Value, 2958 int16Value,
2895 int32Value, 2959 int32Value,
2896 int64Value, 2960 int64Value,
2897 stringValue, 2961 stringValue,
2898 uint8Value, 2962 uint8Value,
(...skipping 335 matching lines...) Expand 10 before | Expand all | Expand 10 after
3234 break; 3298 break;
3235 default: 3299 default:
3236 result += "unknown"; 3300 result += "unknown";
3237 } 3301 }
3238 result += ": $_data)"; 3302 result += ": $_data)";
3239 return result; 3303 return result;
3240 } 3304 }
3241 } 3305 }
3242 3306
3243 3307
3308
3309
3244 enum UserDefinedValueTag { 3310 enum UserDefinedValueTag {
3245 enumValue, 3311 enumValue,
3246 declaredConstant, 3312 declaredConstant,
3247 unknown 3313 unknown
3248 } 3314 }
3249 3315
3250 class UserDefinedValue extends bindings.Union { 3316 class UserDefinedValue extends bindings.Union {
3251 static final _tag_to_int = const { 3317 static final _tag_to_int = const {
3252 UserDefinedValueTag.enumValue: 0, 3318 UserDefinedValueTag.enumValue: 0,
3253 UserDefinedValueTag.declaredConstant: 1, 3319 UserDefinedValueTag.declaredConstant: 1,
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
3340 result += "declaredConstant"; 3406 result += "declaredConstant";
3341 break; 3407 break;
3342 default: 3408 default:
3343 result += "unknown"; 3409 result += "unknown";
3344 } 3410 }
3345 result += ": $_data)"; 3411 result += ": $_data)";
3346 return result; 3412 return result;
3347 } 3413 }
3348 } 3414 }
3349 3415
3416
3417
3418
3419
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698