Package com.google.maps.model
Class AutocompletePrediction
- java.lang.Object
-
- com.google.maps.model.AutocompletePrediction
-
- All Implemented Interfaces:
java.io.Serializable
public class AutocompletePrediction extends java.lang.Object implements java.io.Serializable
Represents a single Autocomplete result returned from the Google Places API Web Service.Please see Query Autocomplete Responses for more detail.
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
AutocompletePrediction.MatchedSubstring
Describes the location of the entered term in the prediction result text, so that the term can be highlighted if desired.static class
AutocompletePrediction.Term
Identifies each section of the returned description.
-
Field Summary
Fields Modifier and Type Field Description java.lang.String
description
Description of the matched prediction.java.lang.Integer
distanceMeters
The distance in meters of the place from thePlaceAutocompleteRequest.origin(LatLng)
.AutocompletePrediction.MatchedSubstring[]
matchedSubstrings
The locations of the entered term in the prediction result text, so that the term can be highlighted if desired.java.lang.String
placeId
The Place ID of the place.AutocompleteStructuredFormatting
structuredFormatting
A description of how the autocomplete query matched the returned result.AutocompletePrediction.Term[]
terms
An array of terms identifying each section of the returned description.java.lang.String[]
types
An array indicating the type of the address component.
-
Constructor Summary
Constructors Constructor Description AutocompletePrediction()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
toString()
-
-
-
Field Detail
-
description
public java.lang.String description
Description of the matched prediction.
-
placeId
public java.lang.String placeId
The Place ID of the place.
-
types
public java.lang.String[] types
An array indicating the type of the address component.Please see supported types for a list of types that can be returned.
-
terms
public AutocompletePrediction.Term[] terms
An array of terms identifying each section of the returned description. (A section of the description is generally terminated with a comma.) Each entry in the array has a value field, containing the text of the term, and an offset field, defining the start position of this term in the description, measured in Unicode characters.
-
distanceMeters
public java.lang.Integer distanceMeters
The distance in meters of the place from thePlaceAutocompleteRequest.origin(LatLng)
. Optional.
-
matchedSubstrings
public AutocompletePrediction.MatchedSubstring[] matchedSubstrings
The locations of the entered term in the prediction result text, so that the term can be highlighted if desired.
-
structuredFormatting
public AutocompleteStructuredFormatting structuredFormatting
A description of how the autocomplete query matched the returned result.
-
-