Class: Google::Apis::HealthV4::ObservationTimeInterval

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

Represents a time interval of an observed data point.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ ObservationTimeInterval

Returns a new instance of ObservationTimeInterval.



3768
3769
3770
# File 'lib/google/apis/health_v4/classes.rb', line 3768

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

Instance Attribute Details

#civil_end_timeGoogle::Apis::HealthV4::CivilDateTime

Civil time representation similar to google.type.DateTime, but ensures that neither the timezone nor the UTC offset can be set to avoid confusion between civil and physical time queries. Corresponds to the JSON property civilEndTime



3737
3738
3739
# File 'lib/google/apis/health_v4/classes.rb', line 3737

def civil_end_time
  @civil_end_time
end

#civil_start_timeGoogle::Apis::HealthV4::CivilDateTime

Civil time representation similar to google.type.DateTime, but ensures that neither the timezone nor the UTC offset can be set to avoid confusion between civil and physical time queries. Corresponds to the JSON property civilStartTime



3744
3745
3746
# File 'lib/google/apis/health_v4/classes.rb', line 3744

def civil_start_time
  @civil_start_time
end

#end_timeString

Required. Observed interval end time. Corresponds to the JSON property endTime

Returns:

  • (String)


3749
3750
3751
# File 'lib/google/apis/health_v4/classes.rb', line 3749

def end_time
  @end_time
end

#end_utc_offsetString

Required. The offset of the user's local time at the end of the observation relative to the Coordinated Universal Time (UTC). Corresponds to the JSON property endUtcOffset

Returns:

  • (String)


3755
3756
3757
# File 'lib/google/apis/health_v4/classes.rb', line 3755

def end_utc_offset
  @end_utc_offset
end

#start_timeString

Required. Observed interval start time. Corresponds to the JSON property startTime

Returns:

  • (String)


3760
3761
3762
# File 'lib/google/apis/health_v4/classes.rb', line 3760

def start_time
  @start_time
end

#start_utc_offsetString

Required. The offset of the user's local time at the start of the observation relative to the Coordinated Universal Time (UTC). Corresponds to the JSON property startUtcOffset

Returns:

  • (String)


3766
3767
3768
# File 'lib/google/apis/health_v4/classes.rb', line 3766

def start_utc_offset
  @start_utc_offset
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



3773
3774
3775
3776
3777
3778
3779
3780
# File 'lib/google/apis/health_v4/classes.rb', line 3773

def update!(**args)
  @civil_end_time = args[:civil_end_time] if args.key?(:civil_end_time)
  @civil_start_time = args[:civil_start_time] if args.key?(:civil_start_time)
  @end_time = args[:end_time] if args.key?(:end_time)
  @end_utc_offset = args[:end_utc_offset] if args.key?(:end_utc_offset)
  @start_time = args[:start_time] if args.key?(:start_time)
  @start_utc_offset = args[:start_utc_offset] if args.key?(:start_utc_offset)
end