forked from SuperMap/iClient-JavaScript
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathAggregationParameter.js
More file actions
56 lines (52 loc) · 2.02 KB
/
AggregationParameter.js
File metadata and controls
56 lines (52 loc) · 2.02 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
/* Copyright© 2000 - 2018 SuperMap Software Co.Ltd. All rights reserved.
* This program are made available under the terms of the Apache License, Version 2.0
* which accompanies this distribution and is available at http://www.apache.org/licenses/LICENSE-2.0.html.*/
import {SuperMap} from '../SuperMap';
import {Util} from '../commontypes/Util';
/**
* @class SuperMap.AggregationParameter
* @classdesc 聚合查询参数设置,该参数仅支持数据来源 Elasticsearch 服务的数据服务。
* @category iServer Data FeatureResults
* @param {Object} options - 初始化参数。
* @param {string} options.aggName - 聚合名称。
* @param {SuperMap.AggregationType} options.aggType - 聚合类型设置。
* @param {string} options.aggFieldName - 聚合字段。
* @param {SuperMap.AggregationParameter} options.subAgg - 子聚合类。
*
*/
export class AggregationParameter {
constructor(options) {
/**
* @member {string} SuperMap.AggregationParameter.prototype.aggName
* @description 聚合名称。
*/
this.aggName = null;
/**
* @member {SuperMap.AggregationType} SuperMap.AggregationParameter.prototype.aggType
* @description 聚合类型设置类。
*/
this.aggType = null;
/**
* @member {string} SuperMap.AggregationParameter.prototype.aggFieldName
* @description 聚合字段。
*/
this.aggFieldName = null;
/**
* @member {SuperMap.AggregationParameter} SuperMap.AggregationParameter.prototype.subAgg
* @description 子聚合。
*/
this.subAgg = null;
this.CLASS_NAME = "SuperMap.AggregationParameter";
Util.extend(this, options);
}
destroy() {
var me = this;
me.aggName = null;
me.aggFieldName = null;
me.aggType = null;
if (me.subAgg) {
me.subAgg = null;
}
}
}
SuperMap.AggregationParameter = AggregationParameter;