Class: Google::Apis::CloudsearchV1::Labels

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Labels

Returns a new instance of Labels.



12980
12981
12982
# File 'lib/google/apis/cloudsearch_v1/classes.rb', line 12980

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

Instance Attribute Details

#display_nameArray<String>

The display name of the labels. This is populated (instead of the id) when the request fetch_spec has LABEL_DISPLAY_NAMES. Corresponds to the JSON property displayName

Returns:

  • (Array<String>)


12973
12974
12975
# File 'lib/google/apis/cloudsearch_v1/classes.rb', line 12973

def display_name
  @display_name
end

#idArray<String>

The ids of the labels attached to the Item, e.g. "^i", "^x_1" Corresponds to the JSON property id

Returns:

  • (Array<String>)


12978
12979
12980
# File 'lib/google/apis/cloudsearch_v1/classes.rb', line 12978

def id
  @id
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



12985
12986
12987
12988
# File 'lib/google/apis/cloudsearch_v1/classes.rb', line 12985

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