SearchInAppsService

public class SearchInAppsService


Interface for accessing SearchInApps features. To use this class, apps need to set the meta-data values for com.google.searchinapps.API_KEY and com.google.searchinapps.CLIENT_ID in their AndroidManifest.xml.

Summary

Public methods

static SearchInAppsService
create(Context context)

Creates a SearchInAppsService.

void
getSearchContentView(
    GetSearchContentViewOptions getSearchContentViewOptions,
    GetSearchContentViewGeneratorCallback callback
)

Called to get search content UI view.

void

Called to get search suggestions UI view.

void

Called to get trending searches UI view.

void

Shut down the service and release its resources.

Public methods

create

public static SearchInAppsService create(Context context)

Creates a SearchInAppsService.

Parameters
Context context

Activity context.

getSearchContentView

public void getSearchContentView(
    GetSearchContentViewOptions getSearchContentViewOptions,
    GetSearchContentViewGeneratorCallback callback
)

Called to get search content UI view. Callback will happen on the same calling thread.

Parameters
GetSearchContentViewOptions getSearchContentViewOptions

options needed for retrieving search content UI view.

GetSearchContentViewGeneratorCallback callback

callback to be invoked when search content UI view are retrieved.

getSearchSuggestionsView

public void getSearchSuggestionsView(
    GetSearchSuggestionsViewOptions getSearchSuggestionsViewOptions,
    GetSearchSuggestionsViewGeneratorCallback callback
)

Called to get search suggestions UI view. Callback will happen on the same calling thread.

Parameters
GetSearchSuggestionsViewOptions getSearchSuggestionsViewOptions

options needed for retrieving search suggestions UI view.

GetSearchSuggestionsViewGeneratorCallback callback

callback to be invoked when search suggestions UI view are retrieved.

getTrendingSearchesView

public void getTrendingSearchesView(
    GetTrendingSearchesViewOptions getTrendingSearchesViewOptions,
    GetSearchSuggestionsViewGeneratorCallback callback
)

Called to get trending searches UI view. Callback will happen on the same calling thread.

Parameters
GetTrendingSearchesViewOptions getTrendingSearchesViewOptions

options needed for retrieving trending searches UI view.

GetSearchSuggestionsViewGeneratorCallback callback

callback to be invoked when trending searches UI view are retrieved.

shutDown

public void shutDown()

Shut down the service and release its resources.