io.deephaven.barrage.flatbuf.BarrageSnapshotOptions Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of barrage-format Show documentation
Show all versions of barrage-format Show documentation
Generated Java files from the IPC Flatbuffer definitions.
The newest version!
// automatically generated by the FlatBuffers compiler, do not modify
package io.deephaven.barrage.flatbuf;
import java.nio.*;
import java.lang.*;
import java.util.*;
import com.google.flatbuffers.*;
@SuppressWarnings("unused")
public final class BarrageSnapshotOptions extends Table {
public static void ValidateVersion() { Constants.FLATBUFFERS_1_12_0(); }
public static BarrageSnapshotOptions getRootAsBarrageSnapshotOptions(ByteBuffer _bb) { return getRootAsBarrageSnapshotOptions(_bb, new BarrageSnapshotOptions()); }
public static BarrageSnapshotOptions getRootAsBarrageSnapshotOptions(ByteBuffer _bb, BarrageSnapshotOptions obj) { _bb.order(ByteOrder.LITTLE_ENDIAN); return (obj.__assign(_bb.getInt(_bb.position()) + _bb.position(), _bb)); }
public void __init(int _i, ByteBuffer _bb) { __reset(_i, _bb); }
public BarrageSnapshotOptions __assign(int _i, ByteBuffer _bb) { __init(_i, _bb); return this; }
/**
* see enum for details
*/
public byte columnConversionMode() { int o = __offset(4); return o != 0 ? bb.get(o + bb_pos) : 1; }
/**
* Deephaven reserves a value in the range of primitives as a custom NULL value. This enables more efficient transmission
* by eliminating the additional complexity of the validity buffer.
*/
public boolean useDeephavenNulls() { int o = __offset(6); return o != 0 ? 0!=bb.get(o + bb_pos) : false; }
/**
* Specify a preferred batch size. Server is allowed to be configured to restrict possible values. Too small of a
* batch size may be dominated with header costs as each batch is wrapped into a separate RecordBatch. Too large of
* a payload and it may not fit within the maximum payload size. A good default might be 4096.
*/
public int batchSize() { int o = __offset(8); return o != 0 ? bb.getInt(o + bb_pos) : 0; }
/**
* Specify a maximum allowed message size. Server will enforce this limit by reducing batch size (to a lower limit
* of one row per batch). If the message size limit cannot be met due to large row sizes, the server will throw a
* `Status.RESOURCE_EXHAUSTED` exception
*/
public int maxMessageSize() { int o = __offset(10); return o != 0 ? bb.getInt(o + bb_pos) : 0; }
public static int createBarrageSnapshotOptions(FlatBufferBuilder builder,
byte column_conversion_mode,
boolean use_deephaven_nulls,
int batch_size,
int max_message_size) {
builder.startTable(4);
BarrageSnapshotOptions.addMaxMessageSize(builder, max_message_size);
BarrageSnapshotOptions.addBatchSize(builder, batch_size);
BarrageSnapshotOptions.addUseDeephavenNulls(builder, use_deephaven_nulls);
BarrageSnapshotOptions.addColumnConversionMode(builder, column_conversion_mode);
return BarrageSnapshotOptions.endBarrageSnapshotOptions(builder);
}
public static void startBarrageSnapshotOptions(FlatBufferBuilder builder) { builder.startTable(4); }
public static void addColumnConversionMode(FlatBufferBuilder builder, byte columnConversionMode) { builder.addByte(0, columnConversionMode, 1); }
public static void addUseDeephavenNulls(FlatBufferBuilder builder, boolean useDeephavenNulls) { builder.addBoolean(1, useDeephavenNulls, false); }
public static void addBatchSize(FlatBufferBuilder builder, int batchSize) { builder.addInt(2, batchSize, 0); }
public static void addMaxMessageSize(FlatBufferBuilder builder, int maxMessageSize) { builder.addInt(3, maxMessageSize, 0); }
public static int endBarrageSnapshotOptions(FlatBufferBuilder builder) {
int o = builder.endTable();
return o;
}
public static final class Vector extends BaseVector {
public Vector __assign(int _vector, int _element_size, ByteBuffer _bb) { __reset(_vector, _element_size, _bb); return this; }
public BarrageSnapshotOptions get(int j) { return get(new BarrageSnapshotOptions(), j); }
public BarrageSnapshotOptions get(BarrageSnapshotOptions obj, int j) { return obj.__assign(__indirect(__element(j), bb), bb); }
}
}