Class: Google::Apis::HealthV4::Distance

Inherits:
Object
  • Object
show all
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

Distance traveled over an interval of time.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Distance

Returns a new instance of Distance.



1589
1590
1591
# File 'lib/google/apis/health_v4/classes.rb', line 1589

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

Instance Attribute Details

#intervalGoogle::Apis::HealthV4::ObservationTimeInterval

Represents a time interval of an observed data point. Corresponds to the JSON property interval



1582
1583
1584
# File 'lib/google/apis/health_v4/classes.rb', line 1582

def interval
  @interval
end

#millimetersFixnum

Required. Distance in millimeters over the observed interval. Corresponds to the JSON property millimeters

Returns:

  • (Fixnum)


1587
1588
1589
# File 'lib/google/apis/health_v4/classes.rb', line 1587

def millimeters
  @millimeters
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1594
1595
1596
1597
# File 'lib/google/apis/health_v4/classes.rb', line 1594

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