Global Variable

HKQuantityTypeIdentifierAppleExerciseTime

A quantity sample type that measures the amount of time the user spent exercising.

Declaration

const HKQuantityTypeIdentifier HKQuantityTypeIdentifierAppleExerciseTime;

Discussion

These samples use time units (described in HKUnit) and measure cumulative values (described in HKStatisticsQuery).

Workout sessions contribute to the exercise time. Apple Watch also tracks exercise time whenever it detects the user moving with an average intensity of a brisk walk or greater. For more information, see Fill the Activity Rings.

See Also

Activity

HKQuantityTypeIdentifierStepCount

A quantity sample type that measures the number of steps the user has taken.

HKQuantityTypeIdentifierDistanceWalkingRunning

A quantity sample type that measures the distance the user has moved by walking or running.

HKQuantityTypeIdentifierDistanceCycling

A quantity sample type that measures the distance the user has moved by cycling.

HKQuantityTypeIdentifierPushCount

A quantity sample type that measures the number of pushes that the user has performed while using a wheelchair.

HKQuantityTypeIdentifierDistanceWheelchair

A quantity sample type that measures the distance the user has moved using a wheelchair.

HKQuantityTypeIdentifierSwimmingStrokeCount

A quantity sample type that measures the number of strokes performed while swimming.

HKQuantityTypeIdentifierDistanceSwimming

A quantity sample type that measures the distance the user has moved while swimming.

HKQuantityTypeIdentifierDistanceDownhillSnowSports

A quantity sample type that measures the distance the user has traveled while skiing or snowboarding.

HKQuantityTypeIdentifierBasalEnergyBurned

A quantity sample type that measures the resting energy burned by the user.

HKQuantityTypeIdentifierActiveEnergyBurned

A quantity sample type that measures the amount of active energy the user has burned.

HKQuantityTypeIdentifierFlightsClimbed

A quantity sample type that measures the number flights of stairs that the user has climbed.

HKQuantityTypeIdentifierNikeFuel

A quantity sample type that measures the number of NikeFuel points the user has earned.

HKCategoryTypeIdentifierAppleStandHour

A category sample type indicating whether the user has stood for at least one minute during the sample.

HKQuantityTypeIdentifierAppleStandTime

A quantity sample type that measures the amount of time the user has spent standing.