@arcgis/core 5.2.0-next.16 → 5.2.0-next.17
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/arcgisGlobal.d.ts +3 -0
- package/assets/esri/core/workers/RemoteClient.js +1 -1
- package/assets/esri/core/workers/chunks/00bcb04934972179b9ca.js +1 -0
- package/assets/esri/core/workers/chunks/073ee52705ea326fecfb.js +1 -0
- package/assets/esri/core/workers/chunks/{282930645ce525d5bc92.js → 0e81b6aa64d5491870b2.js} +1 -1
- package/assets/esri/core/workers/chunks/{4162a2bb774e6ba2c0db.js → 0fb685f385e91d0f0601.js} +1 -1
- package/assets/esri/core/workers/chunks/11d1af758e2140095b10.js +1 -0
- package/assets/esri/core/workers/chunks/{a8ef7acb6d3d1f45e14c.js → 29e6f4b19c3da9129439.js} +1 -1
- package/assets/esri/core/workers/chunks/31c4128b23968575feca.js +1 -0
- package/assets/esri/core/workers/chunks/35a508a9311689d8df52.js +1 -0
- package/assets/esri/core/workers/chunks/3a35779cae6a11cde51b.js +1 -0
- package/assets/esri/core/workers/chunks/3a526e1d18490b99332f.js +1 -0
- package/assets/esri/core/workers/chunks/3e89f487c5851c954d8b.js +1 -0
- package/assets/esri/core/workers/chunks/{cf9a132c4c37e62de3d7.js → 50c88e2545380800381f.js} +1 -1
- package/assets/esri/core/workers/chunks/{a892b3be70f482bef0ba.js → 57a6572d440d2c62432b.js} +1 -1
- package/assets/esri/core/workers/chunks/6849282c4a5cd733779d.js +1 -0
- package/assets/esri/core/workers/chunks/{2b781de7b467c61849b2.js → 6a21a22b08f968fa8d60.js} +1 -1
- package/assets/esri/core/workers/chunks/8104ac2eee69d79ada86.js +1 -0
- package/assets/esri/core/workers/chunks/{1c689bb502657b1f173b.js → 9d59cc5c0a63a4e41d99.js} +1 -1
- package/assets/esri/core/workers/chunks/{91c0de3950991d81b7f2.js → 9de673a04c70bd47047e.js} +1 -1
- package/assets/esri/core/workers/chunks/a195f569eada3a8736be.js +1 -0
- package/assets/esri/core/workers/chunks/{9da1a514e042eb642d35.js → a32651777e4f07df5b6a.js} +1 -1
- package/assets/esri/core/workers/chunks/a3c5b754a6fa0f4250bf.js +1 -0
- package/assets/esri/core/workers/chunks/a59a1fdcd37a875f179b.js +1 -0
- package/assets/esri/core/workers/chunks/{ac7ecd90330090c90005.js → aeeee92b86554962711e.js} +1 -1
- package/assets/esri/core/workers/chunks/b0e4af49fc968b0a910f.js +1 -0
- package/assets/esri/core/workers/chunks/b466af9019f10420115e.js +1 -0
- package/assets/esri/core/workers/chunks/bb9232d9f63ec0c32447.js +1 -0
- package/assets/esri/core/workers/chunks/bf9eca7dd107bdb06614.js +1 -0
- package/assets/esri/core/workers/chunks/cbe8adc100582e746a8c.js +1 -0
- package/assets/esri/core/workers/chunks/{a1509e2e7809b6754b4f.js → d523af1db620b5381c99.js} +1 -1
- package/assets/esri/core/workers/chunks/d5a0e3a73df827dc7b06.js +1 -0
- package/assets/esri/core/workers/chunks/d670e134348954ce465d.js +1 -0
- package/assets/esri/core/workers/chunks/e3ea4b7217df16592def.js +1 -0
- package/assets/esri/core/workers/chunks/{c538435216d253f7702e.js → f23351a04643c464be84.js} +1 -1
- package/assets/esri/core/workers/chunks/f3d331da3c61af5c5a2f.js +1 -0
- package/assets/esri/core/workers/chunks/{68b77b36daae2b4b4237.js → f3fe865506fd7428eb6d.js} +1 -1
- package/assets/esri/core/workers/chunks/{a4d918b47cd4ee0e1666.js → f8cfd0045d06aa24beec.js} +1 -1
- package/config.js +1 -1
- package/kernel.js +1 -1
- package/layers/graphics/sources/MemorySource.js +1 -1
- package/layers/graphics/sources/support/ParquetSourceWorker.js +1 -1
- package/networks/CircuitManager.d.ts +247 -1
- package/networks/UnitIdentifierManager.d.ts +40 -3
- package/networks/UtilityNetwork.d.ts +0 -11
- package/networks/support/Circuit.d.ts +0 -1
- package/networks/support/CircuitLocation.d.ts +0 -1
- package/networks/support/CircuitPath.d.ts +0 -1
- package/networks/support/CircuitPathConnectivityElement.d.ts +0 -1
- package/networks/support/CircuitSection.d.ts +0 -1
- package/networks/support/NamedTraceConfiguration.d.ts +1 -7
- package/networks/support/Subcircuit.d.ts +0 -1
- package/networks/support/UNTraceConfiguration.d.ts +0 -4
- package/networks/support/jsonTypes.d.ts +1 -1
- package/networks/support/typeUtils.d.ts +10 -1
- package/networks/support/typeUtils.js +1 -1
- package/package.json +1 -1
- package/rest/networks/circuits/support/CircuitTraceResult.d.ts +0 -1
- package/rest/networks/circuits/support/CircuitVerifyResult.d.ts +0 -1
- package/rest/networks/support/TelecomNetworkElement.d.ts +0 -1
- package/rest/networks/support/TraceLocation.d.ts +1 -11
- package/rest/networks/support/TraceParameters.d.ts +1 -7
- package/rest/networks/support/TraceResult.d.ts +0 -2
- package/rest/networks/support/TraverseAssociationsParameters.d.ts +69 -0
- package/rest/networks/support/TraverseAssociationsParameters.js +2 -0
- package/rest/networks/support/TraverseAssociationsResult.d.ts +39 -0
- package/rest/networks/support/TraverseAssociationsResult.js +2 -0
- package/rest/networks/traverseAssociations.d.ts +21 -0
- package/rest/networks/traverseAssociations.js +2 -0
- package/rest/networks/unitIdentifiers/support/UnitQueryResult.d.ts +0 -1
- package/support/revision.js +1 -1
- package/views/2d/engine/webgl/shaders/sources/shaderRepository.js +1 -1
- package/views/2d/layers/features/sources/strategies/support/queryAdapters.js +1 -1
- package/views/2d/layers/features/support/FeatureMetadata.js +1 -1
- package/views/3d/webgl-engine/lib/GaussianSplatRenderNode.js +1 -1
- package/views/draw/DrawTool.js +1 -1
- package/widgets/UtilityNetworkTrace/UtilityNetworkTraceViewModel.d.ts +3 -2
- package/assets/esri/core/workers/chunks/01ba5319cac3e0f14205.js +0 -1
- package/assets/esri/core/workers/chunks/05e1f1628a3726eca03d.js +0 -1
- package/assets/esri/core/workers/chunks/1d38b2fcd85ac9ebd7c6.js +0 -1
- package/assets/esri/core/workers/chunks/1effde6a39ef0d4af525.js +0 -1
- package/assets/esri/core/workers/chunks/1ff57bf19f021f5fd246.js +0 -1
- package/assets/esri/core/workers/chunks/3dc6e9494af16f7b8009.js +0 -1
- package/assets/esri/core/workers/chunks/3ecb906322a6a5c8c93b.js +0 -1
- package/assets/esri/core/workers/chunks/3f67162456a1f02190fa.js +0 -1
- package/assets/esri/core/workers/chunks/4e4419282c4bf7ee4678.js +0 -1
- package/assets/esri/core/workers/chunks/609edb4da427ec37bcf7.js +0 -1
- package/assets/esri/core/workers/chunks/6f5a82388a5eb5fcf1b7.js +0 -1
- package/assets/esri/core/workers/chunks/7c61b18e43c789aaecc6.js +0 -1
- package/assets/esri/core/workers/chunks/8dcb3e77f76d8396706b.js +0 -1
- package/assets/esri/core/workers/chunks/a3195521a83565c7c2d3.js +0 -1
- package/assets/esri/core/workers/chunks/b0212df1fe8d9448f3d6.js +0 -1
- package/assets/esri/core/workers/chunks/b590402170ae289290d7.js +0 -1
- package/assets/esri/core/workers/chunks/bfa6f4c08e7571bb1f37.js +0 -1
- package/assets/esri/core/workers/chunks/c5e172d3baf5414868f0.js +0 -1
- package/assets/esri/core/workers/chunks/cf41a66fb97c1076fb34.js +0 -1
- package/assets/esri/core/workers/chunks/f23e995320674b32e142.js +0 -1
- package/assets/esri/core/workers/chunks/f3fd40df92e59f7c687c.js +0 -1
- package/assets/esri/core/workers/chunks/fa1336b60278017d2525.js +0 -1
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[4257],{9775(t,e,s){s.d(e,{A:()=>n});var i=s(62788),r=s(95488);class n{constructor(t=t=>t.values().next().value){this._peeker=t,this._observable=new r.I,this._items=new Set}get length(){return(0,i.gc)(this._observable),this._items.size}clear(){0!==this.length&&(this._items.clear(),this._observable.notify())}last(){if(0===this.length)return;let t;for(t of this._items);return t}peek(){if(0!==this.length)return this._peeker(this._items)}push(t){this.contains(t)||(this._items.add(t),this._observable.notify())}contains(t){return(0,i.gc)(this._observable),this._items.has(t)}pop(){if(0===this.length)return;const t=this.peek();return this._items.delete(t),this._observable.notify(),t}popLast(){if(0===this.length)return;const t=this.last();return this._items.delete(t),this._observable.notify(),t}remove(t){this.contains(t)&&(this._items.delete(t),this._observable.notify())}filter(t){const e=this.length;return this._items.forEach(e=>{t(e)||this._items.delete(e)}),e!==this._items.size&&this._observable.notify(),this}*[Symbol.iterator](){(0,i.gc)(this._observable),yield*this._items}}},36745(t,e,s){s.d(e,{z:()=>o});var i=s(4718),r=s(51118),n=s(60408),a=s(92722);class o{static fromOptimized(t,e,s=1){return(new u).initialize(t,e,s)}static fromJSON(t){const[e,s]=l(t),i=(0,n.Pv)(t),r=(0,n.W0)(t);return(new c).initialize(e,s,i,r,1)}static fromOptimizedCIM(t,e,s=1){return(new p).initialize(t,e,s)}static fromJSONCIM(t,e=1){const[s,i]=l(t),r=(0,n.Pv)(t),a=(0,n.W0)(t);return(new d).initialize(s,i,r,a,e)}static fromFeatureSetReader(t){const e=t.readGeometryForDisplay(),s=t.geometryType;return e&&s?this.fromOptimized(e,s):null}static fromFeatureSetReaderCIM(t){const e=t.readGeometryForDisplay(),s=t.geometryType;return e&&s?this.fromOptimizedCIM(e,s):null}static createEmptyOptimized(t,e=!1,s=!1,i=1){return(new p).initialize(new a.A([],[],e,s),t,i)}static createEmptyJSON(t,e=!1,s=!1){return(new c).initialize([],t,e,s,1)}static createEmptyOptimizedCIM(t,e=!1,s=!1,i=1){return(new p).initialize(new a.A([],[],e,s),t,i)}static createEmptyJSONCIM(t,e=!1,s=!1,i=1){return(new d).initialize([],t,e,s,i)}asJSON(){const t=(0,r.x)(this),{hasZ:e,hasM:s}=this;return"esriGeometryEnvelope"===this.geometryType?{xmin:t[0][0][0],ymin:t[0][0][1],xmax:t[0][2][0],ymax:t[0][2][1]}:"esriGeometryMultipoint"===this.geometryType?{points:t.flat(),hasZ:e,hasM:s}:"esriGeometryPoint"===this.geometryType?{x:t[0][0][0],y:t[0][0][1],z:e?t[0][0][2]:void 0,m:s?t[0][0][e?3:2]:void 0}:"esriGeometryPolygon"===this.geometryType?{rings:t,hasZ:e,hasM:s}:{paths:t,hasZ:e,hasM:s}}getCurrentRingArea(){if(this.pathSize<3)return 0;let t,e,s=0;if(this.seekPathStart(),!this.nextPoint())return 0;t=this.x,e=this.y;const i=t,r=e;for(;this.nextPoint();)s+=(t-this.x)*(e+this.y),t=this.x,e=this.y;return s+=(t-i)*(e+r),-.5*s}invertY(){this.yFactor*=-1}}class u extends o{constructor(){super(...arguments),this._end=-1}get hasZ(){return this._geometry?.hasZ}get hasM(){return this._geometry?.hasM}initialize(t,e,s){return this.geometryType=e,this._stride=t.stride,this._geometry=t,this._pathIndex=-1,this._pathOffset=0,this._pointOffset=-this._stride,this._end=-1,this.yFactor=s,this}reset(){this.initialize(this._geometry,this.geometryType,this.yFactor)}seekPath(t){if(t>=0&&t<this.totalSize){if(this._pathIndex<t)for(;this._pathIndex<t&&this.nextPath(););else if(this._pathIndex>t)for(;this._pathIndex>t&&this.prevPath(););return!0}return!1}seekPathStart(){this._pointOffset=this._pathOffset-this._stride}seekPathEnd(){this._pointOffset=this._end}seekInPath(t){const e=this._pathOffset+t*this._stride;return e>=0&&e<this._end&&(this._pointOffset=e,!0)}nextPoint(){return(this._pointOffset+=this._stride)<this._end}prevPoint(){return(this._pointOffset-=this._stride)>=this._pathOffset}nextPath(){return!(this.pathIndex>=this.totalSize-1||(this._pathIndex>=0&&(this._pathOffset+=this._stride*this.pathSize),this._pathIndex++,this._pointOffset=this._pathOffset-this._stride,this._end=this._pointOffset+this._stride+this._stride*this.pathSize,0))}prevPath(){return!(this.pathIndex<=0||(this._pathIndex--,this._end=this._pathOffset,this._pathOffset-=this._stride*this.pathSize,this._pointOffset=this._pathOffset-this._stride,0))}getCurrentPath(){const t=this._end,e=this._geometry.coords,s=this._pathOffset;return(new u).initialize(new a.A([this.pathSize],e.slice(s,t),this.hasZ,this.hasM),this.geometryType,this.yFactor)}pathLength(){const t=this._end,e=this._stride,s=this._geometry.coords;let i=0;for(let r=this._pathOffset+e;r<t;r+=e){const t=s[r-e],n=s[r-e+1],a=s[r]-t,o=s[r+1]-n;i+=Math.sqrt(a*a+o*o)}return i}startPath(){this._geometry.lengths.push(0)}pushPath(t){this.startPath(),this.pushPoints(t)}pushPoint(t){for(let e=0;e<this._stride;++e)this._geometry.coords.push(t[e]);this._geometry.lengths[this.totalSize-1]++}pushXY(t,e){this._geometry.coords.push(t,e),this._geometry.lengths[this.totalSize-1]++}pushPoints(t){for(const e of t)for(let t=0;t<this._stride;++t)this._geometry.coords.push(e[t]);this._geometry.lengths[this.totalSize-1]+=t.length}pushCursor(t){const e=t.asOptimized();this._geometry.coords.push(...e.coords),this._geometry.lengths.push(...e.lengths)}asOptimized(){const t=this._geometry.clone();if(1!==this.yFactor)for(let e=1;e<t.coords.length;e+=this._stride)t.coords[e]*=this.yFactor;return"esriGeometryPoint"===this.geometryType&&(t.lengths.length=0),t}isClosed(){const t=this._geometry.coords,e=this._pathOffset,s=this._end-this._stride;for(let i=0;i<this._stride;i++)if(t[e+i]!==t[s+i])return!1;return!0}clone(){return(new u).initialize(this._geometry.clone(),this.geometryType,this.yFactor)}get totalPoints(){return this._geometry.isPoint?1:this._geometry.lengths.reduce((t,e)=>t+e)}get pathSize(){const{lengths:t}=this._geometry;return this._geometry.isPoint?1:this._pathIndex<0||this._pathIndex>t.length-1?0:t[this._pathIndex]}get totalSize(){return this._geometry.isPoint?1:this._geometry.lengths.length}get x(){return this._geometry.coords[this._pointOffset]}set x(t){this._geometry.coords[this._pointOffset]=t}get y(){return this.yFactor*this._geometry.coords[this._pointOffset+1]}set y(t){this._geometry.coords[this._pointOffset+1]=this.yFactor*t}get z(){return this._geometry.coords[this._pointOffset+2]}set z(t){this._geometry.coords[this._pointOffset+2]=t}get m(){const t=this.hasZ?3:2;return this._geometry.coords[this._pointOffset+t]}set m(t){this._geometry.coords[this._pointOffset+3]=t}get pathIndex(){return this._pathIndex}get _coordIndex(){return this._pointOffset/this._stride}}function h(t){const e=[t.x,t.y];return t.z&&e.push(t.z),t.m&&e.push(t.m),e}function l(t){return(0,n.Bi)(t)?[t.rings,"esriGeometryPolygon"]:(0,n.Rg)(t)?[t.paths,"esriGeometryPolyline"]:(0,n.U9)(t)?[[t.points],"esriGeometryMultipoint"]:(0,n.ZC)(t)?[[[[t.xmin,t.ymin],[t.xmin,t.ymax],[t.xmax,t.ymax],[t.xmax,t.ymin],[t.xmin,t.ymin]]],"esriGeometryEnvelope"]:(0,n.fT)(t)?[[[h(t)]],"esriGeometryPoint"]:[[],"esriGeometryPolyline"]}class c extends o{initialize(t,e,s,i,r){return this._paths=t,this.geometryType=e,this.hasZ=s,this.hasM=i,this._pathIndex=this._pointIndex=-1,this.yFactor=r,this._mIndex=this.hasZ?3:2,this}reset(){this._pathIndex=this._pointIndex=-1}seekPath(t){return this._pathIndex=t,this._pointIndex=-1,t>=0&&t<this.totalSize&&(this._currentPath=this._paths[t],!0)}seekPathStart(){this._pointIndex=-1}seekPathEnd(){this._pointIndex=this._currentPath.length}seekInPath(t){return t>=0&&t<this._currentPath.length&&(this._pointIndex=t,this._currentPoint=this._currentPath[this._pointIndex],!0)}nextPoint(){return this._currentPoint=this._currentPath[++this._pointIndex],this._pointIndex<this._currentPath.length}prevPoint(){return this._currentPoint=this._currentPath[--this._pointIndex],this._pointIndex>=0}nextPath(){return this._pointIndex=-1,this._currentPath=this._paths[++this._pathIndex],this._pathIndex<this.totalSize}prevPath(){return this.pathIndex>0&&(this._pointIndex=-1,this._pathIndex--,this._currentPath=this._paths[this._pathIndex],!0)}pathLength(){const t=this._currentPath.length,e=this._currentPath;let s=0;for(let i=1;i<t;i++){const t=e[i-1],r=e[i],n=t[0],a=t[1],o=r[0]-n,u=r[1]-a;s+=Math.sqrt(o*o+u*u)}return s}startPath(){this._paths.push([])}getCurrentPath(){return(new c).initialize([this._currentPath],this.geometryType,this.hasZ,this.hasM,this.yFactor)}pushPath(t){this._paths.push(t)}pushPoint(t){this._paths[this.totalSize-1].push(t)}pushXY(t,e){this._paths[this.totalSize-1].push([t,e])}pushPoints(t){this._paths[this.totalSize-1].push(...t)}pushCursor(t){const e=(0,r.x)(t);for(const t of e)this.pushPath(t)}asOptimized(){const{hasZ:t,hasM:e}=this,s=new a.A([],[],t,e),{coords:i,lengths:r}=s;if("esriGeometryPoint"===this.geometryType)i.push(...this._paths[0][0]),r.length=0;else for(const s of this._paths){for(const r of s)i.push(r[0]),i.push(r[1]*this.yFactor),t&&i.push(r[2]),e&&i.push(r[this._mIndex]);r.push(s.length)}return s}isClosed(){const t=this._currentPath[0],e=this._currentPath[this._currentPath.length-1];for(let s=0;s<t.length;s++)if(t[s]!==e[s])return!1;return!0}clone(){return(new c).initialize((0,i.o8)(this._paths),this.geometryType,this.hasZ,this.hasM,this.yFactor)}get totalPoints(){return this._paths.map(t=>t.length).reduce((t,e)=>t+e)}get pathSize(){return this._pathIndex<0||this._pathIndex>this.totalSize-1?-1:this._paths[this._pathIndex].length}get totalSize(){return this._paths.length}get x(){return this._currentPoint[0]}set x(t){this._currentPoint[0]=t}get y(){return this.yFactor*this._currentPoint[1]}set y(t){this._currentPoint[1]=this.yFactor*t}get z(){return this._currentPoint[2]}set z(t){this._currentPoint[2]=t}get m(){return this._currentPoint[this._mIndex]}set m(t){this._currentPoint[this._mIndex]=t}get pathIndex(){return this._pathIndex}}class p extends u{initialize(t,e,s){return super.initialize(t,e,s),this._controlPoints||(this._controlPoints=this._controlPoints=new Array(this.totalSize).fill(void 0).map(t=>new Set)),this}startPath(){super.startPath(),this._controlPoints.push(new Set)}clone(){const t=(new p).initialize(this._geometry.clone(),this.geometryType,this.yFactor);return t._controlPoints=this._controlPoints,t}setControlPoint(){this._controlPoints[this.pathIndex].add(this._coordIndex)}getControlPoint(){return this._controlPoints[this.pathIndex].has(this._coordIndex)}setControlPointAt(t){this._controlPoints[this.pathIndex].add(t)}getControlPointAt(t){return this._controlPoints[this.pathIndex].has(t)}}class d extends c{initialize(t,e,s,i,r){return super.initialize(t,e,s,i,r)}clone(){return(new d).initialize((0,i.o8)(this._paths),this.geometryType,this.hasZ,this.hasM,this.yFactor)}setControlPoint(){this._paths[this.pathIndex][this._pointIndex][4]=1}getControlPoint(){return 1===this._paths[this.pathIndex][this._pointIndex][4]}setControlPointAt(t){this._paths[this.pathIndex][t][4]=1}getControlPointAt(t){return 1===this._paths[this.pathIndex][t][4]}}},32011(t,e,s){s.d(e,{d:()=>u});var i=s(19419),r=s(537),n=s(12359),a=s(95108),o=s(12176);function u(t){if(0===t.totalSize)return null;const e=(0,r.z8)(t);if(!e)return null;const s=4*(Math.abs(e[0])+Math.abs(e[2])+Math.abs(e[1])+Math.abs(e[3])+1)*222045e-19;let a=0,o=0;t.reset();for(let e=0;t.nextPath();e++){const s=t.getCurrentRingArea();s>o&&(o=s,a=e)}if(t.seekPath(a),0===t.pathSize)return null;t.seekPathStart();const u=(0,r.B$)(t);if(Math.abs(o)<=2*s*s)return[(u[0]+u[2])/2,(u[1]+u[3])/2];t.seekPathStart();const p=(0,n.w2)(t,(0,i.vt)());if(null===p)return null;if(t.totalPoints<4)return p;const d=[[NaN,NaN],[NaN,NaN],[NaN,NaN],[NaN,NaN]],f=[NaN,NaN,NaN,NaN],g=[NaN,NaN,NaN,NaN];let x=!1,w=l(p,t,!0);0===w.distance&&(x=!0,d[0][0]=p[0],d[0][1]=p[1],w=l(p,t,!1)),f[0]=w.distance,g[0]=0;const I=[NaN,NaN];let P=!1,S=.25,F=-1,v=NaN;do{if(v=NaN,d[1]=c(t,y(u[0],u[2],S),0,e),isNaN(d[1][0])||isNaN(d[1][1])||(w=l(d[1],t,!1),v=w.distance),!isNaN(v)&&v>s&&h(d[1],t))P=!0,f[1]=v,g[1]=_(d[1],p);else if(!isNaN(v)&&v>F&&(F=v,I[0]=d[1][0],I[1]=d[1][1]),S-=.01,S<.1){if(!(F>=0))break;P=!0,f[1]=F,d[1][0]=I[0],d[1][1]=I[1],g[1]=_(d[1],p)}}while(!P);P=!1,S=.5,F=-1;let N=.01,b=1;do{if(v=NaN,d[2]=c(t,y(u[0],u[2],S),0,e),isNaN(d[2][0])||isNaN(d[2][1])||(w=l(d[2],t,!1),v=w.distance),!isNaN(v)&&v>s&&h(d[2],t))P=!0,f[2]=v,g[2]=_(d[2],p);else if(!isNaN(v)&&v>F)F=v,I[0]=d[2][0],I[1]=d[2][1];else if(v>F&&(F=v,I[0]=d[2][0],I[1]=d[2][1]),S=.5+N*b,N+=.01,b*=-1,S<.3||S>.7){if(!(F>=0))break;P=!0,f[2]=F,d[2][0]=I[0],d[2][1]=I[1],g[2]=_(d[2],p)}}while(!P);P=!1,S=.75,F=-1;do{if(v=NaN,d[3]=c(t,y(u[0],u[2],S),0,e),isNaN(d[3][0])||isNaN(d[3][1])||(w=l(d[3],t,!1),v=w.distance),!isNaN(v)&&v>s&&h(d[3],t))P=!0,f[3]=v,g[3]=_(d[3],p);else if(v>F&&(F=v,I[0]=d[3][0],I[1]=d[3][1]),S+=.01,S>.9){if(!(F>=0))break;P=!0,f[3]=F,d[3][0]=I[0],d[3][1]=I[1],g[3]=_(d[3],p)}}while(!P);const O=[0,1,2,3],z=x?0:1;let C;for(let t=z;t<4;t++)for(let t=z;t<3;t++){const e=g[t],s=g[t+1];m(e,s)>0&&(C=O[t],O[t]=O[t+1],O[t+1]=C,g[t]=s,g[t+1]=e)}let q=z,R=0,T=0;for(let t=z;t<4;t++){switch(t){case 0:T=2*f[O[t]];break;case 1:T=1.66666666*f[O[t]];break;case 2:T=1.33333333*f[O[t]];break;case 3:T=f[O[t]]}T>R&&(R=T,q=O[t])}return d[q]}function h(t,e){let s,i,r,n,a=0;for(e.reset();e.nextPath()&&e.nextPoint();)for(s=e.x,i=e.y;e.nextPoint();s=r,i=n)r=e.x,n=e.y,i>t[1]!=n>t[1]&&((r-s)*(t[1]-i)-(n-i)*(t[0]-s)>0?a++:a--);return 0!==a}function l(t,e,s){if(s&&h(t,e))return{coord:t,distance:0};let i=1/0,r=0,n=0,o=[0,0],u=[0,0];const l=[0,0];for(e.reset();e.nextPath()&&e.nextPoint();)if(!(e.pathSize<2))for(o[0]=e.x,o[1]=e.y;e.nextPoint();o=u){u=[e.x,e.y],(0,a.gR)(l,t,o,u);const s=_(t,l);s<i&&(i=s,r=l[0],n=l[1])}return{coord:[r,n],distance:Math.sqrt(i)}}function c(t,e,s,r){const n=[e,0];let a=1/0,u=1/0,h=!1,l=!1;const c=[[e,r[1]-1],[e,r[3]+1]],f=[0,0],y=[0,0],_=[0,0],m=[[0,0],[0,0]],g=(0,i.vt)();for(t.reset();t.nextPath()&&t.nextPoint();)if(!(t.pathSize<2))for(m[0][0]=t.x,m[0][1]=t.y;t.nextPoint();m[0][0]=m[1][0],m[0][1]=m[1][1]){if(m[1][0]=t.x,m[1][1]=t.y,null===p(g,m))continue;if(y[0]=c[0][0],y[1]=c[0][1],_[0]=c[1][0],_[1]=c[1][1],0===d(g,y,_))continue;if(!(0,o.Ql)(c[0],c[1],m[0],m[1],f))continue;const e=f[1];a>u?e<a&&(a=e,h=!0):e<u&&(u=e,l=!0)}return h&&l?n[1]=(a+u)/2:n[0]=n[1]=NaN,n}function p(t,e){if(e.length<2)return null;t||(t=(0,i.vt)());const[s,r]=e[0],[n,a]=e[1];return t[0]=Math.min(s,n),t[1]=Math.min(r,a),t[2]=Math.max(s,n),t[3]=Math.max(r,a),t}function d(t,e,s){let i=f(e,t),r=f(s,t);const n=t[0],a=t[1],o=t[2],u=t[3];if(i&r)return 0;if(!(i|r))return 4;const h=(i?1:0)|(r?2:0);do{const h=s[0]-e[0],l=s[1]-e[1];if(h>l)3&i?(1&i?(e[1]+=l*(n-e[0])/h,e[0]=n):(e[1]+=l*(o-e[0])/h,e[0]=o),i=f(e,t)):3&r?(1&r?(s[1]+=l*(n-s[0])/h,s[0]=n):(s[1]+=l*(o-s[0])/h,s[0]=o),r=f(s,t)):i?(4&i?(e[0]+=h*(a-e[1])/l,e[1]=a):(e[0]+=h*(u-e[1])/l,e[1]=u),i=f(e,t)):(4&r?(s[0]+=h*(a-s[1])/l,s[1]=a):(s[0]+=h*(u-s[1])/l,s[1]=u),r=f(s,t));else if(12&i?(4&i?(e[0]+=h*(a-e[1])/l,e[1]=a):(e[0]+=h*(u-e[1])/l,e[1]=u),i=f(e,t)):12&r?(4&r?(s[0]+=h*(a-s[1])/l,s[1]=a):(s[0]+=h*(u-s[1])/l,s[1]=u),r=f(s,t)):i?(1&i?(e[1]+=l*(n-e[0])/h,e[0]=n):(e[1]+=l*(o-e[0])/h,e[0]=o),i=f(e,t)):(1&r?(s[1]+=l*(n-s[0])/h,s[0]=n):(s[1]+=l*(o-s[0])/h,s[0]=o),r=f(s,t)),i&r)return 0}while(i|r);return h}function f(t,e){return(t[0]<e[0]?1:0)|(t[0]>e[2]?1:0)<<1|(t[1]<e[1]?1:0)<<2|(t[1]>e[3]?1:0)<<3}function y(t,e,s){return t+(e-t)*s}function _(t,e){return(t[0]-e[0])*(t[0]-e[0])+(t[1]-e[1])*(t[1]-e[1])}function m(t,e){if(t<e)return-1;if(t>e)return 1;if(t===e)return 0;const s=isNaN(t),i=isNaN(e);return s<i?-1:s>i?1:0}},6557(t,e,s){s.r(e),s.d(e,{default:()=>Z});var i=s(5482),r=s(21818),n=s(49186),a=s(44208),o=s(53966),u=s(17676),h=s(563),l=s(39516),c=s(16930),p=s(70328),d=s(19419),f=s(83960),y=s(21325),_=s(90708),m=s(75752),g=s(99352),x=s(8384),w=s(58727),I=s(90951),P=s(64714),S=s(17754),F=s(20437),v=s(95466),N=s(30524),b=s(50639),O=s(42760),z=s(39412),C=s(30661),q=s(28923),R=s(44320),T=s(35258),E=s(16630);const A=new C.Z,M="__OBJECTID",G=new TextDecoder,k=8e3;class Q{constructor(t,e){this._files=t,this._createFileStream=e,this._fileIndex=0,this._streamIndex=0,this._streams=[],this._pending=new Set,this._resolvedCount=0}async next(t){for(await this._fill(t);this._pending.size>0;){(0,u.Te)(t),await this._fill(t);const e=await B(this._pending);if(this._pending.delete(e.read),this._resolvedCount++,null!=e.chunk)return e.chunk}return null}async _fill(t){for(this._removeDone();this._pending.size<8;){const e=this._getOrCreateNextStream(t);if(null==e)return;this._pending.add(e.read(t))}}_getOrCreateNextStream(t){const e=this._resolvedCount>=8?8:2;if(this._fileIndex<this._files.length&&this._streams.length<e){const e=this._files[this._fileIndex++],s=new D(e.id,this._createFileStream(e,t));return this._streams.push(s),s}return this._getNextStream()}_getNextStream(){const t=this._streams.length;for(let e=0;e<t;e++){const s=(this._streamIndex+e)%t,i=this._streams[s];if(i.canRead)return this._streamIndex=(s+1)%t,i}return null}_removeDone(){let t=this._streamIndex;for(let e=this._streams.length-1;e>=0;e--)this._streams[e].done&&(this._streams.splice(e,1),e<t&&t--);this._streamIndex=this._streams.length>0?t%this._streams.length:0}}function B(t){return Promise.race(Array.from(t,async t=>({read:t,chunk:await t})))}class D{constructor(t,e){this._fileId=t,this._stream=e,this._readCount=0,this._reachedEnd=!1}get canRead(){return!this._reachedEnd}get done(){return this._reachedEnd&&0===this._readCount}async read(t){this._readCount++;try{const e=await this._stream,s=await e.next(t);return null==s?(this._reachedEnd=!0,null):{fileId:this._fileId,chunk:s}}finally{this._readCount--}}}class Z{constructor(){this._queue=new h.QueueProcessor({concurrency:4,process:(t,e)=>this._executeQuery(t,e)}),this._streams=new Map,this._streamIdCounter=0,this._indexMap={}}async load(t){const e=t.spatialReference?c.A.fromJSON(t.spatialReference):void 0;if(e&&!e.isWGS84&&!e.isWebMercator)throw new n.A("parquet:unsupported-projection","Only WGS84 and Web Mercator are supported");this._customParameters=t.customParameters,this._provider=(0,I.M)(t.provider,null,()=>this._customParameters);const s=await this._provider.getMetadata(),i=await(0,O.nc)(s,{fields:t.fields?.map(t=>F.A.fromJSON(t)),geometryEncoding:t.geometryEncoding?(0,b.G)(t.geometryEncoding):null,geometryType:t.geometryType?(0,O.hG)(t.geometryType):null,displayOptimization:t.displayOptimization,spatialReference:e});if(!i.fields)throw new n.A("parquet:unsupported","Fields must be defined");let r;if(i.spatialReference&&i.geometryType){if(!i.spatialReference)throw new n.A("parquet:unsupported","SpatialReference must be defined");if(!i.spatialReference.isGeographic&&!i.spatialReference.isWebMercator)throw new n.A("parquet:unsupported-projection","Only WGS84 and Web Mercator are supported");i.spatialReference.isGeographic&&!i.spatialReference.isWGS84&&(o.A.getLogger("parquet:unsupported-projection").warn("Found a geographic projection that is not WGS84. Handling as WGS84.",{spatialReference:i.spatialReference}),i.spatialReference=c.A.WGS84),r={geometry:i.geometryEncoding?{geometryType:(0,O.sA)(i.geometryType),spatialReference:i.spatialReference.toJSON(),encoding:i.geometryEncoding.toJSON()}:null,displayOptimization:i.displayOptimization}}this.setCustomParameters(t.customParameters),this._displayOptimization=i.displayOptimization,await this._provider.updateGeometryInfo(r),this._capabilities=K(await this._getFileStatistics());const a=await this._provider.getFiles();if(!a.length)return{layerDefinition:{},capabilities:K(null)};const u=await a[0].file;i.file=u;const{fields:h}=i;if(null==h)throw new n.A("parquet-layer:missing-metadata","Unable to create parquet source: cannot infer fields",h);h.push(new F.A({name:M,type:"oid",alias:M}));for(const t of h){const e=u.getColumnId(t.name);null!=e&&(this._indexMap[t.name]=e)}const l=new v.A(h.map(t=>t.toJSON()));this._fieldsIndex=l;const p=(0,O.sA)(i.geometryType??"point");return this._metadata=T.i.createFeature({fieldsIndex:l.toJSON(),geometryType:p,hasZ:!1,hasM:!1,featureIdInfo:{type:"object-id",fieldName:M},subtypes:null,subtypeField:null,types:null,typeIdField:null,globalIdField:null,spatialReference:i.spatialReference,outSpatialReference:null,timeInfo:null,timeReferenceUnknownClient:null,dateFieldsTimeZone:null}),this._queryEngineParams={fieldsIndex:this._metadata.fieldsIndex,geometryType:p,featureIdInfo:{type:"object-id",fieldName:M},hasM:!1,hasZ:!1,spatialReference:i.spatialReference?.toJSON()??{wkid:4326},aggregateAdapter:null,timeInfo:null,definitionExpression:null},this._fullExtent=s?.extent?s.extent:await this._tryDeriveParquetFullExtent(i),{capabilities:this._capabilities,layerDefinition:{fields:i.fields?.map(t=>t.toJSON()),drawingInfo:(0,P.F0)(p),extent:this._fullExtent??void 0,geometryType:p,geometryEncoding:i.geometryEncoding?.toJSON(),displayOptimization:i.displayOptimization}}}destroy(){this._provider.destroy(),this._queue.destroy();for(const{handle:t}of this._streams.values())t.remove();this._streams.clear()}setCustomParameters(t){this._customParameters=t}getIndexMap(){return this._indexMap}async updateFileProvider(t){this._provider=(0,I.M)(t,this._provider.getGeometryInfo(),()=>this._customParameters)}async queryFeatures(t,e){return this._validateQuery(t),function(t){return!!(t.objectIds?.length||t.outStatistics||t.orderByFields?.length||t.returnDistinctValues)}(t)||(t.resultRecordCount=t.resultRecordCount?Math.min(t.resultRecordCount,k):k,t.resultOffset=t.resultOffset??0),t.outStatistics?this._queryStatistics(t,e):(t.returnDistinctValues&&(t.returnGeometry=void 0),(await this._enqueueQuery(t,e)).createQueryResponse())}async queryFeatureCount(t,e){const s=await(0,w.T2)(t,null,this._queryEngineParams.spatialReference);return this._validateQuery(s),V(s)?(s.outFields=void 0,s.returnGeometry=void 0,(await this._enqueueQuery(s,e)).createQueryResponseForCount()):this._getFeatureCount()}async queryObjectIds(t,e){const s=await(0,w.T2)(t,null,this._queryEngineParams.spatialReference);return this._validateQuery(s),V(s)?(s.resultRecordCount=s.resultRecordCount?Math.min(s.resultRecordCount,8e3):8e3,s.resultOffset=s.resultOffset??0,s.returnGeometry=void 0,s.outFields=void 0,(await this._enqueueQuery(s,e)).items.map(t=>t.getObjectId())):Array.from({length:await this._getFeatureCount()},(t,e)=>e)}async queryAttributeBins(t,e={}){throw new n.A("parquet:unsupported","queryAttributeBins not supported.")}async queryExtent(t,e){const s=await(0,w.T2)(t,null,this._queryEngineParams.spatialReference);if(this._validateQuery(s),this._fullExtent&&!V(s))return{count:await this._getFeatureCount(),extent:this._fullExtent};const i=(0,r.z)(this._metadata.spatialReference);s.returnGeometry=!0,s.outFields=void 0;const n=(0,p.hZ)((0,p.vt)(),p.qv),a=(0,p.vt)(),o=await this._enqueueQuery(s,e);let u=0;for(const t of o.items)t.getBounds(a)&&((0,p.RF)(n,a),u+=1);return{count:u,extent:(0,m.Wc)(n,i,s.outSR?(0,r.z)(s.outSR):i.toJSON(),i,!1)}}async queryStream(t,e){if(!e.signal)throw new Error("InternalError: AbortSignal must be passed");const s=await this._getCandidateFiles(t),i=new Q(s,async(e,s)=>{const i=await e.file,r=await this._createParquetQuery(i,e.id,t);return i.executeQuery(r,s)}),r=this._streamIdCounter++,n=(0,u.NY)(e.signal,t=>{const e=this._streams.get(r);null!=e&&(e.handle.remove(),this._streams.delete(r))});return this._streams.set(r,{stream:i,handle:n}),r}async getStreamNext(t,e){if(!e.signal)throw new Error("InternalError: AbortSignal must be passed");const s=this._streams.get(t);if(!s)return{result:null};const i=await s.stream.next(e.signal);if(null==i)return s.handle.remove(),this._streams.delete(t),{result:null};const r=i.chunk.serialize().buffer,n={fileId:i.fileId,buffer:r};return r instanceof ArrayBuffer?{result:n,transferList:[r]}:{result:n}}async getStreamNextFeatures(t,e){const{result:s}=await this.getStreamNext(t,e);if(null==s)return null;const i=(await(0,z.N)()).ParquetChunk.deserialize(new Uint8Array(s.buffer)),r=new E.s(this._metadata,this._indexMap,i,s.fileId),n=[];for(;r.next();){const t=(0,_.zv)(r.readGeometryWorldSpace(),r.geometryType,r.hasZ,r.hasM),e=r.readAttributes();n.push({attributes:e,geometry:t})}return{features:n}}async createPatch(t,e,s,i,r){if(!r.signal)throw new Error("InternalError: AbortSignal must be passed");const n=await this._getFileInfoById(t),a=await n.file;return(await a.createChunkPatch(e,s,i,r.signal)).serialize().buffer}async _getCandidateFiles(t){const e=await this._provider.getFiles(),s=await this._getSpatialFilePruning(t);if(null==s)return e;const i=e.filter(t=>this._mayIncludeFileForSpatialPruning(t,s));return"xz"===s.type?function(t,e){return t.slice().sort((t,s)=>{const i=H(t,e),r=H(s,e);return i===r?0:i<r?-1:1})}(i,s):i}async _queryStatistics(t,e){const s=await(0,w.T2)({...t},null,this._queryEngineParams.spatialReference);if(s.returnGeometry=void 0,function(t,e){return!!t.outStatistics?.length&&!V(t)&&!t.groupByFieldsForStatistics?.length&&!t.orderByFields?.length&&!t.returnDistinctValues&&!t.returnAggIds&&t.outStatistics.every(t=>function(t,e){switch(t.statisticType){case"count":return"1"===t.onStatisticField||null!=e.get(t.onStatisticField);case"min":case"max":{const s=e.get(t.onStatisticField);return null!=s&&(0,N.WA)(s)}default:return!1}}(t,e))}(s,this._fieldsIndex)){const t=await this._getStatisticsFromFiles(s);if(t)return t}return(await this._enqueueQuery(s,e)).createQueryResponse()}async _getStatisticsFromFiles(t){const e=await this._provider.getFiles(),s={},i=[];for(const r of t.outStatistics??[]){const t=J(r,e);if(!t.available)return null;s[r.outStatisticFieldName]=t.value,i.push(W(r,this._fieldsIndex))}return{fields:i,features:[{attributes:s}]}}async _getSpatialFilePruning(t){if("tile"!==t.type&&("arcade"!==t.type||null==t.extent))return null;const e=this._displayOptimization,s=e?.index;if(null==s)return null;const i=t.outSpatialReference.wkid;if(null==s.wkid||null==i)return null;const r=s.wkid,n=await(0,z.N)();switch(s.type){case"xz":return{type:"xz",fieldName:s.code,intersects:(e,a)=>n.queryIntersectsXZStatistics(s.fullExtent,t.extent,i,r,20,e,a)};case"z":return{type:"xy",xFieldName:s.xColumn,yFieldName:s.yColumn,intersects:(e,s,a,o)=>n.queryIntersectsXYStatistics(t.extent,i,r,e,s,a,o)}}}_mayIncludeFileForSpatialPruning(t,e){switch(e.type){case"xz":{const s=Y(t,e);return null==s||function(t,e){const s=X(t.minValue),i=X(t.maxValue);return null==s||null==i||e.intersects(s,i)}(s,e)}case"xy":{const{xStatistics:s,yStatistics:i}=function(t,e){return{xStatistics:t.statistics.statistics.get(e.xFieldName)??null,yStatistics:t.statistics.statistics.get(e.yFieldName)??null}}(t,e);return null==s||null==i||function(t,e,s){const i=X(t.minValue),r=X(t.maxValue),n=X(e.minValue),a=X(e.maxValue);return null==i||null==r||null==n||null==a||s.intersects(i,r,n,a)}(s,i,e)}}}async _tryDeriveParquetFullExtent(t){if(!t.spatialReference)return null;if(null==this._fullExtent&&"location"===t.geometryEncoding?.type){const e=await this._provider.getFiles(),{xField:s,yField:r}=t.geometryEncoding,n=(0,p.hZ)((0,p.vt)(),p.qv);for(const t of e){const e=await t.file;for(const t of e.rowGroups()){const e={stack:[],error:void 0,hasError:!1};try{const a=(0,i.mS)(e,t.columnDescriptorForAttribute(s),!1),o=(0,i.mS)(e,t.columnDescriptorForAttribute(r),!1),u=[a.minValue(),o.minValue(),a.maxValue(),o.maxValue()];(0,p.DC)(n,u),t.free()}catch(t){e.error=t,e.hasError=!0}finally{(0,i.hk)(e)}}}return{xmin:n[0],ymin:n[1],xmax:n[3],ymax:n[4],spatialReference:t.spatialReference?.toJSON()}}return null}async _getFileInfoById(t){const e=await this._provider.getFiles();for(const s of e)if(s.id===t)return s;throw new Error(`InternalError: File ${t} does not exist`)}async _getFileStatistics(){return{featureCount:await this._getFeatureCount(),byteLength:await this._getByteLength()}}async _getFile(t){return(await this._getFileInfoById(t)).file}async _createParquetQuery(t,e,s){const i=(await(0,z.N)()).Query.new();return"tile"===s.type?(i.setExtent(s.extent),i.setQuantizationTransform(s.transform),i.setScale(s.scale)):"arcade"===s.type&&null!=s.extent&&i.setExtent(s.extent),i.setOutFields(s.outFields.filter(t=>null!=this._indexMap[t])),i.setOutSpatialReference(s.outSpatialReference.wkid),i.setReturnGeometry(s.returnGeometry),s.where&&await this._setWhereClause(i,t,e,s.where),i}async _getFeatureCount(){return(await this._provider.getFiles()).map(t=>t.statistics.rowCount).reduce((t,e)=>t+e,0)}async _getByteLength(){return(await this._provider.getFiles()).map(t=>t.statistics.byteSize).reduce((t,e)=>t+e,0)}_validateQuery(t){if(!this._capabilities.query.supportsStatistics&&t.outStatistics)throw new n.A("parquet:unsupported","Statistics queries are not supported",{query:t});if(!this._capabilities.query.supportsOrderBy&&t.orderByFields?.length)throw new n.A("parquet:unsupported","Queries using orderBy are not supported",{query:t});if(!this._capabilities.query.supportsDistinct&&t.returnDistinctValues)throw new n.A("parquet:unsupported","Queries using returnDistinctValues are not supported",{query:t})}async _setWhereClause(t,e,s,i){const r=this._indexMap,a=this._fieldsIndex,o={getAttribute(t,i){const n=r[i];if(null==n){const e=a.get(i);if("__OBJECTID"===e?.name){const e=t.row+t.rowGroupStart;return(0,S.xb)(s,e)}return null}const o=e.readAttribute(t.rowGroup,t.row,n);if(null==o)return null;const u=a.get(i);return"esriFieldTypeString"===u.type||"esriFieldTypeDateOnly"===u.type||"esriFieldTypeTimeOnly"===u.type||"esriFieldTypeTimestampOffset"===u.type?G.decode(o):o}},u=await(0,l.GP)(i,this._fieldsIndex);if(!u.isStandardized)throw new n.A("sql-parse-error","expression is not standardized");const h=u.fieldNames.map(t=>a.get(t)).filter(t=>t&&null!=this._indexMap[t?.name]);t.setWhere(i),t.setWhereEvaluator((t,e,s)=>u.testFeatureCompiled({rowGroup:t,row:e,rowGroupStart:s},o,null)),t.setWhereFields(h.map(t=>t.name))}async*_queryChunks(t,e){const s=await(0,z.N)(),i=await this._provider.getFiles(),r=await this._getRequiredFields(t),n=this._tryGetGeneralizedGeometryScale(t);for(const a of i){const i=await a.file,o=s.Query.new();o.setOutFields(r),(t.geometry||t.returnGeometry)&&o.setReturnGeometry(!0),null!=n&&o.setScale(n);const h=t.geometry?.spatialReference??this._queryEngineParams.spatialReference,l=h.wkid;if(t.geometry&&((0,y.K8)(h)||(0,y.oT)(h))){const e=(0,d.C)((0,d.vt)(),d.qv);for(const s of(0,m.qo)(t.geometry))(0,d.DC)(e,s);o.setOutSpatialReference(l),o.setExtent({xmin:e[0],ymin:e[1],xmax:e[2],ymax:e[3]})}t.where&&await this._setWhereClause(o,i,a.id,t.where);const c=await i.executeQuery(o),p=[],f=c.next(e);for(let t=0;t<4;t++)p.push(c.next(e));let _=await f;for(;null!=_;){(0,u.Te)(e);const t=new E.s(this._metadata,this._indexMap,_,a.id),s=L([new q.j(t,null,0,!1)],this._queryEngineParams),i=p.shift();p.push(c.next(e)),yield s,_=await i}}}_enqueueQuery(t,e){return this._queue.push(t,e)}async _executeQuery(t,e){if(t.objectIds?.length){const s=new Map;for(const e of t.objectIds){const t=(0,S.wY)(e),i=(0,S.gE)(e);let r=s.get(t);r||(r=[],s.set(t,r)),r.push(i)}const i=[];for(const[r,n]of s.entries()){const s=await this._executeFileIdQuery(t,r,n,e);for(const t of s)i.push(t)}return new x.G(i,t,{fieldsIndex:this._fieldsIndex,geometryType:this._metadata.geometryType,spatialReference:this._queryEngineParams.spatialReference,hasM:!1,hasZ:!1,featureAdapter:A,featureIdInfo:this._queryEngineParams.featureIdInfo})}let s=t.resultRecordCount??await this._getFeatureCount(),i=t.resultOffset??0;if(s>2e7)throw new n.A("parquet:cannot-execute-query","Unable to execute query, dataset is too large.");const r={...t};t.where=void 0,t.resultRecordCount=void 0,t.resultOffset=void 0;const a=[];for await(const n of this._queryChunks(r,e)){const r=await n.executeQueryForOpaqueFeatures(t,e);if(r.length>i){const e=r.slice(i,Math.min(i+s,r.length));for(const t of e)a.push(t);if(i=0,s-=e.length,0===s)return new x.G(a,t,{fieldsIndex:this._fieldsIndex,geometryType:this._metadata.geometryType,spatialReference:this._queryEngineParams.spatialReference,hasM:!1,hasZ:!1,featureAdapter:A,featureIdInfo:this._queryEngineParams.featureIdInfo})}else i-=r.length}return new x.G(a,t,{fieldsIndex:this._fieldsIndex,geometryType:this._metadata.geometryType,spatialReference:this._queryEngineParams.spatialReference,hasM:!1,hasZ:!1,featureAdapter:A,featureIdInfo:this._queryEngineParams.featureIdInfo})}async _executeFileIdQuery(t,e,s,i){const r=await this._getRequiredFields(t),n=(await(0,z.N)()).Query.new();n.setOutFields(r),n.setReturnGeometry(!!t.returnGeometry),n.setIds(new Uint32Array(s));const a=await this._getFile(e),o=await a.executeQuery(n,i);let u=await o.next(i),h=0;const l=[];for(;null!=u;){const t=new E.s(this._metadata,this._indexMap,u,e),s=new q.j(t,null,h++,!1);l.push(s),u=await o.next(i)}return L(l,this._queryEngineParams).executeQueryForOpaqueFeatures(t,i)}async _getRequiredFields(t){const e=new Set;if(t.outStatistics)for(const s of t.outStatistics)null!=s.onStatisticField&&e.add(s.onStatisticField);else if(t.outFields)for(const s of t.outFields)e.add(s);return(e.has("*")?this._fieldsIndex.fields.map(t=>t.name):Array.from(e)).filter(t=>null!=this._indexMap[t])}_tryGetGeneralizedGeometryScale(t){if(!this._displayOptimization)return null;const e=t.outSR??this._queryEngineParams.spatialReference;if(!(0,y.K8)(e)&&!(0,y.oT)(e))return null;const s=t.quantizationParameters?.tolerance??t.maxAllowableOffset;return s?(0,f.gB)(s,e):null}}function V(t){for(const e in t){const s=e;switch(s){case"resultOffset":case"resultRecordCount":case"aggregateIds":case"distance":case"gdbVersion":case"geometry":case"having":case"timeExtent":case"objectIds":case"historicMoment":case"where":return null!=t[s]}}return!1}function W(t,e){const s="exceedslimit"!==t.statisticType?e.get(t.onStatisticField):null,i="min"!==t.statisticType&&"max"!==t.statisticType||"esriFieldTypeDate"!==s?.type?"esriFieldTypeDouble":s.type;return{name:t.outStatisticFieldName,alias:t.outStatisticFieldName,type:i}}function J(t,e){switch(t.statisticType){case"count":return function(t,e){if("count"!==t.statisticType)return{available:!1,value:null};if("1"===t.onStatisticField)return{available:!0,value:e.reduce((t,e)=>t+e.statistics.rowCount,0)};let s=0;for(const i of e){const e=i.statistics.statistics.get(t.onStatisticField);if(null==e||null==e.nullCount)return{available:!1,value:null};s+=i.statistics.rowCount-e.nullCount}return{available:!0,value:s}}(t,e);case"min":return j(t,e,Math.min);case"max":return j(t,e,Math.max);default:return{available:!1,value:null}}}function j(t,e,s){if("min"!==t.statisticType&&"max"!==t.statisticType)return{available:!1,value:null};let i=null;const r="min"===t.statisticType?"minValue":"maxValue";for(const n of e){const e=n.statistics.statistics.get(t.onStatisticField);if(null==e)return{available:!1,value:null};const a=U(e[r]);null!=a&&(i=null==i?a:s(i,a))}return{available:!0,value:i}}function U(t){return"number"==typeof t&&Number.isFinite(t)?t:null}function L(t,e){const s=new R.I;for(const e of t)s.insert(e);return new m.do({...e,featureStore:s})}function Y(t,e){return t.statistics.statistics.get(e.fieldName)??null}function H(t,e){const s=Y(t,e);if(null==s)return Number.POSITIVE_INFINITY;const i=X(s.minValue),r=X(s.maxValue);return null==i||null==r||r<i?Number.POSITIVE_INFINITY:r-i}function X(t){return"number"==typeof t&&Number.isFinite(t)?t:null}function K(t){const e=t?.featureCount;let s=!1;return null!=e&&e<(0,a.A)("parquetlayer-full-query-feature-count")&&(s=!0),{analytics:{supportsCacheHint:!1},attachment:null,data:{isVersioned:!1,isBranchVersioned:!1,supportedCurveTypes:[],supportsAttachment:!1,supportsM:!1,supportsTrueCurve:!1,supportsZ:!1},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:!1,supportsDelete:!1,supportsEditing:!1,supportsChangeTracking:!1,supportsQuery:!0,supportsQueryBins:!1,supportsQueryPivot:!1,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:!1,supportsExceedsLimitStatistics:!1,supportsAsyncConvert3D:!1},query:{...g.F,maxRecordCount:k,supportsOrderBy:s,supportsDistinct:!0,supportsStatistics:!0,supportsSpatialAggregationStatistics:!1,supportedSpatialAggregationStatistics:{envelope:!1,centroid:!1,convexHull:!1}},queryAttributeBins:{supportsDate:!1,supportsFixedInterval:!1,supportsAutoInterval:!1,supportsFixedBoundaries:!1,supportsStackBy:!1,supportsSplitBy:!1,supportsSnapToData:!1,supportsReturnFullIntervalBin:!1,supportsFirstDayOfWeek:!1,supportsNormalization:!1},queryRelated:{supportsCount:!1,supportsOrderBy:!1,supportsPagination:!1,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},editing:{supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsGeometryUpdate:!1,supportsGlobalId:!1,supportsTrueCurveUpdate:!1,supportsTrueCurveUpdateByTrueCurveClientsOnly:!0,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsUploadWithItemId:!1,supportsUpdateWithoutM:!1,supportsAsyncApplyEdits:!1,zDefault:void 0}}}}}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[2293,4342],{46140(e,t,r){r.d(t,{A:()=>o});var i=r(49186);class o{constructor(e,t,r=""){this.major=e,this.minor=t,this._context=r}lessThan(e,t){return this.major<e||e===this.major&&this.minor<t}greaterEqual(e,t){return!this.lessThan(e,t)}toString(){return`${this.major}.${this.minor}`}validate(e){if(this.major!==e.major){const t=this._context&&this._context+":",r=this._context&&this._context+" ";throw new i.A(t+"unsupported-version",`Required major ${r}version is '${this.major}', but got '\${version.major}.\${version.minor}'`,{version:e})}}clone(){return new o(this.major,this.minor,this._context)}static parse(e,t=""){const[r,n]=e.split("."),s=/^\s*\d+\s*$/;if(!r?.match||!s.test(r))throw new i.A((t&&t+":")+"invalid-version","Expected major version to be a number, but got '${version}'",{version:e});if(!n?.match||!s.test(n))throw new i.A((t&&t+":")+"invalid-version","Expected minor version to be a number, but got '${version}'",{version:e});const a=parseInt(r,10),l=parseInt(n,10);return new o(a,l,t)}}},62815(e,t,r){r.d(t,{N:()=>a,d:()=>l});var i=r(86211),o=r(73941),n=r(21325),s=r(52006);function a(e,t,r){const i=l(t,r);if(1!==i)switch(e){case"point":case"esriGeometryPoint":return e=>function(e,t){null!=e?.z&&(e.z*=t)}(e,i);case"polyline":case"esriGeometryPolyline":return e=>function(e,t){if(e){if(e.curvePaths)for(const r of e.curvePaths)for(const e of r){const r=(0,s.yP)(e);r.length>2&&(r[2]*=t)}if(e.paths)for(const r of e.paths)for(const e of r)e.length>2&&(e[2]*=t)}}(e,i);case"polygon":case"esriGeometryPolygon":return e=>function(e,t){if(e){if(e.curveRings)for(const r of e.curveRings)for(const e of r){const r=(0,s.yP)(e);r.length>2&&(r[2]*=t)}if(e.rings)for(const r of e.rings)for(const e of r)e.length>2&&(e[2]*=t)}}(e,i);case"multipoint":case"esriGeometryMultipoint":return e=>function(e,t){if(e)for(const r of e.points)r.length>2&&(r[2]*=t)}(e,i);case"extent":case"esriGeometryEnvelope":return e=>function(e,t){e&&null!=e.zmin&&null!=e.zmax&&(e.zmin*=t,e.zmax*=t)}(e,i);default:return}}function l(e,t){return null==e||null==t||(0,n.aI)(e,t)||(0,o.xP)(e)||(0,o.xP)(t)?1:(0,i.G9)(e)/(0,i.G9)(t)}},16852(e,t,r){r.r(t),r.d(t,{default:()=>P});var i=r(5482),o=r(49186),n=r(4718),s=r(93637),a=r(91429),l=r(16930),p=r(55156),c=r(60950),u=r(89808),d=r(99959);const y=Symbol("isOrientedImageryGraphicOrigin");var f;class h extends d.A{get[(f=y,c.ym)](){return this.layer}get[p.e](){return this.layer}get[u.Q](){return this.layer}constructor(e){super(),this[f]=!0,this.type="oriented-imagery",this.layer=e}get id(){return this.layer.id}}var g=r(53781),m=r(82935),v=r(23281),w=r(20437),C=r(43440),M=r(79677);const b=new Set(["demPathPrefix","demPathSuffix","depthImagePathPrefix","depthImagePathSuffix","elevationSource","horizontalMeasurementUnit","imageGeometryField","imageReferenceField","referenceIDField","sequenceOrderField","verticalMeasurementUnit","videoPathPrefix","videoPathSuffix","timeAnimation","visibilityTimeExtent"]),j=new Set(["elevationSource"]),Z=(e,t)=>!b.has(t)&&e;function x(e,t,r,i){const{name:o,write:n,read:s}=((e,t,r)=>{const i=`orientedImageryProperties.${e}`,o={allowNull:j.has(e),ignoreOrigin:!0};return{name:i,write:t?{...o,target:i,writer:t}:o,read:r?{ignoreOrigin:!0,source:i,reader:r}:{ignoreOrigin:!0}}})(e,t,r),a={name:o,write:n,read:s,origins:{service:{name:`orientedImageryInfo.${o}`,write:t,read:r},"web-scene":{name:o,write:Z(n,e),read:Z(s,e)},"web-map":{name:o,write:n,read:s}}};return i&&a.origins?(a.type=i,a.origins["web-map"].type=i,a.origins["web-scene"].type=i,a):a}let S=class extends g.default{constructor(e){super(e),this.attributeTableTemplate=null,this.cameraHeading=null,this.cameraHeight=null,this.cameraPitch=null,this.cameraRoll=null,this.coveragePercent=null,this.demPathPrefix=null,this.demPathSuffix=null,this.depthImagePathPrefix=null,this.depthImagePathSuffix=null,this.elevationSource=null,this.farDistance=null,this.geometryType="point",this.graphicOrigin=new h(this),this.horizontalFieldOfView=null,this.horizontalMeasurementUnit=null,this.imageGeometryField="ImageGeometry",this.imagePathPrefix=null,this.imagePathSuffix=null,this.imageReferenceField="OIObjectID",this.imageRotation=null,this.maximumDistance=null,this.nearDistance=null,this.operationalLayerType="OrientedImageryLayer",this.orientationAccuracy=null,this.orientedImageryType=null,this.referenceIDField="OBJECTID",this.sequenceOrderField="SequenceOrder",this.subtypeField=null,this.subtypes=null,this.supportedSourceTypes=new Set(["Oriented Imagery Layer"]),this.type="oriented-imagery",this.timeIntervalUnit="days",this.useViewTime=!0,this.verticalFieldOfView=null,this.verticalMeasurementUnit=null,this.verticalSearchRange=null,this.videoPathPrefix=null,this.videoPathSuffix=null,this.virtualCacheDirectory=null,this.dataStoreID=null,this.visibilityTimeExtent=null}get effectiveElevationSource(){const{elevationSource:e,demPathPrefix:t,demPathSuffix:r}=this;return(0,v.eR)(e,t,r)}get effectiveSequenceOrderField(){const{sequenceOrderField:e,fields:t}=this;return(0,v.o)(e,t)}get fieldConfigurations(){return super.fieldConfigurations}set fieldConfigurations(e){super.fieldConfigurations=e}get portalItem(){return super.portalItem}set portalItem(e){super.portalItem=e}async save(e){return this._debouncedSaveOperations(0,e)}async saveAs(e,t){return this._debouncedSaveOperations(1,t,e)}findFirstValidLayerId(e){return e.layers?.find(({type:e})=>!!e&&this.supportedSourceTypes.has(e))?.id}_verifySource(){if(super._verifySource(),"point"!==this.geometryType)throw new o.A("oriented-imagery-layer:invalid-geometry-type","OrientedImageryLayer only supports point geometry type")}};var T;(0,i.Cg)([(0,a.MZ)({type:C.A,json:{write:!1,read:!1}})],S.prototype,"attributeTableTemplate",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:x("cameraHeading")})],S.prototype,"cameraHeading",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:x("cameraHeight")})],S.prototype,"cameraHeight",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:x("cameraPitch")})],S.prototype,"cameraPitch",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:x("cameraRoll")})],S.prototype,"cameraRoll",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:x("coveragePercent")})],S.prototype,"coveragePercent",void 0),(0,i.Cg)([(0,a.MZ)({type:String,json:x("demPathPrefix")})],S.prototype,"demPathPrefix",void 0),(0,i.Cg)([(0,a.MZ)({type:String,json:x("demPathSuffix")})],S.prototype,"demPathSuffix",void 0),(0,i.Cg)([(0,a.MZ)({type:String,json:x("depthImagePathPrefix")})],S.prototype,"depthImagePathPrefix",void 0),(0,i.Cg)([(0,a.MZ)({type:String,json:x("depthImagePathSuffix")})],S.prototype,"depthImagePathSuffix",void 0),(0,i.Cg)([(0,a.MZ)({type:Object,json:x("elevationSource")})],S.prototype,"elevationSource",void 0),(0,i.Cg)([(0,a.MZ)({readOnly:!0})],S.prototype,"effectiveElevationSource",null),(0,i.Cg)([(0,a.MZ)({readOnly:!0})],S.prototype,"effectiveSequenceOrderField",null),(0,i.Cg)([(0,a.MZ)({type:Number,json:x("farDistance")})],S.prototype,"farDistance",void 0),(0,i.Cg)([(0,a.MZ)({type:[w.A]})],S.prototype,"fields",void 0),(0,i.Cg)([(0,a.MZ)()],S.prototype,"geometryType",void 0),(0,i.Cg)([(0,a.MZ)({readOnly:!0,clonable:!1})],S.prototype,"graphicOrigin",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:x("horizontalFieldOfView")})],S.prototype,"horizontalFieldOfView",void 0),(0,i.Cg)([(0,a.MZ)({type:String,json:x("horizontalMeasurementUnit")})],S.prototype,"horizontalMeasurementUnit",void 0),(0,i.Cg)([(0,a.MZ)({type:String,json:{...x("imageGeometryField"),default:"ImageGeometry"}})],S.prototype,"imageGeometryField",void 0),(0,i.Cg)([(0,a.MZ)({type:String,json:x("imagePathPrefix")})],S.prototype,"imagePathPrefix",void 0),(0,i.Cg)([(0,a.MZ)({type:String,json:x("imagePathSuffix")})],S.prototype,"imagePathSuffix",void 0),(0,i.Cg)([(0,a.MZ)({type:String,json:{...x("imageReferenceField"),default:"OIObjectID"}})],S.prototype,"imageReferenceField",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:x("imageRotation")})],S.prototype,"imageRotation",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:x("maximumDistance")})],S.prototype,"maximumDistance",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:x("nearDistance")})],S.prototype,"nearDistance",void 0),(0,i.Cg)([(0,a.MZ)({type:["OrientedImageryLayer"],json:{origins:{"portal-item":{name:"layerType",write:{enabled:!0,ignoreOrigin:!0}}}}})],S.prototype,"operationalLayerType",void 0),(0,i.Cg)([(0,a.MZ)({json:{...x("orientationAccuracy",(e,t,r)=>{(0,s.sM)(r,e.join(";"),t)},e=>{const t=e?.split(";")?.map(Number);return(0,v.Qv)(t)?(0,v.Yp)(t):[0,0,0,0,0,0,0,0]},String)}})],S.prototype,"orientationAccuracy",void 0),(0,i.Cg)([(0,a.MZ)({json:{...x("orientedImageryType",v.fs.write,v.fs.read,v.fs.jsonValues.slice(1))}})],S.prototype,"orientedImageryType",void 0),(0,i.Cg)([(0,a.MZ)({type:String,json:{...x("referenceIDField"),default:"OBJECTID"}})],S.prototype,"referenceIDField",void 0),(0,i.Cg)([(0,a.MZ)({type:String,json:{...x("sequenceOrderField"),default:"SequenceOrder"}})],S.prototype,"sequenceOrderField",void 0),(0,i.Cg)([(0,a.MZ)({type:l.A})],S.prototype,"spatialReference",void 0),(0,i.Cg)([(0,a.MZ)({readOnly:!0})],S.prototype,"subtypeField",void 0),(0,i.Cg)([(0,a.MZ)({readOnly:!0})],S.prototype,"subtypes",void 0),(0,i.Cg)([(0,a.MZ)({json:{read:!1},value:"oriented-imagery",readOnly:!0})],S.prototype,"type",void 0),(0,i.Cg)([(0,a.MZ)({type:v.RR.apiValues,json:{...x("timeIntervalUnit",v.RR.write,v.RR.read,v.RR.jsonValues)}})],S.prototype,"timeIntervalUnit",void 0),(0,i.Cg)([(0,a.MZ)((T=(0,n.o8)(m.B),T.json?(T.json.origins=T.json.origins??{},T.json.origins["web-scene"]={write:!1,read:!1},T):T))],S.prototype,"useViewTime",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:x("verticalFieldOfView")})],S.prototype,"verticalFieldOfView",void 0),(0,i.Cg)([(0,a.MZ)({type:v.l6.apiValues,json:{...x("verticalMeasurementUnit",v.l6.write,v.l6.read,v.l6.jsonValues)}})],S.prototype,"verticalMeasurementUnit",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:x("verticalSearchRange")})],S.prototype,"verticalSearchRange",void 0),(0,i.Cg)([(0,a.MZ)({type:String,json:x("videoPathPrefix")})],S.prototype,"videoPathPrefix",void 0),(0,i.Cg)([(0,a.MZ)({type:String,json:x("videoPathSuffix")})],S.prototype,"videoPathSuffix",void 0),(0,i.Cg)([(0,a.MZ)({type:String,json:{read:!1,write:!1,origins:{service:{name:"orientedImageryInfo.orientedImageryProperties.virtualCacheDirectory",read:!0}}}})],S.prototype,"virtualCacheDirectory",void 0),(0,i.Cg)([(0,a.MZ)({type:String,json:{read:!1,write:!1,origins:{service:{name:"orientedImageryInfo.dsid",read:!0}}}})],S.prototype,"dataStoreID",void 0),(0,i.Cg)([(0,a.MZ)({type:M.A,json:{origins:{"web-scene":{write:!1,read:!1}}}})],S.prototype,"visibilityTimeExtent",void 0),S=(0,i.Cg)([(0,a.$K)("esri.layers.OrientedImageryLayer")],S);const P=S},32756(e,t,r){r.d(t,{Rr:()=>a,fY:()=>p,ne:()=>l});var i=r(5482),o=r(93637),n=r(91429),s=r(91880);function a(e,t,r){if(!e)return null;const i=e.find(e=>!!e.field);if(!i)return null;const o=new s.A;return o.read(i,r),[o]}const l={type:[s.A],json:{origins:{"web-scene":{write:!1,read:!1}},name:"layerDefinition.orderBy",read:{reader:a},write:{writer:function(e,t,r,i){const n=e.find(e=>!!e.field);n&&(0,o.sM)(r,[n.toJSON()],t)}}}},p=e=>{const t=e;let r=class extends t{constructor(){super(...arguments),this.orderBy=null}};return(0,i.Cg)([(0,n.MZ)(l)],r.prototype,"orderBy",void 0),r=(0,i.Cg)([(0,n.$K)("esri.layers.mixins.OrderedLayer")],r),r}},63490(e,t,r){r.d(t,{E1:()=>p,Mr:()=>l,TH:()=>a});var i=r(5482),o=r(69540),n=r(25482),s=r(91429);let a=class extends((0,o.OU)(n.o)){constructor(){super(...arguments),this.url=null}};(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],a.prototype,"lod",void 0),(0,i.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],a.prototype,"rasterFunction",void 0),(0,i.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],a.prototype,"url",void 0),a=(0,i.Cg)([(0,s.$K)("esri.layers.orientedImagery.core.ElevationSourceDefinitions.ElevationSource")],a);let l=class extends((0,o.OU)(n.o)){constructor(e){super(e),this.constantElevation=null}};(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],l.prototype,"constantElevation",void 0),l=(0,i.Cg)([(0,s.$K)("esri.layers.orientedImagery.core.ElevationSourceDefinitions.ConstantElevation")],l);const p=e=>null!=e&&"number"==typeof e.constantElevation},23281(e,t,r){r.d(t,{eR:()=>b,Qv:()=>D,fs:()=>x,Yp:()=>N,o:()=>O,RR:()=>j,l6:()=>Z});var i=r(66552),o=(r(86211),r(28735),r(5482)),n=r(69540),s=r(25482),a=r(91429),l=r(69622),p=r(21325);let c=class extends l.A{set horizontalWKID(e){e?(0,p.fn)({wkid:+e})?this._set("horizontalWKID",+e):this._set("horizontalWKID",e):this._set("horizontalWKID",null)}set verticalWKID(e){e?this._set("verticalWKID",isFinite(e)&&(0,p.fn)({wkid:+e})?+e:null):this._set("verticalWKID",null)}get isAdvanced(){const{affineTransformations:e,focalLength:t,principalOffsetPoint:r,radialDistortionCoefficients:i,tangentialDistortionCoefficients:o}=this;return e?.length>1&&!Number.isNaN(t)&&r?.length>1&&i?.length>1&&o?.length>1}};(0,o.Cg)([(0,a.MZ)({json:{write:!0}})],c.prototype,"affineTransformations",void 0),(0,o.Cg)([(0,a.MZ)({json:{write:!0}})],c.prototype,"focalLength",void 0),(0,o.Cg)([(0,a.MZ)({json:{write:!0}})],c.prototype,"principalOffsetPoint",void 0),(0,o.Cg)([(0,a.MZ)({json:{write:!0}})],c.prototype,"radialDistortionCoefficients",void 0),(0,o.Cg)([(0,a.MZ)({json:{write:!0}})],c.prototype,"tangentialDistortionCoefficients",void 0),(0,o.Cg)([(0,a.MZ)({json:{write:!0}})],c.prototype,"horizontalWKID",null),(0,o.Cg)([(0,a.MZ)({json:{write:!0}})],c.prototype,"verticalWKID",null),(0,o.Cg)([(0,a.MZ)({json:{write:!0}})],c.prototype,"x",void 0),(0,o.Cg)([(0,a.MZ)({json:{write:!0}})],c.prototype,"y",void 0),(0,o.Cg)([(0,a.MZ)({json:{write:!0}})],c.prototype,"z",void 0),(0,o.Cg)([(0,a.MZ)({json:{write:!0}})],c.prototype,"type",void 0),c=(0,o.Cg)([(0,a.$K)("esri.layers.orientedImagery.core.CameraOrientation")],c);const u=c;let d=class extends((0,n.OU)((0,s.T)(u))){constructor(){super(...arguments),this.type=1}toString(){const{type:e,horizontalWKID:t,verticalWKID:r,x:i,y:o,z:n,heading:s,pitch:a,roll:l,affineTransformations:p,focalLength:c,principalOffsetPoint:u,radialDistortionCoefficients:d,tangentialDistortionCoefficients:y}=this,f=[e,t,r,i,o,n,s,a,l];return this.isAdvanced&&(p?.forEach(e=>f.push(e)),f.push(c),u?.forEach(e=>f.push(e)),d?.forEach(e=>f.push(e)),y?.forEach(e=>f.push(e))),f.map(e=>Number.isNaN(e)?"":e).join("|")}};(0,o.Cg)([(0,a.MZ)({json:{write:!0}})],d.prototype,"type",void 0),(0,o.Cg)([(0,a.MZ)({type:[Number],json:{write:!0}})],d.prototype,"affineTransformations",void 0),(0,o.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],d.prototype,"focalLength",void 0),(0,o.Cg)([(0,a.MZ)({type:[Number],json:{write:!0}})],d.prototype,"principalOffsetPoint",void 0),(0,o.Cg)([(0,a.MZ)({type:[Number],json:{write:!0}})],d.prototype,"radialDistortionCoefficients",void 0),(0,o.Cg)([(0,a.MZ)({type:[Number],json:{write:!0}})],d.prototype,"tangentialDistortionCoefficients",void 0),(0,o.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],d.prototype,"heading",void 0),(0,o.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],d.prototype,"pitch",void 0),(0,o.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],d.prototype,"roll",void 0),(0,o.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],d.prototype,"x",void 0),(0,o.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],d.prototype,"y",void 0),(0,o.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],d.prototype,"z",void 0),d=(0,o.Cg)([(0,a.$K)("esri.layers.orientedImagery.core.CameraOrientationHPR")],d);const y=d;let f=class extends((0,n.OU)((0,s.T)(u))){constructor(){super(...arguments),this.type=4}toString(){const{type:e,latitude:t,longitude:r,ellipsoidRadius:i,squaredEccentricity:o,properties:n}=this,s=`${n}`.split("|");return s.splice(1,1),`${e}|${t}|${r}|${i}|${o}|${s.join("|")}`}};(0,o.Cg)([(0,a.MZ)({json:{write:!0}})],f.prototype,"type",void 0),(0,o.Cg)([(0,a.MZ)({json:{write:!0},type:Number})],f.prototype,"latitude",void 0),(0,o.Cg)([(0,a.MZ)({json:{write:!0},type:Number})],f.prototype,"longitude",void 0),(0,o.Cg)([(0,a.MZ)({json:{write:!0},type:Number})],f.prototype,"ellipsoidRadius",void 0),(0,o.Cg)([(0,a.MZ)({json:{write:!0},type:Number})],f.prototype,"squaredEccentricity",void 0),(0,o.Cg)([(0,a.MZ)({json:{write:!0}})],f.prototype,"properties",void 0),f=(0,o.Cg)([(0,a.$K)("esri.layers.orientedImagery.core.CameraOrientationLTP")],f);const h=f;let g=class extends((0,n.OU)((0,s.T)(u))){constructor(){super(...arguments),this.type=2}toString(){const{type:e,horizontalWKID:t,verticalWKID:r,x:i,y:o,z:n,omega:s,phi:a,kappa:l,affineTransformations:p,focalLength:c,principalOffsetPoint:u,radialDistortionCoefficients:d,tangentialDistortionCoefficients:y}=this,f=[e,t,r,i,o,n,s,a,l];return this.isAdvanced&&(p?.forEach(e=>f.push(e)),f.push(c),u?.forEach(e=>f.push(e)),d?.forEach(e=>f.push(e)),y?.forEach(e=>f.push(e))),f.map(e=>isNaN(e)?"":e).join("|")}};(0,o.Cg)([(0,a.MZ)({json:{write:!0}})],g.prototype,"type",void 0),(0,o.Cg)([(0,a.MZ)({type:[Number],json:{write:!0}})],g.prototype,"affineTransformations",void 0),(0,o.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],g.prototype,"focalLength",void 0),(0,o.Cg)([(0,a.MZ)({type:[Number],json:{write:!0}})],g.prototype,"principalOffsetPoint",void 0),(0,o.Cg)([(0,a.MZ)({type:[Number],json:{write:!0}})],g.prototype,"radialDistortionCoefficients",void 0),(0,o.Cg)([(0,a.MZ)({type:[Number],json:{write:!0}})],g.prototype,"tangentialDistortionCoefficients",void 0),(0,o.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],g.prototype,"omega",void 0),(0,o.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],g.prototype,"phi",void 0),(0,o.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],g.prototype,"kappa",void 0),(0,o.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],g.prototype,"x",void 0),(0,o.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],g.prototype,"y",void 0),(0,o.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],g.prototype,"z",void 0),g=(0,o.Cg)([(0,a.$K)("esri.layers.orientedImagery.core.CameraOrientationOPK")],g);const m=g;let v=class extends((0,n.OU)((0,s.T)(u))){constructor(){super(...arguments),this.type=3}get isAdvanced(){const{affineTransformations:e,focalLength:t,principalOffsetPoint:r,radialDistortionCoefficients:i,tangentialDistortionCoefficients:o}=this;return e?.length>1||!Number.isNaN(t)||r?.length>1||i?.length>1||o?.length>1}toString(){const{type:e,horizontalWKID:t,verticalWKID:r,x:i,y:o,z:n,yaw:s,pitch:a,roll:l,affineTransformations:p,focalLength:c,principalOffsetPoint:u,radialDistortionCoefficients:d,tangentialDistortionCoefficients:y}=this,f=[e,t,r,i,o,n,s,a,l];return this.isAdvanced&&(p?.forEach(e=>f.push(e)),f.push(c),u?.forEach(e=>f.push(e)),u?.forEach(e=>f.push(e)),d?.forEach(e=>f.push(e)),y?.forEach(e=>f.push(e))),f.map(e=>Number.isNaN(e)?"":e).join("|")}};(0,o.Cg)([(0,a.MZ)({json:{write:!0}})],v.prototype,"type",void 0),(0,o.Cg)([(0,a.MZ)({type:[Number],json:{write:!0}})],v.prototype,"affineTransformations",void 0),(0,o.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],v.prototype,"focalLength",void 0),(0,o.Cg)([(0,a.MZ)({type:[Number],json:{write:!0}})],v.prototype,"principalOffsetPoint",void 0),(0,o.Cg)([(0,a.MZ)({type:[Number],json:{write:!0}})],v.prototype,"radialDistortionCoefficients",void 0),(0,o.Cg)([(0,a.MZ)({type:[Number],json:{write:!0}})],v.prototype,"tangentialDistortionCoefficients",void 0),(0,o.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],v.prototype,"yaw",void 0),(0,o.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],v.prototype,"pitch",void 0),(0,o.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],v.prototype,"roll",void 0),(0,o.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],v.prototype,"x",void 0),(0,o.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],v.prototype,"y",void 0),(0,o.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],v.prototype,"z",void 0),v=(0,o.Cg)([(0,a.$K)("esri.layers.orientedImagery.core.CameraOrientationYPR")],v);const w=v,C=new Map;C.set("2",{desc:"Using Omega Phi Kappa",constructor:m}),C.set("1",{desc:"Using Heading, Pitch and Roll",constructor:y}),C.set("3",{desc:"Using Yaw, Pitch and Roll",constructor:w}),C.set("4",{desc:"Using Local Tangent Plane",constructor:h});var M=r(63490);function b(e,t,r){return e?(0,M.E1)(e)?new M.Mr(e):function(e,t,r){let{url:i}=e;return i?(i=function(e,t,r){return t&&(e=`${t}${e}`),r&&(e+=`${r}`),e}(i,t,r),new M.TH({...e,url:i})):null}(e,t,r):e}const j=new i.J({Minutes:"minutes",Hours:"hours",Days:"days",Weeks:"weeks",Months:"months",Years:"years"}),Z=new i.J({Feet:"feet",Meter:"meter"}),x=new i.J({360:"360",Horizontal:"horizontal",Inspection:"inspection",Nadir:"nadir",Oblique:"oblique",Terrestrial360Video:"terrestrial-360-video",TerrestrialFrameVideo:"terrestrial-frame-video",Aerial360Video:"aerial-360-video",AerialFrameVideo:"aerial-frame-video","":null}),S=new Map;S.set("1",function(e){const[t,r,i,o,n,s,a,l,p,c,u,d,y,f,h,g,m,v,w,C,M,b]=e.slice(1);return{horizontalWKID:t,verticalWKID:r,x:i,y:o,z:n,heading:s,pitch:a,roll:l,...P([p,c,u,d,y,f],[g,m],[v,w,C],[M,b],h)}}),S.set("3",function(e){const[t,r,i,o,n,s,a,l,p,c,u,d,y,f,h,g,m,v,w,C,M,b]=e.slice(1);return{horizontalWKID:t,verticalWKID:r,x:i,y:o,z:n,yaw:s,pitch:a,roll:l,...P([p,c,u,d,y,f],[g,m],[v,w,C],[M,b],h)}}),S.set("2",function(e){const[t,r,i,o,n,s,a,l,p,c,u,d,y,f,h,g,m,v,w,C,M,b]=e.slice(1);return{horizontalWKID:t,verticalWKID:r,x:i,y:o,z:n,omega:s,phi:a,kappa:l,...P([p,c,u,d,y,f],[g,m],[v,w,C],[M,b],h)}}),S.set("4",function(e){const[t,r,i,o,n,...s]=e.slice(1),a=S.get(n),l=C.get(n)?.constructor;return a&&l?{latitude:t,longitude:r,ellipsoidRadius:i,squaredEccentricity:o,properties:new l(a([n,"",...s]))}:null});const T=e=>{const t=e.map(e=>parseFloat(e)).filter(e=>!isNaN(e));if(t.length===e.length)return t};function P(e,t,r,i,o){const n=T(e),s=T(t),a=T(r),l=T(i);return{affineTransformations:6===n?.length?n:void 0,focalLength:6===n?.length?parseFloat(o):void 0,principalOffsetPoint:2!==s?.length?[0,0]:s,radialDistortionCoefficients:3!==a?.length?[0,0,0]:a,tangentialDistortionCoefficients:2!==l?.length?[0,0]:l}}function D(e){return Array.isArray(e)&&e?.length>5&&!e.some(isNaN)}function N(e){for(e=e.slice(0,8);e.length<8;)e.push(0);return e}const _="sequenceorder";function O(e,t){if(!e){const e=t.find(e=>e.name.toLocaleLowerCase()===_.toLocaleLowerCase());return e?[{fieldName:e.name,sortOrder:"asc"}]:null}return e.split(";").map(e=>{const r=e.trim(),[i,o]=r.split(/\s+/).map(e=>e.trim()),n=t.find(e=>e.name.toLowerCase()===i.toLowerCase());return n?{fieldName:n?n.name:_,sortOrder:"desc"===o?.toLowerCase()?"desc":"asc"}:null}).filter(e=>null!=e)}},33143(e,t,r){r.d(t,{A:()=>u});var i=r(5482),o=r(69540),n=r(25482),s=r(91429),a=r(8631),l=r(29005),p=r(36005),c=r(43937);let u=class extends((0,o.OU)(n.o)){constructor(e){super(e),this.id=null,this.name=null,this.domains=null,this.templates=null}readDomains(e){const t={};for(const r of Object.keys(e))t[r]=(0,a.r)(e[r]);return t}writeDomains(e,t){const r={};for(const t of Object.keys(e))e[t]&&(r[t]=e[t]?.toJSON());t.domains=r}};(0,i.Cg)([(0,s.MZ)({json:{write:!0}})],u.prototype,"id",void 0),(0,i.Cg)([(0,s.MZ)({json:{write:!0}})],u.prototype,"name",void 0),(0,i.Cg)([(0,s.MZ)({json:{write:!0}})],u.prototype,"domains",void 0),(0,i.Cg)([(0,p.w)("domains")],u.prototype,"readDomains",null),(0,i.Cg)([(0,c.K)("domains")],u.prototype,"writeDomains",null),(0,i.Cg)([(0,s.MZ)({type:[l.A],json:{write:!0}})],u.prototype,"templates",void 0),u=(0,i.Cg)([(0,s.$K)("esri.layers.support.FeatureType")],u)},91880(e,t,r){r.d(t,{A:()=>p});var i,o=r(5482),n=r(66552),s=r(25482),a=r(91429);const l=new n.J({asc:"ascending",desc:"descending"});let p=class extends s.o{static{i=this}constructor(e){super(e),this.field=null,this.valueExpression=null,this.order="ascending"}clone(){return new i({field:this.field,valueExpression:this.valueExpression,order:this.order})}};(0,o.Cg)([(0,a.MZ)({type:String,json:{write:!0}})],p.prototype,"field",void 0),(0,o.Cg)([(0,a.MZ)({type:String,json:{write:!0,origins:{"web-scene":{read:!1,write:!1}}}})],p.prototype,"valueExpression",void 0),(0,o.Cg)([(0,a.MZ)({type:l.apiValues,json:{type:l.jsonValues,read:l.read,write:l.write}})],p.prototype,"order",void 0),p=i=(0,o.Cg)([(0,a.$K)("esri.layers.support.OrderByInfo")],p)},73681(e,t,r){r.d(t,{n:()=>l});var i=r(49186),o=r(53966),n=r(46140),s=r(95466),a=r(55674);class l{static async from(e,t,r){const s=e.dictionary_version?n.A.parse(e.dictionary_version):null,c=new Set(e.itemsNames),u={};if(t)for(const e in t)u[e]=t[e];if(e.authoringInfo.configuration)for(const t of e.authoringInfo.configuration)u.hasOwnProperty(t.name)||(u[t.name]=t.value);const d=new Set(e.authoringInfo.symbol);for(const e of Object.keys(r))d.delete(e);d.size&&o.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("missing-fields: fieldMap entries for the following symbol fields are missing",{symbolFields:d});const y=await(0,a.xR)(e.expression,null,u);if(!y)throw new i.A("dictionary-renderer:expression-error","Unable to create dictionary renderer expression");const f=!s||!s.greaterEqual(4,0);f&&o.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("Dictionary script does not support native field types. Applying fallback",{version:s});const h=new p(r,f);return new l(f,c,y,h)}constructor(e,t,r,i){this._requiresFieldCoercionToString=e,this._itemNames=t,this._compiled=r,this._reader=i}get itemNames(){return this._itemNames}evaluate(e,t,r,i){try{return this._reader.bind(e,r,i),this._compiled.evaluate(this._reader,{$view:{scale:t}})}catch(e){o.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("arcade: dictionary script evaluation failed",{error:e})}return null}createDictionaryFieldsIndex(e){if(!this._requiresFieldCoercionToString)return new s.A(e);const t=e.map(e=>({...e,type:"esriFieldTypeString"}));return new s.A(t)}}class p extends a.Gj{constructor(e,t){super(),this._fieldMap=e,this._requiresFieldCoercionToString=t}_getField(e){const t=this._fieldMap[e]??e;return this._boundSchema.fieldsIndex.get(t)}field(e){if(!this._requiresFieldCoercionToString)return super.field(e,!1);const t=this._getField(e);return null==t||null==this._boundTarget.attributes[t.name]?"":""+this._boundTarget.attributes[t.name]}}},58501(e,t,r){r.d(t,{q:()=>o});var i=r(62815);function o(e,t,r){if(!r?.features||!r.hasZ)return;const o=(0,i.N)(r.geometryType,t,e.outSpatialReference);if(o)for(const e of r.features)o(e.geometry)}},22671(e,t,r){r.d(t,{A:()=>v});var i,o=r(5482),n=r(52106),s=r(66552),a=r(25482),l=r(4718),p=r(91429),c=r(16930),u=r(60408),d=r(65864),y=r(50498),f=r(20437),h=r(36005),g=r(43937);const m=new s.J({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh","":null});let v=i=class extends a.o{constructor(e){super(e),this.displayFieldName=null,this.exceededTransferLimit=!1,this.features=[],this.fields=null,this.geometryType=null,this.hasM=!1,this.hasZ=!1,this.queryGeometry=null,this.spatialReference=null}readFeatures(e,t){return this.readFeaturesWithClass(e,t,n.A)}writeGeometryType(e,t,r,i){if(e)return void m.write(e,t,r,i);const{features:o}=this;if(o)for(const e of o)if(null!=e?.geometry)return void m.write(e.geometry.type,t,r,i)}readQueryGeometry(e,t){if(!e)return null;const r=!!e.spatialReference,i=(0,d.rS)(e);return i&&!r&&t.spatialReference&&(i.spatialReference=c.A.fromJSON(t.spatialReference)),i}writeSpatialReference(e,t){if(e)return void(t.spatialReference=e.toJSON());const{features:r}=this;if(r)for(const e of r)if(e&&null!=e.geometry&&e.geometry.spatialReference)return void(t.spatialReference=e.geometry.spatialReference.toJSON())}clone(){return new i(this.cloneProperties())}cloneProperties(){return(0,l.o8)({displayFieldName:this.displayFieldName,exceededTransferLimit:this.exceededTransferLimit,features:this.features,fields:this.fields,geometryType:this.geometryType,hasM:this.hasM,hasZ:this.hasZ,queryGeometry:this.queryGeometry,spatialReference:this.spatialReference,transform:this.transform})}toJSON(e){const t=this.write();if(t.features&&Array.isArray(e)&&e.length>0)for(let r=0;r<t.features.length;r++){const i=t.features[r];if(i.geometry){const t=e?.[r];i.geometry=t?.toJSON()||i.geometry}}return t}quantize(e){const{scale:[t,r],translate:[i,o]}=e,n=this.features,s=this._getQuantizationFunction(this.geometryType,e=>Math.round((e-i)/t),e=>Math.round((o-e)/r));for(let e=0,t=n.length;e<t;e++)s?.(n[e].geometry)||(n.splice(e,1),e--,t--);return this.transform=e,this}unquantize(){const{geometryType:e,features:t,transform:r}=this;if(!r)return this;const{translate:[i,o],scale:[n,s]}=r;let a=null,l=null;if(this.hasZ&&null!=r?.scale?.[2]){const{translate:[,,e],scale:[,,t]}=r;a=r=>r*t+e}if(this.hasM&&null!=r?.scale?.[3]){const{translate:[,,,e],scale:[,,,t]}=r;l=r=>null==r?r:r*t+e}const p=this._getHydrationFunction(e,e=>e*n+i,e=>o-e*s,a,l);for(const{geometry:e}of t)null!=e&&p&&p(e);return this.transform=null,this}readFeaturesWithClass(e,t,r){const i=c.A.fromJSON(t.spatialReference),o=[];for(let t=0;t<e.length;t++){const n=e[t],s=r.fromJSON(n),a=n.geometry?.spatialReference;null==s.geometry||a||(s.geometry.spatialReference=i);const l=n.aggregateGeometries,p=s.aggregateGeometries;if(l&&null!=p)for(const e in p){const t=p[e],r=l[e],o=r?.spatialReference;null==t||o||(t.spatialReference=i)}o.push(s)}return o}_quantizePoints(e,t,r){let i,o;const n=[];for(let s=0,a=e.length;s<a;s++){const a=e[s];if(s>0){const e=t(a[0]),s=r(a[1]);e===i&&s===o||(n.push([e-i,s-o]),i=e,o=s)}else i=t(a[0]),o=r(a[1]),n.push([i,o])}return n.length>0?n:null}_getQuantizationFunction(e,t,r){return"point"===e?e=>(e.x=t(e.x),e.y=r(e.y),e):"polyline"===e||"polygon"===e?e=>{const i=(0,u.Bi)(e)?e.rings:e.paths,o=[];for(let e=0,n=i.length;e<n;e++){const n=i[e],s=this._quantizePoints(n,t,r);s&&o.push(s)}return o.length>0?((0,u.Bi)(e)?e.rings=o:e.paths=o,e):null}:"multipoint"===e?e=>{const i=this._quantizePoints(e.points,t,r);return i&&i.length>0?(e.points=i,e):null}:"extent"===e?e=>e:null}_getHydrationFunction(e,t,r,i,o){return"point"===e?e=>{e.x=t(e.x),e.y=r(e.y),i&&(e.z=i(e.z))}:"polyline"===e||"polygon"===e?e=>{const n=(0,u.Bi)(e)?e.rings:e.paths;let s,a;for(let e=0,i=n.length;e<i;e++){const i=n[e];for(let e=0,o=i.length;e<o;e++){const o=i[e];e>0?(s+=o[0],a+=o[1]):(s=o[0],a=o[1]),o[0]=t(s),o[1]=r(a)}}if(i&&o)for(let e=0,t=n.length;e<t;e++){const t=n[e];for(let e=0,r=t.length;e<r;e++){const r=t[e];r[2]=i(r[2]),r[3]=o(r[3])}}else if(i)for(let e=0,t=n.length;e<t;e++){const t=n[e];for(let e=0,r=t.length;e<r;e++){const r=t[e];r[2]=i(r[2])}}else if(o)for(let e=0,t=n.length;e<t;e++){const t=n[e];for(let e=0,r=t.length;e<r;e++){const r=t[e];r[2]=o(r[2])}}}:"extent"===e?e=>{e.xmin=t(e.xmin),e.ymin=r(e.ymin),e.xmax=t(e.xmax),e.ymax=r(e.ymax),i&&null!=e.zmax&&null!=e.zmin&&(e.zmax=i(e.zmax),e.zmin=i(e.zmin)),o&&null!=e.mmax&&null!=e.mmin&&(e.mmax=o(e.mmax),e.mmin=o(e.mmin))}:"multipoint"===e?e=>{const n=e.points;let s,a;for(let e=0,i=n.length;e<i;e++){const i=n[e];e>0?(s+=i[0],a+=i[1]):(s=i[0],a=i[1]),i[0]=t(s),i[1]=r(a)}if(i&&o)for(let e=0,t=n.length;e<t;e++){const t=n[e];t[2]=i(t[2]),t[3]=o(t[3])}else if(i)for(let e=0,t=n.length;e<t;e++){const t=n[e];t[2]=i(t[2])}else if(o)for(let e=0,t=n.length;e<t;e++){const t=n[e];t[2]=o(t[2])}}:null}};(0,o.Cg)([(0,p.MZ)({type:String,json:{write:!0}})],v.prototype,"displayFieldName",void 0),(0,o.Cg)([(0,p.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],v.prototype,"exceededTransferLimit",void 0),(0,o.Cg)([(0,p.MZ)({type:[n.A],json:{write:!0}})],v.prototype,"features",void 0),(0,o.Cg)([(0,h.w)("features")],v.prototype,"readFeatures",null),(0,o.Cg)([(0,p.MZ)({type:[f.A],json:{write:!0}})],v.prototype,"fields",void 0),(0,o.Cg)([(0,p.MZ)({type:["point","multipoint","polyline","polygon","extent","mesh"],json:{read:{reader:m.read}}})],v.prototype,"geometryType",void 0),(0,o.Cg)([(0,g.K)("geometryType")],v.prototype,"writeGeometryType",null),(0,o.Cg)([(0,p.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],v.prototype,"hasM",void 0),(0,o.Cg)([(0,p.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],v.prototype,"hasZ",void 0),(0,o.Cg)([(0,p.MZ)({types:y.yR,json:{write:!0}})],v.prototype,"queryGeometry",void 0),(0,o.Cg)([(0,h.w)("queryGeometry")],v.prototype,"readQueryGeometry",null),(0,o.Cg)([(0,p.MZ)({type:c.A,json:{write:!0}})],v.prototype,"spatialReference",void 0),(0,o.Cg)([(0,g.K)("spatialReference")],v.prototype,"writeSpatialReference",null),(0,o.Cg)([(0,p.MZ)({json:{write:!0}})],v.prototype,"transform",void 0),v=i=(0,o.Cg)([(0,p.$K)("esri.rest.support.FeatureSet")],v),v.prototype.toJSON.isDefaultToJSON=!0},55674(e,t,r){r.d(t,{Ad:()=>y,Gj:()=>g,QY:()=>d,lL:()=>m,xR:()=>f});var i=r(66131),o=r(49186),n=(r(44208),r(44729)),s=r(15032),a=r(65864),l=r(95466),p=r(43668),c=r(98623);const u=["geometry","scale","timeProperties"];function d(e,t){if(null!=t)for(const r of u)t.hasArcadeDependency(r)&&e.add(r);return e}function y(e,t){return h.create(e,t,null,["$feature","$view"])}function f(e,t,r){return h.create(e,t,r,["$feature","$view","$config"])}class h{static async create(e,t,r,i){const{arcade:n,Dictionary:s}=await(0,p.l)();let a;try{a=n.parseScript(e)}catch(t){throw new o.A("arcade-bad-expression","Failed to parse arcade script",{script:e,error:t})}const l=n.scriptUsesGeometryEngine(a);l&&await n.enableGeometrySupport(),await n.loadDependentModules(new Set,a,null,!1,l);const c={vars:i.reduce((e,t)=>({...e,[t]:null}),{}),spatialReference:t,useAsync:!1},u=n.compileScript(a,c);let d=null;null!=r&&(d=new s(r),d.immutable=!0);const y=new s;return y.immutable=!1,y.setField("scale",0),new h(e,n,a,u,t,y,d,s)}constructor(e,t,r,i,o,n,s,a){this.script=e,this._arcade=t,this._syntaxTree=r,this._compiled=i,this._spatialReference=o,this._viewDict=n,this._configDict=s,this._dictionaryCtor=a,this._dependencies=new Map,this._featureReader=new g,this._dependencies.set("geometry",t.scriptTouchesGeometry(this._syntaxTree)),this._dependencies.set("scale",this._arcade.referencesMember(this._syntaxTree,"scale")),this._dependencies.set("timeProperties",this._arcade.scriptUsesViewProperties(this._syntaxTree,["timeProperties"]))}evaluate(e,t){const r=t.$view?.timeZone;if(t.$view){let e;if(this._viewDict.setField("scale",t.$view.scale),null!=t.$view.timeProperties){const{currentStart:o,currentEnd:n}=t.$view.timeProperties;e=new this._dictionaryCtor({currentStart:null!=o?null!=r?i.lY.epochToArcadeDate(o,r):i.lY.unknownEpochToArcadeDate(o):void 0,currentEnd:null!=n?null!=r?i.lY.epochToArcadeDate(n,r):i.lY.unknownEpochToArcadeDate(n):void 0,startIncluded:!0,endIncluded:!0})}this._viewDict.setField("timeProperties",e)}return this._compiled({vars:{$view:this._viewDict,$config:this._configDict,$feature:e},spatialReference:this._spatialReference,timeZone:r})}repurposeFeature(e,t){return this._featureReader.bind(e,t,this._spatialReference),this._featureReader}references(e){return this._dependencies.get(e)??!1}}class g{constructor(){this._boundTarget=null,this._boundSchema={fields:null,fieldsIndex:null,spatialReference:null,get geometryType(){return null},get objectIdField(){return null}},this.arcadeDeclaredClass="esri.arcade.Feature",this._contextTimeZone=null}bind(e,t,r){const i=t??new l.A(m(e.attributes));this._boundTarget=e,this._boundSchema.fields=i.fields,this._boundSchema.fieldsIndex=i,this._boundSchema.spatialReference=r}_getField(e){return this._boundSchema.fieldsIndex.get(e)}get contextTimeZone(){return this._contextTimeZone}set contextTimeZone(e){this._contextTimeZone=e}readArcadeFeature(){return this}hasField(e){return this._boundSchema.fieldsIndex.has(e)}geometry(){if("fromJSON"in this._boundTarget)return this._boundTarget.geometry;const e=(0,a.rS)(this._boundTarget.geometry);if(e){if(!this._boundSchema.spatialReference)throw new Error("InternalError: Expected spatial reference to be defined");e.spatialReference=this._boundSchema.spatialReference}return e}_hasGeometry(){return null!=this._boundTarget.geometry}isUnknownDateTimeField(e){return this._boundSchema.fieldsIndex.getTimeZone(e)===c.L5}field(e,t=!0){const r=this._getField(e);if(r){const t=this._boundTarget.attributes[r.name];if(null==t)return null;switch(r.type){case"date-only":case"esriFieldTypeDateOnly":return n.n.fromReader(t);case"time-only":case"esriFieldTypeTimeOnly":return s.k.fromReader(t);case"esriFieldTypeTimestampOffset":case"timestamp-offset":return i.lY.fromReaderAsTimeStampOffset(t);case"date":case"esriFieldTypeDate":return this.isUnknownDateTimeField(e)?i.lY.unknownEpochToArcadeDate(t):i.lY.epochToArcadeDate(t,this.contextTimeZone??c.qU);default:return t}}if(t)throw new Error(`Field ${e} does not exist`);return null}setField(e,t){throw new Error("Unable to update feature attribute values, feature is readonly")}keys(){return this._boundSchema.fieldsIndex.fields.map(e=>e.name)}isEmpty(){return this._boundSchema.fields.length<=0&&!this._hasGeometry()}castToText(e=!1){return JSON.stringify(this._boundTarget)}gdbVersion(){return null}fullSchema(){return this._boundSchema}castAsJson(e=null){return{attributes:this._boundTarget.attributes,geometry:!0===e?.keepGeometryType?this.geometry():this.geometry()?.toJSON()??null}}castAsJsonAsync(e=null,t=null){return Promise.resolve(this.castAsJson(t))}}function m(e){const t=[];for(const r in e)t.push({name:r,alias:r,type:"string"==typeof e[r]?"esriFieldTypeString":"esriFieldTypeDouble"});return t}}}]);
|