---
title: "init(_:_:)"
framework: appintents
role: symbol
role_heading: Initializer
path: "appintents/parametersummaryswitchcondition/init(_:_:)-8b7di"
---

# init(_:_:)

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

## Declaration

```swift
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
