Interface RecordBuilder

All Superinterfaces: RecordAccessor


public interface RecordBuilder extends RecordAccessor

Builder for Record.

See Also: DataApi.newRecordBuilder(String)

Modifier and TypeMethodDescription
Recordbuild()Returns a new and immutable Record instance based on the information stored in this builder.
RecordBuilderwithField(java.lang.String name,boolean value)Sets the value of a field.
RecordBuilderwithField (java.lang.String name,byte value)Sets the value of a field.
RecordBuilderwithField(java.lang.String name,double value)Sets the value of a field.
RecordBuilderwithField(java.lang.String name,float value)Sets the value of a field.
RecordBuilderwithField(java.lang.String name,int value)Sets the value of a field.
RecordBuilderwithField(java.lang.String name,long value)Sets the value of a field.
RecordBuilderwithField(java.lang.String name,short value)Sets the value of a field.
RecordBuilderwithField(java.lang.String name,ReferenceId value)Sets the value of a field.
RecordBuilderwithField(java.lang.String name,java.lang.String value)Sets the value of a field.
RecordBuilderwithField(java.lang.String name,java.math.BigDecimal value)Sets the value of a field.
RecordBuilderwithField(java.lang.String name,java.math.BigInteger value)Sets the value of a field.
RecordBuilderwithNullField (java.lang.String name)Sets the value of a field to null.
RecordBuilderwithoutField (java.lang.String name)Removes a field from this record builder.

getBigDecimalField, getBigIntegerField, getBooleanField, getByteField, getDoubleField, getFieldNames, getFloatField, getIntField, getLongField, getShortField, getStringField, getType, hasField, isNullField

@Nonnull Record build()

Returns a new and immutable Record instance based on the information stored in this builder.

Returns: The new Record instance.

@Nonnull RecordBuilder withoutField​(java.lang.String name)

Removes a field from this record builder.

It will remove the field entirely and will not set it to null. To set a field's value to null, use withNullField(String).

Parameters: name - The name of the field. Returns: This RecordBuilder instance to allow method chaining.

@Nonnull RecordBuilder withNullField​(java.lang.String name)

Sets the value of a field to null.

Parameters: name - The name of the field. Returns: This RecordBuilder instance to allow method chaining.

@Nonnull RecordBuilder withField​(java.lang.String name, @Nullable java.lang.String value)

Sets the value of a field.

Parameters: name - The name of the field. value - The value to set. Returns: This RecordBuilder instance to allow method chaining.

@Nonnull RecordBuilder withField​(java.lang.String name, short value)

Sets the value of a field.

Parameters: name - The name of the field. value - The value to set. Returns: This RecordBuilder instance to allow method chaining.

@Nonnull RecordBuilder withField​(java.lang.String name, long value)

Sets the value of a field.

Parameters: name - The name of the field. value - The value to set. Returns: This RecordBuilder instance to allow method chaining.

@Nonnull RecordBuilder withField​(java.lang.String name, int value)

Sets the value of a field.

Parameters: name - The name of the field. value - The value to set. Returns: This RecordBuilder instance to allow method chaining.

@Nonnull RecordBuilder withField​(java.lang.String name, float value)

Sets the value of a field.

Parameters: name - The name of the field. value - The value to set. Returns: This RecordBuilder instance to allow method chaining.

@Nonnull RecordBuilder withField​(java.lang.String name, double value)

Sets the value of a field.

Parameters: name - The name of the field. value - The value to set. Returns: This RecordBuilder instance to allow method chaining.

@Nonnull RecordBuilder withField​(java.lang.String name, byte value)

Sets the value of a field.

Parameters: name - The name of the field. value - The value to set. Returns: This RecordBuilder instance to allow method chaining.

@Nonnull RecordBuilder withField​(java.lang.String name, boolean value)

Sets the value of a field.

Parameters: name - The name of the field. value - The value to set. Returns: This RecordBuilder instance to allow method chaining.

@Nonnull RecordBuilder withField​(java.lang.String name, @Nullable java.math.BigInteger value)

Sets the value of a field.

Parameters: name - The name of the field. value - The value to set. Returns: This RecordBuilder instance to allow method chaining.

@Nonnull RecordBuilder withField​(java.lang.String name, @Nullable java.math.BigDecimal value)

Sets the value of a field.

Parameters: name - The name of the field. value - The value to set. Returns: This RecordBuilder instance to allow method chaining.

@Nonnull RecordBuilder withField​(java.lang.String name, @Nullable ReferenceId value)

Sets the value of a field.

Parameters: name - The name of the field. value - The value to set. Returns: This RecordBuilder instance to allow method chaining.