Skip to content

Instantly share code, notes, and snippets.

@nazt
Created January 12, 2010 09:42
Show Gist options
  • Save nazt/275058 to your computer and use it in GitHub Desktop.
Save nazt/275058 to your computer and use it in GitHub Desktop.
package NAzT
class GMapsGeoCoder {
def Query="Thammasat"
def url
def jsonObj
void setQuery(input)
{
this.Query=input
url="http://maps.google.com/maps/geo?q=${URLEncoder.encode(this.Query)}&output=json&sensor=false&gl=th&key=ABQIAAAAnGpifcTyPEhEhb5IwFOjbhQzGK7OP4Q3pl9UTFdBNJif2Gef4RR-EFDBL13et4wmQaxhqsIS4JBSOw".toURL()
this.jsonObj=url.text
}
ArrayList getLatLon(input)
{
input.Placemark.Point.coordinates[0]
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment