class Fitbark::Data::DogInfo
Defines structure for dog's informations.
Original attribute names from source API:
-
slug
-
name
-
bluetooth_id
-
activity_value
-
birth
-
breed1
-
breed2
-
gender
-
weight
-
weight_unit
-
country
-
zip
-
tzoffset
-
tzname
-
min_play
-
min_active
-
min_rest
-
medical_conditions
-
hourly_average
-
picture_hash
-
neutered
-
last_min_time
-
last_min_activity
-
daily_goal
-
battery_level
-
last_sync
Public Instance Methods
parse source String value into Date for birth attribute
# File lib/fitbark/data/dog_info.rb, line 36 def birth date_parser(self[:birth]) end
first breed according to Fitbark::Data::Breed
# File lib/fitbark/data/dog_info.rb, line 97 def breed1 init_breed(self[:breed1]) end
second breed according to Fitbark::Data::Breed
# File lib/fitbark/data/dog_info.rb, line 104 def breed2 init_breed(self[:breed2]) end
parse String value into Time for last_min_time attribute
# File lib/fitbark/data/dog_info.rb, line 73 def last_min_time time_parser(self[:last_min_time]) end
parse String value into Time for last_min_activity attribute
# File lib/fitbark/data/dog_info.rb, line 80 def last_minute_activity self[:last_min_activity] end
parse String value into Time for last_sync attribute
# File lib/fitbark/data/dog_info.rb, line 90 def last_sync time_parser(self[:last_sync]) end
an array of Fitbark::Data::MedicalCondition
objects
# File lib/fitbark/data/dog_info.rb, line 111 def medical_conditions self[:medical_conditions].map do |mc| init_medical_condition(mc) end end
an alias for zip attribute
# File lib/fitbark/data/dog_info.rb, line 48 def postal_code self[:zip] end
an alias for source gender attribute
# File lib/fitbark/data/dog_info.rb, line 43 def sex self[:gender] end
an alias for activity_value attribute
# File lib/fitbark/data/dog_info.rb, line 85 def today_activity_points self[:activity_value] end
an alias for min_active attribute
# File lib/fitbark/data/dog_info.rb, line 63 def today_minutes_active self[:min_active] end
an alias for min_play attribute
# File lib/fitbark/data/dog_info.rb, line 58 def today_minutes_playing self[:min_play] end
an alias for min_rest attribute
# File lib/fitbark/data/dog_info.rb, line 68 def today_minutes_resting self[:min_rest] end
an alias for zip attribute
# File lib/fitbark/data/dog_info.rb, line 53 def zip_code self[:zip] end