Class: Google::Apis::HealthV4::NutrientQuantity
- Inherits:
-
Object
- Object
- Google::Apis::HealthV4::NutrientQuantity
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/health_v4/classes.rb,
lib/google/apis/health_v4/representations.rb,
lib/google/apis/health_v4/representations.rb
Overview
Represents the quantity of a nutrient.
Instance Attribute Summary collapse
-
#nutrient ⇒ String
Required.
-
#quantity ⇒ Google::Apis::HealthV4::WeightQuantity
Represents the weight quantity.
Instance Method Summary collapse
-
#initialize(**args) ⇒ NutrientQuantity
constructor
A new instance of NutrientQuantity.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ NutrientQuantity
Returns a new instance of NutrientQuantity.
3616 3617 3618 |
# File 'lib/google/apis/health_v4/classes.rb', line 3616 def initialize(**args) update!(**args) end |
Instance Attribute Details
#nutrient ⇒ String
Required. The nutrient type.
Corresponds to the JSON property nutrient
3609 3610 3611 |
# File 'lib/google/apis/health_v4/classes.rb', line 3609 def nutrient @nutrient end |
#quantity ⇒ Google::Apis::HealthV4::WeightQuantity
Represents the weight quantity.
Corresponds to the JSON property quantity
3614 3615 3616 |
# File 'lib/google/apis/health_v4/classes.rb', line 3614 def quantity @quantity end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
3621 3622 3623 3624 |
# File 'lib/google/apis/health_v4/classes.rb', line 3621 def update!(**args) @nutrient = args[:nutrient] if args.key?(:nutrient) @quantity = args[:quantity] if args.key?(:quantity) end |