com.google.gwt.maps.client.geocode
Class Placemark

java.lang.Object
  extended by com.google.gwt.core.client.JavaScriptObject
      extended by com.google.gwt.maps.client.geocode.Placemark

public class Placemark
extends com.google.gwt.core.client.JavaScriptObject

This class represents a JSON result returned from the Google Geocoding service. This object contains an address encoded in eXtensible Address Language(xAL) from OASIS.


Nested Class Summary
static class Placemark.ExtendedData
          This class represents a JSON ExtendedData object being part of result returned from the Google Geocoding service.
 
Constructor Summary
protected Placemark()
          A protected constructor is required for JS overlays.
 
Method Summary
 int getAccuracy()
          An attribute indicating how accurately the Google servers were able to geocode the given address.
 java.lang.String getAddress()
          Returns the entire address for this result.
 java.lang.String getAdministrativeArea()
          The xAL field for "AdministrativeArea", often referred to as 'state'.
 java.lang.String getCity()
          xAL field for "LocalityName" returned by the query.
 java.lang.String getCountry()
          The xAL field "CountryNameCode" for the country code.
 java.lang.String getCounty()
          The xAL field for "SubAdministrativeAreaName".
 Placemark.ExtendedData getExtendedData()
          Returns class grouping additional information regarding geocoding.
 java.lang.String getLocality()
           
 LatLng getPoint()
          Returns the point corresponding to the decoded address.
 java.lang.String getPostalCode()
          The xAL field for "PostalCode".
 java.lang.String getState()
          The xAL field for "AdministrativeArea".
 java.lang.String getStreet()
          The xAL field for "ThoroughfareName".
 java.lang.String getSubAdministrativeArea()
          The xAL field for "SubAdministrativeAreaName", often called "county".
 
Methods inherited from class com.google.gwt.core.client.JavaScriptObject
cast, createArray, createFunction, createObject, equals, hashCode, toSource, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Placemark

protected Placemark()
A protected constructor is required for JS overlays.

Method Detail

getAccuracy

public final int getAccuracy()
An attribute indicating how accurately the Google servers were able to geocode the given address.

Returns:
one of the integer values defined in GeoAddressAccuracy

getAddress

public final java.lang.String getAddress()
Returns the entire address for this result.

Returns:
a nicely formatted and properly capitalized version of the address including city, state, postal code and country.

getAdministrativeArea

public final java.lang.String getAdministrativeArea()
The xAL field for "AdministrativeArea", often referred to as 'state'.

Returns:
the name of the administrative area.

getCity

public final java.lang.String getCity()
xAL field for "LocalityName" returned by the query.

Returns:
the name of the city for the address.

getCountry

public final java.lang.String getCountry()
The xAL field "CountryNameCode" for the country code.

Returns:
a two letter country code for the address.

getCounty

public final java.lang.String getCounty()
The xAL field for "SubAdministrativeAreaName".

Returns:
the name of the county

getExtendedData

public final Placemark.ExtendedData getExtendedData()
Returns class grouping additional information regarding geocoding.

Returns:
class providing additional information.

getLocality

public final java.lang.String getLocality()

getPoint

public final LatLng getPoint()
Returns the point corresponding to the decoded address.

Returns:
the point corresponding to the decoded address.

getPostalCode

public final java.lang.String getPostalCode()
The xAL field for "PostalCode".

Returns:
the postal code to use with the address.

getState

public final java.lang.String getState()
The xAL field for "AdministrativeArea".

Returns:
the name of the state.

getStreet

public final java.lang.String getStreet()
The xAL field for "ThoroughfareName".

Returns:
the name of the street.

getSubAdministrativeArea

public final java.lang.String getSubAdministrativeArea()
The xAL field for "SubAdministrativeAreaName", often called "county".

Returns:
the name of the sub-administrative area