public final class ColorInfo extends GeneratedMessageV3 implements ColorInfoOrBuilder
The color information of a Product.
Protobuf type google.cloud.retail.v2.ColorInfo
Static Fields
COLORS_FIELD_NUMBER
public static final int COLORS_FIELD_NUMBER
Field Value
COLOR_FAMILIES_FIELD_NUMBER
public static final int COLOR_FAMILIES_FIELD_NUMBER
Field Value
Static Methods
getDefaultInstance()
public static ColorInfo getDefaultInstance()
Returns
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Returns
newBuilder()
public static ColorInfo.Builder newBuilder()
Returns
newBuilder(ColorInfo prototype)
public static ColorInfo.Builder newBuilder(ColorInfo prototype)
Parameter
Returns
public static ColorInfo parseDelimitedFrom(InputStream input)
Parameter
Returns
Exceptions
public static ColorInfo parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parseFrom(byte[] data)
public static ColorInfo parseFrom(byte[] data)
Parameter
Name | Description |
data | byte[]
|
Returns
Exceptions
parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
public static ColorInfo parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parseFrom(ByteString data)
public static ColorInfo parseFrom(ByteString data)
Parameter
Returns
Exceptions
parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static ColorInfo parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
public static ColorInfo parseFrom(CodedInputStream input)
Parameter
Returns
Exceptions
public static ColorInfo parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
public static ColorInfo parseFrom(InputStream input)
Parameter
Returns
Exceptions
public static ColorInfo parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parseFrom(ByteBuffer data)
public static ColorInfo parseFrom(ByteBuffer data)
Parameter
Returns
Exceptions
parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
public static ColorInfo parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parser()
public static Parser<ColorInfo> parser()
Returns
Methods
equals(Object obj)
public boolean equals(Object obj)
Parameter
Returns
Overrides
getColorFamilies(int index)
public String getColorFamilies(int index)
The standard color families. Strongly recommended to use the following
standard color groups: "Red", "Pink", "Orange", "Yellow", "Purple",
"Green", "Cyan", "Blue", "Brown", "White", "Gray", "Black" and
"Mixed". Normally it is expected to have only 1 color family. May consider
using single "Mixed" instead of multiple values.
A maximum of 5 values are allowed. Each value must be a UTF-8 encoded
string with a length limit of 128 characters. Otherwise, an
INVALID_ARGUMENT error is returned.
Google Merchant Center property
color. Schema.org
property Product.color.
repeated string color_families = 1;
Parameter
Name | Description |
index | int
The index of the element to return.
|
Returns
Type | Description |
String | The colorFamilies at the given index.
|
getColorFamiliesBytes(int index)
public ByteString getColorFamiliesBytes(int index)
The standard color families. Strongly recommended to use the following
standard color groups: "Red", "Pink", "Orange", "Yellow", "Purple",
"Green", "Cyan", "Blue", "Brown", "White", "Gray", "Black" and
"Mixed". Normally it is expected to have only 1 color family. May consider
using single "Mixed" instead of multiple values.
A maximum of 5 values are allowed. Each value must be a UTF-8 encoded
string with a length limit of 128 characters. Otherwise, an
INVALID_ARGUMENT error is returned.
Google Merchant Center property
color. Schema.org
property Product.color.
repeated string color_families = 1;
Parameter
Name | Description |
index | int
The index of the value to return.
|
Returns
Type | Description |
ByteString | The bytes of the colorFamilies at the given index.
|
getColorFamiliesCount()
public int getColorFamiliesCount()
The standard color families. Strongly recommended to use the following
standard color groups: "Red", "Pink", "Orange", "Yellow", "Purple",
"Green", "Cyan", "Blue", "Brown", "White", "Gray", "Black" and
"Mixed". Normally it is expected to have only 1 color family. May consider
using single "Mixed" instead of multiple values.
A maximum of 5 values are allowed. Each value must be a UTF-8 encoded
string with a length limit of 128 characters. Otherwise, an
INVALID_ARGUMENT error is returned.
Google Merchant Center property
color. Schema.org
property Product.color.
repeated string color_families = 1;
Returns
Type | Description |
int | The count of colorFamilies.
|
getColorFamiliesList()
public ProtocolStringList getColorFamiliesList()
The standard color families. Strongly recommended to use the following
standard color groups: "Red", "Pink", "Orange", "Yellow", "Purple",
"Green", "Cyan", "Blue", "Brown", "White", "Gray", "Black" and
"Mixed". Normally it is expected to have only 1 color family. May consider
using single "Mixed" instead of multiple values.
A maximum of 5 values are allowed. Each value must be a UTF-8 encoded
string with a length limit of 128 characters. Otherwise, an
INVALID_ARGUMENT error is returned.
Google Merchant Center property
color. Schema.org
property Product.color.
repeated string color_families = 1;
Returns
getColors(int index)
public String getColors(int index)
The color display names, which may be different from standard color family
names, such as the color aliases used in the website frontend. Normally
it is expected to have only 1 color. May consider using single "Mixed"
instead of multiple values.
A maximum of 25 colors are allowed. Each value must be a UTF-8 encoded
string with a length limit of 128 characters. Otherwise, an
INVALID_ARGUMENT error is returned.
Google Merchant Center property
color. Schema.org
property Product.color.
repeated string colors = 2;
Parameter
Name | Description |
index | int
The index of the element to return.
|
Returns
Type | Description |
String | The colors at the given index.
|
getColorsBytes(int index)
public ByteString getColorsBytes(int index)
The color display names, which may be different from standard color family
names, such as the color aliases used in the website frontend. Normally
it is expected to have only 1 color. May consider using single "Mixed"
instead of multiple values.
A maximum of 25 colors are allowed. Each value must be a UTF-8 encoded
string with a length limit of 128 characters. Otherwise, an
INVALID_ARGUMENT error is returned.
Google Merchant Center property
color. Schema.org
property Product.color.
repeated string colors = 2;
Parameter
Name | Description |
index | int
The index of the value to return.
|
Returns
Type | Description |
ByteString | The bytes of the colors at the given index.
|
getColorsCount()
public int getColorsCount()
The color display names, which may be different from standard color family
names, such as the color aliases used in the website frontend. Normally
it is expected to have only 1 color. May consider using single "Mixed"
instead of multiple values.
A maximum of 25 colors are allowed. Each value must be a UTF-8 encoded
string with a length limit of 128 characters. Otherwise, an
INVALID_ARGUMENT error is returned.
Google Merchant Center property
color. Schema.org
property Product.color.
repeated string colors = 2;
Returns
Type | Description |
int | The count of colors.
|
getColorsList()
public ProtocolStringList getColorsList()
The color display names, which may be different from standard color family
names, such as the color aliases used in the website frontend. Normally
it is expected to have only 1 color. May consider using single "Mixed"
instead of multiple values.
A maximum of 25 colors are allowed. Each value must be a UTF-8 encoded
string with a length limit of 128 characters. Otherwise, an
INVALID_ARGUMENT error is returned.
Google Merchant Center property
color. Schema.org
property Product.color.
repeated string colors = 2;
Returns
getDefaultInstanceForType()
public ColorInfo getDefaultInstanceForType()
Returns
getParserForType()
public Parser<ColorInfo> getParserForType()
Returns
Overrides
getSerializedSize()
public int getSerializedSize()
Returns
Overrides
getUnknownFields()
public final UnknownFieldSet getUnknownFields()
Returns
Overrides
hashCode()
Returns
Overrides
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Overrides
isInitialized()
public final boolean isInitialized()
Returns
Overrides
newBuilderForType()
public ColorInfo.Builder newBuilderForType()
Returns
newBuilderForType(GeneratedMessageV3.BuilderParent parent)
protected ColorInfo.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
Returns
Overrides
newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
Returns
Overrides
toBuilder()
public ColorInfo.Builder toBuilder()
Returns
writeTo(CodedOutputStream output)
public void writeTo(CodedOutputStream output)
Parameter
Overrides
Exceptions