SearchInAppsSDK Framework Reference
Stay organized with collections
Save and categorize content based on your preferences.
GetSearchSuggestionsOptions
@objc
final class GetSearchSuggestionsOptions
This class contains all the options necessary to request search suggestions.
-
The client ID used to request search suggestions if it is different from the
client ID specified in Info.plist.
Declaration
Swift
@objc
final var clientId: String?
-
Create options with given location data (i.e. the location context used for generating
location-based search suggestions).
-
Create options with a given text context (i.e. the strings used for generating search
suggestions).
Declaration
Swift
@objc
init(textContext: [String])
-
The information used to generate location-based search suggestions.
-
The text used to generate query-based search suggestions.
Declaration
Swift
@objc
final var textContext: [String]?
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-11-07 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-11-07 UTC."],[[["The `GetSearchSuggestionsOptions` class is used to configure and request search suggestions within an application."],["It allows specifying a `clientId` for authentication, overriding the default one from Info.plist."],["Developers can provide either `locationContext` or `textContext` to generate location-based or query-based suggestions, respectively."],["`locationContext` uses `LocationSuggestionsContext` objects, while `textContext` utilizes an array of strings for input."]]],["The `GetSearchSuggestionsOptions` class provides settings for requesting search suggestions. Key actions include initializing options with either `locationContext` for location-based suggestions or `textContext` for text-based suggestions. `clientId`, which may differ from the Info.plist client ID, can be set. This class contains and manages `locationContext`, an array of `LocationSuggestionsContext`, `textContext`, which is an array of strings, and `clientId`.\n"]]