Class: Google::Apis::RetailV2alpha::GoogleCloudRetailV2alphaSearchResponseFacet

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/retail_v2alpha/classes.rb,
lib/google/apis/retail_v2alpha/representations.rb,
lib/google/apis/retail_v2alpha/representations.rb

Overview

A facet result.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudRetailV2alphaSearchResponseFacet

Returns a new instance of GoogleCloudRetailV2alphaSearchResponseFacet.



7151
7152
7153
# File 'lib/google/apis/retail_v2alpha/classes.rb', line 7151

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#dynamic_facetBoolean Also known as: dynamic_facet?

Whether the facet is dynamically generated. Corresponds to the JSON property dynamicFacet

Returns:

  • (Boolean)


7138
7139
7140
# File 'lib/google/apis/retail_v2alpha/classes.rb', line 7138

def dynamic_facet
  @dynamic_facet
end

#keyString

The key for this facet. E.g., "colorFamilies" or "price" or "attributes.attr1". Corresponds to the JSON property key

Returns:

  • (String)


7144
7145
7146
# File 'lib/google/apis/retail_v2alpha/classes.rb', line 7144

def key
  @key
end

#valuesArray<Google::Apis::RetailV2alpha::GoogleCloudRetailV2alphaSearchResponseFacetFacetValue>

The facet values for this field. Corresponds to the JSON property values



7149
7150
7151
# File 'lib/google/apis/retail_v2alpha/classes.rb', line 7149

def values
  @values
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



7156
7157
7158
7159
7160
# File 'lib/google/apis/retail_v2alpha/classes.rb', line 7156

def update!(**args)
  @dynamic_facet = args[:dynamic_facet] if args.key?(:dynamic_facet)
  @key = args[:key] if args.key?(:key)
  @values = args[:values] if args.key?(:values)
end