@arcgis/core 4.32.0-next.20250102 → 4.32.0-next.20250104

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.
Files changed (276) hide show
  1. package/Color.js +1 -1
  2. package/PopupTemplate.js +1 -1
  3. package/arcade/functions/date.js +1 -1
  4. package/arcade/functions/featuresetbase.js +1 -1
  5. package/arcade/functions/featuresetstats.js +1 -1
  6. package/arcade/functions/featuresetstring.js +1 -1
  7. package/arcade/functions/geomasync.js +1 -1
  8. package/arcade/functions/geometry.js +1 -1
  9. package/arcade/functions/geomsync.js +1 -1
  10. package/arcade/functions/knowledgegraph.js +1 -1
  11. package/arcade/functions/string.js +1 -1
  12. package/arcade/geometry/extendedUnitData.js +5 -0
  13. package/arcade/geometry/functions.js +5 -0
  14. package/arcade/geometry/operators.js +5 -0
  15. package/arcade/geometry/unitConversion.js +5 -0
  16. package/arcade/geometry/wkt.js +5 -0
  17. package/arcade/languageUtils.js +1 -1
  18. package/assets/esri/core/workers/RemoteClient.js +1 -1
  19. package/assets/esri/core/workers/chunks/{e371f4f0eb3c22f222df.js → 005727711cca0614c2ab.js} +2 -2
  20. package/assets/esri/core/workers/chunks/{e371f4f0eb3c22f222df.js.LICENSE.txt → 005727711cca0614c2ab.js.LICENSE.txt} +1 -1
  21. package/assets/esri/core/workers/chunks/{2d908c115ea18e813b95.js → 00c0fbe19c12691cf2c3.js} +1 -1
  22. package/assets/esri/core/workers/chunks/08e28328385066c519c2.js +1 -0
  23. package/assets/esri/core/workers/chunks/{0e735d01296d340b393e.js → 0b95ec12218f3c04df18.js} +1 -1
  24. package/assets/esri/core/workers/chunks/{59bf879b4802a5ba431e.js → 0ee669947c23f469e357.js} +1 -1
  25. package/assets/esri/core/workers/chunks/116103ecec27cce47a2f.js +1 -0
  26. package/assets/esri/core/workers/chunks/11f00218905f0db447ff.js +1 -0
  27. package/assets/esri/core/workers/chunks/14b87f3dd9942e6b19d0.js +1 -0
  28. package/assets/esri/core/workers/chunks/16d7c07e1c11b88dae84.js +1 -0
  29. package/assets/esri/core/workers/chunks/1d04fe800cb98e4d6bc4.js +1 -0
  30. package/assets/esri/core/workers/chunks/{71f6e5742cf0c482066b.js → 1dc6b5b177022b80c473.js} +1 -1
  31. package/assets/esri/core/workers/chunks/{59455e2dd44b4c01cc76.js → 2586741c359057b3f626.js} +1 -1
  32. package/assets/esri/core/workers/chunks/{250a810dd4e1ff293564.js → 318a39b56851e707edad.js} +1 -1
  33. package/assets/esri/core/workers/chunks/{648d7d8fa19a2e772c89.js → 3582836342fa78873fe4.js} +1 -1
  34. package/assets/esri/core/workers/chunks/{b1e4813f0c73fc2a483c.js → 370b230fd2d7703d0698.js} +2 -2
  35. package/assets/esri/core/workers/chunks/{b1e4813f0c73fc2a483c.js.LICENSE.txt → 370b230fd2d7703d0698.js.LICENSE.txt} +1 -1
  36. package/assets/esri/core/workers/chunks/{ebf9caf2dc8af89afec2.js → 42aa697b4718b75b8cb2.js} +2 -2
  37. package/assets/esri/core/workers/chunks/{ebf9caf2dc8af89afec2.js.LICENSE.txt → 42aa697b4718b75b8cb2.js.LICENSE.txt} +1 -1
  38. package/assets/esri/core/workers/chunks/44cc3ea8cec8ddd1e3ab.js +1 -0
  39. package/assets/esri/core/workers/chunks/{801dbea20966806db1c9.js → 53cd990b2c988518de6d.js} +1 -1
  40. package/assets/esri/core/workers/chunks/5a1eb0d1e25ff5574c43.js +1 -0
  41. package/assets/esri/core/workers/chunks/6157c49e7431f5868c77.js +1 -0
  42. package/assets/esri/core/workers/chunks/{eef2d94a73064f9bc085.js → 61d64f163840563017d5.js} +1 -1
  43. package/assets/esri/core/workers/chunks/6ed57d01be6bc054c7cd.js +1 -0
  44. package/assets/esri/core/workers/chunks/7254956381e823219db0.js +1 -0
  45. package/assets/esri/core/workers/chunks/740e6bdb3b76f2ea6d61.js +1 -0
  46. package/assets/esri/core/workers/chunks/756c2f7c8659deab6c96.js.LICENSE.txt +1 -1
  47. package/assets/esri/core/workers/chunks/{56fc353421252f2d0a99.js → 75e8ba7e02647b7216ae.js} +1 -1
  48. package/assets/esri/core/workers/chunks/89d7eec47e5b29935d92.js +1 -0
  49. package/assets/esri/core/workers/chunks/8cd2c9ec1e541836b81c.js +1 -0
  50. package/assets/esri/core/workers/chunks/{0b3e1e903120da297641.js → 932375de79e3d33bc4d7.js} +1 -1
  51. package/assets/esri/core/workers/chunks/{263adfd1c2641ef5c0f5.js → 95f23bd17ce9e07fc8ef.js} +1 -1
  52. package/assets/esri/core/workers/chunks/{7de9c01849c4aa1940e7.js → 986889cea53c4a470347.js} +1 -1
  53. package/assets/esri/core/workers/chunks/{cc6160e8ab3cea4040c2.js → 9e9b2fd958e816b1b5f6.js} +1 -1
  54. package/assets/esri/core/workers/chunks/a57cead317eb2fc9afd8.js +1 -0
  55. package/assets/esri/core/workers/chunks/acec58a7f23b2cc938ee.js +1 -0
  56. package/assets/esri/core/workers/chunks/b0f4254d8a32dd713009.js +1 -0
  57. package/assets/esri/core/workers/chunks/b277b8c2f556918e4f9a.js +1 -0
  58. package/assets/esri/core/workers/chunks/{deffd56e39ce725ce377.js → b30046a40bcfbec8abe4.js} +1 -1
  59. package/assets/esri/core/workers/chunks/{5c11e2e65b97565e5003.js → b7db64b07edb0b37ece1.js} +1 -1
  60. package/assets/esri/core/workers/chunks/bd1fb82e8bac439d05ea.js +1 -0
  61. package/assets/esri/core/workers/chunks/bf0a0ca7fdac98f06a89.js.LICENSE.txt +1 -1
  62. package/assets/esri/core/workers/chunks/c44ce0302dc82fb66ada.js +1 -0
  63. package/assets/esri/core/workers/chunks/c52872a50a5989121388.js +1 -0
  64. package/assets/esri/core/workers/chunks/c8cd6ba5600d8ff8db0b.js +2 -0
  65. package/assets/esri/core/workers/chunks/{a100fb789d72410f8d4f.js.LICENSE.txt → c8cd6ba5600d8ff8db0b.js.LICENSE.txt} +1 -1
  66. package/assets/esri/core/workers/chunks/{57c1370b310768c0790a.js → ca1e186f136abb23ae4b.js} +1 -1
  67. package/assets/esri/core/workers/chunks/{d14e4fc82ad772899336.js → ca4a37bdc0f7fb705146.js} +1 -1
  68. package/assets/esri/core/workers/chunks/cb94fc9b0f613ad50b3f.js +1 -0
  69. package/assets/esri/core/workers/chunks/d20764cc99fcabcb7cbf.js +1 -0
  70. package/assets/esri/core/workers/chunks/df18a72e3625cbe31935.js +1 -0
  71. package/assets/esri/core/workers/chunks/eff8fcb6393cd1193cbc.js +1 -0
  72. package/assets/esri/core/workers/chunks/f19d3c855f6e93544918.js +1 -0
  73. package/assets/esri/core/workers/chunks/f4e3db71d1adae717535.js +2 -0
  74. package/assets/esri/core/workers/chunks/{d82b3e2905cab511ff3a.js.LICENSE.txt → f4e3db71d1adae717535.js.LICENSE.txt} +1 -1
  75. package/assets/esri/core/workers/chunks/{60b40b2319d1651dd150.js → f7e50a8284d12da21355.js} +1 -1
  76. package/assets/esri/core/workers/chunks/f9c0d571f62e611ffe2b.js +1 -0
  77. package/assets/esri/core/workers/chunks/fdfe8e0d942b78f08191.js +1 -0
  78. package/assets/esri/core/workers/chunks/ff21207f46a354786eed.js +1 -0
  79. package/assets/esri/libs/parquet/pkg/arcgis_parquet_bg.wasm +0 -0
  80. package/chunks/Bufferer-BiY2mtjI.js +1 -1
  81. package/chunks/Centroid-DZi-eb9F.js +1 -1
  82. package/chunks/Clipper-a9xfvRaw.js +1 -1
  83. package/chunks/CrackAndCluster-CfzXpEle.js +1 -1
  84. package/chunks/Distance2DCalculator-eS0piaux.js +1 -1
  85. package/chunks/GeodeticDistanceCalculator-bNilDneE.js +1 -1
  86. package/chunks/Geometry.js +1 -1
  87. package/chunks/GeometryCleaner-DVgW95-D.js +1 -1
  88. package/chunks/Intersector-K1VmdfQW.js +1 -1
  89. package/chunks/LineSeries.js +1 -1
  90. package/chunks/OperatorClip.js +1 -1
  91. package/chunks/OperatorCrosses.js +1 -1
  92. package/chunks/OperatorCut.js +1 -1
  93. package/chunks/OperatorDensify.js +1 -1
  94. package/chunks/OperatorDifference.js +1 -1
  95. package/chunks/OperatorGeneralize.js +1 -1
  96. package/chunks/OperatorGeodesicBuffer.js +1 -1
  97. package/chunks/OperatorGeodeticArea.js +1 -1
  98. package/chunks/OperatorGeodeticDensifyByLength.js +1 -1
  99. package/chunks/OperatorGeodeticDistance.js +1 -1
  100. package/chunks/OperatorGeodeticLength.js +1 -1
  101. package/chunks/OperatorIntersection.js +1 -1
  102. package/chunks/OperatorIntersects.js +1 -1
  103. package/chunks/OperatorMultiPartToSinglePart.js +1 -1
  104. package/chunks/OperatorOverlaps.js +1 -1
  105. package/chunks/OperatorProject.js +1 -1
  106. package/chunks/OperatorProximity.js +1 -1
  107. package/chunks/OperatorProximityGeodesic.js +1 -1
  108. package/chunks/OperatorShapePreservingDensify.js +1 -1
  109. package/chunks/OperatorShapePreservingLength.js +1 -1
  110. package/chunks/OperatorSimplify.js +1 -1
  111. package/chunks/OperatorTouches.js +1 -1
  112. package/chunks/OperatorUnion.js +1 -1
  113. package/chunks/OperatorWithin.js +1 -1
  114. package/chunks/QuadraticBezier.js +1 -1
  115. package/chunks/SideCalculator2D-Bf4QCxCR.js +1 -1
  116. package/chunks/Theme.js +1 -1
  117. package/chunks/Tick.js +1 -1
  118. package/chunks/Transformation2D.js +1 -1
  119. package/chunks/arcade.js +1 -1
  120. package/chunks/areaOperator.js +5 -0
  121. package/chunks/array.js +1 -1
  122. package/chunks/bufferOperator.js +5 -0
  123. package/chunks/centroidOperator.js +5 -0
  124. package/chunks/chartUtilsAm5.js +1 -1
  125. package/chunks/clipOperator.js +5 -0
  126. package/chunks/containsOperator.js +5 -0
  127. package/chunks/convexHullOperator.js +5 -0
  128. package/chunks/crossesOperator.js +5 -0
  129. package/chunks/cutOperator.js +5 -0
  130. package/chunks/densifyOperator.js +5 -0
  131. package/chunks/differenceOperator.js +5 -0
  132. package/chunks/disjointOperator.js +5 -0
  133. package/chunks/distanceOperator.js +5 -0
  134. package/chunks/equalsOperator.js +5 -0
  135. package/chunks/generalizeOperator.js +5 -0
  136. package/chunks/geodesicBufferOperator.js +5 -0
  137. package/chunks/geodeticAreaOperator.js +5 -0
  138. package/chunks/geodeticDensifyOperator.js +5 -0
  139. package/chunks/geodeticLengthOperator.js +5 -0
  140. package/chunks/i3s.js +1 -1
  141. package/chunks/intersectionOperator.js +5 -0
  142. package/chunks/intersectsOperator.js +5 -0
  143. package/chunks/languageUtils.js +1 -1
  144. package/chunks/lclayout.js +1 -1
  145. package/chunks/lengthOperator.js +5 -0
  146. package/chunks/lyr3DMain.js +1 -1
  147. package/chunks/lyr3DWorker.js +1 -1
  148. package/chunks/offsetOperator.js +5 -0
  149. package/chunks/overlapsOperator.js +5 -0
  150. package/chunks/pe-wasm.js +1 -1
  151. package/chunks/proximityOperator.js +5 -0
  152. package/chunks/relateOperator.js +5 -0
  153. package/chunks/simplifyOperator.js +5 -0
  154. package/chunks/symmetricDifferenceOperator.js +5 -0
  155. package/chunks/touchesOperator.js +5 -0
  156. package/chunks/unionOperator.js +5 -0
  157. package/chunks/vxlLayer.js +1 -1
  158. package/chunks/withinOperator.js +5 -0
  159. package/copyright.txt +2 -2
  160. package/core/Evented.js +1 -1
  161. package/geometry/operators/areaOperator.js +1 -1
  162. package/geometry/operators/bufferOperator.js +1 -1
  163. package/geometry/operators/centroidOperator.js +1 -1
  164. package/geometry/operators/clipOperator.js +1 -1
  165. package/geometry/operators/containsOperator.js +1 -1
  166. package/geometry/operators/convexHullOperator.js +1 -1
  167. package/geometry/operators/crossesOperator.js +1 -1
  168. package/geometry/operators/cutOperator.js +1 -1
  169. package/geometry/operators/densifyOperator.js +1 -1
  170. package/geometry/operators/differenceOperator.js +1 -1
  171. package/geometry/operators/disjointOperator.js +1 -1
  172. package/geometry/operators/distanceOperator.js +1 -1
  173. package/geometry/operators/equalsOperator.js +1 -1
  174. package/geometry/operators/extendOperator.js +1 -1
  175. package/geometry/operators/generalizeOperator.js +1 -1
  176. package/geometry/operators/geodesicBufferOperator.js +1 -1
  177. package/geometry/operators/geodeticAreaOperator.js +1 -1
  178. package/geometry/operators/geodeticDensifyOperator.js +1 -1
  179. package/geometry/operators/geodeticLengthOperator.js +1 -1
  180. package/geometry/operators/gx/operatorAffineTransform.js +1 -1
  181. package/geometry/operators/gx/operatorAlphaShape.js +1 -1
  182. package/geometry/operators/gx/operatorAutoComplete.js +1 -1
  183. package/geometry/operators/gx/operatorBoundary.js +1 -1
  184. package/geometry/operators/gx/operatorBuffer.js +1 -1
  185. package/geometry/operators/gx/operatorConvexHull.js +1 -1
  186. package/geometry/operators/gx/operatorGraphicBuffer.js +1 -1
  187. package/geometry/operators/gx/operatorIntegrate.js +1 -1
  188. package/geometry/operators/gx/operatorLabelPoint.js +1 -1
  189. package/geometry/operators/gx/operatorLinesToPolygons.js +1 -1
  190. package/geometry/operators/gx/operatorLocateBetween.js +1 -1
  191. package/geometry/operators/gx/operatorMinimumBoundingCircle.js +1 -1
  192. package/geometry/operators/gx/operatorOffset.js +1 -1
  193. package/geometry/operators/gx/operatorPolygonOverlay.js +1 -1
  194. package/geometry/operators/gx/operatorPolygonSlicer.js +1 -1
  195. package/geometry/operators/gx/operatorSinglePartToMultiPart.js +1 -1
  196. package/geometry/operators/gx/operatorSymmetricDifference.js +1 -1
  197. package/geometry/operators/intersectionOperator.js +1 -1
  198. package/geometry/operators/intersectsOperator.js +1 -1
  199. package/geometry/operators/isNearOperator.js +1 -1
  200. package/geometry/operators/json/disjointOperator.js +1 -1
  201. package/geometry/operators/lengthOperator.js +1 -1
  202. package/geometry/operators/offsetOperator.js +1 -1
  203. package/geometry/operators/overlapsOperator.js +1 -1
  204. package/geometry/operators/proximityOperator.js +1 -1
  205. package/geometry/operators/relateOperator.js +1 -1
  206. package/geometry/operators/reshapeOperator.js +1 -1
  207. package/geometry/operators/simplifyOperator.js +1 -1
  208. package/geometry/operators/support/apiConverter.js +1 -1
  209. package/geometry/operators/support/jsonConverter.js +1 -1
  210. package/geometry/operators/symmetricDifferenceOperator.js +1 -1
  211. package/geometry/operators/touchesOperator.js +1 -1
  212. package/geometry/operators/unionOperator.js +1 -1
  213. package/geometry/operators/withinOperator.js +1 -1
  214. package/geometry/support/contains.js +1 -1
  215. package/interfaces.d.ts +56 -0
  216. package/kernel.js +1 -1
  217. package/layers/KMLLayer.js +1 -1
  218. package/layers/WCSLayer.js +1 -1
  219. package/layers/graphics/sources/ParquetSource.js +1 -1
  220. package/layers/support/parquetLayerUtils.js +1 -1
  221. package/layers/support/rasterDatasets/WCSRaster.js +1 -1
  222. package/layers/support/rasterFormats/RasterCodec.js +1 -1
  223. package/layers/support/rasterFormats/TiffDecoder.js +1 -1
  224. package/layers/support/wmtsUtils.js +1 -1
  225. package/libs/parquet/parquet.js +1 -1
  226. package/package.json +3 -3
  227. package/smartMapping/renderers/support/utils.js +1 -1
  228. package/smartMapping/symbology/support/Theme.js +1 -1
  229. package/support/revision.js +1 -1
  230. package/views/2d/layers/features/FeatureContainer.js +1 -1
  231. package/views/2d/layers/features/FeaturePipelineWorker.js +1 -1
  232. package/views/2d/layers/features/Processor.js +1 -1
  233. package/views/2d/layers/features/sources/FeatureSource.js +1 -1
  234. package/views/2d/layers/features/sources/strategies/ParquetLoadStrategy.js +1 -1
  235. package/views/2d/layers/features/sources/strategies/chunks/SourceChunkStore.js +1 -1
  236. package/views/3d/interactive/measurementTools/areaMeasurement3D/AreaMeasurement3DView.js +1 -1
  237. package/views/3d/support/DisplayQualityProfile.js +1 -1
  238. package/views/3d/webgl-engine/core/shaderModules/interfaces.js +1 -1
  239. package/views/3d/webgl-engine/lib/Octree.js +1 -1
  240. package/views/SelectionManager.js +1 -1
  241. package/widgets/BatchAttributeForm.js +1 -1
  242. package/widgets/Feature/support/featureUtils.js +1 -1
  243. package/widgets/LayerList/LayerListItem.js +1 -1
  244. package/widgets/LayerList/support/layerListUtils.js +1 -1
  245. package/widgets/Legend/support/heatmapRampUtils.js +1 -1
  246. package/widgets/OrientedImageryViewer/OrientedImageryViewerVisibleElements.js +1 -1
  247. package/widgets/OrientedImageryViewer.js +1 -1
  248. package/widgets/support/widgetUtils.js +1 -1
  249. package/assets/esri/core/workers/chunks/015285436ca965f94e17.js +0 -1
  250. package/assets/esri/core/workers/chunks/048d296efa26ccd79056.js +0 -1
  251. package/assets/esri/core/workers/chunks/0e0b978459d70b15acb5.js +0 -1
  252. package/assets/esri/core/workers/chunks/10fa211987b16fd71a1a.js +0 -1
  253. package/assets/esri/core/workers/chunks/200a5f1864c2c2f7536c.js +0 -1
  254. package/assets/esri/core/workers/chunks/23a697d48f6e45cc033e.js +0 -1
  255. package/assets/esri/core/workers/chunks/29b610ff44708e044cbd.js +0 -1
  256. package/assets/esri/core/workers/chunks/3600125c58d5d04c515a.js +0 -1
  257. package/assets/esri/core/workers/chunks/457d4abc938d14f28e31.js +0 -1
  258. package/assets/esri/core/workers/chunks/4b5dbdcad438cb2dd4bf.js +0 -1
  259. package/assets/esri/core/workers/chunks/69efc716991a407c3d23.js +0 -1
  260. package/assets/esri/core/workers/chunks/6e254e846e284223ef63.js +0 -1
  261. package/assets/esri/core/workers/chunks/785610aa615198fd3815.js +0 -1
  262. package/assets/esri/core/workers/chunks/7bf7aace72f81f5de4e4.js +0 -1
  263. package/assets/esri/core/workers/chunks/7ea3d652536e1d79dfc6.js +0 -1
  264. package/assets/esri/core/workers/chunks/816c9c81352cd0ca8ce8.js +0 -1
  265. package/assets/esri/core/workers/chunks/9291508232b23f030178.js +0 -1
  266. package/assets/esri/core/workers/chunks/9fc49968dea8e2b64f3e.js +0 -1
  267. package/assets/esri/core/workers/chunks/a0b3d70a1b0360084593.js +0 -1
  268. package/assets/esri/core/workers/chunks/a100fb789d72410f8d4f.js +0 -2
  269. package/assets/esri/core/workers/chunks/b4d76d46661aba356ea3.js +0 -1
  270. package/assets/esri/core/workers/chunks/cb3af81e1fe6405c4885.js +0 -1
  271. package/assets/esri/core/workers/chunks/cbf57abb537e86c1dd7f.js +0 -1
  272. package/assets/esri/core/workers/chunks/cebdf2f88c4d2ad8baab.js +0 -1
  273. package/assets/esri/core/workers/chunks/d56d77125798beb7e493.js +0 -1
  274. package/assets/esri/core/workers/chunks/d82b3e2905cab511ff3a.js +0 -2
  275. package/assets/esri/core/workers/chunks/e2f91098793b8742fae6.js +0 -1
  276. package/assets/esri/core/workers/chunks/f25c04cf1a4bc1d2636a.js +0 -1
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{getAssetUrl as e}from"../../assets.js";import t from"../../request.js";let n;const r=new Array(128).fill(void 0);function _(e){return r[e]}r.push(void 0,null,!0,!1);let i=r.length;function o(e){e<132||(r[e]=i,i=e)}function a(e){const t=_(e);return o(e),t}function s(e){i===r.length&&r.push(r.length+1);const t=i;return i=r[t],r[t]=e,t}const d="undefined"!=typeof TextDecoder?new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0}):{decode:()=>{throw Error("TextDecoder not available")}};"undefined"!=typeof TextDecoder&&d.decode();let g=null;function c(){return null!==g&&0!==g.byteLength||(g=new Uint8Array(n.memory.buffer)),g}function u(e,t){return e>>>=0,d.decode(c().subarray(e,e+t))}function l(e,t){return e>>>=0,c().subarray(e/1,e/1+t)}const w="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>{n.__wbindgen_export_1.get(e.dtor)(e.a,e.b)}));function b(e,t,r,_){const i={a:e,b:t,cnt:1,dtor:r},o=(...e)=>{i.cnt++;const t=i.a;i.a=0;try{return _(t,i.b,...e)}finally{0==--i.cnt?(n.__wbindgen_export_1.get(i.dtor)(t,i.b),w.unregister(i)):i.a=t}};return o.original=i,w.register(o,i,i),o}function p(e,t,r){n._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h976f7baa817b77e0(e,t,s(r))}function f(){n.enable_tracing()}let y=0;const h="undefined"!=typeof TextEncoder?new TextEncoder("utf-8"):{encode:()=>{throw Error("TextEncoder not available")}},m="function"==typeof h.encodeInto?function(e,t){return h.encodeInto(e,t)}:function(e,t){const n=h.encode(e);return t.set(n),{read:e.length,written:n.length}};function k(e,t,n){if(void 0===n){const n=h.encode(e),r=t(n.length,1)>>>0;return c().subarray(r,r+n.length).set(n),y=n.length,r}let r=e.length,_=t(r,1)>>>0;const i=c();let o=0;for(;o<r;o++){const t=e.charCodeAt(o);if(t>127)break;i[_+o]=t}if(o!==r){0!==o&&(e=e.slice(o)),_=n(_,r,r=o+3*e.length,1)>>>0;const t=c().subarray(_+o,_+r);o+=m(e,t).written,_=n(_,r,o,1)>>>0}return y=o,_}let I=null;function F(){return(null===I||!0===I.buffer.detached||void 0===I.buffer.detached&&I.buffer!==n.memory.buffer)&&(I=new DataView(n.memory.buffer)),I}function v(e,t){try{return e.apply(this,t)}catch(r){n.__wbindgen_exn_store(s(r))}}function T(e,t,r,_){n.wasm_bindgen__convert__closures__invoke2_mut__h942ec15236fcac1d(e,t,s(r),s(_))}let x=null;function q(){return null!==x&&0!==x.byteLength||(x=new Float64Array(n.memory.buffer)),x}function M(e,t){return e>>>=0,q().subarray(e/8,e/8+t)}let R=null;function z(){return null!==R&&0!==R.byteLength||(R=new Uint32Array(n.memory.buffer)),R}function O(e,t){return e>>>=0,z().subarray(e/4,e/4+t)}function j(e,t){e>>>=0;const n=F(),r=[];for(let _=e;_<e+4*t;_+=4)r.push(a(n.getUint32(_,!0)));return r}let C=null;function A(){return null!==C&&0!==C.byteLength||(C=new Uint16Array(n.memory.buffer)),C}function P(e,t){const n=t(2*e.length,2)>>>0;return A().set(e,n/2),y=e.length,n}function W(e,t,r){const _=k(e,n.__wbindgen_malloc,n.__wbindgen_realloc),i=y;return a(n.readMetadata(_,i,s(t),s(r)))}function S(e,t){const n=t(1*e.length,1)>>>0;return c().set(e,n/1),y=e.length,n}function G(e){const t=S(e,n.__wbindgen_malloc),r=y;return a(n.readMetadataFromFile(t,r))}function E(e,t){if(!(e instanceof t))throw new Error(`expected instance of ${t.name}`);return e.ptr}function B(e){return null==e}function D(e,t,r,_,i){const o=k(e,n.__wbindgen_malloc,n.__wbindgen_realloc),d=y;E(_,Q);var g=_.__destroy_into_raw();let c=0;B(i)||(E(i,K),c=i.__destroy_into_raw());return a(n.readFile(o,d,s(t),s(r),g,c))}function U(e,t){let r=0;B(e)||(E(e,K),r=e.__destroy_into_raw());const _=S(t,n.__wbindgen_malloc),i=y;return a(n.readFileFromBinary(r,_,i))}const L=Object.freeze({Point:0,0:"Point",Polygon:1,1:"Polygon",Polyline:2,2:"Polyline",Multipoint:3,3:"Multipoint"}),V=["esriFieldTypeSmallInteger","esriFieldTypeInteger","esriFieldTypeBigInteger","esriFieldTypeSingle","esriFieldTypeDouble","esriFieldTypeLong","esriFieldTypeString","esriFieldTypeDate","esriFieldTypeOID","esriFieldTypeGeometry","esriFieldTypeBlob","esriFieldTypeRaster","esriFieldTypeGUID","esriFieldTypeGlobalID","esriFieldTypeXML","esriFieldTypeDateOnly","esriFieldTypeTimeOnly","esriFieldTypeTimestampOffset"],X="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>n.__wbg_columndescriptor_free(e>>>0,1)));class Y{static __wrap(e){e>>>=0;const t=Object.create(Y.prototype);return t.__wbg_ptr=e,X.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,X.unregister(this),e}free(){const e=this.__destroy_into_raw();n.__wbg_columndescriptor_free(e,0)}name(){let e,t;try{const i=n.__wbindgen_add_to_stack_pointer(-16);n.columndescriptor_name(i,this.__wbg_ptr);var r=F().getInt32(i+0,!0),_=F().getInt32(i+4,!0);return e=r,t=_,u(r,_)}finally{n.__wbindgen_add_to_stack_pointer(16),n.__wbindgen_free(e,t,1)}}physicalType(){let e,t;try{const i=n.__wbindgen_add_to_stack_pointer(-16);n.columndescriptor_physicalType(i,this.__wbg_ptr);var r=F().getInt32(i+0,!0),_=F().getInt32(i+4,!0);return e=r,t=_,u(r,_)}finally{n.__wbindgen_add_to_stack_pointer(16),n.__wbindgen_free(e,t,1)}}logicalType(){try{const r=n.__wbindgen_add_to_stack_pointer(-16);n.columndescriptor_logicalType(r,this.__wbg_ptr);var e=F().getInt32(r+0,!0),t=F().getInt32(r+4,!0);let _;return 0!==e&&(_=u(e,t).slice(),n.__wbindgen_free(e,1*t,1)),_}finally{n.__wbindgen_add_to_stack_pointer(16)}}encodings(){try{const _=n.__wbindgen_add_to_stack_pointer(-16);n.columndescriptor_encodings(_,this.__wbg_ptr);var e=F().getInt32(_+0,!0),t=F().getInt32(_+4,!0),r=j(e,t).slice();return n.__wbindgen_free(e,4*t,4),r}finally{n.__wbindgen_add_to_stack_pointer(16)}}pageEncodings(){try{const r=n.__wbindgen_add_to_stack_pointer(-16);n.columndescriptor_pageEncodings(r,this.__wbg_ptr);var e=F().getInt32(r+0,!0),t=F().getInt32(r+4,!0);let _;return 0!==e&&(_=j(e,t).slice(),n.__wbindgen_free(e,4*t,4)),_}finally{n.__wbindgen_add_to_stack_pointer(16)}}numValues(){return n.columndescriptor_numValues(this.__wbg_ptr)}compression(){let e,t;try{const i=n.__wbindgen_add_to_stack_pointer(-16);n.columndescriptor_compression(i,this.__wbg_ptr);var r=F().getInt32(i+0,!0),_=F().getInt32(i+4,!0);return e=r,t=_,u(r,_)}finally{n.__wbindgen_add_to_stack_pointer(16),n.__wbindgen_free(e,t,1)}}compressedSize(){return n.columndescriptor_compressedSize(this.__wbg_ptr)}uncompressedSize(){return n.columndescriptor_uncompressedSize(this.__wbg_ptr)}nullCount(){try{const r=n.__wbindgen_add_to_stack_pointer(-16);n.columndescriptor_nullCount(r,this.__wbg_ptr);var e=F().getInt32(r+0,!0),t=F().getBigInt64(r+8,!0);return 0===e?void 0:t}finally{n.__wbindgen_add_to_stack_pointer(16)}}distinctCount(){try{const r=n.__wbindgen_add_to_stack_pointer(-16);n.columndescriptor_distinctCount(r,this.__wbg_ptr);var e=F().getInt32(r+0,!0),t=F().getBigInt64(r+8,!0);return 0===e?void 0:t}finally{n.__wbindgen_add_to_stack_pointer(16)}}minValue(){try{const r=n.__wbindgen_add_to_stack_pointer(-16);n.columndescriptor_minValue(r,this.__wbg_ptr);var e=F().getInt32(r+0,!0),t=F().getInt32(r+4,!0);let _;return 0!==e&&(_=l(e,t).slice(),n.__wbindgen_free(e,1*t,1)),_}finally{n.__wbindgen_add_to_stack_pointer(16)}}maxValue(){try{const r=n.__wbindgen_add_to_stack_pointer(-16);n.columndescriptor_maxValue(r,this.__wbg_ptr);var e=F().getInt32(r+0,!0),t=F().getInt32(r+4,!0);let _;return 0!==e&&(_=l(e,t).slice(),n.__wbindgen_free(e,1*t,1)),_}finally{n.__wbindgen_add_to_stack_pointer(16)}}}const N="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>n.__wbg_fieldmetadata_free(e>>>0,1)));class ${static __wrap(e){e>>>=0;const t=Object.create($.prototype);return t.__wbg_ptr=e,N.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,N.unregister(this),e}free(){const e=this.__destroy_into_raw();n.__wbg_fieldmetadata_free(e,0)}get name(){let e,t;try{const i=n.__wbindgen_add_to_stack_pointer(-16);n.fieldmetadata_name(i,this.__wbg_ptr);var r=F().getInt32(i+0,!0),_=F().getInt32(i+4,!0);return e=r,t=_,u(r,_)}finally{n.__wbindgen_add_to_stack_pointer(16),n.__wbindgen_free(e,t,1)}}get index(){return n.fieldmetadata_index(this.__wbg_ptr)}get type(){const e=n.fieldmetadata_esri_type(this.__wbg_ptr);return V[e]}get physicalType(){try{const r=n.__wbindgen_add_to_stack_pointer(-16);n.fieldmetadata_physical_type(r,this.__wbg_ptr);var e=F().getInt32(r+0,!0),t=F().getInt32(r+4,!0);let _;return 0!==e&&(_=u(e,t).slice(),n.__wbindgen_free(e,1*t,1)),_}finally{n.__wbindgen_add_to_stack_pointer(16)}}get logicalType(){try{const r=n.__wbindgen_add_to_stack_pointer(-16);n.fieldmetadata_logical_type(r,this.__wbg_ptr);var e=F().getInt32(r+0,!0),t=F().getInt32(r+4,!0);let _;return 0!==e&&(_=u(e,t).slice(),n.__wbindgen_free(e,1*t,1)),_}finally{n.__wbindgen_add_to_stack_pointer(16)}}}const J="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>n.__wbg_filemetadata_free(e>>>0,1)));class Q{static __wrap(e){e>>>=0;const t=Object.create(Q.prototype);return t.__wbg_ptr=e,J.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,J.unregister(this),e}free(){const e=this.__destroy_into_raw();n.__wbg_filemetadata_free(e,0)}version(){return n.filemetadata_version(this.__wbg_ptr)}numRows(){return n.filemetadata_numRows(this.__wbg_ptr)>>>0}numFields(){return n.filemetadata_numFields(this.__wbg_ptr)>>>0}createdBy(){try{const r=n.__wbindgen_add_to_stack_pointer(-16);n.filemetadata_createdBy(r,this.__wbg_ptr);var e=F().getInt32(r+0,!0),t=F().getInt32(r+4,!0);let _;return 0!==e&&(_=u(e,t).slice(),n.__wbindgen_free(e,1*t,1)),_}finally{n.__wbindgen_add_to_stack_pointer(16)}}keyValueMetadata(e){try{const _=n.__wbindgen_add_to_stack_pointer(-16),i=k(e,n.__wbindgen_malloc,n.__wbindgen_realloc),o=y;n.filemetadata_keyValueMetadata(_,this.__wbg_ptr,i,o);var t=F().getInt32(_+0,!0),r=F().getInt32(_+4,!0);let a;return 0!==t&&(a=u(t,r).slice(),n.__wbindgen_free(t,1*r,1)),a}finally{n.__wbindgen_add_to_stack_pointer(16)}}keys(){try{const r=n.__wbindgen_add_to_stack_pointer(-16);n.filemetadata_keys(r,this.__wbg_ptr);var e=F().getInt32(r+0,!0),t=F().getInt32(r+4,!0);let _;return 0!==e&&(_=j(e,t).slice(),n.__wbindgen_free(e,4*t,4)),_}finally{n.__wbindgen_add_to_stack_pointer(16)}}getFieldIndex(e){const t=k(e,n.__wbindgen_malloc,n.__wbindgen_realloc),r=y,_=n.filemetadata_getFieldIndex(this.__wbg_ptr,t,r);return 16777215===_?void 0:_}getFieldByIndex(e){const t=n.filemetadata_getFieldByIndex(this.__wbg_ptr,e);return 0===t?void 0:$.__wrap(t)}getFields(){try{const _=n.__wbindgen_add_to_stack_pointer(-16);n.filemetadata_getFields(_,this.__wbg_ptr);var e=F().getInt32(_+0,!0),t=F().getInt32(_+4,!0),r=j(e,t).slice();return n.__wbindgen_free(e,4*t,4),r}finally{n.__wbindgen_add_to_stack_pointer(16)}}}const H="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>n.__wbg_geometryinfodescriptor_free(e>>>0,1)));class K{static __wrap(e){e>>>=0;const t=Object.create(K.prototype);return t.__wbg_ptr=e,H.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,H.unregister(this),e}free(){const e=this.__destroy_into_raw();n.__wbg_geometryinfodescriptor_free(e,0)}get geometryType(){const e=n.__wbg_get_geometryinfodescriptor_geometryType(this.__wbg_ptr);return 4===e?void 0:e}set geometryType(e){n.__wbg_set_geometryinfodescriptor_geometryType(this.__wbg_ptr,B(e)?4:e)}get wkbIndex(){const e=n.__wbg_get_geometryinfodescriptor_wkbIndex(this.__wbg_ptr);return 16777215===e?void 0:e}set wkbIndex(e){n.__wbg_set_geometryinfodescriptor_wkbIndex(this.__wbg_ptr,B(e)?16777215:e)}get lngIndex(){const e=n.__wbg_get_geometryinfodescriptor_lngIndex(this.__wbg_ptr);return 16777215===e?void 0:e}set lngIndex(e){n.__wbg_set_geometryinfodescriptor_lngIndex(this.__wbg_ptr,B(e)?16777215:e)}get latIndex(){const e=n.__wbg_get_geometryinfodescriptor_latIndex(this.__wbg_ptr);return 16777215===e?void 0:e}set latIndex(e){n.__wbg_set_geometryinfodescriptor_latIndex(this.__wbg_ptr,B(e)?16777215:e)}get inWkid(){try{const r=n.__wbindgen_add_to_stack_pointer(-16);n.__wbg_get_geometryinfodescriptor_inWkid(r,this.__wbg_ptr);var e=F().getInt32(r+0,!0),t=F().getInt32(r+4,!0);return 0===e?void 0:t>>>0}finally{n.__wbindgen_add_to_stack_pointer(16)}}set inWkid(e){n.__wbg_set_geometryinfodescriptor_inWkid(this.__wbg_ptr,!B(e),B(e)?0:e)}get outWkid(){try{const r=n.__wbindgen_add_to_stack_pointer(-16);n.__wbg_get_geometryinfodescriptor_outWkid(r,this.__wbg_ptr);var e=F().getInt32(r+0,!0),t=F().getInt32(r+4,!0);return 0===e?void 0:t>>>0}finally{n.__wbindgen_add_to_stack_pointer(16)}}set outWkid(e){n.__wbg_set_geometryinfodescriptor_outWkid(this.__wbg_ptr,!B(e),B(e)?0:e)}static new(){const e=n.geometryinfodescriptor_new();return K.__wrap(e)}}const Z="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>n.__wbg_pageencodingdescriptor_free(e>>>0,1)));class ee{static __wrap(e){e>>>=0;const t=Object.create(ee.prototype);return t.__wbg_ptr=e,Z.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,Z.unregister(this),e}free(){const e=this.__destroy_into_raw();n.__wbg_pageencodingdescriptor_free(e,0)}pageType(){let e,t;try{const i=n.__wbindgen_add_to_stack_pointer(-16);n.pageencodingdescriptor_pageType(i,this.__wbg_ptr);var r=F().getInt32(i+0,!0),_=F().getInt32(i+4,!0);return e=r,t=_,u(r,_)}finally{n.__wbindgen_add_to_stack_pointer(16),n.__wbindgen_free(e,t,1)}}encoding(){let e,t;try{const i=n.__wbindgen_add_to_stack_pointer(-16);n.pageencodingdescriptor_encoding(i,this.__wbg_ptr);var r=F().getInt32(i+0,!0),_=F().getInt32(i+4,!0);return e=r,t=_,u(r,_)}finally{n.__wbindgen_add_to_stack_pointer(16),n.__wbindgen_free(e,t,1)}}count(){return n.pageencodingdescriptor_count(this.__wbg_ptr)}}const te="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>n.__wbg_parquetchunk_free(e>>>0,1)));class ne{static __wrap(e){e>>>=0;const t=Object.create(ne.prototype);return t.__wbg_ptr=e,te.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,te.unregister(this),e}free(){const e=this.__destroy_into_raw();n.__wbg_parquetchunk_free(e,0)}size(){return n.parquetchunk_size(this.__wbg_ptr)>>>0}hasField(e){return 0!==n.parquetchunk_hasField(this.__wbg_ptr,e)}readX(e){return n.parquetchunk_readX(this.__wbg_ptr,e)}readY(e){return n.parquetchunk_readY(this.__wbg_ptr,e)}readCoords(e){try{const _=n.__wbindgen_add_to_stack_pointer(-16);n.parquetchunk_readCoords(_,this.__wbg_ptr,e);var t=F().getInt32(_+0,!0),r=F().getInt32(_+4,!0);let i;return 0!==t&&(i=M(t,r).slice(),n.__wbindgen_free(t,8*r,8)),i}finally{n.__wbindgen_add_to_stack_pointer(16)}}readLengths(e){try{const _=n.__wbindgen_add_to_stack_pointer(-16);n.parquetchunk_readLengths(_,this.__wbg_ptr,e);var t=F().getInt32(_+0,!0),r=F().getInt32(_+4,!0);let i;return 0!==t&&(i=O(t,r).slice(),n.__wbindgen_free(t,4*r,4)),i}finally{n.__wbindgen_add_to_stack_pointer(16)}}readGeometryTransformed(e,t,r,_,i){const o=n.parquetchunk_readGeometryTransformed(this.__wbg_ptr,e,t,r,_,i);return 0===o?void 0:oe.__wrap(o)}boundsXMin(e){return n.parquetchunk_boundsXMin(this.__wbg_ptr,e)}boundsYMin(e){return n.parquetchunk_boundsYMin(this.__wbg_ptr,e)}boundsXMax(e){return n.parquetchunk_boundsXMax(this.__wbg_ptr,e)}boundsYMax(e){return n.parquetchunk_boundsYMax(this.__wbg_ptr,e)}readAttribute(e,t){return a(n.parquetchunk_readAttribute(this.__wbg_ptr,e,t))}}const re="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>n.__wbg_parquetfile_free(e>>>0,1)));let _e=class e{static __wrap(t){t>>>=0;const n=Object.create(e.prototype);return n.__wbg_ptr=t,re.register(n,n.__wbg_ptr,n),n}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,re.unregister(this),e}free(){const e=this.__destroy_into_raw();n.__wbg_parquetfile_free(e,0)}metadata(){const e=n.parquetfile_metadata(this.__wbg_ptr);return Q.__wrap(e)}rowGroups(){try{const _=n.__wbindgen_add_to_stack_pointer(-16);n.parquetfile_rowGroups(_,this.__wbg_ptr);var e=F().getInt32(_+0,!0),t=F().getInt32(_+4,!0),r=j(e,t).slice();return n.__wbindgen_free(e,4*t,4),r}finally{n.__wbindgen_add_to_stack_pointer(16)}}readChunksWithCallback(e,t){const r=P(e,n.__wbindgen_malloc),_=y;return a(n.parquetfile_readChunksWithCallback(this.__wbg_ptr,r,_,s(t)))}readFirstChunk(e){const t=P(e,n.__wbindgen_malloc),r=y;return a(n.parquetfile_readFirstChunk(this.__wbg_ptr,t,r))}readAllChunks(e){const t=P(e,n.__wbindgen_malloc),r=y;return a(n.parquetfile_readAllChunks(this.__wbg_ptr,t,r))}updateChunks(e){const t=P(e,n.__wbindgen_malloc),r=y;return a(n.parquetfile_updateChunks(this.__wbg_ptr,t,r))}};const ie="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>n.__wbg_quantizedgeometry_free(e>>>0,1)));class oe{static __wrap(e){e>>>=0;const t=Object.create(oe.prototype);return t.__wbg_ptr=e,ie.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,ie.unregister(this),e}free(){const e=this.__destroy_into_raw();n.__wbg_quantizedgeometry_free(e,0)}readCoordsUnsafe(){return a(n.quantizedgeometry_readCoordsUnsafe(this.__wbg_ptr))}readLengthsUnsafe(){return a(n.quantizedgeometry_readLengthsUnsafe(this.__wbg_ptr))}}const ae="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>n.__wbg_rangeproviderjs_free(e>>>0,1)));class se{static __wrap(e){e>>>=0;const t=Object.create(se.prototype);return t.__wbg_ptr=e,ae.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,ae.unregister(this),e}free(){const e=this.__destroy_into_raw();n.__wbg_rangeproviderjs_free(e,0)}static new(e,t){const r=n.rangeproviderjs_new(s(e),s(t));return se.__wrap(r)}static withFetch(){const e=n.rangeproviderjs_withFetch();return se.__wrap(e)}}const de="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>n.__wbg_rowgroup_free(e>>>0,1)));class ge{static __wrap(e){e>>>=0;const t=Object.create(ge.prototype);return t.__wbg_ptr=e,de.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,de.unregister(this),e}free(){const e=this.__destroy_into_raw();n.__wbg_rowgroup_free(e,0)}columns(){try{const _=n.__wbindgen_add_to_stack_pointer(-16);n.rowgroup_columns(_,this.__wbg_ptr);var e=F().getInt32(_+0,!0),t=F().getInt32(_+4,!0),r=j(e,t).slice();return n.__wbindgen_free(e,4*t,4),r}finally{n.__wbindgen_add_to_stack_pointer(16)}}}async function ce(e,t){if("function"==typeof Response&&e instanceof Response){if("function"==typeof WebAssembly.instantiateStreaming)try{return await WebAssembly.instantiateStreaming(e,t)}catch(n){if("application/wasm"==e.headers.get("Content-Type"))throw n;console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve Wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",n)}const r=await e.arrayBuffer();return await WebAssembly.instantiate(r,t)}{const n=await WebAssembly.instantiate(e,t);return n instanceof WebAssembly.Instance?{instance:n,module:e}:n}}function ue(){const e={wbg:{}};return e.wbg.__wbg_new_abda76e883ba8a5f=function(){return s(new Error)},e.wbg.__wbg_stack_658279fe44541cf6=function(e,t){const r=k(_(t).stack,n.__wbindgen_malloc,n.__wbindgen_realloc),i=y;F().setInt32(e+4,i,!0),F().setInt32(e+0,r,!0)},e.wbg.__wbg_error_f851667af71bcfc6=function(e,t){let r,_;try{r=e,_=t,console.error(u(e,t))}finally{n.__wbindgen_free(r,_,1)}},e.wbg.__wbindgen_object_drop_ref=function(e){a(e)},e.wbg.__wbindgen_is_function=function(e){return"function"==typeof _(e)},e.wbg.__wbg_self_3093d5d1f7bcb682=function(){return v((function(){return s(self.self)}),arguments)},e.wbg.__wbg_window_3bcfc4d31bc012f8=function(){return v((function(){return s(window.window)}),arguments)},e.wbg.__wbg_globalThis_86b222e13bdf32ed=function(){return v((function(){return s(globalThis.globalThis)}),arguments)},e.wbg.__wbg_global_e5a3fe56f8be9485=function(){return v((function(){return s(global.global)}),arguments)},e.wbg.__wbindgen_is_undefined=function(e){return void 0===_(e)},e.wbg.__wbg_newnoargs_76313bd6ff35d0f2=function(e,t){return s(new Function(u(e,t)))},e.wbg.__wbindgen_object_clone_ref=function(e){return s(_(e))},e.wbg.__wbindgen_number_new=function(e){return s(e)},e.wbg.__wbindgen_string_new=function(e,t){return s(u(e,t))},e.wbg.__wbg_call_1084a111329e68ce=function(){return v((function(e,t){return s(_(e).call(_(t)))}),arguments)},e.wbg.__wbg_call_89af060b4e1523f2=function(){return v((function(e,t,n){return s(_(e).call(_(t),_(n)))}),arguments)},e.wbg.__wbg_call_7de908392845a9a5=function(){return v((function(e,t,n,r,i){return s(_(e).call(_(t),_(n),_(r),_(i)))}),arguments)},e.wbg.__wbg_valueOf_563b3487b1b116aa=function(e){return _(e).valueOf()},e.wbg.__wbg_buffer_b7b08af79b0b0974=function(e){return s(_(e).buffer)},e.wbg.__wbg_new_b85e72ed1bfd57f9=function(e,t){try{var n={a:e,b:t},r=(e,t)=>{const r=n.a;n.a=0;try{return T(r,n.b,e,t)}finally{n.a=r}};return s(new Promise(r))}finally{n.a=n.b=0}},e.wbg.__wbg_resolve_570458cb99d56a43=function(e){return s(Promise.resolve(_(e)))},e.wbg.__wbg_then_95e6edc0f89b73b1=function(e,t){return s(_(e).then(_(t)))},e.wbg.__wbg_then_876bb3c633745cc6=function(e,t,n){return s(_(e).then(_(t),_(n)))},e.wbg.__wbg_newwithbyteoffsetandlength_b5293b0eedbac651=function(e,t,n){return s(new Int16Array(_(e),t>>>0,n>>>0))},e.wbg.__wbg_new_ea1883e1e5e86686=function(e){return s(new Uint8Array(_(e)))},e.wbg.__wbg_newwithbyteoffsetandlength_874df3e29cb555f9=function(e,t,n){return s(new Uint32Array(_(e),t>>>0,n>>>0))},e.wbg.__wbg_length_8339fcf5d8ecd12e=function(e){return _(e).length},e.wbg.__wbg_set_d1e79e2388520f18=function(e,t,n){_(e).set(_(t),n>>>0)},e.wbg.__wbindgen_throw=function(e,t){throw new Error(u(e,t))},e.wbg.__wbindgen_memory=function(){return s(n.memory)},e.wbg.__wbindgen_array_new=function(){return s([])},e.wbg.__wbindgen_array_push=function(e,t){_(e).push(a(t))},e.wbg.__wbindgen_uint8_array_new=function(e,t){var r=l(e,t).slice();n.__wbindgen_free(e,1*t,1);return s(r)},e.wbg.__wbg_queueMicrotask_48421b3cc9052b68=function(e){return s(_(e).queueMicrotask)},e.wbg.__wbindgen_cb_drop=function(e){const t=a(e).original;if(1==t.cnt--)return t.a=0,!0;return!1},e.wbg.__wbg_queueMicrotask_12a30234db4045d3=function(e){queueMicrotask(_(e))},e.wbg.__wbg_parquetchunk_new=function(e){return s(ne.__wrap(e))},e.wbg.__wbg_parquetfile_new=function(e){return s(_e.__wrap(e))},e.wbg.__wbg_filemetadata_new=function(e){return s(Q.__wrap(e))},e.wbg.__wbg_fieldmetadata_new=function(e){return s($.__wrap(e))},e.wbg.__wbg_rowgroup_new=function(e){return s(ge.__wrap(e))},e.wbg.__wbg_columndescriptor_new=function(e){return s(Y.__wrap(e))},e.wbg.__wbg_pageencodingdescriptor_new=function(e){return s(ee.__wrap(e))},e.wbg.__wbindgen_closure_wrapper1461=function(e,t,n){return s(b(e,t,75,p))},e}function le(e,t){return n=e.exports,be.__wbindgen_wasm_module=t,I=null,x=null,C=null,R=null,g=null,n.__wbindgen_start(),n}function we(e){if(void 0!==n)return n;void 0!==e&&(Object.getPrototypeOf(e)===Object.prototype?({module:e}=e):console.warn("using deprecated parameters for `initSync()`; pass a single object instead"));const t=ue();e instanceof WebAssembly.Module||(e=new WebAssembly.Module(e));return le(new WebAssembly.Instance(e,t),e)}async function be(e){if(void 0!==n)return n;void 0!==e&&(Object.getPrototypeOf(e)===Object.prototype?({module_or_path:e}=e):console.warn("using deprecated parameters for the initialization function; pass a single object instead"));const t=ue();("string"==typeof e||"function"==typeof Request&&e instanceof Request||"function"==typeof URL&&e instanceof URL)&&(e=fetch(e));const{instance:r,module:_}=await ce(await e,t);return le(r,_)}const pe=Object.freeze(Object.defineProperty({__proto__:null,ColumnDescriptor:Y,FieldMetadata:$,FileMetadata:Q,GeometryInfoDescriptor:K,GeometryType:L,PageEncodingDescriptor:ee,ParquetChunk:ne,ParquetFile:_e,QuantizedGeometry:oe,RangeProviderJs:se,RowGroup:ge,default:be,enable_tracing:f,initSync:we,readFile:D,readFileFromBinary:U,readMetadata:W,readMetadataFromFile:G},Symbol.toStringTag,{value:"Module"}));let fe=null;async function ye(){return fe||(fe=he()),fe}async function he(){const t=await Promise.resolve().then((()=>pe));return await t.default({module_or_path:e("esri/libs/parquet/pkg/arcgis_parquet_bg.wasm")}),t}const me=e=>async function(n,r,_){const i=e(),{data:o}=await t(n,{responseType:"array-buffer",query:i,headers:{range:`bytes=${r}-${_}`}});return o},ke=e=>async function(n){const r=e(),{data:_}=await t(n,{responseType:"native",method:"head",query:r}),i=_.headers.get("Content-Length");if(null==i)throw new Error("Unable to parse content length");return parseInt(i,10)};class Ie{static async create(e,t){const n=await ye(),r=await n.readMetadata(e,me(t),ke(t));return Ie.fromFileMetadata(r)}static fromFileMetadata(e){const t=[];for(let n=0;n<e.numFields();n++){const r=e.getFieldByIndex(n);t.push({name:r.name,type:r.type,alias:r.name,index:r.index}),r.free()}return new Ie(e,t)}constructor(e,t){this._inner=e,this.fields=t}destroy(){this._inner.free()}[Symbol.dispose](){this.destroy()}get size(){return this._inner.numRows()}getFieldIndex(e){return this._inner.getFieldIndex(e)}tryReadGeoMetadata(){const e=this._inner.keyValueMetadata("geo");return null==e?null:JSON.parse(e)}}function Fe(e){switch(e){case"esriGeometryPoint":return L.Point;case"esriGeometryPolygon":return L.Polygon;case"esriGeometryPolyline":return L.Polyline;case"esriGeometryMultipoint":return L.Multipoint;default:throw new Error(`InternalError: Found unexpected GeometryType: ${e}`)}}function ve(e,t,n){const r=K.new();return r.geometryType=Fe(e.geometryType),"location"===e.type?(r.latIndex=t.getFieldIndex(e.latitudeFieldName),r.lngIndex=t.getFieldIndex(e.longitudeFieldName)):r.wkbIndex=t.getFieldIndex(e.primaryFieldName),r.inWkid=e.spatialReference.wkid,n&&(r.outWkid=n.wkid),r}class Te{static async create(e,t){const n=await ye(),r=me(t.getCustomParameters),_=ke(t.getCustomParameters),i=await W(e,r,_),o=ve(t.geometryInfo,i,t.outSpatialReference),a=await n.readFile(e,r,_,i,o);return new Te(a,Ie.fromFileMetadata(a.metadata()))}static async fromFile(e,t,n){const r=await ye(),_=await r.readMetadataFromFile(e),i=t?ve(t,_,n):void 0,o=await r.readFileFromBinary(i,e);return new Te(o,Ie.fromFileMetadata(o.metadata()))}constructor(e,t){this.inner=e,this.metadata=t}destroy(){this.inner.free(),this.metadata.destroy()}[Symbol.dispose](){this.destroy()}}export{Te as ParquetFile,Ie as ParquetMetadata};
5
+ import{getAssetUrl as t}from"../../assets.js";import e from"../../request.js";let _;const n=new Array(128).fill(void 0);function r(t){return n[t]}n.push(void 0,null,!0,!1);let i=n.length;function o(t){t<132||(n[t]=i,i=t)}function a(t){const e=r(t);return o(t),e}function s(t){i===n.length&&n.push(n.length+1);const e=i;return i=n[e],n[e]=t,e}const g="undefined"!=typeof TextDecoder?new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0}):{decode:()=>{throw Error("TextDecoder not available")}};"undefined"!=typeof TextDecoder&&g.decode();let d=null;function c(){return null!==d&&0!==d.byteLength||(d=new Uint8Array(_.memory.buffer)),d}function w(t,e){return t>>>=0,g.decode(c().subarray(t,t+e))}function l(t,e){return t>>>=0,c().subarray(t/1,t/1+e)}const u="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>{_.__wbindgen_export_1.get(t.dtor)(t.a,t.b)}));function b(t,e,n,r){const i={a:t,b:e,cnt:1,dtor:n},o=(...t)=>{i.cnt++;const e=i.a;i.a=0;try{return r(e,i.b,...t)}finally{0==--i.cnt?(_.__wbindgen_export_1.get(i.dtor)(e,i.b),u.unregister(i)):i.a=e}};return o.original=i,u.register(o,i,i),o}function p(t,e,n){_._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h6f3c6e2a403d1e3d(t,e,s(n))}function f(){_.enable_tracing()}let y=0;const h="undefined"!=typeof TextEncoder?new TextEncoder("utf-8"):{encode:()=>{throw Error("TextEncoder not available")}},m="function"==typeof h.encodeInto?function(t,e){return h.encodeInto(t,e)}:function(t,e){const _=h.encode(t);return e.set(_),{read:t.length,written:_.length}};function I(t,e,_){if(void 0===_){const _=h.encode(t),n=e(_.length,1)>>>0;return c().subarray(n,n+_.length).set(_),y=_.length,n}let n=t.length,r=e(n,1)>>>0;const i=c();let o=0;for(;o<n;o++){const e=t.charCodeAt(o);if(e>127)break;i[r+o]=e}if(o!==n){0!==o&&(t=t.slice(o)),r=_(r,n,n=o+3*t.length,1)>>>0;const e=c().subarray(r+o,r+n);o+=m(t,e).written,r=_(r,n,o,1)>>>0}return y=o,r}let k=null;function F(){return(null===k||!0===k.buffer.detached||void 0===k.buffer.detached&&k.buffer!==_.memory.buffer)&&(k=new DataView(_.memory.buffer)),k}function v(t,e){try{return t.apply(this,e)}catch(n){_.__wbindgen_exn_store(s(n))}}function R(t,e,n,r){_.wasm_bindgen__convert__closures__invoke2_mut__h367b7e3d952c2b06(t,e,s(n),s(r))}let x=null;function z(){return null!==x&&0!==x.byteLength||(x=new Float64Array(_.memory.buffer)),x}function T(t,e){return t>>>=0,z().subarray(t/8,t/8+e)}let P=null;function M(){return null!==P&&0!==P.byteLength||(P=new Uint32Array(_.memory.buffer)),P}function q(t,e){return t>>>=0,M().subarray(t/4,t/4+e)}function O(t,e){t>>>=0;const _=F(),n=[];for(let r=t;r<t+4*e;r+=4)n.push(a(_.getUint32(r,!0)));return n}let j=null;function C(){return null!==j&&0!==j.byteLength||(j=new Uint16Array(_.memory.buffer)),j}function B(t,e){const _=e(2*t.length,2)>>>0;return C().set(t,_/2),y=t.length,_}function A(t,e){const _=e(4*t.length,4)>>>0,n=F();for(let r=0;r<t.length;r++)n.setUint32(_+4*r,s(t[r]),!0);return y=t.length,_}function S(t,e){if(!(t instanceof e))throw new Error(`expected instance of ${e.name}`);return t.ptr}function W(t,e){const _=e(8*t.length,8)>>>0;return z().set(t,_/8),y=t.length,_}function G(t,e){const _=e(4*t.length,4)>>>0;return M().set(t,_/4),y=t.length,_}function E(t){return null==t}function U(t,e){const _=e(1*t.length,1)>>>0;return c().set(t,_/1),y=t.length,_}function D(t,e,n){const r=I(t,_.__wbindgen_malloc,_.__wbindgen_realloc),i=y;return a(_.readMetadata(r,i,s(e),s(n)))}function L(t){const e=U(t,_.__wbindgen_malloc),n=y;return a(_.readMetadataFromFile(e,n))}function V(t,e,n,r,i){const o=I(t,_.__wbindgen_malloc,_.__wbindgen_realloc),g=y;S(r,tt);var d=r.__destroy_into_raw();let c=0;E(i)||(S(i,rt),c=i.__destroy_into_raw());return a(_.readFile(o,g,s(e),s(n),d,c))}function N(t,e){let n=0;E(t)||(S(t,rt),n=t.__destroy_into_raw());const r=U(e,_.__wbindgen_malloc),i=y;return a(_.readFileFromBinary(n,r,i))}const X=Object.freeze({None:0,0:"None",Snappy:1,1:"Snappy"}),Y=Object.freeze({Point:0,0:"Point",Polygon:1,1:"Polygon",Polyline:2,2:"Polyline",Multipoint:3,3:"Multipoint"}),$=["esriFieldTypeSmallInteger","esriFieldTypeInteger","esriFieldTypeBigInteger","esriFieldTypeSingle","esriFieldTypeDouble","esriFieldTypeLong","esriFieldTypeString","esriFieldTypeDate","esriFieldTypeOID","esriFieldTypeGeometry","esriFieldTypeBlob","esriFieldTypeRaster","esriFieldTypeGUID","esriFieldTypeGlobalID","esriFieldTypeXML","esriFieldTypeDateOnly","esriFieldTypeTimeOnly","esriFieldTypeTimestampOffset"],J="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_columndescriptor_free(t>>>0,1)));class K{static __wrap(t){t>>>=0;const e=Object.create(K.prototype);return e.__wbg_ptr=t,J.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,J.unregister(this),t}free(){const t=this.__destroy_into_raw();_.__wbg_columndescriptor_free(t,0)}name(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.columndescriptor_name(i,this.__wbg_ptr);var n=F().getInt32(i+0,!0),r=F().getInt32(i+4,!0);return t=n,e=r,w(n,r)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}physicalType(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.columndescriptor_physicalType(i,this.__wbg_ptr);var n=F().getInt32(i+0,!0),r=F().getInt32(i+4,!0);return t=n,e=r,w(n,r)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}logicalType(){try{const n=_.__wbindgen_add_to_stack_pointer(-16);_.columndescriptor_logicalType(n,this.__wbg_ptr);var t=F().getInt32(n+0,!0),e=F().getInt32(n+4,!0);let r;return 0!==t&&(r=w(t,e).slice(),_.__wbindgen_free(t,1*e,1)),r}finally{_.__wbindgen_add_to_stack_pointer(16)}}encodings(){try{const r=_.__wbindgen_add_to_stack_pointer(-16);_.columndescriptor_encodings(r,this.__wbg_ptr);var t=F().getInt32(r+0,!0),e=F().getInt32(r+4,!0),n=O(t,e).slice();return _.__wbindgen_free(t,4*e,4),n}finally{_.__wbindgen_add_to_stack_pointer(16)}}pageEncodings(){try{const n=_.__wbindgen_add_to_stack_pointer(-16);_.columndescriptor_pageEncodings(n,this.__wbg_ptr);var t=F().getInt32(n+0,!0),e=F().getInt32(n+4,!0);let r;return 0!==t&&(r=O(t,e).slice(),_.__wbindgen_free(t,4*e,4)),r}finally{_.__wbindgen_add_to_stack_pointer(16)}}numValues(){return _.columndescriptor_numValues(this.__wbg_ptr)}compression(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.columndescriptor_compression(i,this.__wbg_ptr);var n=F().getInt32(i+0,!0),r=F().getInt32(i+4,!0);return t=n,e=r,w(n,r)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}compressedSize(){return _.columndescriptor_compressedSize(this.__wbg_ptr)}uncompressedSize(){return _.columndescriptor_uncompressedSize(this.__wbg_ptr)}nullCount(){try{const n=_.__wbindgen_add_to_stack_pointer(-16);_.columndescriptor_nullCount(n,this.__wbg_ptr);var t=F().getInt32(n+0,!0),e=F().getBigInt64(n+8,!0);return 0===t?void 0:e}finally{_.__wbindgen_add_to_stack_pointer(16)}}distinctCount(){try{const n=_.__wbindgen_add_to_stack_pointer(-16);_.columndescriptor_distinctCount(n,this.__wbg_ptr);var t=F().getInt32(n+0,!0),e=F().getBigInt64(n+8,!0);return 0===t?void 0:e}finally{_.__wbindgen_add_to_stack_pointer(16)}}minValue(){try{const n=_.__wbindgen_add_to_stack_pointer(-16);_.columndescriptor_minValue(n,this.__wbg_ptr);var t=F().getInt32(n+0,!0),e=F().getInt32(n+4,!0);let r;return 0!==t&&(r=l(t,e).slice(),_.__wbindgen_free(t,1*e,1)),r}finally{_.__wbindgen_add_to_stack_pointer(16)}}maxValue(){try{const n=_.__wbindgen_add_to_stack_pointer(-16);_.columndescriptor_maxValue(n,this.__wbg_ptr);var t=F().getInt32(n+0,!0),e=F().getInt32(n+4,!0);let r;return 0!==t&&(r=l(t,e).slice(),_.__wbindgen_free(t,1*e,1)),r}finally{_.__wbindgen_add_to_stack_pointer(16)}}}const Q="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_fieldmetadata_free(t>>>0,1)));class H{static __wrap(t){t>>>=0;const e=Object.create(H.prototype);return e.__wbg_ptr=t,Q.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,Q.unregister(this),t}free(){const t=this.__destroy_into_raw();_.__wbg_fieldmetadata_free(t,0)}get name(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.fieldmetadata_name(i,this.__wbg_ptr);var n=F().getInt32(i+0,!0),r=F().getInt32(i+4,!0);return t=n,e=r,w(n,r)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}get index(){return _.fieldmetadata_index(this.__wbg_ptr)}get type(){const t=_.fieldmetadata_esri_type(this.__wbg_ptr);return $[t]}get physicalType(){try{const n=_.__wbindgen_add_to_stack_pointer(-16);_.fieldmetadata_physical_type(n,this.__wbg_ptr);var t=F().getInt32(n+0,!0),e=F().getInt32(n+4,!0);let r;return 0!==t&&(r=w(t,e).slice(),_.__wbindgen_free(t,1*e,1)),r}finally{_.__wbindgen_add_to_stack_pointer(16)}}get logicalType(){try{const n=_.__wbindgen_add_to_stack_pointer(-16);_.fieldmetadata_logical_type(n,this.__wbg_ptr);var t=F().getInt32(n+0,!0),e=F().getInt32(n+4,!0);let r;return 0!==t&&(r=w(t,e).slice(),_.__wbindgen_free(t,1*e,1)),r}finally{_.__wbindgen_add_to_stack_pointer(16)}}}const Z="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_filemetadata_free(t>>>0,1)));class tt{static __wrap(t){t>>>=0;const e=Object.create(tt.prototype);return e.__wbg_ptr=t,Z.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,Z.unregister(this),t}free(){const t=this.__destroy_into_raw();_.__wbg_filemetadata_free(t,0)}version(){return _.filemetadata_version(this.__wbg_ptr)}numRows(){return _.filemetadata_numRows(this.__wbg_ptr)>>>0}numFields(){return _.filemetadata_numFields(this.__wbg_ptr)>>>0}numColumns(){return _.filemetadata_numColumns(this.__wbg_ptr)>>>0}createdBy(){try{const n=_.__wbindgen_add_to_stack_pointer(-16);_.filemetadata_createdBy(n,this.__wbg_ptr);var t=F().getInt32(n+0,!0),e=F().getInt32(n+4,!0);let r;return 0!==t&&(r=w(t,e).slice(),_.__wbindgen_free(t,1*e,1)),r}finally{_.__wbindgen_add_to_stack_pointer(16)}}keyValueMetadata(t){try{const r=_.__wbindgen_add_to_stack_pointer(-16),i=I(t,_.__wbindgen_malloc,_.__wbindgen_realloc),o=y;_.filemetadata_keyValueMetadata(r,this.__wbg_ptr,i,o);var e=F().getInt32(r+0,!0),n=F().getInt32(r+4,!0);let a;return 0!==e&&(a=w(e,n).slice(),_.__wbindgen_free(e,1*n,1)),a}finally{_.__wbindgen_add_to_stack_pointer(16)}}keys(){try{const n=_.__wbindgen_add_to_stack_pointer(-16);_.filemetadata_keys(n,this.__wbg_ptr);var t=F().getInt32(n+0,!0),e=F().getInt32(n+4,!0);let r;return 0!==t&&(r=O(t,e).slice(),_.__wbindgen_free(t,4*e,4)),r}finally{_.__wbindgen_add_to_stack_pointer(16)}}getFieldIndex(t){const e=I(t,_.__wbindgen_malloc,_.__wbindgen_realloc),n=y,r=_.filemetadata_getFieldIndex(this.__wbg_ptr,e,n);return 16777215===r?void 0:r}getFieldByIndex(t){const e=_.filemetadata_getFieldByIndex(this.__wbg_ptr,t);return 0===e?void 0:H.__wrap(e)}getFields(){try{const r=_.__wbindgen_add_to_stack_pointer(-16);_.filemetadata_getFields(r,this.__wbg_ptr);var t=F().getInt32(r+0,!0),e=F().getInt32(r+4,!0),n=O(t,e).slice();return _.__wbindgen_free(t,4*e,4),n}finally{_.__wbindgen_add_to_stack_pointer(16)}}}const et="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_filewriter_free(t>>>0,1)));class _t{static __wrap(t){t>>>=0;const e=Object.create(_t.prototype);return e.__wbg_ptr=t,et.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,et.unregister(this),t}free(){const t=this.__destroy_into_raw();_.__wbg_filewriter_free(t,0)}static new(t,e){const n=A(t,_.__wbindgen_malloc),r=y,i=_.filewriter_new(n,r,e);return _t.__wrap(i)}writeKeyValue(t,e){const n=I(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=y,i=I(e,_.__wbindgen_malloc,_.__wbindgen_realloc),o=y;_.filewriter_writeKeyValue(this.__wbg_ptr,n,r,i,o)}writeI32Page(t,e){try{const i=_.__wbindgen_add_to_stack_pointer(-16);S(e,pt);var n=e.__destroy_into_raw();_.filewriter_writeI32Page(i,this.__wbg_ptr,t,n);var r=F().getInt32(i+0,!0);if(F().getInt32(i+4,!0))throw a(r)}finally{_.__wbindgen_add_to_stack_pointer(16)}}writeI64Page(t,e){try{const i=_.__wbindgen_add_to_stack_pointer(-16);S(e,yt);var n=e.__destroy_into_raw();_.filewriter_writeI64Page(i,this.__wbg_ptr,t,n);var r=F().getInt32(i+0,!0);if(F().getInt32(i+4,!0))throw a(r)}finally{_.__wbindgen_add_to_stack_pointer(16)}}writeF32Page(t,e){try{const i=_.__wbindgen_add_to_stack_pointer(-16);S(e,dt);var n=e.__destroy_into_raw();_.filewriter_writeF32Page(i,this.__wbg_ptr,t,n);var r=F().getInt32(i+0,!0);if(F().getInt32(i+4,!0))throw a(r)}finally{_.__wbindgen_add_to_stack_pointer(16)}}writeF64Page(t,e){try{const i=_.__wbindgen_add_to_stack_pointer(-16);S(e,wt);var n=e.__destroy_into_raw();_.filewriter_writeF64Page(i,this.__wbg_ptr,t,n);var r=F().getInt32(i+0,!0);if(F().getInt32(i+4,!0))throw a(r)}finally{_.__wbindgen_add_to_stack_pointer(16)}}writeGeometryPage(t,e){try{const i=_.__wbindgen_add_to_stack_pointer(-16);S(e,ut);var n=e.__destroy_into_raw();_.filewriter_writeBytesPage(i,this.__wbg_ptr,t,n);var r=F().getInt32(i+0,!0);if(F().getInt32(i+4,!0))throw a(r)}finally{_.__wbindgen_add_to_stack_pointer(16)}}writeStringPage(t,e){try{const i=_.__wbindgen_add_to_stack_pointer(-16);S(e,mt);var n=e.__destroy_into_raw();_.filewriter_writeBytesPage(i,this.__wbg_ptr,t,n);var r=F().getInt32(i+0,!0);if(F().getInt32(i+4,!0))throw a(r)}finally{_.__wbindgen_add_to_stack_pointer(16)}}writeBytesPage(t,e){try{const i=_.__wbindgen_add_to_stack_pointer(-16);S(e,st);var n=e.__destroy_into_raw();_.filewriter_writeBytesPage(i,this.__wbg_ptr,t,n);var r=F().getInt32(i+0,!0);if(F().getInt32(i+4,!0))throw a(r)}finally{_.__wbindgen_add_to_stack_pointer(16)}}finish(){try{const i=this.__destroy_into_raw(),o=_.__wbindgen_add_to_stack_pointer(-16);_.filewriter_finish(o,i);var t=F().getInt32(o+0,!0),e=F().getInt32(o+4,!0),n=F().getInt32(o+8,!0);if(F().getInt32(o+12,!0))throw a(n);var r=l(t,e).slice();return _.__wbindgen_free(t,1*e,1),r}finally{_.__wbindgen_add_to_stack_pointer(16)}}}const nt="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_geometryinfodescriptor_free(t>>>0,1)));class rt{static __wrap(t){t>>>=0;const e=Object.create(rt.prototype);return e.__wbg_ptr=t,nt.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,nt.unregister(this),t}free(){const t=this.__destroy_into_raw();_.__wbg_geometryinfodescriptor_free(t,0)}get geometryType(){const t=_.__wbg_get_geometryinfodescriptor_geometryType(this.__wbg_ptr);return 4===t?void 0:t}set geometryType(t){_.__wbg_set_geometryinfodescriptor_geometryType(this.__wbg_ptr,E(t)?4:t)}get wkbIndex(){const t=_.__wbg_get_geometryinfodescriptor_wkbIndex(this.__wbg_ptr);return 16777215===t?void 0:t}set wkbIndex(t){_.__wbg_set_geometryinfodescriptor_wkbIndex(this.__wbg_ptr,E(t)?16777215:t)}get lngIndex(){const t=_.__wbg_get_geometryinfodescriptor_lngIndex(this.__wbg_ptr);return 16777215===t?void 0:t}set lngIndex(t){_.__wbg_set_geometryinfodescriptor_lngIndex(this.__wbg_ptr,E(t)?16777215:t)}get latIndex(){const t=_.__wbg_get_geometryinfodescriptor_latIndex(this.__wbg_ptr);return 16777215===t?void 0:t}set latIndex(t){_.__wbg_set_geometryinfodescriptor_latIndex(this.__wbg_ptr,E(t)?16777215:t)}get xIndex(){const t=_.__wbg_get_geometryinfodescriptor_xIndex(this.__wbg_ptr);return 16777215===t?void 0:t}set xIndex(t){_.__wbg_set_geometryinfodescriptor_xIndex(this.__wbg_ptr,E(t)?16777215:t)}get inWkid(){try{const n=_.__wbindgen_add_to_stack_pointer(-16);_.__wbg_get_geometryinfodescriptor_inWkid(n,this.__wbg_ptr);var t=F().getInt32(n+0,!0),e=F().getInt32(n+4,!0);return 0===t?void 0:e>>>0}finally{_.__wbindgen_add_to_stack_pointer(16)}}set inWkid(t){_.__wbg_set_geometryinfodescriptor_inWkid(this.__wbg_ptr,!E(t),E(t)?0:t)}get outWkid(){try{const n=_.__wbindgen_add_to_stack_pointer(-16);_.__wbg_get_geometryinfodescriptor_outWkid(n,this.__wbg_ptr);var t=F().getInt32(n+0,!0),e=F().getInt32(n+4,!0);return 0===t?void 0:e>>>0}finally{_.__wbindgen_add_to_stack_pointer(16)}}set outWkid(t){_.__wbg_set_geometryinfodescriptor_outWkid(this.__wbg_ptr,!E(t),E(t)?0:t)}static new(){const t=_.geometryinfodescriptor_new();return rt.__wrap(t)}setMultiscaleInfo(t){S(t,ot);var e=t.__destroy_into_raw();_.geometryinfodescriptor_setMultiscaleInfo(this.__wbg_ptr,e)}}const it="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_multiscaleinfo_free(t>>>0,1)));class ot{static __wrap(t){t>>>=0;const e=Object.create(ot.prototype);return e.__wbg_ptr=t,it.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,it.unregister(this),t}free(){const t=this.__destroy_into_raw();_.__wbg_multiscaleinfo_free(t,0)}static new(){const t=_.multiscaleinfo_new();return ot.__wrap(t)}push(t,e,n,r,i){_.multiscaleinfo_push(this.__wbg_ptr,t,e,n,r,i)}}const at="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_pagebuilderbytes_free(t>>>0,1)));class st{static __wrap(t){t>>>=0;const e=Object.create(st.prototype);return e.__wbg_ptr=t,at.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,at.unregister(this),t}free(){const t=this.__destroy_into_raw();_.__wbg_pagebuilderbytes_free(t,0)}static new(){const t=_.pagebuilderbytes_new();return st.__wrap(t)}push(t){var e=E(t)?0:U(t,_.__wbindgen_malloc),n=y;_.pagebuilderbytes_push(this.__wbg_ptr,e,n)}}const gt="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_pagebuilderf32_free(t>>>0,1)));class dt{static __wrap(t){t>>>=0;const e=Object.create(dt.prototype);return e.__wbg_ptr=t,gt.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,gt.unregister(this),t}free(){const t=this.__destroy_into_raw();_.__wbg_pagebuilderf32_free(t,0)}static new(){const t=_.pagebuilderbytes_new();return dt.__wrap(t)}push(t){_.pagebuilderf32_push(this.__wbg_ptr,!E(t),E(t)?0:t)}}const ct="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_pagebuilderf64_free(t>>>0,1)));class wt{static __wrap(t){t>>>=0;const e=Object.create(wt.prototype);return e.__wbg_ptr=t,ct.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,ct.unregister(this),t}free(){const t=this.__destroy_into_raw();_.__wbg_pagebuilderf64_free(t,0)}static new(){const t=_.multiscaleinfo_new();return wt.__wrap(t)}push(t){_.pagebuilderf64_push(this.__wbg_ptr,!E(t),E(t)?0:t)}}const lt="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_pagebuildergeometry_free(t>>>0,1)));class ut{static __wrap(t){t>>>=0;const e=Object.create(ut.prototype);return e.__wbg_ptr=t,lt.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,lt.unregister(this),t}free(){const t=this.__destroy_into_raw();_.__wbg_pagebuildergeometry_free(t,0)}static new(){const t=_.pagebuilderbytes_new();return ut.__wrap(t)}writeXY(t,e){try{const r=_.__wbindgen_add_to_stack_pointer(-16);_.pagebuildergeometry_writeXY(r,this.__wbg_ptr,t,e);var n=F().getInt32(r+0,!0);if(F().getInt32(r+4,!0))throw a(n)}finally{_.__wbindgen_add_to_stack_pointer(16)}}writePBF(t,e,n,r){try{const o=_.__wbindgen_add_to_stack_pointer(-16),s=W(t,_.__wbindgen_malloc),g=y,d=G(e,_.__wbindgen_malloc),c=y;_.pagebuildergeometry_writePBF(o,this.__wbg_ptr,s,g,d,c,n,r);var i=F().getInt32(o+0,!0);if(F().getInt32(o+4,!0))throw a(i)}finally{_.__wbindgen_add_to_stack_pointer(16)}}writePolygon(t,e){try{const r=_.__wbindgen_add_to_stack_pointer(-16),i=W(t,_.__wbindgen_malloc),o=y,s=G(e,_.__wbindgen_malloc),g=y;_.pagebuildergeometry_writePolygon(r,this.__wbg_ptr,i,o,s,g);var n=F().getInt32(r+0,!0);if(F().getInt32(r+4,!0))throw a(n)}finally{_.__wbindgen_add_to_stack_pointer(16)}}writePolyline(t,e){try{const r=_.__wbindgen_add_to_stack_pointer(-16),i=W(t,_.__wbindgen_malloc),o=y,s=G(e,_.__wbindgen_malloc),g=y;_.pagebuildergeometry_writePolyline(r,this.__wbg_ptr,i,o,s,g);var n=F().getInt32(r+0,!0);if(F().getInt32(r+4,!0))throw a(n)}finally{_.__wbindgen_add_to_stack_pointer(16)}}writeMultipoint(t,e){try{const r=_.__wbindgen_add_to_stack_pointer(-16),i=W(t,_.__wbindgen_malloc),o=y,s=G(e,_.__wbindgen_malloc),g=y;_.pagebuildergeometry_writeMultipoint(r,this.__wbg_ptr,i,o,s,g);var n=F().getInt32(r+0,!0);if(F().getInt32(r+4,!0))throw a(n)}finally{_.__wbindgen_add_to_stack_pointer(16)}}writeNone(){_.pagebuildergeometry_writeNone(this.__wbg_ptr)}}const bt="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_pagebuilderi32_free(t>>>0,1)));class pt{static __wrap(t){t>>>=0;const e=Object.create(pt.prototype);return e.__wbg_ptr=t,bt.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,bt.unregister(this),t}free(){const t=this.__destroy_into_raw();_.__wbg_pagebuilderi32_free(t,0)}static new(){const t=_.pagebuilderbytes_new();return pt.__wrap(t)}push(t){_.pagebuilderi32_push(this.__wbg_ptr,!E(t),E(t)?0:t)}}const ft="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_pagebuilderi64_free(t>>>0,1)));class yt{static __wrap(t){t>>>=0;const e=Object.create(yt.prototype);return e.__wbg_ptr=t,ft.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,ft.unregister(this),t}free(){const t=this.__destroy_into_raw();_.__wbg_pagebuilderi64_free(t,0)}static new(){const t=_.multiscaleinfo_new();return yt.__wrap(t)}push(t){_.pagebuilderi64_push(this.__wbg_ptr,!E(t),E(t)?0:t)}}const ht="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_pagebuilderstring_free(t>>>0,1)));class mt{static __wrap(t){t>>>=0;const e=Object.create(mt.prototype);return e.__wbg_ptr=t,ht.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,ht.unregister(this),t}free(){const t=this.__destroy_into_raw();_.__wbg_pagebuilderstring_free(t,0)}static new(){const t=_.pagebuilderbytes_new();return mt.__wrap(t)}push(t){var e=E(t)?0:I(t,_.__wbindgen_malloc,_.__wbindgen_realloc),n=y;_.pagebuilderstring_push(this.__wbg_ptr,e,n)}}const It="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_pageencodingdescriptor_free(t>>>0,1)));class kt{static __wrap(t){t>>>=0;const e=Object.create(kt.prototype);return e.__wbg_ptr=t,It.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,It.unregister(this),t}free(){const t=this.__destroy_into_raw();_.__wbg_pageencodingdescriptor_free(t,0)}pageType(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.pageencodingdescriptor_pageType(i,this.__wbg_ptr);var n=F().getInt32(i+0,!0),r=F().getInt32(i+4,!0);return t=n,e=r,w(n,r)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}encoding(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.pageencodingdescriptor_encoding(i,this.__wbg_ptr);var n=F().getInt32(i+0,!0),r=F().getInt32(i+4,!0);return t=n,e=r,w(n,r)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}count(){return _.pageencodingdescriptor_count(this.__wbg_ptr)}}const Ft="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_parquetchunk_free(t>>>0,1)));class vt{static __wrap(t){t>>>=0;const e=Object.create(vt.prototype);return e.__wbg_ptr=t,Ft.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,Ft.unregister(this),t}free(){const t=this.__destroy_into_raw();_.__wbg_parquetchunk_free(t,0)}size(){return _.parquetchunk_size(this.__wbg_ptr)>>>0}hasField(t){return 0!==_.parquetchunk_hasField(this.__wbg_ptr,t)}readX(t){return _.parquetchunk_readX(this.__wbg_ptr,t)}readY(t){return _.parquetchunk_readY(this.__wbg_ptr,t)}readCoords(t){try{const r=_.__wbindgen_add_to_stack_pointer(-16);_.parquetchunk_readCoords(r,this.__wbg_ptr,t);var e=F().getInt32(r+0,!0),n=F().getInt32(r+4,!0);let i;return 0!==e&&(i=T(e,n).slice(),_.__wbindgen_free(e,8*n,8)),i}finally{_.__wbindgen_add_to_stack_pointer(16)}}readLengths(t){try{const r=_.__wbindgen_add_to_stack_pointer(-16);_.parquetchunk_readLengths(r,this.__wbg_ptr,t);var e=F().getInt32(r+0,!0),n=F().getInt32(r+4,!0);let i;return 0!==e&&(i=q(e,n).slice(),_.__wbindgen_free(e,4*n,4)),i}finally{_.__wbindgen_add_to_stack_pointer(16)}}readGeometryTransformed(t,e,n,r,i){const o=_.parquetchunk_readGeometryTransformed(this.__wbg_ptr,t,e,n,r,i);return 0===o?void 0:Tt.__wrap(o)}boundsXMin(t){return _.parquetchunk_boundsXMin(this.__wbg_ptr,t)}boundsYMin(t){return _.parquetchunk_boundsYMin(this.__wbg_ptr,t)}boundsXMax(t){return _.parquetchunk_boundsXMax(this.__wbg_ptr,t)}boundsYMax(t){return _.parquetchunk_boundsYMax(this.__wbg_ptr,t)}readAttribute(t,e){return a(_.parquetchunk_readAttribute(this.__wbg_ptr,t,e))}}const Rt="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_parquetfile_free(t>>>0,1)));let xt=class t{static __wrap(e){e>>>=0;const _=Object.create(t.prototype);return _.__wbg_ptr=e,Rt.register(_,_.__wbg_ptr,_),_}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,Rt.unregister(this),t}free(){const t=this.__destroy_into_raw();_.__wbg_parquetfile_free(t,0)}metadata(){const t=_.parquetfile_metadata(this.__wbg_ptr);return tt.__wrap(t)}rowGroups(){try{const r=_.__wbindgen_add_to_stack_pointer(-16);_.parquetfile_rowGroups(r,this.__wbg_ptr);var t=F().getInt32(r+0,!0),e=F().getInt32(r+4,!0),n=O(t,e).slice();return _.__wbindgen_free(t,4*e,4),n}finally{_.__wbindgen_add_to_stack_pointer(16)}}readChunksWithCallback(t,e){const n=B(t,_.__wbindgen_malloc),r=y;return a(_.parquetfile_readChunksWithCallback(this.__wbg_ptr,n,r,s(e)))}readFirstChunk(t){const e=B(t,_.__wbindgen_malloc),n=y;return a(_.parquetfile_readFirstChunk(this.__wbg_ptr,e,n))}readAllChunks(t){const e=B(t,_.__wbindgen_malloc),n=y;return a(_.parquetfile_readAllChunks(this.__wbg_ptr,e,n))}updateChunks(t){const e=B(t,_.__wbindgen_malloc),n=y;return a(_.parquetfile_updateChunks(this.__wbg_ptr,e,n))}};const zt="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_quantizedgeometry_free(t>>>0,1)));class Tt{static __wrap(t){t>>>=0;const e=Object.create(Tt.prototype);return e.__wbg_ptr=t,zt.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,zt.unregister(this),t}free(){const t=this.__destroy_into_raw();_.__wbg_quantizedgeometry_free(t,0)}readCoordsUnsafe(){return a(_.quantizedgeometry_readCoordsUnsafe(this.__wbg_ptr))}readLengthsUnsafe(){return a(_.quantizedgeometry_readLengthsUnsafe(this.__wbg_ptr))}}const Pt="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_rangeproviderjs_free(t>>>0,1)));class Mt{static __wrap(t){t>>>=0;const e=Object.create(Mt.prototype);return e.__wbg_ptr=t,Pt.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,Pt.unregister(this),t}free(){const t=this.__destroy_into_raw();_.__wbg_rangeproviderjs_free(t,0)}static new(t,e){const n=_.rangeproviderjs_new(s(t),s(e));return Mt.__wrap(n)}static withFetch(){const t=_.rangeproviderjs_withFetch();return Mt.__wrap(t)}}const qt="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_rowgroup_free(t>>>0,1)));class Ot{static __wrap(t){t>>>=0;const e=Object.create(Ot.prototype);return e.__wbg_ptr=t,qt.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,qt.unregister(this),t}free(){const t=this.__destroy_into_raw();_.__wbg_rowgroup_free(t,0)}columns(){try{const r=_.__wbindgen_add_to_stack_pointer(-16);_.rowgroup_columns(r,this.__wbg_ptr);var t=F().getInt32(r+0,!0),e=F().getInt32(r+4,!0),n=O(t,e).slice();return _.__wbindgen_free(t,4*e,4),n}finally{_.__wbindgen_add_to_stack_pointer(16)}}}const jt="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_schemafield_free(t>>>0,1)));class Ct{static __wrap(t){t>>>=0;const e=Object.create(Ct.prototype);return e.__wbg_ptr=t,jt.register(e,e.__wbg_ptr,e),e}static __unwrap(t){return t instanceof Ct?t.__destroy_into_raw():0}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,jt.unregister(this),t}free(){const t=this.__destroy_into_raw();_.__wbg_schemafield_free(t,0)}static tryNew(t,e){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=I(t,_.__wbindgen_malloc,_.__wbindgen_realloc),s=y,g=I(e,_.__wbindgen_malloc,_.__wbindgen_realloc),d=y;_.schemafield_tryNew(i,o,s,g,d);var n=F().getInt32(i+0,!0),r=F().getInt32(i+4,!0);if(F().getInt32(i+8,!0))throw a(r);return Ct.__wrap(n)}finally{_.__wbindgen_add_to_stack_pointer(16)}}name(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.schemafield_name(i,this.__wbg_ptr);var n=F().getInt32(i+0,!0),r=F().getInt32(i+4,!0);return t=n,e=r,w(n,r)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}}async function Bt(t,e){if("function"==typeof Response&&t instanceof Response){if("function"==typeof WebAssembly.instantiateStreaming)try{return await WebAssembly.instantiateStreaming(t,e)}catch(_){if("application/wasm"==t.headers.get("Content-Type"))throw _;console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve Wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",_)}const n=await t.arrayBuffer();return await WebAssembly.instantiate(n,e)}{const _=await WebAssembly.instantiate(t,e);return _ instanceof WebAssembly.Instance?{instance:_,module:t}:_}}function At(){const t={wbg:{}};return t.wbg.__wbg_new_abda76e883ba8a5f=function(){return s(new Error)},t.wbg.__wbg_stack_658279fe44541cf6=function(t,e){const n=I(r(e).stack,_.__wbindgen_malloc,_.__wbindgen_realloc),i=y;F().setInt32(t+4,i,!0),F().setInt32(t+0,n,!0)},t.wbg.__wbg_error_f851667af71bcfc6=function(t,e){let n,r;try{n=t,r=e,console.error(w(t,e))}finally{_.__wbindgen_free(n,r,1)}},t.wbg.__wbindgen_object_drop_ref=function(t){a(t)},t.wbg.__wbindgen_is_function=function(t){return"function"==typeof r(t)},t.wbg.__wbg_self_3093d5d1f7bcb682=function(){return v((function(){return s(self.self)}),arguments)},t.wbg.__wbg_window_3bcfc4d31bc012f8=function(){return v((function(){return s(window.window)}),arguments)},t.wbg.__wbg_globalThis_86b222e13bdf32ed=function(){return v((function(){return s(globalThis.globalThis)}),arguments)},t.wbg.__wbg_global_e5a3fe56f8be9485=function(){return v((function(){return s(global.global)}),arguments)},t.wbg.__wbindgen_is_undefined=function(t){return void 0===r(t)},t.wbg.__wbg_newnoargs_76313bd6ff35d0f2=function(t,e){return s(new Function(w(t,e)))},t.wbg.__wbindgen_object_clone_ref=function(t){return s(r(t))},t.wbg.__wbindgen_number_new=function(t){return s(t)},t.wbg.__wbindgen_string_new=function(t,e){return s(w(t,e))},t.wbg.__wbg_call_1084a111329e68ce=function(){return v((function(t,e){return s(r(t).call(r(e)))}),arguments)},t.wbg.__wbg_call_89af060b4e1523f2=function(){return v((function(t,e,_){return s(r(t).call(r(e),r(_)))}),arguments)},t.wbg.__wbg_call_7de908392845a9a5=function(){return v((function(t,e,_,n,i){return s(r(t).call(r(e),r(_),r(n),r(i)))}),arguments)},t.wbg.__wbg_valueOf_563b3487b1b116aa=function(t){return r(t).valueOf()},t.wbg.__wbg_buffer_b7b08af79b0b0974=function(t){return s(r(t).buffer)},t.wbg.__wbg_new_b85e72ed1bfd57f9=function(t,e){try{var _={a:t,b:e},n=(t,e)=>{const n=_.a;_.a=0;try{return R(n,_.b,t,e)}finally{_.a=n}};return s(new Promise(n))}finally{_.a=_.b=0}},t.wbg.__wbg_resolve_570458cb99d56a43=function(t){return s(Promise.resolve(r(t)))},t.wbg.__wbg_then_95e6edc0f89b73b1=function(t,e){return s(r(t).then(r(e)))},t.wbg.__wbg_then_876bb3c633745cc6=function(t,e,_){return s(r(t).then(r(e),r(_)))},t.wbg.__wbg_newwithbyteoffsetandlength_b5293b0eedbac651=function(t,e,_){return s(new Int16Array(r(t),e>>>0,_>>>0))},t.wbg.__wbg_new_ea1883e1e5e86686=function(t){return s(new Uint8Array(r(t)))},t.wbg.__wbg_newwithbyteoffsetandlength_874df3e29cb555f9=function(t,e,_){return s(new Uint32Array(r(t),e>>>0,_>>>0))},t.wbg.__wbg_length_8339fcf5d8ecd12e=function(t){return r(t).length},t.wbg.__wbg_set_d1e79e2388520f18=function(t,e,_){r(t).set(r(e),_>>>0)},t.wbg.__wbindgen_throw=function(t,e){throw new Error(w(t,e))},t.wbg.__wbindgen_memory=function(){return s(_.memory)},t.wbg.__wbindgen_array_new=function(){return s([])},t.wbg.__wbindgen_array_push=function(t,e){r(t).push(a(e))},t.wbg.__wbindgen_uint8_array_new=function(t,e){var n=l(t,e).slice();_.__wbindgen_free(t,1*e,1);return s(n)},t.wbg.__wbg_queueMicrotask_48421b3cc9052b68=function(t){return s(r(t).queueMicrotask)},t.wbg.__wbindgen_cb_drop=function(t){const e=a(t).original;if(1==e.cnt--)return e.a=0,!0;return!1},t.wbg.__wbg_queueMicrotask_12a30234db4045d3=function(t){queueMicrotask(r(t))},t.wbg.__wbg_parquetchunk_new=function(t){return s(vt.__wrap(t))},t.wbg.__wbg_parquetfile_new=function(t){return s(xt.__wrap(t))},t.wbg.__wbg_filemetadata_new=function(t){return s(tt.__wrap(t))},t.wbg.__wbg_fieldmetadata_new=function(t){return s(H.__wrap(t))},t.wbg.__wbg_rowgroup_new=function(t){return s(Ot.__wrap(t))},t.wbg.__wbg_schemafield_unwrap=function(t){return Ct.__unwrap(a(t))},t.wbg.__wbg_columndescriptor_new=function(t){return s(K.__wrap(t))},t.wbg.__wbg_pageencodingdescriptor_new=function(t){return s(kt.__wrap(t))},t.wbg.__wbindgen_closure_wrapper1827=function(t,e,_){return s(b(t,e,163,p))},t}function St(t,e){return _=t.exports,Gt.__wbindgen_wasm_module=e,k=null,x=null,j=null,P=null,d=null,_.__wbindgen_start(),_}function Wt(t){if(void 0!==_)return _;void 0!==t&&(Object.getPrototypeOf(t)===Object.prototype?({module:t}=t):console.warn("using deprecated parameters for `initSync()`; pass a single object instead"));const e=At();t instanceof WebAssembly.Module||(t=new WebAssembly.Module(t));return St(new WebAssembly.Instance(t,e),t)}async function Gt(t){if(void 0!==_)return _;void 0!==t&&(Object.getPrototypeOf(t)===Object.prototype?({module_or_path:t}=t):console.warn("using deprecated parameters for the initialization function; pass a single object instead"));const e=At();("string"==typeof t||"function"==typeof Request&&t instanceof Request||"function"==typeof URL&&t instanceof URL)&&(t=fetch(t));const{instance:n,module:r}=await Bt(await t,e);return St(n,r)}const Et=Object.freeze(Object.defineProperty({__proto__:null,ColumnDescriptor:K,CompressMode:X,FieldMetadata:H,FileMetadata:tt,FileWriter:_t,GeometryInfoDescriptor:rt,GeometryType:Y,MultiScaleInfo:ot,PageBuilderBytes:st,PageBuilderF32:dt,PageBuilderF64:wt,PageBuilderGeometry:ut,PageBuilderI32:pt,PageBuilderI64:yt,PageBuilderString:mt,PageEncodingDescriptor:kt,ParquetChunk:vt,ParquetFile:xt,QuantizedGeometry:Tt,RangeProviderJs:Mt,RowGroup:Ot,SchemaField:Ct,default:Gt,enable_tracing:f,initSync:Wt,readFile:V,readFileFromBinary:N,readMetadata:D,readMetadataFromFile:L},Symbol.toStringTag,{value:"Module"}));let Ut=null;async function Dt(){return Ut||(Ut=Lt()),Ut}async function Lt(){const e=await Promise.resolve().then((()=>Et));return await e.default({module_or_path:t("esri/libs/parquet/pkg/arcgis_parquet_bg.wasm")}),e}const Vt=t=>async function(_,n,r){const i=t(),{data:o}=await e(_,{responseType:"array-buffer",query:i,headers:{range:`bytes=${n}-${r}`}});return o},Nt=t=>async function(_){const n=t(),{data:r}=await e(_,{responseType:"native",method:"head",query:n}),i=r.headers.get("Content-Length");if(null==i)throw new Error("Unable to parse content length");return parseInt(i,10)};class Xt{static async create(t,e){const _=await Dt(),n=await _.readMetadata(t,Vt(e),Nt(e));return Xt.fromFileMetadata(n)}static fromFileMetadata(t){const e=[];for(let _=0;_<t.numFields();_++){const n=t.getFieldByIndex(_);e.push({name:n.name,type:n.type,alias:n.name,index:n.index}),n.free()}return new Xt(t,e)}constructor(t,e){this._inner=t,this.fields=e}destroy(){this._inner.free()}[Symbol.dispose](){this.destroy()}get size(){return this._inner.numRows()}getFieldIndex(t){return this._inner.getFieldIndex(t)}tryReadGeoMetadata(){const t=this._inner.keyValueMetadata("geo");return null==t?null:JSON.parse(t)}tryReadEsriMetadata(){const t=this._inner.keyValueMetadata("esri");return null==t?null:JSON.parse(t)}}function Yt(t){switch(t){case"esriGeometryPoint":return Y.Point;case"esriGeometryPolygon":return Y.Polygon;case"esriGeometryPolyline":return Y.Polyline;case"esriGeometryMultipoint":return Y.Multipoint;default:throw new Error(`InternalError: Found unexpected GeometryType: ${t}`)}}function $t(t,e,_){const n=rt.new();if(n.geometryType=Yt(t.geometryType),"location"===t.type)n.latIndex=e.getFieldIndex(t.latitudeFieldName),n.lngIndex=e.getFieldIndex(t.longitudeFieldName);else{if(null==t.primaryFieldName)throw new Error("InternalError: A primary field name or set of location fields must be defined");if(n.wkbIndex=e.getFieldIndex(t.primaryFieldName),t.multiscale){const _=ot.new();for(const n of t.multiscale.levels){const[t,r]=n.transform.translate,[i,o]=n.transform.scale,a=e.getFieldIndex(n.column);_.push(a,t,r,i,o)}n.setMultiscaleInfo(_)}}return n.inWkid=t.spatialReference.wkid,_&&(n.outWkid=_.wkid),n}class Jt{static async create(t,e){const _=await Dt(),n=Vt(e.getCustomParameters),r=Nt(e.getCustomParameters),i=await D(t,n,r),o=$t(e.geometryInfo,i,e.outSpatialReference),a=await _.readFile(t,n,r,i,o);return new Jt(a,Xt.fromFileMetadata(a.metadata()))}static async fromFile(t,e,_){const n=await Dt(),r=await n.readMetadataFromFile(t),i=e?$t(e,r,_):void 0,o=await n.readFileFromBinary(i,t);return new Jt(o,Xt.fromFileMetadata(o.metadata()))}constructor(t,e){this.inner=t,this.metadata=e}destroy(){this.inner.free(),this.metadata.destroy()}[Symbol.dispose](){this.destroy()}}export{Jt as ParquetFile,Xt as ParquetMetadata};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@arcgis/core",
3
- "version": "4.32.0-next.20250102",
3
+ "version": "4.32.0-next.20250104",
4
4
  "homepage": "https://js.arcgis.com",
