class Google::Apis::FitnessV1::Session

Sessions contain metadata, such as a user-friendly name and time interval information.

Attributes

active_time_millis[RW]

Session active time. While start_time_millis and end_time_millis define the full session time, the active time can be shorter and specified by active_time_millis. If the inactive time during the session is known, it should also be inserted via a com.google.activity.segment data point with a STILL activity value Corresponds to the JSON property `activeTimeMillis` @return [Fixnum]

activity_type[RW]

The type of activity this session represents. Corresponds to the JSON property `activityType` @return [Fixnum]

application[RW]

The application that created the session. Corresponds to the JSON property `application` @return [Google::Apis::FitnessV1::Application]

description[RW]

A description for this session. Corresponds to the JSON property `description` @return [String]

end_time_millis[RW]

An end time, in milliseconds since epoch, inclusive. Corresponds to the JSON property `endTimeMillis` @return [Fixnum]

id[RW]

A client-generated identifier that is unique across all sessions owned by this particular user. Corresponds to the JSON property `id` @return [String]

modified_time_millis[RW]

A timestamp that indicates when the session was last modified. Corresponds to the JSON property `modifiedTimeMillis` @return [Fixnum]

name[RW]

A human readable name of the session. Corresponds to the JSON property `name` @return [String]

start_time_millis[RW]

A start time, in milliseconds since epoch, inclusive. Corresponds to the JSON property `startTimeMillis` @return [Fixnum]

Public Class Methods

new(**args) click to toggle source
# File lib/google/apis/fitness_v1/classes.rb, line 893
def initialize(**args)
   update!(**args)
end

Public Instance Methods

update!(**args) click to toggle source

Update properties of this object

# File lib/google/apis/fitness_v1/classes.rb, line 898
def update!(**args)
  @active_time_millis = args[:active_time_millis] if args.key?(:active_time_millis)
  @activity_type = args[:activity_type] if args.key?(:activity_type)
  @application = args[:application] if args.key?(:application)
  @description = args[:description] if args.key?(:description)
  @end_time_millis = args[:end_time_millis] if args.key?(:end_time_millis)
  @id = args[:id] if args.key?(:id)
  @modified_time_millis = args[:modified_time_millis] if args.key?(:modified_time_millis)
  @name = args[:name] if args.key?(:name)
  @start_time_millis = args[:start_time_millis] if args.key?(:start_time_millis)
end