class Google::Apis::CloudsearchV1::ContextAttribute
A named attribute associated with an item which can be used for influencing the ranking of the item based on the context in the request.
Attributes
name[RW]
The name of the attribute. It should not be empty. The maximum length is 32 characters. The name must start with a letter and can only contain letters (A- Z, a-z) or numbers (0-9). The name will be normalized (lower-cased) before being matched. Corresponds to the JSON property `name` @return [String]
values[RW]
Text values of the attribute. The maximum number of elements is 10. The maximum length of an element in the array is 32 characters. The value will be normalized (lower-cased) before being matched. Corresponds to the JSON property `values` @return [Array<String>]
Public Class Methods
new(**args)
click to toggle source
# File lib/google/apis/cloudsearch_v1/classes.rb, line 184 def initialize(**args) update!(**args) end
Public Instance Methods
update!(**args)
click to toggle source
Update properties of this object
# File lib/google/apis/cloudsearch_v1/classes.rb, line 189 def update!(**args) @name = args[:name] if args.key?(:name) @values = args[:values] if args.key?(:values) end