<!--
{
  "availability" : [
    "iOS: 27.2.0 -",
    "iPadOS: 27.2.0 -",
    "macCatalyst: 27.2.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "HomeExtensions",
  "identifier" : "/documentation/HomeExtensions/HomeAccessoryEnumSettingConstant",
  "metadataVersion" : "0.1.0",
  "role" : "Protocol",
  "symbol" : {
    "kind" : "Protocol",
    "modules" : [
      "HomeExtensions"
    ],
    "preciseIdentifier" : "s:14HomeExtensions0A28AccessoryEnumSettingConstantP"
  },
  "title" : "HomeAccessoryEnumSettingConstant"
}
-->

# HomeAccessoryEnumSettingConstant

A type whose cases are the options for an enumeration setting.

```
protocol HomeAccessoryEnumSettingConstant : CaseIterable, Hashable, RawRepresentable where Self.RawValue : LosslessStringConvertible
```

## Overview

For example, the following code defines an enumeration that has a string raw value:

```swift
enum FanSpeed: String, HomeAccessoryEnumSettingConstant {
    case low, medium, high

    var value: HomeAccessorySettingLabel {
        switch self {
        case .low: HomeAccessorySettingLabel("Low", systemImage: "wind")
        case .medium: HomeAccessorySettingLabel("Medium", systemImage: "wind.circle")
        case .high: HomeAccessorySettingLabel("High", systemImage: "wind.circle.fill")
        }
    }
}
```

## Topics

### Providing a label

[`var value: HomeAccessorySettingLabel`](/documentation/HomeExtensions/HomeAccessoryEnumSettingConstant/value)

The label to display for this setting.

## Relationships

### Inherits From

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

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

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

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

---

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)