public class Search extends Object
SearchManager
Modifier and Type | Field and Description |
---|---|
static String |
SOURCE
Key for the source identifier set by the application that launched a search intent.
|
static String |
SUGGEST_COLUMN_LAST_ACCESS_HINT
Column name for suggestions cursor.
|
Modifier and Type | Method and Description |
---|---|
static Cursor |
getSuggestions(Context context,
SearchableInfo searchable,
String query)
Gets a cursor with search suggestions.
|
static Cursor |
getSuggestions(Context context,
SearchableInfo searchable,
String query,
int limit)
Gets a cursor with search suggestions.
|
public static final String SOURCE
SearchManager.APP_DATA
Bundle in Intent.ACTION_SEARCH
and
Intent.ACTION_WEB_SEARCH
intents.public static final String SUGGEST_COLUMN_LAST_ACCESS_HINT
System.currentTimeMillis()
(wall time in UTC) when an item was last
accessed within the results-providing application. If set, this may be
used to show more-recently-used items first.
See SearchManager.SUGGEST_COLUMN_LAST_ACCESS_HINT
in ICS.public static Cursor getSuggestions(Context context, SearchableInfo searchable, String query)
searchable
- Information about how to get the suggestions.query
- The search text entered (so far).null the suggestion query failed.
public static Cursor getSuggestions(Context context, SearchableInfo searchable, String query, int limit)
searchable
- Information about how to get the suggestions.query
- The search text entered (so far).limit
- The query limit to pass to the suggestion provider. This is advisory,
the returned cursor may contain more rows. Pass -1
for no limit.null the suggestion query failed.