Class FilePart.Builder (0.27.0)

public static final class FilePart.Builder extends GeneratedMessage.Builder<FilePart.Builder> implements FilePartOrBuilder

FilePart represents the different ways files can be provided.

Protobuf type google.cloud.geminidataanalytics.v1beta.FilePart

Implements

FilePartOrBuilder

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

build()

public FilePart build()
Returns
Type Description
FilePart

buildPartial()

public FilePart buildPartial()
Returns
Type Description
FilePart

clear()

public FilePart.Builder clear()
Returns
Type Description
FilePart.Builder
Overrides

clearFile()

public FilePart.Builder clearFile()
Returns
Type Description
FilePart.Builder

clearFileWithBytes()

public FilePart.Builder clearFileWithBytes()

The raw bytes of the file.

bytes file_with_bytes = 2;

Returns
Type Description
FilePart.Builder

This builder for chaining.

clearFileWithUri()

public FilePart.Builder clearFileWithUri()

The URI pointing to the file.

string file_with_uri = 1;

Returns
Type Description
FilePart.Builder

This builder for chaining.

clearMimeType()

public FilePart.Builder clearMimeType()

Optional. The MIME type of the file.

string mime_type = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
FilePart.Builder

This builder for chaining.

clearName()

public FilePart.Builder clearName()

Optional. The name of the file.

string name = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
FilePart.Builder

This builder for chaining.

getDefaultInstanceForType()

public FilePart getDefaultInstanceForType()
Returns
Type Description
FilePart

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getFileCase()

public FilePart.FileCase getFileCase()
Returns
Type Description
FilePart.FileCase

getFileWithBytes()

public ByteString getFileWithBytes()

The raw bytes of the file.

bytes file_with_bytes = 2;

Returns
Type Description
ByteString

The fileWithBytes.

getFileWithUri()

public String getFileWithUri()

The URI pointing to the file.

string file_with_uri = 1;

Returns
Type Description
String

The fileWithUri.

getFileWithUriBytes()

public ByteString getFileWithUriBytes()

The URI pointing to the file.

string file_with_uri = 1;

Returns
Type Description
ByteString

The bytes for fileWithUri.

getMimeType()

public String getMimeType()

Optional. The MIME type of the file.

string mime_type = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
String

The mimeType.

getMimeTypeBytes()

public ByteString getMimeTypeBytes()

Optional. The MIME type of the file.

string mime_type = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ByteString

The bytes for mimeType.

getName()

public String getName()

Optional. The name of the file.

string name = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
String

The name.

getNameBytes()

public ByteString getNameBytes()

Optional. The name of the file.

string name = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ByteString

The bytes for name.

hasFileWithBytes()

public boolean hasFileWithBytes()

The raw bytes of the file.

bytes file_with_bytes = 2;

Returns
Type Description
boolean

Whether the fileWithBytes field is set.

hasFileWithUri()

public boolean hasFileWithUri()

The URI pointing to the file.

string file_with_uri = 1;

Returns
Type Description
boolean

Whether the fileWithUri field is set.

internalGetFieldAccessorTable()

protected GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(FilePart other)

public FilePart.Builder mergeFrom(FilePart other)
Parameter
Name Description
other FilePart
Returns
Type Description
FilePart.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public FilePart.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
FilePart.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public FilePart.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
FilePart.Builder
Overrides

setFileWithBytes(ByteString value)

public FilePart.Builder setFileWithBytes(ByteString value)

The raw bytes of the file.

bytes file_with_bytes = 2;

Parameter
Name Description
value ByteString

The fileWithBytes to set.

Returns
Type Description
FilePart.Builder

This builder for chaining.

setFileWithUri(String value)

public FilePart.Builder setFileWithUri(String value)

The URI pointing to the file.

string file_with_uri = 1;

Parameter
Name Description
value String

The fileWithUri to set.

Returns
Type Description
FilePart.Builder

This builder for chaining.

setFileWithUriBytes(ByteString value)

public FilePart.Builder setFileWithUriBytes(ByteString value)

The URI pointing to the file.

string file_with_uri = 1;

Parameter
Name Description
value ByteString

The bytes for fileWithUri to set.

Returns
Type Description
FilePart.Builder

This builder for chaining.

setMimeType(String value)

public FilePart.Builder setMimeType(String value)

Optional. The MIME type of the file.

string mime_type = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value String

The mimeType to set.

Returns
Type Description
FilePart.Builder

This builder for chaining.

setMimeTypeBytes(ByteString value)

public FilePart.Builder setMimeTypeBytes(ByteString value)

Optional. The MIME type of the file.

string mime_type = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value ByteString

The bytes for mimeType to set.

Returns
Type Description
FilePart.Builder

This builder for chaining.

setName(String value)

public FilePart.Builder setName(String value)

Optional. The name of the file.

string name = 4 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value String

The name to set.

Returns
Type Description
FilePart.Builder

This builder for chaining.

setNameBytes(ByteString value)

public FilePart.Builder setNameBytes(ByteString value)

Optional. The name of the file.

string name = 4 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value ByteString

The bytes for name to set.

Returns
Type Description
FilePart.Builder

This builder for chaining.