ios - How to get the name of HKWorkoutActivityType in HealthKit? -
ok, property workoutactivitytype of hkworkout returns nsinteger.
here list activities: workoutactivitytype list
for now, create plist , activity name when integer. seems little odd have go through this.
do need find out activity on own or there missing?
unfortunately, apple provides enum , have implement own names. idea lazily instantiate dictionary including keys of nsnumber (object wrapped nsinteger) , values of strings. should quite easy make , unfortunately solution.
Comments
Post a Comment