Class ImageComponent.Builder (2.45.1)

public static final class ImageComponent.Builder extends GeneratedMessageV3.Builder<ImageComponent.Builder> implements ImageComponentOrBuilder

Represents an image.

Google Workspace Add-ons and Chat apps:

Protobuf type google.apps.card.v1.ImageComponent

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public ImageComponent.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
ImageComponent.Builder
Overrides

build()

public ImageComponent build()
Returns
Type Description
ImageComponent

buildPartial()

public ImageComponent buildPartial()
Returns
Type Description
ImageComponent

clear()

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

clearAltText()

public ImageComponent.Builder clearAltText()

The accessibility label for the image.

string alt_text = 2;

Returns
Type Description
ImageComponent.Builder

This builder for chaining.

clearBorderStyle()

public ImageComponent.Builder clearBorderStyle()

The border style to apply to the image.

.google.apps.card.v1.BorderStyle border_style = 4;

Returns
Type Description
ImageComponent.Builder

clearCropStyle()

public ImageComponent.Builder clearCropStyle()

The crop style to apply to the image.

.google.apps.card.v1.ImageCropStyle crop_style = 3;

Returns
Type Description
ImageComponent.Builder

clearField(Descriptors.FieldDescriptor field)

public ImageComponent.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
ImageComponent.Builder
Overrides

clearImageUri()

public ImageComponent.Builder clearImageUri()

The image URL.

string image_uri = 1;

Returns
Type Description
ImageComponent.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public ImageComponent.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
ImageComponent.Builder
Overrides

clone()

public ImageComponent.Builder clone()
Returns
Type Description
ImageComponent.Builder
Overrides

getAltText()

public String getAltText()

The accessibility label for the image.

string alt_text = 2;

Returns
Type Description
String

The altText.

getAltTextBytes()

public ByteString getAltTextBytes()

The accessibility label for the image.

string alt_text = 2;

Returns
Type Description
ByteString

The bytes for altText.

getBorderStyle()

public BorderStyle getBorderStyle()

The border style to apply to the image.

.google.apps.card.v1.BorderStyle border_style = 4;

Returns
Type Description
BorderStyle

The borderStyle.

getBorderStyleBuilder()

public BorderStyle.Builder getBorderStyleBuilder()

The border style to apply to the image.

.google.apps.card.v1.BorderStyle border_style = 4;

Returns
Type Description
BorderStyle.Builder

getBorderStyleOrBuilder()

public BorderStyleOrBuilder getBorderStyleOrBuilder()

The border style to apply to the image.

.google.apps.card.v1.BorderStyle border_style = 4;

Returns
Type Description
BorderStyleOrBuilder

getCropStyle()

public ImageCropStyle getCropStyle()

The crop style to apply to the image.

.google.apps.card.v1.ImageCropStyle crop_style = 3;

Returns
Type Description
ImageCropStyle

The cropStyle.

getCropStyleBuilder()

public ImageCropStyle.Builder getCropStyleBuilder()

The crop style to apply to the image.

.google.apps.card.v1.ImageCropStyle crop_style = 3;

Returns
Type Description
ImageCropStyle.Builder

getCropStyleOrBuilder()

public ImageCropStyleOrBuilder getCropStyleOrBuilder()

The crop style to apply to the image.

.google.apps.card.v1.ImageCropStyle crop_style = 3;

Returns
Type Description
ImageCropStyleOrBuilder

getDefaultInstanceForType()

public ImageComponent getDefaultInstanceForType()
Returns
Type Description
ImageComponent

getDescriptorForType()

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

getImageUri()

public String getImageUri()

The image URL.

string image_uri = 1;

Returns
Type Description
String

The imageUri.

getImageUriBytes()

public ByteString getImageUriBytes()

The image URL.

string image_uri = 1;

Returns
Type Description
ByteString

The bytes for imageUri.

hasBorderStyle()

public boolean hasBorderStyle()

