<!--
{
  "availability" : [
    "iOS: 27.0.0 -",
    "iPadOS: 27.0.0 -",
    "macCatalyst: -",
    "macOS: 27.0.0 -",
    "tvOS: 27.0.0 -",
    "visionOS: 27.0.0 -",
    "watchOS: 27.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "AppIntents",
  "identifier" : "/documentation/AppIntents/ParameterSummarySwitchCondition/init(_:_:)-8b7di",
  "metadataVersion" : "0.1.0",
  "role" : "Initializer",
  "symbol" : {
    "kind" : "Initializer",
    "modules" : [
      "App Intents",
      "AppIntents"
    ],
    "preciseIdentifier" : "s:10AppIntents31ParameterSummarySwitchConditionVyACyxq_q0_Gs7KeyPathCyxAA06IntentC0Cyq_GG_q0_yXEtcs8SendableR_AA0A10UnionValue0L4TypeRp_rlufc"
  },
  "title" : "init(_:_:)"
}
-->

# init(_:_:)

Creates a `Switch` statement that branches based on union value parameter cases.

```
init(_ keyPath: KeyPath<Intent, IntentParameter<Value>>, @ParameterSummaryCaseBuilder<Intent, Value.ValueType.Cases> _ builder: () -> CaseCondition) where Value : Sendable, Value.ValueType : AppUnionValue
```

## Parameters

`keyPath`

Key path to the union value parameter

`builder`

A result builder that constructs the case conditions

---

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)