init(description:defaultValue:defaultUnit:defaultUnitAdjustForLocale:supportsNegativeNumbers:requestValueDialog:inputConnectionBehavior:)
Creates an app intent parameter with a default unit for the measurement.
Declaration
convenience init(description: LocalizedStringResource? = nil, defaultValue: Double? = nil, defaultUnit: IntentParameter<Value>.Energy? = nil, defaultUnitAdjustForLocale: Bool = false, supportsNegativeNumbers: Bool = true, requestValueDialog: IntentDialog? = nil, inputConnectionBehavior: InputConnectionBehavior = .default)Parameters
- description:
Additional details about this parameter.
- defaultValue:
The default value for this parameter. People can specify a different value.
- defaultUnit:
The default unit that should be selected when this parameter is initially created.
- defaultUnitAdjustForLocale:
Whether or not the default unit should adjust to match someone’s locale. Default value is
false. - supportsNegativeNumbers:
Whether or not this parameter supports negative number inputs. Default value is
true. - requestValueDialog:
A prompt that asks a person to provide the parameter value.
- inputConnectionBehavior:
An enum that indicates how this parameter receives the output from a preceding app intent.