| OLD | NEW |
| 1 // WARNING: DO NOT EDIT. This file was generated by a program. | 1 // WARNING: DO NOT EDIT. This file was generated by a program. |
| 2 // See $MOJO_SDK/tools/bindings/mojom_bindings_generator.py. | 2 // See $MOJO_SDK/tools/bindings/mojom_bindings_generator.py. |
| 3 | 3 |
| 4 library types_mojom; | 4 library types_mojom; |
| 5 import 'package:mojo/bindings.dart' as bindings; | 5 import 'package:mojo/bindings.dart' as bindings; |
| 6 | 6 |
| 7 const int kOpenFlagRead = 1; | 7 const int kOpenFlagRead = 1; |
| 8 const int kOpenFlagWrite = 2; | 8 const int kOpenFlagWrite = 2; |
| 9 const int kOpenFlagCreate = 4; | 9 const int kOpenFlagCreate = 4; |
| 10 const int kOpenFlagExclusive = 8; | 10 const int kOpenFlagExclusive = 8; |
| (...skipping 226 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 237 | 237 |
| 238 class Timespec extends bindings.Struct { | 238 class Timespec extends bindings.Struct { |
| 239 static const List<bindings.StructDataHeader> kVersions = const [ | 239 static const List<bindings.StructDataHeader> kVersions = const [ |
| 240 const bindings.StructDataHeader(24, 0) | 240 const bindings.StructDataHeader(24, 0) |
| 241 ]; | 241 ]; |
| 242 int seconds = 0; | 242 int seconds = 0; |
| 243 int nanoseconds = 0; | 243 int nanoseconds = 0; |
| 244 | 244 |
| 245 Timespec() : super(kVersions.last.size); | 245 Timespec() : super(kVersions.last.size); |
| 246 | 246 |
| 247 Timespec.init( |
| 248 int this.seconds, |
| 249 int this.nanoseconds |
| 250 ) : super(kVersions.last.size); |
| 251 |
| 247 static Timespec deserialize(bindings.Message message) { | 252 static Timespec deserialize(bindings.Message message) { |
| 248 var decoder = new bindings.Decoder(message); | 253 var decoder = new bindings.Decoder(message); |
| 249 var result = decode(decoder); | 254 var result = decode(decoder); |
| 250 if (decoder.excessHandles != null) { | 255 if (decoder.excessHandles != null) { |
| 251 decoder.excessHandles.forEach((h) => h.close()); | 256 decoder.excessHandles.forEach((h) => h.close()); |
| 252 } | 257 } |
| 253 return result; | 258 return result; |
| 254 } | 259 } |
| 255 | 260 |
| 256 static Timespec decode(bindings.Decoder decoder0) { | 261 static Timespec decode(bindings.Decoder decoder0) { |
| (...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 323 | 328 |
| 324 class TimespecOrNow extends bindings.Struct { | 329 class TimespecOrNow extends bindings.Struct { |
| 325 static const List<bindings.StructDataHeader> kVersions = const [ | 330 static const List<bindings.StructDataHeader> kVersions = const [ |
| 326 const bindings.StructDataHeader(24, 0) | 331 const bindings.StructDataHeader(24, 0) |
| 327 ]; | 332 ]; |
| 328 bool now = false; | 333 bool now = false; |
| 329 Timespec timespec = null; | 334 Timespec timespec = null; |
| 330 | 335 |
| 331 TimespecOrNow() : super(kVersions.last.size); | 336 TimespecOrNow() : super(kVersions.last.size); |
| 332 | 337 |
| 338 TimespecOrNow.init( |
| 339 bool this.now, |
| 340 Timespec this.timespec |
| 341 ) : super(kVersions.last.size); |
| 342 |
| 333 static TimespecOrNow deserialize(bindings.Message message) { | 343 static TimespecOrNow deserialize(bindings.Message message) { |
| 334 var decoder = new bindings.Decoder(message); | 344 var decoder = new bindings.Decoder(message); |
| 335 var result = decode(decoder); | 345 var result = decode(decoder); |
| 336 if (decoder.excessHandles != null) { | 346 if (decoder.excessHandles != null) { |
| 337 decoder.excessHandles.forEach((h) => h.close()); | 347 decoder.excessHandles.forEach((h) => h.close()); |
| 338 } | 348 } |
| 339 return result; | 349 return result; |
| 340 } | 350 } |
| 341 | 351 |
| 342 static TimespecOrNow decode(bindings.Decoder decoder0) { | 352 static TimespecOrNow decode(bindings.Decoder decoder0) { |
| (...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 412 static const List<bindings.StructDataHeader> kVersions = const [ | 422 static const List<bindings.StructDataHeader> kVersions = const [ |
| 413 const bindings.StructDataHeader(40, 0) | 423 const bindings.StructDataHeader(40, 0) |
| 414 ]; | 424 ]; |
| 415 FileType type = null; | 425 FileType type = null; |
| 416 int size = 0; | 426 int size = 0; |
| 417 Timespec atime = null; | 427 Timespec atime = null; |
| 418 Timespec mtime = null; | 428 Timespec mtime = null; |
| 419 | 429 |
| 420 FileInformation() : super(kVersions.last.size); | 430 FileInformation() : super(kVersions.last.size); |
| 421 | 431 |
| 432 FileInformation.init( |
| 433 FileType this.type, |
| 434 int this.size, |
| 435 Timespec this.atime, |
| 436 Timespec this.mtime |
| 437 ) : super(kVersions.last.size); |
| 438 |
| 422 static FileInformation deserialize(bindings.Message message) { | 439 static FileInformation deserialize(bindings.Message message) { |
| 423 var decoder = new bindings.Decoder(message); | 440 var decoder = new bindings.Decoder(message); |
| 424 var result = decode(decoder); | 441 var result = decode(decoder); |
| 425 if (decoder.excessHandles != null) { | 442 if (decoder.excessHandles != null) { |
| 426 decoder.excessHandles.forEach((h) => h.close()); | 443 decoder.excessHandles.forEach((h) => h.close()); |
| 427 } | 444 } |
| 428 return result; | 445 return result; |
| 429 } | 446 } |
| 430 | 447 |
| 431 static FileInformation decode(bindings.Decoder decoder0) { | 448 static FileInformation decode(bindings.Decoder decoder0) { |
| (...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 530 | 547 |
| 531 class DirectoryEntry extends bindings.Struct { | 548 class DirectoryEntry extends bindings.Struct { |
| 532 static const List<bindings.StructDataHeader> kVersions = const [ | 549 static const List<bindings.StructDataHeader> kVersions = const [ |
| 533 const bindings.StructDataHeader(24, 0) | 550 const bindings.StructDataHeader(24, 0) |
| 534 ]; | 551 ]; |
| 535 FileType type = null; | 552 FileType type = null; |
| 536 String name = null; | 553 String name = null; |
| 537 | 554 |
| 538 DirectoryEntry() : super(kVersions.last.size); | 555 DirectoryEntry() : super(kVersions.last.size); |
| 539 | 556 |
| 557 DirectoryEntry.init( |
| 558 FileType this.type, |
| 559 String this.name |
| 560 ) : super(kVersions.last.size); |
| 561 |
| 540 static DirectoryEntry deserialize(bindings.Message message) { | 562 static DirectoryEntry deserialize(bindings.Message message) { |
| 541 var decoder = new bindings.Decoder(message); | 563 var decoder = new bindings.Decoder(message); |
| 542 var result = decode(decoder); | 564 var result = decode(decoder); |
| 543 if (decoder.excessHandles != null) { | 565 if (decoder.excessHandles != null) { |
| 544 decoder.excessHandles.forEach((h) => h.close()); | 566 decoder.excessHandles.forEach((h) => h.close()); |
| 545 } | 567 } |
| 546 return result; | 568 return result; |
| 547 } | 569 } |
| 548 | 570 |
| 549 static DirectoryEntry decode(bindings.Decoder decoder0) { | 571 static DirectoryEntry decode(bindings.Decoder decoder0) { |
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 612 Map toJson() { | 634 Map toJson() { |
| 613 Map map = new Map(); | 635 Map map = new Map(); |
| 614 map["type"] = type; | 636 map["type"] = type; |
| 615 map["name"] = name; | 637 map["name"] = name; |
| 616 return map; | 638 return map; |
| 617 } | 639 } |
| 618 } | 640 } |
| 619 | 641 |
| 620 | 642 |
| 621 | 643 |
| OLD | NEW |