Class StorageError.Builder (2.47.0)

public static final class StorageError.Builder extends GeneratedMessageV3.Builder<StorageError.Builder> implements StorageErrorOrBuilder

Structured custom BigQuery Storage error message. The error can be attached as error details in the returned rpc Status. In particular, the use of error codes allows more structured error handling, and reduces the need to evaluate unstructured error text strings.

Protobuf type google.cloud.bigquery.storage.v1beta2.StorageError

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public StorageError.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
StorageError.Builder
Overrides

build()

public StorageError build()
Returns
TypeDescription
StorageError

buildPartial()

public StorageError buildPartial()
Returns
TypeDescription
StorageError

clear()

public StorageError.Builder clear()
Returns
TypeDescription
StorageError.Builder
Overrides

clearCode()

public StorageError.Builder clearCode()

BigQuery Storage specific error code.

.google.cloud.bigquery.storage.v1beta2.StorageError.StorageErrorCode code = 1;

Returns
TypeDescription
StorageError.Builder

This builder for chaining.

clearEntity()

public StorageError.Builder clearEntity()

Name of the failed entity.

string entity = 2;

Returns
TypeDescription
StorageError.Builder

This builder for chaining.

clearErrorMessage()

public StorageError.Builder clearErrorMessage()

Message that describes the error.

string error_message = 3;

Returns
TypeDescription
StorageError.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

public StorageError.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
StorageError.Builder
Overrides

clearOneof(Descriptors.OneofDescriptor oneof)

public StorageError.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
StorageError.Builder
Overrides

clone()

public StorageError.Builder clone()
Returns
TypeDescription
StorageError.Builder
Overrides

getCode()

public StorageError.StorageErrorCode getCode()

BigQuery Storage specific error code.

.google.cloud.bigquery.storage.v1beta2.StorageError.StorageErrorCode code = 1;

Returns
TypeDescription
StorageError.StorageErrorCode

The code.

getCodeValue()

public int getCodeValue()

BigQuery Storage specific error code.

.google.cloud.bigquery.storage.v1beta2.StorageError.StorageErrorCode code = 1;

Returns
TypeDescription
int

The enum numeric value on the wire for code.

getDefaultInstanceForType()

public StorageError getDefaultInstanceForType()
Returns
TypeDescription
StorageError

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getEntity()

public String getEntity()

Name of the failed entity.

string entity = 2;

Returns
TypeDescription
String

The entity.

getEntityBytes()

public ByteString getEntityBytes()

Name of the failed entity.

string entity = 2;

Returns
TypeDescription
ByteString

The bytes for entity.

getErrorMessage()

public String getErrorMessage()

Message that describes the error.

string error_message = 3;

Returns
TypeDescription
String

The errorMessage.

getErrorMessageBytes()

public ByteString getErrorMessageBytes()

Message that describes the error.

string error_message = 3;

Returns
TypeDescription
ByteString

The bytes for errorMessage.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(StorageError other)

public StorageError.Builder mergeFrom(StorageError other)
Parameter
NameDescription
otherStorageError
Returns
TypeDescription
StorageError.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public StorageError.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
StorageError.Builder
Overrides
Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public StorageError.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
StorageError.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final StorageError.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
StorageError.Builder
Overrides

setCode(StorageError.StorageErrorCode value)

public StorageError.Builder setCode(StorageError.StorageErrorCode value)

BigQuery Storage specific error code.

.google.cloud.bigquery.storage.v1beta2.StorageError.StorageErrorCode code = 1;

Parameter
NameDescription
valueStorageError.StorageErrorCode

The code to set.

Returns
TypeDescription
StorageError.Builder

This builder for chaining.

setCodeValue(int value)

public StorageError.Builder setCodeValue(int value)

BigQuery Storage specific error code.

.google.cloud.bigquery.storage.v1beta2.StorageError.StorageErrorCode code = 1;

Parameter
NameDescription
valueint

The enum numeric value on the wire for code to set.

Returns
TypeDescription
StorageError.Builder

This builder for chaining.

setEntity(String value)

public StorageError.Builder setEntity(String value)

Name of the failed entity.

string entity = 2;

Parameter
NameDescription
valueString

The entity to set.

Returns
TypeDescription
StorageError.Builder

This builder for chaining.

setEntityBytes(ByteString value)

public StorageError.Builder setEntityBytes(ByteString value)

Name of the failed entity.

string entity = 2;

Parameter
NameDescription
valueByteString

The bytes for entity to set.

Returns
TypeDescription
StorageError.Builder

This builder for chaining.

setErrorMessage(String value)

public StorageError.Builder setErrorMessage(String value)

Message that describes the error.

string error_message = 3;

Parameter
NameDescription
valueString

The errorMessage to set.

Returns
TypeDescription
StorageError.Builder

This builder for chaining.

setErrorMessageBytes(ByteString value)

public StorageError.Builder setErrorMessageBytes(ByteString value)

Message that describes the error.

string error_message = 3;

Parameter
NameDescription
valueByteString

The bytes for errorMessage to set.

Returns
TypeDescription
StorageError.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

public StorageError.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
StorageError.Builder
Overrides

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public StorageError.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
StorageError.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final StorageError.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
StorageError.Builder
Overrides