Once you find the right geocoder for the job, create a Grails service to encapsulate the remote Web services call in a reusable method call.
在您找到合适的地理编码器之后,创建一个Grails服务以把远程Web服务调用封装在可重用方法调用中。
In this two-part article series, to turn street addresses into their geographical coordinates for storage in the database, you called the Google Geocoder Web service from PHP.
在这个分为两部分的系列文章中,通过从php调用GoogleGeocoderWeb服务,将街道地址转换成地理坐标并存储在数据库中。
Call the Geocoder server-side before recording the information in the database.
在数据库中记录信息之前调用Geocoder服务器端。
For example, suppose the Geocoder response returned multiple codes within the State element, you would access the first one with $this->xml->Response->Status->code[0].
例如,假设Geocoder响应返回State元素中的多个代码,要使用 $this->xml->Response->Status->code[0]访问第一个元素。
Storing Geocoder data in the database.
在数据库中存储Geocoder数据。
You called the Geocoder service and stored the coordinate information in the database.
调用了Geocoder服务,并在数据库中存储坐标信息。
The first line gets a HashMap from the geocoder service.
第一行从geocoder服务获得一个HashMap。
The Google Geocoder service will return KML that describes the address.
GoogleGeocoder服务将返回描述地址的KML。
First you will call the Geocoder from PHP, and use the SimpleXML module to traverse the results.
首先,从php调用Geocoder,并使用SimpleXML模块遍历结果。
The response contains a Status reporting either success (code 200) or one of a number of error codes (see Resources for a link to a table of error codes on the Geocoder service page).
响应包含一个Status,报告成功(代码 200)或错误代码之一 (参见参考资料 获得 Geocoder服务页面的错误代码表链接)。
The response contains a Status reporting either success (code 200) or one of a number of error codes (see Resources for a link to a table of error codes on the Geocoder service page).
响应包含一个Status,报告成功(代码 200)或错误代码之一 (参见参考资料 获得 Geocoder服务页面的错误代码表链接)。
应用推荐