Initializes the intent object with information about the requested type of code.
- iOS 11.0+
- Mac Catalyst 13.0+
- watchOS 4.0+
The type of visual code that the user requested. For a list of possible values, see
An initialized intent object or
nil if the object could not be created.
Normally, you do not create instances of this class yourself. Instead, SiriKit creates instances when the user asks for a visual code from your app. However, you can use this method during testing to create intent objects in order to validate your intent handling code paths.