Class BatchTranslateResponse.Builder (2.20.0)

public static final class BatchTranslateResponse.Builder extends GeneratedMessageV3.Builder<BatchTranslateResponse.Builder> implements BatchTranslateResponseOrBuilder

Stored in the google.longrunning.Operation.response field returned by BatchTranslateText if at least one sentence is translated successfully.

Protobuf type google.cloud.translation.v3beta1.BatchTranslateResponse

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public BatchTranslateResponse build()
Returns
TypeDescription
BatchTranslateResponse

buildPartial()

public BatchTranslateResponse buildPartial()
Returns
TypeDescription
BatchTranslateResponse

clear()

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

clearEndTime()

public BatchTranslateResponse.Builder clearEndTime()

The time when the operation is finished and google.longrunning.Operation.done is set to true.

.google.protobuf.Timestamp end_time = 5;

Returns
TypeDescription
BatchTranslateResponse.Builder

clearFailedCharacters()

public BatchTranslateResponse.Builder clearFailedCharacters()

Number of characters that have failed to process (Unicode codepoints).

int64 failed_characters = 3;

Returns
TypeDescription
BatchTranslateResponse.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

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

clearOneof(Descriptors.OneofDescriptor oneof)

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

clearSubmitTime()

public BatchTranslateResponse.Builder clearSubmitTime()

Time when the operation was submitted.

.google.protobuf.Timestamp submit_time = 4;

Returns
TypeDescription
BatchTranslateResponse.Builder

clearTotalCharacters()

public BatchTranslateResponse.Builder clearTotalCharacters()

Total number of characters (Unicode codepoints).

int64 total_characters = 1;

Returns
TypeDescription
BatchTranslateResponse.Builder

This builder for chaining.

clearTranslatedCharacters()

public BatchTranslateResponse.Builder clearTranslatedCharacters()

Number of successfully translated characters (Unicode codepoints).

int64 translated_characters = 2;

Returns
TypeDescription
BatchTranslateResponse.Builder

This builder for chaining.

clone()

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

getDefaultInstanceForType()

public BatchTranslateResponse getDefaultInstanceForType()
Returns
TypeDescription
BatchTranslateResponse

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getEndTime()

public Timestamp getEndTime()

The time when the operation is finished and google.longrunning.Operation.done is set to true.

.google.protobuf.Timestamp end_time = 5;

Returns
TypeDescription
Timestamp

The endTime.

getEndTimeBuilder()

public Timestamp.Builder getEndTimeBuilder()

The time when the operation is finished and google.longrunning.Operation.done is set to true.

.google.protobuf.Timestamp end_time = 5;

Returns
TypeDescription
Builder

getEndTimeOrBuilder()

public TimestampOrBuilder getEndTimeOrBuilder()

The time when the operation is finished and google.longrunning.Operation.done is set to true.

.google.protobuf.Timestamp end_time = 5;

Returns
TypeDescription
TimestampOrBuilder

getFailedCharacters()

public long getFailedCharacters()

Number of characters that have failed to process (Unicode codepoints).

int64 failed_characters = 3;

Returns
TypeDescription
long

The failedCharacters.

getSubmitTime()

public Timestamp getSubmitTime()

Time when the operation was submitted.

.google.protobuf.Timestamp submit_time = 4;

Returns
TypeDescription
Timestamp

The submitTime.

getSubmitTimeBuilder()

public Timestamp.Builder getSubmitTimeBuilder()

Time when the operation was submitted.

.google.protobuf.Timestamp submit_time = 4;

Returns
TypeDescription
Builder

getSubmitTimeOrBuilder()

public TimestampOrBuilder getSubmitTimeOrBuilder()

Time when the operation was submitted.

.google.protobuf.Timestamp submit_time = 4;

Returns
TypeDescription
TimestampOrBuilder

getTotalCharacters()

public long getTotalCharacters()

Total number of characters (Unicode codepoints).

int64 total_characters = 1;

Returns
TypeDescription
long

The totalCharacters.

