Class: Google::Apis::HealthV4::Settings

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

Settings details.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Settings

Returns a new instance of Settings.



4921
4922
4923
# File 'lib/google/apis/health_v4/classes.rb', line 4921

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

Instance Attribute Details

#auto_stride_enabledBoolean Also known as: auto_stride_enabled?

Optional. True if the user's stride length is determined automatically. Updates to this field are currently not supported. Corresponds to the JSON property autoStrideEnabled

Returns:

  • (Boolean)


4833
4834
4835
# File 'lib/google/apis/health_v4/classes.rb', line 4833

def auto_stride_enabled
  @auto_stride_enabled
end

#distance_unitString

Optional. The measurement unit defined in the user's account settings. Updates to this field are currently not supported. Corresponds to the JSON property distanceUnit

Returns:

  • (String)


4840
4841
4842
# File 'lib/google/apis/health_v4/classes.rb', line 4840

def distance_unit
  @distance_unit
end

#food_language_codeString

Output only. The food language code derived from the user's food database. Possible values: 'en-US', 'en-GB', 'de-DE', 'es-ES', 'fr-FR', 'zh- CN', 'zh-TW', 'ja-JP', 'en-AU', 'en-CA', 'it-IT', 'ko-KR', 'es- MX', 'en-IN', 'en-SG', 'en-PH', 'en-IE', 'fr-CA'. Updates to this field are currently not supported. Corresponds to the JSON property foodLanguageCode

Returns:

  • (String)


4849
4850
4851
# File 'lib/google/apis/health_v4/classes.rb', line 4849

def food_language_code
  @food_language_code
end

#glucose_unitString

Optional. The measurement unit defined in the user's account settings. Corresponds to the JSON property glucoseUnit

Returns:

  • (String)


4854
4855
4856
# File 'lib/google/apis/health_v4/classes.rb', line 4854

def glucose_unit
  @glucose_unit
end

#height_unitString

Optional. The measurement unit defined in the user's account settings. Corresponds to the JSON property heightUnit

Returns:

  • (String)


4859
4860
4861
# File 'lib/google/apis/health_v4/classes.rb', line 4859

def height_unit
  @height_unit
end

#language_localeString

Optional. The locale defined in the user's account settings. Updates to this field are currently not supported. Corresponds to the JSON property languageLocale

Returns:

  • (String)


4865
4866
4867
# File 'lib/google/apis/health_v4/classes.rb', line 4865

def language_locale
  @language_locale
end

#nameString

Identifier. The resource name of this Settings resource. Format: users/user/ settings Example: users/1234567890/settings or users/me/settings The user ID is a system-generated Google Health API user ID, a string of 1-63 characters consisting of lowercase and uppercase letters, numbers, and hyphens. The literal me can also be used to refer to the authenticated user. Corresponds to the JSON property name

Returns:

  • (String)


4874
4875
4876
# File 'lib/google/apis/health_v4/classes.rb', line 4874

def name
  @name
end

#stride_length_running_typeString

Optional. The stride length type defined in the user's account settings for running. Updates to this field are currently not supported. Corresponds to the JSON property strideLengthRunningType

Returns:

  • (String)


4880
4881
4882
# File 'lib/google/apis/health_v4/classes.rb', line 4880

def stride_length_running_type
  @stride_length_running_type
end

#stride_length_walking_typeString

Optional. The stride length type defined in the user's account settings for walking. Updates to this field are currently not supported. Corresponds to the JSON property strideLengthWalkingType

Returns:

  • (String)


4886
4887
4888
# File 'lib/google/apis/health_v4/classes.rb', line 4886

def stride_length_walking_type
  @stride_length_walking_type
end

#swim_unitString

Optional. The measurement unit defined in the user's account settings. Corresponds to the JSON property swimUnit

Returns:

  • (String)


4891
4892
4893
# File 'lib/google/apis/health_v4/classes.rb', line 4891

def swim_unit
  @swim_unit
end

#temperature_unitString

Optional. The measurement unit defined in the user's account settings. Corresponds to the JSON property temperatureUnit

Returns:

  • (String)


4896
4897
4898
# File 'lib/google/apis/health_v4/classes.rb', line 4896

def temperature_unit
  @temperature_unit
end

#time_zoneString

Optional. The timezone defined in the user's account settings. This follows the IANA Time Zone Database. Updates to this field are currently not supported. Corresponds to the JSON property timeZone

Returns:

  • (String)


4903
4904
4905
# File 'lib/google/apis/health_v4/classes.rb', line 4903

def time_zone
  @time_zone
end

#utc_offsetString

Optional. The user's timezone offset relative to UTC. Updates to this field are currently not supported. Corresponds to the JSON property utcOffset

Returns:

  • (String)


4909
4910
4911
# File 'lib/google/apis/health_v4/classes.rb', line 4909

def utc_offset
  @utc_offset
end

#water_unitString

Optional. The measurement unit defined in the user's account settings. Corresponds to the JSON property waterUnit

Returns:

  • (String)


4914
4915
4916
# File 'lib/google/apis/health_v4/classes.rb', line 4914

def water_unit
  @water_unit
end

#weight_unitString

Optional. The measurement unit defined in the user's account settings. Corresponds to the JSON property weightUnit

Returns:

  • (String)


4919
4920
4921
# File 'lib/google/apis/health_v4/classes.rb', line 4919

def weight_unit
  @weight_unit
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



4926
4927
4928
4929
4930
4931
4932
4933
4934
4935
4936
4937
4938
4939
4940
4941
4942
# File 'lib/google/apis/health_v4/classes.rb', line 4926

def update!(**args)
  @auto_stride_enabled = args[:auto_stride_enabled] if args.key?(:auto_stride_enabled)
  @distance_unit = args[:distance_unit] if args.key?(:distance_unit)
  @food_language_code = args[:food_language_code] if args.key?(:food_language_code)
  @glucose_unit = args[:glucose_unit] if args.key?(:glucose_unit)
  @height_unit = args[:height_unit] if args.key?(:height_unit)
  @language_locale = args[:language_locale] if args.key?(:language_locale)
  @name = args[:name] if args.key?(:name)
  @stride_length_running_type = args[:stride_length_running_type] if args.key?(:stride_length_running_type)
  @stride_length_walking_type = args[:stride_length_walking_type] if args.key?(:stride_length_walking_type)
  @swim_unit = args[:swim_unit] if args.key?(:swim_unit)
  @temperature_unit = args[:temperature_unit] if args.key?(:temperature_unit)
  @time_zone = args[:time_zone] if args.key?(:time_zone)
  @utc_offset = args[:utc_offset] if args.key?(:utc_offset)
  @water_unit = args[:water_unit] if args.key?(:water_unit)
  @weight_unit = args[:weight_unit] if args.key?(:weight_unit)
end