The border style to apply to the image.

.google.apps.card.v1.BorderStyle border_style = 4;

Returns
Type Description
boolean

Whether the borderStyle field is set.

hasCropStyle()

public boolean hasCropStyle()

The crop style to apply to the image.

.google.apps.card.v1.ImageCropStyle crop_style = 3;

Returns
Type Description
boolean

Whether the cropStyle field is set.

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeBorderStyle(BorderStyle value)

public ImageComponent.Builder mergeBorderStyle(BorderStyle value)

The border style to apply to the image.

.google.apps.card.v1.BorderStyle border_style = 4;

Parameter
Name Description
value BorderStyle
Returns
Type Description
ImageComponent.Builder

mergeCropStyle(ImageCropStyle value)

public ImageComponent.Builder mergeCropStyle(ImageCropStyle value)

The crop style to apply to the image.

.google.apps.card.v1.ImageCropStyle crop_style = 3;

Parameter
Name Description
value ImageCropStyle
Returns
Type Description
ImageComponent.Builder

mergeFrom(ImageComponent other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeUnknownFields(UnknownFieldSet unknownFields)

public final ImageComponent.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
ImageComponent.Builder
Overrides

setAltText(String value)

public ImageComponent.Builder setAltText(String value)

The accessibility label for the image.

string alt_text = 2;

Parameter
Name Description
value String

The altText to set.

Returns
Type Description
ImageComponent.Builder

This builder for chaining.

setAltTextBytes(ByteString value)

public ImageComponent.Builder setAltTextBytes(ByteString value)

The accessibility label for the image.

string alt_text = 2;

Parameter
Name Description
value ByteString

The bytes for altText to set.

Returns
Type Description
ImageComponent.Builder

This builder for chaining.

setBorderStyle(BorderStyle value)

public ImageComponent.Builder setBorderStyle(BorderStyle value)

The border style to apply to the image.

.google.apps.card.v1.BorderStyle border_style = 4;

Parameter
Name Description
value BorderStyle
Returns
Type Description
ImageComponent.Builder

setBorderStyle(BorderStyle.Builder builderForValue)

public ImageComponent.Builder setBorderStyle(BorderStyle.Builder builderForValue)

The border style to apply to the image.

.google.apps.card.v1.BorderStyle border_style = 4;

Parameter
Name Description
builderForValue BorderStyle.Builder
Returns
Type Description
ImageComponent.Builder

setCropStyle(ImageCropStyle value)

public ImageComponent.Builder setCropStyle(ImageCropStyle value)

The crop style to apply to the image.

.google.apps.card.v1.ImageCropStyle crop_style = 3;

Parameter
Name Description
value ImageCropStyle
Returns
Type Description
ImageComponent.Builder

setCropStyle(ImageCropStyle.Builder builderForValue)

public ImageComponent.Builder setCropStyle(ImageCropStyle.Builder builderForValue)

The crop style to apply to the image.

.google.apps.card.v1.ImageCropStyle crop_style = 3;

Parameter
Name Description
builderForValue ImageCropStyle.Builder
Returns
Type Description
ImageComponent.Builder

setField(Descriptors.FieldDescriptor field, Object value)

public ImageComponent.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
ImageComponent.Builder
Overrides

setImageUri(String value)

public ImageComponent.Builder setImageUri(String value)

The image URL.

string image_uri = 1;

Parameter
Name Description
value String

The imageUri to set.

Returns
Type Description
ImageComponent.Builder

This builder for chaining.

setImageUriBytes(ByteString value)

public ImageComponent.Builder setImageUriBytes(ByteString value)

The image URL.

string image_uri = 1;

Parameter
Name Description
value ByteString

The bytes for imageUri to set.

Returns
Type Description
ImageComponent.Builder

This builder for chaining.

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

public ImageComponent.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
ImageComponent.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final ImageComponent.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
ImageComponent.Builder
Overrides