<!--
{
  "availability" : [
    "iOS: 16.0.0 -",
    "iPadOS: 16.0.0 -",
    "macCatalyst: 16.0.0 -",
    "macOS: 13.0.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 9.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "HealthKit",
  "identifier" : "/documentation/HealthKit/HKLensSpecification",
  "metadataVersion" : "0.1.0",
  "role" : "Class",
  "symbol" : {
    "kind" : "Class",
    "modules" : [
      "HealthKit"
    ],
    "preciseIdentifier" : "c:objc(cs)HKLensSpecification"
  },
  "title" : "HKLensSpecification"
}
-->

# HKLensSpecification

An abstract superclass for lens specifications.

```
class HKLensSpecification
```

## Overview

Don’t instantiate this class directly. Instead, use one of its concrete subclasses: [`HKGlassesLensSpecification`](/documentation/HealthKit/HKGlassesLensSpecification) or [`HKContactsLensSpecification`](/documentation/HealthKit/HKContactsLensSpecification).

## Topics

### Accessing lens specification data

[`var sphere: HKQuantity`](/documentation/HealthKit/HKLensSpecification/sphere)

The correction for farsightedness.

[`var cylinder: HKQuantity?`](/documentation/HealthKit/HKLensSpecification/cylinder)

Part of the correction for astigmatism that measures the strength of the correction.

[`var axis: HKQuantity?`](/documentation/HealthKit/HKLensSpecification/axis)

Part of the correction for astigmatism that measures the orientation fo the correction.

[`var addPower: HKQuantity?`](/documentation/HealthKit/HKLensSpecification/addPower)

The correction for nearsightedness.

## Relationships

### Conforms To

[`SendableMetatype`](/documentation/Swift/SendableMetatype)

[`Hashable`](/documentation/Swift/Hashable)

[`Sendable`](/documentation/Swift/Sendable)

[`NSObjectProtocol`](/documentation/ObjectiveC/NSObjectProtocol)

[`Equatable`](/documentation/Swift/Equatable)

[`CVarArg`](/documentation/Swift/CVarArg)

[`CustomStringConvertible`](/documentation/Swift/CustomStringConvertible)

[`CustomDebugStringConvertible`](/documentation/Swift/CustomDebugStringConvertible)

### Inherited By

[`HKGlassesLensSpecification`](/documentation/HealthKit/HKGlassesLensSpecification)

[`HKContactsLensSpecification`](/documentation/HealthKit/HKContactsLensSpecification)

### Inherits From

[`NSObject-swift.class`](/documentation/ObjectiveC/NSObject-swift.class)

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)