5
5
  "description": "ArcGIS Maps SDK for JavaScript: A complete 2D and 3D mapping and data visualization API",
6
6
  "keywords": [
@@ -26,11 +26,11 @@
26
26
  },
27
27
  "dependencies": {
28
28
  "@esri/arcgis-html-sanitizer": "~4.1.0",
29
- "@esri/calcite-components": "~3.0.0-next.82",
29
+ "@esri/calcite-components": "~3.0.0-next.87",
30
30
  "@vaadin/grid": "~24.6.0",
31
31
  "@zip.js/zip.js": "~2.7.54",
32
32
  "luxon": "~3.5.0",
33
- "marked": "~15.0.4",
33
+ "marked": "~15.0.5",
34
34
  "sortablejs": "~1.15.6"
35
35
  },
36
36
  "type": "module"
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import e from"../../../Color.js";import"../../../intl.js";import"../../../symbols.js";import t from"../../../core/Collection.js";import"../../../core/has.js";import n from"../../../core/Error.js";import{convertDateFormatToIntlOptions as o,formatDate as i}from"../../../intl/date.js";import{round as r}from"../../../renderers/support/numberUtils.js";import s from"../../../renderers/support/pointCloud/PointSizeSplatAlgorithm.js";import l from"../../heuristics/outline.js";import a from"../../statistics/classBreaks.js";import m from"../../statistics/summaryStatistics.js";import{getAgeExpressions as u}from"../../statistics/support/ageUtils.js";import{defaultBasemapGroups as c,isAnyDateField as f,defaultStatisticTypes as d,getBasemapId as p,getBasemapGroup as y}from"../../support/utils.js";import w from"../../../symbols/edges/SketchEdges3D.js";import h from"../../../symbols/edges/SolidEdges3D.js";import{getTimeZoneFormattingOptions as b,shortTimeZoneName as g}from"../../../time/timeZoneUtils.js";import{getBackgroundColorTheme as j}from"../../../views/support/colorUtils.js";import D from"../../../symbols/MeshSymbol3D.js";import S from"../../../symbols/FillSymbol3DLayer.js";import v from"../../../symbols/SimpleFillSymbol.js";import x from"../../../symbols/PolygonSymbol3D.js";import z from"../../../symbols/ExtrudeSymbol3DLayer.js";import T from"../../../symbols/SimpleLineSymbol.js";import U from"../../../symbols/LineSymbol3D.js";import L from"../../../symbols/LineSymbol3DLayer.js";import V from"../../../symbols/PathSymbol3DLayer.js";import k from"../../../symbols/SimpleMarkerSymbol.js";import F from"../../../symbols/PointSymbol3D.js";import I from"../../../symbols/IconSymbol3DLayer.js";import M from"../../../symbols/ObjectSymbol3DLayer.js";import{fetchMessageBundle as C}from"../../../intl/messages.js";import{substitute as Z}from"../../../intl/substitute.js";const B=/^(\d+(\.\d+)?)\s*(%)$/i,E=new e([0,0,0,.4]),P=new Set(["hours","minutes","seconds"]),A=[...c.light,...c.dark];function R(e,t,n,r){if("string"==typeof e){const t=n.getField(e);if(t&&f(t))return t.alias||t.name}else if("number"==typeof e||e instanceof Date){const s=null!=t&&P.has(t),l=o(s?"short-date-short-time":"short-date");if(r&&s){const t=n.layer,{timeZone:o}=b("preferredTimeZone"in t?t.preferredTimeZone:null,"datesInUnknownTimezone"in t&&t.datesInUnknownTimezone,r.timeZone,l,"date");return i(e,{...l,timeZone:o,timeZoneName:g})}return i(e,l)}return e}function Y(e,t,n){return e+t>0&&0>e-t&&n<0?0:e}function N(e,t,n,o){const{avg:i,stddev:r,min:s,max:l}=e,a=W(e,!!n,o??!0);let m=a?a[0]:s,u=a?a[1]:l;return a?{minDataValue:m,maxDataValue:u,defaultValuesUsed:!0}:("above"===t?m=Y(i,r,s):"below"===t&&(u=Y(i,r,s)),{minDataValue:m,maxDataValue:u,defaultValuesUsed:!1})}function W(e,t,n){let o,i;const r=$({statistics:e,isDate:t});return r.defaultValuesUsed?(o=r.min,i=r.max):!n||null!=e.avg&&e.stddev||(o=e.min,i=e.max),null!=o&&null!=i?[o,i]:null}function $(e){let t,n,o=e&&e.statistics;if(o||(o={}),null==o.min)if(e.isDate){const e=q();t=e[0],n=e[1]}else t=0,n=100;else if(o.min===o.max)if(e.isDate){const e=q(o.min);t=e[0],n=e[1]}else o.min<0?(t=2*o.min,n=0):o.min>0?(t=0,n=2*o.min):(t=0,n=100);return{min:null!=t?t:o.min,max:null!=n?n:o.max,defaultValuesUsed:null!=t||null!=n}}function q(e){const t=("number"==typeof e?new Date(e):new Date).getUTCFullYear();let n=Date.UTC(t,0,1,12,0,0,0),o=Date.UTC(t,11,31,12,0,0,0);return"number"==typeof e&&(e<n&&(n=e),e>o&&(o=e)),[n,o]}function O({minDataValue:e,maxDataValue:t,defaultValuesUsed:n},o,i,r=!0){return n||"above"===i||"below"===i?H(e,t,5):J(o,r)}function _(e,t){const{avg:n,stddev:o}=e,i=e.min,s=e.max;if(null==n||null==o){const[n,o]=W(e,t,!0);return H(n,o,5)}const l=Y(n,o,i),a=s-l,m=l-i,u=Math.max(a,m);return r([l-u,l-u/2,l,u/2+l,l+u],{strictBounds:!0})}function G(e,t){const{min:n,max:o}=t,[i,s,l,a,m]=e,u=null!=n&&i<n,c=null!=o&&m>o;if(null==n||null==o||!u&&!c)return e;const f=u?n:i,d=c?o:m;return r([f,u?f+(l-f)/2:s,l,c?l+(d-l)/2:a,d],{strictBounds:!0})}function H(e,t,n){const o=(t-e)/(n-1),i=[e];for(let r=1;r<=n-2;r++)i.push(e+r*o);return i.push(t),r(i,{strictBounds:!0})}function J({min:e,max:t,avg:n,stddev:o},i=!0){if(null==e||null==t||null==n||null==o)return[];let s=n-o,l=n+o;s<e&&(s=e),l>t&&(l=t),i&&(n=s+(l-s)/2);let a=r([s,l],{strictBounds:!0});return s=a[0],l=a[1],a=[s,s+(n-s)/2,n,n+(l-n)/2,l],r(a,{strictBounds:!0})}function K(e,t,n){switch(t){case"point":case"multipoint":return n?"noDataSize"in e?e.noDataSize:null:"size"in e?e.size:null;case"polyline":return n?"noDataWidth"in e?e.noDataWidth:null:"width"in e?e.width:null;case"polygon":return"size"in e?e.size:null;default:return}}function Q(e,t,n){switch(t){case"point":case"multipoint":case"polygon":{if(!("outline"in e))return null;const t={color:e.outline.color,width:e.outline.width};if(null!=n&&t.color){const e=t.color.clone();e.a=n,t.color=e}return t}default:return}}function X(e,n){const{type:o,size:i,color:r,outline:s}=n;let l;switch(e){case"point":case"multipoint":if("2d"===o)l=new k({color:r,size:i,outline:{color:s.color,width:s.width}});else if("3d-flat"===o)l=new F({symbolLayers:new t([new I({size:i,resource:{primitive:"circle"},material:{color:r},outline:{color:s.color,size:s.width}})])});else if(o?.includes("3d-volumetric")){const e="3d-volumetric-uniform"===o,s=new M({height:i,resource:{primitive:e?"sphere":"cylinder"},material:{color:r}});e||(s.width=n.widthAndDepth,s.depth=n.widthAndDepth),l=new F({symbolLayers:new t([s])})}break;case"polyline":"2d"===o?l=new T({color:r,width:i}):"3d-flat"===o?l=new U({symbolLayers:new t([new L({size:i,material:{color:r}})])}):"3d-volumetric"===o&&(l=new U({symbolLayers:new t([new V({width:"number"==typeof i?i:parseFloat(i),height:"number"==typeof i?i:parseFloat(i),material:{color:r}})])}));break;case"polygon":"2d"===o?l=new v({color:r,outline:{color:s.color,width:s.width}}):"3d-flat"===o?l=new x({symbolLayers:new t([new S({material:{color:r},outline:{color:s.color,size:s.width}})])}):"3d-volumetric"===o&&(l=new x({symbolLayers:new t([new z({size:i,material:{color:r}})])}));break;case"mesh":{const e=n.meshInfo?.colorMixMode,o=n.meshInfo?.edgesType;l=new D({symbolLayers:new t([new S({material:{color:r,colorMixMode:e||null},edges:"solid"===o?new h({color:E}):"sketch"===o?new w({color:E}):null})])});break}}return l}function ee(e,t,o){const i=te({layer:e,fields:t});if(i.length)return new n(o,"Unknown fields: "+i.join(", ")+". You can only use fields defined in the layer schema");const r=ne({layer:e,fields:t});return r.length?new n(o,"Unsupported fields: "+r.join(", ")+". You can only use fields that are accessible to the renderer i.e. FieldUsageInfo.supportsRenderer must be true"):void 0}function te(e){const t=e.layer;return e.fields.filter((e=>!t.getField(e)))}function ne(e){const t=e.layer;return e.fields.filter((e=>{const n=t.getFieldUsageInfo(e);return!n||!n.supportsRenderer}))}async function oe(e,t){const n={layer:e.layer,view:e.view,filter:e.filter,signal:e.signal},[o,i]=await Promise.all([a(e).catch(ue),t?l(n).catch(ue):null]),r=W({min:o?.minValue,max:o?.maxValue,avg:null,stddev:null},!1,!1);return{result:r?await a({...e,classificationMethod:"equal-interval",numClasses:1,analyzeData:!1,minValue:r[0],maxValue:r[1],normalizationTotal:r[0]+r[1]}):o,defaultValuesUsed:!!r,outlineResult:i}}function ie(e){return m({outStatisticTypes:d,...e})}function re(e,t){let{minSize:n,maxSize:o}=e;if("height"===t){n=((o-n)/2+n)/(2*2.3),o*=2}return{minSize:n,maxSize:o}}function se(e){return B.test(e)}function le(e){if(null==e)return;const t=e.match(B),n=Number(t[1]);return"%"===t[3]?new s({scaleFactor:n/100}):void 0}function ae(e,t,n,o){e.startTime=t instanceof Date?t.getTime():t,e.endTime=n instanceof Date?n.getTime():n,e.units=o,e.field="string"==typeof t?t:"string"==typeof n?n:null}async function me(e,t){let n=null,o=null;if(!e&&!t)return{basemapId:n,basemapTheme:o};if(t&&(o=await j(t),e||(e=t.map?.basemap)),e&&(n=p(e,A,!1),n&&!o)){const e=y(n);null!=e&&(o=e)}return!n&&o&&(n="dark"===o?"dark-gray":"gray"),{basemapId:n,basemapTheme:o}}function ue(e){const t=e.name?.toLowerCase();if(!t||t?.includes(":insufficient-info")||t?.includes(":insufficient-data"))return null;throw e}async function ce(e,t){const{layer:n,startTime:o,endTime:i,view:r}=e,s=u({layer:n,startTime:o,endTime:i,unit:t}).valueExpression,l=await C("esri/smartMapping/t9n/smartMapping");return{valueExpression:s,title:Z(l[`ageInfo_${t}`],{unit:t,startTime:R(o,t,n,r),endTime:R(i,t,n,r)})}}export{G as clampAboveAndBelowStopValues,O as createDataValues,H as createDefaultStopValues,J as createStopValues,_ as createStopValuesForAboveBelow,X as createSymbol,ue as errorCallback,R as formatDate,Y as getBaseValueForAboveBelow,me as getBasemapInfo,oe as getClassBreaks,N as getDataRange,W as getDefaultDataRange,le as getPointSizeAlgorithm,re as getSizeRangeForAxis,ie as getSummaryStatistics,Q as getSymbolOutlineFromScheme,K as getSymbolSizeFromScheme,ce as getTitleAndExpressionForAgeRenderer,se as isValidPointSize,ae as updateAgeRendererAuthoringInfoVV,ee as verifyBasicFieldValidity};
5
+ import e from"../../../Color.js";import"../../../intl.js";import"../../../symbols.js";import t from"../../../core/Collection.js";import"../../../core/has.js";import n from"../../../core/Error.js";import{convertDateFormatToIntlOptions as o,formatDate as i}from"../../../intl/date.js";import{round as r}from"../../../renderers/support/numberUtils.js";import s from"../../../renderers/support/pointCloud/PointSizeSplatAlgorithm.js";import l from"../../heuristics/outline.js";import a from"../../statistics/classBreaks.js";import m from"../../statistics/summaryStatistics.js";import{getAgeExpressions as u}from"../../statistics/support/ageUtils.js";import{defaultBasemapGroups as c,isAnyDateField as f,defaultStatisticTypes as d,getBasemapId as p,getBasemapGroup as y}from"../../support/utils.js";import w from"../../../symbols/edges/SketchEdges3D.js";import h from"../../../symbols/edges/SolidEdges3D.js";import{getTimeZoneFormattingOptions as b,shortTimeZoneName as g}from"../../../time/timeZoneUtils.js";import{getBackgroundColorTheme as j}from"../../../views/support/colorUtils.js";import D from"../../../symbols/MeshSymbol3D.js";import S from"../../../symbols/FillSymbol3DLayer.js";import v from"../../../symbols/SimpleFillSymbol.js";import x from"../../../symbols/PolygonSymbol3D.js";import z from"../../../symbols/ExtrudeSymbol3DLayer.js";import T from"../../../symbols/SimpleLineSymbol.js";import U from"../../../symbols/LineSymbol3D.js";import L from"../../../symbols/LineSymbol3DLayer.js";import V from"../../../symbols/PathSymbol3DLayer.js";import k from"../../../symbols/SimpleMarkerSymbol.js";import F from"../../../symbols/PointSymbol3D.js";import I from"../../../symbols/IconSymbol3DLayer.js";import M from"../../../symbols/ObjectSymbol3DLayer.js";import{fetchMessageBundle as C}from"../../../intl/messages.js";import{substitute as Z}from"../../../intl/substitute.js";const B=/^(\d+(\.\d+)?)\s*(%)$/i,E=new e([0,0,0,.4]),P=new Set(["hours","minutes","seconds"]),A=[...c.light,...c.dark];function R(e,t,n,r){if("string"==typeof e){const t=n.getField(e);if(t&&f(t))return t.alias||t.name}else if("number"==typeof e||e instanceof Date){const s=null!=t&&P.has(t),l=o(s?"short-date-short-time":"short-date");if(r&&s){const t=n.layer,{timeZone:o}=b("preferredTimeZone"in t?t.preferredTimeZone:null,"datesInUnknownTimezone"in t&&t.datesInUnknownTimezone,r.timeZone,l,"date");return i(e,{...l,timeZone:o,timeZoneName:g})}return i(e,l)}return e}function Y(e,t,n){return e+t>0&&0>e-t&&n<0?0:e}function N(e,t,n,o){const{avg:i,stddev:r,min:s,max:l}=e,a=W(e,!!n,o??!0);let m=a?a[0]:s,u=a?a[1]:l;return a?{minDataValue:m,maxDataValue:u,defaultValuesUsed:!0}:("above"===t?m=Y(i,r,s):"below"===t&&(u=Y(i,r,s)),{minDataValue:m,maxDataValue:u,defaultValuesUsed:!1})}function W(e,t,n){let o,i;const r=$({statistics:e,isDate:t});return r.defaultValuesUsed?(o=r.min,i=r.max):!n||null!=e.avg&&e.stddev||(o=e.min,i=e.max),null!=o&&null!=i?[o,i]:null}function $(e){let t,n,o=e.statistics;if(o||(o={}),null==o.min)if(e.isDate){const e=q();t=e[0],n=e[1]}else t=0,n=100;else if(o.min===o.max)if(e.isDate){const e=q(o.min);t=e[0],n=e[1]}else o.min<0?(t=2*o.min,n=0):o.min>0?(t=0,n=2*o.min):(t=0,n=100);return{min:null!=t?t:o.min,max:null!=n?n:o.max,defaultValuesUsed:null!=t||null!=n}}function q(e){const t=("number"==typeof e?new Date(e):new Date).getUTCFullYear();let n=Date.UTC(t,0,1,12,0,0,0),o=Date.UTC(t,11,31,12,0,0,0);return"number"==typeof e&&(e<n&&(n=e),e>o&&(o=e)),[n,o]}function O({minDataValue:e,maxDataValue:t,defaultValuesUsed:n},o,i,r=!0){return n||"above"===i||"below"===i?H(e,t,5):J(o,r)}function _(e,t){const{avg:n,stddev:o}=e,i=e.min,s=e.max;if(null==n||null==o){const[n,o]=W(e,t,!0);return H(n,o,5)}const l=Y(n,o,i),a=s-l,m=l-i,u=Math.max(a,m);return r([l-u,l-u/2,l,u/2+l,l+u],{strictBounds:!0})}function G(e,t){const{min:n,max:o}=t,[i,s,l,a,m]=e,u=null!=n&&i<n,c=null!=o&&m>o;if(null==n||null==o||!u&&!c)return e;const f=u?n:i,d=c?o:m;return r([f,u?f+(l-f)/2:s,l,c?l+(d-l)/2:a,d],{strictBounds:!0})}function H(e,t,n){const o=(t-e)/(n-1),i=[e];for(let r=1;r<=n-2;r++)i.push(e+r*o);return i.push(t),r(i,{strictBounds:!0})}function J({min:e,max:t,avg:n,stddev:o},i=!0){if(null==e||null==t||null==n||null==o)return[];let s=n-o,l=n+o;s<e&&(s=e),l>t&&(l=t),i&&(n=s+(l-s)/2);let a=r([s,l],{strictBounds:!0});return s=a[0],l=a[1],a=[s,s+(n-s)/2,n,n+(l-n)/2,l],r(a,{strictBounds:!0})}function K(e,t,n){switch(t){case"point":case"multipoint":return n?"noDataSize"in e?e.noDataSize:null:"size"in e?e.size:null;case"polyline":return n?"noDataWidth"in e?e.noDataWidth:null:"width"in e?e.width:null;case"polygon":return"size"in e?e.size:null;default:return}}function Q(e,t,n){switch(t){case"point":case"multipoint":case"polygon":{if(!("outline"in e))return null;const t={color:e.outline.color,width:e.outline.width};if(null!=n&&t.color){const e=t.color.clone();e.a=n,t.color=e}return t}default:return}}function X(e,n){const{type:o,size:i,color:r,outline:s}=n;let l;switch(e){case"point":case"multipoint":if("2d"===o)l=new k({color:r,size:i,outline:{color:s.color,width:s.width}});else if("3d-flat"===o)l=new F({symbolLayers:new t([new I({size:i,resource:{primitive:"circle"},material:{color:r},outline:{color:s.color,size:s.width}})])});else if(o?.includes("3d-volumetric")){const e="3d-volumetric-uniform"===o,s=new M({height:i,resource:{primitive:e?"sphere":"cylinder"},material:{color:r}});e||(s.width=n.widthAndDepth,s.depth=n.widthAndDepth),l=new F({symbolLayers:new t([s])})}break;case"polyline":"2d"===o?l=new T({color:r,width:i}):"3d-flat"===o?l=new U({symbolLayers:new t([new L({size:i,material:{color:r}})])}):"3d-volumetric"===o&&(l=new U({symbolLayers:new t([new V({width:"number"==typeof i?i:parseFloat(i),height:"number"==typeof i?i:parseFloat(i),material:{color:r}})])}));break;case"polygon":"2d"===o?l=new v({color:r,outline:{color:s.color,width:s.width}}):"3d-flat"===o?l=new x({symbolLayers:new t([new S({material:{color:r},outline:{color:s.color,size:s.width}})])}):"3d-volumetric"===o&&(l=new x({symbolLayers:new t([new z({size:i,material:{color:r}})])}));break;case"mesh":{const e=n.meshInfo?.colorMixMode,o=n.meshInfo?.edgesType;l=new D({symbolLayers:new t([new S({material:{color:r,colorMixMode:e||null},edges:"solid"===o?new h({color:E}):"sketch"===o?new w({color:E}):null})])});break}}return l}function ee(e,t,o){const i=te({layer:e,fields:t});if(i.length)return new n(o,"Unknown fields: "+i.join(", ")+". You can only use fields defined in the layer schema");const r=ne({layer:e,fields:t});return r.length?new n(o,"Unsupported fields: "+r.join(", ")+". You can only use fields that are accessible to the renderer i.e. FieldUsageInfo.supportsRenderer must be true"):void 0}function te(e){const t=e.layer;return e.fields.filter((e=>!t.getField(e)))}function ne(e){const t=e.layer;return e.fields.filter((e=>{const n=t.getFieldUsageInfo(e);return!n||!n.supportsRenderer}))}async function oe(e,t){const n={layer:e.layer,view:e.view,filter:e.filter,signal:e.signal},[o,i]=await Promise.all([a(e).catch(ue),t?l(n).catch(ue):null]),r=W({min:o?.minValue,max:o?.maxValue,avg:null,stddev:null},!1,!1);return{result:r?await a({...e,classificationMethod:"equal-interval",numClasses:1,analyzeData:!1,minValue:r[0],maxValue:r[1],normalizationTotal:r[0]+r[1]}):o,defaultValuesUsed:!!r,outlineResult:i}}function ie(e){return m({outStatisticTypes:d,...e})}function re(e,t){let{minSize:n,maxSize:o}=e;if("height"===t){n=((o-n)/2+n)/(2*2.3),o*=2}return{minSize:n,maxSize:o}}function se(e){return B.test(e)}function le(e){if(null==e)return;const t=e.match(B),n=Number(t[1]);return"%"===t[3]?new s({scaleFactor:n/100}):void 0}function ae(e,t,n,o){e.startTime=t instanceof Date?t.getTime():t,e.endTime=n instanceof Date?n.getTime():n,e.units=o,e.field="string"==typeof t?t:"string"==typeof n?n:null}async function me(e,t){let n=null,o=null;if(!e&&!t)return{basemapId:n,basemapTheme:o};if(t&&(o=await j(t),e||(e=t.map?.basemap)),e&&(n=p(e,A,!1),n&&!o)){const e=y(n);null!=e&&(o=e)}return!n&&o&&(n="dark"===o?"dark-gray":"gray"),{basemapId:n,basemapTheme:o}}function ue(e){const t=e.name?.toLowerCase();if(!t||t?.includes(":insufficient-info")||t?.includes(":insufficient-data"))return null;throw e}async function ce(e,t){const{layer:n,startTime:o,endTime:i,view:r}=e,s=u({layer:n,startTime:o,endTime:i,unit:t}).valueExpression,l=await C("esri/smartMapping/t9n/smartMapping");return{valueExpression:s,title:Z(l[`ageInfo_${t}`],{unit:t,startTime:R(o,t,n,r),endTime:R(i,t,n,r)})}}export{G as clampAboveAndBelowStopValues,O as createDataValues,H as createDefaultStopValues,J as createStopValues,_ as createStopValuesForAboveBelow,X as createSymbol,ue as errorCallback,R as formatDate,Y as getBaseValueForAboveBelow,me as getBasemapInfo,oe as getClassBreaks,N as getDataRange,W as getDefaultDataRange,le as getPointSizeAlgorithm,re as getSizeRangeForAxis,ie as getSummaryStatistics,Q as getSymbolOutlineFromScheme,K as getSymbolSizeFromScheme,ce as getTitleAndExpressionForAgeRenderer,se as isValidPointSize,ae as updateAgeRendererAuthoringInfoVV,ee as verifyBasicFieldValidity};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{clone as s}from"../../../core/lang.js";import{defaultBasemapGroups as e,getBasemapId as t,getBasemapGroup as a}from"../../support/utils.js";function p(s,e,p){let m=null,o=null;if(e&&(m=t(e,s,!1),m)){const s=a(m);null!=s&&(o=s)}return!m&&p&&(m="dark"===p?"dark-gray":"gray",o=p),m||o||(m="gray",o="light"),{basemapId:m,basemapTheme:o}}class m{constructor(s){const{name:t,label:a,description:p,schemes:m}=s;this.name=t,this.label=a,this.description=p,this.schemes=m;const o=s.basemapGroups||e;let r=[];o&&Object.keys(o).forEach((s=>{r=r.concat(o[s])})),this.supportedBasemaps=r,this.basemapGroups=o}isBasemapSupported(s){const e=t(s,this.supportedBasemaps);return!(!e||!this.supportedBasemaps.includes(e))}getRawSchemes(e){const{basemapId:t,basemapTheme:m}=p(this.supportedBasemaps,e.basemap,e.basemapTheme);let o=m;if(t){const s=a(t,this.basemapGroups);null!=s&&(o=s)}let r=e.geometryType;"multipoint"===r?r="point":"mesh"===r&&(r="polygon");const i=this.schemes[r]||this.schemes.default;return{schemesInfo:s(i[o]),basemapId:t,basemapTheme:m}}}export{m as default};
5
+ import{clone as s}from"../../../core/lang.js";import{defaultBasemapGroups as e,getBasemapId as t,getBasemapGroup as a}from"../../support/utils.js";function p(s,e,p){let m=null,o=null;if(e&&(m=t(e,s,!1),m)){const s=a(m);null!=s&&(o=s)}return!m&&p&&(m="dark"===p?"dark-gray":"gray",o=p),m||o||(m="gray",o="light"),{basemapId:m,basemapTheme:o}}class m{constructor(s){const{name:t,label:a,description:p,schemes:m}=s;this.name=t,this.label=a,this.description=p,this.schemes=m;const o=s.basemapGroups||e;let r=[];Object.keys(o).forEach((s=>{r=r.concat(o[s])})),this.supportedBasemaps=r,this.basemapGroups=o}isBasemapSupported(s){const e=t(s,this.supportedBasemaps);return!(!e||!this.supportedBasemaps.includes(e))}getRawSchemes(e){const{basemapId:t,basemapTheme:m}=p(this.supportedBasemaps,e.basemap,e.basemapTheme);let o=m;if(t){const s=a(t,this.basemapGroups);null!=s&&(o=s)}let r=e.geometryType;"multipoint"===r?r="point":"mesh"===r&&(r="polygon");const i=this.schemes[r]||this.schemes.default;return{schemesInfo:s(i[o]),basemapId:t,basemapTheme:m}}}export{m as default};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- const a="20250102",b="b6ca44001df4b6a844af4b1710eac365a5b450e7";export{a as buildDate,b as commitHash};
5
+ const b="20250104",c="2ba12bd5f0eb40cb900c28ed37dc2a34f6ba6b93";export{b as buildDate,c as commitHash};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import has from"../../../../core/has.js";import{throwIfAborted as e,createResolver as t}from"../../../../core/promiseUtils.js";import{UpdatingHandles as s}from"../../../../core/support/UpdatingHandles.js";import{AFeatureContainer as r}from"../../engine/AFeatureContainer.js";import{WGLDrawPhase as i,FeatureSelection as n,FeatureBatchingStrategy as a}from"../../engine/webgl/enums.js";import o from"../../engine/webgl/shaderGraph/techniques/FeatureInstanceStore.js";import{Techniques as h}from"../../engine/webgl/shaderGraph/techniques/TechniqueRegistry.js";import{TechniqueType as d}from"../../engine/webgl/shaderGraph/techniques/TechniqueType.js";import{RenderState as l}from"./RenderState.js";import{renderHighlight as u}from"../support/util.js";class c{constructor(e,s){this.id=e,this.version=s,this._resolver=t(),this._done=!1}get done(){return this._done}get promise(){return this._resolver.promise}end(){this._resolver.resolve(),this._done=!0}destroy(){this._resolver.reject()}}class p extends r{constructor(e){super(e.view.featuresTilingScheme),this.updatingHandles=new s,this._hitTestsRequests=[],this._store=new o,this._visibleTiles=new Set,this._subscriptions=new Map,this._updateStatisticsRequests=[],this._lockStatisticUpdates=!1,this._layerView=e,this.addTransitionable(this._layerView.featureEffectView)}renderChildren(e){if(this._updateAttributeView(),this._renderState?.update(this.attributeView.currentEpoch),this._renderState){const e=Array.from(this._renderState.tiles()).filter((e=>e.needsUpload));if(e.length){e[Math.floor(Math.random()*e.length)].upload(),e.length>=2&&this.requestRender()}for(const t of this._renderState.tiles())t.tryReady(this.attributeView.currentEpoch)&&(this._subscriptions.get(t.key.id)?.end(),this._layerView.requestUpdate(),this.hasLabels&&this._layerView.view.labelManager.requestUpdate(),this.requestRender())}for(const t of this.children)t.setTransform(e.state);switch(super.renderChildren(e),e.drawPhase){case i.MAP:return this._renderMapPhase(e);case i.HIGHLIGHT:return this._renderHighlightPhase(e);case i.LABEL:return this._renderLabelPhase(e)}}subscriptions(){return this._subscriptions.values()}get _instanceStore(){return this._store}get instanceStore(){return this._store}get layerView(){return this._layerView}get hasLabels(){return this._layerView.labelingCollisionInfos.length>0}get hasHighlight(){return this._layerView.hasHighlight()}get _layer(){return this._layerView.layer}_getHeatmapInstance(e){if(null==this._instanceStore||!(e.drawPhase&h.heatmap.drawPhase))return null;for(const t of this._instanceStore.values())if(_(t))return t;return null}get children(){return this._renderState?Array.from(this._renderState.tiles()).filter((e=>this._visibleTiles.has(e.key.id))):[]}updateAttributeView(e){this.requestRender(),this.attributeView.requestUpdate(e),this.hasLabels&&this._layerView.view.labelManager.requestUpdate()}updateSubscriptions(e){for(const{tileId:t,version:s}of e.subscribe)if(this._subscriptions.has(t))this._subscriptions.get(t).version=s;else{const e=new c(t,s);this._subscriptions.set(t,e),this.updatingHandles.addPromise(e.promise)}for(const t of e.unsubscribe){const e=this._subscriptions.get(t);e?.destroy(),this._subscriptions.delete(t),this.removeTile(t)}}isDone(e){return!!this._renderState&&this._renderState.isTileDone(e)}async updateRenderState(e){has("esri-2d-update-debug")&&console.debug(`Version[${e}] FeatureContainer.updateRenderState`),this._renderStateNext=new l((()=>this._stage),(e=>this._subscriptions.get(e)?.version),e,this.tileInfoView)}getDisplayStatistics(e,t){const s=this._statisticsByLevel.get(e);return s?s.get(t):null}updateStatistics(e,t){if(this._lockStatisticUpdates)return void this._updateStatisticsRequests.push({level:e,statistics:t});let s=this._statisticsByLevel.get(e);s||(s=new Map,this._statisticsByLevel.set(e,s));for(const r of t)s.set(r.fieldName,{minValue:r.minValue,maxValue:r.maxValue})}editStart(){this._renderState?.lockUploads(),this.attributeView.lockTextureUploads(),this._lockStatisticUpdates=!0}editEnd(){this._renderState?.unlockUploads(),this.attributeView.unlockTextureUploads(),this._lockStatisticUpdates=!1;for(const e of this._updateStatisticsRequests)this.updateStatistics(e.level,e.statistics);this._updateStatisticsRequests=[],this._renderState?.flush(),this.requestRender()}swapRenderState(){this._renderStateNext&&(has("esri-2d-update-debug")&&console.debug(`Version[${this._renderStateNext.version}] FeatureContainer.update.swapRenderState`),this._renderState?.destroy(),this._renderState=this._renderStateNext,this._renderStateNext=null),this._renderState&&this._renderState.flush(),this.requestRender()}setVisibleTiles(e){this._visibleTiles=e}async onMessage(t,s){e(s);const r=t.inner;if(!this._subscriptions.has(r.id))return;const i=this._subscriptions.get(r.id);if(i.version!==r.subscriptionVesrion){if(has("esri-2d-update-debug")){const e=`${r.subscriptionVesrion} != ${i.version}`;console.debug(`Version[${e}] Tile[${r.id}] FeatureContainer - Dropping message, outdated version]`,r)}return}const n=this._renderStateNext??this._renderState;if(!n)throw new Error("InternalError: No renderState defined");n.version!==r.version&&console.error(`InternalError: Version mismatch. [renderState: ${n.version}, message: ${r.version}]`),n.enqueueUpdate(t),this.requestRender(),this._layerView.view.labelManager.requestUpdate(),this._layerView.requestUpdate()}removeTile(e){(this._renderState||this._renderStateNext)&&(this._renderState&&this._renderState.removeTile(e),this._renderStateNext&&this._renderStateNext.removeTile(e))}hitTest(e){let s=this._hitTestsRequests.find((({x:t,y:s})=>t===e.x&&s===e.y));const r=t();return s?s.resolvers.push(r):(s={x:e.x,y:e.y,resolvers:[r]},this._hitTestsRequests.push(s)),this.requestRender(),r.promise}getSortKeys(e){const t=new Set(e),s=new Map;for(const r of this.children)if(r.getSortKeys(t).forEach(((e,t)=>s.set(t,e))),s.size===t.size)break;return s}get hasAnimation(){return this.hasLabels}doRender(e){const{minScale:t,maxScale:s}=this._layer.effectiveScaleRange,r=e.state.scale;r<=(t||1/0)&&r>=s&&super.doRender(e)}afterRender(e){super.afterRender(e),this._hitTestsRequests.length&&this.requestRender()}setStencilReference(e){if(null==this._getHeatmapInstance(e))super.setStencilReference(e);else for(const t of this.children)t.stencilRef=h.heatmap.getStencilReference(t)}_renderMapPhase(e){this._layerView.featureEffectView.hasEffects?(this._renderOutsideEffect(e),this._renderInsideEffect(e)):this._renderFeatures(e,n.All),this._hitTestsRequests.length>0&&this._renderHittest(e)}_renderHighlightPhase(e){this.hasHighlight&&u(e,!1,(e=>{this._renderFeatures(e,n.Highlight)}))}_renderLabelPhase(e){this._renderFeatures(e,n.All)}_renderInsideEffect(e){const t=e.painter.effects.insideEffect;t.bind(e),this._renderFeatures(e,n.InsideEffect),t.draw(e,this._layerView.featureEffectView.includedEffects),t.unbind()}_renderOutsideEffect(e){const t=e.painter.effects.outsideEffect;t.bind(e),this._renderFeatures(e,n.OutsideEffect),t.draw(e,this._layerView.featureEffectView.excludedEffects),t.unbind()}_renderHittest(e){const{context:t}=e,s=e.painter.effects.hittest,r=t.getBoundFramebufferObject(),a=t.getViewport(),o=e.passOptions,h=e.drawPhase;s.bind(e),e.passOptions=s.createOptions(e,this._hitTestsRequests),e.drawPhase=i.HITTEST;const{distance:d,smallSymbolDistance:l}=e.passOptions,u=Math.max(d,l);for(const i of this.children)i.visible&&i.containsScreenPoint(e.state,e.passOptions.position,2*u)&&this._renderTile(i,e,n.All);s.draw(e),s.unbind(),t.bindFramebuffer(r),t.restoreViewport(a),e.passOptions=o,e.drawPhase=h}_renderFeatures(e,t){const s=this._getHeatmapInstance(e);null!=s?this._renderHeatmapFeatures(e,t,s):this._renderGeometryFeatures(e,t)}_renderGeometryFeatures(e,t){for(const s of this.children)s.visible&&this._renderTile(s,e,t)}_renderHeatmapFeatures(e,t,s){for(const r of this.children)r.visible&&this._renderTile(r,e,t,d.Heatmap);s.techniqueRef.renderResolvePass(e,s)}_renderTile(e,t,s,r){const i=has("featurelayer-force-marker-text-draw-order")?a.STRICT_MARKERS_AND_TEXT:a.BATCHING,n=e.getDisplayList(this._instanceStore,i);t.selection=s,n?.render(t,r)}}function _(e){return e.techniqueRef.type===d.Heatmap}export{p as FeatureContainer};
5
+ import has from"../../../../core/has.js";import{throwIfAborted as e,createResolver as t}from"../../../../core/promiseUtils.js";import{UpdatingHandles as s}from"../../../../core/support/UpdatingHandles.js";import{AFeatureContainer as r}from"../../engine/AFeatureContainer.js";import{WGLDrawPhase as i,FeatureSelection as n,FeatureBatchingStrategy as a}from"../../engine/webgl/enums.js";import o from"../../engine/webgl/shaderGraph/techniques/FeatureInstanceStore.js";import{Techniques as h}from"../../engine/webgl/shaderGraph/techniques/TechniqueRegistry.js";import{TechniqueType as d}from"../../engine/webgl/shaderGraph/techniques/TechniqueType.js";import{RenderState as l}from"./RenderState.js";import{renderHighlight as u}from"../support/util.js";class c{constructor(e,s){this.id=e,this.version=s,this._resolver=t(),this._done=!1}get done(){return this._done}get promise(){return this._resolver.promise}end(){this._resolver.resolve(),this._done=!0}destroy(){this._resolver.reject()}}class _ extends r{constructor(e){super(e.view.featuresTilingScheme),this.updatingHandles=new s,this._hitTestsRequests=[],this._store=new o,this._visibleTiles=new Set,this._subscriptions=new Map,this._updateStatisticsRequests=[],this._lockStatisticUpdates=!1,this._layerView=e,this.addTransitionable(this._layerView.featureEffectView)}renderChildren(e){if(this._updateAttributeView(),this._renderState?.update(this.attributeView.currentEpoch),this._renderState){const e=Array.from(this._renderState.tiles()).filter((e=>e.needsUpload));if(e.length){e[Math.floor(Math.random()*e.length)].upload(),e.length>=2&&this.requestRender()}for(const t of this._renderState.tiles())t.tryReady(this.attributeView.currentEpoch)&&(this._subscriptions.get(t.key.id)?.end(),this._layerView.requestUpdate(),this.hasLabels&&this._layerView.view.labelManager.requestUpdate(),this.requestRender())}for(const t of this.children)t.setTransform(e.state);switch(super.renderChildren(e),e.drawPhase){case i.MAP:return this._renderMapPhase(e);case i.HIGHLIGHT:return this._renderHighlightPhase(e);case i.LABEL:return this._renderLabelPhase(e)}}subscriptions(){return this._subscriptions.values()}get _instanceStore(){return this._store}get instanceStore(){return this._store}get layerView(){return this._layerView}get hasLabels(){return this._layerView.labelingCollisionInfos.length>0}get hasHighlight(){return this._layerView.hasHighlight()}get _layer(){return this._layerView.layer}_getHeatmapInstance(e){if(null==this._instanceStore||!(e.drawPhase&h.heatmap.drawPhase))return null;for(const t of this._instanceStore.values())if(p(t))return t;return null}get children(){return this._renderState?Array.from(this._renderState.tiles()).filter((e=>this._visibleTiles.has(e.key.id))):[]}updateAttributeView(e){this.requestRender(),this.attributeView.requestUpdate(e),this.hasLabels&&this._layerView.view.labelManager.requestUpdate()}updateSubscriptions(e){for(const{tileId:t,version:s}of e.subscribe)if(this._subscriptions.has(t))this._subscriptions.get(t).version=s;else{const e=new c(t,s);this._subscriptions.set(t,e),this.updatingHandles.addPromise(e.promise)}for(const t of e.unsubscribe){const e=this._subscriptions.get(t);e?.destroy(),this._subscriptions.delete(t),this.removeTile(t)}}isDone(e){return!!this._renderState&&this._renderState.isTileDone(e)}async updateRenderState(e){has("esri-2d-update-debug")&&console.debug(`Version[${e}] FeatureContainer.updateRenderState`),this._renderStateNext=new l((()=>this._stage),(e=>this._subscriptions.get(e)?.version),e,this.tileInfoView)}getDisplayStatistics(e,t){const s=this._statisticsByLevel.get(e);return s?s.get(t):null}updateStatistics(e,t){if(this._lockStatisticUpdates)return void this._updateStatisticsRequests.push({level:e,statistics:t});let s=this._statisticsByLevel.get(e);s||(s=new Map,this._statisticsByLevel.set(e,s));for(const r of t)s.set(r.fieldName,{minValue:r.minValue,maxValue:r.maxValue})}editStart(){this._renderState?.lockUploads(),this.attributeView.lockTextureUploads(),this._lockStatisticUpdates=!0}editEnd(){this._renderState?.unlockUploads(),this.attributeView.unlockTextureUploads(),this._lockStatisticUpdates=!1;for(const e of this._updateStatisticsRequests)this.updateStatistics(e.level,e.statistics);this._updateStatisticsRequests=[],this._renderState?.flush(),this.requestRender()}swapRenderState(){this._renderStateNext&&(has("esri-2d-update-debug")&&console.debug(`Version[${this._renderStateNext.version}] FeatureContainer.update.swapRenderState`),this._renderState?.destroy(),this._renderState=this._renderStateNext,this._renderStateNext=null),this._renderState&&this._renderState.flush(),this.requestRender()}setVisibleTiles(e){this._visibleTiles=e}async onMessage(t,s){e(s);const r=t.inner;if(!this._subscriptions.has(r.id))return;const i=this._subscriptions.get(r.id);if(i.version!==r.subscriptionVesrion){if(has("esri-2d-update-debug")){const e=`${r.subscriptionVesrion} != ${i.version}`;console.debug(`Version[${e}] Tile[${r.id}] FeatureContainer - Dropping message, outdated version]`,r)}return}const n=this._renderStateNext??this._renderState;if(!n)throw new Error("InternalError: No renderState defined");n.version!==r.version&&console.error(`InternalError: Version mismatch. [renderState: ${n.version}, message: ${r.version}]`),n.enqueueUpdate(t),this.requestRender(),this._layerView.view.labelManager.requestUpdate(),this._layerView.requestUpdate()}removeTile(e){(this._renderState||this._renderStateNext)&&(this._renderState&&this._renderState.removeTile(e),this._renderStateNext&&this._renderStateNext.removeTile(e))}hitTest(e){let s=this._hitTestsRequests.find((({x:t,y:s})=>t===e.x&&s===e.y));const r=t();return s?s.resolvers.push(r):(s={x:e.x,y:e.y,resolvers:[r]},this._hitTestsRequests.push(s)),this.requestRender(),r.promise}getSortKeys(e){const t=new Set(e),s=new Map;for(const r of this.children)if(r.getSortKeys(t).forEach(((e,t)=>s.set(t,e))),s.size===t.size)break;return s}get hasAnimation(){return this.hasLabels}doRender(e){const{minScale:t,maxScale:s}=this._layer.effectiveScaleRange,r=e.state.scale;r<=(t||1/0)&&r>=s&&super.doRender(e)}afterRender(e){super.afterRender(e),this._hitTestsRequests.length&&this.requestRender()}setStencilReference(e){if(null==this._getHeatmapInstance(e))super.setStencilReference(e);else for(const t of this.children)t.stencilRef=h.heatmap.getStencilReference(t)}_renderMapPhase(e){this._layerView.featureEffectView.hasEffects?(this._renderOutsideEffect(e),this._renderInsideEffect(e)):this._renderFeatures(e,n.All),this._hitTestsRequests.length>0&&this._renderHittest(e)}_renderHighlightPhase(e){this.hasHighlight&&u(e,!1,(e=>{this._renderFeatures(e,n.Highlight)}))}_renderLabelPhase(e){this._renderFeatures(e,n.All)}_renderInsideEffect(e){const t=e.painter.effects.insideEffect;t.bind(e),this._renderFeatures(e,n.InsideEffect),t.draw(e,this._layerView.featureEffectView.includedEffects),t.unbind()}_renderOutsideEffect(e){const t=e.painter.effects.outsideEffect;t.bind(e),this._renderFeatures(e,n.OutsideEffect),t.draw(e,this._layerView.featureEffectView.excludedEffects),t.unbind()}_renderHittest(e){const{context:t}=e,s=e.painter.effects.hittest,r=t.getBoundFramebufferObject(),a=t.getViewport(),o=e.passOptions,h=e.drawPhase;s.bind(e),e.passOptions=s.createOptions(e,this._hitTestsRequests),e.drawPhase=i.HITTEST;const{distance:d,smallSymbolDistance:l}=e.passOptions,u=Math.max(d,l);for(const i of this.children)i.visible&&i.containsScreenPoint(e.state,e.passOptions.position,2*u)&&this._renderTile(i,e,n.All);s.draw(e),s.unbind(),t.bindFramebuffer(r),t.restoreViewport(a),e.passOptions=o,e.drawPhase=h}_renderFeatures(e,t){const s=this._getHeatmapInstance(e);null!=s?this._renderHeatmapFeatures(e,t,s):this._renderGeometryFeatures(e,t)}_renderGeometryFeatures(e,t){for(const s of this.children)s.visible&&this._renderTile(s,e,t)}_renderHeatmapFeatures(e,t,s){for(const r of this.children)r.visible&&this._renderTile(r,e,t,d.Heatmap);s.techniqueRef.renderResolvePass(e,s)}_renderTile(e,t,s,r){const i=has("featurelayer-strict-draw-order")?a.STRICT_ORDER:has("featurelayer-force-marker-text-draw-order")?a.STRICT_MARKERS_AND_TEXT:a.BATCHING,n=e.getDisplayList(this._instanceStore,i);t.selection=s,n?.render(t,r)}}function p(e){return e.techniqueRef.type===d.Heatmap}export{_ as FeatureContainer};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import e from"../../../../core/Error.js";import{handlesGroup as t}from"../../../../core/handleUtils.js";import has from"../../../../core/has.js";import{nextTick as s}from"../../../../core/nextTick.js";import{throwIfNotAbortError as i,createResolver as r,ignoreAbortErrors as o}from"../../../../core/promiseUtils.js";import n from"../../../../core/RandomLCG.js";import{watch as u}from"../../../../core/reactiveUtils.js";import{pt2px as a}from"../../../../core/screenUtils.js";import{ignoreConnectionErrors as d}from"../../../../core/workers/utils.js";import c from"../../../../layers/support/TileInfo.js";import p from"../../tiling/TileInfoView.js";import"../../tiling/TileKey.js";import"../../tiling/TileQueue.js";import"../../tiling/TileStrategy.js";import{tileSize as l}from"../../engine/webgl/definitions.js";import{PipelineConnectionHandlers as h}from"./PipelineConnectionHandlers.js";import g from"./Processor.js";import{FeatureSource as _}from"./sources/FeatureSource.js";import{FeatureTileSubscription as b}from"./sources/FeatureTileSubscription.js";import{Tile as f}from"./support/Tile.js";class m{constructor(e){this.inner=e,this.resolver=r()}}class y{constructor(){this._aggregateAdapter={getFeatureObjectIds:e=>this._processor.getFeatureObjectIdsForAggregate(e)},this._subscriptions=new Map,this._updateRequested=!1,this._updateSubscriptionRequests=[],this._updateHighlightRequests=[]}destroy(){this._subscriptions.clear(),this._processor?.destroy(),this._source?.destroy(),this._handles?.remove(),this._updateOverridesRequest=null,this._tileInfoView=null}onAttach(e){has("esri-2d-update-debug")&&console.debug("Pipeline.onAttach");const s=this._connection,i=c.fromJSON(e.tileInfoJSON);this._tileInfoView=new p(i),this._source=new _(e.service,this._aggregateAdapter,this._subscriptions,(()=>this._requestUpdate()),s),this._processor=new g(s,this._source),this._handles=t([u((()=>this._source.updateTracking.updating),(()=>{this._requestUpdate(),o(this._connection.layerView.setUpdating({source:this._source.updateTracking.updating,pipeline:!0}))}))])}onDetach(){has("esri-2d-update-debug")&&console.debug("Pipeline.onDetach"),this.destroy()}set remoteClient(e){this._connection=new h(e)}get features(){const t=this._source?.queryEngine;if(!t)throw new e("no-queryEngine","No query engine defined");return t}get aggregates(){const t=this._processor?.aggregateQueryEngine;if(!t)throw new e("no-queryEngine","No aggregate query engine defined");return t}get processor(){return this._processor}get streamMessenger(){return this._source.streamMessenger}getDisplayFeatures(e){return this._processor.getDisplayFeatures(e)}getDisplayIds(e){return this._processor.getDisplayIds(e)}getObjectIdsFromGlobalIds(e){return this._source.getObjectIdsFromGlobalIds(e)}async updateSchema(e,t){return has("esri-2d-update-debug")&&this._updateSchemaRequest&&console.error("InternalError: Schema already updating"),this._updateSchemaRequest=new m({schema:e,version:t}),this._requestUpdate(),this._updateSchemaRequest.resolver.promise}updateSubscriptions(e){const t=new m(e);return this._updateSubscriptionRequests.push(t),this._requestUpdate(),t.resolver.promise}updateHighlight(e){const t=new m(e);return this._updateHighlightRequests.push(t),this._requestUpdate(),t.resolver.promise}async addParquetFile(e){return this._source.addParquetFile(e)}async onOverride(t){if(null!=this._updateOverridesRequest)throw new e("InternalError - Already processing an edit");this._updateOverridesRequest=new m(t);const s=this._updateOverridesRequest.resolver.promise;return this._requestUpdate(),s}queryStatistics(){return this._source.statistics.toJSON()}async queryVisibleFeatures(e,t){return this.features.executeQuery(e,t)}async queryHeatmapStatistics(e){const t=Math.round(a(e.radius));let s=Number.POSITIVE_INFINITY,i=Number.NEGATIVE_INFINITY;const r="string"==typeof e.fieldOffset,o=e.fieldOffset??0,n=Array.from(this._subscriptions.values()),u=this._source.chunks(),d=t**2,c=3/(Math.PI*d),p=2*t,h=Math.ceil(l/p);for(const a of n){const t=a.tile,n=new Float64Array(h*h);for(const s of u){const i=s.getTileReader(t);if(!i)continue;const u=i.getCursor();for(;u.next();){let t=1;if(null!=e.field){const s=u.readAttribute(e.field);t=r?-1*+s:+s+o}const s=u.readXForDisplay()/p,i=u.readYForDisplay()/p,a=Math.floor(s),l=Math.floor(i);if(a<0||l<0||a>=h||l>=h)continue;const g=((.5+a-s)*p)**2+((.5+l-i)*p)**2;if(g>d)continue;const _=t*(c*(1-g/d)**2);n[l+a*h]+=_}}for(let e=0;e<n.length;e++)s=Math.min(s,n[e]),i=Math.max(i,n[e])}return{max:i,min:s}}async getSampleFeatures(e){const t=this._source.chunks();if(t.reduce(((e,t)=>e+t.size()),0)<=e.minFeatureCount){if(!this._source.updateTracking.updating){const e=[];return this._source.store.forEachUnsafe((t=>e.push(t.readLegacyFeatureWorldSpace()))),e}return null}const s=new Set,i=[],r=t.map((e=>e.reader.getCursor())),o=new n,u=3*e.sampleSize;for(let n=0;n<u&&i.length<e.sampleSize;n++){const e=r[o.getIntRange(0,t.length-1)];if(0===e.getSize())continue;const n=o.getIntRange(0,e.getSize()-1);e.setIndex(n);const u=e.getObjectId();s.has(u)||(s.add(u),i.push(e.readLegacyFeatureWorldSpace()))}return i.length>=e.sampleSize?i:null}_requestUpdate(){this._updateRequested||(this._updateRequested=!0,s((()=>this._scheduleNextUpdate())))}_scheduleNextUpdate(){this._updateRequested&&(this._ongoingUpdate||(this._ongoingUpdate=d(this._doUpdate()).finally((()=>{this._ongoingUpdate=null,this._scheduleNextUpdate()})),this._updateRequested=!1))}_subscribe(e){const t=e.tileId;if(this._subscriptions.has(t))return;has("esri-2d-update-debug")&&console.debug(`Tile[${t}] Pipeline.subscribe`);const s=new f(this._tileInfoView,t),i=new b(s,e.version);this._subscriptions.set(t,i),this._source.onSubscribe(i),this._processor.onSubscribe(i)}_unsubscribe(e){const t=this._subscriptions.get(e);t&&(has("esri-2d-update-debug")&&console.debug(`Tile[${e}] Pipeline.unsubscribe`),t.abort(),this._source.onUnsubscribe(t),this._processor.onUnsubscribe(t),this._subscriptions.delete(t.key.id))}async _doUpdate(){if(has("esri-2d-update-debug")&&console.debug("Pipeline._doUpdateStart"),await this._connection.layerView.setUpdating({source:this._source.updateTracking.updating,pipeline:!0}),this._updateSubscriptionRequests.length){const e=this._updateSubscriptionRequests;this._updateSubscriptionRequests=[];for(const t of e)this._doUpdateSubscriptions(t.inner),t.resolver.resolve()}const e=this._updateSchemaRequest;if(this._updateSchemaRequest=null,null!=e){const{schema:t,version:s}=e.inner;await this._doUpdateSchema(t,s)}const t=this._updateOverridesRequest;if(this._updateOverridesRequest=null,null!=t){has("esri-2d-update-debug")&&console.debug("Pipeline.applyOverride",t.inner);const e=await this._source.normalizeOverrides(t.inner);null!=e.historicMoment&&this._source.unsafeSetQueryHistoricMoment(e.historicMoment),this._source.applyOverride(e),has("esri-2d-update-debug")&&console.debug("Pipeline.endOverride",t.inner)}if(this._updateHighlightRequests.length){const e=this._updateHighlightRequests;this._updateHighlightRequests=[];for(const t of e)this._processor.updateHighlight(t.inner),t.resolver.resolve()}const s=this._source.cleanupRemovedChunks();this._processor.removeChunks(s);try{const e=this._source.takeOverrideUpdate();null!=e&&this._subscriptions.size&&(has("esri-2d-update-debug")&&console.debug("Pipeline.applyOverrideChangesStart"),await this._processor.applyOverrideUpdate(e),has("esri-2d-update-debug")&&console.debug("Pipeline.applyOverrideChangesEnd")),this._subscriptions.size&&(has("esri-2d-update-debug")&&console.debug("Pipeline.updateChunksStart"),await this._processor.updateChunks(),has("esri-2d-update-debug")&&console.debug("Pipeline.updateChunksEnd"))}catch(r){i(r)}null!=t&&t.resolver.resolve(),null!=e&&e.resolver.resolve(),this._updateRequested?(has("esri-2d-update-debug")&&console.debug("Pipeline._doUpdateEnd [updateRequested=true]"),await this._connection.layerView.setUpdating({source:this._source.updateTracking.updating,pipeline:!0})):(has("esri-2d-update-debug")&&console.debug("Pipeline._doUpdateEnd [updateRequested=false, After flush]"),await this._connection.layerView.setUpdating({source:this._source.updateTracking.updating,pipeline:this._updateRequested}))}async _doUpdateSchema(e,t){has("esri-2d-update-debug")&&console.debug(`Version[${t}] Pipeline.updateStart`,{schema:e});const s={tileInfo:this._tileInfoView?.tileInfo},i=await this._source.update(e,t),r=Array.from(this._subscriptions.values());await this._processor.update(e,t,s,i,r),has("esri-2d-update-debug")&&console.debug(`Version[${t}] Pipeline.updateEnd`)}_doUpdateSubscriptions(e){has("esri-2d-update-debug")&&console.debug("Pipeline.updateSubscriptions",e);for(const t of e.subscribe)this._subscribe(t);for(const t of e.unsubscribe)this._unsubscribe(t)}}export{y as default};
5
+ import e from"../../../../core/Error.js";import{handlesGroup as t}from"../../../../core/handleUtils.js";import has from"../../../../core/has.js";import{nextTick as s}from"../../../../core/nextTick.js";import{throwIfNotAbortError as i,createResolver as r,ignoreAbortErrors as o}from"../../../../core/promiseUtils.js";import n from"../../../../core/RandomLCG.js";import{watch as u}from"../../../../core/reactiveUtils.js";import{pt2px as a}from"../../../../core/screenUtils.js";import{ignoreConnectionErrors as d}from"../../../../core/workers/utils.js";import c from"../../../../layers/support/TileInfo.js";import p from"../../tiling/TileInfoView.js";import"../../tiling/TileKey.js";import"../../tiling/TileQueue.js";import"../../tiling/TileStrategy.js";import{tileSize as h}from"../../engine/webgl/definitions.js";import{PipelineConnectionHandlers as l}from"./PipelineConnectionHandlers.js";import g from"./Processor.js";import{FeatureSource as _}from"./sources/FeatureSource.js";import{FeatureTileSubscription as b}from"./sources/FeatureTileSubscription.js";import{Tile as f}from"./support/Tile.js";class m{constructor(e){this.inner=e,this.resolver=r()}}class q{constructor(){this._aggregateAdapter={getFeatureObjectIds:e=>this._processor.getFeatureObjectIdsForAggregate(e)},this._subscriptions=new Map,this._updateRequested=!1,this._didSourceRefresh=!1,this._updateSubscriptionRequests=[],this._updateHighlightRequests=[]}destroy(){this._subscriptions.clear(),this._processor?.destroy(),this._source?.destroy(),this._handles?.remove(),this._updateOverridesRequest=null,this._tileInfoView=null}onAttach(e){has("esri-2d-update-debug")&&console.debug("Pipeline.onAttach");const s=this._connection,i=c.fromJSON(e.tileInfoJSON);this._tileInfoView=new p(i),this._source=new _(e.service,this._aggregateAdapter,this._subscriptions,s),this._processor=new g(s,this._source),this._handles=t([this._source.store.events.on("changed",(()=>this._requestUpdate())),this._source.store.events.on("refresh",(()=>this._requestRefresh())),u((()=>this._source.updateTracking.updating),(()=>{this._requestUpdate(),o(this._connection.layerView.setUpdating({source:this._source.updateTracking.updating,pipeline:!0}))}))])}onDetach(){has("esri-2d-update-debug")&&console.debug("Pipeline.onDetach"),this.destroy()}set remoteClient(e){this._connection=new l(e)}get features(){const t=this._source?.queryEngine;if(!t)throw new e("no-queryEngine","No query engine defined");return t}get aggregates(){const t=this._processor?.aggregateQueryEngine;if(!t)throw new e("no-queryEngine","No aggregate query engine defined");return t}get processor(){return this._processor}get streamMessenger(){return this._source.streamMessenger}getDisplayFeatures(e){return this._processor.getDisplayFeatures(e)}getDisplayIds(e){return this._processor.getDisplayIds(e)}getObjectIdsFromGlobalIds(e){return this._source.getObjectIdsFromGlobalIds(e)}async updateSchema(e,t){return has("esri-2d-update-debug")&&this._updateSchemaRequest&&console.error("InternalError: Schema already updating"),this._updateSchemaRequest=new m({schema:e,version:t}),this._requestUpdate(),this._updateSchemaRequest.resolver.promise}updateSubscriptions(e){const t=new m(e);return this._updateSubscriptionRequests.push(t),this._requestUpdate(),t.resolver.promise}updateHighlight(e){const t=new m(e);return this._updateHighlightRequests.push(t),this._requestUpdate(),t.resolver.promise}async addParquetFile(e){return this._source.addParquetFile(e)}async onOverride(t){if(null!=this._updateOverridesRequest)throw new e("InternalError - Already processing an edit");this._updateOverridesRequest=new m(t);const s=this._updateOverridesRequest.resolver.promise;return this._requestUpdate(),s}queryStatistics(){return this._source.statistics.toJSON()}async queryVisibleFeatures(e,t){return this.features.executeQuery(e,t)}async queryHeatmapStatistics(e){const t=Math.round(a(e.radius));let s=Number.POSITIVE_INFINITY,i=Number.NEGATIVE_INFINITY;const r="string"==typeof e.fieldOffset,o=e.fieldOffset??0,n=Array.from(this._subscriptions.values()),u=this._source.chunks(),d=t**2,c=3/(Math.PI*d),p=2*t,l=Math.ceil(h/p);for(const a of n){const t=a.tile,n=new Float64Array(l*l);for(const s of u){const i=s.getTileReader(t);if(!i)continue;const u=i.getCursor();for(;u.next();){let t=1;if(null!=e.field){const s=u.readAttribute(e.field);t=r?-1*+s:+s+o}const s=u.readXForDisplay()/p,i=u.readYForDisplay()/p,a=Math.floor(s),h=Math.floor(i);if(a<0||h<0||a>=l||h>=l)continue;const g=((.5+a-s)*p)**2+((.5+h-i)*p)**2;if(g>d)continue;const _=t*(c*(1-g/d)**2);n[h+a*l]+=_}}for(let e=0;e<n.length;e++)s=Math.min(s,n[e]),i=Math.max(i,n[e])}return{max:i,min:s}}async getSampleFeatures(e){const t=this._source.chunks();if(t.reduce(((e,t)=>e+t.size()),0)<=e.minFeatureCount){if(!this._source.updateTracking.updating){const e=[];return this._source.store.forEachUnsafe((t=>e.push(t.readLegacyFeatureWorldSpace()))),e}return null}const s=new Set,i=[],r=t.map((e=>e.reader.getCursor())),o=new n,u=3*e.sampleSize;for(let n=0;n<u&&i.length<e.sampleSize;n++){const e=r[o.getIntRange(0,t.length-1)];if(0===e.getSize())continue;const n=o.getIntRange(0,e.getSize()-1);e.setIndex(n);const u=e.getObjectId();s.has(u)||(s.add(u),i.push(e.readLegacyFeatureWorldSpace()))}return i.length>=e.sampleSize?i:null}_requestUpdate(){this._updateRequested||(this._updateRequested=!0,s((()=>this._scheduleNextUpdate())))}_requestRefresh(){this._didSourceRefresh=!0,this._requestUpdate()}_scheduleNextUpdate(){this._updateRequested&&(this._ongoingUpdate||(this._ongoingUpdate=d(this._doUpdate()).finally((()=>{this._ongoingUpdate=null,this._scheduleNextUpdate()})),this._updateRequested=!1))}_subscribe(e){const t=e.tileId;if(this._subscriptions.has(t))return;has("esri-2d-update-debug")&&console.debug(`Tile[${t}] Pipeline.subscribe`);const s=new f(this._tileInfoView,t),i=new b(s,e.version);this._subscriptions.set(t,i),this._source.onSubscribe(i),this._processor.onSubscribe(i)}_unsubscribe(e){const t=this._subscriptions.get(e);t&&(has("esri-2d-update-debug")&&console.debug(`Tile[${e}] Pipeline.unsubscribe`),t.abort(),this._source.onUnsubscribe(t),this._processor.onUnsubscribe(t),this._subscriptions.delete(t.key.id))}async _doUpdate(){if(has("esri-2d-update-debug")&&console.debug("Pipeline._doUpdateStart"),await this._connection.layerView.setUpdating({source:this._source.updateTracking.updating,pipeline:!0}),this._updateSubscriptionRequests.length){const e=this._updateSubscriptionRequests;this._updateSubscriptionRequests=[];for(const t of e)this._doUpdateSubscriptions(t.inner),t.resolver.resolve()}const e=this._updateSchemaRequest;if(this._updateSchemaRequest=null,null!=e){const{schema:t,version:s}=e.inner;await this._doUpdateSchema(t,s)}this._didSourceRefresh&&(this._processor.requestInvalidateMesh(),this._didSourceRefresh=!1);const t=this._processor.invalidateRequested;t&&await this._connection.container.updateRenderState(this._processor.version);const s=this._updateOverridesRequest;if(this._updateOverridesRequest=null,null!=s){has("esri-2d-update-debug")&&console.debug("Pipeline.applyOverride",s.inner);const e=await this._source.normalizeOverrides(s.inner);null!=e.historicMoment&&this._source.unsafeSetQueryHistoricMoment(e.historicMoment),this._source.applyOverride(e),has("esri-2d-update-debug")&&console.debug("Pipeline.endOverride",s.inner)}if(this._updateHighlightRequests.length){const e=this._updateHighlightRequests;this._updateHighlightRequests=[];for(const t of e)this._processor.updateHighlight(t.inner),t.resolver.resolve()}const r=this._source.cleanupRemovedChunks();this._processor.removeChunks(r);try{const e=this._source.takeOverrideUpdate();null!=e&&this._subscriptions.size&&(has("esri-2d-update-debug")&&console.debug("Pipeline.applyOverrideChangesStart"),await this._processor.applyOverrideUpdate(e),has("esri-2d-update-debug")&&console.debug("Pipeline.applyOverrideChangesEnd")),this._subscriptions.size&&(has("esri-2d-update-debug")&&console.debug("Pipeline.updateChunksStart"),await this._processor.updateChunks(),has("esri-2d-update-debug")&&console.debug("Pipeline.updateChunksEnd"))}catch(o){i(o)}null!=s&&s.resolver.resolve(),null!=e&&e.resolver.resolve(),t&&await this._connection.container.swapRenderState(),this._updateRequested?(has("esri-2d-update-debug")&&console.debug("Pipeline._doUpdateEnd [updateRequested=true]"),await this._connection.layerView.setUpdating({source:this._source.updateTracking.updating,pipeline:!0})):(has("esri-2d-update-debug")&&console.debug("Pipeline._doUpdateEnd [updateRequested=false, After flush]"),await this._connection.layerView.setUpdating({source:this._source.updateTracking.updating,pipeline:this._updateRequested}))}async _doUpdateSchema(e,t){has("esri-2d-update-debug")&&console.debug(`Version[${t}] Pipeline.updateStart`,{schema:e});const s={tileInfo:this._tileInfoView?.tileInfo},i=await this._source.update(e,t),r=Array.from(this._subscriptions.values());await this._processor.update(e,t,s,i,r),has("esri-2d-update-debug")&&console.debug(`Version[${t}] Pipeline.updateEnd`)}_doUpdateSubscriptions(e){has("esri-2d-update-debug")&&console.debug("Pipeline.updateSubscriptions",e);for(const t of e.subscribe)this._subscribe(t);for(const t of e.unsubscribe)this._unsubscribe(t)}}export{q as default};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import has from"../../../../core/has.js";import{destroyMaybe as e}from"../../../../core/maybe.js";import{notDeepEqual as t}from"../../../../core/object.js";import{throwIfNotAbortError as s,throwIfAborted as r}from"../../../../core/promiseUtils.js";import{diff as i}from"../../../../core/accessorSupport/diffUtils.js";import{ignoreConnectionErrors as a}from"../../../../core/workers/utils.js";import o from"../../../../geometry/SpatialReference.js";import{MultiTileMeshData as n}from"../../engine/webgl/mesh/MultiTileMeshData.js";import{FeatureMeshFactory as c}from"../../engine/webgl/mesh/factories/FeatureMeshFactory.js";import{ResourceProxy as h}from"../../engine/webgl/mesh/factories/ResourceProxy.js";import{MeshWriterRegistry as u}from"../../engine/webgl/shaderGraph/techniques/mesh/MeshWriterRegistry.js";import{MatcherContext as p}from"../../engine/webgl/util/MatcherContext.js";import{ProcessorTileMessageQueue as g}from"./ProcessorTileMessageQueue.js";import{BinningStrategy as d}from"./processor/BinningStrategy.js";import{ClusterStrategy as y}from"./processor/ClusterStrategy.js";import{FeatureUpdateStrategy as _}from"./processor/FeatureUpdateStrategy.js";import{AttributeStore as l}from"./support/AttributeStore.js";import{ComputedAttributeStorage as m}from"./support/ComputedAttributeStorage.js";class f{constructor(e,t){this._connection=e,this._source=t,this._version=1,this._registry=new u,this._proxy=new h({fetch:(e,t)=>this._connection.layerView.fetch(e,t),fetchDictionary:(e,t)=>this._connection.layerView.fetchDictionary(e,t)}),this._attributeStore=new l({isLocal:!1,update:e=>a(this._connection.container.updateAttributeView(e))})}destroy(){this._proxy.destroy(),this._strategy?.destroy(),this._attributeStore.destroy()}get aggregateQueryEngine(){return this._strategy?.aggregateQueryEngine}getDisplayFeatures(e){return this._strategy?this._strategy.getDisplayFeatures(e):{features:[],aggregates:[]}}getDisplayIds(e){const t={};return this._strategy?(this._strategy.displayMap(e,(e=>e),((e,s,r)=>{t[r]=e})),t):t}getFeatureObjectIdsForAggregate(e){return this._strategy?this._strategy.getFeatureObjectIdsForAggregate(e):[]}onSubscribe(e){this._strategy?.onSubscribe(e)}onUnsubscribe(e){this._strategy?.onUnsubscribe(e)}async update(e,s,r,a,n){const h=e.processor,u=t(this._schema?.storage,h.storage),g=t(this._schema?.mesh.properties,h.mesh.properties),d=t(this._schema?.mesh.factory,h.mesh.factory),y=t(this._schema?.mesh.strategy,h.mesh.strategy),_=b(this._schema?.expressionProperties,h.expressionProperties),l=_.some((e=>this._attributeStore.hasArcadeDependency(e))),f=_.some((e=>this._factory?.hasArcadeDependency(e)??!1)),S=_.some((e=>this._strategy?.hasArcadeDependency(e)))||this._strategy?.isAggregate&&l,j=f||S,I=g||d||y;if(!(u||I||(f||l||S))&&!a)return;has("esri-2d-update-debug")&&console.debug(`Version[${this._version}] SymbolProcessor.update`,{changes:i(this._schema,h),schema:h}),this._schema=h;const x=o.fromJSON(this._source.service.outSpatialReference),v=new m({fields:this._source.metadata.fieldsIndex,spatialReference:x});if((u||I||l)&&(await this._attributeStore.update(h.storage,v,this._source.metadata,x,s),this._strategy?.invalidateAttributeData(w(h))),!a&&!I&&!j)return;(y||g||j)&&await this._updateStrategy(h.mesh.strategy,x,n,w(h)),this._updateSortKey(v,"sortKey"in h.mesh.properties?h.mesh.properties.sortKey:null);const M=new p(v,this._proxy,r,this._registry);return(d||"dictionary"===h.mesh.factory.symbology.type)&&(this._factory=await c.create(M,h.mesh.factory)),this._invalidate(),this._version=s,this._connection.container.updateRenderState(this._version)}async applyOverrideUpdate(e){if(!this._strategy)return;const t=this._strategy.applyOverrideUpdate(e);for await(const r of t)try{await this._process(r)}catch(s){}}async updateChunks(){await this._doUpdateChunks(),this._strategy?.afterUpdateChunks()}async removeChunks(e){this._strategy?.removeChunks(e),this._attributeStore.incrementDisplayIdGeneration()}updateHighlight({highlights:e}){if(!this._strategy)return void this._attributeStore.setHighlight(e.map((({objectId:e,highlightFlags:t})=>({objectId:e,highlightFlags:t,displayId:-1}))),e);const t=this._strategy.displayMap(e,(({objectId:e})=>e),((e,{highlightFlags:t},s)=>({objectId:s,displayId:e,highlightFlags:t})));this._attributeStore.setHighlight(t,e)}async _doUpdateChunks(){if(!this._strategy)return;const e=this._strategy.updateChunks(),t=[],r=new Map;for await(const a of e){let e=r.get(a.id);null==e&&(e=new g({concurrency:16,process:e=>this._process(e)}),r.set(a.id,e));const i=e.push(a).catch((e=>s(e)));t.push(i)}try{await Promise.all(t)}catch(i){}has("esri-2d-update-debug")&&console.log("SendUpdates"),this._attributeStore.sendUpdates(),has("esri-2d-update-debug")&&console.log("SendUpdates.await")}async _updateStrategy(e,t,s,r){switch(this._strategy?.destroy(),e.type){case"feature":this._strategy=new _(this._source,this._attributeStore,r);break;case"binning":this._strategy=await d.create(e,t,this._source,this._attributeStore,r);break;case"cluster":this._strategy=await y.create(this._connection,e,t,this._source,this._attributeStore,r)}for(const i of s)this._strategy.onSubscribe(i)}async _updateSortKey(t,s){if(this._sortInfo=e(this._sortInfo?.computed),null!=s){const e=s.byRenderer?null:await t.createComputedField(s);this._sortInfo={...s,computed:e}}}_invalidate(){this._strategy&&this._strategy.invalidate()}async _process(e){const t=e.subscription;if(has("esri-2d-update-debug")){const s=t.tile;console.debug(`Version[${this._version}] Tile[${s.key.id}, end=${e.end}] Processor._process`)}await this._fetchResources(e),r(t.signal);const s=await this._write(e,t.tile.createArcadeEvaluationOptions(w(this._schema))),i=t.tile.tileInfoView.getLODInfoAt(t.tile.key),{message:a,transferList:o}=s.serialize(i),n={objectIdMap:null,inner:e.createMessage(a,this._version,this._attributeStore.epoch)};if(this._schema?.mesh.properties.returnMeshObjectId){n.objectIdMap={};const t=e.reader?.getCursor();if(t)for(;t.next();)n.objectIdMap[t.getDisplayId()]=t.getObjectId()}if(r(t.signal),await this._connection.container.onMessage(n,{signal:t.signal,transferList:o}),this._attributeStore.sendUpdates(),has("esri-2d-update-debug")){const s=t.tile;console.debug(`Version[${this._version}] Tile[${s.key.id}, end=${e.end}] Processor._process.await`)}}async _fetchResources(e){await this._fetchMatcherResources(e),await this._fetchWriterResources(e)}async _fetchMatcherResources(e){if(e.reader)return this._factory.enqueueMatcherRequests(this._proxy,e.reader)}async _fetchWriterResources(e){if(!e.reader)return;const t=e.reader.getCursor(),s=e.subscription.tile.createArcadeEvaluationOptions(w(this._schema));for(;t.next();)this._factory.enqueueWriterRequests(this._proxy,t,s);await this._proxy.fetchEnqueuedResources()}async _write(e,t){const s=e.subscription.tile,r=e.reader?.getCursor(),i=r?.getSize()??0,a=s.tileInfoView.tileInfo.isWrappable,o=s.tileInfoView.tileInfo.spatialReference.isWGS84,c=new n(s.key,this._strategy.enablePixelBuffering,a,o,i);if(!r)return c;const h=s.createArcadeEvaluationOptions(w(this._schema));for(;r.next();){const e=this._getSortKeyValue(r,t);c.entityStart(r.getDisplayId(),e),this._factory.write(c,this._proxy,r,h,s.level),c.entityEnd()}return c}_getSortKeyValue(e,t){if(!this._sortInfo)return 0;const{computed:s,order:r,byRenderer:i}=this._sortInfo,a=i?this._factory.getSortKey(e,t):s?.read(e,t);return null==a||isNaN(a)?0:a*("asc"===r?-1:1)}}function b(e,t){const s=[];return e?.timeExtent?.start===t.timeExtent?.start&&e?.timeExtent?.end===t.timeExtent?.end||s.push("timeProperties"),s}function w(e){const{timeZone:t}=e?.mesh.properties??{},{timeExtent:s}=e?.expressionProperties??{};return{timeZone:t,timeExtent:s}}export{f as default};
5
+ import has from"../../../../core/has.js";import{destroyMaybe as e}from"../../../../core/maybe.js";import{notDeepEqual as t}from"../../../../core/object.js";import{throwIfNotAbortError as s,throwIfAborted as r}from"../../../../core/promiseUtils.js";import{diff as i}from"../../../../core/accessorSupport/diffUtils.js";import{ignoreConnectionErrors as a}from"../../../../core/workers/utils.js";import o from"../../../../geometry/SpatialReference.js";import{MultiTileMeshData as n}from"../../engine/webgl/mesh/MultiTileMeshData.js";import{FeatureMeshFactory as c}from"../../engine/webgl/mesh/factories/FeatureMeshFactory.js";import{ResourceProxy as h}from"../../engine/webgl/mesh/factories/ResourceProxy.js";import{MeshWriterRegistry as u}from"../../engine/webgl/shaderGraph/techniques/mesh/MeshWriterRegistry.js";import{MatcherContext as d}from"../../engine/webgl/util/MatcherContext.js";import{ProcessorTileMessageQueue as g}from"./ProcessorTileMessageQueue.js";import{BinningStrategy as p}from"./processor/BinningStrategy.js";import{ClusterStrategy as y}from"./processor/ClusterStrategy.js";import{FeatureUpdateStrategy as _}from"./processor/FeatureUpdateStrategy.js";import{AttributeStore as l}from"./support/AttributeStore.js";import{ComputedAttributeStorage as m}from"./support/ComputedAttributeStorage.js";class f{constructor(e,t){this._connection=e,this._source=t,this._version=1,this._registry=new u,this._invalidateRequested=!1,this._proxy=new h({fetch:(e,t)=>this._connection.layerView.fetch(e,t),fetchDictionary:(e,t)=>this._connection.layerView.fetchDictionary(e,t)}),this._attributeStore=new l({isLocal:!1,update:e=>a(this._connection.container.updateAttributeView(e))})}destroy(){this._proxy.destroy(),this._strategy?.destroy(),this._attributeStore.destroy()}get aggregateQueryEngine(){return this._strategy?.aggregateQueryEngine}get invalidateRequested(){return this._invalidateRequested}get version(){return this._version}getDisplayFeatures(e){return this._strategy?this._strategy.getDisplayFeatures(e):{features:[],aggregates:[]}}getDisplayIds(e){const t={};return this._strategy?(this._strategy.displayMap(e,(e=>e),((e,s,r)=>{t[r]=e})),t):t}getFeatureObjectIdsForAggregate(e){return this._strategy?this._strategy.getFeatureObjectIdsForAggregate(e):[]}onSubscribe(e){this._strategy?.onSubscribe(e)}onUnsubscribe(e){this._strategy?.onUnsubscribe(e)}async update(e,s,r,a,n){const h=e.processor,u=t(this._schema?.storage,h.storage),g=t(this._schema?.mesh.properties,h.mesh.properties),p=t(this._schema?.mesh.factory,h.mesh.factory),y=t(this._schema?.mesh.strategy,h.mesh.strategy),_=b(this._schema?.expressionProperties,h.expressionProperties),l=_.some((e=>this._attributeStore.hasArcadeDependency(e))),f=_.some((e=>this._factory?.hasArcadeDependency(e)??!1)),S=_.some((e=>this._strategy?.hasArcadeDependency(e)))||this._strategy?.isAggregate&&l,I=f||S,j=g||p||y;if(!(u||j||(f||l||S))&&!a)return;has("esri-2d-update-debug")&&console.debug(`Version[${this._version}] SymbolProcessor.update`,{changes:i(this._schema,h),schema:h}),this._schema=h;const v=o.fromJSON(this._source.service.outSpatialReference),x=new m({fields:this._source.metadata.fieldsIndex,spatialReference:v});if((u||j||l)&&(await this._attributeStore.update(h.storage,x,this._source.metadata,v,s),this._strategy?.invalidateAttributeData(w(h))),!a&&!j&&!I)return;(y||g||I)&&await this._updateStrategy(h.mesh.strategy,v,n,w(h)),this._updateSortKey(x,"sortKey"in h.mesh.properties?h.mesh.properties.sortKey:null);const R=new d(x,this._proxy,r,this._registry);(p||"dictionary"===h.mesh.factory.symbology.type)&&(this._factory=await c.create(R,h.mesh.factory)),this.requestInvalidateMesh(),this._version=s}requestInvalidateMesh(){this._invalidateRequested=!0}async applyOverrideUpdate(e){if(!this._strategy)return;const t=this._strategy.applyOverrideUpdate(e);for await(const r of t)try{await this._process(r)}catch(s){}}async updateChunks(){this._invalidateRequested&&(this._invalidate(),this._invalidateRequested=!1),await this._doUpdateChunks(),this._strategy?.afterUpdateChunks()}async removeChunks(e){this._strategy?.removeChunks(e),this._attributeStore.incrementDisplayIdGeneration()}updateHighlight({highlights:e}){if(!this._strategy)return void this._attributeStore.setHighlight(e.map((({objectId:e,highlightFlags:t})=>({objectId:e,highlightFlags:t,displayId:-1}))),e);const t=this._strategy.displayMap(e,(({objectId:e})=>e),((e,{highlightFlags:t},s)=>({objectId:s,displayId:e,highlightFlags:t})));this._attributeStore.setHighlight(t,e)}async _doUpdateChunks(){if(!this._strategy)return;const e=this._strategy.updateChunks(),t=[],r=new Map;for await(const a of e){let e=r.get(a.id);null==e&&(e=new g({concurrency:16,process:e=>this._process(e)}),r.set(a.id,e));const i=e.push(a).catch((e=>s(e)));t.push(i)}try{await Promise.all(t)}catch(i){}has("esri-2d-update-debug")&&console.log("SendUpdates"),this._attributeStore.sendUpdates(),has("esri-2d-update-debug")&&console.log("SendUpdates.await")}async _updateStrategy(e,t,s,r){switch(this._strategy?.destroy(),e.type){case"feature":this._strategy=new _(this._source,this._attributeStore,r);break;case"binning":this._strategy=await p.create(e,t,this._source,this._attributeStore,r);break;case"cluster":this._strategy=await y.create(this._connection,e,t,this._source,this._attributeStore,r)}for(const i of s)this._strategy.onSubscribe(i)}async _updateSortKey(t,s){if(this._sortInfo=e(this._sortInfo?.computed),null!=s){const e=s.byRenderer?null:await t.createComputedField(s);this._sortInfo={...s,computed:e}}}_invalidate(){this._strategy&&this._strategy.invalidate()}async _process(e){const t=e.subscription;if(has("esri-2d-update-debug")){const s=t.tile;console.debug(`Version[${this._version}] Tile[${s.key.id}, end=${e.end}] Processor._process`)}await this._fetchResources(e),r(t.signal);const s=await this._write(e,t.tile.createArcadeEvaluationOptions(w(this._schema))),i=t.tile.tileInfoView.getLODInfoAt(t.tile.key),{message:a,transferList:o}=s.serialize(i),n={objectIdMap:null,inner:e.createMessage(a,this._version,this._attributeStore.epoch)};if(this._schema?.mesh.properties.returnMeshObjectId){n.objectIdMap={};const t=e.reader?.getCursor();if(t)for(;t.next();)n.objectIdMap[t.getDisplayId()]=t.getObjectId()}if(r(t.signal),await this._connection.container.onMessage(n,{signal:t.signal,transferList:o}),this._attributeStore.sendUpdates(),has("esri-2d-update-debug")){const s=t.tile;console.debug(`Version[${this._version}] Tile[${s.key.id}, end=${e.end}] Processor._process.await`)}}async _fetchResources(e){await this._fetchMatcherResources(e),await this._fetchWriterResources(e)}async _fetchMatcherResources(e){if(e.reader)return this._factory.enqueueMatcherRequests(this._proxy,e.reader)}async _fetchWriterResources(e){if(!e.reader)return;const t=e.reader.getCursor(),s=e.subscription.tile.createArcadeEvaluationOptions(w(this._schema));for(;t.next();)this._factory.enqueueWriterRequests(this._proxy,t,s);await this._proxy.fetchEnqueuedResources()}async _write(e,t){const s=e.subscription.tile,r=e.reader?.getCursor(),i=r?.getSize()??0,a=s.tileInfoView.tileInfo.isWrappable,o=s.tileInfoView.tileInfo.spatialReference.isWGS84,c=new n(s.key,this._strategy.enablePixelBuffering,a,o,i);if(!r)return c;const h=s.createArcadeEvaluationOptions(w(this._schema));for(;r.next();){const e=this._getSortKeyValue(r,t);c.entityStart(r.getDisplayId(),e),this._factory.write(c,this._proxy,r,h,s.level),c.entityEnd()}return c}_getSortKeyValue(e,t){if(!this._sortInfo)return 0;const{computed:s,order:r,byRenderer:i}=this._sortInfo,a=i?this._factory.getSortKey(e,t):s?.read(e,t);return null==a||isNaN(a)?0:a*("asc"===r?-1:1)}}function b(e,t){const s=[];return e?.timeExtent?.start===t.timeExtent?.start&&e?.timeExtent?.end===t.timeExtent?.end||s.push("timeProperties"),s}function w(e){const{timeZone:t}=e?.mesh.properties??{},{timeExtent:s}=e?.expressionProperties??{};return{timeZone:t,timeExtent:s}}export{f as default};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import e from"../../../../../request.js";import has from"../../../../../core/has.js";import{ignoreAbortErrors as t,throwIfNotAbortError as s}from"../../../../../core/promiseUtils.js";import{diff as r,hasRootDiffOnly as a,hasRootDiff as i}from"../../../../../core/accessorSupport/diffUtils.js";import{OptimizedFeature as n}from"../../../../../layers/graphics/OptimizedFeature.js";import{QueryEngine as o}from"../../../../../layers/graphics/data/QueryEngine.js";import{executeQueryForCount as d}from"../../../../../rest/query/operations/query.js";import{FeatureStoreStatistics as h}from"../FeatureStoreStatistics.js";import{FeatureSourceQueryInfo as u}from"./FeatureSourceQueryInfo.js";import{StreamMessenger as c}from"./StreamMessenger.js";import{DrillDownTileLoadStrategy as m}from"./strategies/DrillDownTileLoadStrategy.js";import{PagedTileLoadStrategy as p}from"./strategies/PagedTileLoadStrategy.js";import{ParquetLoadStrategy as l}from"./strategies/ParquetLoadStrategy.js";import{SnapshotLoadStrategy as _}from"./strategies/SnapshotLoadStrategy.js";import{StreamLoadStrategy as y}from"./strategies/StreamLoadStrategy.js";import{FeatureSourceChunkStore as g}from"./strategies/chunks/SourceChunkStore.js";import{FeatureMetadata as f}from"../support/FeatureMetadata.js";import{UpdateTracking2D as v}from"../../support/UpdateTracking2D.js";class S{constructor(e,t,s,r,a){this.service=e,this._aggregateAdapter=t,this._subscriptions=s,this._onChange=r,this._connection=a,this._updateTracking=new v({debugName:"FeatureSource"}),this._didInvalidateData=!1,this._metadata=f.createFeature(e.metadata),this._store=new g(this._onChange,this._metadata)}destroy(){this._strategy?.destroy(),this._store.destroy(),this._streamMessenger?.destroy(),"memory"===this.service.type&&this.service.source.map((e=>e.close()))}get metadata(){if(!this._metadata)throw new Error("InternalError: Metadata not defined. Was update called?");return this._metadata}get store(){return this._store}get streamMessenger(){return null==this._streamMessenger&&this._initStreamMessenger(),this._streamMessenger}get statistics(){return h.from(this._store)}get updateTracking(){return this._updateTracking}get queryEngine(){if(!this._queryEngine){if(!this._schema)return null;const{dataFilter:e}=this._schema.mutable,t=this._schema.mutable.availableFields,s=this._metadata;this._queryEngine=new o({featureStore:this._store,fieldsIndex:s.fieldsIndex,geometryType:s.geometryType,objectIdField:s.objectIdField,hasM:!1,hasZ:!1,spatialReference:this.service.outSpatialReference,aggregateAdapter:this._aggregateAdapter,timeInfo:s.timeInfo,definitionExpression:e.definitionExpression,availableFields:t})}return this._queryEngine}get isStream(){return"stream"===this._schema.type}chunks(){return Array.from(this._store.chunks())}cleanupRemovedChunks(){return this._store.cleanupRemovedChunks()}onSubscribe(e){this._connection.onEvent({type:"subscribe",tile:e.tile.id});const t=this._strategy?.load(e);t&&(t.then((()=>this._connection.onEvent({type:"loaded",tile:e.tile.id}))).catch((t=>this._connection.onEvent({type:"error",tile:e.tile.id,error:t}))),this._updateTracking.addPromise(t))}onResume(e){this._updateTracking.addPromise(t(this._strategy?.load(e)))}onUnsubscribe(e){this._connection.onEvent({type:"unsubscribe",tile:e.tile.id}),this._strategy?.unload(e)}applyOverride(e){this._didInvalidateData=!0,this._store.applyOverride(e)}takeOverrideUpdate(){return this._store.takeOverrideUpdate()}async update(e,t){const s=e.source,n=r(this._schema?.mutable,s.mutable);if(!n)return!1;if(has("esri-2d-update-debug")&&console.debug(`Version[${t}] FeatureSource.update`,{changes:n}),this._schema=s,this._queryEngine?.destroy(),this._queryEngine=null,"feature-service"===this.service.type&&null!=this.service.queryMetadata.lastEditDate&&(this._lastEditDate=this.service.queryMetadata.lastEditDate),null==this._streamMessenger&&"stream"===this._schema.type&&this._initStreamMessenger(),a(n,"sourceRefreshVersion")&&this._strategy?.refresh)return await this._strategy.refresh(),!0;if(("feature"===s.type||"parquet"===s.type)&&a(n,"availableFields")){if(await this._queryLastEditDateChanged()||this._didInvalidateData)this._didInvalidateData=!1,await this._updateStrategy(t);else{this._connection.onEvent({type:"updateFieldsStart"});try{await this._strategy.updateFields(s.mutable.availableFields),this._connection.onEvent({type:"updateFieldsEnd"})}catch(o){this._connection.onEvent({type:"updateFieldsError",error:o})}}return!1}return!(!i(n,"dataFilter")&&!i(n,"sourceRefreshVersion"))&&(await this._updateStrategy(t),!0)}async addParquetFile(e){this._strategy.addParquetFile(e)}unsafeSetQueryHistoricMoment(e){"feature"===this._schema.type&&(this._schema.mutable.dataFilter.historicMoment=e,this._strategy.unsafeSetQueryHistoricMoment(new Date(e)))}_initStreamMessenger(){null==this._streamMessenger&&(this._streamMessenger=new c(this._connection))}async normalizeOverrides(e){const t={historicMoment:e.historicMoment,commands:{updateWeak:e.commands.updateWeak.map(n.fromJSON),removeWeak:e.commands.removeWeak,update:e.commands.update.map(n.fromJSON),remove:e.commands.remove,release:e.commands.release}},s=e.commands.updateByIdWeak,r=await this._queryOptimizedFeatures(s);return t.commands.updateWeak.push(...r),t}async _queryOptimizedFeatures(e){if(0===e.length)return[];const t=[],s=(await this._strategy.queryByObjectId(e)).getCursor();for(;s.next();)t.push(s.readOptimizedFeatureWorldSpace());return t}getObjectIdsFromGlobalIds(e){const t=new Set(e),s=this.metadata.globalIdField;if(null==s)throw new Error("InternalError: Recieved an edit with globalIds, but not supported by the service");const r=[];return this._store.forEachUnsafe((e=>{const a=e.readAttribute(s);if(t.has(a)){const t=e.getObjectId();null!=t&&r.push(t)}})),r}async _queryLastEditDateChanged(){if(null==this._lastEditDate)return!1;const t=this.service.source,s={...t.query,f:"json"},r=(await e(t.path,{query:s,responseType:"json"})).data.editingInfo.lastEditDate;return r!==this._lastEditDate&&(this._lastEditDate=r,!0)}async _createStrategy(){const e="isSourceHosted"in this.service&&this.service.isSourceHosted,t=Array.isArray(this.service.source),s=this.service.source&&"collection"in this.service.source,r=e||t||s;if("stream"===this._schema.type){const e=new y(this.service,this._schema.mutable.dataFilter,this._store,{outSR:this.service.outSpatialReference},this.metadata);return this._streamMessenger.strategy=e,e}if("parquet"===this._schema.type){const e=this.service;return new l(e,this._metadata,this._schema,this._store)}const a=this.service,i=u.fromSchema(a,this._schema,this._metadata),n=await this._supportSnapshotMode(a,i);return n?new _(a,i,this._store,n.featureCount,this.metadata,this._connection):r?new p(a,i,this._store,this.metadata,this._connection):new m(a,i,this._store,this.metadata,this._connection)}async _updateStrategy(e){const t=await this._createStrategy();this._connection.onEvent({type:"updateStrategyStart",about:t.about});const r=!!this._strategy;this._store.clear(),this._strategy?.destroy(),this._strategy=t,has("esri-2d-update-debug")&&console.debug(`Version[${e}] FeatureSource.updateStrategy`,{strategy:t});const a=Array.from(this._subscriptions.values());if(!a.length)return void this._connection.onEvent({type:"updateStrategyEnd"});const i=Promise.all(a.map((e=>this._strategy.load(e).then((()=>this._connection.onEvent({type:"loaded",tile:e.tile.id}))).catch((t=>this._connection.onEvent({type:"error",tile:e.tile.id,error:t}))))));this._updateTracking.addPromise(i);try{r&&await i}catch(n){s(n)}this._connection.onEvent({type:"updateStrategyEnd"}),has("esri-2d-update-debug")&&console.debug(`Version[${e}] FeatureSource.updateStrategyEnd`,{strategy:t})}async _supportSnapshotMode(e,t){const{queryMetadata:s}=e,r=s.snapshotInfo;if(!r||!r.supportsSnapshotMinThreshold||!r.snapshotCountThresholds)return null;const a=e.source,i=t.createQuery();i.inner.orderByFields=[],i.inner.returnGeometry=!1;const n=(await d(a,i.inner,{query:i.customParameters})).data.count,{min:o,max:h}=r.snapshotCountThresholds;return n<=o||r.supportsSnapshotMaxThreshold&&n<h?{featureCount:n}:null}}export{S as FeatureSource};
5
+ import e from"../../../../../request.js";import has from"../../../../../core/has.js";import{ignoreAbortErrors as t,throwIfNotAbortError as s}from"../../../../../core/promiseUtils.js";import{diff as r,hasRootDiffOnly as a,hasRootDiff as i}from"../../../../../core/accessorSupport/diffUtils.js";import{OptimizedFeature as n}from"../../../../../layers/graphics/OptimizedFeature.js";import{QueryEngine as o}from"../../../../../layers/graphics/data/QueryEngine.js";import{executeQueryForCount as d}from"../../../../../rest/query/operations/query.js";import{FeatureStoreStatistics as h}from"../FeatureStoreStatistics.js";import{FeatureSourceQueryInfo as u}from"./FeatureSourceQueryInfo.js";import{StreamMessenger as c}from"./StreamMessenger.js";import{DrillDownTileLoadStrategy as m}from"./strategies/DrillDownTileLoadStrategy.js";import{PagedTileLoadStrategy as p}from"./strategies/PagedTileLoadStrategy.js";import{ParquetLoadStrategy as l}from"./strategies/ParquetLoadStrategy.js";import{SnapshotLoadStrategy as y}from"./strategies/SnapshotLoadStrategy.js";import{StreamLoadStrategy as _}from"./strategies/StreamLoadStrategy.js";import{FeatureSourceChunkStore as g}from"./strategies/chunks/SourceChunkStore.js";import{FeatureMetadata as f}from"../support/FeatureMetadata.js";import{UpdateTracking2D as v}from"../../support/UpdateTracking2D.js";class S{constructor(e,t,s,r){this.service=e,this._aggregateAdapter=t,this._subscriptions=s,this._connection=r,this._updateTracking=new v({debugName:"FeatureSource"}),this._didInvalidateData=!1,this._metadata=f.createFeature(e.metadata),this._store=new g(this._metadata)}destroy(){this._strategy?.destroy(),this._store.destroy(),this._streamMessenger?.destroy(),"memory"===this.service.type&&this.service.source.map((e=>e.close()))}get metadata(){if(!this._metadata)throw new Error("InternalError: Metadata not defined. Was update called?");return this._metadata}get store(){return this._store}get streamMessenger(){return null==this._streamMessenger&&this._initStreamMessenger(),this._streamMessenger}get statistics(){return h.from(this._store)}get updateTracking(){return this._updateTracking}get queryEngine(){if(!this._queryEngine){if(!this._schema)return null;const{dataFilter:e}=this._schema.mutable,t=this._schema.mutable.availableFields,s=this._metadata;this._queryEngine=new o({featureStore:this._store,fieldsIndex:s.fieldsIndex,geometryType:s.geometryType,objectIdField:s.objectIdField,hasM:!1,hasZ:!1,spatialReference:this.service.outSpatialReference,aggregateAdapter:this._aggregateAdapter,timeInfo:s.timeInfo,definitionExpression:e.definitionExpression,availableFields:t})}return this._queryEngine}get isStream(){return"stream"===this._schema.type}chunks(){return Array.from(this._store.chunks())}cleanupRemovedChunks(){return this._store.cleanupRemovedChunks()}onSubscribe(e){this._connection.onEvent({type:"subscribe",tile:e.tile.id});const t=this._strategy?.load(e);t&&(t.then((()=>this._connection.onEvent({type:"loaded",tile:e.tile.id}))).catch((t=>this._connection.onEvent({type:"error",tile:e.tile.id,error:t}))),this._updateTracking.addPromise(t))}onResume(e){this._updateTracking.addPromise(t(this._strategy?.load(e)))}onUnsubscribe(e){this._connection.onEvent({type:"unsubscribe",tile:e.tile.id}),this._strategy?.unload(e)}applyOverride(e){this._didInvalidateData=!0,this._store.applyOverride(e)}takeOverrideUpdate(){return this._store.takeOverrideUpdate()}async update(e,t){const s=e.source,n=r(this._schema?.mutable,s.mutable);if(!n)return!1;if(has("esri-2d-update-debug")&&console.debug(`Version[${t}] FeatureSource.update`,{changes:n}),this._schema=s,this._queryEngine?.destroy(),this._queryEngine=null,"feature-service"===this.service.type&&null!=this.service.queryMetadata.lastEditDate&&(this._lastEditDate=this.service.queryMetadata.lastEditDate),null==this._streamMessenger&&"stream"===this._schema.type&&this._initStreamMessenger(),a(n,"sourceRefreshVersion")&&this._strategy?.refresh)return await this._strategy.refresh(),!0;if(("feature"===s.type||"parquet"===s.type)&&a(n,"availableFields")){if(await this._queryLastEditDateChanged()||this._didInvalidateData)this._didInvalidateData=!1,await this._updateStrategy(t);else{this._connection.onEvent({type:"updateFieldsStart"});try{await this._strategy.updateFields(s.mutable.availableFields),this._connection.onEvent({type:"updateFieldsEnd"})}catch(o){this._connection.onEvent({type:"updateFieldsError",error:o})}}return!1}return!(!i(n,"dataFilter")&&!i(n,"sourceRefreshVersion"))&&(await this._updateStrategy(t),!0)}async addParquetFile(e){this._strategy.addParquetFile(e)}unsafeSetQueryHistoricMoment(e){"feature"===this._schema.type&&(this._schema.mutable.dataFilter.historicMoment=e,this._strategy.unsafeSetQueryHistoricMoment(new Date(e)))}_initStreamMessenger(){null==this._streamMessenger&&(this._streamMessenger=new c(this._connection))}async normalizeOverrides(e){const t={historicMoment:e.historicMoment,commands:{updateWeak:e.commands.updateWeak.map(n.fromJSON),removeWeak:e.commands.removeWeak,update:e.commands.update.map(n.fromJSON),remove:e.commands.remove,release:e.commands.release}},s=e.commands.updateByIdWeak,r=await this._queryOptimizedFeatures(s);return t.commands.updateWeak.push(...r),t}async _queryOptimizedFeatures(e){if(0===e.length)return[];const t=[],s=(await this._strategy.queryByObjectId(e)).getCursor();for(;s.next();)t.push(s.readOptimizedFeatureWorldSpace());return t}getObjectIdsFromGlobalIds(e){const t=new Set(e),s=this.metadata.globalIdField;if(null==s)throw new Error("InternalError: Recieved an edit with globalIds, but not supported by the service");const r=[];return this._store.forEachUnsafe((e=>{const a=e.readAttribute(s);if(t.has(a)){const t=e.getObjectId();null!=t&&r.push(t)}})),r}async _queryLastEditDateChanged(){if(null==this._lastEditDate)return!1;const t=this.service.source,s={...t.query,f:"json"},r=(await e(t.path,{query:s,responseType:"json"})).data.editingInfo.lastEditDate;return r!==this._lastEditDate&&(this._lastEditDate=r,!0)}async _createStrategy(){const e="isSourceHosted"in this.service&&this.service.isSourceHosted,t=Array.isArray(this.service.source),s=this.service.source&&"collection"in this.service.source,r=e||t||s;if("stream"===this._schema.type){const e=new _(this.service,this._schema.mutable.dataFilter,this._store,{outSR:this.service.outSpatialReference},this.metadata);return this._streamMessenger.strategy=e,e}if("parquet"===this._schema.type){const e=this.service;return new l(e,this._metadata,this._schema,this._store)}const a=this.service,i=u.fromSchema(a,this._schema,this._metadata),n=await this._supportSnapshotMode(a,i);return n?new y(a,i,this._store,n.featureCount,this.metadata,this._connection):r?new p(a,i,this._store,this.metadata,this._connection):new m(a,i,this._store,this.metadata,this._connection)}async _updateStrategy(e){const t=await this._createStrategy();this._connection.onEvent({type:"updateStrategyStart",about:t.about});const r=!!this._strategy;this._store.clear(),this._strategy?.destroy(),this._strategy=t,has("esri-2d-update-debug")&&console.debug(`Version[${e}] FeatureSource.updateStrategy`,{strategy:t});const a=Array.from(this._subscriptions.values());if(!a.length)return void this._connection.onEvent({type:"updateStrategyEnd"});const i=Promise.all(a.map((e=>this._strategy.load(e).then((()=>this._connection.onEvent({type:"loaded",tile:e.tile.id}))).catch((t=>this._connection.onEvent({type:"error",tile:e.tile.id,error:t}))))));this._updateTracking.addPromise(i);try{r&&await i}catch(n){s(n)}this._connection.onEvent({type:"updateStrategyEnd"}),has("esri-2d-update-debug")&&console.debug(`Version[${e}] FeatureSource.updateStrategyEnd`,{strategy:t})}async _supportSnapshotMode(e,t){const{queryMetadata:s}=e,r=s.snapshotInfo;if(!r||!r.supportsSnapshotMinThreshold||!r.snapshotCountThresholds)return null;const a=e.source,i=t.createQuery();i.inner.orderByFields=[],i.inner.returnGeometry=!1;const n=(await d(a,i.inner,{query:i.customParameters})).data.count,{min:o,max:h}=r.snapshotCountThresholds;return n<=o||r.supportsSnapshotMaxThreshold&&n<h?{featureCount:n}:null}}export{S as FeatureSource};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{throwIfAborted as e}from"../../../../../../core/promiseUtils.js";import{difference as t,union as s}from"../../../../../../core/SetUtils.js";import a from"../../../../../../layers/support/FieldsIndex.js";import{ParquetFile as i}from"../../../../../../libs/parquet/parquet.js";import{ALoadStrategy as r}from"./ALoadStrategy.js";import{FeatureSnapshotSourceChunk as l}from"./chunks/FeatureSnapshotSourceChunk.js";import{FeatureSetReaderJSON as o}from"../../support/FeatureSetReaderJSON.js";import{FeatureSetReaderParquet as n}from"../../support/FeatureSetReaderParquet.js";class d extends r{constructor(e,t,s,a){super(a),this._service=e,this._metadata=t,this._schema=s,this._chunkId=0,this._files=[],this._availableFields=new Set(s.mutable.availableFields);const{geometryInfo:i}=this._service;"location"===i.type?(this._availableFields.add(i.latitudeFieldName),this._availableFields.add(i.longitudeFieldName)):this._availableFields.add(i.primaryFieldName)}destroy(){for(const e of this._files)e.destroy()}get about(){return{willQueryAllFeatures:!0,willQueryFullResolutionGeometry:!0}}async updateFields(e){await this._promise;const a=new Set(e),i=t(a,this._availableFields);this._availableFields=s(i,this._availableFields),await Promise.all(this._files.map((e=>{const t=Array.from(i).map((t=>e.metadata.getFieldIndex(t)));return e.inner.updateChunks(new Uint16Array(t))})))}async load(e){return null==this._promise&&(this._promise=this._download()),this._promise}unload(e){}async addParquetFile(e){this._insert(e)}async _insert(t){const s=await i.create(t,{geometryInfo:this._service.geometryInfo,outSpatialReference:this._service.outSpatialReference,getCustomParameters:()=>this._schema.mutable.dataFilter.customParameters}),{geometryInfo:r}=this._service;e(this._options);const{fields:o,timeZoneByFieldName:d}=this._service.metadata.fieldsIndex,m=o.map((e=>({...e,index:s.metadata.getFieldIndex(e.name)}))),h=a.fromJSON({fields:m,timeZoneByFieldName:d}),u=new Uint16Array(Array.from(this._availableFields.values()).map((e=>h.get(e)?.index)));await s.inner.readChunksWithCallback(u,(e=>{const t=this._chunkId++,s=new n(this._metadata,h,r,e,t),a=new l(s,null,t,!1);this._store.insert(a)})),this._files.push(s)}async _download(){try{await Promise.all(this._service.source.urls.map((e=>this._insert(e))));const e=new l(o.empty(this._metadata),null,-1,!0);this._store.insert(e)}catch(e){throw console.error(e),e}}}export{d as ParquetLoadStrategy};
5
+ import{throwIfAborted as e}from"../../../../../../core/promiseUtils.js";import{difference as t,union as s}from"../../../../../../core/SetUtils.js";import i from"../../../../../../layers/support/FieldsIndex.js";import{ParquetFile as a}from"../../../../../../libs/parquet/parquet.js";import{ALoadStrategy as r}from"./ALoadStrategy.js";import{FeatureSnapshotSourceChunk as l}from"./chunks/FeatureSnapshotSourceChunk.js";import{FeatureSetReaderJSON as o}from"../../support/FeatureSetReaderJSON.js";import{FeatureSetReaderParquet as n}from"../../support/FeatureSetReaderParquet.js";class m extends r{constructor(e,t,s,i){super(i),this._service=e,this._metadata=t,this._schema=s,this._chunkId=0,this._files=[],this._availableFields=new Set(s.mutable.availableFields);const{geometryInfo:a}=this._service;if("location"===a.type)this._availableFields.add(a.latitudeFieldName),this._availableFields.add(a.longitudeFieldName);else if(null!=a.multiscale&&a.multiscale.levels.length>=1){const e=a.multiscale.levels[0];this._availableFields.add(e.column)}else this._availableFields.add(a.primaryFieldName)}destroy(){for(const e of this._files)e.destroy()}get about(){return{willQueryAllFeatures:!0,willQueryFullResolutionGeometry:!0}}async updateFields(e){await this._promise;const i=new Set(e),a=t(i,this._availableFields);this._availableFields=s(a,this._availableFields),a.size&&await Promise.all(this._files.map((e=>{const t=Array.from(a).map((t=>e.metadata.getFieldIndex(t)));return e.inner.updateChunks(new Uint16Array(t))})))}async load(e){return null==this._promise&&(this._promise=this._download().then((()=>{this._loadHigherResGeometry()}))),this._promise}unload(e){}async addParquetFile(e){this._insert(e)}async _loadHigherResGeometry(){const{geometryInfo:e}=this._service;if("geometry"===e.type){if(!(null!=e.multiscale&&e.multiscale.levels.length>=1))return;await this.updateFields([e.primaryFieldName])}const t=Array.from(this._store.chunks());this._store.clear();for(const s of t)this._store.insert(s);this._store.refresh()}async _insert(t){const s=await a.create(t,{geometryInfo:this._service.geometryInfo,outSpatialReference:this._service.outSpatialReference,getCustomParameters:()=>this._schema.mutable.dataFilter.customParameters}),{geometryInfo:r}=this._service;e(this._options);const{fields:o,timeZoneByFieldName:m}=this._service.metadata.fieldsIndex,d=o.map((e=>({...e,index:s.metadata.getFieldIndex(e.name)}))),h=i.fromJSON({fields:d,timeZoneByFieldName:m}),u=new Uint16Array(Array.from(this._availableFields.values()).map((e=>h.get(e)?.index)));await s.inner.readChunksWithCallback(u,(e=>{const t=this._chunkId++,s=new n(this._metadata,h,r,e,t),i=new l(s,null,t,!1);this._store.insert(i)})),this._files.push(s)}async _download(){try{await Promise.all(this._service.source.urls.map((e=>this._insert(e))));const e=new l(o.empty(this._metadata),null,-1,!0);this._store.insert(e)}catch(e){throw console.error(e),e}}}export{m as ParquetLoadStrategy};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import e from"../../../../../../../core/Evented.js";import has from"../../../../../../../core/has.js";import{create as s}from"../../../../../../../geometry/support/aaBoundingBox.js";import{FeatureStoreQueryAdapter as t}from"../../../FeatureStoreQueryAdapter.js";import{OverrideState as o}from"./Overrides.js";class r{constructor(s,r){this._onChange=s,this._metadata=r,this._chunks=new Map,this._chunksToRemove=[],this._overrides=new o,this.events=new e,this.featureAdapter=new t}destroy(){this.clear()}clear(){for(const e of this._chunks.values())this._chunksToRemove.push(e);this._chunks.clear()}*chunks(){this._overrides&&(yield this._overrides.asChunk(this._metadata)),yield*this._chunks.values()}insert(e){has("esri-2d-update-debug")&&console.debug(`Chunk[${e.chunkId}] SourceChunkStore.insert`),this._overrides.onChunkInsert(e),this._chunks.set(e.chunkId,e),this.events.emit("changed"),this._onChange()}remove(e){has("esri-2d-update-debug")&&console.debug(`Chunk[${e.chunkId}] SourceChunkStore.remove`),this._chunks.delete(e.chunkId),this._chunksToRemove.push(e)}cleanupRemovedChunks(){const e=this._chunksToRemove;return this._chunksToRemove=[],e}applyOverride(e){this._overrides.apply(e,this),this.events.emit("changed");for(const s of this._chunks.values())s.invalidate()}takeOverrideUpdate(){return this._overrides.takeOverrideUpdate()}forEach(e){const s=new Set;for(const t of this.chunks()){const o=t.reader.getCursor();for(;o.next();){const t=o.getObjectId();s.has(t)||(e(o.copy()),s.add(t))}}}forEachUnsafe(e){const s=new Set;for(const t of this.chunks()){const o=t.reader.getCursor();for(;o.next();){const t=o.getObjectId();s.has(t)||(e(o),s.add(t))}}}forEachInBounds(e,s){const t=new Set;for(const o of this.chunks()){const r=o.queryFeaturesInBounds(e);for(;r.next();){const e=r.getObjectId();t.has(e)||(s(r.copy()),t.add(e))}}}forEachBounds(e,t){const o=s();for(const s of e){s.getBounds(o)&&t(o)}}}export{r as FeatureSourceChunkStore};
5
+ import e from"../../../../../../../core/Evented.js";import has from"../../../../../../../core/has.js";import{create as s}from"../../../../../../../geometry/support/aaBoundingBox.js";import{FeatureStoreQueryAdapter as t}from"../../../FeatureStoreQueryAdapter.js";import{OverrideState as o}from"./Overrides.js";class r{constructor(s){this._metadata=s,this._chunks=new Map,this._chunksToRemove=[],this._overrides=new o,this.events=new e,this.featureAdapter=new t}destroy(){this.clear()}clear(){for(const e of this._chunks.values())this._chunksToRemove.push(e);this._chunks.clear()}*chunks(){this._overrides&&(yield this._overrides.asChunk(this._metadata)),yield*this._chunks.values()}insert(e){has("esri-2d-update-debug")&&console.debug(`Chunk[${e.chunkId}] SourceChunkStore.insert`),this._overrides.onChunkInsert(e),this._chunks.set(e.chunkId,e),this.events.emit("changed")}remove(e){has("esri-2d-update-debug")&&console.debug(`Chunk[${e.chunkId}] SourceChunkStore.remove`),this._chunks.delete(e.chunkId),this._chunksToRemove.push(e)}cleanupRemovedChunks(){const e=this._chunksToRemove;return this._chunksToRemove=[],e}applyOverride(e){this._overrides.apply(e,this),this.events.emit("changed");for(const s of this._chunks.values())s.invalidate()}takeOverrideUpdate(){return this._overrides.takeOverrideUpdate()}refresh(){this.events.emit("refresh")}forEach(e){const s=new Set;for(const t of this.chunks()){const o=t.reader.getCursor();for(;o.next();){const t=o.getObjectId();s.has(t)||(e(o.copy()),s.add(t))}}}forEachUnsafe(e){const s=new Set;for(const t of this.chunks()){const o=t.reader.getCursor();for(;o.next();){const t=o.getObjectId();s.has(t)||(e(o),s.add(t))}}}forEachInBounds(e,s){const t=new Set;for(const o of this.chunks()){const r=o.queryFeaturesInBounds(e);for(;r.next();){const e=r.getObjectId();t.has(e)||(s(r.copy()),t.add(e))}}}forEachBounds(e,t){const o=s();for(const s of e){s.getBounds(o)&&t(o)}}}export{r as FeatureSourceChunkStore};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import t from"../../../../../Color.js";import{multiplyOpacityToUnitRGBA as e,colorEquals as i,getContrast as s}from"../../../../../core/colorUtils.js";import a from"../../../../../core/Handles.js";import"../../../../../core/has.js";import{destroyMaybe as r}from"../../../../../core/maybe.js";import{watch as o,sync as n}from"../../../../../core/reactiveUtils.js";import{screenPointObjectToArray as l}from"../../../../../core/screenUtils.js";import{create as h}from"../../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import _ from"../../../../../geometry/Point.js";import{Manipulator3D as u}from"../../Manipulator3D.js";import{createManipulatorMaterial as p}from"../../manipulatorUtils.js";import{RenderObject as c}from"../../RenderObject.js";import{PickResult as d}from"../support/PickRequest.js";import{LaserlineVisualElement as m}from"../../visualElements/LaserlineVisualElement.js";import{createSphereGeometry as w}from"../../../webgl-engine/lib/GeometryUtil.js";import{ManipulatorCollection as v}from"../../../../interactive/ManipulatorCollection.js";import{newToolIntersector as g}from"../../../../interactive/ToolIntersector.js";class y{constructor(t){this.vertexManipulators=[],this._destroyed=!1,this._isManipulatorsOwner=!0,this._visible=!0,this._listenerHandles=null,this._tempHandlePosition=h();const{analysisViewData:e,manipulators:i,toolState:s,view:a,visible:r}=t;this._analysisViewData=e,this._toolState=s,null!=i?(this._manipulators=i,this._isManipulatorsOwner=!1):this._manipulators=new v,this._view=a,this._intersector=g(a.state.viewingMode);const o=p(this._handleColor),n=[new c(w(o,1,32,32))],l=new u({view:a,renderObjects:n});l.available=!1,l.radius=D,l.interactive=!1,this._manipulators.add(l),this._cursorManipulator=l,this._cursorManipulatorMaterial=o,this._laserLine=new m({view:a,attached:!0,style:{glowWidth:V,glowFalloff:M,innerWidth:b},isDecoration:!0}),this._updateVisibility(r??!0)}destroy(){this._listenerHandles=r(this._listenerHandles),this._isManipulatorsOwner?this._manipulators=r(this._manipulators):this._manipulators=null,this._laserLine=r(this._laserLine),this._destroyed=!0}get destroyed(){return this._destroyed}get visible(){return this._visible}set visible(t){t?this.show():this.hide()}get testData(){}show(){this._setVisibility(!0)}hide(){this._setVisibility(!1)}_setVisibility(t){this._destroyed||this._visible===t||this._updateVisibility(t)}_updateVisibility(t){this._visible=t,this._laserLine.visible=t,t?(this._initializeListeners(),this._updateAll()):(this._destroyListeners(),this.vertexManipulators.forEach((({manipulator:t})=>this._removeVertexManipulator(t))),this.vertexManipulators=[],this._view.cursor=null)}vertexHandleAt(t,e){const i=this._manipulators.intersect(t,e);return i?.metadata}pick(t){const e=this._view.spatialReference,i=l(t.screenPoint);this._view.sceneIntersectionHelper.intersectToolIntersectorScreen(i,this._intersector);const s=this._intersector.results.min,a=h();if(!s.getIntersectionPoint(a))return null;const r=this._view.renderCoordsHelper.fromRenderCoords(a,new _({spatialReference:e}));return null==r?null:new d(a,r)}_updateAll(){this._visible&&(this._updateVertexManipulators(),this._updateLaserLine())}_createVertexManipulator(){const t=p(this._handleColor),e=[new c(w(t,1,32,32))],i=new u({view:this._view,renderObjects:e});return i.radius=D,this._manipulators.add(i),{manipulator:i,material:t}}_removeVertexManipulator(t){this._manipulators.remove(t)}_updateVertexManipulators(){const{viewData:t}=this._analysisViewData,e=this._analysisViewData.path?this._analysisViewData.path.vertices:[],i=this.vertexManipulators;f(i,e.length,(()=>this._createVertexManipulator()),(({manipulator:t})=>this._removeVertexManipulator(t))),i.forEach((({manipulator:i},s)=>{i.metadata=e[s],i.renderLocation=t.positionsRender[s],i.cursor=0===s&&"drawing"===this._toolState.polygonState?"crosshair":null})),"drawing"===this._toolState.polygonState&&null!=this._analysisViewData.stagedPoint?(this._cursorManipulator.available=!0,this._cursorManipulator.location=this._analysisViewData.stagedPoint):this._cursorManipulator.available=!1}get _handleColor(){return e(this._view.effectiveTheme.accentColor,.5)}_getFocusPoint(){const{lastDraggedVertex:t}=this._analysisViewData;switch(this._toolState.polygonState){case"drawing":return null!=this._analysisViewData.stagedPoint?this._analysisViewData.stagedPoint:null!=t?this._analysisViewData.path.getVertexPositionAsPoint(t):this._analysisViewData.path.lastPoint;case"editing":return null!=t?this._analysisViewData.path.getVertexPositionAsPoint(t):null;default:return this._analysisViewData.stagedPoint}}_updateLaserLine(){const t="measured"!==this._toolState.polygonState&&this._toolState.active,e=this._getFocusPoint();if(t&&null!=e){const t=this._tempHandlePosition;this._view.renderCoordsHelper.toRenderCoords(e,t),this._laserLine.heightManifoldTarget=t}else this._laserLine.heightManifoldTarget=null}_initializeListeners(){this._listenerHandles=new a,this._listenerHandles.add([o((()=>this._toolState.polygonState),(()=>this._updateLaserLine())),o((()=>this._analysisViewData.viewData),(()=>this._updateAll()),n),o((()=>({lastDraggedVertex:this._analysisViewData.lastDraggedVertex,cursorPoint:this._analysisViewData.stagedPoint})),(()=>this._updateLaserLine())),o((()=>this._toolState.active),(()=>this._updateAll())),o((()=>this._view.effectiveTheme.accentColor),(i=>{const a=e(i,.5);for(const{material:t}of this.vertexManipulators)t.setParameters({color:a});this._cursorManipulatorMaterial.setParameters({color:a});const r=t.toUnitRGB(i),o=t.toUnitRGB(s(i)),n=.75*i.a,l=this._laserLine,h=l.style;l.style={...h,glowColor:r,innerColor:o,globalAlpha:n}}),{initial:!0,equals:i})])}_destroyListeners(){this._listenerHandles=r(this._listenerHandles)}}function f(t,e,i,s){for(;t.length<e;)t.push(i());if(s)for(;t.length>e;){s(t.pop())}else t.length=e}const V=8,M=8,b=1,D=5;export{y as default};
5
+ import t from"../../../../../Color.js";import{multiplyOpacityToUnitRGBA as e,colorEquals as i,getContrast as s}from"../../../../../core/colorUtils.js";import a from"../../../../../core/Handles.js";import"../../../../../core/has.js";import{destroyMaybe as r}from"../../../../../core/maybe.js";import{watch as o,sync as n}from"../../../../../core/reactiveUtils.js";import{screenPointObjectToArray as l}from"../../../../../core/screenUtils.js";import{create as h}from"../../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import _ from"../../../../../geometry/Point.js";import{Manipulator3D as u}from"../../Manipulator3D.js";import{createManipulatorMaterial as p}from"../../manipulatorUtils.js";import{RenderObject as c}from"../../RenderObject.js";import{PickResult as d}from"../support/PickRequest.js";import{LaserlineVisualElement as m}from"../../visualElements/LaserlineVisualElement.js";import{createSphereGeometry as w}from"../../../webgl-engine/lib/GeometryUtil.js";import{ManipulatorCollection as v}from"../../../../interactive/ManipulatorCollection.js";import{newToolIntersector as g}from"../../../../interactive/ToolIntersector.js";class y{constructor(t){this.vertexManipulators=[],this._destroyed=!1,this._isManipulatorsOwner=!0,this._visible=!0,this._listenerHandles=null,this._tempHandlePosition=h();const{analysisViewData:e,manipulators:i,toolState:s,view:a,visible:r}=t;this._analysisViewData=e,this._toolState=s,null!=i?(this._manipulators=i,this._isManipulatorsOwner=!1):this._manipulators=new v,this._view=a,this._intersector=g(a.state.viewingMode);const o=p(this._handleColor),n=[new c(w(o,1,32,32))],l=new u({view:a,renderObjects:n});l.available=!1,l.radius=D,l.interactive=!1,this._manipulators.add(l),this._cursorManipulator=l,this._cursorManipulatorMaterial=o,this._laserLine=new m({view:a,attached:!0,style:{glowWidth:V,glowFalloff:M,innerWidth:b},isDecoration:!0}),this._updateVisibility(r??!0)}destroy(){this._listenerHandles=r(this._listenerHandles),this._isManipulatorsOwner?this._manipulators=r(this._manipulators):this._manipulators=null,this._laserLine=r(this._laserLine),this._destroyed=!0}get destroyed(){return this._destroyed}get visible(){return this._visible}set visible(t){t?this.show():this.hide()}get testData(){}show(){this._setVisibility(!0)}hide(){this._setVisibility(!1)}_setVisibility(t){this._destroyed||this._visible===t||this._updateVisibility(t)}_updateVisibility(t){this._visible=t,this._laserLine.visible=t,t?(this._initializeListeners(),this._updateAll()):(this._destroyListeners(),this.vertexManipulators.forEach((({manipulator:t})=>this._removeVertexManipulator(t))),this.vertexManipulators=[],this._view.cursor=null)}vertexHandleAt(t,e){const i=this._manipulators.intersect(t,e);return i?.metadata}pick(t){const e=this._view.spatialReference,i=l(t.screenPoint);this._view.sceneIntersectionHelper.intersectToolIntersectorScreen(i,this._intersector);const s=this._intersector.results.min,a=h();if(!s.getIntersectionPoint(a))return null;const r=this._view.renderCoordsHelper.fromRenderCoords(a,new _({spatialReference:e}));return null==r?null:new d(a,r)}_updateAll(){this._visible&&(this._updateVertexManipulators(),this._updateLaserLine())}_createVertexManipulator(){const t=p(this._handleColor),e=[new c(w(t,1,32,32))],i=new u({view:this._view,renderObjects:e});return i.radius=D,this._manipulators.add(i),{manipulator:i,material:t}}_removeVertexManipulator(t){this._manipulators.remove(t)}_updateVertexManipulators(){const{viewData:t}=this._analysisViewData,e=this._analysisViewData.path?this._analysisViewData.path.vertices:[],i=this.vertexManipulators;f(i,e.length,(()=>this._createVertexManipulator()),(({manipulator:t})=>this._removeVertexManipulator(t))),i.forEach((({manipulator:i},s)=>{i.metadata=e[s],i.renderLocation=t.positionsRender[s],i.cursor=0===s&&"drawing"===this._toolState.polygonState?"crosshair":null})),"drawing"===this._toolState.polygonState&&null!=this._analysisViewData.stagedPoint?(this._cursorManipulator.available=!0,this._cursorManipulator.location=this._analysisViewData.stagedPoint):this._cursorManipulator.available=!1}get _handleColor(){return e(this._view.effectiveTheme.accentColor,.5)}_getFocusPoint(){const{lastDraggedVertex:t}=this._analysisViewData;switch(this._toolState.polygonState){case"drawing":return null!=this._analysisViewData.stagedPoint?this._analysisViewData.stagedPoint:null!=t?this._analysisViewData.path.getVertexPositionAsPoint(t):this._analysisViewData.path.lastPoint;case"editing":return null!=t?this._analysisViewData.path.getVertexPositionAsPoint(t):null;default:return this._analysisViewData.stagedPoint}}_updateLaserLine(){const t="measured"!==this._toolState.polygonState&&this._toolState.active,e=this._getFocusPoint();if(t&&null!=e){const t=this._tempHandlePosition;this._view.renderCoordsHelper.toRenderCoords(e,t),this._laserLine.heightManifoldTarget=t}else this._laserLine.heightManifoldTarget=null}_initializeListeners(){this._listenerHandles=new a,this._listenerHandles.add([o((()=>this._toolState.polygonState),(()=>this._updateLaserLine())),o((()=>this._analysisViewData.viewData),(()=>this._updateAll()),n),o((()=>({lastDraggedVertex:this._analysisViewData.lastDraggedVertex,cursorPoint:this._analysisViewData.stagedPoint})),(()=>this._updateLaserLine())),o((()=>this._toolState.active),(()=>this._updateAll())),o((()=>this._view.effectiveTheme.accentColor),(i=>{const a=e(i,.5);for(const{material:t}of this.vertexManipulators)t.setParameters({color:a});this._cursorManipulatorMaterial.setParameters({color:a});const r=t.toUnitRGB(i),o=t.toUnitRGB(s(i)),n=.75*i.a,l=this._laserLine,h=l.style;l.style={...h,glowColor:r,innerColor:o,globalAlpha:n}}),{initial:!0,equals:i})])}_destroyListeners(){this._listenerHandles=r(this._listenerHandles)}}function f(t,e,i,s){for(;t.length<e;)t.push(i());for(;t.length>e;){s(t.pop())}}const V=8,M=8,b=1,D=5;export{y as default};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import has from"../../../core/has.js";import{Milliseconds as e}from"../../../core/time.js";class a{static isValidProfile(e){return e in a.profiles}static getDefaultProfile(){return has("esri-iPhone")?"low":"medium"}static apply(e,i){const o=a.profiles[e];i.graphics3D.maxTotalNumberOfFeatures=o.graphics3D.maxTotalNumberOfFeatures,i.graphics3D.maxNumberOfDrawCalls=o.graphics3D.maxNumberOfDrawCalls,i.graphics3D.maxTotalNumberOfVertices=o.graphics3D.maxTotalNumberOfVertices,i.graphics3D.polygonLodFactor=o.graphics3D.polygonLodFactor,i.graphics3D.polylineLodFactor=o.graphics3D.polylineLodFactor,i.graphics3D.snapshotAvailable=o.graphics3D.snapshotAvailable,i.graphics3D.skipHighSymbolLods=o.graphics3D.skipHighSymbolLods,i.graphics3D.uncompressedTextureDownsamplingEnabled=o.graphics3D.uncompressedTextureDownsamplingEnabled;const l=i.sceneService.object,t=o.sceneService.object;l.lodFactor=t.lodFactor,i.sceneService.point.lodFactor=o.sceneService.point.lodFactor,i.sceneService.integratedMesh.lodFactor=o.sceneService.integratedMesh.lodFactor,i.sceneService.pointCloud.lodFactor=o.sceneService.pointCloud.lodFactor,i.sceneService.uncompressedTextureDownsamplingEnabled=o.sceneService.uncompressedTextureDownsamplingEnabled,i.tiledSurface.lodBias=o.tiledSurface.lodBias,i.tiledSurface.angledSplitBias=o.tiledSurface.angledSplitBias,i.tiledSurface.vtlContentZoom=o.tiledSurface.vtlContentZoom,i.tiledSurface.elevationLevelDelta=o.tiledSurface.elevationLevelDelta,i.tiledSurface.reduceTileLevelDifferences=o.tiledSurface.reduceTileLevelDifferences,i.heatmap.pixelRatio=o.heatmap.pixelRatio,i.heatmap.maxTotalNumberOfFeatures=o.heatmap.maxTotalNumberOfFeatures,i.fadeDuration=o.fadeDuration,i.antialiasingEnabled=o.antialiasingEnabled,i.physicallyBasedRenderingEnabled=o.physicalBasedRenderingEnabled,i.highQualityTransparency=o.highQualityTransparency,i.highResolutionAtmosphere=o.highResolutionAtmosphere,i.reflections=o.reflections,i.ambientOcclusion=o.ambientOcclusion,i.memoryLimit=o.memoryLimit,i.additionalCacheMemory=o.additionalCacheMemory,i.frameRate=o.frameRate,i.maximumPixelRatio=o.maximumPixelRatio}}a.test={reset(){const e=o();for(const i of Object.keys(e))a.profiles[i]=e[i]}};const i={IPhone12Pro:120,GalaxyS20:200,FullHD:240,SurfacePro7:300,FullHDRetina:430};function o(){const a=!!has("esri-mobile"),o=!!has("ios"),l=e(400);return{low:{graphics3D:{maxTotalNumberOfFeatures:25e3,maxNumberOfDrawCalls:8e3,maxTotalNumberOfVertices:255e4,polygonLodFactor:.5,polylineLodFactor:1,snapshotAvailable:!1,skipHighSymbolLods:!0,uncompressedTextureDownsamplingEnabled:!0},heatmap:{pixelRatio:.125,maxTotalNumberOfFeatures:5e4},sceneService:{object:{lodFactor:.2},point:{lodFactor:1},integratedMesh:{lodFactor:.6},pointCloud:{lodFactor:.5},uncompressedTextureDownsamplingEnabled:!0},tiledSurface:{lodBias:-1,angledSplitBias:.5,vtlContentZoom:.75,elevationLevelDelta:3,reduceTileLevelDifferences:!0},fadeDuration:e(0),antialiasingEnabled:!1,physicalBasedRenderingEnabled:!1,highQualityTransparency:!1,highResolutionAtmosphere:!1,reflections:!1,ambientOcclusion:!1,memoryLimit:200+i.IPhone12Pro,additionalCacheMemory:0,frameRate:0,maximumPixelRatio:1},medium:{graphics3D:{maxTotalNumberOfFeatures:1e5,maxNumberOfDrawCalls:17e3,maxTotalNumberOfVertices:625e4,polygonLodFactor:a?.8:1,polylineLodFactor:a?1.2:1.5,snapshotAvailable:!o,skipHighSymbolLods:!1,uncompressedTextureDownsamplingEnabled:a},heatmap:{pixelRatio:.25,maxTotalNumberOfFeatures:13e4},sceneService:{object:{lodFactor:1},point:{lodFactor:1},integratedMesh:{lodFactor:1},pointCloud:{lodFactor:1},uncompressedTextureDownsamplingEnabled:a},tiledSurface:{lodBias:0,angledSplitBias:1,vtlContentZoom:1.5,elevationLevelDelta:3,reduceTileLevelDifferences:!has("disable-feature:reduce-map-tile-levels")},fadeDuration:l,antialiasingEnabled:!1,physicalBasedRenderingEnabled:!0,highQualityTransparency:!0,highResolutionAtmosphere:!1,reflections:!1,ambientOcclusion:!1,memoryLimit:a?600+i.GalaxyS20:750+i.FullHD,additionalCacheMemory:a?-100:150,frameRate:0,maximumPixelRatio:1},high:{graphics3D:{maxTotalNumberOfFeatures:1e5,maxNumberOfDrawCalls:17e3,maxTotalNumberOfVertices:125e5,polygonLodFactor:a?1.2:2,polylineLodFactor:a?1.2:2,snapshotAvailable:!o,skipHighSymbolLods:!1,uncompressedTextureDownsamplingEnabled:!1},heatmap:{pixelRatio:.5,maxTotalNumberOfFeatures:23e4},sceneService:{object:{lodFactor:1},point:{lodFactor:1},integratedMesh:{lodFactor:1},pointCloud:{lodFactor:1},uncompressedTextureDownsamplingEnabled:!1},tiledSurface:{lodBias:0,angledSplitBias:1,vtlContentZoom:1.5,elevationLevelDelta:2,reduceTileLevelDifferences:!has("disable-feature:reduce-map-tile-levels")},fadeDuration:l,antialiasingEnabled:!0,physicalBasedRenderingEnabled:!0,highQualityTransparency:!0,highResolutionAtmosphere:!0,reflections:!0,ambientOcclusion:!0,memoryLimit:a?900+i.SurfacePro7:1500+i.FullHDRetina,additionalCacheMemory:a?-150:0,frameRate:0,maximumPixelRatio:a?1:1/0}}}!function(e){e.profiles=o()}(a||(a={}));const l=a;export{l as default};
5
+ import has from"../../../core/has.js";import{Milliseconds as e}from"../../../core/time.js";class a{static isValidProfile(e){return e in a.profiles}static getDefaultProfile(){return has("esri-iPhone")?"low":"medium"}static apply(e,i){const o=a.profiles[e];i.graphics3D.maxTotalNumberOfFeatures=o.graphics3D.maxTotalNumberOfFeatures,i.graphics3D.maxNumberOfDrawCalls=o.graphics3D.maxNumberOfDrawCalls,i.graphics3D.maxTotalNumberOfVertices=o.graphics3D.maxTotalNumberOfVertices,i.graphics3D.polygonLodFactor=o.graphics3D.polygonLodFactor,i.graphics3D.polylineLodFactor=o.graphics3D.polylineLodFactor,i.graphics3D.snapshotAvailable=o.graphics3D.snapshotAvailable,i.graphics3D.skipHighSymbolLods=o.graphics3D.skipHighSymbolLods,i.graphics3D.uncompressedTextureDownsamplingEnabled=o.graphics3D.uncompressedTextureDownsamplingEnabled;const l=i.sceneService.object,t=o.sceneService.object;l.lodFactor=t.lodFactor,i.sceneService.point.lodFactor=o.sceneService.point.lodFactor,i.sceneService.integratedMesh.lodFactor=o.sceneService.integratedMesh.lodFactor,i.sceneService.pointCloud.lodFactor=o.sceneService.pointCloud.lodFactor,i.sceneService.uncompressedTextureDownsamplingEnabled=o.sceneService.uncompressedTextureDownsamplingEnabled,i.tiledSurface.lodBias=o.tiledSurface.lodBias,i.tiledSurface.angledSplitBias=o.tiledSurface.angledSplitBias,i.tiledSurface.vtlContentZoom=o.tiledSurface.vtlContentZoom,i.tiledSurface.elevationLevelDelta=o.tiledSurface.elevationLevelDelta,i.tiledSurface.reduceTileLevelDifferences=o.tiledSurface.reduceTileLevelDifferences,i.heatmap.pixelRatio=o.heatmap.pixelRatio,i.heatmap.maxTotalNumberOfFeatures=o.heatmap.maxTotalNumberOfFeatures,i.fadeDuration=o.fadeDuration,i.antialiasingEnabled=o.antialiasingEnabled,i.physicallyBasedRenderingEnabled=o.physicalBasedRenderingEnabled,i.highQualityTransparency=o.highQualityTransparency,i.highResolutionAtmosphere=o.highResolutionAtmosphere,i.reflections=o.reflections,i.ambientOcclusion=o.ambientOcclusion,i.memoryLimit=o.memoryLimit,i.additionalCacheMemory=o.additionalCacheMemory,i.frameRate=o.frameRate,i.maximumPixelRatio=o.maximumPixelRatio}}a.test={reset(){const e=o();for(const i of Object.keys(e))a.profiles[i]=e[i]}};const i={IPhone12Pro:120,GalaxyS20:200,FullHD:240,SurfacePro7:300,FullHDRetina:430};function o(){const a=!!has("esri-mobile"),o=!!has("ios"),l=e(400);return{low:{graphics3D:{maxTotalNumberOfFeatures:25e3,maxNumberOfDrawCalls:8e3,maxTotalNumberOfVertices:255e4,polygonLodFactor:.5,polylineLodFactor:1,snapshotAvailable:!1,skipHighSymbolLods:!0,uncompressedTextureDownsamplingEnabled:!0},heatmap:{pixelRatio:.125,maxTotalNumberOfFeatures:5e4},sceneService:{object:{lodFactor:.2},point:{lodFactor:1},integratedMesh:{lodFactor:.6},pointCloud:{lodFactor:.5},uncompressedTextureDownsamplingEnabled:!0},tiledSurface:{lodBias:-1,angledSplitBias:.5,vtlContentZoom:.75,elevationLevelDelta:3,reduceTileLevelDifferences:!0},fadeDuration:e(0),antialiasingEnabled:!1,physicalBasedRenderingEnabled:!1,highQualityTransparency:!1,highResolutionAtmosphere:!1,reflections:!1,ambientOcclusion:!1,memoryLimit:200+i.IPhone12Pro,additionalCacheMemory:0,frameRate:0,maximumPixelRatio:1},medium:{graphics3D:{maxTotalNumberOfFeatures:1e5,maxNumberOfDrawCalls:17e3,maxTotalNumberOfVertices:625e4,polygonLodFactor:a?.8:1,polylineLodFactor:a?1.2:1.5,snapshotAvailable:!o,skipHighSymbolLods:!1,uncompressedTextureDownsamplingEnabled:a},heatmap:{pixelRatio:.25,maxTotalNumberOfFeatures:13e4},sceneService:{object:{lodFactor:1},point:{lodFactor:1},integratedMesh:{lodFactor:1},pointCloud:{lodFactor:1},uncompressedTextureDownsamplingEnabled:a},tiledSurface:{lodBias:0,angledSplitBias:1,vtlContentZoom:1.5,elevationLevelDelta:3,reduceTileLevelDifferences:!has("disable-feature:reduce-map-tile-levels")},fadeDuration:l,antialiasingEnabled:!1,physicalBasedRenderingEnabled:!0,highQualityTransparency:!0,highResolutionAtmosphere:!1,reflections:!1,ambientOcclusion:!1,memoryLimit:a?600+i.GalaxyS20:750+i.FullHD,additionalCacheMemory:a?-100:150,frameRate:0,maximumPixelRatio:1},high:{graphics3D:{maxTotalNumberOfFeatures:1e5,maxNumberOfDrawCalls:17e3,maxTotalNumberOfVertices:125e5,polygonLodFactor:a?1.2:2,polylineLodFactor:a?1.2:2,snapshotAvailable:!o,skipHighSymbolLods:!1,uncompressedTextureDownsamplingEnabled:!1},heatmap:{pixelRatio:.5,maxTotalNumberOfFeatures:23e4},sceneService:{object:{lodFactor:1},point:{lodFactor:1},integratedMesh:{lodFactor:1},pointCloud:{lodFactor:1},uncompressedTextureDownsamplingEnabled:!1},tiledSurface:{lodBias:0,angledSplitBias:1,vtlContentZoom:1.5,elevationLevelDelta:2,reduceTileLevelDifferences:!has("disable-feature:reduce-map-tile-levels")},fadeDuration:l,antialiasingEnabled:!0,physicalBasedRenderingEnabled:!0,highQualityTransparency:!0,highResolutionAtmosphere:!0,reflections:!0,ambientOcclusion:!0,memoryLimit:a?900+i.SurfacePro7:1500+i.FullHDRetina,additionalCacheMemory:a?-150:0,frameRate:0,maximumPixelRatio:a?1:1/0}}}!function(e){e.profiles=o()}(a);export{a as default};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- class n{}const t=n;function o(n,...t){let o="";for(let r=0;r<t.length;r++)o+=n[r]+t[r];return o+=n[n.length-1],o}function r(n,t,o=""){return n?t:o}!function(n){function t(n){return Math.round(n).toString()}function o(n){return n.toPrecision(8)}n.int=t,n.float=o}(o||(o={}));export{r as If,t as NoParameters,o as glsl};
5
+ class n{}const t=n;function o(n,...t){let o="";for(let r=0;r<t.length;r++)o+=n[r]+t[r];return o+=n[n.length-1],o}function r(n,t,o=""){return n?t:o}!function(n){function t(n){return Math.round(n).toString()}function o(n){return n.toPrecision(8)}n.int=t,n.float=o}(o);export{r as If,t as NoParameters,o as glsl};