Class: Google::Apis::HealthV4::ExerciseEvent

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 instantaneous events that happen during an exercise, such as start, stop, pause, split.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ ExerciseEvent

Returns a new instance of ExerciseEvent.



2313
2314
2315
# File 'lib/google/apis/health_v4/classes.rb', line 2313

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

Instance Attribute Details

#event_timeString

Required. Exercise event time Corresponds to the JSON property eventTime

Returns:

  • (String)


2301
2302
2303
# File 'lib/google/apis/health_v4/classes.rb', line 2301

def event_time
  @event_time
end

#event_utc_offsetString

Required. Exercise event time offset from UTC Corresponds to the JSON property eventUtcOffset

Returns:

  • (String)


2306
2307
2308
# File 'lib/google/apis/health_v4/classes.rb', line 2306

def event_utc_offset
  @event_utc_offset
end

#exercise_event_typeString

Required. The type of the event, such as start, stop, pause, resume. Corresponds to the JSON property exerciseEventType

Returns:

  • (String)


2311
2312
2313
# File 'lib/google/apis/health_v4/classes.rb', line 2311

def exercise_event_type
  @exercise_event_type
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



2318
2319
2320
2321
2322
# File 'lib/google/apis/health_v4/classes.rb', line 2318

def update!(**args)
  @event_time = args[:event_time] if args.key?(:event_time)
  @event_utc_offset = args[:event_utc_offset] if args.key?(:event_utc_offset)
  @exercise_event_type = args[:exercise_event_type] if args.key?(:exercise_event_type)
end