Class: Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaSearchResponseFacet

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

Overview

A facet result.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudDiscoveryengineV1alphaSearchResponseFacet

Returns a new instance of GoogleCloudDiscoveryengineV1alphaSearchResponseFacet.



11834
11835
11836
# File 'lib/google/apis/discoveryengine_v1alpha/classes.rb', line 11834

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)


11820
11821
11822
# File 'lib/google/apis/discoveryengine_v1alpha/classes.rb', line 11820

def dynamic_facet
  @dynamic_facet
end

#keyString

The key for this facet. For example, "colors" or "price". It matches SearchRequest.FacetSpec.FacetKey.key. Corresponds to the JSON property key

Returns:

  • (String)


11827
11828
11829
# File 'lib/google/apis/discoveryengine_v1alpha/classes.rb', line 11827

def key
  @key
end

#valuesArray<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue>

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



11832
11833
11834
# File 'lib/google/apis/discoveryengine_v1alpha/classes.rb', line 11832

def values
  @values
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



11839
11840
11841
11842
11843
# File 'lib/google/apis/discoveryengine_v1alpha/classes.rb', line 11839

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