public com.dremio.common.types.TypeProtos.MajorType build() { com.dremio.common.types.TypeProtos.MajorType result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; }
public static Builder newBuilder(com.dremio.common.types.TypeProtos.MajorType prototype) { return newBuilder().mergeFrom(prototype); } public Builder toBuilder() { return newBuilder(this); }
public static MajorType withMode(final MinorType type, final DataMode mode) { return MajorType.newBuilder().setMode(mode).setMinorType(type).build(); }
public static MajorType withScaleAndPrecision(final MinorType type, final DataMode mode, final int scale, final int precision) { return MajorType.newBuilder().setMinorType(type).setMode(mode).setScale(scale).setPrecision(precision).build(); }
public static MajorType overrideMode(final MajorType originalMajorType, final DataMode overrideMode) { return withScaleAndPrecision(originalMajorType.getMinorType(), overrideMode, originalMajorType.getScale(), originalMajorType.getPrecision()); }
public static boolean isBytesScalarType(final MajorType type) { if (type.getMode() == REPEATED) { return false; } switch(type.getMinorType()) { case FIXEDSIZEBINARY: case VARBINARY: return true; default: return false; } }
public static boolean isFixedWidthType(final MajorType type) { return isFixedWidthType(type.getMinorType()); }
public static boolean isComplex(final MajorType type) { switch(type.getMinorType()) { case LIST: case STRUCT: return true; } return false; }
public com.dremio.common.types.TypeProtos.MajorType.Builder newMessage() { return com.dremio.common.types.TypeProtos.MajorType.newBuilder(); } public java.lang.String getFieldName(int number)
/** * <code>optional .common.MinorType minor_type = 1;</code> */ public Builder clearMinorType() { bitField0_ = (bitField0_ & ~0x00000001); minorType_ = com.dremio.common.types.TypeProtos.MinorType.LATE; onChanged(); return this; }
public boolean isInitialized(com.dremio.common.types.TypeProtos.MajorType message) { return message.isInitialized(); } public java.lang.String getFieldName(int number)
public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { return getDescriptor(); } public static final com.google.protobuf.Descriptors.EnumDescriptor
public java.lang.String getFieldName(int number) { return com.dremio.common.types.SchemaTypeProtos.MajorType.getFieldName(number); } public int getFieldNumber(java.lang.String name)
public int getFieldNumber(java.lang.String name) { return com.dremio.common.types.SchemaTypeProtos.MajorType.getFieldNumber(name); } public java.lang.Class<com.dremio.common.types.TypeProtos.MajorType.Builder> typeClass()
public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { return getDescriptor(); } public static final com.google.protobuf.Descriptors.EnumDescriptor
@java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessage.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /**
public static MajorType required(final MinorType type) { return MajorType.newBuilder().setMode(DataMode.REQUIRED).setMinorType(type).build(); }
/** * <code>optional .common.DataMode mode = 2;</code> */ public Builder clearMode() { bitField0_ = (bitField0_ & ~0x00000002); mode_ = com.dremio.common.types.TypeProtos.DataMode.OPTIONAL; onChanged(); return this; }
public static MajorType repeated(final MinorType type) { return MajorType.newBuilder().setMode(REPEATED).setMinorType(type).build(); }