public final class CompleteQueryResponse extends com.google.protobuf.GeneratedMessageV3 implements CompleteQueryResponseOrBuilder
Response of the autocomplete query.Protobuf type
google.cloud.retail.v2.CompleteQueryResponse| Modifier and Type | Class and Description |
|---|---|
static class |
CompleteQueryResponse.AttributeResult
Resource that represents attribute results.
|
static interface |
CompleteQueryResponse.AttributeResultOrBuilder |
static class |
CompleteQueryResponse.Builder
Response of the autocomplete query.
|
static class |
CompleteQueryResponse.CompletionResult
Resource that represents completion results.
|
static interface |
CompleteQueryResponse.CompletionResultOrBuilder |
static class |
CompleteQueryResponse.RecentSearchResult
Deprecated.
|
static interface |
CompleteQueryResponse.RecentSearchResultOrBuilder
Deprecated.
|
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 |
ATTRIBUTE_RESULTS_FIELD_NUMBER |
static int |
ATTRIBUTION_TOKEN_FIELD_NUMBER |
static int |
COMPLETION_RESULTS_FIELD_NUMBER |
static int |
RECENT_SEARCH_RESULTS_FIELD_NUMBER |
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, 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 COMPLETION_RESULTS_FIELD_NUMBER
public static final int ATTRIBUTION_TOKEN_FIELD_NUMBER
public static final int RECENT_SEARCH_RESULTS_FIELD_NUMBER
public static final int ATTRIBUTE_RESULTS_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.MapFieldReflectionAccessor internalGetMapFieldReflection(int number)
internalGetMapFieldReflection in class com.google.protobuf.GeneratedMessageV3protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3public List<CompleteQueryResponse.CompletionResult> getCompletionResultsList()
Results of the matching suggestions. The result list is ordered and the first result is top suggestion.
repeated .google.cloud.retail.v2.CompleteQueryResponse.CompletionResult completion_results = 1;
getCompletionResultsList in interface CompleteQueryResponseOrBuilderpublic List<? extends CompleteQueryResponse.CompletionResultOrBuilder> getCompletionResultsOrBuilderList()
Results of the matching suggestions. The result list is ordered and the first result is top suggestion.
repeated .google.cloud.retail.v2.CompleteQueryResponse.CompletionResult completion_results = 1;
getCompletionResultsOrBuilderList in interface CompleteQueryResponseOrBuilderpublic int getCompletionResultsCount()
Results of the matching suggestions. The result list is ordered and the first result is top suggestion.
repeated .google.cloud.retail.v2.CompleteQueryResponse.CompletionResult completion_results = 1;
getCompletionResultsCount in interface CompleteQueryResponseOrBuilderpublic CompleteQueryResponse.CompletionResult getCompletionResults(int index)
Results of the matching suggestions. The result list is ordered and the first result is top suggestion.
repeated .google.cloud.retail.v2.CompleteQueryResponse.CompletionResult completion_results = 1;
getCompletionResults in interface CompleteQueryResponseOrBuilderpublic CompleteQueryResponse.CompletionResultOrBuilder getCompletionResultsOrBuilder(int index)
Results of the matching suggestions. The result list is ordered and the first result is top suggestion.
repeated .google.cloud.retail.v2.CompleteQueryResponse.CompletionResult completion_results = 1;
getCompletionResultsOrBuilder in interface CompleteQueryResponseOrBuilderpublic String getAttributionToken()
A unique complete token. This should be included in the [UserEvent.completion_detail][google.cloud.retail.v2.UserEvent.completion_detail] for search events resulting from this completion, which enables accurate attribution of complete model performance.
string attribution_token = 2;getAttributionToken in interface CompleteQueryResponseOrBuilderpublic com.google.protobuf.ByteString getAttributionTokenBytes()
A unique complete token. This should be included in the [UserEvent.completion_detail][google.cloud.retail.v2.UserEvent.completion_detail] for search events resulting from this completion, which enables accurate attribution of complete model performance.
string attribution_token = 2;getAttributionTokenBytes in interface CompleteQueryResponseOrBuilder@Deprecated public List<CompleteQueryResponse.RecentSearchResult> getRecentSearchResultsList()
Deprecated. Matched recent searches of this user. The maximum number of recent searches is 10. This field is a restricted feature. If you want to enable it, contact Retail Search support. This feature is only available when [CompleteQueryRequest.visitor_id][google.cloud.retail.v2.CompleteQueryRequest.visitor_id] field is set and [UserEvent][google.cloud.retail.v2.UserEvent] is imported. The recent searches satisfy the follow rules: * They are ordered from latest to oldest. * They are matched with [CompleteQueryRequest.query][google.cloud.retail.v2.CompleteQueryRequest.query] case insensitively. * They are transformed to lower case. * They are UTF-8 safe. Recent searches are deduplicated. More recent searches will be reserved when duplication happens.
repeated .google.cloud.retail.v2.CompleteQueryResponse.RecentSearchResult recent_search_results = 3 [deprecated = true];
getRecentSearchResultsList in interface CompleteQueryResponseOrBuilder@Deprecated public List<? extends CompleteQueryResponse.RecentSearchResultOrBuilder> getRecentSearchResultsOrBuilderList()
Deprecated. Matched recent searches of this user. The maximum number of recent searches is 10. This field is a restricted feature. If you want to enable it, contact Retail Search support. This feature is only available when [CompleteQueryRequest.visitor_id][google.cloud.retail.v2.CompleteQueryRequest.visitor_id] field is set and [UserEvent][google.cloud.retail.v2.UserEvent] is imported. The recent searches satisfy the follow rules: * They are ordered from latest to oldest. * They are matched with [CompleteQueryRequest.query][google.cloud.retail.v2.CompleteQueryRequest.query] case insensitively. * They are transformed to lower case. * They are UTF-8 safe. Recent searches are deduplicated. More recent searches will be reserved when duplication happens.
repeated .google.cloud.retail.v2.CompleteQueryResponse.RecentSearchResult recent_search_results = 3 [deprecated = true];
getRecentSearchResultsOrBuilderList in interface CompleteQueryResponseOrBuilder@Deprecated public int getRecentSearchResultsCount()
Deprecated. Matched recent searches of this user. The maximum number of recent searches is 10. This field is a restricted feature. If you want to enable it, contact Retail Search support. This feature is only available when [CompleteQueryRequest.visitor_id][google.cloud.retail.v2.CompleteQueryRequest.visitor_id] field is set and [UserEvent][google.cloud.retail.v2.UserEvent] is imported. The recent searches satisfy the follow rules: * They are ordered from latest to oldest. * They are matched with [CompleteQueryRequest.query][google.cloud.retail.v2.CompleteQueryRequest.query] case insensitively. * They are transformed to lower case. * They are UTF-8 safe. Recent searches are deduplicated. More recent searches will be reserved when duplication happens.
repeated .google.cloud.retail.v2.CompleteQueryResponse.RecentSearchResult recent_search_results = 3 [deprecated = true];
getRecentSearchResultsCount in interface CompleteQueryResponseOrBuilder@Deprecated public CompleteQueryResponse.RecentSearchResult getRecentSearchResults(int index)
Deprecated. Matched recent searches of this user. The maximum number of recent searches is 10. This field is a restricted feature. If you want to enable it, contact Retail Search support. This feature is only available when [CompleteQueryRequest.visitor_id][google.cloud.retail.v2.CompleteQueryRequest.visitor_id] field is set and [UserEvent][google.cloud.retail.v2.UserEvent] is imported. The recent searches satisfy the follow rules: * They are ordered from latest to oldest. * They are matched with [CompleteQueryRequest.query][google.cloud.retail.v2.CompleteQueryRequest.query] case insensitively. * They are transformed to lower case. * They are UTF-8 safe. Recent searches are deduplicated. More recent searches will be reserved when duplication happens.
repeated .google.cloud.retail.v2.CompleteQueryResponse.RecentSearchResult recent_search_results = 3 [deprecated = true];
getRecentSearchResults in interface CompleteQueryResponseOrBuilder@Deprecated public CompleteQueryResponse.RecentSearchResultOrBuilder getRecentSearchResultsOrBuilder(int index)
Deprecated. Matched recent searches of this user. The maximum number of recent searches is 10. This field is a restricted feature. If you want to enable it, contact Retail Search support. This feature is only available when [CompleteQueryRequest.visitor_id][google.cloud.retail.v2.CompleteQueryRequest.visitor_id] field is set and [UserEvent][google.cloud.retail.v2.UserEvent] is imported. The recent searches satisfy the follow rules: * They are ordered from latest to oldest. * They are matched with [CompleteQueryRequest.query][google.cloud.retail.v2.CompleteQueryRequest.query] case insensitively. * They are transformed to lower case. * They are UTF-8 safe. Recent searches are deduplicated. More recent searches will be reserved when duplication happens.
repeated .google.cloud.retail.v2.CompleteQueryResponse.RecentSearchResult recent_search_results = 3 [deprecated = true];
getRecentSearchResultsOrBuilder in interface CompleteQueryResponseOrBuilderpublic int getAttributeResultsCount()
CompleteQueryResponseOrBuilderA map of matched attribute suggestions. This field is only available for "cloud-retail" dataset. Current supported keys: * `brands` * `categories`
map<string, .google.cloud.retail.v2.CompleteQueryResponse.AttributeResult> attribute_results = 4;
getAttributeResultsCount in interface CompleteQueryResponseOrBuilderpublic boolean containsAttributeResults(String key)
A map of matched attribute suggestions. This field is only available for "cloud-retail" dataset. Current supported keys: * `brands` * `categories`
map<string, .google.cloud.retail.v2.CompleteQueryResponse.AttributeResult> attribute_results = 4;
containsAttributeResults in interface CompleteQueryResponseOrBuilder@Deprecated public Map<String,CompleteQueryResponse.AttributeResult> getAttributeResults()
getAttributeResultsMap() instead.getAttributeResults in interface CompleteQueryResponseOrBuilderpublic Map<String,CompleteQueryResponse.AttributeResult> getAttributeResultsMap()
A map of matched attribute suggestions. This field is only available for "cloud-retail" dataset. Current supported keys: * `brands` * `categories`
map<string, .google.cloud.retail.v2.CompleteQueryResponse.AttributeResult> attribute_results = 4;
getAttributeResultsMap in interface CompleteQueryResponseOrBuilderpublic CompleteQueryResponse.AttributeResult getAttributeResultsOrDefault(String key, CompleteQueryResponse.AttributeResult defaultValue)
A map of matched attribute suggestions. This field is only available for "cloud-retail" dataset. Current supported keys: * `brands` * `categories`
map<string, .google.cloud.retail.v2.CompleteQueryResponse.AttributeResult> attribute_results = 4;
getAttributeResultsOrDefault in interface CompleteQueryResponseOrBuilderpublic CompleteQueryResponse.AttributeResult getAttributeResultsOrThrow(String key)
A map of matched attribute suggestions. This field is only available for "cloud-retail" dataset. Current supported keys: * `brands` * `categories`
map<string, .google.cloud.retail.v2.CompleteQueryResponse.AttributeResult> attribute_results = 4;
getAttributeResultsOrThrow in interface CompleteQueryResponseOrBuilderpublic 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 CompleteQueryResponse parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static CompleteQueryResponse parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static CompleteQueryResponse parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static CompleteQueryResponse parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static CompleteQueryResponse parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static CompleteQueryResponse parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static CompleteQueryResponse parseFrom(InputStream input) throws IOException
IOExceptionpublic static CompleteQueryResponse parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic static CompleteQueryResponse parseDelimitedFrom(InputStream input) throws IOException
IOExceptionpublic static CompleteQueryResponse parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic static CompleteQueryResponse parseFrom(com.google.protobuf.CodedInputStream input) throws IOException
IOExceptionpublic static CompleteQueryResponse parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic CompleteQueryResponse.Builder newBuilderForType()
newBuilderForType in interface com.google.protobuf.MessagenewBuilderForType in interface com.google.protobuf.MessageLitepublic static CompleteQueryResponse.Builder newBuilder()
public static CompleteQueryResponse.Builder newBuilder(CompleteQueryResponse prototype)
public CompleteQueryResponse.Builder toBuilder()
toBuilder in interface com.google.protobuf.MessagetoBuilder in interface com.google.protobuf.MessageLiteprotected CompleteQueryResponse.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
newBuilderForType in class com.google.protobuf.GeneratedMessageV3public static CompleteQueryResponse getDefaultInstance()
public static com.google.protobuf.Parser<CompleteQueryResponse> parser()
public com.google.protobuf.Parser<CompleteQueryResponse> getParserForType()
getParserForType in interface com.google.protobuf.MessagegetParserForType in interface com.google.protobuf.MessageLitegetParserForType in class com.google.protobuf.GeneratedMessageV3public CompleteQueryResponse getDefaultInstanceForType()
getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuildergetDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilderCopyright © 2025 Google LLC. All rights reserved.