Class: Google::Apis::CustomsearchV1::Result::Label

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

Overview

Refinement label associated with a custom search result.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Label

Returns a new instance of Label.



323
324
325
# File 'lib/google/apis/customsearch_v1/classes.rb', line 323

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

Instance Attribute Details

#display_nameString

The display name of a refinement label. This is the name you should display in your user interface. Corresponds to the JSON property displayName

Returns:

  • (String)


310
311
312
# File 'lib/google/apis/customsearch_v1/classes.rb', line 310

def display_name
  @display_name
end

#label_with_opString

Refinement label and the associated refinement operation. Corresponds to the JSON property label_with_op

Returns:

  • (String)


315
316
317
# File 'lib/google/apis/customsearch_v1/classes.rb', line 315

def label_with_op
  @label_with_op
end

#nameString

The name of a refinement label, which you can use to refine searches. Don't display this in your user interface; instead, use displayName. Corresponds to the JSON property name

Returns:

  • (String)


321
322
323
# File 'lib/google/apis/customsearch_v1/classes.rb', line 321

def name
  @name
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



328
329
330
331
332
# File 'lib/google/apis/customsearch_v1/classes.rb', line 328

def update!(**args)
  @display_name = args[:display_name] if args.key?(:display_name)
  @label_with_op = args[:label_with_op] if args.key?(:label_with_op)
  @name = args[:name] if args.key?(:name)
end