Class Image.Builder (0.25.0)

public static final class Image.Builder extends GeneratedMessage.Builder<Image.Builder> implements ImageOrBuilder

Product image represented as bytes directly or a URI.

Protobuf type google.shopping.merchant.productstudio.v1alpha.Image

Implements

ImageOrBuilder

Static Methods

getDescriptor()

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

Methods

build()

public Image build()
Returns
Type Description
Image

buildPartial()

public Image buildPartial()
Returns
Type Description
Image

clear()

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

clearData()

public Image.Builder clearData()

Raw bytes for the image.

bytes data = 2;

Returns
Type Description
Image.Builder

This builder for chaining.

clearImage()

public Image.Builder clearImage()
Returns
Type Description
Image.Builder

clearUri()

public Image.Builder clearUri()

Generally web-requestable URI.

string uri = 1;

Returns
Type Description
Image.Builder

This builder for chaining.

getData()

public ByteString getData()

Raw bytes for the image.

bytes data = 2;

Returns
Type Description
ByteString

The data.

getDefaultInstanceForType()

public Image getDefaultInstanceForType()
Returns
Type Description
Image

getDescriptorForType()

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

getImageCase()

public Image.ImageCase getImageCase()
Returns
Type Description
Image.ImageCase

getUri()

public String getUri()

Generally web-requestable URI.

string uri = 1;

Returns
Type Description
String

The uri.

getUriBytes()

public ByteString getUriBytes()

Generally web-requestable URI.

string uri = 1;

Returns
Type Description
ByteString

The bytes for uri.

hasData()

public boolean hasData()

Raw bytes for the image.

bytes data = 2;

Returns
Type Description
boolean

Whether the data field is set.

hasUri()

public boolean hasUri()

Generally web-requestable URI.

string uri = 1;

Returns
Type Description
boolean

Whether the uri field is set.

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeFrom(Image other)

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

setData(ByteString value)

public Image.Builder setData(ByteString value)

Raw bytes for the image.

bytes data = 2;

Parameter
Name Description
value ByteString

The data to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setUri(String value)

public Image.Builder setUri(String value)

Generally web-requestable URI.

string uri = 1;

Parameter
Name Description
value String

The uri to set.

Returns
Type Description
Image.Builder

This builder for chaining.

setUriBytes(ByteString value)

public Image.Builder setUriBytes(ByteString value)

Generally web-requestable URI.

string uri = 1;

Parameter
Name Description
value ByteString

The bytes for uri to set.

Returns
Type Description
Image.Builder

This builder for chaining.