blob: 5c2fae3e8747f4038f2e45b1ce1a682d05b7a04b [file] [log] [blame]
James Kuszmaul8e62b022022-03-22 09:33:25 -07001// automatically generated by the FlatBuffers compiler, do not modify
2
3import java.nio.*;
4import java.lang.*;
5import java.util.*;
6import com.google.flatbuffers.*;
7
8@SuppressWarnings("unused")
9public final class FallingTub extends Struct {
10 public void __init(int _i, ByteBuffer _bb) { __reset(_i, _bb); }
11 public FallingTub __assign(int _i, ByteBuffer _bb) { __init(_i, _bb); return this; }
12
13 public int weight() { return bb.getInt(bb_pos + 0); }
14 public void mutateWeight(int weight) { bb.putInt(bb_pos + 0, weight); }
15
16 public static int createFallingTub(FlatBufferBuilder builder, int weight) {
17 builder.prep(4, 4);
18 builder.putInt(weight);
19 return builder.offset();
20 }
21
22 public static final class Vector extends BaseVector {
23 public Vector __assign(int _vector, int _element_size, ByteBuffer _bb) { __reset(_vector, _element_size, _bb); return this; }
24
25 public FallingTub get(int j) { return get(new FallingTub(), j); }
26 public FallingTub get(FallingTub obj, int j) { return obj.__assign(__element(j), bb); }
27 }
28 public FallingTubT unpack() {
29 FallingTubT _o = new FallingTubT();
30 unpackTo(_o);
31 return _o;
32 }
33 public void unpackTo(FallingTubT _o) {
34 int _oWeight = weight();
35 _o.setWeight(_oWeight);
36 }
37 public static int pack(FlatBufferBuilder builder, FallingTubT _o) {
38 if (_o == null) return 0;
39 return createFallingTub(
40 builder,
41 _o.getWeight());
42 }
43}
44