FindAutocompletePredictionsRequest.Builder

public static abstract class FindAutocompletePredictionsRequest.Builder extends Object

Public Constructor Summary

Public Method Summary

abstract FindAutocompletePredictionsRequest
build()
abstract FindAutocompletePredictionsRequest.Builder
setCancellationToken(CancellationToken cancellationToken)
Sets the CancellationToken used by PlacesClient to cancel any yet-to-be-executed requests.
abstract FindAutocompletePredictionsRequest.Builder
setCountry(String countryCode)
Sets the country to restrict results to.
abstract FindAutocompletePredictionsRequest.Builder
setLocationBias(LocationBias locationBias)
Sets the location where autocomplete predictions are to be biased towards.
abstract FindAutocompletePredictionsRequest.Builder
setLocationRestriction(LocationRestriction locationRestriction)
Sets the location where autocomplete predictions are to be restricted within.
abstract FindAutocompletePredictionsRequest.Builder
setQuery(String query)
Sets the query string for which the autocomplete predictions are to be fetched.
abstract FindAutocompletePredictionsRequest.Builder
setSessionToken(AutocompleteSessionToken sessionToken)
Sets the AutocompleteSessionToken for sessionizing multiple instances of FindAutocompletePredictionsRequest.
abstract FindAutocompletePredictionsRequest.Builder
setTypeFilter(TypeFilter typeFilter)
Sets the filter used to restrict the type of the results returned.

Inherited Method Summary

Public Constructors

public FindAutocompletePredictionsRequest.Builder ()

Public Methods

public abstract FindAutocompletePredictionsRequest build ()

public abstract FindAutocompletePredictionsRequest.Builder setCancellationToken (CancellationToken cancellationToken)

Sets the CancellationToken used by PlacesClient to cancel any yet-to-be-executed requests.

Parameters
cancellationToken

public abstract FindAutocompletePredictionsRequest.Builder setCountry (String countryCode)

Sets the country to restrict results to. This should be a ISO 3166-1 Alpha-2 country code (case insensitive). If null or empty, no country filtering will take place.

Parameters
countryCode

public abstract FindAutocompletePredictionsRequest.Builder setLocationBias (LocationBias locationBias)

Sets the location where autocomplete predictions are to be biased towards. If null, no location biases will be imposed.

Note that the autocomplete predictions will not necessarily be within the location specified. To enforce a restriction, use setLocationRestriction(LocationRestriction). You may not set both LocationBias and LocationRestriction simultaneously.

Parameters
locationBias

public abstract FindAutocompletePredictionsRequest.Builder setLocationRestriction (LocationRestriction locationRestriction)

Sets the location where autocomplete predictions are to be restricted within. If null, no location restrictions will be imposed.

To bias autocomplete predictions to a given location, use setLocationBias(LocationBias). You may not set both LocationBias and LocationRestriction simultaneously.

Parameters
locationRestriction

public abstract FindAutocompletePredictionsRequest.Builder setQuery (String query)

Sets the query string for which the autocomplete predictions are to be fetched. If null or empty, no predictions will be returned.

Parameters
query

public abstract FindAutocompletePredictionsRequest.Builder setSessionToken (AutocompleteSessionToken sessionToken)

Sets the AutocompleteSessionToken for sessionizing multiple instances of FindAutocompletePredictionsRequest.

Parameters
sessionToken

public abstract FindAutocompletePredictionsRequest.Builder setTypeFilter (TypeFilter typeFilter)

Sets the filter used to restrict the type of the results returned.

Possible values:

Parameters
typeFilter

Enviar comentários sobre…