init
TypeScriptstatic init(term: string): StringSearchCriteriaSwift declarationinit(term: String)Initializes the type with the specified search term. - Parameters: - term: The search term to use when matching items.
struct · iOS 17.2+ · SDK 27.1
struct StringSearchCriteriaA type that tells your app to match its items against a provided string. Use this type in app intents that match your app’s content against a string-based value. When you define an app intent using the ``AppSchema/SystemIntent/search`` schema or the ``ShowInAppSearchResultsIntent`` protocol, apply this type to the ``ShowInAppSearchResultsIntent/criteria`` property. When your app intent runs, the system sets that property to an instance of this structure and fills it with the search term. When you use this type in your app intent, use the accompanying ``StringSearchScope`` type for the ``ShowInAppSearchResultsIntent/searchScopes`` property.
static init(term: string): StringSearchCriteriaSwift declarationinit(term: String)Initializes the type with the specified search term. - Parameters: - term: The search term to use when matching items.
get term(): stringSwift declarationvar term: StringThe string to use when matching items in your app. Pass the value of this property to the code you use to search for items in your app. The system provides this value when it creates the app intent.
set term(value: string)Swift declarationvar term: StringThe string to use when matching items in your app. Pass the value of this property to the code you use to search for items in your app. The system provides this value when it creates the app intent.
1 declarations were excluded from these bindings. Each reason comes from the generator or the iOS SDK compiler.
StringSearchCriteria.defaultResolverSpecification
This protocol needs associated types that cannot yet cross the bridge.