Class CompleteQueryResponse.QuerySuggestion.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<CompleteQueryResponse.QuerySuggestion.Builder>
com.google.cloud.discoveryengine.v1beta.CompleteQueryResponse.QuerySuggestion.Builder
All Implemented Interfaces:
CompleteQueryResponse.QuerySuggestionOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
Enclosing class:
CompleteQueryResponse.QuerySuggestion

public static final class CompleteQueryResponse.QuerySuggestion.Builder extends com.google.protobuf.GeneratedMessage.Builder<CompleteQueryResponse.QuerySuggestion.Builder> implements CompleteQueryResponse.QuerySuggestionOrBuilder
 Suggestions as search queries.
 
Protobuf type google.cloud.discoveryengine.v1beta.CompleteQueryResponse.QuerySuggestion
  • Method Details

    • getDescriptor

      public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessage.Builder<CompleteQueryResponse.QuerySuggestion.Builder>
    • clear

      Specified by:
      clear in interface com.google.protobuf.Message.Builder
      Specified by:
      clear in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clear in class com.google.protobuf.GeneratedMessage.Builder<CompleteQueryResponse.QuerySuggestion.Builder>
    • getDescriptorForType

      public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
      Specified by:
      getDescriptorForType in interface com.google.protobuf.Message.Builder
      Specified by:
      getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
      Overrides:
      getDescriptorForType in class com.google.protobuf.GeneratedMessage.Builder<CompleteQueryResponse.QuerySuggestion.Builder>
    • getDefaultInstanceForType

      public CompleteQueryResponse.QuerySuggestion getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
    • build

      Specified by:
      build in interface com.google.protobuf.Message.Builder
      Specified by:
      build in interface com.google.protobuf.MessageLite.Builder
    • buildPartial

      Specified by:
      buildPartial in interface com.google.protobuf.Message.Builder
      Specified by:
      buildPartial in interface com.google.protobuf.MessageLite.Builder
    • mergeFrom

      public CompleteQueryResponse.QuerySuggestion.Builder mergeFrom(com.google.protobuf.Message other)
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<CompleteQueryResponse.QuerySuggestion.Builder>
    • mergeFrom

    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessage.Builder<CompleteQueryResponse.QuerySuggestion.Builder>
    • mergeFrom

      public CompleteQueryResponse.QuerySuggestion.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Specified by:
      mergeFrom in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<CompleteQueryResponse.QuerySuggestion.Builder>
      Throws:
      IOException
    • getSuggestion

      public String getSuggestion()
       The suggestion for the query.
       
      string suggestion = 1;
      Specified by:
      getSuggestion in interface CompleteQueryResponse.QuerySuggestionOrBuilder
      Returns:
      The suggestion.
    • getSuggestionBytes

      public com.google.protobuf.ByteString getSuggestionBytes()
       The suggestion for the query.
       
      string suggestion = 1;
      Specified by:
      getSuggestionBytes in interface CompleteQueryResponse.QuerySuggestionOrBuilder
      Returns:
      The bytes for suggestion.
    • setSuggestion

       The suggestion for the query.
       
      string suggestion = 1;
      Parameters:
      value - The suggestion to set.
      Returns:
      This builder for chaining.
    • clearSuggestion

       The suggestion for the query.
       
      string suggestion = 1;
      Returns:
      This builder for chaining.
    • setSuggestionBytes

      public CompleteQueryResponse.QuerySuggestion.Builder setSuggestionBytes(com.google.protobuf.ByteString value)
       The suggestion for the query.
       
      string suggestion = 1;
      Parameters:
      value - The bytes for suggestion to set.
      Returns:
      This builder for chaining.
    • getCompletableFieldPathsList

      public com.google.protobuf.ProtocolStringList getCompletableFieldPathsList()
       The unique document field paths that serve as the source of this
       suggestion if it was generated from completable fields.
      
       This field is only populated for the document-completable model.
       
      repeated string completable_field_paths = 2;
      Specified by:
      getCompletableFieldPathsList in interface CompleteQueryResponse.QuerySuggestionOrBuilder
      Returns:
      A list containing the completableFieldPaths.
    • getCompletableFieldPathsCount

      public int getCompletableFieldPathsCount()
       The unique document field paths that serve as the source of this
       suggestion if it was generated from completable fields.
      
       This field is only populated for the document-completable model.
       
      repeated string completable_field_paths = 2;
      Specified by:
      getCompletableFieldPathsCount in interface CompleteQueryResponse.QuerySuggestionOrBuilder
      Returns:
      The count of completableFieldPaths.
    • getCompletableFieldPaths

      public String getCompletableFieldPaths(int index)
       The unique document field paths that serve as the source of this
       suggestion if it was generated from completable fields.
      
       This field is only populated for the document-completable model.
       
      repeated string completable_field_paths = 2;
      Specified by:
      getCompletableFieldPaths in interface CompleteQueryResponse.QuerySuggestionOrBuilder
      Parameters:
      index - The index of the element to return.
      Returns:
      The completableFieldPaths at the given index.
    • getCompletableFieldPathsBytes

      public com.google.protobuf.ByteString getCompletableFieldPathsBytes(int index)
       The unique document field paths that serve as the source of this
       suggestion if it was generated from completable fields.
      
       This field is only populated for the document-completable model.
       
      repeated string completable_field_paths = 2;
      Specified by:
      getCompletableFieldPathsBytes in interface CompleteQueryResponse.QuerySuggestionOrBuilder
      Parameters:
      index - The index of the value to return.
      Returns:
      The bytes of the completableFieldPaths at the given index.
    • setCompletableFieldPaths

      public CompleteQueryResponse.QuerySuggestion.Builder setCompletableFieldPaths(int index, String value)
       The unique document field paths that serve as the source of this
       suggestion if it was generated from completable fields.
      
       This field is only populated for the document-completable model.
       
      repeated string completable_field_paths = 2;
      Parameters:
      index - The index to set the value at.
      value - The completableFieldPaths to set.
      Returns:
      This builder for chaining.
    • addCompletableFieldPaths

      public CompleteQueryResponse.QuerySuggestion.Builder addCompletableFieldPaths(String value)
       The unique document field paths that serve as the source of this
       suggestion if it was generated from completable fields.
      
       This field is only populated for the document-completable model.
       
      repeated string completable_field_paths = 2;
      Parameters:
      value - The completableFieldPaths to add.
      Returns:
      This builder for chaining.
    • addAllCompletableFieldPaths

      public CompleteQueryResponse.QuerySuggestion.Builder addAllCompletableFieldPaths(Iterable<String> values)
       The unique document field paths that serve as the source of this
       suggestion if it was generated from completable fields.
      
       This field is only populated for the document-completable model.
       
      repeated string completable_field_paths = 2;
      Parameters:
      values - The completableFieldPaths to add.
      Returns:
      This builder for chaining.
    • clearCompletableFieldPaths

      public CompleteQueryResponse.QuerySuggestion.Builder clearCompletableFieldPaths()
       The unique document field paths that serve as the source of this
       suggestion if it was generated from completable fields.
      
       This field is only populated for the document-completable model.
       
      repeated string completable_field_paths = 2;
      Returns:
      This builder for chaining.
    • addCompletableFieldPathsBytes

      public CompleteQueryResponse.QuerySuggestion.Builder addCompletableFieldPathsBytes(com.google.protobuf.ByteString value)
       The unique document field paths that serve as the source of this
       suggestion if it was generated from completable fields.
      
       This field is only populated for the document-completable model.
       
      repeated string completable_field_paths = 2;
      Parameters:
      value - The bytes of the completableFieldPaths to add.
      Returns:
      This builder for chaining.