SupportPlaceAutocompleteFragment

public class SupportPlaceAutocompleteFragment extends AutocompleteSupportFragment

A fragment that provides auto-completion for places.

To use this class, you must include the Android support library in your build path.

Public Constructor Summary

Public Method Summary

void
onActivityCreated(Bundle savedInstanceState)
void
setBoundsBias(LatLngBounds bounds)
Biases the autocomplete results to a particular area.
void
setFilter(AutocompleteFilter filter)
Sets a filter on autocomplete predictions.
SupportPlaceAutocompleteFragment
setHint(CharSequence hint)
Sets the hint text to display in the search input field when there is no text entered.
void
setOnPlaceSelectedListener(PlaceSelectionListener listener)
Sets a listener that will be notified when a place is selected.
SupportPlaceAutocompleteFragment
setText(CharSequence text)
Sets the text to display in the search input field.

Inherited Method Summary

Public Constructors

public SupportPlaceAutocompleteFragment ()

Public Methods

public void onActivityCreated (Bundle savedInstanceState)

Parameters
savedInstanceState

public void setBoundsBias (LatLngBounds bounds)

Biases the autocomplete results to a particular area.

If the bounds are unset or explicitly set to null, the autocomplete results will be biased to the device's approximate location.

Parameters
bounds A LatLngBounds object that defines a geographical area using two sets of latitude/longitude coordinates marking the top left and bottom right corners.

public void setFilter (AutocompleteFilter filter)

Sets a filter on autocomplete predictions.

Parameters
filter A filter to use for restricting the returned predictions. If null, a filter with no constraints will be used.

public SupportPlaceAutocompleteFragment setHint (CharSequence hint)

Sets the hint text to display in the search input field when there is no text entered.

Parameters
hint

public void setOnPlaceSelectedListener (PlaceSelectionListener listener)

Sets a listener that will be notified when a place is selected.

Parameters
listener The listener that should be notified.

public SupportPlaceAutocompleteFragment setText (CharSequence text)

Sets the text to display in the search input field.

Parameters
text