Instance Property


A Boolean value that determines whether the query groups the results based on the quantity sample’s start date.


@property(nonatomic, assign) BOOL orderByQuantitySampleStartDate;


By default the query returns all the quantities in ascending order based on their start date. If you set this property to YES, HealthKit first sorts the matching HKQuantitySample objects by their startDate parameter. Then, for each sample, it returns all the quantity objects in ascending order. If the sample objects overlap, then the quantities may not appear in ascending order when switching from one sample to the next.

See Also

Creating a Series Query

- initWithQuantityType:predicate:quantityHandler:

Creates a new query for a series of the specified quantity type.


A Boolean value that determines whether the query should return the series sample.