【文件属性】:
文件名称:Distance:PHP的地理距离库
文件大小:24KB
文件格式:ZIP
更新时间:2021-05-20 14:43:17
php distance geo PHP
PHP距离库
该库提供:
距离计算
距离矩阵计算
请注意,该库不提供地理编码功能(出于这些目的,您可以使用)。
例子
use Distance \ Model \ Distance ;
use Distance \ Model \ Coordinate ;
use Distance \ Exception \ PoolError ;
// for HTTP providers
$ client = new GuzzleHttp \ Client ();
// fail-safe distance source
$ pool = new Distance \ ProviderPool ([
// Google distance matrix provider
new Distance \ Provider \ GoogleProvider ( $ client ),
【文件预览】:
Distance-master
----src()
--------Exception()
--------ProviderPool.php(3KB)
--------Provider()
--------Model()
----phpunit.xml.dist(411B)
----.travis.yml(200B)
----LICENSE(1023B)
----composer.lock(9KB)
----README.md(2KB)
----tests()
--------ProviderPoolTest.php(2KB)
--------Provider()
--------Model()
--------bootstrap.php(280B)
----.gitignore(8B)
----composer.json(606B)