Go to Google Earth Home
Google Earth COM API Documentation Document Version: 1.0 - Last modified:


ISearchControllerGE Interface Reference

This contains search options and controls. More...

import "earth.idl";

List of all members.

Public Member Functions

HRESULT Search ([in] BSTR searchString)
 Performs a regular search.
HRESULT IsSearchInProgress ([out, retval] BOOL *inProgress)
 Checks if there is any search currently in progress.
HRESULT GetResults ([out, retval] IFeatureCollectionGE **pResults)
 Retrieves search results.
HRESULT ClearResults ()
 Clears all search results.


Detailed Description

This contains search options and controls.

Use this interface to control searches and their results.

To get an instance of ISearchControllerGE, call IApplicationGE::SearchController.

Note:
This interface always reflects the current state of the application's search, even if changes occur after creation.
Associated GUIDs:
See also:
IApplicationGE::TourController


Member Function Documentation

HRESULT ISearchControllerGE::Search ( [in] BSTR  searchString  ) 

Performs a regular search.

Performs a search given a search string. This search string may represent a location, driving directions, businesses, or anything else possible through Google Earth's regular search box.

There is a limit on the number of searches within a certain time period. When this limit is exceeded, the function returns E_USAGE_LIMIT_EXCEEDED, and the search is not performed. This restriction is subject to change.

Note:
This function may return before search is actually complete, which means that GetResults might not immediately reflect very recent searches made. Use IsSearchInProgress to check if there is a search in progress.
Parameters:
searchString string containing search parameters. Could contain special keywords such as "near", "from:", "to:", etc.
Return values:
S_OK Successfully performing search. Returns successfully even if search will not yield any results.
E_USAGE_LIMIT_EXCEEDED Exceeded maximum number of searches within a certain time period.
(other) Appropriate error code.
See also:
IsSearchInProgress, GetResults

HRESULT ISearchControllerGE::IsSearchInProgress ( [out, retval] BOOL *  inProgress  ) 

Checks if there is any search currently in progress.

Useful for knowing when search is complete after calling Search and before calling GetResults.

Parameters:
inProgress output boolean representing whether or not a search is in progress.
Return values:
S_OK Successfully retrieved value for inProgress.
(other) Appropriate error code.

HRESULT ISearchControllerGE::GetResults ( [out, retval] IFeatureCollectionGE **  pResults  ) 

Retrieves search results.

Retrieves the collection of features in the search results.

Note:
Searches may take a few moments to complete, which means that GetResults might not immediately reflect very recent searches made. Use IsSearchInProgress to check if there is a search in progress.
Parameters:
pResults retrieved collection of results. If function returns succesfully, results may be returned as an empty collection, but never NULL.
Return values:
S_OK Successfully retrieved features.
(other) Appropriate error code.
See also:
Search, IsSearchInProgress, IApplicationGE::GetMyPlaces, IApplicationGE::GetTemporaryPlaces, IApplicationGE::GetLayersDatabases

HRESULT ISearchControllerGE::ClearResults (  ) 

Clears all search results.

Clears all the features from search results.

Return values:
S_OK Successfully cleared search results.
(other) Appropriate error code.
See also:
Search


The documentation for this interface was generated from the following file:

Google Earth
     
©2008 Google - Google Home - About Google