@arcgis/core
Version:
ArcGIS Maps SDK for JavaScript: A complete 2D and 3D mapping and data visualization API
6 lines (5 loc) • 645 B
JavaScript
/*
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
*/
import{DictionaryValue as t}from"../support/DictionaryValue.js";class s{static async create(i,e){if("count"===e.statisticType){const i=new t(1);return new s(e.name,e.alias,e.type,e.statisticType,i)}const a=await i.createComputedField({expression:e.onStatisticExpression?.expression,field:e.onStatisticField});return new s(e.name,e.alias,e.type,e.statisticType,a)}constructor(t,s,i,e,a){this.name=t,this.alias=s,this.type=i,this.statisticType=e,this.computed=a}}export{s as ComputedAggregateField};