Class: Google::Apis::HomegraphV1::ComponentTraitUpdates

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

Overview

Contains the set of updates for a component.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ ComponentTraitUpdates

Returns a new instance of ComponentTraitUpdates.



168
169
170
# File 'lib/google/apis/homegraph_v1/classes.rb', line 168

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

Instance Attribute Details

#component_idString

Required. ID of the component from the device provider. Corresponds to the JSON property componentId

Returns:

  • (String)


161
162
163
# File 'lib/google/apis/homegraph_v1/classes.rb', line 161

def component_id
  @component_id
end

#trait_dataArray<Google::Apis::HomegraphV1::TraitData>

Required. The updated trait data for the component. Corresponds to the JSON property traitData



166
167
168
# File 'lib/google/apis/homegraph_v1/classes.rb', line 166

def trait_data
  @trait_data
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



173
174
175
176
# File 'lib/google/apis/homegraph_v1/classes.rb', line 173

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