Class DominantColorsAnnotation.Builder (3.50.0)

public static final class DominantColorsAnnotation.Builder extends GeneratedMessageV3.Builder<DominantColorsAnnotation.Builder> implements DominantColorsAnnotationOrBuilder

Set of dominant colors and their corresponding scores.

Protobuf type google.cloud.vision.v1.DominantColorsAnnotation

Static Methods

getDescriptor()

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

Methods

addAllColors(Iterable<? extends ColorInfo> values)

public DominantColorsAnnotation.Builder addAllColors(Iterable<? extends ColorInfo> values)

RGB color values with their score and pixel fraction.

repeated .google.cloud.vision.v1.ColorInfo colors = 1;

Parameter
Name Description
values Iterable<? extends com.google.cloud.vision.v1.ColorInfo>
Returns
Type Description
DominantColorsAnnotation.Builder

addColors(ColorInfo value)

public DominantColorsAnnotation.Builder addColors(ColorInfo value)

RGB color values with their score and pixel fraction.

repeated .google.cloud.vision.v1.ColorInfo colors = 1;

Parameter
Name Description
value ColorInfo
Returns
Type Description
DominantColorsAnnotation.Builder

addColors(ColorInfo.Builder builderForValue)

public DominantColorsAnnotation.Builder addColors(ColorInfo.Builder builderForValue)

RGB color values with their score and pixel fraction.

repeated .google.cloud.vision.v1.ColorInfo colors = 1;

Parameter
Name Description
builderForValue ColorInfo.Builder
Returns
Type Description
DominantColorsAnnotation.Builder

addColors(int index, ColorInfo value)

public DominantColorsAnnotation.Builder addColors(int index, ColorInfo value)

RGB color values with their score and pixel fraction.

repeated .google.cloud.vision.v1.ColorInfo colors = 1;

Parameters
Name Description
index int
value ColorInfo
Returns
Type Description
DominantColorsAnnotation.Builder

addColors(int index, ColorInfo.Builder builderForValue)

public DominantColorsAnnotation.Builder addColors(int index, ColorInfo.Builder builderForValue)

RGB color values with their score and pixel fraction.

repeated .google.cloud.vision.v1.ColorInfo colors = 1;

Parameters
Name Description
index int
builderForValue ColorInfo.Builder
Returns
Type Description
DominantColorsAnnotation.Builder

addColorsBuilder()

public ColorInfo.Builder addColorsBuilder()

RGB color values with their score and pixel fraction.

repeated .google.cloud.vision.v1.ColorInfo colors = 1;

Returns
Type Description
ColorInfo.Builder

addColorsBuilder(int index)

public ColorInfo.Builder addColorsBuilder(int index)

RGB color values with their score and pixel fraction.

repeated .google.cloud.vision.v1.ColorInfo colors = 1;

Parameter
Name Description
index int
Returns
Type Description
ColorInfo.Builder

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public DominantColorsAnnotation build()
Returns
Type Description
DominantColorsAnnotation

buildPartial()

public DominantColorsAnnotation buildPartial()
Returns
Type Description
DominantColorsAnnotation

clear()

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

clearColors()

public DominantColorsAnnotation.Builder clearColors()

RGB color values with their score and pixel fraction.

repeated .google.cloud.vision.v1.ColorInfo colors = 1;

Returns
Type Description
DominantColorsAnnotation.Builder

clearField(Descriptors.FieldDescriptor field)

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

clearOneof(Descriptors.OneofDescriptor oneof)

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

clone()

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

getColors(int index)

public ColorInfo getColors(int index)

RGB color values with their score and pixel fraction.

repeated .google.cloud.vision.v1.ColorInfo colors = 1;

Parameter
Name Description
index int
Returns
Type Description
ColorInfo

getColorsBuilder(int index)

public ColorInfo.Builder getColorsBuilder(int index)

RGB color values with their score and pixel fraction.

repeated .google.cloud.vision.v1.ColorInfo colors = 1;

Parameter
Name Description
index int
Returns
Type Description
ColorInfo.Builder

getColorsBuilderList()

public List<ColorInfo.Builder> getColorsBuilderList()

RGB color values with their score and pixel fraction.

repeated .google.cloud.vision.v1.ColorInfo colors = 1;

Returns
Type Description
List<Builder>

getColorsCount()

public int getColorsCount()

RGB color values with their score and pixel fraction.

repeated .google.cloud.vision.v1.ColorInfo colors = 1;

Returns
Type Description
int

getColorsList()

public List<ColorInfo> getColorsList()

RGB color values with their score and pixel fraction.

repeated .google.cloud.vision.v1.ColorInfo colors = 1;

Returns
Type Description
List<ColorInfo>

getColorsOrBuilder(int index)

public ColorInfoOrBuilder getColorsOrBuilder(int index)

RGB color values with their score and pixel fraction.

repeated .google.cloud.vision.v1.ColorInfo colors = 1;

Parameter
Name Description
index int
Returns
Type Description
ColorInfoOrBuilder

getColorsOrBuilderList()

public List<? extends ColorInfoOrBuilder> getColorsOrBuilderList()

RGB color values with their score and pixel fraction.

repeated .google.cloud.vision.v1.ColorInfo colors = 1;

Returns
Type Description
List<? extends com.google.cloud.vision.v1.ColorInfoOrBuilder>

getDefaultInstanceForType()

public DominantColorsAnnotation getDefaultInstanceForType()
Returns
Type Description
DominantColorsAnnotation

getDescriptorForType()

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

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(DominantColorsAnnotation other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeUnknownFields(UnknownFieldSet unknownFields)

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

removeColors(int index)

public DominantColorsAnnotation.Builder removeColors(int index)

RGB color values with their score and pixel fraction.

repeated .google.cloud.vision.v1.ColorInfo colors = 1;

Parameter
Name Description
index int
Returns
Type Description
DominantColorsAnnotation.Builder

setColors(int index, ColorInfo value)

public DominantColorsAnnotation.Builder setColors(int index, ColorInfo value)

RGB color values with their score and pixel fraction.

repeated .google.cloud.vision.v1.ColorInfo colors = 1;

Parameters
Name Description
index int
value ColorInfo
Returns
Type Description
DominantColorsAnnotation.Builder

setColors(int index, ColorInfo.Builder builderForValue)

public DominantColorsAnnotation.Builder setColors(int index, ColorInfo.Builder builderForValue)

RGB color values with their score and pixel fraction.

repeated .google.cloud.vision.v1.ColorInfo colors = 1;

Parameters
Name Description
index int
builderForValue ColorInfo.Builder
Returns
Type Description
DominantColorsAnnotation.Builder

setField(Descriptors.FieldDescriptor field, Object value)

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

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

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

setUnknownFields(UnknownFieldSet unknownFields)

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