Class Rule.RemoveFacetAction.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<Rule.RemoveFacetAction.Builder>
com.google.cloud.retail.v2alpha.Rule.RemoveFacetAction.Builder
All Implemented Interfaces:
Rule.RemoveFacetActionOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
Enclosing class:
Rule.RemoveFacetAction

public static final class Rule.RemoveFacetAction.Builder extends com.google.protobuf.GeneratedMessage.Builder<Rule.RemoveFacetAction.Builder> implements Rule.RemoveFacetActionOrBuilder
 Removes an attribute/facet in the request if is present.

 * Rule Condition:
 Must specify non-empty
 [Condition.query_terms][google.cloud.retail.v2alpha.Condition.query_terms]
 (for search only) or
 [Condition.page_categories][google.cloud.retail.v2alpha.Condition.page_categories]
 (for browse only), but can't specify both.

 * Action Input: attribute name

 * Action Result: Will remove the attribute (as a facet) from the request
 if it is present.

 Example: Suppose the query is "shoes", the
 [Condition.query_terms][google.cloud.retail.v2alpha.Condition.query_terms]
 is "shoes" and the attribute name "size", then facet key "size" will be
 removed from the request (if it is present).
 
Protobuf type google.cloud.retail.v2alpha.Rule.RemoveFacetAction
  • Method Summary

    Modifier and Type
    Method
    Description
    The attribute names (i.e. facet keys) to remove from the dynamic facets (if present in the request).
    The attribute names (i.e. facet keys) to remove from the dynamic facets (if present in the request).
    addAttributeNamesBytes(com.google.protobuf.ByteString value)
    The attribute names (i.e. facet keys) to remove from the dynamic facets (if present in the request).
     
     
     
    The attribute names (i.e. facet keys) to remove from the dynamic facets (if present in the request).
    getAttributeNames(int index)
    The attribute names (i.e. facet keys) to remove from the dynamic facets (if present in the request).
    com.google.protobuf.ByteString
    The attribute names (i.e. facet keys) to remove from the dynamic facets (if present in the request).
    int
    The attribute names (i.e. facet keys) to remove from the dynamic facets (if present in the request).
    com.google.protobuf.ProtocolStringList
    The attribute names (i.e. facet keys) to remove from the dynamic facets (if present in the request).
     
    static final com.google.protobuf.Descriptors.Descriptor
     
    com.google.protobuf.Descriptors.Descriptor
     
    protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
     
    final boolean
     
     
    mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
     
    mergeFrom(com.google.protobuf.Message other)
     
    setAttributeNames(int index, String value)
    The attribute names (i.e. facet keys) to remove from the dynamic facets (if present in the request).

    Methods inherited from class com.google.protobuf.GeneratedMessage.Builder

    addRepeatedField, clearField, clearOneof, clone, getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, internalGetMutableMapField, internalGetMutableMapFieldReflection, isClean, markClean, mergeUnknownFields, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setField, setRepeatedField, setUnknownFields, setUnknownFieldSetBuilder, setUnknownFieldsProto3

    Methods inherited from class com.google.protobuf.AbstractMessage.Builder

    findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toString

    Methods inherited from class com.google.protobuf.AbstractMessageLite.Builder

    addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageException

    Methods inherited from class java.lang.Object

    equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait

    Methods inherited from interface com.google.protobuf.Message.Builder

    mergeDelimitedFrom, mergeDelimitedFrom

    Methods inherited from interface com.google.protobuf.MessageLite.Builder

    mergeFrom

    Methods inherited from interface com.google.protobuf.MessageOrBuilder

    findInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
  • 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<Rule.RemoveFacetAction.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<Rule.RemoveFacetAction.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<Rule.RemoveFacetAction.Builder>
    • getDefaultInstanceForType

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

      public Rule.RemoveFacetAction build()
      Specified by:
      build in interface com.google.protobuf.Message.Builder
      Specified by:
      build in interface com.google.protobuf.MessageLite.Builder
    • buildPartial

      public Rule.RemoveFacetAction buildPartial()
      Specified by:
      buildPartial in interface com.google.protobuf.Message.Builder
      Specified by:
      buildPartial in interface com.google.protobuf.MessageLite.Builder
    • mergeFrom

      public Rule.RemoveFacetAction.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<Rule.RemoveFacetAction.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<Rule.RemoveFacetAction.Builder>
    • mergeFrom

      public Rule.RemoveFacetAction.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<Rule.RemoveFacetAction.Builder>
      Throws:
      IOException
    • getAttributeNamesList

      public com.google.protobuf.ProtocolStringList getAttributeNamesList()
       The attribute names (i.e. facet keys) to remove from the dynamic facets
       (if present in the request). There can't be more 3 attribute names.
       Each attribute name should be a valid attribute name, be non-empty and
       contain at most 80 characters.
       
      repeated string attribute_names = 1;
      Specified by:
      getAttributeNamesList in interface Rule.RemoveFacetActionOrBuilder
      Returns:
      A list containing the attributeNames.
    • getAttributeNamesCount

      public int getAttributeNamesCount()
       The attribute names (i.e. facet keys) to remove from the dynamic facets
       (if present in the request). There can't be more 3 attribute names.
       Each attribute name should be a valid attribute name, be non-empty and
       contain at most 80 characters.
       
      repeated string attribute_names = 1;
      Specified by:
      getAttributeNamesCount in interface Rule.RemoveFacetActionOrBuilder
      Returns:
      The count of attributeNames.
    • getAttributeNames

      public String getAttributeNames(int index)
       The attribute names (i.e. facet keys) to remove from the dynamic facets
       (if present in the request). There can't be more 3 attribute names.
       Each attribute name should be a valid attribute name, be non-empty and
       contain at most 80 characters.
       
      repeated string attribute_names = 1;
      Specified by:
      getAttributeNames in interface Rule.RemoveFacetActionOrBuilder
      Parameters:
      index - The index of the element to return.
      Returns:
      The attributeNames at the given index.
    • getAttributeNamesBytes

      public com.google.protobuf.ByteString getAttributeNamesBytes(int index)
       The attribute names (i.e. facet keys) to remove from the dynamic facets
       (if present in the request). There can't be more 3 attribute names.
       Each attribute name should be a valid attribute name, be non-empty and
       contain at most 80 characters.
       
      repeated string attribute_names = 1;
      Specified by:
      getAttributeNamesBytes in interface Rule.RemoveFacetActionOrBuilder
      Parameters:
      index - The index of the value to return.
      Returns:
      The bytes of the attributeNames at the given index.
    • setAttributeNames

      public Rule.RemoveFacetAction.Builder setAttributeNames(int index, String value)
       The attribute names (i.e. facet keys) to remove from the dynamic facets
       (if present in the request). There can't be more 3 attribute names.
       Each attribute name should be a valid attribute name, be non-empty and
       contain at most 80 characters.
       
      repeated string attribute_names = 1;
      Parameters:
      index - The index to set the value at.
      value - The attributeNames to set.
      Returns:
      This builder for chaining.
    • addAttributeNames

      public Rule.RemoveFacetAction.Builder addAttributeNames(String value)
       The attribute names (i.e. facet keys) to remove from the dynamic facets
       (if present in the request). There can't be more 3 attribute names.
       Each attribute name should be a valid attribute name, be non-empty and
       contain at most 80 characters.
       
      repeated string attribute_names = 1;
      Parameters:
      value - The attributeNames to add.
      Returns:
      This builder for chaining.
    • addAllAttributeNames

      public Rule.RemoveFacetAction.Builder addAllAttributeNames(Iterable<String> values)
       The attribute names (i.e. facet keys) to remove from the dynamic facets
       (if present in the request). There can't be more 3 attribute names.
       Each attribute name should be a valid attribute name, be non-empty and
       contain at most 80 characters.
       
      repeated string attribute_names = 1;
      Parameters:
      values - The attributeNames to add.
      Returns:
      This builder for chaining.
    • clearAttributeNames

      public Rule.RemoveFacetAction.Builder clearAttributeNames()
       The attribute names (i.e. facet keys) to remove from the dynamic facets
       (if present in the request). There can't be more 3 attribute names.
       Each attribute name should be a valid attribute name, be non-empty and
       contain at most 80 characters.
       
      repeated string attribute_names = 1;
      Returns:
      This builder for chaining.
    • addAttributeNamesBytes

      public Rule.RemoveFacetAction.Builder addAttributeNamesBytes(com.google.protobuf.ByteString value)
       The attribute names (i.e. facet keys) to remove from the dynamic facets
       (if present in the request). There can't be more 3 attribute names.
       Each attribute name should be a valid attribute name, be non-empty and
       contain at most 80 characters.
       
      repeated string attribute_names = 1;
      Parameters:
      value - The bytes of the attributeNames to add.
      Returns:
      This builder for chaining.