Class FileInputSource.Builder (2.33.0)

public static final class FileInputSource.Builder extends GeneratedMessageV3.Builder<FileInputSource.Builder> implements FileInputSourceOrBuilder

An inlined file.

Protobuf type google.cloud.translation.v3.FileInputSource

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public FileInputSource build()
Returns
TypeDescription
FileInputSource

buildPartial()

public FileInputSource buildPartial()
Returns
TypeDescription
FileInputSource

clear()

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

clearContent()

public FileInputSource.Builder clearContent()

Required. The file's byte contents.

bytes content = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
FileInputSource.Builder

This builder for chaining.

clearDisplayName()

public FileInputSource.Builder clearDisplayName()

Required. The file's display name.

string display_name = 3 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
FileInputSource.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

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

clearMimeType()

public FileInputSource.Builder clearMimeType()

Required. The file's mime type.

string mime_type = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
FileInputSource.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

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

clone()

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

getContent()

public ByteString getContent()

Required. The file's byte contents.

bytes content = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
ByteString

The content.

getDefaultInstanceForType()

public FileInputSource getDefaultInstanceForType()
Returns
TypeDescription
FileInputSource

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getDisplayName()

public String getDisplayName()

Required. The file's display name.

string display_name = 3 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
String

The displayName.

getDisplayNameBytes()

public ByteString getDisplayNameBytes()

Required. The file's display name.

string display_name = 3 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
ByteString

The bytes for displayName.

getMimeType()

public String getMimeType()

Required. The file's mime type.

string mime_type = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
String

The mimeType.

getMimeTypeBytes()

public ByteString getMimeTypeBytes()

Required. The file's mime type.

string mime_type = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
ByteString

The bytes for mimeType.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(FileInputSource other)

public FileInputSource.Builder mergeFrom(FileInputSource other)
Parameter
NameDescription
otherFileInputSource
Returns
TypeDescription
FileInputSource.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeUnknownFields(UnknownFieldSet unknownFields)

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

setContent(ByteString value)

public FileInputSource.Builder setContent(ByteString value)

Required. The file's byte contents.

bytes content = 2 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valueByteString

The content to set.

Returns
TypeDescription
FileInputSource.Builder

This builder for chaining.

setDisplayName(String value)

public FileInputSource.Builder setDisplayName(String value)

Required. The file's display name.

string display_name = 3 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valueString

The displayName to set.

Returns
TypeDescription
FileInputSource.Builder

This builder for chaining.

setDisplayNameBytes(ByteString value)

public FileInputSource.Builder setDisplayNameBytes(ByteString value)

Required. The file's display name.

string display_name = 3 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valueByteString

The bytes for displayName to set.

Returns
TypeDescription
FileInputSource.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

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

setMimeType(String value)

public FileInputSource.Builder setMimeType(String value)

Required. The file's mime type.

string mime_type = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valueString

The mimeType to set.

Returns
TypeDescription
FileInputSource.Builder

This builder for chaining.

setMimeTypeBytes(ByteString value)

public FileInputSource.Builder setMimeTypeBytes(ByteString value)

Required. The file's mime type.

string mime_type = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valueByteString

The bytes for mimeType to set.

Returns
TypeDescription
FileInputSource.Builder

This builder for chaining.

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

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

setUnknownFields(UnknownFieldSet unknownFields)

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