Austin Schuh | e89fa2d | 2019-08-14 20:24:23 -0700 | [diff] [blame] | 1 | // automatically generated by the FlatBuffers compiler, do not modify |
| 2 | |
| 3 | package NamespaceA; |
| 4 | |
| 5 | import java.nio.*; |
| 6 | import java.lang.*; |
| 7 | import java.util.*; |
| 8 | import com.google.flatbuffers.*; |
| 9 | |
| 10 | @SuppressWarnings("unused") |
| 11 | public final class SecondTableInA extends Table { |
James Kuszmaul | 3b15b0c | 2022-11-08 14:03:16 -0800 | [diff] [blame^] | 12 | public static void ValidateVersion() { Constants.FLATBUFFERS_22_10_26(); } |
Austin Schuh | e89fa2d | 2019-08-14 20:24:23 -0700 | [diff] [blame] | 13 | public static SecondTableInA getRootAsSecondTableInA(ByteBuffer _bb) { return getRootAsSecondTableInA(_bb, new SecondTableInA()); } |
| 14 | public static SecondTableInA getRootAsSecondTableInA(ByteBuffer _bb, SecondTableInA obj) { _bb.order(ByteOrder.LITTLE_ENDIAN); return (obj.__assign(_bb.getInt(_bb.position()) + _bb.position(), _bb)); } |
| 15 | public void __init(int _i, ByteBuffer _bb) { __reset(_i, _bb); } |
| 16 | public SecondTableInA __assign(int _i, ByteBuffer _bb) { __init(_i, _bb); return this; } |
| 17 | |
| 18 | public NamespaceC.TableInC referToC() { return referToC(new NamespaceC.TableInC()); } |
| 19 | public NamespaceC.TableInC referToC(NamespaceC.TableInC obj) { int o = __offset(4); return o != 0 ? obj.__assign(__indirect(o + bb_pos), bb) : null; } |
| 20 | |
| 21 | public static int createSecondTableInA(FlatBufferBuilder builder, |
James Kuszmaul | 8e62b02 | 2022-03-22 09:33:25 -0700 | [diff] [blame] | 22 | int referToCOffset) { |
Austin Schuh | e89fa2d | 2019-08-14 20:24:23 -0700 | [diff] [blame] | 23 | builder.startTable(1); |
James Kuszmaul | 8e62b02 | 2022-03-22 09:33:25 -0700 | [diff] [blame] | 24 | SecondTableInA.addReferToC(builder, referToCOffset); |
Austin Schuh | e89fa2d | 2019-08-14 20:24:23 -0700 | [diff] [blame] | 25 | return SecondTableInA.endSecondTableInA(builder); |
| 26 | } |
| 27 | |
| 28 | public static void startSecondTableInA(FlatBufferBuilder builder) { builder.startTable(1); } |
| 29 | public static void addReferToC(FlatBufferBuilder builder, int referToCOffset) { builder.addOffset(0, referToCOffset, 0); } |
| 30 | public static int endSecondTableInA(FlatBufferBuilder builder) { |
| 31 | int o = builder.endTable(); |
| 32 | return o; |
| 33 | } |
Austin Schuh | 272c613 | 2020-11-14 16:37:52 -0800 | [diff] [blame] | 34 | |
| 35 | public static final class Vector extends BaseVector { |
| 36 | public Vector __assign(int _vector, int _element_size, ByteBuffer _bb) { __reset(_vector, _element_size, _bb); return this; } |
| 37 | |
| 38 | public SecondTableInA get(int j) { return get(new SecondTableInA(), j); } |
| 39 | public SecondTableInA get(SecondTableInA obj, int j) { return obj.__assign(__indirect(__element(j), bb), bb); } |
| 40 | } |
James Kuszmaul | 8e62b02 | 2022-03-22 09:33:25 -0700 | [diff] [blame] | 41 | public SecondTableInAT unpack() { |
| 42 | SecondTableInAT _o = new SecondTableInAT(); |
| 43 | unpackTo(_o); |
| 44 | return _o; |
| 45 | } |
| 46 | public void unpackTo(SecondTableInAT _o) { |
| 47 | if (referToC() != null) _o.setReferToC(referToC().unpack()); |
| 48 | else _o.setReferToC(null); |
| 49 | } |
| 50 | public static int pack(FlatBufferBuilder builder, SecondTableInAT _o) { |
| 51 | if (_o == null) return 0; |
| 52 | int _refer_to_c = _o.getReferToC() == null ? 0 : NamespaceC.TableInC.pack(builder, _o.getReferToC()); |
| 53 | return createSecondTableInA( |
| 54 | builder, |
| 55 | _refer_to_c); |
| 56 | } |
Austin Schuh | e89fa2d | 2019-08-14 20:24:23 -0700 | [diff] [blame] | 57 | } |
| 58 | |