new ChartService(url, options)
Usage
// 浏览器
<script type="text/javascript" src="https://iclient.supermap.io/dist/openlayers/iclient-ol.js"></script>
<script>
new ol.supermap.ChartService(url, options);
</script>
// ES6 Import
import { ChartService } from '@supermapgis/iclient-ol';
new ChartService(url, options);
openlayers/services/ChartService.js, line 10
Name | Type | Description | ||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
url |
string |
服务地址。 |
||||||||||||||||||||||||
options |
Object |
参数。
|
Example
new ChartService(url,{
fieldNameFormatter: function(fieldName){
return fieldName + 'test'
}
}).queryChart(param,function(result){
//doSomething
})
Extends
Methods
-
getChartAcronymClassify(callback){Promise}
openlayers/services/ChartService.js, line 64 -
获取海图产品规范物标分组信息服务。
Name Type Description callback
RequestCallback 可选 回调函数,该参数未传时可通过返回的promise 获取结果。
- Version:
- 11.2.0
Returns:
Type Description Promise Promise 对象。 -
getChartFeatureInfo(callback){Promise}
openlayers/services/ChartService.js, line 54 -
获取海图物标信息服务。
Name Type Description callback
RequestCallback 可选 回调函数,该参数未传时可通过返回的 promise 获取结果。
Returns:
Type Description Promise Promise 对象。 -
queryChart(params, callback, resultFormat){Promise}
openlayers/services/ChartService.js, line 41 -
查询海图服务。
Name Type Description params
ChartQueryParameters 海图查询所需参数类。
callback
RequestCallback 可选 回调函数,该参数未传时可通过返回的 promise 获取结果。
resultFormat
DataFormat 返回结果类型。
Returns:
Type Description Promise Promise 对象。