\DtApp\ThinkLibrary\service\baiduLbsYunService

百度地图 http://lbsyun.baidu.com/index.php?title=webapi Class LbsYunService

Summary

Methods
Properties
Constants
__construct()
instance()
ak()
weather()
weatherAbroad()
No public properties found
No constants found
initialize()
$app
N/A
No private methods found
$ak
$output
N/A

Properties

$app

$app : \think\App

应用实例

Type

\think\App

$ak

$ak : string

Type

string

$output

$output : string

Type

string

Methods

__construct()

__construct(\think\App  $app) 

Service constructor.

Parameters

\think\App $app

instance()

instance(array  $args) : static

静态实例对象

Parameters

array $args

Returns

static

ak()

ak(string  $ak) : $this

Parameters

string $ak

Returns

$this

weather()

weather(integer  $district_id = 110100, string  $coordtype = "bd09ll", string  $location = "") : array|boolean|mixed|string

国内天气查询 http://lbsyun.baidu.com/index.php?title=webapi/weather

Parameters

integer $district_id
string $coordtype
string $location

Throws

\DtApp\ThinkLibrary\exception\DtaException

Returns

array|boolean|mixed|string

weatherAbroad()

weatherAbroad(integer  $district_id = 110100, string  $coordtype = "bd09ll", string  $location = "", string  $language = "cn") : array|boolean|mixed|string

国外天气查询 http://lbsyun.baidu.com/index.php?title=webapi/weather-abroad

Parameters

integer $district_id
string $coordtype
string $location
string $language

Throws

\DtApp\ThinkLibrary\exception\DtaException

Returns

array|boolean|mixed|string

initialize()

initialize() : $this

初始化服务

Returns

$this