us.dustinj.timezonemap.serialization.flatbuffer.Polygon Maven / Gradle / Ivy
// automatically generated by the FlatBuffers compiler, do not modify
package us.dustinj.timezonemap.serialization.flatbuffer;
import java.nio.*;
import java.lang.*;
import java.util.*;
import com.google.flatbuffers.*;
@SuppressWarnings("unused")
public final class Polygon extends Table {
public static Polygon getRootAsPolygon(ByteBuffer _bb) { return getRootAsPolygon(_bb, new Polygon()); }
public static Polygon getRootAsPolygon(ByteBuffer _bb, Polygon obj) { _bb.order(ByteOrder.LITTLE_ENDIAN); return (obj.__assign(_bb.getInt(_bb.position()) + _bb.position(), _bb)); }
public void __init(int _i, ByteBuffer _bb) { bb_pos = _i; bb = _bb; }
public Polygon __assign(int _i, ByteBuffer _bb) { __init(_i, _bb); return this; }
public Ring rings(int j) { return rings(new Ring(), j); }
public Ring rings(Ring obj, int j) { int o = __offset(4); return o != 0 ? obj.__assign(__indirect(__vector(o) + j * 4), bb) : null; }
public int ringsLength() { int o = __offset(4); return o != 0 ? __vector_len(o) : 0; }
public static int createPolygon(FlatBufferBuilder builder,
int ringsOffset) {
builder.startObject(1);
Polygon.addRings(builder, ringsOffset);
return Polygon.endPolygon(builder);
}
public static void startPolygon(FlatBufferBuilder builder) { builder.startObject(1); }
public static void addRings(FlatBufferBuilder builder, int ringsOffset) { builder.addOffset(0, ringsOffset, 0); }
public static int createRingsVector(FlatBufferBuilder builder, int[] data) { builder.startVector(4, data.length, 4); for (int i = data.length - 1; i >= 0; i--) builder.addOffset(data[i]); return builder.endVector(); }
public static void startRingsVector(FlatBufferBuilder builder, int numElems) { builder.startVector(4, numElems, 4); }
public static int endPolygon(FlatBufferBuilder builder) {
int o = builder.endObject();
return o;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy