/** * Adds the precision for a DECIMAL. * <p> * This value is required for decimals and must be less than or equal to * the maximum number of base-10 digits in the underlying type. A 4-byte * fixed, for example, can store up to 9 base-10 digits. * * @param precision an int precision value for the DECIMAL * @return this builder for method chaining * * @deprecated use {@link #as(LogicalTypeAnnotation)} with the corresponding decimal type instead */ @Deprecated public THIS precision(int precision) { this.precision = precision; precisionAlreadySet = true; return self(); }
/** * Adds the scale for a DECIMAL. * <p> * This value must be less than the maximum precision of the type and must * be a positive number. If not set, the default scale is 0. * <p> * The scale specifies the number of digits of the underlying unscaled * that are to the right of the decimal point. The decimal interpretation * of values in this column is: {@code value*10^(-scale)}. * * @param scale an int scale value for the DECIMAL * @return this builder for method chaining * * @deprecated use {@link #as(LogicalTypeAnnotation)} with the corresponding decimal type instead */ @Deprecated public THIS scale(int scale) { this.scale = scale; scaleAlreadySet = true; return self(); }
/** * Adds the scale for a DECIMAL. * <p> * This value must be less than the maximum precision of the type and must * be a positive number. If not set, the default scale is 0. * <p> * The scale specifies the number of digits of the underlying unscaled * that are to the right of the decimal point. The decimal interpretation * of values in this column is: {@code value*10^(-scale)}. * * @param scale an int scale value for the DECIMAL * @return this builder for method chaining */ public THIS scale(int scale) { this.scale = scale; return self(); }
/** * Adds the column order for the primitive type. * <p> * In case of not set the default column order is {@link ColumnOrderName#TYPE_DEFINED_ORDER} except the type * {@link PrimitiveTypeName#INT96} and the types annotated by {@link OriginalType#INTERVAL} where the default column * order is {@link ColumnOrderName#UNDEFINED}. * * @param columnOrder * the column order for the primitive type * @return this builder for method chaining */ public THIS columnOrder(ColumnOrder columnOrder) { this.columnOrder = columnOrder; return self(); }
/** * Adds the column order for the primitive type. * <p> * In case of not set the default column order is {@link ColumnOrderName#TYPE_DEFINED_ORDER} except the type * {@link PrimitiveTypeName#INT96} and the types annotated by {@link OriginalType#INTERVAL} where the default column * order is {@link ColumnOrderName#UNDEFINED}. * * @param columnOrder * the column order for the primitive type * @return this builder for method chaining */ public THIS columnOrder(ColumnOrder columnOrder) { this.columnOrder = columnOrder; return self(); }
/** * Adds the precision for a DECIMAL. * <p> * This value is required for decimals and must be less than or equal to * the maximum number of base-10 digits in the underlying type. A 4-byte * fixed, for example, can store up to 9 base-10 digits. * * @param precision an int precision value for the DECIMAL * @return this builder for method chaining */ public THIS precision(int precision) { this.precision = precision; return self(); }
/** * Adds the length for a FIXED_LEN_BYTE_ARRAY. * * @param length an int length * @return this builder for method chaining */ public THIS length(int length) { this.length = length; return self(); }
/** * Adds the length for a FIXED_LEN_BYTE_ARRAY. * * @param length an int length * @return this builder for method chaining */ public THIS length(int length) { this.length = length; return self(); }