Stay organized with collections
Save and categorize content based on your preferences.
public class SearchIntents
Constants for intents to perform in-app search from a Search Action.
Summary
Constants |
static final String |
Intent action for performing an in-app search.
|
static final String |
Intent extra specifying the text query to use as a string for ACTION_SEARCH.
|
Constants
public static final String ACTION_SEARCH = "com.google.android.gms.actions.SEARCH_ACTION"
Intent action for performing an in-app search. The intent should include an optional extra to specify the text to search for EXTRA_QUERY. If no extras are provided, the application should just show an Activity with the search UI activated.
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-10-31 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-10-31 UTC."],[],["`SearchIntents` defines constants for in-app search actions. `ACTION_SEARCH` (\"com.google.android.gms.actions.SEARCH_ACTION\") is the intent action used to initiate an in-app search. The `EXTRA_QUERY` (\"query\") is an optional string extra included in the intent to specify the search term. If `EXTRA_QUERY` is omitted, the application should display the search UI. These constants facilitate integrating in-app search from external sources.\n"]]