public class PlacesApi
extends java.lang.Object
See also: Places API Web Service documentation.
Modifier and Type | Method and Description |
---|---|
static NearbySearchRequest |
nearbySearchNextPage(GeoApiContext context,
java.lang.String nextPageToken)
Retrieve the next page of Text Search results.
|
static NearbySearchRequest |
nearbySearchQuery(GeoApiContext context,
LatLng location)
Perform a search for nearby Places.
|
static PhotoRequest |
photo(GeoApiContext context,
java.lang.String photoReference)
Request a Photo from a PhotoReference.
|
static PlaceAutocompleteRequest |
placeAutocomplete(GeoApiContext context,
java.lang.String input)
The Place Autocomplete service can match on full words as well as substrings.
|
static PlaceDetailsRequest |
placeDetails(GeoApiContext context,
java.lang.String placeId)
Request the details of a Place.
|
static QueryAutocompleteRequest |
queryAutocomplete(GeoApiContext context,
java.lang.String input)
Query Autocomplete allows you to add on-the-fly geographic query predictions to your
application.
|
static RadarSearchRequest |
radarSearchQuery(GeoApiContext context,
LatLng location,
int radius)
Perform a radar search for up to 200 places, but with less detail than is returned from Text
Search or Nearby Search.
|
static TextSearchRequest |
textSearchNextPage(GeoApiContext context,
java.lang.String nextPageToken)
Retrieve the next page of Text Search results.
|
static TextSearchRequest |
textSearchQuery(GeoApiContext context,
java.lang.String query)
Perform a search for Places using a text query — for example "pizza in New York" or "shoe
stores near Ottawa".
|
public static NearbySearchRequest nearbySearchQuery(GeoApiContext context, LatLng location)
context
- The context on which to make Geo API requests.location
- The latitude/longitude around which to retrieve place information.public static NearbySearchRequest nearbySearchNextPage(GeoApiContext context, java.lang.String nextPageToken)
context
- The context on which to make Geo API requests.nextPageToken
- The nextPageToken returned as part of a PlaceSearchResponse.public static TextSearchRequest textSearchQuery(GeoApiContext context, java.lang.String query)
context
- The context on which to make Geo API requests.query
- The text string on which to search, for example: "restaurant".public static TextSearchRequest textSearchNextPage(GeoApiContext context, java.lang.String nextPageToken)
context
- The context on which to make Geo API requests.nextPageToken
- The nextPageToken returned as part of a PlaceSearchResponse.public static RadarSearchRequest radarSearchQuery(GeoApiContext context, LatLng location, int radius)
context
- The context on which to make Geo API requests.location
- The location around which to retrieve place information.radius
- The distance in meters within which to return place results.public static PlaceDetailsRequest placeDetails(GeoApiContext context, java.lang.String placeId)
context
- The context on which to make Geo API requests.placeId
- The PlaceID to request details on.public static PhotoRequest photo(GeoApiContext context, java.lang.String photoReference)
Note: If you want to use a Photo in a web browser, please retrieve the photos for a place via our JavaScript Places Library. Likewise, on Android, Places Photos can be retrieved using the Google Places API for Android.
context
- The context on which to make Geo API requests.photoReference
- The reference to the photo to retrieve.public static PlaceAutocompleteRequest placeAutocomplete(GeoApiContext context, java.lang.String input)
context
- The context on which to make Geo API requests.input
- input is the text string on which to search.public static QueryAutocompleteRequest queryAutocomplete(GeoApiContext context, java.lang.String input)
context
- The context on which to make Geo API requests.input
- input is the text string on which to search.