public final class CustomAttribute extends com.google.protobuf.GeneratedMessageV3 implements CustomAttributeOrBuilder
A custom attribute that is not explicitly modeled in [Product][google.cloud.retail.v2alpha.Product].Protobuf type
google.cloud.retail.v2alpha.CustomAttribute| Modifier and Type | Class and Description |
|---|---|
static class |
CustomAttribute.Builder
A custom attribute that is not explicitly modeled in
[Product][google.cloud.retail.v2alpha.Product].
|
com.google.protobuf.GeneratedMessageV3.BuilderParent, com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>,BuilderT extends com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT,BuilderT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.FieldAccessorTable, com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter| Modifier and Type | Field and Description |
|---|---|
static int |
INDEXABLE_FIELD_NUMBER |
static int |
NUMBERS_FIELD_NUMBER |
static int |
SEARCHABLE_FIELD_NUMBER |
static int |
TEXT_FIELD_NUMBER |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj) |
static CustomAttribute |
getDefaultInstance() |
CustomAttribute |
getDefaultInstanceForType() |
static com.google.protobuf.Descriptors.Descriptor |
getDescriptor() |
boolean |
getIndexable()
Deprecated.
google.cloud.retail.v2alpha.CustomAttribute.indexable is deprecated. See
google/cloud/retail/v2alpha/common.proto;l=447
|
double |
getNumbers(int index)
The numerical values of this custom attribute.
|
int |
getNumbersCount()
The numerical values of this custom attribute.
|
List<Double> |
getNumbersList()
The numerical values of this custom attribute.
|
com.google.protobuf.Parser<CustomAttribute> |
getParserForType() |
boolean |
getSearchable()
Deprecated.
google.cloud.retail.v2alpha.CustomAttribute.searchable is deprecated. See
google/cloud/retail/v2alpha/common.proto;l=426
|
int |
getSerializedSize() |
String |
getText(int index)
The textual values of this custom attribute.
|
com.google.protobuf.ByteString |
getTextBytes(int index)
The textual values of this custom attribute.
|
int |
getTextCount()
The textual values of this custom attribute.
|
com.google.protobuf.ProtocolStringList |
getTextList()
The textual values of this custom attribute.
|
int |
hashCode() |
boolean |
hasIndexable()
Deprecated.
google.cloud.retail.v2alpha.CustomAttribute.indexable is deprecated. See
google/cloud/retail/v2alpha/common.proto;l=447
|
boolean |
hasSearchable()
Deprecated.
google.cloud.retail.v2alpha.CustomAttribute.searchable is deprecated. See
google/cloud/retail/v2alpha/common.proto;l=426
|
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable |
internalGetFieldAccessorTable() |
boolean |
isInitialized() |
static CustomAttribute.Builder |
newBuilder() |
static CustomAttribute.Builder |
newBuilder(CustomAttribute prototype) |
CustomAttribute.Builder |
newBuilderForType() |
protected CustomAttribute.Builder |
newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) |
protected Object |
newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused) |
static CustomAttribute |
parseDelimitedFrom(InputStream input) |
static CustomAttribute |
parseDelimitedFrom(InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static CustomAttribute |
parseFrom(byte[] data) |
static CustomAttribute |
parseFrom(byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static CustomAttribute |
parseFrom(ByteBuffer data) |
static CustomAttribute |
parseFrom(ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static CustomAttribute |
parseFrom(com.google.protobuf.ByteString data) |
static CustomAttribute |
parseFrom(com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static CustomAttribute |
parseFrom(com.google.protobuf.CodedInputStream input) |
static CustomAttribute |
parseFrom(com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static CustomAttribute |
parseFrom(InputStream input) |
static CustomAttribute |
parseFrom(InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static com.google.protobuf.Parser<CustomAttribute> |
parser() |
CustomAttribute.Builder |
toBuilder() |
void |
writeTo(com.google.protobuf.CodedOutputStream output) |
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, isStringEmpty, makeExtensionsImmutable, makeMutableCopy, makeMutableCopy, mergeFromAndMakeImmutableInternal, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, newBooleanList, newBuilderForType, newDoubleList, newFloatList, newIntList, newLongList, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTagfindInitializationErrors, getInitializationErrorString, hashBoolean, hashEnum, hashEnumList, hashFields, hashLong, toStringaddAll, addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeToclone, finalize, getClass, notify, notifyAll, wait, wait, waitpublic static final int TEXT_FIELD_NUMBER
public static final int NUMBERS_FIELD_NUMBER
public static final int SEARCHABLE_FIELD_NUMBER
public static final int INDEXABLE_FIELD_NUMBER
protected Object newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
newInstance in class com.google.protobuf.GeneratedMessageV3public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3public com.google.protobuf.ProtocolStringList getTextList()
The textual values of this custom attribute. For example, `["yellow", "green"]` when the key is "color". Empty string is not allowed. Otherwise, an INVALID_ARGUMENT error is returned. Exactly one of [text][google.cloud.retail.v2alpha.CustomAttribute.text] or [numbers][google.cloud.retail.v2alpha.CustomAttribute.numbers] should be set. Otherwise, an INVALID_ARGUMENT error is returned.
repeated string text = 1;getTextList in interface CustomAttributeOrBuilderpublic int getTextCount()
The textual values of this custom attribute. For example, `["yellow", "green"]` when the key is "color". Empty string is not allowed. Otherwise, an INVALID_ARGUMENT error is returned. Exactly one of [text][google.cloud.retail.v2alpha.CustomAttribute.text] or [numbers][google.cloud.retail.v2alpha.CustomAttribute.numbers] should be set. Otherwise, an INVALID_ARGUMENT error is returned.
repeated string text = 1;getTextCount in interface CustomAttributeOrBuilderpublic String getText(int index)
The textual values of this custom attribute. For example, `["yellow", "green"]` when the key is "color". Empty string is not allowed. Otherwise, an INVALID_ARGUMENT error is returned. Exactly one of [text][google.cloud.retail.v2alpha.CustomAttribute.text] or [numbers][google.cloud.retail.v2alpha.CustomAttribute.numbers] should be set. Otherwise, an INVALID_ARGUMENT error is returned.
repeated string text = 1;getText in interface CustomAttributeOrBuilderindex - The index of the element to return.public com.google.protobuf.ByteString getTextBytes(int index)
The textual values of this custom attribute. For example, `["yellow", "green"]` when the key is "color". Empty string is not allowed. Otherwise, an INVALID_ARGUMENT error is returned. Exactly one of [text][google.cloud.retail.v2alpha.CustomAttribute.text] or [numbers][google.cloud.retail.v2alpha.CustomAttribute.numbers] should be set. Otherwise, an INVALID_ARGUMENT error is returned.
repeated string text = 1;getTextBytes in interface CustomAttributeOrBuilderindex - The index of the value to return.public List<Double> getNumbersList()
The numerical values of this custom attribute. For example, `[2.3, 15.4]` when the key is "lengths_cm". Exactly one of [text][google.cloud.retail.v2alpha.CustomAttribute.text] or [numbers][google.cloud.retail.v2alpha.CustomAttribute.numbers] should be set. Otherwise, an INVALID_ARGUMENT error is returned.
repeated double numbers = 2;getNumbersList in interface CustomAttributeOrBuilderpublic int getNumbersCount()
The numerical values of this custom attribute. For example, `[2.3, 15.4]` when the key is "lengths_cm". Exactly one of [text][google.cloud.retail.v2alpha.CustomAttribute.text] or [numbers][google.cloud.retail.v2alpha.CustomAttribute.numbers] should be set. Otherwise, an INVALID_ARGUMENT error is returned.
repeated double numbers = 2;getNumbersCount in interface CustomAttributeOrBuilderpublic double getNumbers(int index)
The numerical values of this custom attribute. For example, `[2.3, 15.4]` when the key is "lengths_cm". Exactly one of [text][google.cloud.retail.v2alpha.CustomAttribute.text] or [numbers][google.cloud.retail.v2alpha.CustomAttribute.numbers] should be set. Otherwise, an INVALID_ARGUMENT error is returned.
repeated double numbers = 2;getNumbers in interface CustomAttributeOrBuilderindex - The index of the element to return.@Deprecated public boolean hasSearchable()
This field is normally ignored unless [AttributesConfig.attribute_config_level][google.cloud.retail.v2alpha.AttributesConfig.attribute_config_level] of the [Catalog][google.cloud.retail.v2alpha.Catalog] is set to the deprecated 'PRODUCT_LEVEL_ATTRIBUTE_CONFIG' mode. For information about product-level attribute configuration, see [Configuration modes](https://cloud.google.com/retail/docs/attribute-config#config-modes). If true, custom attribute values are searchable by text queries in [SearchService.Search][google.cloud.retail.v2alpha.SearchService.Search]. This field is ignored in a [UserEvent][google.cloud.retail.v2alpha.UserEvent]. Only set if type [text][google.cloud.retail.v2alpha.CustomAttribute.text] is set. Otherwise, a INVALID_ARGUMENT error is returned.
optional bool searchable = 3 [deprecated = true];hasSearchable in interface CustomAttributeOrBuilder@Deprecated public boolean getSearchable()
This field is normally ignored unless [AttributesConfig.attribute_config_level][google.cloud.retail.v2alpha.AttributesConfig.attribute_config_level] of the [Catalog][google.cloud.retail.v2alpha.Catalog] is set to the deprecated 'PRODUCT_LEVEL_ATTRIBUTE_CONFIG' mode. For information about product-level attribute configuration, see [Configuration modes](https://cloud.google.com/retail/docs/attribute-config#config-modes). If true, custom attribute values are searchable by text queries in [SearchService.Search][google.cloud.retail.v2alpha.SearchService.Search]. This field is ignored in a [UserEvent][google.cloud.retail.v2alpha.UserEvent]. Only set if type [text][google.cloud.retail.v2alpha.CustomAttribute.text] is set. Otherwise, a INVALID_ARGUMENT error is returned.
optional bool searchable = 3 [deprecated = true];getSearchable in interface CustomAttributeOrBuilder@Deprecated public boolean hasIndexable()
This field is normally ignored unless [AttributesConfig.attribute_config_level][google.cloud.retail.v2alpha.AttributesConfig.attribute_config_level] of the [Catalog][google.cloud.retail.v2alpha.Catalog] is set to the deprecated 'PRODUCT_LEVEL_ATTRIBUTE_CONFIG' mode. For information about product-level attribute configuration, see [Configuration modes](https://cloud.google.com/retail/docs/attribute-config#config-modes). If true, custom attribute values are indexed, so that they can be filtered, faceted or boosted in [SearchService.Search][google.cloud.retail.v2alpha.SearchService.Search]. This field is ignored in a [UserEvent][google.cloud.retail.v2alpha.UserEvent]. See [SearchRequest.filter][google.cloud.retail.v2alpha.SearchRequest.filter], [SearchRequest.facet_specs][google.cloud.retail.v2alpha.SearchRequest.facet_specs] and [SearchRequest.boost_spec][google.cloud.retail.v2alpha.SearchRequest.boost_spec] for more details.
optional bool indexable = 4 [deprecated = true];hasIndexable in interface CustomAttributeOrBuilder@Deprecated public boolean getIndexable()
This field is normally ignored unless [AttributesConfig.attribute_config_level][google.cloud.retail.v2alpha.AttributesConfig.attribute_config_level] of the [Catalog][google.cloud.retail.v2alpha.Catalog] is set to the deprecated 'PRODUCT_LEVEL_ATTRIBUTE_CONFIG' mode. For information about product-level attribute configuration, see [Configuration modes](https://cloud.google.com/retail/docs/attribute-config#config-modes). If true, custom attribute values are indexed, so that they can be filtered, faceted or boosted in [SearchService.Search][google.cloud.retail.v2alpha.SearchService.Search]. This field is ignored in a [UserEvent][google.cloud.retail.v2alpha.UserEvent]. See [SearchRequest.filter][google.cloud.retail.v2alpha.SearchRequest.filter], [SearchRequest.facet_specs][google.cloud.retail.v2alpha.SearchRequest.facet_specs] and [SearchRequest.boost_spec][google.cloud.retail.v2alpha.SearchRequest.boost_spec] for more details.
optional bool indexable = 4 [deprecated = true];getIndexable in interface CustomAttributeOrBuilderpublic final boolean isInitialized()
isInitialized in interface com.google.protobuf.MessageLiteOrBuilderisInitialized in class com.google.protobuf.GeneratedMessageV3public void writeTo(com.google.protobuf.CodedOutputStream output)
throws IOException
writeTo in interface com.google.protobuf.MessageLitewriteTo in class com.google.protobuf.GeneratedMessageV3IOExceptionpublic int getSerializedSize()
getSerializedSize in interface com.google.protobuf.MessageLitegetSerializedSize in class com.google.protobuf.GeneratedMessageV3public boolean equals(Object obj)
equals in interface com.google.protobuf.Messageequals in class com.google.protobuf.AbstractMessagepublic int hashCode()
hashCode in interface com.google.protobuf.MessagehashCode in class com.google.protobuf.AbstractMessagepublic static CustomAttribute parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static CustomAttribute parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static CustomAttribute parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static CustomAttribute parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static CustomAttribute parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static CustomAttribute parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static CustomAttribute parseFrom(InputStream input) throws IOException
IOExceptionpublic static CustomAttribute parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic static CustomAttribute parseDelimitedFrom(InputStream input) throws IOException
IOExceptionpublic static CustomAttribute parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic static CustomAttribute parseFrom(com.google.protobuf.CodedInputStream input) throws IOException
IOExceptionpublic static CustomAttribute parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic CustomAttribute.Builder newBuilderForType()
newBuilderForType in interface com.google.protobuf.MessagenewBuilderForType in interface com.google.protobuf.MessageLitepublic static CustomAttribute.Builder newBuilder()
public static CustomAttribute.Builder newBuilder(CustomAttribute prototype)
public CustomAttribute.Builder toBuilder()
toBuilder in interface com.google.protobuf.MessagetoBuilder in interface com.google.protobuf.MessageLiteprotected CustomAttribute.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
newBuilderForType in class com.google.protobuf.GeneratedMessageV3public static CustomAttribute getDefaultInstance()
public static com.google.protobuf.Parser<CustomAttribute> parser()
public com.google.protobuf.Parser<CustomAttribute> getParserForType()
getParserForType in interface com.google.protobuf.MessagegetParserForType in interface com.google.protobuf.MessageLitegetParserForType in class com.google.protobuf.GeneratedMessageV3public CustomAttribute getDefaultInstanceForType()
getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuildergetDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilderCopyright © 2024 Google LLC. All rights reserved.