1// automatically generated by the FlatBuffers compiler, do not modify
2// ignore_for_file: unused_import, unused_field, unused_local_variable
3
4library my_game.example2;
5
6import 'dart:typed_data' show Uint8List;
7import 'package:flat_buffers/flat_buffers.dart' as fb;
8
9import 'include_test1_my_game.example2_generated.dart';
10import 'include_test2_my_game.example2_generated.dart';
11import './monster_test_my_game_generated.dart' as my_game;
12import './monster_test_my_game.example_generated.dart' as my_game_example;
13
14class Monster {
15  Monster._(this._bc, this._bcOffset);
16  factory Monster(List<int> bytes) {
17    fb.BufferContext rootRef = new fb.BufferContext.fromBytes(bytes);
18    return reader.read(rootRef, 0);
19  }
20
21  static const fb.Reader<Monster> reader = const _MonsterReader();
22
23  final fb.BufferContext _bc;
24  final int _bcOffset;
25
26
27  @override
28  String toString() {
29    return 'Monster{}';
30  }
31}
32
33class _MonsterReader extends fb.TableReader<Monster> {
34  const _MonsterReader();
35
36  @override
37  Monster createObject(fb.BufferContext bc, int offset) =>
38    new Monster._(bc, offset);
39}
40
41class MonsterObjectBuilder extends fb.ObjectBuilder {
42
43  MonsterObjectBuilder();
44
45  /// Finish building, and store into the [fbBuilder].
46  @override
47  int finish(
48    fb.Builder fbBuilder) {
49    assert(fbBuilder != null);
50
51    fbBuilder.startTable();
52    return fbBuilder.endTable();
53  }
54
55  /// Convenience method to serialize to byte list.
56  @override
57  Uint8List toBytes([String fileIdentifier]) {
58    fb.Builder fbBuilder = new fb.Builder();
59    int offset = finish(fbBuilder);
60    return fbBuilder.finish(offset, fileIdentifier);
61  }
62}
63