Class: TeslaAPI::GUISettings
Overview
Defines the current user settings for the vehicle’s graphical display
Instance Method Summary collapse
-
#gui_24_hour_time? ⇒ Boolean
true if the UI show 24 hour time (e.g. 17:45).
-
#gui_charge_rate_units ⇒ String
Units (“kW”) for showing charge rage.
-
#gui_distance_units ⇒ String
Units (“mi/hr”) for showing range.
-
#gui_range_display ⇒ String
Units (“Rated”, “Ideal”) for showing range.
-
#gui_temperature_units ⇒ String
Units (“F”, “C”) for showing temperaturs.
-
#initialize(data) ⇒ GUISettings
constructor
A new instance of GUISettings.
Methods inherited from Data
#inspect, #ivar_from_data, #method_missing, #respond_to_missing?
Constructor Details
#initialize(data) ⇒ GUISettings
Returns a new instance of GUISettings.
25 26 27 28 29 30 31 |
# File 'lib/tesla-api/gui_settings.rb', line 25 def initialize(data) ivar_from_data("gui_distance_units", "gui_distance_units", data) ivar_from_data("gui_temperature_units", "gui_temperature_units", data) ivar_from_data("gui_charge_rate_units", "gui_charge_rate_units", data) ivar_from_data("gui_24_hour_time", "gui_24_hour_time", data) ivar_from_data("gui_range_display", "gui_range_display", data) end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class TeslaAPI::Data
Instance Method Details
#gui_24_hour_time? ⇒ Boolean
true if the UI show 24 hour time (e.g. 17:45)
21 22 23 |
# File 'lib/tesla-api/gui_settings.rb', line 21 def gui_24_hour_time? @gui_24_hour_time end |
#gui_charge_rate_units ⇒ String
Returns Units (“kW”) for showing charge rage.
|
# File 'lib/tesla-api/gui_settings.rb', line 12
|
#gui_distance_units ⇒ String
Returns Units (“mi/hr”) for showing range.
|
# File 'lib/tesla-api/gui_settings.rb', line 4
|
#gui_range_display ⇒ String
Returns Units (“Rated”, “Ideal”) for showing range.
|
# File 'lib/tesla-api/gui_settings.rb', line 16
|
#gui_temperature_units ⇒ String
Returns Units (“F”, “C”) for showing temperaturs.
|
# File 'lib/tesla-api/gui_settings.rb', line 8
|