HealthKit · IOS API REFERENCE
HKCategorySample
class · iOS 8.0+ · SDK 27.1
class HKCategorySample
Members (5)
init · iOS 8.0+init
TypeScriptstatic initTypeValueStartEnd(type: HKCategoryType, value: number, startDate: globalThis.Date, endDate: globalThis.Date): HKCategorySample
Swift declarationconvenience init(type: HKCategoryType, value: Int, start startDate: Date, end endDate: Date)
init · iOS 9.0+init
TypeScriptstatic initTypeValueStartEndDeviceMetadata(type: HKCategoryType, value: number, startDate: globalThis.Date, endDate: globalThis.Date, device?: (HKDevice) | null, metadata?: (Record<string, unknown>) | null): HKCategorySample
Swift declarationconvenience init(type: HKCategoryType, value: Int, start startDate: Date, end endDate: Date, device: HKDevice?, metadata: [String : Any]?)
init · iOS 8.0+init
TypeScriptstatic initTypeValueStartEndMetadata(type: HKCategoryType, value: number, startDate: globalThis.Date, endDate: globalThis.Date, metadata?: (Record<string, unknown>) | null): HKCategorySample
Swift declarationconvenience init(type: HKCategoryType, value: Int, start startDate: Date, end endDate: Date, metadata: [String : Any]?)
get · iOS 8.0+categoryType
TypeScriptget categoryType(): HKCategoryType
Swift declarationvar categoryType: HKCategoryType { get }
get · iOS 8.0+value
TypeScriptget value(): number
Swift declarationvar value: Int { get }
Skipped declarations
1 declarations were excluded from these bindings. Each reason comes from the generator or the iOS SDK compiler.
HKCategorySample.init()
inherited init: cannot prove legal (class declares 6 custom initializers)
All HealthKit types →