Overview
GMSAutocompleteResultsViewController provides an interface that displays place autocomplete predictions in a table view.
The table view will be automatically updated as input text changes.
This class is intended to be used as the search results controller of a UISearchController. Pass an instance of GMSAutocompleteResultsViewController
to UISearchController's initWithSearchResultsController method, then set the controller as the UISearchController's searchResultsUpdater property.
Use the GMSAutocompleteResultsViewControllerDelegate
delegate protocol to be notified when a place is selected from the list.
Public Member Functions | |
(void) | - setAutocompleteBoundsUsingNorthEastCorner:SouthWestCorner: |
Sets up the autocomplete bounds using the NE and SW corner locations. | |
Properties | |
id < GMSAutocompleteResultsViewControllerDelegate > | delegate |
Delegate to be notified when a place is selected. | |
GMSCoordinateBounds * | autocompleteBounds |
Bounds used to bias or restrict the autocomplete results depending on the value of autocompleteBoundsMode (can be nil). | |
GMSAutocompleteBoundsMode | autocompleteBoundsMode |
How to treat the autocompleteBounds property. | |
GMSAutocompleteFilter * | autocompleteFilter |
Filter to apply to autocomplete suggestions (can be nil). | |
IBInspectable UIColor * | tableCellBackgroundColor |
The background color of table cells. | |
IBInspectable UIColor * | tableCellSeparatorColor |
The color of the separator line between table cells. | |
IBInspectable UIColor * | primaryTextColor |
The color of result name text in autocomplete results. | |
IBInspectable UIColor * | primaryTextHighlightColor |
The color used to highlight matching text in autocomplete results. | |
IBInspectable UIColor * | secondaryTextColor |
The color of the second row of text in autocomplete results. | |
IBInspectable UIColor * | tintColor |
The tint color applied to controls in the Autocomplete view. | |
GMSPlaceField | placeFields |
Specify individual place details to fetch for object GMSPlace . |
Member Function Documentation
- (void) setAutocompleteBoundsUsingNorthEastCorner: | (CLLocationCoordinate2D) | NorthEastCorner | |
SouthWestCorner: | (CLLocationCoordinate2D) | SouthWestCorner | |
Sets up the autocomplete bounds using the NE and SW corner locations.
Property Documentation
- (id<GMSAutocompleteResultsViewControllerDelegate>) delegate [read, write, assign] |
Delegate to be notified when a place is selected.
- (GMSCoordinateBounds*) autocompleteBounds [read, write, assign] |
Bounds used to bias or restrict the autocomplete results depending on the value of autocompleteBoundsMode
(can be nil).
- (GMSAutocompleteBoundsMode) autocompleteBoundsMode [read, write, assign] |
How to treat the autocompleteBounds
property.
Defaults to kGMSAutocompleteBoundsModeBias
.
Has no effect if autocompleteBounds
is nil.
- (GMSAutocompleteFilter*) autocompleteFilter [read, write, assign] |
Filter to apply to autocomplete suggestions (can be nil).
- (IBInspectable UIColor*) tableCellBackgroundColor [read, write, assign] |
The background color of table cells.
- (IBInspectable UIColor*) tableCellSeparatorColor [read, write, assign] |
The color of the separator line between table cells.
- (IBInspectable UIColor*) primaryTextColor [read, write, assign] |
The color of result name text in autocomplete results.
- (IBInspectable UIColor*) primaryTextHighlightColor [read, write, assign] |
The color used to highlight matching text in autocomplete results.
- (IBInspectable UIColor*) secondaryTextColor [read, write, assign] |
The color of the second row of text in autocomplete results.
- (IBInspectable UIColor*) tintColor [read, write, assign] |
The tint color applied to controls in the Autocomplete view.
- (GMSPlaceField) placeFields [read, write, assign] |
Specify individual place details to fetch for object GMSPlace
.
Defaults to returning all details if not overridden.