getTranslatedCharacters()

public long getTranslatedCharacters()

Number of successfully translated characters (Unicode codepoints).

int64 translated_characters = 2;

Returns
TypeDescription
long

The translatedCharacters.

hasEndTime()

public boolean hasEndTime()

The time when the operation is finished and google.longrunning.Operation.done is set to true.

.google.protobuf.Timestamp end_time = 5;

Returns
TypeDescription
boolean

Whether the endTime field is set.

hasSubmitTime()

public boolean hasSubmitTime()

Time when the operation was submitted.

.google.protobuf.Timestamp submit_time = 4;

Returns
TypeDescription
boolean

Whether the submitTime field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeEndTime(Timestamp value)

public BatchTranslateResponse.Builder mergeEndTime(Timestamp value)

The time when the operation is finished and google.longrunning.Operation.done is set to true.

.google.protobuf.Timestamp end_time = 5;

Parameter
NameDescription
valueTimestamp
Returns
TypeDescription
BatchTranslateResponse.Builder

mergeFrom(BatchTranslateResponse other)

public BatchTranslateResponse.Builder mergeFrom(BatchTranslateResponse other)
Parameter
NameDescription
otherBatchTranslateResponse
Returns
TypeDescription
BatchTranslateResponse.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeSubmitTime(Timestamp value)

public BatchTranslateResponse.Builder mergeSubmitTime(Timestamp value)

Time when the operation was submitted.

.google.protobuf.Timestamp submit_time = 4;

Parameter
NameDescription
valueTimestamp
Returns
TypeDescription
BatchTranslateResponse.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

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

setEndTime(Timestamp value)

public BatchTranslateResponse.Builder setEndTime(Timestamp value)

The time when the operation is finished and google.longrunning.Operation.done is set to true.

.google.protobuf.Timestamp end_time = 5;

Parameter
NameDescription
valueTimestamp
Returns
TypeDescription
BatchTranslateResponse.Builder

setEndTime(Timestamp.Builder builderForValue)

public BatchTranslateResponse.Builder setEndTime(Timestamp.Builder builderForValue)

The time when the operation is finished and google.longrunning.Operation.done is set to true.

.google.protobuf.Timestamp end_time = 5;

Parameter
NameDescription
builderForValueBuilder
Returns
TypeDescription
BatchTranslateResponse.Builder

setFailedCharacters(long value)

public BatchTranslateResponse.Builder setFailedCharacters(long value)

Number of characters that have failed to process (Unicode codepoints).

int64 failed_characters = 3;

Parameter
NameDescription
valuelong

The failedCharacters to set.

Returns
TypeDescription
BatchTranslateResponse.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

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

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

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

setSubmitTime(Timestamp value)

public BatchTranslateResponse.Builder setSubmitTime(Timestamp value)

Time when the operation was submitted.

.google.protobuf.Timestamp submit_time = 4;

Parameter
NameDescription
valueTimestamp
Returns
TypeDescription
BatchTranslateResponse.Builder

setSubmitTime(Timestamp.Builder builderForValue)

public BatchTranslateResponse.Builder setSubmitTime(Timestamp.Builder builderForValue)

Time when the operation was submitted.

.google.protobuf.Timestamp submit_time = 4;

Parameter
NameDescription
builderForValueBuilder
Returns
TypeDescription
BatchTranslateResponse.Builder

setTotalCharacters(long value)

public BatchTranslateResponse.Builder setTotalCharacters(long value)

Total number of characters (Unicode codepoints).

int64 total_characters = 1;

Parameter
NameDescription
valuelong

The totalCharacters to set.

Returns
TypeDescription
BatchTranslateResponse.Builder

This builder for chaining.

setTranslatedCharacters(long value)

public BatchTranslateResponse.Builder setTranslatedCharacters(long value)

Number of successfully translated characters (Unicode codepoints).

int64 translated_characters = 2;

Parameter
NameDescription
valuelong

The translatedCharacters to set.

Returns
TypeDescription
BatchTranslateResponse.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

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