@arcgis/core 5.0.0-next.7 → 5.0.0-next.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/applications/KnowledgeStudio/resourceSerializationUtils.js +1 -1
- package/assets/esri/core/workers/RemoteClient.js +1 -1
- package/assets/esri/core/workers/chunks/{8f56f298e7c1a283f407.js → 0030d68d9edf42b4af57.js} +1 -1
- package/assets/esri/core/workers/chunks/01d460398f3ba6767a37.js +1 -0
- package/assets/esri/core/workers/chunks/{17d5f8dba6ebb1184506.js → 042cd64e1f4eb326c30f.js} +1 -1
- package/assets/esri/core/workers/chunks/05429f9d292a7a714309.js +316 -0
- package/assets/esri/core/workers/chunks/{66db5f77e09d25e33951.js → 063905fbf9a0c6586949.js} +1 -1
- package/assets/esri/core/workers/chunks/{9486032af3e934d85582.js → 0a5d74414dd02a2fb8e1.js} +1 -1
- package/assets/esri/core/workers/chunks/{3815ffa13e7b439bca6e.js → 0d5212f59e9b62c16164.js} +1 -1
- package/assets/esri/core/workers/chunks/{73487b9d85e726e9c012.js → 1257c37bf04d39c27b62.js} +1 -1
- package/assets/esri/core/workers/chunks/{398f356b11fd33bd3831.js → 136a7d781dad05a7463b.js} +1 -1
- package/assets/esri/core/workers/chunks/{1e4e7aedf4b779241a02.js → 15c7c10ff9ac63f0e792.js} +1 -1
- package/assets/esri/core/workers/chunks/17784cf16fa91504b9ea.js +1 -0
- package/assets/esri/core/workers/chunks/{a395373e3173e6458a56.js → 1ab37e13947d0e2e4181.js} +1 -1
- package/assets/esri/core/workers/chunks/{f03635ddf56e2ef90e4c.js → 1d06fcae4c2f02fb1c95.js} +1 -1
- package/assets/esri/core/workers/chunks/{020c8913d8e35d63080b.js → 1d15d1b20dc10fde6def.js} +1 -1
- package/assets/esri/core/workers/chunks/1dfca37f95f2b968aa54.js +1 -0
- package/assets/esri/core/workers/chunks/20975513be0a3a1da286.js +1 -0
- package/assets/esri/core/workers/chunks/{285762ff92d5388b6024.js → 2166238a7ad63a2d43c7.js} +1 -1
- package/assets/esri/core/workers/chunks/{620a94b54be3ed78350d.js → 22ca80f491e070b2a5e7.js} +1 -1
- package/assets/esri/core/workers/chunks/{88074189fa10c335370b.js → 24cd7b84cd0f3de4bff2.js} +1 -1
- package/assets/esri/core/workers/chunks/{9fac5a12e878cd745354.js → 28020063048e644f17a5.js} +1 -1
- package/assets/esri/core/workers/chunks/{95c594a87b732f5c4979.js → 2a8dff8521e1e6a10cf6.js} +1 -1
- package/assets/esri/core/workers/chunks/{7e43c105f1cfc44b7bd0.js → 2fa01bd3f3608616fd7f.js} +1 -1
- package/assets/esri/core/workers/chunks/30e220f4f843681a4cdd.js +1 -0
- package/assets/esri/core/workers/chunks/{5d3661d1fe46dd29aae9.js → 311b564e44ae637c960d.js} +1 -1
- package/assets/esri/core/workers/chunks/31c7ce65e16f7858400f.js +1 -0
- package/assets/esri/core/workers/chunks/{8a314b3790313e6dc5db.js → 333b62dad3811cff0f14.js} +1 -1
- package/assets/esri/core/workers/chunks/36d067c8d03d7a894f5f.js +1 -0
- package/assets/esri/core/workers/chunks/{e31192ae920e3e19b6aa.js → 37c1f155da14de91565a.js} +1 -1
- package/assets/esri/core/workers/chunks/{aa54b6f2aba6952af149.js → 38cc18fd93c18815ded0.js} +1 -1
- package/assets/esri/core/workers/chunks/{c55c096669677321a227.js → 38cd3648932bf2534b0f.js} +1 -1
- package/assets/esri/core/workers/chunks/{ac26e3e77df4302f47a2.js → 3afb83f5de033dda89ec.js} +1 -1
- package/assets/esri/core/workers/chunks/{f5e47eea8720ba84665b.js → 3c07aa2015ab1dff5f7b.js} +1 -1
- package/assets/esri/core/workers/chunks/{e9311386f58f3cb95c22.js → 42a1e71d09e8583a7327.js} +1 -1
- package/assets/esri/core/workers/chunks/443dfe7029ec208f670c.js +1 -0
- package/assets/esri/core/workers/chunks/{b75930d60449eceb0f1c.js → 4baf6f6e7ddedb25f806.js} +1 -1
- package/assets/esri/core/workers/chunks/{bb5484b5eeacc9ad2ceb.js → 4d0cbf9584446f411a37.js} +1 -1
- package/assets/esri/core/workers/chunks/{17103e6542aae53c7301.js → 4e3e27673d0671fc2b58.js} +1 -1
- package/assets/esri/core/workers/chunks/{5fc7b61f467f1d60a284.js → 51ab2acac4ecc1ca9c34.js} +1 -1
- package/assets/esri/core/workers/chunks/{fc4417d1260b717a9385.js → 52282f767bd0e99ddca0.js} +1 -1
- package/assets/esri/core/workers/chunks/{fc06014fb484fc8c697e.js → 53654edd766d9b4ef750.js} +1 -1
- package/assets/esri/core/workers/chunks/{90f8b4bda28af43ea019.js → 538f509d7fc8337d37ac.js} +1 -1
- package/assets/esri/core/workers/chunks/{ed8a85efbd90241512bb.js → 588533c3abe876f20f62.js} +1 -1
- package/assets/esri/core/workers/chunks/{c8733cd621105afab2ac.js → 59d3cac32ad6dad941dc.js} +1 -1
- package/assets/esri/core/workers/chunks/{72846fb9c87c6642daf0.js → 5e2ce34def5e053913b2.js} +1 -1
- package/assets/esri/core/workers/chunks/{8c056eac35d05d9524b7.js → 5f29422a051311ef9b3c.js} +1 -1
- package/assets/esri/core/workers/chunks/5f402b3c00bc4afc77b2.js +1 -0
- package/assets/esri/core/workers/chunks/{ff35a077ac6776469805.js → 61d970ed75c2c358b1e9.js} +1 -1
- package/assets/esri/core/workers/chunks/{7a6a96edc892d7060b7d.js → 629127877042ad784ad2.js} +1 -1
- package/assets/esri/core/workers/chunks/{fd2efd1d1cf9d95a87e6.js → 63a6f3e70d2b6ea57e40.js} +1 -1
- package/assets/esri/core/workers/chunks/{90b2b43b8b54c9a1ec35.js → 664ae441617afe4b17ec.js} +1 -1
- package/assets/esri/core/workers/chunks/{c4e4da69969499a89a2c.js → 695cdef5057e5461078a.js} +1 -1
- package/assets/esri/core/workers/chunks/{4c5a7249a311070d8f43.js → 6af18d7a0d314d7c1756.js} +1 -1
- package/assets/esri/core/workers/chunks/{f35aaa04cca676c2d3f8.js → 6b59f94040c7d2f6728a.js} +1 -1
- package/assets/esri/core/workers/chunks/{811d4c46c75cf6a63e78.js → 6bb7dbc46787b8e34bd9.js} +1 -1
- package/assets/esri/core/workers/chunks/6d9f2b113d6bde936a04.js +1 -0
- package/assets/esri/core/workers/chunks/{5132ca68e8c7af111a47.js → 6e22b02a9715c10578d0.js} +1 -1
- package/assets/esri/core/workers/chunks/{cd1930f08e1fc8b30b14.js → 6ee2f0f708494102a493.js} +1 -1
- package/assets/esri/core/workers/chunks/{f0e0a63962784acb4ba1.js → 6f0aec7428021e440ac9.js} +1 -1
- package/assets/esri/core/workers/chunks/{deb2854bb7d082a26f52.js → 7005d956c990a04ee8b2.js} +1 -1
- package/assets/esri/core/workers/chunks/{a3991ae8caa713d4ddcd.js → 731f7b552dde0fb325cd.js} +1 -1
- package/assets/esri/core/workers/chunks/{464d42bebb365287808d.js → 773f2c6c9d38db76dfed.js} +1 -1
- package/assets/esri/core/workers/chunks/{3f3d492f1093b7832aab.js → 7803495f8862d9025bcd.js} +1 -1
- package/assets/esri/core/workers/chunks/78694ad8229347903f41.js +1 -0
- package/assets/esri/core/workers/chunks/7e4c14d4502e3f06d94b.js +1 -0
- package/assets/esri/core/workers/chunks/{7544316a75dbd981aea6.js → 86cb097deec50b0da3f3.js} +1 -1
- package/assets/esri/core/workers/chunks/8a40ed2ee4b032822c30.js +1 -0
- package/assets/esri/core/workers/chunks/{09de8be660174a229efb.js → 8cbb28476151a37ae958.js} +1 -1
- package/assets/esri/core/workers/chunks/{62a49cfd9a2508950e9f.js → 8fedfd33c37172dba6bf.js} +1 -1
- package/assets/esri/core/workers/chunks/90cbd627d4113db3b686.js +1 -0
- package/assets/esri/core/workers/chunks/91aa1157da32f650983b.js +1 -0
- package/assets/esri/core/workers/chunks/{e7638b9ab6674bc8a18f.js → 91dfd29e2dba200eab09.js} +1 -1
- package/assets/esri/core/workers/chunks/{794748fd1edc29a621cd.js → 9698f36c143953a975d4.js} +1 -1
- package/assets/esri/core/workers/chunks/98584902c9db6faa3e4d.js +1 -0
- package/assets/esri/core/workers/chunks/9e5e05d6430712b0b1bc.js +1 -0
- package/assets/esri/core/workers/chunks/{6f4bd0ee85e7e5a74340.js → a31635a6366347dcef0f.js} +1 -1
- package/assets/esri/core/workers/chunks/a6ee40dfc471d6612f3c.js +1 -0
- package/assets/esri/core/workers/chunks/{ccc0da0e01f023c8aa1f.js → a876d6159ca120c1567e.js} +1 -1
- package/assets/esri/core/workers/chunks/{a4db5c9a90107e097df8.js → af47272aaaef0ea57e71.js} +1 -1
- package/assets/esri/core/workers/chunks/{d1fe816b6990918c13c7.js → afc13d5b842275db7dbc.js} +1 -1
- package/assets/esri/core/workers/chunks/aff8e40a641c6822af1d.js +1 -0
- package/assets/esri/core/workers/chunks/{22d6b8102e75bdef204c.js → b0365cbc3d2a41969e3b.js} +1 -1
- package/assets/esri/core/workers/chunks/{79968c183135281d2a6f.js → b3613a38178cad2ebc82.js} +1 -1
- package/assets/esri/core/workers/chunks/b548910e820d731ffe8a.js +1 -0
- package/assets/esri/core/workers/chunks/{5bd36dbf46c25bd961c8.js → b708792c84620b73c847.js} +1 -1
- package/assets/esri/core/workers/chunks/c29486c4eeb3e72effff.js +1 -0
- package/assets/esri/core/workers/chunks/{2b94623cabc6ae0f86ce.js → c37f7756d48ff9af2656.js} +1 -1
- package/assets/esri/core/workers/chunks/{1c52999a6392370844a6.js → c4090a60d149a5962179.js} +1 -1
- package/assets/esri/core/workers/chunks/{73c1d43070b4fe1e5c1e.js → c8e686efe344a33a0258.js} +1 -1
- package/assets/esri/core/workers/chunks/{6bb5158de43c4b59107f.js → c9b16fd41cd59d452522.js} +1 -1
- package/assets/esri/core/workers/chunks/ce98416437cc1a89d8ea.js +1 -0
- package/assets/esri/core/workers/chunks/{279366e6b743f9680603.js → cfff044859e6e6dcc75d.js} +1 -1
- package/assets/esri/core/workers/chunks/d07f911d40bf05fc0306.js +1 -0
- package/assets/esri/core/workers/chunks/{8833c3d168951be4bf20.js → d0d79dd3e88eecf5c314.js} +1 -1
- package/assets/esri/core/workers/chunks/{76ae1702fecc7ad7017c.js → d1e97cce5047f1791e22.js} +1 -1
- package/assets/esri/core/workers/chunks/{17acde0245ecd956306c.js → d233cc33497a663450f9.js} +1 -1
- package/assets/esri/core/workers/chunks/{36fe6b8228e622407ec2.js → d8793eead02491136841.js} +1 -1
- package/assets/esri/core/workers/chunks/{dedc4583b5f32a278124.js → d88f2fe680b8d5603ef8.js} +1 -1
- package/assets/esri/core/workers/chunks/{4d599008e1ea42321b37.js → da24ad57747714ac5eda.js} +1 -1
- package/assets/esri/core/workers/chunks/{facb3886714222772ab2.js → ddfd01bb9ba8577c3ffc.js} +1 -1
- package/assets/esri/core/workers/chunks/{50d9f69d5255af4b29bb.js → df5afa06c6deb6b40109.js} +1 -1
- package/assets/esri/core/workers/chunks/e25c4b4a03270d48f408.js +1 -0
- package/assets/esri/core/workers/chunks/e3294318daf1192b8319.js +1 -0
- package/assets/esri/core/workers/chunks/{da573ecc68e6aa8f6da9.js → e767f83f9e2de6650f80.js} +1 -1
- package/assets/esri/core/workers/chunks/e9d4cae2144974489d6e.js +1 -0
- package/assets/esri/core/workers/chunks/{91df8638b8b904e6d8c5.js → ead8d0cbcebd12dbfad7.js} +1 -1
- package/assets/esri/core/workers/chunks/{f9324e88c359c03f35aa.js → eb9c166db0db6fa60e95.js} +1 -1
- package/assets/esri/core/workers/chunks/{8ffd4710d168c2fcfd96.js → ebf23b46db56aaa88841.js} +1 -1
- package/assets/esri/core/workers/chunks/{bc241c7735e4efba734a.js → f34e3fa0c5b28531e289.js} +1 -1
- package/assets/esri/core/workers/chunks/f64037a88ab03662dc2a.js +1 -0
- package/assets/esri/core/workers/chunks/{d97fadbc69e055d183a0.js → f77f4bd6a577b92cf66f.js} +1 -1
- package/assets/esri/core/workers/chunks/{16d66770ef841564ee3f.js → f89c90f98c85667b0ebc.js} +1 -1
- package/assets/esri/core/workers/chunks/{4c4227b0ea21a5e429ab.js → fb192de7e4fa152342bb.js} +1 -1
- package/assets/esri/core/workers/chunks/fbd8d2f61f8a15bcf3db.js +1 -0
- package/assets/esri/core/workers/chunks/{2f78861afe0e9037dd8d.js → fe49321dca22dc60d105.js} +1 -1
- package/assets/esri/core/workers/chunks/{fe77ae6cf232a7a3298e.js → fef45bc59c71f88c60b5.js} +1 -1
- package/assets/esri/libs/parquet/pkg/bundle_bg.wasm +0 -0
- package/chunks/MultiPathImpl.js +1 -1
- package/chunks/Point2D.js +1 -1
- package/chunks/UnitFactory.js +1 -1
- package/config.js +1 -1
- package/core/QueueProcessor.js +1 -1
- package/core/SetUtils.js +1 -1
- package/core/has.js +1 -1
- package/geometry/operators/gx/operatorOffset.js +1 -1
- package/geometry/support/meshUtils/loadGLTFMesh.js +1 -1
- package/identity/Credential.js +1 -1
- package/identity/IdentityManager.js +1 -1
- package/identity/IdentityManagerBase.js +1 -1
- package/interfaces.d.ts +67 -27
- package/kernel.js +1 -1
- package/layers/FeatureLayer.js +1 -1
- package/layers/SceneLayer.js +1 -1
- package/layers/graphics/controllers/FeatureTileController3D.js +1 -1
- package/layers/graphics/controllers/I3SOnDemandController.js +1 -1
- package/layers/graphics/sources/connections/GeoEventConnection.js +1 -1
- package/layers/graphics/sources/support/ParquetSourceWorker.js +1 -1
- package/layers/orientedImagery/core/ExposurePoint.js +1 -1
- package/layers/support/fieldConfigUtils.js +1 -1
- package/layers/support/rasterDatasets/pixelReader.js +1 -1
- package/layers/support/source/DataLayerSource.js +1 -1
- package/package.json +3 -3
- package/popup/FieldInfo.js +1 -1
- package/processRequest.js +5 -0
- package/request.js +1 -1
- package/requestConfig.js +5 -0
- package/requestQueue.js +5 -0
- package/rest/query/executeForCount.js +1 -1
- package/rest/query/executeForExtent.js +1 -1
- package/rest/query/executeForIds.js +1 -1
- package/rest/query/executeQueryJSON.js +1 -1
- package/rest/query/executeQueryPBF.js +1 -1
- package/rest/query/operations/query.js +1 -1
- package/rest/support/BaseImageMeasureResultValue.js +5 -0
- package/rest/support/ImageAreaResult.js +1 -1
- package/rest/support/ImageDistanceResult.js +1 -1
- package/rest/support/ImageHeightResult.js +1 -1
- package/rest/support/ImageMeasureResultAngleValue.js +5 -0
- package/rest/support/ImageMeasureResultAreaValue.js +5 -0
- package/rest/support/ImageMeasureResultLengthValue.js +5 -0
- package/rest/support/ImageWithType.js +5 -0
- package/rest/support/imageMeasureUtils.js +1 -1
- package/support/revision.js +1 -1
- package/views/2d/interactive/snapping/featureSources/featureServiceSource/FeatureServiceTiles2D.js +1 -1
- package/views/2d/layers/FeatureLayerView2D.js +1 -1
- package/views/2d/layers/features/FeaturePipelineWorker.js +1 -1
- package/views/2d/layers/features/schema/SourceSchema.js +1 -1
- package/views/2d/layers/features/sources/FeatureSource.js +1 -1
- package/views/2d/layers/features/sources/strategies/AFeatureLoadStrategy.js +1 -1
- package/views/2d/layers/features/sources/strategies/ALoadStrategy.js +1 -1
- package/views/2d/layers/features/sources/strategies/ParquetSnapshotLoadStrategy.js +1 -1
- package/views/2d/layers/features/sources/strategies/ParquetTileLoadStrategy.js +1 -1
- package/views/2d/layers/features/sources/strategies/chunks/Overrides.js +1 -1
- package/views/2d/layers/features/sources/strategies/chunks/SourceChunkStore.js +1 -1
- package/views/{3d/support/ImageWithType.js → 2d/layers/features/sources/strategies/constants.js} +1 -1
- package/views/2d/layers/features/sources/strategies/support/queryAdapters.js +1 -1
- package/views/3d/analysis/Dimension/LengthDimensionSubTool.js +1 -1
- package/views/3d/analysis/VolumeMeasurement/VolumeMeasurementCutFillController.js +1 -1
- package/views/3d/analysis/VolumeMeasurement/volumeMeasurementErrors.js +1 -1
- package/views/3d/glTF/DefaultLoadingContext.js +1 -1
- package/views/3d/interactive/measurementTools/areaMeasurement3D/AreaMeasurement3DTool.js +1 -1
- package/views/3d/interactive/measurementTools/directLineMeasurement3D/DirectLineMeasurement3DTool.js +1 -1
- package/views/3d/interactive/snapping/featureSources/featureServiceSource/FeatureServiceTiles3D.js +1 -1
- package/views/3d/layers/ElevationLayerView3D.js +1 -1
- package/views/3d/layers/FeatureLayerViewBase3D.js +1 -1
- package/views/3d/layers/PointCloudLayerView3D.js +1 -1
- package/views/3d/layers/graphics/FeatureGraphics3DGraphicsPipeline.js +1 -1
- package/views/3d/layers/graphics/Graphics3DCore.js +1 -1
- package/views/3d/layers/graphics/Graphics3DObjectSymbolLayer.js +1 -1
- package/views/3d/layers/graphics/Graphics3DSymbolCreationContext.js +1 -1
- package/views/3d/layers/graphics/ObjectResourceCache.js +1 -1
- package/views/3d/layers/graphics/objectResourceUtils.js +1 -1
- package/views/3d/layers/graphics/pipeline/Feature3DPipeline.js +1 -1
- package/views/3d/layers/graphics/pipeline/fetching/Tile3DFetcher.js +1 -1
- package/views/3d/layers/graphics/wosrLoader.js +1 -1
- package/views/3d/layers/i3s/I3SDataRequester.js +5 -0
- package/views/3d/layers/i3s/I3SIndex.js +1 -1
- package/views/3d/layers/i3s/I3SNodeLoader.js +1 -1
- package/views/3d/layers/i3s/I3SViewportQueries.js +1 -1
- package/views/3d/layers/support/FeatureTile.js +1 -1
- package/views/3d/layers/support/FeatureTileFetcher3D.js +1 -1
- package/views/3d/layers/support/MediaLayerInteractionOptions.js +1 -1
- package/views/3d/layers/support/MediaLayerInteractionReshapeOptions.js +5 -0
- package/views/3d/layers/support/SampledGeometryMaxDistanceRatio.js +5 -0
- package/views/3d/layers/support/featureTileQuery3D.js +1 -1
- package/views/3d/layers/support/fetchTile.js +1 -1
- package/views/3d/support/ResourceController.js +1 -1
- package/views/3d/support/SharedSymbolResources.js +1 -1
- package/views/3d/support/StreamTextureCollection.js +1 -1
- package/views/3d/terrain/TerrainSurface.js +1 -1
- package/views/3d/webgl-engine/lib/BindParameters.js +1 -1
- package/views/3d/webgl-engine/lighting/SceneLighting.js +1 -1
- package/views/3d/webgl-engine/shaders/AnimatedLine.glsl.js +6 -0
- package/views/SceneView.js +1 -1
- package/views/analysis/ElevationProfile/ElevationProfileTool.js +1 -1
- package/views/analysis/ElevationProfile/elevationProfileGeometryUtils.js +1 -1
- package/views/draw/MultipointDrawAction.js +1 -1
- package/views/draw/PointDrawAction.js +1 -1
- package/views/draw/PolygonDrawAction.js +1 -1
- package/views/draw/PolylineDrawAction.js +1 -1
- package/views/draw/SegmentDrawAction.js +1 -1
- package/views/draw/input/CursorUpdateEvents.js +5 -0
- package/views/draw/input/DrawCompleteEvent.js +5 -0
- package/views/draw/input/VertexAddEvent.js +5 -0
- package/views/draw/input/VertexRemoveEvent.js +5 -0
- package/views/draw/input/VertexUpdateEvent.js +5 -0
- package/views/interactive/editGeometry/CheckpointingEditGeometryOperations.js +5 -0
- package/views/interactive/editGeometry/EditGeometry.js +1 -1
- package/views/interactive/editGeometry/operations/ReplayableAppendVertex.js +5 -0
- package/views/interactive/snapping/featureSources/FeatureServiceSnappingSource.js +1 -1
- package/views/interactive/snapping/featureSources/featureServiceSource/FeatureServiceSnappingSourceWorkerHandle.js +1 -1
- package/views/interactive/snapping/featureSources/featureServiceSource/FeatureServiceTileStore.js +1 -1
- package/views/interactive/snapping/featureSources/featureServiceSource/FeatureServiceTiledFetcher.js +1 -1
- package/views/interactive/snapping/featureSources/featureServiceSource/FeatureServiceTilesSimple.js +1 -1
- package/webscene/spec-certification/api.js +1 -1
- package/widgets/CoordinateConversion/CoordinateConversionViewModel.js +1 -1
- package/widgets/CoordinateConversion.js +1 -1
- package/widgets/Editor.js +1 -1
- package/widgets/OrientedImageryViewer/OrientedImageryViewerViewModel.js +1 -1
- package/widgets/OrientedImageryViewer/adapters/sketch/TriangulatedMeasurementAdapter.js +1 -1
- package/widgets/OrientedImageryViewer/galleryUtils.js +1 -1
- package/widgets/PanoramicViewer/PanoramicViewerViewModel.js +1 -1
- package/widgets/PanoramicViewer/PanoramicZoomManager.js +1 -1
- package/widgets/PanoramicViewer/support/PanoramicMeshManager.js +1 -1
- package/widgets/PanoramicViewer/support/PanoramicTileNode.js +1 -1
- package/widgets/PanoramicViewer/support/PanoramicTilePyramid.js +1 -1
- package/widgets/PanoramicViewer/support/getVisibleTiles.js +5 -0
- package/widgets/Sketch/CreateToolVisibilityMap.js +5 -0
- package/widgets/Sketch/SelectionToolVisibilityMap.js +5 -0
- package/widgets/Sketch/VisibleElements.js +1 -1
- package/widgets/Sketch.js +1 -1
- package/assets/esri/core/workers/chunks/02e69f0c63d97661da60.js +0 -1
- package/assets/esri/core/workers/chunks/05eee334d58a0b9f6316.js +0 -1
- package/assets/esri/core/workers/chunks/087973e7c4fea5fcfa5e.js +0 -1
- package/assets/esri/core/workers/chunks/326a76a4e80269d4029d.js +0 -1
- package/assets/esri/core/workers/chunks/377a66034e7c1bad5599.js +0 -1
- package/assets/esri/core/workers/chunks/4442817beb7a76c95770.js +0 -1
- package/assets/esri/core/workers/chunks/459a67928bde4a62b6a4.js +0 -1
- package/assets/esri/core/workers/chunks/53bd8996e8812f1ad7b2.js +0 -1
- package/assets/esri/core/workers/chunks/557960763695abee4a83.js +0 -1
- package/assets/esri/core/workers/chunks/6201356f7f91e5c06425.js +0 -1
- package/assets/esri/core/workers/chunks/6c3b99209d542efa64d4.js +0 -1
- package/assets/esri/core/workers/chunks/7413e582bc2b16af6a0f.js +0 -1
- package/assets/esri/core/workers/chunks/7461124454bfb4fb6474.js +0 -1
- package/assets/esri/core/workers/chunks/75bf27271a31e26e1b21.js +0 -1
- package/assets/esri/core/workers/chunks/7aaaebbabee27690283c.js +0 -1
- package/assets/esri/core/workers/chunks/7c4a63aeead2505d6f02.js +0 -1
- package/assets/esri/core/workers/chunks/90250e9239c173aace88.js +0 -1
- package/assets/esri/core/workers/chunks/9786f91455350eaae493.js +0 -1
- package/assets/esri/core/workers/chunks/99859dce1925b406ccd0.js +0 -1
- package/assets/esri/core/workers/chunks/9c5cbf8810f37b1a4718.js +0 -1
- package/assets/esri/core/workers/chunks/9e8dceef4c961f56940d.js +0 -1
- package/assets/esri/core/workers/chunks/a06bac9b8f9e18874de8.js +0 -316
- package/assets/esri/core/workers/chunks/a712cdff78fc826acd8c.js +0 -1
- package/assets/esri/core/workers/chunks/d305a21666b1ed5bf33d.js +0 -1
- package/assets/esri/core/workers/chunks/d40f57f9fc47f9a9f97c.js +0 -1
- package/assets/esri/core/workers/chunks/e82f5437bd66779c6740.js +0 -1
- package/assets/esri/core/workers/chunks/f4d0ae6be1b3984228d0.js +0 -1
- package/assets/esri/core/workers/chunks/f6c8beb60f6d29945a2e.js +0 -1
- package/assets/esri/core/workers/chunks/f746e3f7ebff2bbdf333.js +0 -1
- package/views/3d/layers/i3s/I3SStreamDataController.js +0 -5
- package/views/3d/support/StreamDataLoader.js +0 -5
- package/views/3d/support/StreamDataRequester.js +0 -5
- package/views/3d/support/downloadSlots.js +0 -5
- package/views/draw/input/DrawEvents.js +0 -5
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3561,5804],{15804:(e,t,r)=>{r.d(t,{addOrUpdateResources:()=>i,bg:()=>d,cL:()=>p,fetchResources:()=>n,removeAllResources:()=>l,removeResource:()=>c});var a=r(
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3561,5804],{15804:(e,t,r)=>{r.d(t,{addOrUpdateResources:()=>i,bg:()=>d,cL:()=>p,fetchResources:()=>n,removeAllResources:()=>l,removeResource:()=>c});var a=r(43773),o=r(49186),s=r(84952);async function n(e,t={},r){await e.load(r);const a=(0,s.fj)(e.itemUrl,"resources"),{start:o=1,num:n=10,sortOrder:i="asc",sortField:c="resource"}=t,l={query:{start:o,num:n,sortOrder:i,sortField:c,token:e.apiKey},signal:r?.signal},u=await e.portal.request(a,l);return{total:u.total,nextStart:u.nextStart,resources:u.resources.map(({created:t,size:r,resource:a})=>({created:new Date(t),size:r,resource:e.resourceFromPath(a)}))}}async function i(e,t,r,a){const n=new Map;for(const{resource:e,content:a,compress:s,access:i}of t){if(!e.hasPath())throw new o.A(`portal-item-resource-${r}:invalid-path`,"Resource does not have a valid path");const[t,c]=u(e.path),l=`${t}/${s??""}/${i??""}`;n.has(l)||n.set(l,{prefix:t,compress:s,access:i,files:[]}),n.get(l).files.push({fileName:c,content:a})}await e.load(a);const i=(0,s.fj)(e.userItemUrl,"add"===r?"addResources":"updateResources");for(const{prefix:t,compress:r,access:o,files:s}of n.values()){const n=25;for(let c=0;c<s.length;c+=n){const l=s.slice(c,c+n),u=new FormData;t&&"."!==t&&u.append("resourcesPrefix",t),r&&u.append("compress","true"),o&&u.append("access",o);let p=0;for(const{fileName:e,content:t}of l)u.append("file"+ ++p,t,e);u.append("f","json"),await e.portal.request(i,{method:"post",body:u,signal:a?.signal})}}}async function c(e,t,r){if(!t.hasPath())throw new o.A("portal-item-resources-remove:invalid-path","Resource does not have a valid path");await e.load(r);const a=(0,s.fj)(e.userItemUrl,"removeResources");await e.portal.request(a,{method:"post",query:{resource:t.path},signal:r?.signal}),t.portalItem=null}async function l(e,t){await e.load(t);const r=(0,s.fj)(e.userItemUrl,"removeResources");return e.portal.request(r,{method:"post",query:{deleteAll:!0},signal:t?.signal})}function u(e){const t=e.lastIndexOf("/");return-1===t?[".",e]:[e.slice(0,t),e.slice(t+1)]}async function p(e){return"blob"===e.type?e.blob:"json"===e.type?new Blob([e.jsonString],{type:"application/json"}):(await(0,a.A)(e.url,{responseType:"blob"})).data}function d(e,t){if(!e.hasPath())return null;const[r,,a]=function(e){const[t,r]=function(e){const t=(0,s.Zo)(e);return null==t?[e,""]:[e.slice(0,e.length-t.length-1),`.${t}`]}(e),[a,o]=u(t);return[a,o,r]}(e.path);return e.portalItem.resourceFromPath((0,s.fj)(r,t+a))}},26121:(e,t,r)=>{r.d(t,{ci:()=>n,dL:()=>o});var a=r(49186);async function o(e){const t=[];for(const r of e.allLayers)if("beforeSave"in r&&"function"==typeof r.beforeSave){const e=r.beforeSave();e&&t.push(e)}await Promise.allSettled(t)}r(77548);const s=new Set(["layer:unsupported","property:unsupported","symbol:unsupported","symbol-layer:unsupported","url:unsupported"]);function n(e,t,r){let o=(e.messages??[]).filter(({type:e})=>"error"===e).map(({name:e,message:t,details:r})=>new a.A(e,t,r));if(e.blockedRelativeUrls&&(o=o.concat(e.blockedRelativeUrls.map(e=>new a.A("url:unsupported",`Relative url '${e}' is not supported`)))),r){const{ignoreUnsupported:e,supplementalUnsupportedErrors:t=[],requiredPropertyChecksDisabled:a}=r;e&&(o=o.filter(({name:e})=>!(s.has(e)||t.includes(e)))),a&&(o=o.filter(e=>"web-document-write:property-required"!==e.name))}if(o.length>0)throw new a.A(t.errorName,"Failed to save due to unsupported or invalid content. See 'details.errors' for more detailed information",{errors:o})}},46130:(e,t,r)=>{r.d(t,{v:()=>o});var a=r(76553);function o(e){e?.writtenProperties&&e.writtenProperties.forEach(({target:e,propName:t,newOrigin:r})=>{(0,a.H)(e)&&r&&e.originOf(t)!==r&&e.updateOrigin(t,r)})}},63561:(e,t,r)=>{r.d(t,{save:()=>w,saveAs:()=>y});var a=r(71530),o=r(88788),s=r(10407),n=r(91682);const i="Media Layer",c="media-layer-save",l="media-layer-save-as",u=["media-layer:unsupported-source"];function p(e){return{isValid:"media"===e.type,errorMessage:"Layer.type should be 'media'"}}function d(e){return(0,o.m)(e,"portal-item",!0)}function f(e){return Promise.resolve(e.layerJSON)}async function m(e,t){t.extent=e.fullExtent?await(0,s.sQ)(e.fullExtent):null}async function h(e,t){t.title||=e.title,await m(e,t),(0,s.OM)(t,s.mm.METADATA)}async function w(e,t){return(0,a.UN)({layer:e,itemType:i,validateLayer:p,createJSONContext:e=>d(e),createItemData:f,errorNamePrefix:c,supplementalUnsupportedErrors:u,setItemProperties:m,saveResources:(t,r)=>(0,n.r)(e.resourceReferences,r)},t)}async function y(e,t,r){return(0,a.Uh)({layer:e,itemType:i,validateLayer:p,createJSONContext:e=>d(e),createItemData:f,errorNamePrefix:l,supplementalUnsupportedErrors:u,newItem:t,setItemProperties:h,saveResources:(t,r)=>(0,n.r)(e.resourceReferences,r)},r)}},71530:(e,t,r)=>{r.d(t,{UN:()=>v,Uh:()=>g});var a=r(49186),o=r(46130),s=r(20655),n=r(80812),i=r(88788),c=r(10407),l=r(26121);async function u(e){const{layer:t,errorNamePrefix:r,validateLayer:o}=e;await t.load(),function(e,t,r){const o=r(e);if(!o.isValid)throw new a.A(`${t}:invalid-parameters`,o.errorMessage,{layer:e})}(t,r,o)}function p(e,t){return`Layer (title: ${e.title}, id: ${e.id}) of type '${e.declaredClass}' ${t}`}function d(e){const{item:t,errorNamePrefix:r,layer:o,validateItem:s}=e;if(function(e){const{item:t,itemType:r,additionalItemType:o,errorNamePrefix:s,layer:n}=e,i=[r];if(o&&i.push(o),!i.includes(t.type)){const e=i.map(e=>`'${e}'`).join(", ");throw new a.A(`${s}:portal-item-wrong-type`,`Portal item type should be one of: "${e}"`,{item:t,layer:n})}}(e),s){const e=s(t);if(!e.isValid)throw new a.A(`${r}:invalid-parameters`,e.errorMessage,{layer:o})}}function f(e){const{layer:t,errorNamePrefix:r}=e,{portalItem:o}=t;if(!o)throw new a.A(`${r}:portal-item-not-set`,p(t,"requires the portalItem property to be set"));if(!o.loaded)throw new a.A(`${r}:portal-item-not-loaded`,p(t,"cannot be saved to a portal item that does not exist or is inaccessible"));d({...e,item:o})}function m(e){const{newItem:t,itemType:r}=e;let a=n.default.from(t);return a.id&&(a=a.clone(),a.id=null),a.type??=r,a.portal??=s.A.getDefault(),d({...e,item:a}),a}function h(e){return(0,i.m)(e,"portal-item")}async function w(e,t,r){"beforeSave"in e&&"function"==typeof e.beforeSave&&await e.beforeSave();const a=e.write({},t);return await Promise.all(t.resources?.pendingOperations??[]),(0,l.ci)(t,{errorName:"layer-write:unsupported"},r),a}function y(e){(0,c.LG)(e,c.mm.JSAPI),e.typeKeywords&&(e.typeKeywords=e.typeKeywords.filter((e,t,r)=>r.indexOf(e)===t))}async function v(e,t){const{layer:r,createItemData:a,createJSONContext:s,setItemProperties:n,saveResources:i,supplementalUnsupportedErrors:c}=e;await u(e),f(e);const l=r.portalItem,p=s?s(l):h(l),d=await w(r,p,{...t,supplementalUnsupportedErrors:c}),m=await a({layer:r,layerJSON:d},l);return await(n?.(r,l,m)),y(l),await l.update({data:m}),(0,o.v)(p),await(i?.(l,p)),l}async function g(e,t){const{layer:r,createItemData:a,createJSONContext:s,setItemProperties:n,saveResources:i,supplementalUnsupportedErrors:c}=e;await u(e);const l=m(e),p=s?s(l):h(l),d=await w(r,p,{...t,supplementalUnsupportedErrors:c}),f=await a({layer:r,layerJSON:d},l);return await n(r,l,f),y(l),await async function(e,t,r){const a=e.portal;await a.signIn(),await a.user.addItem({item:e,data:t,folder:r?.folder})}(l,f,t),r.portalItem=l,(0,o.v)(p),await(i?.(l,p)),l}},76553:(e,t,r)=>{function a(e){return e&&"getAtOrigin"in e&&"originOf"in e}r.d(t,{H:()=>a})},88788:(e,t,r)=>{r.d(t,{m:()=>n,v:()=>s});var a=r(84952),o=r(20655);function s(e,t){return{...i(e,t),readResourcePaths:[]}}function n(e,t,r){const o=(0,a.An)(e.itemUrl);return{...i(e,t),messages:[],writtenProperties:[],blockedRelativeUrls:[],verifyItemRelativeUrls:o?{rootPath:o.path,writtenUrls:[]}:null,resources:r?{toAdd:[],toUpdate:[],toKeep:[],pendingOperations:[]}:null}}function i(e,t){return{origin:t,url:(0,a.An)(e.itemUrl),portal:e.portal||o.A.getDefault(),portalItem:e}}},91682:(e,t,r)=>{r.d(t,{S:()=>c,r:()=>i});var a=r(49186),o=r(74887),s=r(13069),n=r(15804);async function i(e,t,r){const a=await l(e,t,r);await u(a,t,r)}async function c(e,t,r,a,o){const s=await l(r,a,o);await e.update({data:t}),await u(s,a,o)}async function l(e,t,i){if(!t?.resources)return;const c=t.portalItem===e.portalItem?new Set(e.paths):new Set;e.paths.length=0,e.portalItem=t.portalItem;const l=new Set(t.resources.toKeep.map(e=>e.resource.path)),u=new Set,p=[];l.forEach(t=>{c.delete(t),e.paths.push(t)});const d=[],f=[],m=[];for(const r of t.resources.toUpdate)if(c.delete(r.resource.path),l.has(r.resource.path)||u.has(r.resource.path)){const{resource:t,content:a,finish:o}=r,i=(0,n.bg)(t,(0,s.lk)());e.paths.push(i.path),d.push({resource:i,content:await(0,n.cL)(a),compress:r.compress}),o&&m.push(()=>o(i))}else{e.paths.push(r.resource.path),f.push({resource:r.resource,content:await(0,n.cL)(r.content),compress:r.compress});const t=r.finish;t&&m.push(()=>t(r.resource)),u.add(r.resource.path)}for(const r of t.resources.toAdd)if(e.paths.push(r.resource.path),c.has(r.resource.path))c.delete(r.resource.path);else{d.push({resource:r.resource,content:await(0,n.cL)(r.content),compress:r.compress});const e=r.finish;e&&m.push(()=>e(r.resource))}if(d.length||f.length){const{addOrUpdateResources:e}=await Promise.resolve().then(r.bind(r,15804));await e(t.portalItem,d,"add",i),await e(t.portalItem,f,"update",i)}if(m.forEach(e=>e()),0===p.length)return c;const h=await(0,o.Ol)(p);if((0,o.Te)(i),h.length>0)throw new a.A("save:resources","Failed to save one or more resources",{errors:h});return c}async function u(e,t,r){if(!e||!t.portalItem)return;const a=[];for(const o of e){const e=t.portalItem.resourceFromPath(o);a.push(e.portalItem.removeResource(e,r))}await(0,o.Lx)(a)}}}]);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[7548],{4146:(e,t,n)=>{n.d(t,{A:()=>w});var r=n(31635),i=n(
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[7548],{4146:(e,t,n)=>{n.d(t,{A:()=>w});var r=n(31635),i=n(43773),l=n(49186),a=n(65529),s=n(4902),o=n(92474),u=n(53966),p=n(74887),c=n(84952),d=n(10107),y=(n(44208),n(87811),n(64108)),g=n(5443),h=n(16930),f=n(92602),m=n(79677);let b=0,w=class extends((0,a.Zt)((0,s.s)(o.x_))){constructor(){super(...arguments),this.attributionDataUrl=null,this.fullExtent=new g.A(-180,-90,180,90,h.A.WGS84),this.id=Date.now().toString(16)+"-layer-"+b++,this.legendEnabled=!0,this.listMode="show",this.opacity=1,this.parent=null,this.persistenceEnabled=!1,this.popupEnabled=!0,this.attributionVisible=!0,this.spatialReference=h.A.WGS84,this.title=null,this.type=null,this.url=null,this.visibilityTimeExtent=null,this.visible=!0}static async fromArcGISServerUrl(e){const t="string"==typeof e?{url:e}:e;return(await Promise.all([n.e(812),n.e(7982)]).then(n.bind(n,27982))).fromUrl(t)}static fromPortalItem(e){return async function(e){const t="portalItem"in e?e:{portalItem:e},{fromItem:r}=await Promise.all([n.e(812),n.e(5613),n.e(5710)]).then(n.bind(n,45613));try{return await r(t)}catch(e){const n=t?.portalItem,r=n?.id||"unset",i=n?.portal?.url||f.A.portalUrl;throw u.A.getLogger("esri.layers.support.fromPortalItem").error("#fromPortalItem()","Failed to create layer from portal item (portal: '"+i+"', id: '"+r+"')",e),e}}(e)}initialize(){this.when().catch(e=>{(0,p.zf)(e)||u.A.getLogger(this).error("#load()",`Failed to load layer (title: '${this.title??"no title"}', id: '${this.id??"no id"}')`,{error:e})})}destroy(){const{parent:e}=this;e&&(this.parent=null,e.removeChildLayer?.(this))}get effectiveVisible(){return this.visible&&(this.parent?.effectiveVisible??!0)}get hasAttributionData(){return null!=this.attributionDataUrl}get loaded(){return super.loaded}removeFromParent(){const{parent:e}=this;e&&(e.removeChildLayer?.(this),this.parent=null)}get parsedUrl(){return(0,c.An)(this.url)}createLayerView(e,t){return Promise.reject(new l.A("layer:create-layer-view","Layer does not support creating a layer view"))}async fetchAttributionData(){const e=this.attributionDataUrl;if(this.hasAttributionData&&e)return(await(0,i.A)(e,{query:{f:"json"},responseType:"json"})).data;throw new l.A("layer:no-attribution-data","Layer does not have attribution data")}};(0,r.Cg)([(0,d.MZ)({type:String})],w.prototype,"attributionDataUrl",void 0),(0,r.Cg)([(0,d.MZ)({readOnly:!0})],w.prototype,"effectiveVisible",null),(0,r.Cg)([(0,d.MZ)({type:g.A})],w.prototype,"fullExtent",void 0),(0,r.Cg)([(0,d.MZ)({readOnly:!0})],w.prototype,"hasAttributionData",null),(0,r.Cg)([(0,d.MZ)({type:String,clonable:!1})],w.prototype,"id",void 0),(0,r.Cg)([(0,d.MZ)({type:Boolean,nonNullable:!0})],w.prototype,"legendEnabled",void 0),(0,r.Cg)([(0,d.MZ)({type:["show","hide","hide-children"]})],w.prototype,"listMode",void 0),(0,r.Cg)([(0,d.MZ)({type:Number,range:{min:0,max:1},nonNullable:!0})],w.prototype,"opacity",void 0),(0,r.Cg)([(0,d.MZ)({clonable:!1})],w.prototype,"parent",void 0),(0,r.Cg)([(0,d.MZ)({readOnly:!0})],w.prototype,"parsedUrl",null),(0,r.Cg)([(0,d.MZ)({type:Boolean,readOnly:!0})],w.prototype,"persistenceEnabled",void 0),(0,r.Cg)([(0,d.MZ)({type:Boolean})],w.prototype,"popupEnabled",void 0),(0,r.Cg)([(0,d.MZ)({type:Boolean})],w.prototype,"attributionVisible",void 0),(0,r.Cg)([(0,d.MZ)({type:h.A})],w.prototype,"spatialReference",void 0),(0,r.Cg)([(0,d.MZ)({type:String})],w.prototype,"title",void 0),(0,r.Cg)([(0,d.MZ)({readOnly:!0,json:{read:!1}})],w.prototype,"type",void 0),(0,r.Cg)([(0,d.MZ)()],w.prototype,"url",void 0),(0,r.Cg)([(0,d.MZ)({type:m.A})],w.prototype,"visibilityTimeExtent",void 0),(0,r.Cg)([(0,d.MZ)({type:Boolean,nonNullable:!0})],w.prototype,"visible",void 0),w=(0,r.Cg)([(0,y.$)("esri.layers.Layer")],w)},16215:(e,t,n)=>{n.d(t,{S:()=>i,Y:()=>r});const r=Symbol("BasemapInstance");function i(e){return null!=e&&"object"==typeof e&&r in e}},77548:(e,t,n)=>{n.d(t,{Gh:()=>f,tk:()=>d,BR:()=>c,wI:()=>p,G$:()=>g,$x:()=>y,Ov:()=>s,W_:()=>o,OP:()=>h,TU:()=>a,XX:()=>l,jy:()=>u});var r=n(70333),i=n(43773);n(7762),n(84952),n(36563),n(36708),n(4146),new WeakMap,n(16215);const l={Point:"SceneLayer","3DObject":"SceneLayer",IntegratedMesh:"IntegratedMeshLayer",PointCloud:"PointCloudLayer",Building:"BuildingSceneLayer"};function a(e){const t=e?.type;return"building-scene"===t||"integrated-mesh"===t||"point-cloud"===t||"scene"===t}function s(e){return"feature"===e?.type&&!e.url&&"memory"===e.source?.type}function o(e){const t=e?.type;return("feature"===t||"subtype-group"===t||"oriented-imagery"===t)&&"feature-layer"===e?.source?.type}function u(e){return function(e){return null!=e&&"object"==typeof e&&"type"in e&&"feature"===e.type}(e)&&function(e){return"feature"===e?.type&&"feature-layer"===e.source?.type}(e)}async function p(e,t){const n=r.id?.findServerInfo(e);if(null!=n?.currentVersion)return n.owningSystemUrl||null;const l=e.toLowerCase().indexOf("/rest/services");if(-1===l)return null;const a=`${e.slice(0,l)}/rest/info`,s=null!=t?t.signal:null,{data:o}=await(0,i.A)(a,{query:{f:"json"},responseType:"json",signal:s});return o?.owningSystemUrl||null}function c(e){return function(e){if(!("capabilities"in e))return!1;switch(e.type){case"catalog":case"catalog-footprint":case"csv":case"feature":case"geojson":case"imagery":case"knowledge-graph-sublayer":case"ogc-feature":case"oriented-imagery":case"scene":case"sublayer":case"subtype-group":case"subtype-sublayer":case"wfs":return!0;default:return!1}}(e)?"effectiveCapabilities"in e?e.effectiveCapabilities:e.capabilities:null}function d(e){return!!function(e){if(!("editingEnabled"in e))return!1;switch(e.type){case"csv":case"feature":case"geojson":case"oriented-imagery":case"scene":case"subtype-group":case"subtype-sublayer":case"knowledge-graph-sublayer":return!0;default:return!1}}(e)&&("effectiveEditingEnabled"in e?e.effectiveEditingEnabled:e.editingEnabled)}function y(e,t){return null}function g(e){return null}function h(e){return!e||"Feature Service"===e.type&&!e.sourceUrl}function f(e,t){if(!t||!h(e))return;const n=(e.url,null);n&&(e.url=n)}},79677:(e,t,n)=>{n.d(t,{A:()=>d});var r,i=n(31635),l=n(25482),a=n(88930),s=n(10107),o=(n(44208),n(53966),n(87811),n(36005)),u=n(64108),p=n(43937),c=n(98623);let d=class extends l.o{static{r=this}static get allTime(){return y}static get empty(){return g}static fromArray(e){return new r({start:null!=e[0]?new Date(e[0]):e[0],end:null!=e[1]?new Date(e[1]):e[1]})}constructor(e){super(e),this.end=null,this.start=null}readEnd(e,t){return null!=t.end?new Date(t.end):null}writeEnd(e,t){t.end=e?.getTime()??null}get isAllTime(){return this.equals(r.allTime)}get isEmpty(){return this.equals(r.empty)}readStart(e,t){return null!=t.start?new Date(t.start):null}writeStart(e,t){t.start=e?.getTime()??null}clone(){return new r({end:this.end,start:this.start})}equals(e){if(!e)return!1;const t=this.start?.getTime()??this.start,n=this.end?.getTime()??this.end,r=e.start?.getTime()??e.start,i=e.end?.getTime()??e.end;return t===r&&n===i}expandTo(e,t=c.qU){if(this.isEmpty||this.isAllTime)return this.clone();let n=this.start;n&&(n=(0,a.lL)(n,e,t));let i=this.end;if(i){const n=(0,a.lL)(i,e,t);i=i.getTime()===n.getTime()?n:(0,a.S1)(n,1,e,t)}return new r({start:n,end:i})}intersection(e){if(!e)return this.clone();if(this.isEmpty||e.isEmpty)return r.empty;if(this.isAllTime)return e.clone();if(e.isAllTime)return this.clone();const t=this.start?.getTime()??-1/0,n=this.end?.getTime()??1/0,i=e.start?.getTime()??-1/0,l=e.end?.getTime()??1/0;let a,s;return i>=t&&i<=n?a=i:t>=i&&t<=l&&(a=t),n>=i&&n<=l?s=n:l>=t&&l<=n&&(s=l),null==a||null==s||isNaN(a)||isNaN(s)?r.empty:new r({start:a===-1/0?null:new Date(a),end:s===1/0?null:new Date(s)})}offset(e,t,n=c.qU){if(this.isEmpty||this.isAllTime)return this.clone();const i=new r,{start:l,end:s}=this;return null!=l&&(i.start=(0,a.S1)(l,e,t,n)),null!=s&&(i.end=(0,a.S1)(s,e,t,n)),i}toArray(){return this.isEmpty?[void 0,void 0]:[this.start?.getTime()??null,this.end?.getTime()??null]}union(e){if(!e||e.isEmpty)return this.clone();if(this.isEmpty)return e.clone();if(this.isAllTime||e.isAllTime)return y.clone();const t=null!=this.start&&null!=e.start?new Date(Math.min(this.start.getTime(),e.start.getTime())):null,n=null!=this.end&&null!=e.end?new Date(Math.max(this.end.getTime(),e.end.getTime())):null;return new r({start:t,end:n})}};(0,i.Cg)([(0,s.MZ)({type:Date,json:{write:{allowNull:!0}}})],d.prototype,"end",void 0),(0,i.Cg)([(0,o.w)("end")],d.prototype,"readEnd",null),(0,i.Cg)([(0,p.K)("end")],d.prototype,"writeEnd",null),(0,i.Cg)([(0,s.MZ)({readOnly:!0,json:{read:!1}})],d.prototype,"isAllTime",null),(0,i.Cg)([(0,s.MZ)({readOnly:!0,json:{read:!1}})],d.prototype,"isEmpty",null),(0,i.Cg)([(0,s.MZ)({type:Date,json:{write:{allowNull:!0}}})],d.prototype,"start",void 0),(0,i.Cg)([(0,o.w)("start")],d.prototype,"readStart",null),(0,i.Cg)([(0,p.K)("start")],d.prototype,"writeStart",null),d=r=(0,i.Cg)([(0,u.$)("esri.time.TimeExtent")],d);const y=new d,g=new d({start:void 0,end:void 0})}}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3661],{55537:(t,s,e)=>{function i(t,s){try{if(!t)throw new Error(s)}catch(t){throw t}}e.d(s,{A:()=>L,B:()=>P,C:()=>C,D:()=>F,G:()=>m,a:()=>M,b:()=>w,c:()=>R,d:()=>z,e:()=>v,f:()=>d,g:()=>i,h:()=>x,i:()=>p,j:()=>N,k:()=>b,l:()=>_,m:()=>g,n:()=>E,o:()=>B,p:()=>D,q:()=>q,r:()=>T,s:()=>G,t:()=>A,u:()=>f,v:()=>y,w:()=>I,x:()=>k,y:()=>S,z:()=>Z});class n extends Error{constructor(t,s){super(s),this.m_AdditionalMessage=s,this.m_ErrorType=t,this.name="GeometryError"}what(){return function(t){switch(t){case 1:return"Unknown error";case 2:return"Corrupted geometry";case 3:return"Empty geometry";case 4:return"Math singularity";case 5:return"Buffer is too small";case 6:return"Invalid shape type";case 7:return"Projection out of supported range";case 8:return"Non simple geometry";case 9:return"Cannot calculate geodesic";case 10:return"Notation conversion";case 11:return"Missing grid file";case 12:return"Invalid call";case 13:return"Internal error";case 14:return"Not implemented";case 15:return"IO error";case 16:return"Invalid 3D";case 17:return"An ambiguous geography edge with antipodal points";case 18:return"Geocentric coordinates require ellipsoidal height";case 19:return"Geography cannot be projected into a gnomonic plane or a result of an operation cannot fit into a gnomonic plane";case 20:return"Geometry is too large to be exported in to a given format";case 22:return"Operation is canceled by the user";case 21:return"The operation, such as projection or geodetic computation, cannot be performed without pe-wasm loaded";default:return"unknown error"}}(this.m_ErrorType)}additionalMessage(){return this.m_AdditionalMessage?this.m_AdditionalMessage:""}code(){return this.m_ErrorType}}class r extends n{constructor(t){super(2,t),this.name="CorruptedGeometryError"}}class u extends n{constructor(t){super(3,t),this.name="EmptyGeometryError"}}class h extends n{constructor(t){super(4,t),this.name="MathSingularityError"}}class o extends n{constructor(t){super(21,t),this.name="ProjectionEngineNotLoadedError"}}class a extends n{constructor(t){super(8,t),this.name="NonSimpleGeometryError"}}var m,l;(l=m||(m={}))[l.enumUnknown=0]="enumUnknown",l[l.enumPoint=513]="enumPoint",l[l.enumLine=5122]="enumLine",l[l.enumBezier=5123]="enumBezier",l[l.enumEllipticArc=5124]="enumEllipticArc",l[l.enumEnvelope=3077]="enumEnvelope",l[l.enumMultiPoint=8710]="enumMultiPoint",l[l.enumPolyline=25607]="enumPolyline",l[l.enumPolygon=27656]="enumPolygon",l[l.enumMultipatch=40969]="enumMultipatch",l[l.enumGeometryCollection=3594]="enumGeometryCollection",l[l.enumRationalBezier2=5134]="enumRationalBezier2",l[l.enumBezier2=5135]="enumBezier2",l[l.enumRationalBezier23d=5392]="enumRationalBezier23d",l[l.enumGreatArc3d=5393]="enumGreatArc3d";const c=[0,0,1,1,1,2,0,1,2,3,-1,-1,-1,-1,1,1];function f(t){return c[15&t]}function v(t){return!!(512&t)}function _(t){return!!(1024&t)}function b(t){return!!(2048&t)}function d(t){return!!(4096&t)}function p(t){return!!(8192&t)}function x(t){return!!(16384&t)}function N(t){return!!(32768&t)}function y(t){const s=t.getGeometryType();return p(s)?t.getPointCount():t.isEmpty()?0:s===m.enumEnvelope?4:s===m.enumPoint?1:d(s)?2:void z("missing type")}function g(t){const s=t.getGeometryType();if(x(s))return t.hasNonLinearSegments();if(s===m.enumGeometryCollection){const s=t;for(let t=0,e=s.getGeometryCount();t<e;t++)if(g(s.getGeometry(t)))return!0;return!1}return!!d(s)&&s!==m.enumLine}function T(t){throw new o(t)}function E(t){throw new r(t)}function M(t){throw new Error(t)}function w(t){throw new h(t)}function I(){M("Geometry type is not supported for 3D operations.")}function D(t){throw new n(12,t)}function P(t){throw new u(t)}function A(t){throw new n(14,t)}function q(t){throw new Error(t)}function z(t){throw new n(13,t)}function C(t){throw new Error(t)}function Z(t){throw new a(t)}function B(t){t&&g(t)&&A("Operation does not support curves.")}function R(t){t&&N(t.getGeometryType())&&A("Unsupported geometry type.")}function k(t){t===m.enumGeometryCollection&&M("Geometry_collection instances are not supported in this operation")}function G(t){k(t.getGeometryType())}function S(t){M(`bad wkid: ${t}`)}function L(t){let s="bad wkt: ";s+=t,s+="...",M(s)}function F(t,s){t||M(s)}},83661:(t,s,e)=>{e.d(s,{$:()=>Ls,A:()=>ms,B:()=>vs,C:()=>At,D:()=>Dt,E:()=>a,F:()=>Ht,G:()=>I,H:()=>Ts,I:()=>as,J:()=>ds,K:()=>n,L:()=>Os,M:()=>Bs,N:()=>Tt,O:()=>ls,P:()=>Qs,Q:()=>R,R:()=>Nt,S:()=>Zt,T:()=>ts,U:()=>d,V:()=>ws,W:()=>M,X:()=>l,Y:()=>fs,Z:()=>Ut,_:()=>Fs,a:()=>G,a0:()=>bs,a1:()=>ys,a2:()=>cs,a3:()=>gs,a4:()=>Kt,a5:()=>Jt,a6:()=>p,a7:()=>Pt,a8:()=>Es,a9:()=>ft,aA:()=>ks,aB:()=>Rs,aC:()=>lt,aD:()=>Cs,aE:()=>yt,aF:()=>V,aG:()=>S,aH:()=>at,aI:()=>L,aJ:()=>es,aK:()=>_t,aa:()=>xt,ab:()=>St,ac:()=>As,ad:()=>ct,ae:()=>Ct,af:()=>Z,ag:()=>B,ah:()=>pt,ai:()=>A,aj:()=>Ds,ak:()=>Is,al:()=>zs,am:()=>D,an:()=>P,ao:()=>q,ap:()=>z,aq:()=>x,ar:()=>Gs,as:()=>Ps,at:()=>it,au:()=>nt,av:()=>wt,aw:()=>N,ax:()=>y,ay:()=>et,az:()=>Rt,b:()=>vt,c:()=>bt,d:()=>zt,e:()=>F,f:()=>w,g:()=>Ns,h:()=>Et,i:()=>ss,j:()=>Xt,k:()=>qt,l:()=>Bt,m:()=>It,n:()=>st,o:()=>Gt,p:()=>kt,q:()=>C,r:()=>Wt,s:()=>Ms,t:()=>O,u:()=>gt,v:()=>dt,w:()=>Mt,x:()=>k,y:()=>g,z:()=>E});var i=e(55537);class n{constructor(t){this.sum=t,this.compensation=0}assign(t){return this.compensation=t.compensation,this.sum=t.sum,this}reset(){this.sum=this.compensation=0}resetToStart(t){this.sum=t,this.compensation=0}normalize(){const t=[Number.NaN];this.sum=tt(this.sum,this.compensation,t),this.compensation=t[0]}add(t){const s=this.sum+t;let e;if(Math.abs(this.sum)>=Math.abs(t)){const i=this.sum-s+t;e=this.compensation+i}else{const i=t-s+this.sum;e=this.compensation+i}this.sum=s,this.compensation=e}sub(t){this.add(-t)}addProduct(t,s){const e=[0],i=J(t,s,e);this.add(i),this.add(e[0])}mul(t){const s=new n(0);s.addProduct(this.sum,t),s.addProduct(this.compensation,t),this.assign(s)}getResult(){return this.sum+this.compensation}pe(t){return this.add(t),this}me(t){return this.add(-t),this}}const r=[5,1,2,1,3,1,2,1,4,1,2,1,3,1,2,1],u=[-1,0,1,1,2,2,2,2,3,3,3,3,3,3,3,3];function h(t){let s=0;return 65535n&t||(s+=16,t>>=16n),255n&t||(s+=8,t>>=8n),15n&t||(s+=4,t>>=4n),s+r[Number(BigInt.asUintN(4,t))]}function o(t){let s=0;return 4294967295n&t||(s=32,t>>=32n),s+h(BigInt.asUintN(32,t))}class a{constructor(t,s){if(this.m_EnvelopeType=1,void 0!==t){if(t instanceof a)return this.vmin=t.vmin,void(this.vmax=t.vmax);this.vmin=t,this.vmax=s,this.normalize()}else this.setEmpty()}static construct(t,s){return new a(t,s)}static constructEmpty(){return new a}setCoords(t,s){this.vmin=t,this.vmax=s,this.normalize()}setCoordsFromEnvelope(t){this.vmin=t.vmin,this.vmax=t.vmax}setEmpty(){this.vmin=Number.NaN,this.vmax=Number.NaN}getCenter(){return.5*(this.vmin+this.vmax)}equalsRange(t,s){return Ht(this.vmin,t)&&Ht(this.vmax,s)}equals(t,s){return!(!this.isEmpty()||!t.isEmpty())||(void 0!==s?Math.abs(this.vmin-t.vmin)<=s&&Math.abs(this.vmax-t.vmax)<=s:this.vmin===t.vmin&&this.vmax===t.vmax)}width(){return this.vmax-this.vmin}isEmpty(){return Number.isNaN(this.vmin)||Number.isNaN(this.vmax)}isZero(){return this.vmin===this.vmax}setInfinite(){this.vmin=Number.NEGATIVE_INFINITY,this.vmax=Number.POSITIVE_INFINITY}move(t){this.isEmpty()||(this.vmin+=t,this.vmax+=t)}contains(t){return t.vmin>=this.vmin&&t.vmax<=this.vmax}containsCoordinate(t){return t>=this.vmin&&t<=this.vmax}containsRightExclusive(t){return t>=this.vmin&&t<this.vmax}containsExclusiveCoordinate(t){return t>this.vmin&&t<this.vmax}containsExclusive(t){return t.vmin>this.vmin&&t.vmax<this.vmax}isIntersecting(t){return this.vmin<=t.vmin?this.vmax>=t.vmin:t.vmax>=this.vmin}mergeCoordinate(t){if(this.isEmpty())return this.vmin=t,void(this.vmax=t);this.mergeNeCoordinate(t)}merge(t){if(t.isEmpty())return;const s=t.vmin,e=t.vmax;this.mergeCoordinate(s),this.mergeCoordinate(e)}mergeNe(t){const s=t.vmin,e=t.vmax;this.mergeNeCoordinate(s),this.mergeNeCoordinate(e)}mergeNeCoordinate(t){t<this.vmin?this.vmin=t:t>this.vmax&&(this.vmax=t)}intersect(t){this.isEmpty()||t.isEmpty()?this.setEmpty():(this.vmin<t.vmin&&(this.vmin=t.vmin),this.vmax>t.vmax&&(this.vmax=t.vmax),this.vmin>this.vmax&&this.setEmpty())}inflate(t){this.isEmpty()||(this.vmin-=t,this.vmax+=t,this.vmax<this.vmin&&this.setEmpty())}normalize(){this.vmin<=this.vmax||(this.vmin>this.vmax?this.vmax=bt(this.vmin,this.vmin=this.vmax):this.setEmpty())}isValid(){return this.isEmpty()||this.vmin<=this.vmax}snapClip(t){return Ms(t,this.vmin,this.vmax)}calculateToleranceFromEnvelope(){return this.isEmpty()?Ns():(Math.abs(this.vmin)+Math.abs(this.vmax)+1)*Ns()}static unit(){return m}normalizeNoNAN(){this.vmin>this.vmax&&(this.vmax=bt(this.vmin,this.vmin=this.vmax))}setCoordsNoNAN(t,s){this.vmin=t,this.vmax=s,this.normalizeNoNAN()}clone(){return new a(this.vmin,this.vmax)}}const m=new a(0,1);class l{static getNAN(){return new l(Number.NaN)}constructor(t,s){this.m_value=t??0,this.m_eps=s??0}[Symbol.toPrimitive](t){return this}clone(){return new l(this.m_value,this.m_eps)}assign(t){return this.m_value=t.m_value,this.m_eps=t.m_eps,this}scaleError(t){this.m_eps*=t}setError(t){this.m_eps=t}set(t,s){return this.m_value=t,this.m_eps=s??0,this}setWithEps(t,s){return void 0===s&&(s=1),this.m_value=t,this.m_eps=l.ulp(t)*s,this}setE(t){return this.m_value=t.m_value,this.m_eps=t.m_eps,this}precise(){return new l(this.m_value)}value(){return this.m_value}toDouble(){return this.m_value}eps(){return this.m_eps}resetError(){return this.m_eps=0,this}absThis(){return this.m_value=Math.abs(this.m_value),this}add(t){return this.clone().addThis(t)}addE(t){return this.clone().addThisE(t)}addThisE(t){const s=this.m_value+t.m_value,e=this.m_eps+t.m_eps+l.ulp(s);return this.m_value=s,this.m_eps=e,this}addThis(t){const s=this.m_value+t,e=this.m_eps+l.ulp(s);return this.m_value=s,this.m_eps=e,this}subE(t){return this.clone().subThisE(t)}sub(t){return this.clone().subThis(t)}subThisE(t){const s=this.m_value-t.m_value,e=this.m_eps+t.m_eps+l.ulp(s);return this.m_value=s,this.m_eps=e,this}subThis(t){const s=this.m_value-t,e=this.m_eps+l.ulp(s);return this.m_value=s,this.m_eps=e,this}setAddE(t,s){return this.m_value=t.m_value+s.m_value,this.m_eps=t.m_eps+s.m_eps+l.ulp(this.m_value),this}setAdd(t,s){return this.m_value=t+s,this.m_eps=l.ulp(this.m_value),this}setAddEN(t,s){return this.m_value=t.m_value+s,this.m_eps=t.m_eps+l.ulp(this.m_value),this}setAddNE(t,s){return this.m_value=t+s.m_value,this.m_eps=s.m_eps+l.ulp(this.m_value),this}setSubE(t,s){return this.m_value=t.m_value-s.m_value,this.m_eps=t.m_eps+s.m_eps+l.ulp(this.m_value),this}setSub(t,s){return this.m_value=t-s,this.m_eps=l.ulp(this.m_value),this}setSubEN(t,s){return this.m_value=t.m_value-s,this.m_eps=t.m_eps+l.ulp(this.m_value),this}setSubNE(t,s){return this.m_value=t-s.m_value,this.m_eps=s.m_eps+l.ulp(this.m_value),this}mulThisE(t){const s=this.m_value*t.m_value;return this.m_eps=this.m_eps*Math.abs(t.m_value)+t.m_eps*Math.abs(this.m_value)+this.m_eps*t.m_eps+l.ulp(s),this.m_value=s,this}mulThis(t){const s=this.m_value*t;return this.m_eps=this.m_eps*Math.abs(t)+l.ulp(s),this.m_value=s,this}mul(t){return this.clone().mulThis(t)}mulE(t){return this.clone().mulThisE(t)}setMulE(t,s){const e=t.m_value*s.m_value;return this.m_eps=t.m_eps*Math.abs(s.m_value)+s.m_eps*Math.abs(t.m_value)+t.m_eps*s.m_eps+l.ulp(e),this.m_value=e,this}setMul(t,s){return this.m_value=t*s,this.m_eps=l.ulp(this.m_value),this}setMulEN(t,s){return this.setE(t),this.mulThis(s)}setMulNE(t,s){return this.setE(s),this.mulThis(t)}mulThisByPower2(t){return this.m_value*=t,this.m_eps*=Math.abs(t),this}static st_mulByPower2(t,s){return new l(t.m_value,t.m_eps).mulThisByPower2(s)}divE(t){return this.clone().divThisE(t)}divThisE(t){const s=Math.abs(t.m_value),e=this.m_value/t.m_value;let i=(this.m_eps+Math.abs(e)*t.m_eps)/s;if(t.m_eps>.01*s){const e=t.m_eps/s;i*=1+(1+e)*e}return this.m_value=e,this.m_eps=i+l.ulp(e),this}divThis(t){const s=Math.abs(t);return this.m_value/=t,this.m_eps=this.m_eps/s+l.ulp(this.m_value),this}setDivE(t,s){return this.setE(t),this.divThisE(s)}setDiv(t,s){return this.m_value=t/s,this.m_eps=l.ulp(this.m_value),this}setDivEN(t,s){return this.setE(t),this.divThis(s)}setDivNE(t,s){return this.set(t),this.divThisE(s)}divThisByPower2(t){return this.m_value/=t,this.m_eps/=Math.abs(t),this}invThis(){return this.setE(p.clone().divThisE(this)),this}sqrt(){return this.clone().sqrtThis()}sqrtThis(){let t,s;return this.m_value>=0?(t=Math.sqrt(this.m_value),s=this.m_value>10*this.m_eps?.5*this.m_eps/t:this.m_value>this.m_eps?t-Math.sqrt(this.m_value-this.m_eps):Math.max(t,Math.sqrt(this.m_value+this.m_eps)-t),s+=l.ulp(t)):this.m_value<-this.m_eps?(t=Number.NaN,s=Number.NaN):(t=0,s=Math.sqrt(this.m_eps)),this.m_value=t,this.m_eps=s,this}sqr(){return this.clone().sqrThis()}sqrThis(){const t=this.m_value*this.m_value;return this.m_eps=2*this.m_eps*Math.abs(this.m_value)+this.m_eps*this.m_eps+l.ulp(t),this.m_value=t,this}setSin(t){const s=Math.sin(t.m_value),e=Math.cos(t.m_value);this.m_value=s;const i=Math.abs(s),n=Math.abs(t.value());return this.m_eps=(Math.abs(e)+.5*i*t.m_eps)*t.m_eps+l.ulp(i+n),this}static ulp(t){let s=Vt(t);const e=((0x7ff0000000000000n&s)>>52n)-1075n;return e>-1023n?(s=e+0x3ffn<<52n,function(t){return Ot[0]=t,Ft[0]}(s)):0===t?0:Number.MIN_VALUE}setCos(t){const s=Math.sin(t.m_value),e=Math.cos(t.m_value);this.m_value=e;const i=Math.abs(e),n=Math.abs(t.value());return this.m_eps=(Math.abs(s)+.5*i*t.m_eps)*t.m_eps+l.ulp(i+n),this}static st_cosAndSin(t,s,e){const i=Math.sin(t.m_value),n=Math.cos(t.m_value);e.m_value=i,s.m_value=n;const r=Math.abs(i),u=Math.abs(n),h=Math.abs(t.value());e.m_eps=(Math.abs(n)+.5*r*t.m_eps)*t.m_eps+l.ulp(r+h),s.m_eps=(Math.abs(i)+.5*u*t.m_eps)*t.m_eps+l.ulp(u+h)}negate(){return this.clone().negateThis()}negateThis(){return this.m_value=-this.m_value,this}setAbs(){return this.m_value=Math.abs(this.m_value),this}isInInterval(t){return a.construct(this.m_value-this.m_eps,this.m_value+this.m_eps).isIntersecting(t)}eq(t){return Math.abs(this.m_value-t.m_value)<=this.m_eps+t.m_eps}ne(t){return!this.eq(t)}gt(t){return this.m_value-t.m_value>this.m_eps+t.m_eps}lt(t){return t.m_value-this.m_value>this.m_eps+t.m_eps}ge(t){return!this.lt(t)}le(t){return!this.gt(t)}tolEQ(t,s){return Math.abs(this.m_value-t.m_value)<=s||this.eq(t)}tolNE(t,s){return!this.tolEQ(t,s)}tolGT(t,s){return this.m_value-t.m_value>s&&this.gt(t)}tolLT(t,s){return t.m_value-this.m_value>s&&this.lt(t)}tolGE(t,s){return!this.tolLT(t,s)}tolLE(t,s){return!this.tolGT(t,s)}isZero(){return Math.abs(this.m_value)<=this.m_eps}isFuzzyZero(){return this.isZero()&&0!==this.m_eps}tolIsZero(t){return Math.abs(this.m_value)<=Math.max(this.m_eps,t)}setPi(){this.setE(b)}setEuler(){this.set(2.718281828459045,_())}static size(){return 1}}function c(t,s){const e=jt(t),i=jt(s),n=53-o(e),r=53-o(i);return(n>=0?n:0)+(r>=0?r:0)<=52}function f(t,s){const e=t+s;return e-t===s&&e-s===t}function v(t,s){const e=t-s;return t-e===s&&s+e===t}function _(){return Ts()}l.dimensions=1;const b=new l(Math.PI,.5*_()),d=new l(0,0),p=new l(1,0),x=new l(4,0);function N(t,s,e){return t.addE(s.subE(t).mulE(e))}function y(t,s,e){return s.subE(s.subE(t).mulE(p.subE(e)))}function g(t){let s;if(0===t)s=1;else if(Math.abs(t)>.01)s=function(t){return Math.atanh(t)}(t)/t;else{let e;const i=-36.841361487904734;s=0;const n=t*t;for(let t=2*Math.trunc(i/Math.log(n)+2.5)-1;t>1;t-=2)e=1/t,s=(s+e)*n;s+=1}return s}function T(t){const s=Math.PI*Math.PI/6;let e;if(1===t)e=s;else if(t>1)e=s;else if(0===t)e=t;else if(t<0){const s=1+(t=Math.abs(t)),i=Math.log(s);e=i*i/-2-T(t/s)}else if(t>.5){const i=1-t,n=Math.log(t)*Math.log(i);e=s-T(i)-n}else{e=0;const s=1+Math.trunc(-16*Math.log(10)/Math.log(t)+1.5);let i=s;for(let n=s;n>0;n--,i-=1)e*=t,e+=1/(i*i);e*=t}return e}function E(t,s){const e=s*t;if(Math.abs(s)<.1){let s=0;for(let t=60;t>=1;t--)s*=e,s+=1/t/t;return s*=t,s}return T(e)/s}function M(t,s){return t<s?Bt(t,s):Bt(s,t)}function w(t,s){const e=Math.abs(t);return s>=0?e:-e}function I(t){return Math.round(t)}function D(t,s,e,i,n){n[0]=s[0]+(e[0]-s[0])*i,n[1]=s[1]+(e[1]-s[1])*i,3===t&&(n[2]=s[2]+(e[2]-s[2])*i)}function P(t,s,e,i,n){n[0]=e[0]-(e[0]-s[0])*(1-i),n[1]=e[1]-(e[1]-s[1])*(1-i),3===t&&(n[2]=e[2]-(e[2]-s[2])*(1-i))}function A(t,s,e,i,n){i<=.5?D(t,s,e,i,n):P(t,s,e,i,n)}function q(t,s,e,i,n){n[0]=s[0].addE(e[0].subE(s[0]).mulE(i)),n[1]=s[1].addE(e[1].subE(s[1]).mulE(i))}function z(t,s,e,i,n){n[0]=e[0].subE(e[0].subE(s[0]).mulE(p.subE(i))),n[1]=e[1].subE(e[1].subE(s[1]).mulE(p.subE(i)))}function C(t,s,e){let i;return i=e<=.5?t+(s-t)*e:s-(s-t)*(1-e),i}function Z(t,s,e){return t+(s-t)*e}function B(t,s,e){return s-(s-t)*(1-e)}function R(t,s,e,i){e<=.5?(i.x=t.x+(s.x-t.x)*e,i.y=t.y+(s.y-t.y)*e):(i.x=s.x-(s.x-t.x)*(1-e),i.y=s.y-(s.y-t.y)*(1-e))}function k(t,s,e,i){e<=.5?(i.x=t.x+(s.x-t.x)*e,i.y=t.y+(s.y-t.y)*e,i.z=t.z+(s.z-t.z)*e):(i.x=s.x-(s.x-t.x)*(1-e),i.y=s.y-(s.y-t.y)*(1-e),i.z=s.z-(s.z-t.z)*(1-e))}function G(t){return t*t}function S(t){return t*t*t}function L(t){return 1/Math.sqrt(t)}function F(t){return t<0?-1:t>0?1:0}function O(t,s,e,i){const n=[0],r=[0],u=[0];return tt(J(t,e,n),J(s,i,r),u)+(n[0]+r[0]+u[0])}const Q=[0],U=[0];function V(t,s,e){return function(t,s,e,i){const n=tt(t,s,W),r=tt(n,e,X);return tt(r,W[0]+X[0],i)}(J(t,s,Q),e,Q[0],U)}const j=[0],Y=[0],$=[0],H=[0];function J(t,s,e){const i=t*s;return K(t,j,Y),K(s,$,H),e[0]=Y[0]*H[0]-(i-j[0]*$[0]-Y[0]*$[0]-j[0]*H[0]),i}function K(t,s,e){const i=134217729*t;s[0]=i-(i-t),e[0]=t-s[0]}const W=[0],X=[0];function tt(t,s,e){const i=t+s;return Math.abs(t)>Math.abs(s)?e[0]=t-i+s:e[0]=s-i+t,i}function st(t,s){return t%s}function et(t){const s=1-t;if(0===s)return 1;let e;if(s<=.01){const t=s,i=Math.log(t);e=1+t*(.4431471805599453-.25*i+t*(.05680519270997949-.09375*i+t*(.02183137044373718-.05859375*i+t*(.011544521417308362-.042724609375*i+t*(.00714200031339596-.0336456298828125*i+t*(.004854743337164948-.027757644653320312*i+t*(.003514687963781376-.023627042770385742*i)))))))}else{if(t<.016){const s=t,e=.25,i=.046875,n=.01953125,r=.01068115234375,u=.0067291259765625,h=.004626274108886719,o=.0033752918243408203,a=.0025710230693221092;return As()*(1-s*(e+s*(i+s*(n+s*(r+s*(u+s*(h+s*(o+s*a))))))))}e=rt(0,s,1)-t*ut(0,s,1)/3}return Ms(e,1,As())}function it(t,s,e=Number.NaN){if((0,i.g)(s>=0&&s<=1),0===s)return t;let n=1,r=t;if(r<0&&(r=-r,n=-1),1===s){const t=Math.round(r/Ds()),s=r-t*Ds();return n*(2*t+Math.sin(s))}const u=As(),h=Math.floor(r/u);1&h?r=(h+1)*u-r:r-=h*u;const o=Math.sin(r),a=Number.isNaN(e)?et(s):e;let m;if(1===o)m=a+Math.sqrt(1-s)*(r-u);else{const t=r*r;if(.01424*Math.pow(t,4)<=2*Ts())m=r*(1+t*s*(-1/6+t*((4-3*s)/120-(16+(45*s-60)*s)/5040*t)));else if(s<=.01){const t=Math.sin(2*r),e=Math.sin(4*r),i=Math.sin(6*r),n=Math.sin(8*r),u=Math.sin(10*r);m=r+s*((2*-r+t)/8+s*((-3*r+2*t-.25*e)/64+s*((-20*r+15*t-3*e+i/3)/1024+s*(5*(-140*r+112*t-28*e+16/3*i-.5*n)/65536+7*s*((-63*r+52.5*t-15*e+3.75*i-.625*n+.05*u)/65536+s*(-693*r+594*t-185.625*e+1.375*i-12.375*n+1.8*u-.125*Math.sin(12*r))/1048576)))))}else{const t=o*o,e=Math.cos(r),i=e*e,n=ht(o,e,s);m=o*(rt(i,n,1)-s*t*ut(i,n,1)/3)}}return 1&h?m=a*(h+1)-m:m+=a*h,n*m}function nt(t,s,e=Number.NaN){if(0===t)return 0;let i=1,n=t;t<0&&(n=-n,i=-1);const r=Number.isNaN(e)?et(s):e,u=Math.floor(n/r);1&u?n=(u+1)*r-n:n-=u*r;let h=n<=0?0:n>=r?As():function(t,s,e){if(0===s)return t;if(1===s)return Math.asin(t);let i=0,n=!0;if(t<.2){const e=t*t,r=t*(1+e*s*(1/6+e*((13*s-4)/120+(16-284*s+493*s*s)/5040*e))),u=Math.abs(s*(4944*s-64-31224*s*s+37369*s*s*s)/362880*Math.pow(t,9));if(u<Math.abs(r)*Ts())return r;i=r,n=u>.1*r}if(n){const n=1-s,r=1-t/e,u=Math.sqrt(r*r+n*n),h=Math.atan2(n,t+Ts());i=As()+Math.sqrt(u)*(h-As())}let r=0;for(let n=0;n<7;n++){r=it(i,s,e);const u=ht(Math.sin(i),Math.cos(i),s);if(i-=(r-t)/Math.sqrt(u),n>0&&Math.abs(r-t)<=4*Ts()*t)break}return i}(n,s,r);return 1&u?h=As()*(u+1)-h:h+=As()*u,i*h}function rt(t,s,e){(0,i.g)((0!==t?1:0)+(0!==s?1:0)+1>1);let n=t,r=s,u=e;for(;;){const t=Math.sqrt(n*r)+Math.sqrt(r*u)+Math.sqrt(u*n);n=.25*(n+t),r=.25*(r+t),u=.25*(u+t);const s=(n+r+u)/3,e=(s-n)/s,i=(s-r)/s,h=(s-u)/s;if(Math.abs(e)<=.0024&&Math.abs(i)<=.0024&&Math.abs(h)<=.0024){const t=e*i-h*h,n=e*i*h;return(1+(1/24*t-.1-3/44*n-5*t*t/208+t*n/16)*t+(1/14+3*n/104)*n)/Math.sqrt(s)}}}function ut(t,s,e){(0,i.g)(0!==t||0!==s);let r=t,u=s,h=e;const o=new n(0);let a=1;for(;;){const t=.2*(r+u+3*h),s=(t-r)/t,e=(t-u)/t,i=(t-h)/t;if(Math.abs(s)<=.0015&&Math.abs(e)<=.0015&&Math.abs(i)<=.0015){const n=s*e,r=i*i,u=n-r,h=n-6*r,m=h+u+u,l=3/26,c=h*(9/22*.25*h-.21428571428571427-1.5*l*i*m),f=i*(1/6*m+i*(-.4090909090909091*u+i*l*n));return 3*o.getResult()+a*(1+c+f)/(t*Math.sqrt(t))}const n=Math.sqrt(r),m=Math.sqrt(u),l=Math.sqrt(h),c=n*(m+l)+m*l;o.add(a/(l*(h+c))),a*=.25,r=.25*(r+c),u=.25*(u+c),h=.25*(h+c)}}function ht(t,s,e){return t<.999?1-e*G(t):1-e+e*G(s)}const ot=new class{constructor(t){for(this.values=[[1]];this.values.length<t+1;){const t=this.values.at(-1),s=zt(t.length+1,1);for(let e=1;e<t.length;++e)s[e]=t[e-1]+t[e];this.values.push(s)}}get(t,s){return this.values[t][s]}}(32);function at(t,s){if(t<ot.values.length)return ot.get(t,s);const e=Math.exp(((0,i.g)(0),0));return e+.01>2147483647&&(0,i.q)("The result value of n choose k is out of range"),e+.01}function mt(t,s){if(t.isZero())return t.clone();const e=t.clone().divThis(t);if(s<0)return e.divThis(mt(t,-s));for(t=t.clone(),s=Math.trunc(s);1&s&&e.mulThis(t),s>>=1;)t.mulThis(t);return e}function lt(t,s){if(0===s)return[];const e=t[0].clone().mulDoubleThis(0),i=[];i.length=s;const n=s-1;for(let s=0;s<=n;++s){i[s]=e.clone();for(let e=0;e<=s;++e)i[s].addThis(t[e].clone().mulDoubleThis(at(s,e)/at(n,e)))}return i}function ct(t,s,e,n,r){return 0===t?0===n?s:1===n?e:r:1===t?0===n?s:1===n?e:C(s,e,n):(2===t&&(0,i.t)("angular interpolation"),void(0,i.t)(""))}function ft(t,s,e,n,r,u,h,o){if(0===t)for(let t=0;t<u;++t)n[t+r]=0===h?s[t]:1===h?e[t]:o;else if(1===t)if(0===h)vt(n,s,r,0,u);else if(1===h)vt(n,e,r,0,u);else for(let t=0;t<u;++t)n[t+r]=C(s[t],e[t],h);else if(2===t)if(0===h)vt(n,s,r,0,u);else if(1===h)vt(n,e,r,0,u);else{let t=0;for(let i=0,o=r;i<u;++i,++o)n[o]=C(s[i],e[i],h),t+=n[o]*n[o];if(t>0){t=Math.sqrt(t);for(let s=r;s<r+u;++s)n[s]/=t}else{for(let t=r;t<r+u;++t)n[t]=0;n[r]=1}}else(0,i.t)("")}function vt(t,s,e,i,n){if(0===n)return;let r=0,u=e,h=i;for(;r++<n;)t[u++]=s[h++]}function _t(t,s,e){let i=0;for(let n=0;!i&&n<e;++n)i=t[n]-s[n];return i}function bt(t,s){return t}function dt(t){t.sort((t,s)=>t<s?-1:t>s?1:0)}function pt(t,s){const e=t.slice(0,s);dt(e),vt(t,e,0,0,s)}function xt(t,s,e,i){const n=t.slice(s,s+e);n.sort(i),vt(t,n,s,0,e)}function Nt(t,s){return t<s?-1:t>s?1:0}function yt(t,s,e,i){return t<e?-1:t>e?1:s<i?-1:s>i?1:0}function gt(t,s){if(t.length<2)return t.length;let e=0;for(let i=1;i<t.length;++i)s(t[i],t[e])||(e++,t[i]=bt(t[e],t[e]=t[i]));return 1+e}function Tt(t,s){t[s]=t.at(-1),t.pop()}function Et(t,s=!1){return{[Symbol.dispose](){this.bForget||t()},bForget:s}}function Mt(t,s,e){t.length=s,t.fill(e)}function wt(t,s,e){t.length=e;for(let i=0;i<e;++i)t[i]=new s}function It(t,s){const e=new Array(s);for(let i=0;i<s;++i)e[i]=new t;return e}function Dt(t,s,e){for(let i=0;i<e;++i)t[i].assign(s[i]);return e}function Pt(t,s){const e=t.slice(0,s);for(let t=0;t<s;++t)e[t]=e[t].clone();return e}function At(t){return Array.from({length:t},()=>null)}function qt(t,s){return Array.from({length:s},()=>t())}function zt(t,s){const e=new Array(t);return e.fill(s),e}function Ct(t,s){return s in t&&1===Object.getOwnPropertyNames(t).length}class Zt{constructor(...t){this.m_elts=t}get length(){return this.m_elts.length}at(t){return this.m_elts[t]}[Symbol.dispose](){for(const t of this.m_elts)t[Symbol.dispose]()}}function Bt(t,s){return{first:t,second:s}}const Rt=Math.PI,kt=2*Math.PI,Gt=.5*Math.PI;class St{constructor(t,s){this.m_cr=t,this.m_cc=s,this.m_v=zt(t*s,0)}get(t,s){return this.m_v[t*this.m_cc+s]}set(t,s,e){this.m_v[t*this.m_cc+s]=e}inc(t,s){return++this.m_v[t*this.m_cc+s]}}const Lt=new ArrayBuffer(8),Ft=new Float64Array(Lt),Ot=new BigUint64Array(Lt),Qt=0x0fffffffffffffn;function Ut(){return Number.EPSILON*xs}function Vt(t){return Ft[0]=t,Ot[0]}function jt(t){return Vt(t)&Qt}function Yt(t){return Number((9218868437227405312n&Vt(t))>>52n)}function $t(t){if(0n===t)return-1n;if(1n===t||-1n===t)return 0n;t<0n&&(t=-t);let s=0n,e=512n,i=1n<<s+e;for(;t>=i;)s+=e,e<<=1n,i<<=e;let n=s;e>>=1n;let r=n+e;for(;e>0n;)t<1n<<r||(n=r),e>>=1n,r=n+e;return n}function Ht(t,s){return t===s||Number.isNaN(t)&&Number.isNaN(s)}function Jt(t,s,e){return t===s||Math.abs(t-s)<=e||Number.isNaN(t)&&Number.isNaN(s)}function Kt(t,s){return t<s?-1:t>s?1:0}function Wt(t,s){if(t<s)return-1;if(t>s)return 1;if(t===s)return 0;{const e=Number.isNaN(t),i=Number.isNaN(s);return e<i?-1:e>i?1:0}}function Xt(){return 2147483647}function ts(){return 32767}function ss(){return 2147483647}function es(){return-2147483648}const is=2147483647,ns=BigInt(is),rs=2166136261,us=16777619,hs=14695981039346656037n,os=1099511628211n;function as(t){let s=rs;for(let e=0,i=t.length;e<i;++e)s=(s^t.charCodeAt(e))*us;return s&is}function ms(t,s){return s+2654435769+(t<<6)+(t>>2)&is}function ls(t,s){return ms(t,_s(s))}function cs(t){return ms(3735928559,t)}function fs(t,s){return ms(t,cs(s))}function vs(t){return function(t){let s=rs,e=t;return s=(s^255&e)*us,e>>=8,s=(s^255&e)*us,e>>=8,s=(s^255&e)*us,e>>=8,s=(s^255&e)*us,s&is}(t)}function _s(t){return Number(function(t){let s=hs,e=t;return s=(s^0xffn&e)*os,e>>=8n,s=(s^0xffn&e)*os,e>>=8n,s=(s^0xffn&e)*os,e>>=8n,s=(s^0xffn&e)*os,e>>=8n,s=(s^0xffn&e)*os,e>>=8n,s=(s^0xffn&e)*os,e>>=8n,s=(s^0xffn&e)*os,s&ns}(t))}function bs(t){return _s(Vt(function(t){return Cs(t)}(t)))}function ds(t){return function(t){return 1103515245*t+12345&2147483647}(t)}const ps=100,xs=100;function Ns(){return Number.EPSILON*ps}function ys(){return.38196601125010515}function gs(){return 1.4142135623730951}function Ts(){return Number.EPSILON}function Es(t,s,e){return t===s||t===e}function Ms(t,s,e){return t>=s?t<=e?t:e:s}function ws(t,s,e){const i=t[0];if(i>=s){if(i<=e)return!1;t[0]=e}else t[0]=s;return!0}function Is(t,s){return t>=s?s:t<-s?-s:t}function Ds(){return Rt}function Ps(){return kt}function As(){return Gt}const qs=3*As();function zs(){return qs}function Cs(t){return t+0}function Zs(t){return{v:t}}class Bs{constructor(){this.m_rn=Zs(0n),this.m_rd=Zs(1n),this.m_bNaN=!1,this.m_bNormalized=!1,this.m_power=0,this.m_sign=0}static constructAssign(t,s){const e=t.clone();return void 0!==s&&e.limitPrecisionThis(s),e}static constructDouble(t){return(new Bs).setDouble(t)}static constructInt64(t){return(new Bs).setInt64(t)}static constructRational(t,s){return(new Bs).setRational(t,s)}static constructInt32(t){return this.constructInt64(BigInt(Math.trunc(t)))}[Symbol.toPrimitive](t){return this}compare(t){return this.lt(t)?-1:this.gt(t)?1:0}assignCopy(t){return this.setThis(t)}abs(){return this.clone().absThis()}absThis(){return this.isNAN()||(this.m_sign*=this.m_sign),this}clone(){return(new Bs).setThis(this)}setThis(t){return this.m_bNaN=t.m_bNaN,this.m_bNormalized=t.m_bNormalized,this.m_rn.v=t.m_rn.v,this.m_rd.v=t.m_rd.v,this.m_power=t.m_power,this.m_sign=t.m_sign,this}setZero(){return this.m_rn.v=0n,this.m_rd.v=1n,this.m_bNaN=!1,this.m_power=0,this.m_bNormalized=!0,this.m_sign=0,this}setDouble(t){if(this.setZero(),0===t)return this;if(Number.isInteger(t)&&Math.abs(t)<2147483647)return this.setInt32(t);const s=Vt(t),e=(s&Bs.s_em)>>52n,n=!!(s&Bs.s_sm),r=s&Bs.s_fm;if(e===Bs.s_emax)return r?(this.m_rn.v=this.m_rd.v=0n,this.m_bNaN=!0,this):(this.m_rn.v=n?-1n:1n,this.m_rd.v=0n,this);0n===e&&(0,i.t)("denormalized numbers not yet implemented");const u=e-1023n,h=u>=0n?u:0n,o=u<0n?-u:0n;return this.m_rn.v=(1n<<52n|r)<<h,this.m_rd.v=1n<<52n+o,this.m_sign=n?-1:1,this.m_bNormalized=!1,this.normalizeThis()}setInt64(t){return 0n===t?this.setZero():(this.m_bNaN=!1,this.m_sign=t>0n?1:-1,this.m_rn.v=t>0n?t:-t,this.m_rd.v=1n,this.m_power=0,this.m_bNormalized=!1,this.normalizeThis())}setRational(t,s){return 0n===t?0n===s?this.setNAN():this.setZero():0n===s?t>0n?this.setPositiveInf():this.setNegativeInf():(this.m_sign=(t>0n?1:-1)*(s>0n?1:-1),this.m_rn.v=t>0n?t:-t,this.m_rd.v=s>0n?s:-s,this.m_power=0,this.m_bNormalized=!1,this.normalizeThis())}setInt32(t){return this.setInt64(BigInt(Math.trunc(t)))}getDouble(){return this.convertToDouble()}toDouble(){return this.convertToDouble()}value(){return this.convertToDouble()}isNAN(){return this.m_bNaN}isPositiveInf(){return!this.isNAN()&&0n===this.m_rd.v&&1===this.m_sign}isNegativeInf(){return!this.isNAN()&&0n===this.m_rd.v&&-1===this.m_sign}isFinite(){return!this.isNAN()&&0n!==this.m_rd.v}setNAN(){return this.m_bNaN=!0,this.m_rn.v=0n,this.m_rd.v=0n,this.m_power=0,this.m_bNormalized=!0,this}setPositiveInf(){return this.m_rn.v=1n,this.m_rd.v=0n,this.m_bNaN=!1,this.m_bNormalized=!0,this.m_sign=1,this.m_power=0,this}setNegativeInf(){return this.m_rn.v=1n,this.m_rd.v=0n,this.m_bNaN=!1,this.m_bNormalized=!0,this.m_sign=-1,this.m_power=0,this}subThis(t){if(t.isNAN()&&this.setNAN(),this.isPositiveInf()&&t.isPositiveInf())this.setNAN();else{if(this.isPositiveInf()&&t.isNegativeInf())return this.setPositiveInf(),this;if(this.isNegativeInf()&&t.isNegativeInf())this.setNAN();else if(this.isNegativeInf()&&t.isPositiveInf())return this.setNegativeInf(),this}return this.isNAN()?this:this.opPlusMinus(t,!1)}thisSubAbs(t){return(0,i.g)(0),this}mulThis(t){return t.isNAN()&&this.setNAN(),this.isNAN()?this:(this.m_sign*=t.m_sign,0===this.m_sign?this.setZero():(this.m_rn.v*=t.m_rn.v,this.m_rd.v*=t.m_rd.v,this.m_power+=t.m_power,this.m_bNormalized=!1,this.normalizeThis(),this))}mulDoubleThis(t){return this.mulThis(Bs.constructDouble(t))}thisMulInt64(t){return(0,i.g)(0),this}thisMulInt32(t){return(0,i.g)(0),this}divThis(t){return this.mulThis(t.clone().invertThis())}divDoubleThis(t){return this.divThis(Bs.constructDouble(t))}addDoubleThis(t){return this.addThis(Bs.constructDouble(t))}subDoubleThis(t){return this.subThis(Bs.constructDouble(t))}mul(t){return this.clone().mulThis(t)}mulBigIntThis(t){return this.mulThis(Bs.constructInt64(t))}mulDouble(t){return this.clone().mulThis(Bs.constructDouble(t))}div(t){return this.clone().divThis(t)}divDouble(t){return this.clone().divDoubleThis(t)}add(t){return this.clone().addThis(t)}fmSubThis(t,s){return this.subThis(t.clone().mulThis(s))}fmAddThis(t,s){return this.addThis(t.clone().mulThis(s))}addThis(t){if(t.isNAN()&&this.setNAN(),this.isPositiveInf()&&t.isPositiveInf())return this.setPositiveInf(),this;if(this.isPositiveInf()&&t.isNegativeInf())this.setNAN();else{if(this.isNegativeInf()&&t.isNegativeInf())return this.setNegativeInf(),this;this.isNegativeInf()&&t.isPositiveInf()&&this.setNAN()}return this.isNAN()?this:this.opPlusMinus(t,!0)}addDouble(t){return this.clone().addThis(Bs.constructDouble(t))}sub(t){return this.clone().subThis(t)}subDouble(t){return this.clone().subThis(Bs.constructDouble(t))}isZero(){return 0===this.m_sign}equals(t){return this.clone().subThis(t).isZero()}lt(t){return!this.isNAN()&&!t.isNAN()&&!(this.isPositiveInf()&&t.isPositiveInf()||this.isNegativeInf()&&t.isNegativeInf())&&!this.isPositiveInf()&&(!!t.isPositiveInf()||this.clone().sub(t).LZ())}absLessAbs(t){return this.abs().lt(t.abs())}gt(t){return this.clone().sub(t).GZ()}lte(t){return this.sub(t).LEZ()}gte(t){return this.sub(t).GEZ()}normalizeThis(){if(this.m_bNormalized)return this;if(0n===this.m_rn.v)return this.setZero();let t=0,s=0xffffffffn;for(;0n===(this.m_rn.v&s)&&s<=this.m_rn.v;)s<<=32n,t+=32;s&=this.m_rn.v,s>>=BigInt(t),t+=h(BigInt.asUintN(32,s))-1;let e=0;for(s=0xffffffffn;0n===(this.m_rd.v&s)&&s<=this.m_rd.v;)s<<=32n,e+=32;return s&=this.m_rd.v,s>>=BigInt(e),e+=h(BigInt.asUintN(32,s))-1,this.m_rn.v>>=BigInt(t),this.m_rd.v>>=BigInt(e),this.m_power+=t-e,this.m_rn.v>1n&&this.m_rd.v>1n&&(this.m_rn.v%this.m_rd.v===0n?(this.m_rn.v/=this.m_rd.v,this.m_rd.v=1n):this.m_rd.v%this.m_rn.v===0n&&(this.m_rd.v/=this.m_rn.v,this.m_rn.v=1n)),this.m_bNormalized=!0,this}negateThis(){return this.isNAN()||(this.m_sign*=-1),this}negate(){return this.clone().negateThis()}invertThis(){return this.isNAN()?this:this.isPositiveInf()||this.isNegativeInf()?(this.setZero(),this):0n===this.m_rn.v?(this.setPositiveInf(),this):(this.m_rd=bt(this.m_rn,this.m_rn=this.m_rd),this.m_power=-this.m_power,this)}limitPrecisionThis(t){if(0===t)return this;if(this.isZero())return this.setZero();if(!this.isFinite())return this;this.normalizeThis();let s=Number($t(this.m_rn.v));if(s>t){const e=s-t;this.m_rn.v>>=BigInt(s-t),this.m_power+=e}if(s=Number($t(this.m_rd.v)),s>t){const e=s-t;this.m_rd.v>>=BigInt(s-t),this.m_power-=e}return this}hiBitIndex(){return Math.max(Number($t(this.m_rn.v)),Number($t(this.m_rd.v)))}ldexp(t){return this.clone().ldexpThis(t)}ldexpThis(t){return t&&(this.m_bNormalized=!1,this.m_power+=t,this.normalizeThis()),this}static lerp(t,s,e){return Bs.lerpLo(s,s,e)}static lerpLo(t,s,e){return s.sub(t).mulThis(e).addThis(t)}static lerpHi(t,s,e){return s.sub(t).mulThis(Rs.sub(e)).addThis(t)}LZ(){return!this.isNAN()&&-1===this.m_sign}GZ(){return!this.isNAN()&&1===this.m_sign}LEZ(){return!this.isNAN()&&this.m_sign<=0}GEZ(){return!this.isNAN()&&this.m_sign>=0}toString(){return this.toDouble().toString()}sqr(){return this.clone().sqrThis()}sqrThis(){return this.mulThis(this.clone())}static sqrt(t,s){if(t.m_sign<0n&&(0,i.q)("MP_value: sqrt(-1)"),t.isZero())return t.clone();let e=52,n=2220446049250313e-31;for(;e<s;)2*e<=s?(n*=n,e*=2):(n*=2220446049250313e-31,e+=52);e+=52;const r=$t(t.m_rn.v),u=$t(t.m_rd.v);let h,o=t.m_power+Number(r-u);const a=new Bs;Math.abs(o)>200?(1&Math.abs(o)&&(o+=1),h=Bs.constructAssign(t,53).ldexpThis(-o).value(),a.setThis(t).ldexpThis(-o),(0,i.g)(Number.isFinite(h))):(a.setThis(t),h=a.value(),(0,i.g)(Number.isFinite(h)),o=0),h=Math.sqrt(h);const m=Bs.constructDouble(h),l=Bs.constructDouble(n);l.mulThis(m).ldexpThis(1);const c=n*h*2,f=m.clone(),v=new Bs;let _;for(let t=0;t<10;++t){f.mulThis(m),v.setThis(a).subThis(f).absThis();let t=v.value();if(_=1,t<.9)for(;t>c;)t*=t,++_;else _=4;if(v.lte(l))break;for(let t=0;t<_;t++)f.setThis(m).divThis(a).invertThis().addThis(m).ldexpThis(-1).limitPrecisionThis(e),m.setThis(f)}return m.ldexpThis(o/2)}static cubicRoot(t,s){if(t.isZero())return t.clone();let e=52,i=2220446049250313e-31;for(;e<s;)2*e<=s?(i*=i,e*=2):(i*=2220446049250313e-31,e+=52);e+=52;const n=Math.pow(Math.abs(t.value()),1/3),r=Bs.constructDouble(n),u=r.clone();u.sqrThis().mulDoubleThis(3).mulDoubleThis(i),u.limitPrecisionThis(32),t.LZ()&&r.negateThis();for(let s=0;s<10;++s){const s=r.clone();s.sqrThis().mulThis(r);const i=s.clone();if(i.subThis(t),i.absThis().limitPrecisionThis(32),i.lte(u))break;i.setThis(t),i.ldexpThis(1),i.addThis(s);const n=s.clone();n.ldexpThis(1),n.addThis(t),i.divThis(n),r.mulThis(i),r.limitPrecisionThis(e)}return r}isInTheRangeOfDouble(){return(0,i.g)(0),!1}sign(){return this.m_sign}cosAndSin(t,s){(0,i.g)(0)}pow(t){return mt(this,t)}static nan(){return(0,i.g)(0),new Bs}convertToDouble(){if(this.m_bNaN)return Number.NaN;if(this.isZero())return 0;if(0n===this.m_rd.v)return 1===this.m_sign?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY;const t=-1===this.m_sign,s=this.m_rn.v<<(this.m_power>=0?BigInt(this.m_power):0n);let e=this.m_rd.v<<(this.m_power<0?BigInt(-this.m_power):0n);const i=s/e;let n=Number(i);if(BigInt(n)!==i)return t?-n:n;let r=s-i*e;if(r){let t=$t(e)-1023n;t>0n&&(e>>=t,r<<=52n,r>>=t);let s=Number(r);Number.isFinite(s)||(r>>=52n,s=Number(r),t=0n),t>0n&&(s/=Math.pow(2,52)),n+=s/Number(e)}return t?-n:n}signVal(){return 1===this.m_sign?1n:-1===this.m_sign?-1n:0n}opPlusMinus(t,s){const e=Math.min(this.m_power,t.m_power);let i,n;this.m_power>e?(i=BigInt(this.m_power-e),n=0n):(i=0n,n=BigInt(t.m_power-e));const r=this.signVal()*this.m_rn.v*t.m_rd.v<<i,u=t.signVal()*t.m_rn.v*this.m_rd.v<<n;return this.m_rn.v=s?r+u:r-u,this.m_rd.v*=t.m_rd.v,this.m_power=e,this.m_sign=1,this.m_rn.v<0n&&(this.m_sign=-1,this.m_rn.v=-this.m_rn.v),this.m_bNormalized=!1,this.normalizeThis(),this}}Bs.s_sm=0x8000000000000000n,Bs.s_em=0x7ff0000000000000n,Bs.s_fm=0x000fffffffffffffn,Bs.s_emax=0x7ffn;const Rs=Bs.constructInt32(1),ks=Bs.constructInt32(0),Gs=Bs.constructDouble(.5);function Ss(t,s){let e=Yt(t);const i=Yt(s);return e===i?(e-=53-function(t,s){return function(t){let s=0;return 0xffffffff00000000n&t&&(s=32,t>>=32n),s+function(t){let s=0;return 4294901760n&t&&(s+=16,t>>=16n),65280n&t&&(s+=8,t>>=8n),240n&t&&(s+=4,t>>=4n),s+u[Number(BigInt.asUintN(4,t))]+1}(t)}(t^s)}(jt(t),jt(s)),e):e>i?e:i}function Ls(t,s){for(let e=0,i=0,n=t.length;e<n;e+=2,i++)s[i].x=t[e],s[i].y=t[e+1]}function Fs(t){const s=new Float64Array(2*t.length);for(let e=0,i=t.length;e<i;++e){const i=e<<1;s[i]=t[e].x,s[i+1]=t[e].y}return s}function Os(t){const s=It(Qs,t.length);for(let e=0,i=t.length;e<i;++e)s[e].setCoords(t[e][0],t[e][1]);return s}class Qs{static construct(t,s){return new Qs(t,s)}constructor(t,s){void 0!==t?(this.x=t,this.y=s):this.x=this.y=Number.NaN}clone(){return new Qs(this.x,this.y)}assign(t){this.setCoordsPoint2D(t)}setCoords(t,s){return this.x=t,this.y=s,this}setCoordsPoint2D(t){this.x=t.x,this.y=t.y}isEqualPoint2D(t,s){return void 0!==s?Math.abs(this.x-t.x)<=s&&Math.abs(this.y-t.y)<=s:this.x===t.x&&this.y===t.y}isEqual(t,s,e){return void 0!==e?Math.abs(this.x-t)<=e&&Math.abs(this.y-s)<=e:this.x===t&&this.y===s}equalsPoint2D(t,s){return this.isEqualPoint2D(t,s)}setSub(t,s){this.x=t.x-s.x,this.y=t.y-s.y}addThis(t){return this.x+=t.x,this.y+=t.y,this}setAdd(t,s){return this.x=t.x+s.x,this.y=t.y+s.y,this}absoluteOther(t){}absolute(){return(0,i.g)(0),this}setNegate(){this.x=-this.x,this.y=-this.y}setNegateOther(t){this.x=-t.x,this.y=-t.y}interpolateThis(t,s){}interpolate(t,s,e){(0,i.g)(0)}scaleAddThis(t,s){this.x=this.x*t+s.x,this.y=this.y*t+s.y}setScaleAdd(t,s,e){this.x=s.x*t+e.x,this.y=s.y*t+e.y}scaleOther(t,s){(0,i.g)(0)}scale(t){this.x*=t,this.y*=t}compare(t){return this.y<t.y?-1:this.y>t.y?1:this.x<t.x?-1:this.x>t.x?1:0}compareX(t){return this.x<t.x?-1:this.x>t.x?1:this.y<t.y?-1:this.y>t.y?1:0}normalizeOther(t){(0,i.g)(0)}normalize(){const t=this.length();return t?(this.x/=t,this.y/=t):(this.x=1,this.y=0),this}getUnitVector(){return this.clone().normalize()}length(){return Math.sqrt(this.x*this.x+this.y*this.y)}sqrLength(){return this.x*this.x+this.y*this.y}static averageFast(t,s){return(0,i.g)(0),{}}static average(t,s){const e=new Qs;if(0===s)return e.setNAN(),e;if(1===s)return e.assign(t[0]),e;const i=new n(t[0].x),r=new n(t[0].y);for(let e=1;e<s;e++)i.add(t[e].x),r.add(t[e].y),255&e||(i.normalize(),r.normalize());return e.x=i.getResult()/s,e.y=r.getResult()/s,e}static calculateLength(t,s){const e=new n(0);for(let i=1;i<s;i++)e.add(Qs.distance(t[i],t[i-1]));return e.getResult()}offset(t,s){const e=Qs.distance(t,s),i=Qs.construct(this.x,this.y);if(0===e)return Qs.distance(i,t);const n=s.clone();return n.subThis(t),i.subThis(t),i.crossProduct(n)/e}side(t,s){return t.equals(s)?this.equals(t)?0:1:Qs.orientationRobust(s,t,this)}static sqrDistance(t,s){const e=t.x-s.x,i=t.y-s.y;return e*e+i*i}static sqrDistanceCoords(t,s,e,i){const n=e-t,r=i-s;return n*n+r*r}static distance(t,s){return Math.sqrt(Qs.sqrDistance(t,s))}dotProduct(t){return this.x*t.x+this.y*t.y}dotProductAbs(t){return Math.abs(this.x*t.x)+Math.abs(this.y*t.y)}crossProduct(t){return this.x*t.y-this.y*t.x}crossProductAbs(t){return(0,i.g)(0),0}rotateDirect(t,s){const e=this.x*t-this.y*s,i=this.x*s+this.y*t;this.x=e,this.y=i}rotateReverse(t,s){const e=this.x*t+this.y*s,i=-this.x*s+this.y*t;this.x=e,this.y=i}leftPerpendicularThis(){const t=this.x;this.x=-this.y,this.y=t}leftPerpendicularOther(t){const s=t.x;this.x=-t.y,this.y=s}rightPerpendicularThis(){const t=this.x;this.x=this.y,this.y=-t}rightPerpendicularOther(t){const s=t.x;this.x=t.y,this.y=-s}equals(t){return this.x===t.x&&this.y===t.y}notequals(t){return this.x!==t.x||this.y!==t.y}not(){return!this.x&&!this.y}gt(t){return this.y>t.y||this.y===t.y&&this.x>t.x}gte(t){return!this.lt(t)}lt(t){return this.y<t.y||this.y===t.y&&this.x<t.x}lte(t){return!this.gt(t)}subThis(t){return this.x-=t.x,this.y-=t.y,this}divThis(t){return this.x/=t,this.y/=t,this}add(t){return new Qs(this.x+t.x,this.y+t.y)}sub(t){return new Qs(this.x-t.x,this.y-t.y)}negateThis(){return this.x=-this.x,this.y=-this.y,this}negate(){return new Qs(-this.x,-this.y)}mul(t){return new Qs(this.x*t,this.y*t)}mulThis(t){return this.x*=t,this.y*=t,this}divide(t){return new Qs(this.x/t,this.y/t)}setNAN(){this.x=this.y=Number.NaN}isNAN(){return Number.isNaN(this.x)||Number.isNaN(this.y)}static getNAN(){return new Qs(Number.NaN,Number.NaN)}isFinite(){return Number.isFinite(this.x)&&Number.isFinite(this.y)}isZero(){return 0===this.x&&0===this.y}norm(t){switch(t){case 0:{const t=Math.abs(this.x),s=Math.abs(this.y),e=t-s;return e>=0?t:e<=0?s:Number.NaN}case 1:return Math.abs(this.x)+Math.abs(this.y);case 2:return Math.sqrt(this.x*this.x+this.y*this.y);default:(0,i.a)("norm")}}getQuarter(){return Qs.getQuarterCoords(this.x,this.y)}static getQuarterCoords(t,s){return t>0?s>=0?1:4:s>0?2:0===t?4:3}static compareVectors(t,s){const e=t.getQuarter(),i=s.getQuarter();return i===e?Qs.orientationRobustImpl(Qs.construct(0,0),s,t,!0):e<i?-1:1}static compareVectorsOrigin(t,s,e){const i=s.sub(t),n=e.sub(t),r=i.getQuarter(),u=n.getQuarter();return u===r?Qs.orientationRobustImpl(t,e,s,!0):r<u?-1:1}static orientationRobust(t,s,e){return Qs.orientationRobustImpl(t,s,e,!1)}static orientationRobustEx(t,s,e,i){if(t.equals(s)||e.equals(i))return 0;const n=s.x-t.x,r=s.y-t.y,u=i.x-e.x,h=i.y-e.y;{const t=Qs.getQuarterCoords(n,r)-1,s=Qs.getQuarterCoords(u,h)-1,e=Qs.d[t][s];if(0!==e)return e}const o=n*h,a=r*u,m=4*Ts()*(Math.abs(o)+Math.abs(a)),l=o-a;return Math.abs(l)>=m?l<0?-1:l>0?1:0:Qs.orientationRobustExMp(t,s,e,i)}static orientationRobustExMp(t,s,e,i){const n=Bs.constructDouble(s.x),r=Bs.constructDouble(i.x);n.subThis(Bs.constructDouble(t.x)),r.subThis(Bs.constructDouble(e.x));const u=Bs.constructDouble(s.y),h=Bs.constructDouble(i.y);return u.subThis(Bs.constructDouble(t.y)),h.subThis(Bs.constructDouble(e.y)),n.mulThis(h),u.mulThis(r),n.subThis(u),n.LZ()?-1:n.GZ()?1:0}static orientationNonRobust(t,s,e){const i=s.sub(t).crossProduct(e.sub(t));return i<0?-1:i>0?1:0}static orientationRobustImpl(t,s,e,i){if(s.isEqualPoint2D(t)||e.isEqualPoint2D(t)||s.isEqualPoint2D(e))return 0;const n=s.x-t.x,r=s.y-t.y,u=e.x-t.x,h=e.y-t.y;if(!i){const t=Qs.getQuarterCoords(n,r)-1,s=Qs.getQuarterCoords(u,h)-1,e=Qs.d[t][s];if(0!==e)return e}const o=(Math.abs(n)+Math.abs(r)+Math.abs(u)+Math.abs(h))*(Math.abs(s.x)+Math.abs(s.y)+Math.abs(e.x)+Math.abs(e.y))*8*_(),a=n*h-r*u;if(Math.abs(a)>o)return a<0?-1:1;if(v(s.x,t.x)&&v(e.y,t.y)&&v(s.y,t.y)&&v(e.x,t.x)&&c(n,h)&&c(r,u)){const t=n*h,s=r*u;if(v(t,s)){const e=t-s;return e<0?-1:e>0?1:0}}return Qs.orientationRobustMp(t,s,e)}static orientationRobustMp(t,s,e){const i=Bs.constructDouble(s.x),n=Bs.constructDouble(e.x);{const s=Bs.constructDouble(t.x);i.subThis(s),n.subThis(s)}const r=Bs.constructDouble(e.y),u=Bs.constructDouble(s.y);{const s=Bs.constructDouble(t.y);r.subThis(s),u.subThis(s)}return i.mulThis(r),u.mulThis(n),i.subThis(u),i.LZ()?-1:i.GZ()?1:0}static inCircleRobust(t,s,e,i){const n=new l,r=new l;n.set(t.x),n.subThis(i.x),r.set(t.y),r.subThis(i.y);const u=new l,h=new l;u.set(s.x),u.subThis(i.x),h.set(s.y),h.subThis(i.y);const o=new l,a=new l;o.set(e.x),o.subThis(i.x),a.set(e.y),a.subThis(i.y);const m=n.mulE(h).subE(r.mulE(u)),c=u.mulE(a).subE(h.mulE(o)),f=n.mulE(a).subE(r.mulE(o)),v=n.mulE(n).addE(r.mulE(r)),_=u.mulE(u).addE(h.mulE(h)),b=o.mulE(o).addE(a.mulE(a)),d=v.mulE(c).subE(_.mulE(f)).addE(b.mulE(m));if(!d.isFuzzyZero()){const t=d.value();return t<0?-1:t>0?1:0}return Qs.inCircleRobustMp(t,s,e,i)}static inCircleRobustMp(t,s,e,i){do{if(!v(t.x,i.x)||!v(t.y,i.y))break;if(!v(s.x,i.x)||!v(s.y,i.y))break;if(!v(e.x,i.x)||!v(e.y,i.y))break;const n=t.x-i.x,r=t.y-i.y,u=s.x-i.x,h=s.y-i.y,o=e.x-i.x,a=e.y-i.y;if(!c(n,h)||!c(r,u))break;if(!c(u,a)||!c(h,o))break;if(!c(n,a)||!c(r,o))break;if(!c(n,n)||!c(r,r))break;if(!c(u,u)||!c(h,h))break;if(!c(o,o)||!c(a,a))break;const m=n*h,l=r*u,_=u*a,b=h*o,d=n*a,p=r*o,x=n*n,N=r*r,y=u*u,g=h*h,T=o*o,E=a*a;if(!v(m,l))break;if(!v(_,b))break;if(!v(d,p))break;if(!f(x,N))break;if(!f(y,g))break;if(!f(T,E))break;const M=m-l,w=_-b,I=d-p,D=x+N,P=y+g,A=T+E;if(!c(D,w))break;if(!c(P,I))break;if(!c(A,M))break;const q=D*w,z=P*I,C=A*M;if(!v(q,z))break;const Z=q-z;if(!f(Z,C))break;const B=Z+C;return B<0?-1:B>0?1:0}while(0);const n=Bs.constructDouble(i.x),r=Bs.constructDouble(i.y),u=Bs.constructDouble(t.x),h=Bs.constructDouble(t.y);u.subThis(n),h.subThis(r);const o=Bs.constructDouble(s.x),a=Bs.constructDouble(s.y);o.subThis(n),a.subThis(r);const m=Bs.constructDouble(e.x),l=Bs.constructDouble(e.y);m.subThis(n),l.subThis(r);const _=u.mul(a).sub(h.mul(o)),b=o.mul(l).sub(a.mul(m)),d=u.mul(l).sub(h.mul(m)),p=u.mul(u).add(h.mul(h)),x=o.mul(o).add(a.mul(a)),N=m.mul(m).add(l.mul(l)),y=p.mul(b).sub(x.mul(d)).add(N.mul(_));return y.LZ()?-1:y.GZ()?1:0}static inCircleRobustMp3Point(t,s,e){const i=Bs.constructDouble(t.x),n=Bs.constructDouble(t.y),r=Bs.constructDouble(s.x),u=Bs.constructDouble(s.y),h=Bs.constructDouble(e.x),o=Bs.constructDouble(e.y),a=h.mul(h).add(o.mul(o)).sub(h.mul(i).add(o.mul(n)).add(h.mul(r)).add(o.mul(u))).add(i.mul(r).add(n.mul(u)));return a.LZ()?-1:a.GZ()?1:0}static inCircleRobust3Point(t,s,e){const i=new l(t.x),n=new l(t.y),r=new l(s.x),u=new l(s.y),h=new l(e.x),o=new l(e.y),a=h.mulE(h).addE(o.mulE(o)).subE(h.mulE(i).addE(o.mulE(n)).addE(h.mulE(r)).addE(o.mulE(u))).addE(i.mulE(r).addE(n.mulE(u)));if(!a.isFuzzyZero()){const t=a.value();return t<0?-1:t>0?1:0}return Qs.inCircleRobustMp3Point(t,s,e)}static calculateCircleCenterFromThreePoints(t,s,e){if(t.equals(e)||t.equals(s)||e.equals(s))return Qs.getNAN();const i=function(t,s,e){const i=new l(s.x);i.subThis(t.x);const n=new l(s.y);n.subThis(t.y);const r=new l(e.x);r.subThis(t.x);const u=new l(e.y);u.subThis(t.y);const h=i.clone();h.mulThisE(u);let o=n.clone();if(o.mulThisE(r),h.subThisE(o),0===h.value())return Qs.getNAN();h.mulThis(2);const a=i.clone();a.mulThisE(i);const m=n.clone();m.mulThisE(n);const c=a.clone();c.addThisE(m);const f=r.clone();f.mulThisE(r);const v=u.clone();v.mulThisE(u);const _=f.clone();_.addThisE(v);const b=n.clone();b.mulThisE(_),o=u.clone(),o.mulThisE(c),b.subThisE(o),b.divThisE(h);const d=i.clone();d.mulThisE(_),o=r.clone(),o.mulThisE(c),d.subThisE(o),d.divThisE(h);const p=Qs.construct(t.x-b.value(),t.y+d.value()),x=t.sub(p).length(),N=s.sub(p).length(),y=e.sub(p).length(),g=1e-15*(x+Math.abs(t.x)+Math.abs(s.x)+Math.abs(e.x)+Math.abs(t.y)+Math.abs(s.y)+Math.abs(e.y));return Math.abs(x-N)<=g&&Math.abs(x-y)<=g&&b.eps()<g&&d.eps()<g?p:Qs.getNAN()}(t,s,e);return i.isNAN()?function(t,s,e){const i=Bs.constructDouble(s.x);i.subDoubleThis(t.x);const n=Bs.constructDouble(s.y);n.subDoubleThis(t.y);const r=Bs.constructDouble(e.x);r.subDoubleThis(t.x);const u=Bs.constructDouble(e.y);u.subDoubleThis(t.y);const h=i.clone();h.mulThis(u);let o=n.clone();if(o.mulThis(r),h.subThis(o),h.isZero())return Qs.getNAN();h.mulDoubleThis(2);const a=i.clone();a.mulThis(i);const m=n.clone();m.mulThis(n);const l=a.clone();l.addThis(m);const c=r.clone();c.mulThis(r);const f=u.clone();f.mulThis(u);const v=c.clone();v.addThis(f);const _=n.clone();_.mulThis(v),o=u.clone(),o.mulThis(l),_.subThis(o),_.divThis(h);const b=i.clone();return b.mulThis(v),o=r.clone(),o.mulThis(l),b.subThis(o),b.divThis(h),Qs.construct(t.x-_.value(),t.y+b.value())}(t,s,e):i}static calculateAngle(t,s){return Math.atan2(t.crossProduct(s),t.dotProduct(s))}static isBisectorRobust(t,s,e){return(0,i.g)(0),!1}static size(){return 2}get 0(){return this.x}get 1(){return this.y}set 0(t){this.x=t}set 1(t){this.y=t}static compareZorder(t,s){const e=Qs.c_compare_zorder_xx[t.x<0?1:0]|Qs.c_compare_zorder_yy[t.y<0?1:0],i=Qs.c_compare_zorder_xx[s.x<0?1:0]|Qs.c_compare_zorder_yy[s.y<0?1:0];if(e===i){let e=0,i=0;for(let n=0;n<2;++n){const r=Ss(t[n],s[n]);r>e&&(e=r,i=n)}return t[i]<s[i]}return e<i}static lerp(t,s,e){const i=new Qs;return R(t,s,e,i),i}static getClosestCoordinate(t,s,e,i=!1){const n=Qs.getNAN();n.setSub(s,t);const r=n.sqrLength();if(0===r)return.5;if(s.isEqualPoint2D(e))return 1;const u=Qs.getNAN();u.setSub(e,t);let h=u.dotProduct(n)/r;return i||(h<0?h=0:h>1&&(h=1)),h}static intersectLinesAtOnePoint(t,s,e,i){if(t.equals(s)||e.equals(i))return Qs.getNAN();const n=s.x-t.x,r=e.x-i.x,u=s.y-t.y,h=e.y-i.y,o=n*h-r*u;if(!o)return Qs.getNAN();const a=o;if(0===a)return Qs.getNAN();let m=(e.x-t.x)*h-(e.y-t.y)*r;m/=a;const l=new Qs;return R(t,s,m,l),l.isFinite()?l:Qs.getNAN()}toString(){return`[${this.x},${this.y}]`}}Qs.dimensions=2,Qs.d=[[0,1,0,-1],[-1,0,1,0],[0,-1,0,1],[1,0,-1,0]],Qs.c_compare_zorder_xx=[2,0],Qs.c_compare_zorder_yy=[1,0]}}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[7677],{563:(e,t,i)=>{i.d(t,{QueueProcessor:()=>c,SharedConcurrency:()=>h});var s=i(97768),r=i(74887),n=i(9775),o=i(32587),l=i(76030),a=i(44794);class c{constructor(e){this._schedule=null,this._deferreds=new o.A,this._controllers=new o.A,this._processingItems=new o.A,this._pausedSignal=(0,a.v)(!1),this.process=e.process,this.concurrency=e.concurrency,this.sharedConcurrency=e.sharedConcurrency??d,this._queue=new n.A(e.peeker)}destroy(){this.clear(),this._schedule=(0,s.xt)(this._schedule)}get updating(){return this.running}get length(){return this._processingItems.size+this._queue.length}get running(){return!this._pausedSignal.value&&this._queue.length>0&&!this.full}get full(){return this._processingItems.size>=this.concurrency||this.sharedConcurrency.full}abort(e){const t=this._controllers.get(e);t?.abort()}clear(){this._queue.clear();const e=Array.from(this._controllers.values());this._controllers.clear(),e.forEach(e=>e.abort()),this.sharedConcurrency.current.value-=this._processingItems.size,this._processingItems.clear(),this._cancelNext()}forEach(e){this._deferreds.forEach((t,i)=>e(i))}_get(e){const t=this._deferreds.get(e);return t?.promise}pause(){this._pausedSignal.value||(this._pausedSignal.value=!0,this._cancelNext())}push(e,t){const i=this._get(e);if(i)return i;const s=new AbortController,n=(0,r.Tw)(),o=t?(0,r.u7)(t,()=>s.abort()):null,l=(0,r.NY)(s.signal,()=>{const t=this._processingItems.get(e);t&&t.controller.abort(),a(),n.reject((0,r.NK)())}),a=()=>{l.remove(),o?.remove(),this._removeItem(e),this._queue.remove(e),this._scheduleNext()};return this._deferreds.set(e,n),this._controllers.set(e,s),n.promise.then(a,a),this._queue.push(e),this._scheduleNext(),n.promise}last(){return this._queue.last()}reset(){const e=Array.from(this._processingItems.values());this.sharedConcurrency.current.value-=this._processingItems.size,this._processingItems.clear();for(const t of e)this._queue.push(t.item),t.controller.abort();this._scheduleNext()}resume(){this._pausedSignal.value&&(this._pausedSignal.value=!1,this._scheduleNext())}takeAll(){const e=[];for(;this._queue.length;)e.push(this._queue.pop());return this.clear(),e}_removeItem(e){this._deferreds.delete(e),this._controllers.delete(e),this._processingItems.has(e)&&(this._processingItems.delete(e),this.sharedConcurrency.current.value-=1)}_scheduleNext(){this._pausedSignal.value||this._schedule||(this._schedule=(0,l._)(()=>{this._schedule=null,this._next()}))}_next(){for(;this._queue.length>0&&this._processingItems.size<this.concurrency&&!this.sharedConcurrency.full;)this._process(this._queue.pop())}_cancelNext(){this._schedule&&(this._schedule.remove(),this._schedule=null)}_processResult(e,t){this._canProcessFulfillment(e)&&(this._scheduleNext(),this._deferreds.get(e.item).resolve(t))}_processError(e,t){this._canProcessFulfillment(e)&&(this._scheduleNext(),this._deferreds.get(e.item).reject(t))}_canProcessFulfillment(e){return!!this._deferreds.get(e.item)&&this._processingItems.get(e.item)===e}_process(e){if(null==e)return;let t;const i=new AbortController,s=new u(e,i);this._processingItems.set(e,s),this.sharedConcurrency.current.value+=1;try{t=this.process(e,i.signal)}catch(e){this._processError(s,e)}(0,r.$X)(t)?(s.promise=t,t.then(e=>this._processResult(s,e),e=>this._processError(s,e))):this._processResult(s,t)}}class u{constructor(e,t){this.item=e,this.controller=t,this.promise=null}}class h{constructor(e){this.limit=e,this.current=(0,a.v)(0)}get full(){return this.current.value>=this.limit}}const d=new h(1/0)},4916:(e,t,i)=>{i.d(t,{A:()=>N});var s=i(31635),r=i(43773),n=i(49186),o=i(25482),l=i(53966),a=i(74887),c=i(563),u=i(10107),h=i(56507),d=(i(44208),i(87811),i(64108)),p=i(5443),f=i(86738),m=i(16930),g=i(60694),y=i(10873),x=i(45617),_=i(91806),v=i(20223),w=i(87045),b=i(76353),I=i(77301),R=i(70834);const S=new Map,C=new class{constructor(e=15e3,t=5e3){this._timer=null,this._cachedBlocks=new Map,this._size=-1,this._duration=e,this._interval=Math.min(e,t)}decreaseRefCount(e,t){const i=e+"/"+t,s=this._cachedBlocks;if(s.has(i)){const e=s.get(i);return e.refCount--,e.refCount<=0&&(s.delete(i),e.controller&&e.controller.abort()),e.refCount}return 0}getBlock(e,t){const i=e+"/"+t,s=this._cachedBlocks;if(s.has(i)){const e=s.get(i);return e.ts=Date.now(),e.refCount++,s.delete(i),s.set(i,e),e.block}return null}putBlock(e,t,i,s){const r=this._cachedBlocks,n=e+"/"+t;if(r.has(n)){const e=r.get(n);e.ts=Date.now(),e.refCount++}else r.set(n,{block:i,ts:Date.now(),refCount:1,controller:s});this._trim(),this._updateTimer()}deleteBlock(e,t){const i=this._cachedBlocks,s=e+"/"+t;i.has(s)&&i.delete(s)}updateMaxSize(e){this._size=e,this._trim()}empty(){this._cachedBlocks.clear(),this._clearTimer()}getCurrentSize(){return this._cachedBlocks.size}_updateTimer(){if(null!=this._timer)return;const e=this._cachedBlocks;this._timer=setInterval(()=>{const t=Array.from(e),i=Date.now();for(let s=0;s<t.length&&t[s][1].ts<=i-this._duration;s++)e.delete(t[s][0]);0===e.size&&this._clearTimer()},this._interval)}_trim(){const e=this._cachedBlocks;if(-1===this._size||this._size>=e.size)return;const t=Array.from(e);for(let i=0;i<t.length-this._size;i++)e.delete(t[i][0])}_clearTimer(){null!=this._timer&&(clearInterval(this._timer),this._timer=null)}};function k(e,t,i){const s=S.get(e);if(!s)return null==t?C.decreaseRefCount(e,i):0;if(null==t||null==s[t])return C.decreaseRefCount(e,i);const r=s[t]?.cache,n=r?.get(i);if(r&&n){if(n.refCount--,0===n.refCount){r.delete(i);for(let e=0;e<s.length;e++)s[e]?.cache.delete(i);n.controller&&n.controller.abort()}return n.refCount}return 0}function M(e,t,i){const s=S.get(e);if(!s)return null==t?C.getBlock(e,i):null;if(null==t||null==s[t]){for(let e=0;e<s.length;e++){const t=s[e]?.cache.get(i);if(t)return t.refCount++,t.block}return C.getBlock(e,i)}const r=s[t]?.cache.get(i);if(r)return r.refCount++,r.block;for(let e=0;e<s.length;e++){if(e===t||!s[e])continue;const r=s[e]?.cache,n=r?.get(i);if(r&&n)return n.refCount++,r.set(i,n),n.block}return null}function T(e,t,i,s,r=null){const n=S.get(e);if(!n)return void(null==t&&C.putBlock(e,i,s,r));if(null==t||null==n[t])return void C.putBlock(e,i,s,r);const o={refCount:1,block:s,isResolved:!1,isRejected:!1,controller:r};s.then(()=>o.isResolved=!0).catch(()=>o.isRejected=!0),n[t]?.cache.set(i,o)}function A(e,t,i){const s=S.get(e);s?null!=t&&null!=s[t]?s[t]?.cache.delete(i):C.deleteBlock(e,i):null==t&&C.deleteBlock(e,i)}var z=i(16019),F=i(77649),P=i(28435),B=i(14636);let D=0,N=class extends o.o{constructor(){super(...arguments),this._tileFetchQueue=new c.QueueProcessor({concurrency:32,process:(e,t)=>this.fetchRawTile(e.pyramidLevel,e.row,e.col,{...e.options,signal:t})}),this.datasetName=null,this.datasetFormat=null,this.hasUniqueSourceStorageInfo=!0,this.rasterInfo=null,this.ioConfig={sampling:"closest"}}normalizeCtorArgs(e){return e?.ioConfig&&(e={...e,ioConfig:{resolution:null,bandIds:null,sampling:"closest",tileInfo:w.A.create(),...e.ioConfig}}),e}get _isGlobalWrappableSource(){const{rasterInfo:e}=this,t=(0,R.FT)(e.spatialReference);return null!=t&&e.extent.width>=t/2}get _hasNoneOrGCSShiftTransform(){const{transform:e}=this.rasterInfo;return null==e||"gcs-shift"===e.type}set rasterJobHandler(e){this._set("rasterJobHandler",e),(0,b.qg)(this)&&this.primaryRasters?.rasters?.forEach(t=>t.rasterJobHandler=e)}get rasterId(){return this.url||"rasterId-"+D++}set url(e){this._set("url",(0,g.Jf)(e,l.A.getLogger(this)))}async open(e){return this._openPromise??=(0,R.Hh)().then(()=>this._open(e)),this._openPromise}async fetchTile(e,t,i,s={}){const r=s.tileInfo||this.rasterInfo.storageInfo.tileInfo,o=this.getTileExtentFromTileInfo(e,t,i,r);if(!o)throw new n.A("imagery-tile:out-of-bounds","Level for fetch tile out of range");return s={noClip:!0,...s},this.fetchPixels(o,r.size[0],r.size[1],s)}async identify(e,t={}){e=(0,h.PZ)(f.A,e).clone().normalize();const{multidimensionalDefinition:i,timeExtent:s}=t,{rasterInfo:r}=this,{hasMultidimensionalTranspose:n,multidimensionalInfo:o}=r;let{transposedVariableName:l}=t;const a=null!=o&&n&&(null!=s||(0,I.DY)(i));a&&!l&&(l=null!=i&&i.length>0?i[0].variableName??void 0:o.variables[0].name,t={...t,transposedVariableName:l}),t=this._getRequestOptionsWithSliceId(t);const{spatialReference:c,extent:u}=r,{datumTransformation:d}=t;let m=(0,R._I)(e,c,d);if(!u.intersects(m))return{location:m,value:null};if(null!=r.transform){const e=r.transform.inverseTransform(m);if(!r.nativeExtent.intersects(e))return{location:e,value:null};m=e}let g=0;const y=null!=l&&null!=o&&r.hasMultidimensionalTranspose;if((0,b.qg)(this)){const e=this.primaryRasters.rasters[0];if(y)return e.identify(m,t);const{pixelSize:s}=r,n=3,o=s.x*n/2,l=s.y*n/2,a=new p.A({xmin:m.x-o,xmax:m.x+o,ymin:m.y-l,ymax:m.y+l,spatialReference:c}),u={interpolation:"nearest",multidimensionalDefinition:i,sliceId:t.sliceId,bandIds:t.bandIds},{pixelBlock:h}=await e.fetchPixels(a,n,n,u),{pixelBlock:d}=await this.fetchPixels(a,n,n,u);if(null==h)return{location:m,value:null};const f=Math.floor(n*n*.5),g=!h.mask||h.mask[f]?h.pixels.map(e=>e[f]):null;let x;return null!=d&&(x=!d.mask||d.mask[f]?d.pixels.map(e=>e[f]):void 0),{location:m,value:g,processedValue:x,pyramidLevel:0}}if(!y)if(t.srcResolution)g=(0,R.t$)(t.srcResolution,r,this.ioConfig.sampling).pyramidLevel;else if(g=await this.computeBestPyramidLevelForLocation(e,t),null==g)return{location:m,value:null};const x=this.identifyPixelLocation(m,g,null,y);if(null===x)return{location:m,value:null};const{row:_,col:v,rowOffset:w,colOffset:S,blockWidth:C}=x,k=await this._fetchRawTile(g,_,v,t);if(!k?.pixels?.length)return{location:m,value:null};const M=w*C+S;return this._processIdentifyResult(k,{srcLocation:m,position:M,pyramidLevel:g,useTransposedTile:!!y,requestSomeSlices:a,identifyOptions:t})}async fetchPixels(e,t,i,s={}){e=(0,R.Ps)(e),s=this._getRequestOptionsWithSliceId(s);const{_hasNoneOrGCSShiftTransform:r}=this;if(s.requestRawData&&r)return this._fetchPixels(e,t,i,s);const n=(0,R.FT)(e.spatialReference),o=(0,R.OM)(e);if(null==n||0===o||1===o&&this._isGlobalWrappableSource&&r)return this._fetchPixels(e,t,i,s);if(o>=3)return{extent:e,pixelBlock:null};const l=[],{xmin:a,xmax:c}=e,u=Math.round(n/(c-a)*t),h=u-Math.round((n/2-a)/(c-a)*t);let d=0;const f=[];for(let r=0;r<=o;r++){const m=new p.A({xmin:0===r?a:-n/2,xmax:r===o?c-n*r:n/2,ymin:e.ymin,ymax:e.ymax,spatialReference:e.spatialReference}),g=0===r?u-h:r===o?t-d:u;d+=g,f.push(g);const y=s.disableWrapAround&&r>0?null:this._fetchPixels(m,g,i,s);l.push(y)}const m=(await Promise.all(l)).map(e=>e?.pixelBlock);let g=null;const y={width:t,height:i};return g=this.rasterJobHandler?(await this.rasterJobHandler.mosaicAndTransform({srcPixelBlocks:m,srcMosaicSize:y,destDimension:null,coefs:null,sampleSpacing:null,interpolation:"nearest",alignmentInfo:null,blockWidths:f},s)).pixelBlock:(0,P.z7)(m,y,{blockWidths:f}),{extent:e,srcExtent:(0,R._l)(e,this.rasterInfo.spatialReference,s.datumTransformation),pixelBlock:g}}async fetchRawPixels(e,t,i,s={}){t={x:Math.floor(t.x),y:Math.floor(t.y)};const r=await this._fetchRawTiles(e,t,i,s),{nativeExtent:n,nativePixelSize:o,storageInfo:l}=this.rasterInfo,a=2**e,c=o.x*a,u=o.y*a,h=new p.A({xmin:n.xmin+c*t.x,xmax:n.xmin+c*(t.x+i.width-1),ymin:n.ymax-u*(t.y+i.height-1),ymax:n.ymax-u*t.y,spatialReference:n.spatialReference});if(!r)return{extent:h,srcExtent:h,pixelBlock:null};const{pixelBlocks:d,mosaicSize:f}=r;if(1===d.length&&null!=d[0]&&d[0].width===i.width&&d[0].height===i.height)return{extent:h,srcExtent:h,pixelBlock:r.pixelBlocks[0]};const m=e>0?l.pyramidBlockWidth:l.blockWidth,g=e>0?l.pyramidBlockHeight:l.blockHeight,y={x:t.x%m,y:t.y%g};let x;return x=this.rasterJobHandler?(await this.rasterJobHandler.mosaicAndTransform({srcPixelBlocks:d,srcMosaicSize:f,destDimension:i,clipOffset:y,clipSize:i,coefs:null,sampleSpacing:null,interpolation:s.interpolation,alignmentInfo:null,blockWidths:null},s)).pixelBlock:(0,P.z7)(d,f,{clipOffset:y,clipSize:i}),{extent:h,srcExtent:h,pixelBlock:x}}fetchRawTile(e,t,i,s){throw new n.A("BaseRaster:read-not-implemented","fetchRawTile() is not implemented")}computeExtent(e){return(0,R._l)(this.rasterInfo.extent,e)}decodePixelBlock(e,t){return!this.rasterJobHandler||t.useCanvas?(0,F.D)(e,t):this.rasterJobHandler.decode({data:e,options:t})}async request(e,t,i=0){const{customFetchParameters:s}=this.ioConfig,{range:n,query:o,headers:l}=t;i=i??t.retryCount??this.ioConfig.retryCount;const a=n?{Range:`bytes=${n.from}-${n.to}`}:null;try{return await(0,r.A)(e,{...t,query:{...o,...s},headers:{...l,...a}})}catch(s){if(i>0)return i--,this.request(e,t,i);throw s}}getSliceIndex(e){const{multidimensionalInfo:t}=this.rasterInfo;return null==t||null==e||0===e.length?null:(0,I.NG)(e,t)}getTileExtentFromTileInfo(e,t,i,s){const r=s.lodAt(e);return r?this.getTileExtent({x:r.resolution,y:r.resolution},t,i,s.origin,s.spatialReference,s.size):null}updateTileInfo(){const{storageInfo:e,spatialReference:t,extent:i,pixelSize:s}=this.rasterInfo,{pyramidResolutions:r}=e;if(!e.tileInfo){const n=[],o=e.maximumPyramidLevel||0;let l=(s.x+s.y)/2,a=1/.0254*96*l;for(let e=0;e<=o&&(n.unshift(new _.A({level:o-e,resolution:l,scale:a})),e!==o);e++)if(r){const t=(r[e].x+r[e].y)/2;a*=t/l,l=t}else l*=2,a*=2;const c=new f.A({x:i.xmin,y:i.ymax,spatialReference:t});e.tileInfo=new w.A({origin:c,size:[e.blockWidth,e.blockHeight],spatialReference:t,lods:n}),e.isVirtualTileInfo=!0}}createRemoteDatasetStorageInfo(e,t=512,i=512,s){const{width:r,height:n,nativeExtent:o,pixelSize:l,spatialReference:a}=e,c=new f.A({x:o.xmin,y:o.ymax,spatialReference:a});null==s&&(s=Math.max(0,Math.round(Math.log(Math.max(r,n))/Math.LN2-8)));const u=this.computeBlockBoundary(o,512,512,{x:o.xmin,y:o.ymax},[l],s);e.storageInfo=new v.A({blockWidth:t,blockHeight:i,pyramidBlockWidth:t,pyramidBlockHeight:i,origin:c,firstPyramidLevel:1,maximumPyramidLevel:s,blockBoundary:u})}async computeBestPyramidLevelForLocation(e,t={}){return 0}computeBlockBoundary(e,t,i,s,r,n=0,o=2){if(1===r.length&&n>0){r=[...r];let{x:e,y:t}=r[0];for(let i=0;i<n;i++)e*=o,t*=o,r.push({x:e,y:t})}const l=[],{x:a,y:c}=s;for(let s=0;s<r.length;s++){const{x:n,y:o}=r[s];l.push({minCol:Math.floor((e.xmin-a+.1*n)/t/n),maxCol:Math.floor((e.xmax-a-.1*n)/t/n),minRow:Math.floor((c-e.ymax+.1*o)/i/o),maxRow:Math.floor((c-e.ymin-.1*o)/i/o)})}return l}getPyramidPixelSize(e){const{nativePixelSize:t}=this.rasterInfo,{pyramidResolutions:i,pyramidScalingFactor:s}=this.rasterInfo.storageInfo;if(0===e)return t;if(null!=i&&i.length)return i[e-1];const r=s**e;return{x:t.x*r,y:t.y*r}}identifyPixelLocation(e,t,i,s){const{spatialReference:r,nativeExtent:n,storageInfo:o}=this.rasterInfo,{maximumPyramidLevel:l,origin:a,transposeInfo:c}=o,u=s&&null!=c?c.tileSize[0]:o.blockWidth,h=s&&null!=c?c.tileSize[1]:o.blockHeight,d=(0,R._I)(e,r,i);if(!n.intersects(d))return null;if(t<0||t>l)return null;const p=this.getPyramidPixelSize(t),{x:f,y:m}=p,g=(a.y-d.y)/m/h,y=(d.x-a.x)/f/u,x=Math.min(h-1,Math.floor((g-Math.floor(g))*h)),_=Math.min(u-1,Math.floor((y-Math.floor(y))*u));return{pyramidLevel:t,row:Math.floor(g),col:Math.floor(y),rowOffset:x,colOffset:_,blockWidth:u,srcLocation:d}}getTileExtent(e,t,i,s,r,n){const[o,l]=n,a=s.x+i*o*e.x,c=a+o*e.x,u=s.y-t*l*e.y,h=u-l*e.y;return new p.A({xmin:a,xmax:c,ymin:h,ymax:u,spatialReference:r})}getBlockWidthHeight(e){return{blockWidth:e>0?this.rasterInfo.storageInfo.pyramidBlockWidth:this.rasterInfo.storageInfo.blockWidth,blockHeight:e>0?this.rasterInfo.storageInfo.pyramidBlockHeight:this.rasterInfo.storageInfo.blockHeight}}isBlockOutside(e,t,i){const s=this.rasterInfo.storageInfo.blockBoundary[e];return!s||s.maxRow<t||s.maxCol<i||s.minRow>t||s.minCol>i}updateImageSpaceRasterInfo(e){const{pixelSize:t}=e,{width:i,height:s}=e,r=m.A.WebMercator;e.spatialReference=r,e.extent=e.nativeExtent=new p.A({xmin:-.5,ymax:.5,xmax:i-.5,ymin:.5-s,spatialReference:r}),e.isPseudoSpatialReference=!0,e.transform=null,e.pixelSize=new f.A({x:1,y:1,spatialReference:r});const{extent:n,storageInfo:o}=e;if(o){o.origin=new f.A({x:n.xmin,y:n.ymax,spatialReference:r});const{pyramidResolutions:i,tileInfo:s}=o;if(i&&i.forEach(e=>{e.x/=t.x,e.y/=t.y}),s){s.origin=o.origin;const t=(e.nativePixelSize.x+e.nativePixelSize.y)/2;s.lods.forEach((e,i)=>{e.resolution=t*2**i,e.scale=96*e.resolution/.0254})}}}async _fetchPixels(e,t,i,s={}){let r=(0,R.OM)(e);if(r>=2)return{extent:e,pixelBlock:null};const n=this._getSourceDataInfo(e,t,i,s),{pyramidLevel:o,srcResolution:l,srcExtent:a,srcWidth:c,srcHeight:u,ul:h}=n;if(0===c||0===u)return{extent:e,srcExtent:a,pixelBlock:null};const{rasterInfo:d}=this,p=d.transform,m="gcs-shift"===p?.type,g=null!=(0,R.FT)(e.spatialReference);!m&&g||(r=(0,R.OM)(n.srcExtent,m));const y=await this._fetchRawTiles(o,h,{width:c,height:u,wrapCount:r},s);if(!y)return{extent:e,srcExtent:a,pixelBlock:null};const x=d.storageInfo,_=o>0?x.pyramidBlockWidth:x.blockWidth,v=o>0?x.pyramidBlockHeight:x.blockHeight;let{x:w,y:b}=d.pixelSize;if(o>0){const{pyramidResolutions:e,pyramidScalingFactor:t}=x;if(null!=e&&e[o-1])({x:w,y:b}=e[o-1]);else{const e=t**o;w*=e,b*=e}}const I=d.spatialReference,S=new f.A({x:w,y:b,spatialReference:I}),C=_===c&&v===u&&h.x%_===0&&h.y%v===0,k=new f.A({x:(e.xmax-e.xmin)/t,y:(e.ymax-e.ymin)/i,spatialReference:e.spatialReference}),M=!e.spatialReference.equals(I),T=I.isGeographic?1e-9:1e-4,{datumTransformation:A}=s;if(!M&&C&&1===y.pixelBlocks.length&&_===t&&v===i&&function(e,t,i){return Math.abs(e.x-t.x)<i&&Math.abs(e.y-t.y)<i}(l,k,T))return{extent:e,srcExtent:a,srcTilePixelSize:S,pixelBlock:y.pixelBlocks[0]};const z=g&&null!=(0,R.FT)(a.spatialReference)&&this._hasNoneOrGCSShiftTransform,F=s.requestProjectedLocalDirections&&this.rasterInfo.dataType.startsWith("vector");F&&!this.rasterJobHandler&&await(0,R.Hh)();const D=this.rasterJobHandler?await this.rasterJobHandler.getProjectionOffsetGrid({projectedExtent:e,srcBufferExtent:y.extent,pixelSize:k.toJSON(),datumTransformation:A,rasterTransform:p,hasWrapAround:r>0||z,isAdaptive:!1!==this.ioConfig.optimizeProjectionAccuracy,includeGCSGrid:F},s):(0,R.l0)({projectedExtent:e,srcBufferExtent:y.extent,pixelSize:k,datumTransformation:A,rasterTransform:p,hasWrapAround:r>0||z,isAdaptive:!1,includeGCSGrid:F});let N;const J=!s.requestRawData,O={rows:D.spacing[0],cols:D.spacing[1]},H=this._hasNoneOrGCSShiftTransform?this._getRasterTileAlignmentInfo(o,y.extent.xmin):void 0,{pixelBlocks:E,mosaicSize:L,isPartiallyFilled:q}=y;let Z=null;if(this.rasterJobHandler){const e=await this.rasterJobHandler.mosaicAndTransform({srcPixelBlocks:E,srcMosaicSize:L,destDimension:J?{width:t,height:i}:null,coefs:J?D.coefficients:null,sampleSpacing:J?O:null,projectDirections:F,gcsGrid:F?D.gcsGrid:null,isUV:"vector-uv"===this.rasterInfo.dataType,interpolation:s.interpolation,alignmentInfo:H,blockWidths:null},s);({pixelBlock:N,localNorthDirections:Z}=e)}else{const e=(0,P.z7)(E,L,{alignmentInfo:H});N=J?(0,P.$i)(e,{width:t,height:i},D.coefficients,O,s.interpolation):e,F&&D.gcsGrid&&(Z=(0,P.QF)({width:t,height:i},D.gcsGrid),N=(0,B.Y2)(N,this.rasterInfo.dataType,Z))}return s.requestRawData||F?{extent:e,srcExtent:a,srcTilePixelSize:S,pixelBlock:N,transformGrid:D,localNorthDirections:Z,isPartiallyFilled:q}:{extent:e,srcExtent:a,srcTilePixelSize:S,pixelBlock:N}}async _fetchRawTiles(e,t,i,s){const{origin:r,blockBoundary:n}=this.rasterInfo.storageInfo,{blockWidth:o,blockHeight:l}=this.getBlockWidthHeight(e);let{x:a,y:c}=t,{width:u,height:h,wrapCount:d}=i;const f=this._getRasterTileAlignmentInfo(e,0);s.buffer&&(a-=s.buffer.cols,c-=s.buffer.rows,u+=2*s.buffer.cols,h+=2*s.buffer.rows);let m=0,g=0,y=0;d&&null!=f&&(({worldColumnCountFromOrigin:g,originColumnOffset:y,rightPadding:m}=f),g*f.blockWidth-m>=a+u&&(m=0));const x=Math.floor(a/o),_=Math.floor(c/l),v=Math.floor((a+u+m-1)/o),w=Math.floor((c+h+m-1)/l),b=n[e];if(!b)return null;const{minRow:I,minCol:R,maxCol:S,maxRow:C}=b;if(0===d&&(w<I||v<R||_>C||x>S))return null;const k=new Array;let M=!1;const T=null==this.ioConfig.allowPartialFill?s.allowPartialFill:this.ioConfig.allowPartialFill;for(let t=_;t<=w;t++)for(let i=x;i<=v;i++){let r=i;if(!s.disableWrapAround&&d&&null!=f&&g<=i&&(r=i-g-y),t>=I&&r>=R&&C>=t&&S>=r){const i=this._fetchRawTile(e,t,r,s);T?k.push(new Promise(e=>{i.then(t=>e(t)).catch(()=>{M=!0,e(null)})})):k.push(i)}else k.push(Promise.resolve(null))}if(0===k.length)return null;const A=await Promise.all(k),z={height:(w-_+1)*l,width:(v-x+1)*o},{spatialReference:F}=this.rasterInfo,P=this.getPyramidPixelSize(e),{x:B,y:D}=P;return{extent:new p.A({xmin:r.x+x*o*B,xmax:r.x+(v+1)*o*B,ymin:r.y-(w+1)*l*D,ymax:r.y-_*l*D,spatialReference:F}),pixelBlocks:A,mosaicSize:z,isPartiallyFilled:M}}_fetchRawTile(e,t,i,s){const{storageInfo:r}=this.rasterInfo,n=null!=r.transposeInfo&&!!s.transposedVariableName;if(!n){const s=r.blockBoundary[e];if(!s)return Promise.resolve(null);const{minRow:n,minCol:o,maxCol:l,maxRow:a}=s;if(t<n||i<o||t>a||i>l)return Promise.resolve(null)}const o=n?s.transposeVariableName:s.sliceId,l=r.isBsqTile?s.bandIds:null,c=function(e,t,i){const s=[];return null!=t&&s.push(`sliceId=${t}`),null!=i&&s.push(`bandIds=${i.join(",")}`),s.length?`${e}?${s.join("&")}`:e}(this.rasterId,o,l),u=`${e}/${t}/${i}`;let h=M(c,s.registryId,u);if(null==h){const n=new AbortController,o=s.bandIds?.slice();if(o?.length&&r.isBsqTile){const r=new Set(o),l=[],a=Array.from(r);for(const r of o)l.push(this._tileFetchQueue.push({pyramidLevel:e,row:t,col:i,options:{...s,bandIds:[r]}},{signal:n.signal}));h=Promise.all(l).then(e=>{if(e.some(e=>null==e))return null;if(a.length!==o.length){const t=[];for(const i of o){let s=e[a.indexOf(i)];t.includes(s)&&(s=s.clone()),t.push(s)}e=t}return this.rasterJobHandler?this.rasterJobHandler.compositeBands({pixelBlocks:e},{signal:n.signal,transferPixelsToWorker:!0}):(0,P.Wy)(e)})}else h=this._tileFetchQueue.push({pyramidLevel:e,row:t,col:i,options:s},{signal:n.signal});T(c,s.registryId,u,h,n),h.catch(()=>A(c,s.registryId,u))}return s.signal&&(0,a.u7)(s,()=>{k(c,s.registryId,u)}),h}_computeMagDirValues(e){const{bandCount:t,dataType:i}=this.rasterInfo;if((2!==t||"vector-magdir"!==i)&&"vector-uv"!==i||2!==e?.length||!e[0]?.length)return null;const s=e[0].length;if("vector-magdir"===i){const t=e[1].map(e=>(e+360)%360);return[e[0],t]}const[r,n]=e,o=[],l=[];for(let e=0;e<s;e++){const[t,i]=(0,B.Lu)([r[e],n[e]]);o.push(t),l.push(i)}return[o,l]}_getRasterTileAlignmentInfo(e,t){return null==this._rasterTileAlignmentInfo&&(this._rasterTileAlignmentInfo=(0,R.DO)(this.rasterInfo)),null==this._rasterTileAlignmentInfo.pyramidsInfo?null:{startX:t,halfWorldWidth:this._rasterTileAlignmentInfo.halfWorldWidth,hasGCSSShiftTransform:this._rasterTileAlignmentInfo.hasGCSSShiftTransform,...this._rasterTileAlignmentInfo.pyramidsInfo[e]}}_getSourceDataInfo(e,t,i,s={}){const r={datumTransformation:s.datumTransformation,pyramidLevel:0,pyramidResolution:null,srcExtent:null,srcHeight:0,srcResolution:null,srcWidth:0,ul:{x:0,y:0}};s.srcResolution&&(r.srcResolution=s.srcResolution,this._updateSourceDataInfo(e,r));const n=this.rasterInfo.storageInfo.maximumPyramidLevel||0,{srcWidth:o,srcHeight:l,pyramidLevel:a}=r,c=o/t,u=l/i,h=a<n&&c*u>=16,d=a===n&&this._requireTooManySrcTiles(o,l,t,i);if(h||d||0===o||0===l){const o=new f.A({x:(e.xmax-e.xmin)/t,y:(e.ymax-e.ymin)/i,spatialReference:e.spatialReference});let l=(0,R.Wo)(o,this.rasterInfo.spatialReference,e,r.datumTransformation);const d=!l||s.srcResolution&&l.x+l.y<s.srcResolution.x+s.srcResolution.y;if(h&&s.srcResolution&&d){const e=Math.round(Math.log(Math.max(c,u))/Math.LN2)-1;if(n-a+3>=e){const t=2**e;l={x:s.srcResolution.x*t,y:s.srcResolution.y*t}}}l&&(r.srcResolution=l,this._updateSourceDataInfo(e,r))}return this._requireTooManySrcTiles(r.srcWidth,r.srcHeight,t,i)&&(r.srcWidth=0,r.srcHeight=0),r}_requireTooManySrcTiles(e,t,i,s){const{tileInfo:r}=this.rasterInfo.storageInfo,n=e/i,o=t/s;return Math.ceil(e/r.size[0])*Math.ceil(t/r.size[1])>=256*Math.max(1,(i+s)/1024)||n>8||o>8}_updateSourceDataInfo(e,t){t.srcWidth=0,t.srcHeight=0;const{rasterInfo:i}=this,s=i.spatialReference,{srcResolution:r,datumTransformation:n}=t,{pyramidLevel:o,pyramidResolution:l,excessiveReading:a}=(0,R.t$)(r,i,this.ioConfig.sampling);if(a)return;let c=t.srcExtent||(0,R._l)(e,s,n);if(null==c)return;const u=i.transform;u&&(c=u.inverseTransform(c)),t.srcExtent=c;const{origin:h}=i.storageInfo,{width:d,height:p,ul:f}=(0,b.$g)(c,h,l,o);t.pyramidLevel=o,t.pyramidResolution=l,t.srcWidth=d,t.srcHeight=p,t.ul=f}_getRequestOptionsWithSliceId(e){return null!=this.rasterInfo.multidimensionalInfo&&null==e.sliceId&&(e={...e,sliceId:this.getSliceIndex(e.multidimensionalDefinition)}),e}_processIdentifyResult(e,t){const{srcLocation:i,position:s,pyramidLevel:r,useTransposedTile:n}=t,o=e.pixels[0].length/e.width/e.height;if(e.mask&&!e.mask[s])return{location:i,value:null};const{multidimensionalInfo:l}=this.rasterInfo;if(null==l||!n){const t=e.pixels.map(e=>e[s]),n={location:i,value:t,pyramidLevel:r},o=this._computeMagDirValues(t.map(e=>[e]));return o?.length&&(n.magdirValue=o.map(e=>e[0])),n}let a=e.pixels.map(e=>e.slice(s*o,s*o+o)),c=this._computeMagDirValues(a);const{requestSomeSlices:u,identifyOptions:h}=t;let d=(0,I.QW)(l,h.transposedVariableName);if(u){const e=(0,I.xx)(d,h.multidimensionalDefinition,h.timeExtent);a=a.map(t=>e.map(e=>t[e])),c=c?.map(t=>e.map(e=>t[e])),d=e.map(e=>d[e])}const p=e.noDataValues||this.rasterInfo.noDataValue,f={pixels:a,pixelType:e.pixelType};let m;return null!=p&&((0,z.Sp)(f,p),m=f.mask),{location:i,value:null,dataSeries:d.map((e,t)=>{const i={value:0===m?.[t]?null:a.map(e=>e[t]),multidimensionalDefinition:e.multidimensionalDefinition.map(e=>new x.A({...e,isSlice:!0}))};return c?.length&&(i.magdirValue=[c[0][t],c[1][t]]),i}),pyramidLevel:r}}};(0,s.Cg)([(0,u.MZ)()],N.prototype,"_rasterTileAlignmentInfo",void 0),(0,s.Cg)([(0,u.MZ)()],N.prototype,"_tileFetchQueue",void 0),(0,s.Cg)([(0,u.MZ)({readOnly:!0})],N.prototype,"_isGlobalWrappableSource",null),(0,s.Cg)([(0,u.MZ)({readOnly:!0})],N.prototype,"_hasNoneOrGCSShiftTransform",null),(0,s.Cg)([(0,u.MZ)()],N.prototype,"_openPromise",void 0),(0,s.Cg)([(0,u.MZ)()],N.prototype,"rasterJobHandler",null),(0,s.Cg)([(0,u.MZ)({readOnly:!0})],N.prototype,"rasterId",null),(0,s.Cg)([(0,u.MZ)(y.OZ)],N.prototype,"url",null),(0,s.Cg)([(0,u.MZ)({type:String,json:{write:!0}})],N.prototype,"datasetName",void 0),(0,s.Cg)([(0,u.MZ)({type:String,json:{write:!0}})],N.prototype,"datasetFormat",void 0),(0,s.Cg)([(0,u.MZ)()],N.prototype,"hasUniqueSourceStorageInfo",void 0),(0,s.Cg)([(0,u.MZ)()],N.prototype,"rasterInfo",void 0),(0,s.Cg)([(0,u.MZ)()],N.prototype,"ioConfig",void 0),(0,s.Cg)([(0,u.MZ)()],N.prototype,"sourceJSON",void 0),N=(0,s.Cg)([(0,d.$)("esri.layers.support.rasterDatasets.BaseRaster")],N)},32587:(e,t,i)=>{i.d(t,{A:()=>n});var s=i(62788),r=i(95488);class n{constructor(e){this._observable=new r.I,this._map=new Map(e)}get size(){return(0,s.gc)(this._observable),this._map.size}clear(){this._map.size>0&&(this._map.clear(),this._observable.notify())}delete(e){const t=this._map.delete(e);return t&&this._observable.notify(),t}entries(){return(0,s.gc)(this._observable),this._map.entries()}forEach(e,t){(0,s.gc)(this._observable),this._map.forEach((i,s)=>e.call(t,i,s,this),t)}get(e){return(0,s.gc)(this._observable),this._map.get(e)}has(e){return(0,s.gc)(this._observable),this._map.has(e)}keys(){return(0,s.gc)(this._observable),this._map.keys()}set(e,t){return this._map.set(e,t),this._observable.notify(),this}values(){return(0,s.gc)(this._observable),this._map.values()}[Symbol.iterator](){return(0,s.gc)(this._observable),this._map[Symbol.iterator]()}[Symbol.dispose](){this._observable.destroy()}get[Symbol.toStringTag](){return this._map[Symbol.toStringTag]}}},44794:(e,t,i)=>{i.d(t,{v:()=>l});var s=i(4718),r=i(62788),n=i(95488);class o{constructor(e,t){this._observable=new n.I,this._value=e,this._equalityFunction=t}get value(){return(0,r.gc)(this._observable),this._value}set value(e){this._equalityFunction(e,this._value)||(this._value=e,this._observable.notify())}mutate(e){e(this._value),this._observable.notify()}}function l(e,t=s.gh){return new o(e,t)}},50103:(e,t,i)=>{function s(e,t){if(!e||!t)return[];let i=t;t.includes("/")?(i=t.slice(0,t.indexOf("/")),t=t.slice(t.indexOf("/")+1)):t="";const r=[];if(t){const n=s(e,i);for(let e=0;e<n.length;e++)s(n[e],t).forEach(e=>r.push(e));return r}const n=e.getElementsByTagNameNS("*",i);if(!n||0===n.length)return[];for(let e=0;e<n.length;e++)r.push(n[e]||n.item(e));return r}function r(e,t){if(!e||!t)return null;let i=t;t.includes("/")?(i=t.slice(0,t.indexOf("/")),t=t.slice(t.indexOf("/")+1)):t="";const n=s(e,i);return n.length>0?t?r(n[0],t):n[0]:null}function n(e,t=null){const i=t?r(e,t):e;let s;return i?(s=i.textContent||i.nodeValue,s?s.trim():null):null}function o(e,t){const i=s(e,t),r=[];let n;for(let e=0;e<i.length;e++)n=i[e].textContent||i[e].nodeValue,n&&(n=n.trim(),""!==n&&r.push(n));return r}function l(e,t=null){const i=n(e,t);return i?.split(" ").map(e=>Number(e))??[]}function a(e,t){return o(e,t).map(e=>Number(e))}function c(e,t){const i=n(e,t);return Number(i)}function u(e,t){const i=e?.nodeName?.toLowerCase(),s=t.toLowerCase();return i.slice(i.lastIndexOf(":")+1)===s}function h(e){return e.nodeName.slice(e.nodeName.lastIndexOf(":")+1)}i.d(t,{Dy:()=>o,IC:()=>s,Ui:()=>a,V6:()=>r,g7:()=>u,mX:()=>n,pN:()=>l,v7:()=>c,vv:()=>h})},72802:(e,t,i)=>{i.d(t,{U:()=>r});var s=i(19419);class r{constructor(e,t,i,r=(0,s.vt)()){this._level=e,this._row=t,this._col=i,this.extent=r}get id(){return this._id??=`${this.level}/${this.row}/${this.col}`,this._id}get level(){return this._level}set level(e){this._level=e,this._id=null}get row(){return this._row}set row(e){this._row=e,this._id=null}get col(){return this._col}set col(e){this._col=e,this._id=null}toJSON(){return{level:this._level,row:this._row,col:this._col,extent:this.extent}}static fromJSON(e){return new r(e.level,e.row,e.col,e.extent)}}},84169:(e,t,i)=>{i.d(t,{A:()=>p});var s=i(31635),r=i(49186),n=i(10107),o=(i(44208),i(53966),i(87811),i(64108)),l=i(39829),a=i(4916),c=i(77359),u=i(28435),h=i(70834),d=i(22671);let p=class extends a.A{constructor(){super(...arguments),this.datasetFormat="Function",this.tileType="Raster",this.rasterFunction=null,this._clippingGeometry=new Map}async fetchPixels(e,t,i,s={}){const{rasters:r,rasterIds:n}=this.primaryRasters;let o=!1;const{interpolation:l}=s,a=this.rasterFunction.flatWebGLFunctionChain?.hasFocalFunction;!s.requestRawData&&a&&(o=1===r.length&&!s.skipRasterFunction,s={...s,interpolation:"bilinear",requestRawData:o}),s.requestRawData&&r.length>1&&!this.hasUniqueSourceStorageInfo&&(o=!1,s={...s,requestRawData:!1});const h=r.map(r=>r.fetchPixels(e,t,i,s)),d=await Promise.all(h),p=d.map(e=>e.pixelBlock),f=o||s.requestRawData?d.map(e=>e.srcTilePixelSize):null;if(s.skipRasterFunction||p.every(e=>null==e))return d[0];const m=d.find(e=>null!=e.pixelBlock)?.extent??e;let g=this.rasterJobHandler?await this.rasterJobHandler.process({extent:m,primaryPixelBlocks:p,primaryPixelSizes:f,primaryRasterIds:n}):this.rasterFunction.process({extent:m,primaryPixelBlocks:p,primaryPixelSizes:f,primaryRasterIds:n});const{transformGrid:y}=d[0];if(!o||null==g||null==y){const e=s.noClip?null:this.getClippingGeometry(m.spatialReference);return!s.noClip&&null!=g&&e&&(g=await(0,c.$Q)(g,m,e)),{...d[0],pixelBlock:g}}const x={rows:y.spacing[0],cols:y.spacing[1]};let _;_=this.rasterJobHandler?(await this.rasterJobHandler.mosaicAndTransform({srcPixelBlocks:[g],srcMosaicSize:{width:g.width,height:g.height},destDimension:{width:t,height:i},coefs:y.coefficients,sampleSpacing:x,projectDirections:!1,gcsGrid:null,isUV:!1,interpolation:l,alignmentInfo:void 0,blockWidths:null},s)).pixelBlock:(0,u.$i)(g,{width:t,height:i},y.coefficients,x,l);const v=s.noClip?null:this.getClippingGeometry(e.spatialReference);return s.noClip||null==_||null==v||(_=await(0,c.$Q)(_,e,v)),{extent:e,srcExtent:d[0].srcExtent,pixelBlock:_}}getClippingGeometry(e){const t=this._clippingGeometry.get("0");if(!e||!t)return t;const i=function(e){return String(e.wkid??e.wkt??e.wkt2)}(e);let s=this._clippingGeometry.get(i);return null!=s||(s=e.equals(t.spatialReference)?t:(0,h.uk)(t,e),this._clippingGeometry.set(i,s)),s}async _open(e){const{rasterFunction:t}=this;t.isRoot=!0,this.primaryRasters?.rasters?.length?t.sourceRasters=this.primaryRasters.rasters:(this.primaryRasters=t.getPrimaryRasters(),this.rasterJobHandler&&this.primaryRasters.rasters?.forEach(e=>e.rasterJobHandler=this.rasterJobHandler));const{rasters:i,rasterIds:s}=this.primaryRasters,n=i.map(t=>t.rasterInfo?void 0:t.open(e));await Promise.all(n);const o=i.map(({rasterInfo:e})=>e),l=t.bind({rasterInfos:o,rasterIds:s});if(t.rawSourceRasterInfos=o,!l.success||0===o.length)throw new r.A("raster-function:open",`cannot bind the function: ${l.error??""}`);const a="Table"===t.functionName?t:t.functionArguments?.raster;"Table"===a?.functionName&&(t.rasterInfo.attributeTable=d.A.fromJSON(a.functionArguments.attributeTableAsRecordSet)),await this.syncJobHandler();const c=o[0];this.hasUniqueSourceStorageInfo=1===o.length||o.slice(1).every(e=>function(e,t){const{storageInfo:i,pixelSize:s,spatialReference:r,extent:n}=e,{storageInfo:o,pixelSize:l,spatialReference:a,extent:c}=t;return s.x===l.x&&s.y===l.y&&r.equals(a)&&n.equals(c)&&i.blockHeight===o.blockHeight&&i.blockWidth===o.blockWidth&&i.maximumPyramidLevel===o.maximumPyramidLevel&&i.firstPyramidLevel===o.firstPyramidLevel&&i.pyramidBlockWidth===o.pyramidBlockWidth&&i.pyramidBlockHeight===o.pyramidBlockHeight&&i.pyramidScalingFactor===o.pyramidScalingFactor}(e,c)),this.set("sourceJSON",i[0].sourceJSON),this.set("rasterInfo",t.rasterInfo),await this._updateClipGeometry()}async syncJobHandler(){return this.rasterJobHandler?.updateRasterFunction(this.rasterFunction)}async _updateClipGeometry(){const e=this.rasterFunction.getClippingGeometries()[0];let t=e?.clippingGeometry;if(t&&"inside"===e.clippingType){const{extent:e}=this.rasterInfo,s=await Promise.all([i.e(3661),i.e(1878),i.e(9117),i.e(3299),i.e(8411)]).then(i.bind(i,88411)),r=await Promise.all([i.e(3661),i.e(1878),i.e(9117),i.e(3299),i.e(3054)]).then(i.bind(i,93054));let n=s.execute(l.A.fromExtent(e),2*(e.width+e.height)/40);n=(0,h.uk)(n,t.spatialReference),t=r.execute(n,t)}this._clippingGeometry.clear(),t&&this._clippingGeometry.set("0",t)}};(0,s.Cg)([(0,n.MZ)({type:String,json:{write:!0}})],p.prototype,"datasetFormat",void 0),(0,s.Cg)([(0,n.MZ)()],p.prototype,"tileType",void 0),(0,s.Cg)([(0,n.MZ)()],p.prototype,"rasterFunction",void 0),(0,s.Cg)([(0,n.MZ)()],p.prototype,"primaryRasters",void 0),p=(0,s.Cg)([(0,o.$)("esri.layers.support.rasterDatasets.FunctionRaster")],p)},87045:(e,t,i)=>{i.d(t,{A:()=>v});var s,r=i(31635),n=i(66552),o=i(25482),l=i(83047),a=i(10107),c=i(56507),u=(i(44208),i(87811),i(36005)),h=i(64108),d=i(43937),p=i(86738),f=i(16930),m=i(21325),g=i(28735),y=i(91806),x=i(72802);const _=new n.J({PNG:"png",PNG8:"png8",PNG24:"png24",PNG32:"png32",JPEG:"jpg",JPG:"jpg",DIB:"dib",TIFF:"tiff",EMF:"emf",PS:"ps",PDF:"pdf",GIF:"gif",SVG:"svg",SVGZ:"svgz",Mixed:"mixed",MIXED:"mixed",LERC:"lerc",LERC2D:"lerc2d",RAW:"raw",pbf:"pbf"});let v=class extends o.o{static{s=this}static create(e={}){const{resolutionFactor:t=1,scales:i,size:r=256,spatialReference:n=f.A.WebMercator,numLODs:o=24}=e;if(!(0,m.fn)(n)){const e=[];if(i)for(let t=0;t<i.length;t++){const s=i[t];e.push(new y.A({level:t,scale:s,resolution:s}))}else{let t=5e-4;for(let i=o-1;i>=0;i--)e.unshift(new y.A({level:i,scale:t,resolution:t})),t*=2}return new s({dpi:96,lods:e,origin:new p.A(0,0,n),size:[r,r],spatialReference:n})}const a=(0,m.Vp)(n),c=e.origin?new p.A({x:e.origin.x,y:e.origin.y,spatialReference:n}):new p.A(a?{x:a.origin[0],y:a.origin[1],spatialReference:n}:{x:0,y:0,spatialReference:n}),u=1/(39.37*(0,l.GA)(n)*96),h=[];if(i)for(let e=0;e<i.length;e++){const t=i[e],s=t*u;h.push(new y.A({level:e,scale:t,resolution:s}))}else{let e=(0,m.EA)(n)?512/r*591657527.5917094:256/r*591657527.591555;const i=Math.ceil(o/t);h.push(new y.A({level:0,scale:e,resolution:e*u}));for(let s=1;s<i;s++){const i=e/2**t,r=i*u;h.push(new y.A({level:s,scale:i,resolution:r})),e=i}}return new s({dpi:96,lods:h,origin:c,size:[r,r],spatialReference:n})}constructor(e){super(e),this.dpi=96,this.format=null,this.origin=null,this.size=null,this.spatialReference=null}get isWrappable(){const{spatialReference:e,origin:t}=this;if(e&&t){const i=(0,m.Vp)(e);return e.isWrappable&&!!i&&Math.abs(i.origin[0]-t.x)<=i.dx}return!1}readOrigin(e,t){return p.A.fromJSON({spatialReference:t.spatialReference,...e})}set lods(e){let t=0,i=0;const s=[],r=this._levelToLOD={};e&&(t=-1/0,i=1/0,e.forEach(e=>{s.push(e.scale),t=e.scale>t?e.scale:t,i=e.scale<i?e.scale:i,r[e.level]=e})),this._set("scales",s),this._set("lods",e),this._initializeUpsampleLevels()}readSize(e,t){return[t.cols,t.rows]}writeSize(e,t){t.cols=e[0],t.rows=e[1]}zoomToScale(e){const t=this.scales;if(e<=0)return t[0];if(e>=t.length-1)return t[t.length-1];const i=Math.floor(e),s=i+1;return t[i]/(t[i]/t[s])**(e-i)}scaleToZoom(e){const t=this.scales,i=t.length-1;let s=0;for(;s<i;s++){const i=t[s],r=t[s+1];if(i<=e)return s;if(r===e)return s+1;if(i>e&&r<e)return s+Math.log(i/e)/Math.log(i/r)}return s}tileAt(e,t,i,s){const r=this.lodAt(e);if(!r)return null;let n,o;if("number"==typeof t)n=t,o=i;else if((0,m.aI)(t.spatialReference,this.spatialReference))n=t.x,o=t.y,s=i;else{const e=(0,g.Cv)(t,this.spatialReference);if(null==e)return null;n=e.x,o=e.y,s=i}const l=r.resolution*this.size[0],a=r.resolution*this.size[1];return s??=new x.U(0,0,0),s.level=e,s.row=Math.floor((this.origin.y-o)/a+.001),s.col=Math.floor((n-this.origin.x)/l+.001),this.updateTileInfo(s),s}updateTileInfo(e,t=0){if(!("extent"in e))return!1;let i=this.lodAt(e.level);if(!i&&1===t){const t=this.lods[this.lods.length-1];t.level<e.level&&(i=t)}if(!i)return!1;const s=e.level-i.level,r=i.resolution*this.size[0]/2**s,n=i.resolution*this.size[1]/2**s;return e.extent[0]=this.origin.x+e.col*r,e.extent[1]=this.origin.y-(e.row+1)*n,e.extent[2]=e.extent[0]+r,e.extent[3]=e.extent[1]+n,!0}upsampleTile(e){const t=this._upsampleLevels[e.level];return!(!t||-1===t.parentLevel||(e.level=t.parentLevel,e.row=Math.floor(e.row/t.factor+.001),e.col=Math.floor(e.col/t.factor+.001),this.updateTileInfo(e),0))}getTileBounds(e,t){const i=this.lodAt(t.level);if(null==i)return null;const{resolution:s}=i,r=s*this.size[0],n=s*this.size[1];return e[0]=this.origin.x+t.col*r,e[1]=this.origin.y-(t.row+1)*n,e[2]=e[0]+r,e[3]=e[1]+n,e}lodAt(e){return this._levelToLOD?.[e]??null}clone(){return s.fromJSON(this.write({}))}getCompatibleForVTL(e){if(this.size[0]!==this.size[1]||256===this.size[0]&&512===e)return null;const t=(512===this.size[0]&&256===e?-1:0)+(this.spatialReference.isGeographic?1:0);if(this.size[0]===e&&0===t)return this;const i=[],r=this.lods.length-t;for(let e=0;e<r;e++){const s=e+t,{scale:r,resolution:n}=s>=0?this.lods[s]:{scale:2*this.lods[0].scale,resolution:2*this.lods[0].resolution};i.push(new y.A({level:e,scale:r,resolution:n}))}return new s({size:[e,e],dpi:this.dpi,format:this.format,compressionQuality:this.compressionQuality,origin:this.origin,spatialReference:this.spatialReference,lods:i})}_initializeUpsampleLevels(){const e=this.lods;this._upsampleLevels=[];let t=null;for(let i=0;i<e.length;i++){const s=e[i];this._upsampleLevels[s.level]={parentLevel:t?t.level:-1,factor:t?t.resolution/s.resolution:0},t=s}}};(0,r.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],v.prototype,"compressionQuality",void 0),(0,r.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],v.prototype,"dpi",void 0),(0,r.Cg)([(0,a.MZ)({type:String,json:{read:_.read,write:_.write,origins:{"web-scene":{read:!1,write:!1}}}})],v.prototype,"format",void 0),(0,r.Cg)([(0,a.MZ)({readOnly:!0})],v.prototype,"isWrappable",null),(0,r.Cg)([(0,a.MZ)({type:p.A,json:{write:!0}})],v.prototype,"origin",void 0),(0,r.Cg)([(0,u.w)("origin")],v.prototype,"readOrigin",null),(0,r.Cg)([(0,a.MZ)({type:[y.A],value:null,json:{write:!0}})],v.prototype,"lods",null),(0,r.Cg)([(0,a.MZ)({readOnly:!0})],v.prototype,"scales",void 0),(0,r.Cg)([(0,a.MZ)({cast:e=>Array.isArray(e)?e:"number"==typeof e?[e,e]:[256,256]})],v.prototype,"size",void 0),(0,r.Cg)([(0,u.w)("size",["rows","cols"])],v.prototype,"readSize",null),(0,r.Cg)([(0,d.K)("size",{cols:{type:c.jz},rows:{type:c.jz}})],v.prototype,"writeSize",null),(0,r.Cg)([(0,a.MZ)({type:f.A,json:{write:!0}})],v.prototype,"spatialReference",void 0),v=s=(0,r.Cg)([(0,h.$)("esri.layers.support.TileInfo")],v)},89015:(e,t,i)=>{i.d(t,{o:()=>N});var s=i(31635),r=i(43773),n=i(49186),o=i(53966),l=i(10107),a=i(56507),c=(i(44208),i(87811),i(93223)),u=i(36005),h=i(64108),d=i(86738),p=i(16930),f=i(21325),m=i(60694),g=i(10873),y=i(45617),x=i(43577),_=i(13868),v=i(22796),w=i(87045),b=i(76353),I=i(84169),R=i(77301),S=i(77359),C=i(6049),k=i(70834),M=i(6952),T=i(12711),A=i(85676),z=i(94359),F=i(22048),P=i(49410),B=i(34606),D=i(51508);const N=e=>{const t=e;let N=class extends t{constructor(...e){super(...e),this._isConstructedFromFunctionRaster=!1,this.bandIds=null,this.copyright=null,this.interpolation=null,this.multidimensionalSubset=null,this.raster=null,this.serviceRasterInfo=null,this.sourceJSON=null,this.spatialReference=null,this.symbolizer=null,this._isConstructedFromFunctionRaster=(0,b.qg)(e[0]?.raster)}destroy(){this._shutdownJobHandler()}get fullExtent(){return this.serviceRasterInfo?.extent}set multidimensionalDefinition(e){this._set("multidimensionalDefinition",e),this.updateRenderer()}set rasterFunction(e){"none"===e?.functionName?.toLowerCase()&&(e=void 0),this._set("rasterFunction",e),this.updateRasterFunction()}set url(e){this._set("url",(0,m.Jf)(e,o.A.getLogger(this)))}get renderer(){if("imagery-tile"!==this.type)return this.internalRenderer;const{activePresetRendererName:e,presetRenderers:t}=this;if(e){const i=t?.find(({name:t})=>t===e);return i?.renderer.clone()}return this.internalRenderer}set renderer(e){"imagery-tile"===this.type&&(this.activePresetRendererName=null),this.internalRenderer=e}set internalRenderer(e){null==e&&null==this.rasterFunction?this._configDefaultRenderer("override"):(this._set("internalRenderer",e),this.updateRenderer())}readRenderer(e,t,i){const s=t?.layerDefinition?.drawingInfo?.renderer;return(0,z.LF)(s,i)||void 0}async computeStatisticsHistograms(e,t){await this.load(t),e=(0,a.PZ)(F.A,e).clone();const{serviceRasterInfo:i}=this;if(null==i)throw new n.A("imagery-tile-mixin:compute-statistics-histograms","serviceRasterInfo must be specified");const{geometry:s}=e;if(null==s)throw new n.A("imagery-tile-mixin:compute-statistics-histograms","geometry must be specified");let r=s;const{spatialReference:o}=i;if(!s.spatialReference.equals(o)){await(0,k.Hh)();const e="extent"===s.type?(0,k._l)(s,o):(0,k.uk)(s,o);if(null==e)throw new n.A("imagery-tile-mixin:compute-statistics-histograms","geometry cannot be projected to the data source");r=e}const l=e.pixelSize??new d.A({x:i.pixelSize.x,y:i.pixelSize.y,spatialReference:o}),{extent:c,width:u,height:h}=(0,S.b7)(i,r,l),p=await this.fetchPixels(c,u,h,{...t,interpolation:"nearest"});if(null==p.pixelBlock)throw new n.A("imagery-tile-mixin:compute-statistics-histograms","failed to fetch pixels");const f=await(0,S.$Q)(p.pixelBlock,c,r),m=this._rasterJobHandler;return m?m.computeStatisticsHistograms({pixelBlock:f},t):(0,M.eH)(f)}normalizeRasterFetchOptions(e){const{multidimensionalInfo:t}=this.serviceRasterInfo??{};if(null==t)return e;const i=(0,R.XU)({rasterInfo:this.raster.rasterInfo,multidimensionalDefinition:e.multidimensionalDefinition||this.multidimensionalDefinition,timeExtent:e.timeExtent??this.timeExtent,multidimensionalSubset:this.multidimensionalSubset});return{...e,multidimensionalDefinition:i,timeExtent:void 0}}async updateRasterFunction(){return this.loaded&&"imagery-tile"===this.type&&(this.rasterFunction||this._cachedRasterFunctionJson)&&JSON.stringify(this.rasterFunction)!==JSON.stringify(this._cachedRasterFunctionJson)?(this._cachedRasterFunctionJson=this.rasterFunction?.toJSON(),this._rasterFunctionUpdatePromise=this._updateRasterFunction(),this._rasterFunctionUpdatePromise):this._rasterFunctionUpdatePromise}async updateRenderer(){const{loaded:e,symbolizer:t,renderer:i}=this;if(!e||!t||!i)return;const{rasterInfo:s}=this.raster,r=(0,R.ct)(s,{multidimensionalDefinition:this.multidimensionalDefinition,multidimensionalSubset:this.multidimensionalSubset}),n=r?.name,o=(0,T.m7)(s,n);return this._updateSymbolizer(t,i,n,o)}async applyRenderer(e,t,i){const s=e?.pixelBlock;if(!(null!=s&&s.pixels&&s.pixels.length>0))return null;await this.updateRenderer();const r=this.bandIds??[],{pixelBlock:n}=await this._symbolize({pixelData:e,simpleStretchParams:t,bandIds:r,symbolizer:this.symbolizer},i);return n}getRawDisplayBandIds(){let{bandIds:e,raster:t}=this;if(this.rasterFunction&&(0,b.qg)(t)){const i=t.rasterFunction.rawInputBandIds;e=e?.length&&i?.length&&1!==t.rasterInfo.bandCount?e.map(e=>i[Math.min(e,i.length-1)]):i}return e&&e.length>3&&e.every((e,t)=>e===t)?null:e}getTileUrl(e,t,i){return"RasterTileServer"===this.raster.datasetFormat?`${this.url}/tile/${e}/${t}/${i}`:""}getCompatibleTileInfo(e,t,i=!1){if(!this.loaded||null==t)return null;if(i&&e.equals(this.spatialReference))return this.tileInfo;const s=(0,f.Vp)(e);return w.A.create({size:256,spatialReference:e,origin:s?{x:s.origin[0],y:s.origin[1]}:{x:t.xmin,y:t.ymax}})}getCompatibleFullExtent(e){return this.loaded?(this._compatibleFullExtent?.spatialReference.equals(e)||(this._compatibleFullExtent=this.raster.computeExtent(e)),this._compatibleFullExtent):null}async fetchTile(e,t,i,s={}){if(J(this),s.requestAsImageElement){const n=this.getTileUrl(e,t,i);return(0,r.A)(n,{responseType:"image",query:{...this.refreshParameters,...this.raster.ioConfig.customFetchParameters},signal:s.signal}).then(e=>e.data)}const{serviceRasterInfo:n}=this;if(null!=n.multidimensionalInfo&&null==(s=this.normalizeRasterFetchOptions(s)).multidimensionalDefinition){const r=s.tileInfo||n.storageInfo.tileInfo,o=this.raster.getTileExtentFromTileInfo(e,t,i,r);if(o)return{extent:o,pixelBlock:null}}return await this._initJobHandler(),await this.updateRasterFunction(),"raster-shaded-relief"===this.renderer?.type&&(s={...s,buffer:{cols:1,rows:1}}),this.raster.fetchTile(e,t,i,s)}async fetchPixels(e,t,i,s={}){if(null!=this.serviceRasterInfo.multidimensionalInfo&&null==(s=this.normalizeRasterFetchOptions(s)).multidimensionalDefinition)return{extent:e,pixelBlock:null};await this._initJobHandler(),await this.updateRasterFunction(),t=Math.round(t),i=Math.round(i);const r=await this.raster.fetchPixels(e,t,i,s);return s.bandIds?.length&&!this.raster.rasterInfo.storageInfo.isBsqTile&&(r.pixelBlock=r.pixelBlock?.extractBands(s.bandIds)),r}async getSamples(e,t){if(await this.load(),(e=(0,a.PZ)(B.A,e).clone()).interpolation&&"nearest"!==e.interpolation)throw new n.A("imagery-tile-mixin:get-samples","only nearest interpolation is currently supported");const i=e.mosaicRule?.multidimensionalDefinition,s={...t,multidimensionalDefinition:i},r=(await this._getSampleLocations(e)).map(e=>this.identify(e,s).then(t=>(t.location=e,t))),o=(await Promise.all(r)).flatMap((e,t)=>this._convertRasterIdentifyResultToSample(e,t));return new D.A({samples:o})}async identify(e,t={}){await this.load();const{raster:i,serviceRasterInfo:s}=this;if(null!=s?.multidimensionalInfo&&(!s.hasMultidimensionalTranspose||!(0,R.DY)(t.multidimensionalDefinition)&&!t.transposedVariableName)&&null==(t=this.normalizeRasterFetchOptions(t)).multidimensionalDefinition)return{location:e,value:null};const r=this.multidimensionalSubset?.areaOfInterest;if(r&&!r.contains(e))throw new n.A("imagery-tile-mixin:identify","the request cannot be fulfilled when falling outside of the multidimensional subset");let o;if(this.serviceRasterInfo?.storageInfo.isBsqTile){const e=(0,b.qg)(i)?this.getRawDisplayBandIds():this.bandIds;o=e?.length?e:void 0}return i.identify(e,{...t,bandIds:o})}hasStandardTime(){const e=this.serviceRasterInfo?.multidimensionalInfo;if(null==e||"standard-time"!==this.serviceRasterInfo?.dataType)return!1;const t=this.multidimensionalDefinition,i=t?.[0]?.variableName;return e.variables.some(e=>e.name===i&&(!t?.[0].dimensionName||e.dimensions.some(e=>"StdTime"===e.name)))}getStandardTimeValue(e){return new Date((0,R.$E)(e)).toISOString()}getMultidimensionalSubsetVariables(e){const t=e??this.serviceRasterInfo?.multidimensionalInfo;return(0,R.z2)(this.multidimensionalSubset,t)}_configDefaultSettings(){this._configDefaultInterpolation(),this.multidimensionalDefinition||(this.multidimensionalDefinition=(0,R.fy)(this.raster.rasterInfo,{multidimensionalSubset:this.multidimensionalSubset})),this.rasterFunction&&(0,b.qg)(this.raster)&&(this._cachedRasterFunctionJson=this.rasterFunction.toJSON()),this._configDefaultRenderer()}async _initJobHandler(){if(!this._rasterJobHandler)return super._initJobHandler().then(async()=>{if(!this._rasterJobHandler)return;J(this);const{raster:e}=this;e.rasterJobHandler=this._rasterJobHandler,(0,b.qg)(e)&&e.syncJobHandler(),this.rasterFunction&&await this.updateRasterFunction().catch(()=>{}),this.renderer&&this.updateRenderer()}).catch(()=>{})}_shutdownJobHandler(){super._shutdownJobHandler(),this.raster&&(this.raster.rasterJobHandler=null)}async _getSampleLocations(e){const{geometry:t}=e;if("point"===t.type)return[t];const{spatialReference:s,type:r}=t;if("multipoint"===r)return t.points.map(e=>new d.A({x:e[0],y:e[1],spatialReference:s}));if("polyline"===r){let r=t;if(e.sampleCount||e.sampleDistance){const s=await Promise.all([i.e(3661),i.e(1878),i.e(9117),i.e(3299),i.e(8411)]).then(i.bind(i,88411)),n=(await Promise.all([i.e(3661),i.e(1878),i.e(9117),i.e(3299),i.e(4929)]).then(i.bind(i,965))).execute(t,{unit:"meters"}),o=Math.min(e.sampleCount||100,1e3);let l=e.sampleDistance;l||(l=n/(o+(2===r.paths[0].length?1:0))),r=s.execute(t,l,{unit:"meters"})}return r.paths.flatMap(e=>e.map(e=>new d.A({x:e[0],y:e[1],spatialReference:s})))}const n=Math.min(e.sampleCount||100,1e3),o="extent"===t.type,l=o?t:t.extent,a=Math.sqrt(l.width*l.height/n),c=l.height/a,u=l.width/a,{xmin:h,ymax:p}=l,f=[];for(let e=0;e<c;e++)for(let i=0;i<u;i++){const r=new d.A({x:h+(i+.5)*a,y:p-(e+.5)*a,spatialReference:s});(o||t.contains(r))&&f.push(r)}return f}_configDefaultInterpolation(){if(null==this.interpolation){J(this);const{raster:e}=this,t=(0,T.w6)(e.rasterInfo,e.tileType,this.sourceJSON?.defaultResamplingMethod);this._set("interpolation",t)}}_configDefaultRenderer(e="no"){J(this);const{rasterInfo:t}=this.raster,i=(0,R.ct)(t,{multidimensionalDefinition:this.multidimensionalDefinition,multidimensionalSubset:this.multidimensionalSubset}),s=i?.name,r=(0,T.I8)({variableName:s,rasterFunctionName:this.rasterFunction?.functionName,presetRenderers:this.presetRenderers});if(!this.bandIds&&t.bandCount>1&&(this.bandIds=r?.bandIds??(0,T.ci)(t)),!this.renderer||"override"===e){const e=(0,T.Mm)(this.raster),i=r?.renderer??(0,T.PD)(t,{bandIds:this.bandIds,variableName:s,rasterFunctionColorRamp:e}),n=t.statistics,o=n&&n.length>0?n[0]:null,l=o?.max??0,a=o?.min??0;"WCSServer"===this.raster.datasetFormat&&"raster-stretch"===i.type&&(l>1e24||a<-1e24)&&(i.dynamicRangeAdjustment=!0,i.customStatistics=null,"none"===i.stretchType&&(i.stretchType="min-max")),this.renderer=i}const n=(0,T.$P)({...this.renderer.toJSON(),variableName:s}),l=(0,T.m7)(t,s);this.symbolizer?(this.symbolizer.rendererJSON=n,this.symbolizer.rasterInfo=l):this.symbolizer=new A.A({rendererJSON:n,rasterInfo:l});const a=this.symbolizer.bind();if(a.success){if("auto"===e){const{colormap:e}=this.raster.rasterInfo,t=this.renderer;if(null!=e&&"raster-colormap"===t.type){const e=(0,T.PD)(this.raster.rasterInfo);JSON.stringify(e)!==JSON.stringify(t)&&this._configDefaultRenderer("override")}else if("raster-stretch"===t.type){const e=this.bandIds?.length,i=t.customStatistics?.length;!t.dynamicRangeAdjustment&&i&&e&&i!==e&&this._configDefaultRenderer("override")}}}else o.A.getLogger(this).warn("imagery-tile-mixin",a.error||"The given renderer is not supported by the layer."),"auto"===e&&this._configDefaultRenderer("override")}async _updateRasterFunction(){if(this._isConstructedFromFunctionRaster&&(0,b.qg)(this.raster)){const e=this.raster.rasterFunction.toJSON();return void(!this.rasterFunction&&e&&this._set("rasterFunction",v.A.fromJSON(e)))}let e,t=this.raster,i=!1;(0,b.qg)(t)?(e=t.primaryRasters.rasters,t=e[0],i=!0):e=[t];const{rasterFunction:s}=this;if(s){const i={raster:t};e.length>1&&e.forEach(e=>i[e.url]=e);const r=(0,C.vt)(s.functionDefinition?.toJSON()??s.toJSON(),i),n=new I.A({rasterFunction:r});n.rasterJobHandler=this._rasterJobHandler,await n.open(),this.raster=n}else this.raster=t,await t.open();if(this._cachedRendererJson=void 0,!i&&!s)return;const{bandIds:r}=this,{bandCount:n}=this.raster.rasterInfo,o=r?.length?r.some(e=>e>=n):n>=3;r&&(o||this.renderer&&"raster-stretch"!==this.renderer.type)&&this._set("bandIds",null),this._configDefaultRenderer("auto")}_convertRasterIdentifyResultToSample(e,t){const{rasterInfo:i}=this.raster,s=i.storageInfo.pyramidScalingFactor**(e.pyramidLevel??0),r=(i.pixelSize.x+i.pixelSize.y)/2*s;if(!e.dataSeries?.length)return[new P.A({location:e.location,pixelValue:e.value,locationId:t,resolution:r})];const n=[];return e.dataSeries.forEach(({value:i,multidimensionalDefinition:s},o)=>{const l={Variables:s[0].variableName,Dimensions:s.flatMap(({dimensionName:e})=>e).join(",")};for(const{dimensionName:e,values:t}of s){l[e]=Array.isArray(t[0])?t[0][0]:t[0];const i=t[t.length-1];l[`${e}_Max`]=Array.isArray(i)?i[i.length-1]:i}const a=new P.A({location:e.location,pixelValue:i,rasterId:o,locationId:t,resolution:r,attributes:l});n.push(a)}),n}};function J(e){if(!e.raster||!e.serviceRasterInfo)throw new n.A("imagery-tile","no raster")}return(0,s.Cg)([(0,l.MZ)({clonable:!1})],N.prototype,"_cachedRasterFunctionJson",void 0),(0,s.Cg)([(0,l.MZ)({clonable:!1})],N.prototype,"_compatibleFullExtent",void 0),(0,s.Cg)([(0,l.MZ)({clonable:!1})],N.prototype,"_isConstructedFromFunctionRaster",void 0),(0,s.Cg)([(0,l.MZ)({clonable:!1})],N.prototype,"_rasterFunctionUpdatePromise",void 0),(0,s.Cg)([(0,l.MZ)({type:[a.jz],json:{write:{overridePolicy(){return{enabled:!this.loaded||"Raster"===this.raster.tileType||"0,1,2"!==this.bandIds?.join(",")}}}}})],N.prototype,"bandIds",void 0),(0,s.Cg)([(0,l.MZ)({json:{origins:{service:{read:{source:"copyrightText"}}}}})],N.prototype,"copyright",void 0),(0,s.Cg)([(0,l.MZ)({json:{read:!1}})],N.prototype,"fullExtent",null),(0,s.Cg)([(0,l.MZ)({json:{write:{overridePolicy(){return{enabled:!this.loaded||"Raster"===this.raster.tileType||"bilinear"!==this.interpolation}}}}}),(0,c.e)(_.SZ)],N.prototype,"interpolation",void 0),(0,s.Cg)([(0,l.MZ)()],N.prototype,"ioConfig",void 0),(0,s.Cg)([(0,l.MZ)({type:[y.A],json:{write:!0}})],N.prototype,"multidimensionalDefinition",null),(0,s.Cg)([(0,l.MZ)({type:x.A,json:{write:!0}})],N.prototype,"multidimensionalSubset",void 0),(0,s.Cg)([(0,l.MZ)()],N.prototype,"raster",void 0),(0,s.Cg)([(0,l.MZ)({type:v.A})],N.prototype,"rasterFunction",null),(0,s.Cg)([(0,l.MZ)()],N.prototype,"serviceRasterInfo",void 0),(0,s.Cg)([(0,l.MZ)()],N.prototype,"sourceJSON",void 0),(0,s.Cg)([(0,l.MZ)({readOnly:!0,type:p.A,json:{read:!1}})],N.prototype,"spatialReference",void 0),(0,s.Cg)([(0,l.MZ)({type:w.A})],N.prototype,"tileInfo",void 0),(0,s.Cg)([(0,l.MZ)(g.OZ)],N.prototype,"url",null),(0,s.Cg)([(0,l.MZ)()],N.prototype,"renderer",null),(0,s.Cg)([(0,l.MZ)({types:z.uy,json:{name:"layerDefinition.drawingInfo.renderer",write:{overridePolicy(){const e="raster-stretch"===this.renderer?.type&&"none"===this.renderer.stretchType&&!this.renderer.useGamma;return{enabled:!this.loaded||"Raster"===this.raster.tileType||!e}}},origins:{"web-scene":{types:z.Gj,name:"layerDefinition.drawingInfo.renderer",write:{overridePolicy:e=>({enabled:e&&"vector-field"!==e.type})}}}}})],N.prototype,"internalRenderer",null),(0,s.Cg)([(0,u.w)("internalRenderer")],N.prototype,"readRenderer",null),(0,s.Cg)([(0,l.MZ)({clonable:!1})],N.prototype,"symbolizer",void 0),N=(0,s.Cg)([(0,h.$)("esri.layers.mixins.ImageryTileMixin")],N),N}},91806:(e,t,i)=>{i.d(t,{A:()=>c});var s,r=i(31635),n=i(25482),o=i(10107),l=i(56507),a=(i(44208),i(87811),i(64108));let c=class extends n.o{static{s=this}constructor(e){super(e),this.cols=null,this.level=0,this.levelValue=null,this.origin=null,this.resolution=0,this.rows=null,this.scale=0}clone(){return new s({cols:this.cols,level:this.level,levelValue:this.levelValue,resolution:this.resolution,rows:this.rows,scale:this.scale})}};(0,r.Cg)([(0,o.MZ)({json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],c.prototype,"cols",void 0),(0,r.Cg)([(0,o.MZ)({type:l.jz,json:{write:!0}})],c.prototype,"level",void 0),(0,r.Cg)([(0,o.MZ)({type:String,json:{write:!0}})],c.prototype,"levelValue",void 0),(0,r.Cg)([(0,o.MZ)({json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],c.prototype,"origin",void 0),(0,r.Cg)([(0,o.MZ)({type:Number,json:{write:!0}})],c.prototype,"resolution",void 0),(0,r.Cg)([(0,o.MZ)({json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],c.prototype,"rows",void 0),(0,r.Cg)([(0,o.MZ)({type:Number,json:{write:!0}})],c.prototype,"scale",void 0),c=s=(0,r.Cg)([(0,a.$)("esri.layers.support.LOD")],c)}}]);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[1360],{2272:(e,t,i)=>{i.d(t,{Dl:()=>u,gf:()=>h,jV:()=>l,lF:()=>d});var s=i(92602),n=i(70333),r=i(4718),o=i(84952),a=i(926);function l(e,t){return t?{...t,query:{...e,...t.query}}:{query:e}}function u(e){return"string"==typeof e?(0,o.An)(e):(0,r.o8)(e)}function d(e,t,i){const s={};for(const n in e){if("declaredClass"===n)continue;const r=e[n];if(null!=r&&"function"!=typeof r)if(Array.isArray(r))s[n]=r.map(e=>d(e));else if("object"==typeof r)if(r.toJSON){const e=r.toJSON(i?.[n]);s[n]=t?e:JSON.stringify(e)}else s[n]=t?r:JSON.stringify(r);else s[n]=r}return s}async function h(e,t,r){const o=function(e,t){return e?t&&(0,a.Qc)(e)?t:(0,a.CG)(e)??n.id?.findCredential(e)?.token:null}(e,t);if(o)return o;!n.id&&s.A.request.useIdentity&&await Promise.all([i.e(7330),i.e(168),i.e(3747)]).then(i.bind(i,73747));const l=await n.id.getCredential(e,r);return l?.token}},6518:(e,t,i)=>{i.d(t,{F:()=>a});var s=i(44208),n=i(75503),r=i(19419);const o={minX:0,minY:0,maxX:0,maxY:0};class a{constructor(){this._indexInvalid=!1,this._boundsToLoad=[],this._boundsById=new Map,this._idByBounds=new Map,this._index=new n.wq(9,(0,s.A)("esri-csp-restrictions")?e=>({minX:e[0],minY:e[1],maxX:e[2],maxY:e[3]}):["[0]","[1]","[2]","[3]"]),this._loadIndex=()=>{if(this._indexInvalid){const e=new Array(this._idByBounds.size);let t=0;this._idByBounds.forEach((i,s)=>{e[t++]=s}),this._indexInvalid=!1,this._index.clear(),this._index.load(e)}else this._boundsToLoad.length&&(this._index.load(Array.from(new Set(this._boundsToLoad.filter(e=>this._idByBounds.has(e))))),this._boundsToLoad.length=0)}}get fullBounds(){if(!this._boundsById.size)return null;const e=(0,r.Ie)();for(const t of this._boundsById.values())t&&(e[0]=Math.min(t[0],e[0]),e[1]=Math.min(t[1],e[1]),e[2]=Math.max(t[2],e[2]),e[3]=Math.max(t[3],e[3]));return e}get valid(){return!this._indexInvalid}clear(){this._indexInvalid=!1,this._boundsToLoad.length=0,this._boundsById.clear(),this._idByBounds.clear(),this._index.clear()}delete(e){const t=this._boundsById.get(e);this._boundsById.delete(e),t&&(this._idByBounds.delete(t),this._indexInvalid||this._index.remove(t))}forEachInBounds(e,t){this._loadIndex(),function(e,t,i){(function(e){o.minX=e[0],o.minY=e[1],o.maxX=e[2],o.maxY=e[3]})(t),e.search(o,i)}(this._index,e,e=>t(this._idByBounds.get(e)))}get(e){return this._boundsById.get(e)}has(e){return this._boundsById.has(e)}invalidateIndex(){this._indexInvalid||(this._indexInvalid=!0,this._boundsToLoad.length=0)}set(e,t){if(!this._indexInvalid){const t=this._boundsById.get(e);t&&(this._index.remove(t),this._idByBounds.delete(t))}this._boundsById.set(e,t),t&&(this._idByBounds.set(t,e),this._indexInvalid||(this._boundsToLoad.push(t),this._boundsToLoad.length>5e4&&this._loadIndex()))}}},29432:(e,t,i)=>{i.r(t),i.d(t,{default:()=>S});var s=i(49186),n=i(65864),r=i(21325),o=i(90708),a=i(33032),l=i(83221),u=i(31464),d=i(56390),h=i(64714),c=i(82832),f=i(95466),m=i(98453),p=i(30524),y=i(98623);const _=r.KK,g={xmin:-180,ymin:-90,xmax:180,ymax:90,spatialReference:r.KK},b={hasAttachments:!1,capabilities:"query, editing, create, delete, update",useStandardizedQueries:!0,supportsCoordinatesQuantization:!0,supportsReturningQueryGeometry:!0,advancedQueryCapabilities:{supportsQueryAttachments:!1,supportsQueryAttachmentOrderByFields:!1,supportsQueryAttachmentWithTypeWildcard:!1,supportsQueryBins:!0,supportsQueryPivot:!1,supportsStatistics:!0,supportsPercentileStatistics:!0,supportsReturningGeometryCentroid:!0,supportsQueryWithDistance:!0,supportsDistinct:!0,supportsReturningQueryExtent:!0,supportsReturningGeometryProperties:!1,supportsHavingClause:!0,supportsOrderBy:!0,supportsPagination:!0,supportsQueryWithResultType:!0,supportsSqlExpression:!0,supportsDisjointSpatialRel:!0,supportsQueryWithCacheHint:!0},queryBinsCapabilities:c.PC};function x(e){return(0,n.fT)(e)?null!=e.z:!!e.hasZ}function I(e){return(0,n.fT)(e)?null!=e.m:!!e.hasM}class S{constructor(){this._queryEngine=null,this._nextObjectId=null}destroy(){this._queryEngine?.destroy(),this._queryEngine=this._createDefaultAttributes=null}async load(e){const t=[],{features:i}=e,n=this._inferLayerProperties(i,e.fields),r=e.fields||[],o=null!=e.hasM?e.hasM:!!n.hasM,c=null!=e.hasZ?e.hasZ:!!n.hasZ,x=!e.spatialReference&&!n.spatialReference,I=x?_:e.spatialReference||n.spatialReference,S=x?g:null,B=e.geometryType||n.geometryType,M=!B;let F=e.objectIdField||n.objectIdField,v=e.timeInfo;const z=new f.A(r);if(!M&&(x&&t.push({name:"feature-layer:spatial-reference-not-found",message:"Spatial reference not provided or found in features. Defaults to WGS84"}),!B))throw new s.A("feature-layer:missing-property","geometryType not set and couldn't be inferred from the provided features");if(!F)throw new s.A("feature-layer:missing-property","objectIdField not set and couldn't be found in the provided fields");if(n.objectIdField&&F!==n.objectIdField&&(t.push({name:"feature-layer:duplicated-oid-field",message:`Provided objectIdField "${F}" doesn't match the field name "${n.objectIdField}", found in the provided fields`}),F=n.objectIdField),F&&!n.objectIdField){const e=z.get(F);e?(F=e.name,e.type="esriFieldTypeOID",e.editable=!1,e.nullable=!1):r.unshift({alias:F,name:F,type:"esriFieldTypeOID",editable:!1,nullable:!1})}for(const e of r){if(null==e.name&&(e.name=e.alias),null==e.alias&&(e.alias=e.name),!e.name)throw new s.A("feature-layer:invalid-field-name","field name is missing",{field:e});if(e.name===F&&(e.type="esriFieldTypeOID"),!m.m.jsonValues.includes(e.type))throw new s.A("feature-layer:invalid-field-type",`invalid type for field "${e.name}"`,{field:e});null==e.length&&(e.length=(0,p._b)(e))}const T={};for(const e of r)if("esriFieldTypeOID"!==e.type&&"esriFieldTypeGlobalID"!==e.type){const t=(0,p.lD)(e);void 0!==t&&(T[e.name]=t)}if(v){if(v.startTimeField){const e=z.get(v.startTimeField);e?(v.startTimeField=e.name,e.type="esriFieldTypeDate"):v.startTimeField=null}if(v.endTimeField){const e=z.get(v.endTimeField);e?(v.endTimeField=e.name,e.type="esriFieldTypeDate"):v.endTimeField=null}if(v.trackIdField){const e=z.get(v.trackIdField);e?v.trackIdField=e.name:(v.trackIdField=null,t.push({name:"feature-layer:invalid-timeInfo-trackIdField",message:"trackIdField is missing",details:{timeInfo:v}}))}v.startTimeField||v.endTimeField||(t.push({name:"feature-layer:invalid-timeInfo",message:"startTimeField and endTimeField are missing or invalid",details:{timeInfo:v}}),v=null)}const w=z.dateFields.length?{timeZoneIANA:e.dateFieldsTimeZone??y.n$}:null;this._createDefaultAttributes=(0,h.Vx)(T,F);const E={warnings:t,featureErrors:[],layerDefinition:{...b,drawingInfo:(0,h.F0)(B),templates:(0,h.e2)(T),extent:S,geometryType:B,objectIdField:F,fields:r,hasZ:c,hasM:o,timeInfo:v,dateFieldsTimeReference:w},assignedObjectIds:{}},A={type:"object-id",fieldName:F};if(this._queryEngine=new d.do({fieldsIndex:f.A.fromLayerJSON({fields:r,timeInfo:v,dateFieldsTimeReference:w}),geometryType:B,hasM:o,hasZ:c,featureIdInfo:A,spatialReference:I,featureStore:new l.A({geometryType:B,hasM:o,hasZ:c}),timeInfo:v}),!i?.length)return this._nextObjectId=a.L,E;const R=(0,a.H)(F,i);return this._nextObjectId=R+1,await(0,u.Nk)(i,I),this._loadInitialFeatures(E,i)}async applyEdits(e){const{spatialReference:t,geometryType:i}=this._queryEngine;return await Promise.all([(0,c.$1)(t,i),(0,u.Nk)(e.adds,t),(0,u.Nk)(e.updates,t)]),this._applyEdits(e)}queryFeatures(e,t={}){return this._queryEngine.executeQuery(e,t.signal)}queryFeatureCount(e,t={}){return this._queryEngine.executeQueryForCount(e,t.signal)}queryObjectIds(e,t={}){return this._queryEngine.executeQueryForIds(e,t.signal)}queryExtent(e,t={}){return this._queryEngine.executeQueryForExtent(e,t.signal)}querySnapping(e,t={}){return this._queryEngine.executeQueryForSnapping(e,t.signal)}queryAttributeBins(e,t={}){return this._queryEngine.executeAttributeBinsQuery(e,t.signal)}_inferLayerProperties(e,t){let i,s,r=null,o=null,a=null;for(const t of e){const e=t.geometry;if(null!=e&&(r||(r=(0,n.$B)(e)),o||(o=e.spatialReference),null==i&&(i=x(e)),null==s&&(s=I(e)),r&&o&&null!=i&&null!=s))break}if(t&&t.length){let e=null;t.some(t=>{const i="esriFieldTypeOID"===t.type,s=!t.type&&t.name&&"objectid"===t.name.toLowerCase();return e=t,i||s})&&(a=e.name)}return{geometryType:r,spatialReference:o,objectIdField:a,hasM:s,hasZ:i}}async _loadInitialFeatures(e,t){const{geometryType:i,hasM:s,hasZ:r,objectIdField:a,spatialReference:l,featureStore:d,fieldsIndex:h}=this._queryEngine,f=[],m={type:"object-id",fieldName:a};for(const s of t){if(null!=s.uid&&(e.assignedObjectIds[s.uid]=-1),s.geometry&&i!==(0,n.$B)(s.geometry)){e.featureErrors.push((0,c.Yx)("Incorrect geometry type."));continue}const t=this._createDefaultAttributes(),r=(0,c.MB)(h,t,s.attributes,!0);r?e.featureErrors.push(r):(this._assignObjectId(t,s.attributes,!0),s.attributes=t,null!=s.uid&&(e.assignedObjectIds[s.uid]=s.attributes[a]),null!=s.geometry&&(s.geometry=(0,u.Cv)(s.geometry,s.geometry.spatialReference,l)),f.push(s))}d.addMany((0,o.Di)([],f,i,r,s,m));const{fullExtent:p,timeExtent:y}=await this._queryEngine.fetchRecomputedExtents();if(e.layerDefinition.extent=p,y){const{start:t,end:i}=y;e.layerDefinition.timeInfo.timeExtent=[t,i]}return e}async _applyEdits(e){const{adds:t,updates:i,deletes:s}=e,n={addResults:[],deleteResults:[],updateResults:[],uidToObjectId:{}};if(t?.length&&this._applyAddEdits(n,t),i?.length&&this._applyUpdateEdits(n,i),s?.length){for(const e of s)n.deleteResults.push((0,c.bP)(e));this._queryEngine.featureStore.removeManyById(s)}const{fullExtent:r,timeExtent:o}=await this._queryEngine.fetchRecomputedExtents();return{extent:r,timeExtent:o,featureEditResults:n}}_applyAddEdits(e,t){const{addResults:i}=e,{geometryType:s,hasM:r,hasZ:a,objectIdField:l,spatialReference:d,featureStore:h,featureIdInfo:f,fieldsIndex:m}=this._queryEngine,p=[];for(const r of t){if(r.geometry&&s!==(0,n.$B)(r.geometry)){i.push((0,c.Yx)("Incorrect geometry type."));continue}const t=this._createDefaultAttributes(),o=(0,c.MB)(m,t,r.attributes);if(o)i.push(o);else{if(this._assignObjectId(t,r.attributes),r.attributes=t,null!=r.uid){const t=r.attributes[l];e.uidToObjectId[r.uid]=t}if(null!=r.geometry){const e=r.geometry.spatialReference??d;r.geometry=(0,u.Cv)((0,c.CR)(r.geometry,e),e,d)}p.push(r),i.push((0,c.bP)(r.attributes[l]))}}h.addMany((0,o.Di)([],p,s,a,r,f))}_applyUpdateEdits({updateResults:e},t){const{geometryType:i,hasM:s,hasZ:r,objectIdField:a,spatialReference:l,featureStore:d,fieldsIndex:h,featureIdInfo:f}=this._queryEngine;for(const m of t){const{attributes:t,geometry:p}=m,y=t?.[a];if(null==y){e.push((0,c.Yx)(`Identifier field ${a} missing`));continue}if(!d.has(y)){e.push((0,c.Yx)(`Feature with object id ${y} missing`));continue}const _=(0,o.oN)(d.getFeature(y),i,r,s);if(null!=p){if(i!==(0,n.$B)(p)){e.push((0,c.Yx)("Incorrect geometry type."));continue}const t=p.spatialReference??l;_.geometry=(0,u.Cv)((0,c.CR)(p,t),t,l)}if(t){const i=(0,c.MB)(h,_.attributes,t);if(i){e.push(i);continue}}d.add((0,o.E2)(_,i,r,s,f)),e.push((0,c.bP)(y))}}_assignObjectId(e,t,i=!1){const s=this._queryEngine.objectIdField;i&&t&&isFinite(t[s])?e[s]=t[s]:e[s]=this._nextObjectId++}}},33032:(e,t,i)=>{i.d(t,{H:()=>n,L:()=>s});const s=1;function n(e,t){let i=0;for(const s of t){const t=s.attributes?.[e];"number"==typeof t&&isFinite(t)&&(i=Math.max(i,t))}return i}},36708:(e,t,i)=>{i.d(t,{C_:()=>c,OH:()=>p,Vh:()=>y,on:()=>h,pc:()=>_,wB:()=>l,z7:()=>u});var s=i(37955),n=i(36563),r=i(97768),o=i(74887),a=i(14012);function l(e,t,i={}){return d(e,t,i,f)}function u(e,t,i={}){return d(e,t,i,m)}function d(e,t,i={},s){let n=null;const o=i.once?(e,i)=>{s(e)&&((0,r.xt)(n),t(e,i))}:(e,i)=>{s(e)&&t(e,i)};if(n=(0,a.Cn)(e,o,i.sync,i.equals),i.initial){const t=e();o(t,t)}return n}function h(e,t,i,o={}){let a=null,u=null,d=null;function h(){a&&u&&(u.remove(),o.onListenerRemove?.(a),a=null,u=null)}function c(e){o.once&&o.once&&(0,r.xt)(d),i(e)}const f=l(e,(e,i)=>{h(),(0,s.wb)(e)&&(a=e,u=(0,s.on)(e,t,c),o.onListenerAdd?.(e))},{sync:o.sync,initial:!0});return d=(0,n.hA)(()=>{f.remove(),h()}),d}function c(e,t){return function(e,t,i){if((0,o.G4)(i))return Promise.reject((0,o.NK)());const s=e();if(t?.(s))return Promise.resolve(s);let a=null;function l(){a=(0,r.xt)(a)}return new Promise((s,r)=>{a=(0,n.vE)([(0,o.u7)(i,()=>{l(),r((0,o.NK)())}),d(e,e=>{l(),s(e)},{sync:!1,once:!0},t??f)])})}(e,m,t)}function f(e){return!0}function m(e){return!!e}i(80559);const p={sync:!0},y={initial:!0},_={sync:!0,initial:!0}},37730:(e,t,i)=>{i.d(t,{T:()=>n});var s=i(43334);const n={getObjectId:e=>e.objectId,getAttributes:e=>e.attributes,getAttribute:(e,t)=>e.attributes[t],cloneWithGeometry:(e,t)=>new s.Om(t,e.attributes,null,e.objectId),getGeometry:e=>e.geometry,getCentroid:(e,t)=>e.ensureCentroid(t)}},64714:(e,t,i)=>{i.d(t,{F0:()=>a,Vx:()=>d,e2:()=>c,f:()=>f});var s=i(44208),n=i(4718),r=i(99352),o=i(93470);function a(e){return{renderer:{type:"simple",symbol:"esriGeometryPoint"===e||"esriGeometryMultipoint"===e?o.Cb:"esriGeometryPolyline"===e?o.yM:o.WR}}}const l=/^[_$a-zA-Z][_$a-zA-Z0-9]*$/;let u=1;function d(e,t){if((0,s.A)("esri-csp-restrictions"))return()=>({[t]:null,...e});try{let i=`this${h(t)} = null;`;for(const t in e)i+=`this${h(t)} = ${JSON.stringify(e[t])};`;const s=new Function(`\n return class AttributesClass$${u++} {\n constructor() {\n ${i};\n }\n }\n `)();return()=>new s}catch(i){return()=>({[t]:null,...e})}}function h(e){return l.test(e)?`.${e}`:`["${e}"]`}function c(e={}){return[{name:"New Feature",description:"",prototype:{attributes:(0,n.o8)(e)}}]}function f(e,t){return{analytics:{supportsCacheHint:!1},attachment:null,data:{isVersioned:!1,isBranchVersioned:!1,supportsAttachment:!1,supportsM:!1,supportsZ:e},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:t,supportsDelete:t,supportsEditing:t,supportsChangeTracking:!1,supportsQuery:!0,supportsQueryBins:!0,supportsQueryPivot:!1,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:t,supportsExceedsLimitStatistics:!0,supportsAsyncConvert3D:!1},query:r.F,queryRelated:{supportsCount:!0,supportsOrderBy:!0,supportsPagination:!0,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:r.P,editing:{supportsGeometryUpdate:t,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsAsyncApplyEdits:!1,zDefault:void 0}}}},66344:(e,t,i)=>{i.d(t,{q:()=>a});const s=!!(0,i(44208).A)("esri-tests-disable-gpu-memory-measurements");Symbol.iterator;class n{get size(){return this._size}constructor(e=10485760){this._maxSize=e,this._db=new Map,this._size=0,this._hit=0,this._miss=0,this._users=new Map,this._sizeLimits=new Map}destroy(){this.clearAll(),this._sizeLimits.clear(),this._users.clear(),this._db=null}register(e){this._users.set(e.id.slice(0,-1),e)}deregister(e){this.clear(e),this._sizeLimits.delete(e),this._users.delete(e.id.slice(0,-1))}get maxSize(){return this._maxSize}set maxSize(e){this._maxSize=Math.max(e,-1),this._checkSize()}getSize(e,t){const i=this._db.get(e.id+t);return i?.size??0}put(e,t,i,n,o){t=e.id+t;const a=this._db.get(t);if(a&&(this._size-=a.size,e.size-=a.size,this._db.delete(t),a.entry!==i&&this._notifyRemove(t,a.entry,a.size,0)),n>this._maxSize)return void this._notifyRemove(t,i,n,0);if(void 0===i)return void console.warn("Refusing to cache undefined entry ");if(!n||n<0)return s||console.warn(`Refusing to cache entry with size ${n} for key ${t}`),void this._notifyRemove(t,i,0,0);const l=1+Math.max(o,-4)- -3;this._db.set(t,new r(i,n,l)),this._size+=n,e.size+=n,this._checkSize()}updateSize(e,t){t=e.id+t;const i=this._db.get(t);if(!i)return;this._size-=i.size,e.size-=i.size;let s=i.entry.usedMemory;for(;s>this._maxSize;){const e=this._notifyRemove(t,i.entry,s,1);if(!(null!=e&&e>0))return void this._db.delete(t);s=e}i.size=s,this._size+=s,e.size+=s,this._checkSize()}pop(e,t){t=e.id+t;const i=this._db.get(t);if(i)return this._size-=i.size,e.size-=i.size,this._db.delete(t),++this._hit,i.entry;++this._miss}get(e,t){t=e.id+t;const i=this._db.get(t);if(void 0!==i)return this._db.delete(t),i.lives=i.lifetime,this._db.set(t,i),++this._hit,i.entry;++this._miss}peek(e,t){const i=this._db.get(e.id+t);return i?++this._hit:++this._miss,i?.entry}get performanceInfo(){const e={Size:Math.round(this._size/1048576)+"/"+Math.round(this._maxSize/1048576)+"MB","Hit rate":Math.round(100*this._getHitRate())+"%",Entries:this._db.size.toString()},t={},i=new Array;this._db.forEach((e,s)=>{const n=e.lifetime;i[n]=(i[n]||0)+e.size,this._users.forEach(i=>{const{id:n,name:r}=i;if(s.startsWith(n)){const i=t[r]||0;t[r]=i+e.size}})});const s={};this._users.forEach(e=>{const i=e.name;if("hitRate"in e&&"number"==typeof e.hitRate&&!isNaN(e.hitRate)&&e.hitRate>0){const n=t[i]||0;t[i]=n,s[i]=Math.round(100*e.hitRate)+"%"}else s[i]="0%"});const n=Object.keys(t);n.sort((e,i)=>t[i]-t[e]),n.forEach(i=>e[i]=Math.round(t[i]/2**20)+"MB / "+s[i]);for(let t=i.length-1;t>=0;--t){const s=i[t];s&&(e["Priority "+(t+-3-1)]=Math.round(s/this._size*100)+"%")}return e}resetStats(){this._hit=this._miss=0,this._users.forEach(e=>e.resetHitRate())}clear(e){const t=e.id;this._db.forEach((e,i)=>{i.startsWith(t)&&(this._size-=e.size,this._db.delete(i),this._notifyRemove(i,e.entry,e.size,0))}),e.size=0}clearAll(){this._db.forEach((e,t)=>this._notifyRemove(t,e.entry,e.size,0)),this._users.forEach(e=>e.size=0),this._size=0,this._db.clear()}*values(e){for(const[t,i]of this._db)t.startsWith(e.id)&&(yield i.entry)}_getHitRate(){return this._hit/(this._hit+this._miss)}_notifyRemove(e,t,i,s){const n=this._users.get(e.split(o)[0])?.removeFunc,r=n?.(t,s,i);return"number"==typeof r?r:null}_checkSize(){this._sizeLimits.forEach((e,t)=>this._checkSizeLimits(e,t)),this._checkSizeLimits(this.maxSize)}setMaxSize(e,t){null==t||t<=0?this._sizeLimits.delete(e):this._sizeLimits.set(e,t)}_checkSizeLimits(e,t){const i=t??this;if(i.size<=e)return;const s=t?.id;let n=!0;for(;n;){n=!1;for(const[r,a]of this._db)if(0===a.lifetime&&(!s||r.startsWith(s))){const s=t??this._users.get(r.split(o)[0]);if(this._purgeItem(r,a,s),i.size<=.9*e)return;n||=this._db.has(r)}}for(const[n,r]of this._db)if(!s||n.startsWith(s)){const s=t??this._users.get(n.split(o)[0]);if(this._purgeItem(n,r,s),i.size<=.9*e)return}}_purgeItem(e,t,i){if(this._db.delete(e),t.lives<=1){this._size-=t.size,i&&(i.size-=t.size);const s=this._notifyRemove(e,t.entry,t.size,1);null!=s&&s>0&&(this._size+=s,i&&(i.size+=s),t.lives=t.lifetime,t.size=s,this._db.set(e,t))}else--t.lives,this._db.set(e,t)}}new n(0);class r{constructor(e,t,i){this.entry=e,this.size=t,this.lifetime=i,this.lives=i}}const o=":";class a{constructor(e,t){this.removeFunc=t,this._storage=new n,this.id="",this.name="",this.size=0,this._storage.maxSize=e,this._storage.register(this)}destroy(){this._storage.deregister(this),this._storage.destroy(),this._storage=null}put(e,t,i=1){this._storage.put(this,e,t,i,1)}pop(e){return this._storage.pop(this,e)}get(e){return this._storage.get(this,e)}clear(){this._storage.clearAll()}get maxSize(){return this._storage.maxSize}set maxSize(e){this._storage.maxSize=e}resetHitRate(){}}},67482:(e,t,i)=>{function s(e){return null!=a(e)||null!=o(e)}function n(e){return l.test(e)}function r(e){return a(e)??o(e)}function o(e){const t=new Date(e);return function(e,t){if(Number.isNaN(e.getTime()))return!1;let i=!0;if(d&&/\d+\W*$/.test(t)){const e=t.match(/[a-zA-Z]{2,}/);if(e){let t=!1,s=0;for(;!t&&s<=e.length;)t=!u.test(e[s]),s++;i=!t}}return i}(t,e)?Number.isNaN(t.getTime())?null:t.getTime()-6e4*t.getTimezoneOffset():null}function a(e){const t=l.exec(e);if(!t?.groups)return null;const i=t.groups,s=+i.year,n=+i.month-1,r=+i.day,o=+(i.hours??"0"),a=+(i.minutes??"0"),u=+(i.seconds??"0");if(o>23)return null;if(a>59)return null;if(u>59)return null;const d=i.ms??"0",h=d?+d.padEnd(3,"0").slice(0,3):0;let c;if(i.isUTC||!i.offsetSign)c=Date.UTC(s,n,r,o,a,u,h);else{const e=+i.offsetHours,t=+i.offsetMinutes;c=6e4*("+"===i.offsetSign?-1:1)*(60*e+t)+Date.UTC(s,n,r,o,a,u,h)}return Number.isNaN(c)?null:c}i.d(t,{Br:()=>n,Cq:()=>s,_U:()=>r});const l=/^(?:(?<year>-?\d{4,})-(?<month>\d{2})-(?<day>\d{2}))(?:T(?<hours>\d{2}):(?<minutes>\d{2}):(?<seconds>\d{2})(?:\.(?<ms>\d+))?)?(?:(?<isUTC>Z)|(?:(?<offsetSign>\+|-)(?<offsetHours>\d{2}):(?<offsetMinutes>\d{2})))?$/,u=/^((jan(uary)?)|(feb(ruary)?)|(mar(ch)?)|(apr(il)?)|(may)|(jun(e)?)|(jul(y)?)|(aug(ust)?)|(sep(tember)?)|(oct(ober)?)|(nov(ember)?)|(dec(ember)?)|(am)|(pm)|(gmt)|(utc))$/i,d=!Number.isNaN(new Date("technology 10").getTime())},69540:(e,t,i)=>{i.d(t,{OU:()=>d,Pw:()=>h});var s=i(31635),n=i(69622),r=(i(44208),i(4718)),o=(i(53966),i(97768)),a=i(88620),l=i(64108);const u=Symbol("ClonableMixin"),d=e=>{var t;const i=e;let n=class extends i{constructor(){super(...arguments),this[t]=!0}static{t=u}clone(e){const t=(0,a.oY)(this);(0,o.Lw)(t,"unable to clone instance of non-accessor class");const i=t.metadata,s=t.store,n={},l=new Map;for(const t in i){const o=i[t],a=s?.originOf(t),u=o.clonable;if(o.readOnly||!1===u||7!==a&&0!==a&&5!==a&&4!==a)continue;const d=this[t];let h=null;if("function"==typeof u)h=u(d,e);else if("reference"===u)h=d;else if(h=(0,r.TU)(d,e),null!=d&&null==h)continue;0===a?l.set(t,h):n[t]=h}const u=new(0,Object.getPrototypeOf(this).constructor)(n);if(l.size){const e=(0,a.oY)(u)?.store;if(e)for(const[t,i]of l)e.set(t,i,0)}return u}};return n=(0,s.Cg)([(0,l.$)("esri.core.Clonable")],n),n},h=d(n.A)},75503:(e,t,i)=>{i.d(t,{EC:()=>F,wq:()=>a});var s=i(4576),n=i(21818),r=(i(44208),i(15142)),o=i(11006);class a{constructor(e=9,t){this._compareMinX=c,this._compareMinY=f,this._toBBox=e=>e,this._maxEntries=Math.max(4,e||9),this._minEntries=Math.max(2,Math.ceil(.4*this._maxEntries)),t&&("function"==typeof t?this._toBBox=t:this._initFormat(t)),this.clear()}destroy(){this.clear(),I.prune(),S.prune(),B.prune(),M.prune()}all(e){l(this._data,e)}search(e,t){let i=this._data;const s=this._toBBox;if(b(e,i))for(I.clear();i;){for(let n=0,r=i.children.length;n<r;n++){const r=i.children[n],o=i.leaf?s(r):r;b(e,o)&&(i.leaf?t(r):g(e,o)?l(r,t):I.push(r))}i=I.pop()}}collides(e){let t=this._data;const i=this._toBBox;if(!b(e,t))return!1;for(I.clear();t;){for(let s=0,n=t.children.length;s<n;s++){const n=t.children[s],r=t.leaf?i(n):n;if(b(e,r)){if(t.leaf||g(e,r))return!0;I.push(n)}}t=I.pop()}return!1}load(e){if(!e.length)return this;if(e.length<this._minEntries){for(let t=0,i=e.length;t<i;t++)this.insert(e[t]);return this}let t=this._build(e.slice(),0,e.length-1,0);if(this._data.children.length)if(this._data.height===t.height)this._splitRoot(this._data,t);else{if(this._data.height<t.height){const e=this._data;this._data=t,t=e}this._insert(t,this._data.height-t.height-1,!0)}else this._data=t;return this}insert(e){return e&&this._insert(e,this._data.height-1),this}clear(){return this._data=new z([]),this}remove(e){if(!e)return this;let t,i=this._data,r=null,o=0,a=!1;const l=this._toBBox(e);for(B.clear(),M.clear();i||B.length>0;){if(i||(i=B.pop(),r=B.data[B.length-1],o=M.pop()??0,a=!0),i.leaf&&(t=(0,s.qh)(i.children,(0,n.zI)(e),i.children.length,i.indexHint),-1!==t))return i.children.splice(t,1),B.push(i),this._condense(B),this;a||i.leaf||!g(i,l)?r?(o++,i=r.children[o],a=!1):i=null:(B.push(i),M.push(o),o=0,r=i,i=i.children[0])}return this}toJSON(){return this._data}fromJSON(e){return this._data=e,this}_build(e,t,i,s){const n=i-t+1;let r=this._maxEntries;if(n<=r){const s=new z(e.slice(t,i+1));return u(s,this._toBBox),s}s||(s=Math.ceil(Math.log(n)/Math.log(r)),r=Math.ceil(n/r**(s-1)));const o=new T([]);o.height=s;const a=Math.ceil(n/r),l=a*Math.ceil(Math.sqrt(r));x(e,t,i,l,this._compareMinX);for(let n=t;n<=i;n+=l){const t=Math.min(n+l-1,i);x(e,n,t,a,this._compareMinY);for(let i=n;i<=t;i+=a){const n=Math.min(i+a-1,t);o.children.push(this._build(e,i,n,s-1))}}return u(o,this._toBBox),o}_insert(e,t,i){const s=this._toBBox,n=i?e:s(e);B.clear();const r=function(e,t,i,s){for(;s.push(t),!0!==t.leaf&&s.length-1!==i;){let i,s=1/0,n=1/0;for(let r=0,o=t.children.length;r<o;r++){const o=t.children[r],a=m(o),l=y(e,o)-a;l<n?(n=l,s=a<s?a:s,i=o):l===n&&a<s&&(s=a,i=o)}t=i||t.children[0]}return t}(n,this._data,t,B);for(r.children.push(e),h(r,n);t>=0&&B.data[t].children.length>this._maxEntries;)this._split(B,t),t--;!function(e,t,i){for(let s=i;s>=0;s--)h(t.data[s],e)}(n,B,t)}_split(e,t){const i=e.data[t],s=i.children.length,n=this._minEntries;this._chooseSplitAxis(i,n,s);const r=this._chooseSplitIndex(i,n,s);if(!r)return;const o=i.children.splice(r,i.children.length-r),a=i.leaf?new z(o):new T(o);a.height=i.height,u(i,this._toBBox),u(a,this._toBBox),t?e.data[t-1].children.push(a):this._splitRoot(i,a)}_splitRoot(e,t){this._data=new T([e,t]),this._data.height=e.height+1,u(this._data,this._toBBox)}_chooseSplitIndex(e,t,i){let s,n,r;s=n=1/0;for(let o=t;o<=i-t;o++){const t=d(e,0,o,this._toBBox),a=d(e,o,i,this._toBBox),l=_(t,a),u=m(t)+m(a);l<s?(s=l,r=o,n=u<n?u:n):l===s&&u<n&&(n=u,r=o)}return r}_chooseSplitAxis(e,t,i){const s=e.leaf?this._compareMinX:c,n=e.leaf?this._compareMinY:f;this._allDistMargin(e,t,i,s)<this._allDistMargin(e,t,i,n)&&e.children.sort(s)}_allDistMargin(e,t,i,s){e.children.sort(s);const n=this._toBBox,r=d(e,0,t,n),o=d(e,i-t,i,n);let a=p(r)+p(o);for(let s=t;s<i-t;s++){const t=e.children[s];h(r,e.leaf?n(t):t),a+=p(r)}for(let s=i-t-1;s>=t;s--){const t=e.children[s];h(o,e.leaf?n(t):t),a+=p(o)}return a}_condense(e){for(let t=e.length-1;t>=0;t--){const i=e.data[t];if(0===i.children.length)if(t>0){const n=e.data[t-1],r=n.children;r.splice((0,s.qh)(r,i,r.length,n.indexHint),1)}else this.clear();else u(i,this._toBBox)}}_initFormat(e){const t=["return a"," - b",";"];this._compareMinX=new Function("a","b",t.join(e[0])),this._compareMinY=new Function("a","b",t.join(e[1])),this._toBBox=new Function("a","return {minX: a"+e[0]+", minY: a"+e[1]+", maxX: a"+e[2]+", maxY: a"+e[3]+"};")}}function l(e,t){let i=e;for(S.clear();i;){if(!0===i.leaf)for(const e of i.children)t((0,n.zI)(e));else S.pushArray(i.children);i=S.pop()??null}}function u(e,t){d(e,0,e.children.length,t,e)}function d(e,t,i,s,n){n||(n=new z([])),n.minX=1/0,n.minY=1/0,n.maxX=-1/0,n.maxY=-1/0;for(let r,o=t;o<i;o++)r=e.children[o],h(n,e.leaf?s(r):r);return n}function h(e,t){e.minX=Math.min(e.minX,t.minX),e.minY=Math.min(e.minY,t.minY),e.maxX=Math.max(e.maxX,t.maxX),e.maxY=Math.max(e.maxY,t.maxY)}function c(e,t){return e.minX-t.minX}function f(e,t){return e.minY-t.minY}function m(e){return(e.maxX-e.minX)*(e.maxY-e.minY)}function p(e){return e.maxX-e.minX+(e.maxY-e.minY)}function y(e,t){return(Math.max(t.maxX,e.maxX)-Math.min(t.minX,e.minX))*(Math.max(t.maxY,e.maxY)-Math.min(t.minY,e.minY))}function _(e,t){const i=Math.max(e.minX,t.minX),s=Math.max(e.minY,t.minY),n=Math.min(e.maxX,t.maxX),r=Math.min(e.maxY,t.maxY);return Math.max(0,n-i)*Math.max(0,r-s)}function g(e,t){return e.minX<=t.minX&&e.minY<=t.minY&&t.maxX<=e.maxX&&t.maxY<=e.maxY}function b(e,t){return t.minX<=e.maxX&&t.minY<=e.maxY&&t.maxX>=e.minX&&t.maxY>=e.minY}function x(e,t,i,s,n){const r=[t,i];for(;r.length;){const t=r.pop(),i=r.pop();if(t-i<=s)continue;const a=i+Math.ceil((t-i)/s/2)*s;(0,o.q)(e,a,i,t,n),r.push(i,a,a,t)}}const I=new r.A,S=new r.A,B=new r.A,M=new r.A({deallocator:void 0});class F{constructor(){this.minX=1/0,this.minY=1/0,this.maxX=-1/0,this.maxY=-1/0}}class v extends F{constructor(){super(...arguments),this.height=1,this.indexHint=new s.vW}}class z extends v{constructor(e){super(),this.children=e,this.leaf=!0}}class T extends v{constructor(e){super(),this.children=e,this.leaf=!1}}},82832:(e,t,i)=>{i.d(t,{$1:()=>y,CR:()=>p,MB:()=>c,PC:()=>_,Yx:()=>l,bP:()=>d});var s=i(67482),n=i(21325),r=i(30524);class o{constructor(e){this.description=e,this.code=null}}class a{constructor(e){this.globalId=null,this.objectId=null,this.success=!1,this.uniqueId=null,this.error=new o(e)}}function l(e){return new a(e)}class u{constructor(e){this.globalId=null,this.success=!0,this.objectId=this.uniqueId=e}}function d(e){return new u(e)}const h=new Set;function c(e,t,i,s=!1){h.clear();for(const n in i){const o=e.get(n);if(!o)continue;const a=f(o,i[n]);if(h.add(o.name),o&&(s||o.editable)){const e=(0,r.CJ)(o,a);if(e)return l((0,r.uo)(e,o,a));t[o.name]=a}}for(const t of e.requiredFields??[])if(!h.has(t.name))return l(`missing required field "${t.name}"`);return null}function f(e,t){let i=t;return(0,r.WA)(e)&&"string"==typeof t?i=parseFloat(t):(0,r.yM)(e)&&null!=t&&"string"!=typeof t?i=String(t):(0,r.vE)(e)&&"string"==typeof t&&(i=(0,s._U)(t)),(0,r.WX)(i)}let m;function p(e,t){if(!e||!(0,n.fn)(t))return e;if("rings"in e||"paths"in e){if(null==m)throw new TypeError("geometry engine not loaded");return m.simplify(t,e)}return e}async function y(e,t){!(0,n.fn)(e)||"esriGeometryPolygon"!==t&&"esriGeometryPolyline"!==t||await async function(){return null==m&&(m=await Promise.all([i.e(3209),i.e(7559)]).then(i.bind(i,47559))),m}()}const _={supportsAutoIntervalBin:!0,supportsFixedIntervalBin:!0,supportsFixedBoundariesBin:!0,supportsDateBin:!0,supportsStackBy:!0,supportsSplitBy:!0,supportsNormalization:!0,supportedStatisticTypes:["COUNT","SUM","AVG","VAR","STDDEV","MIN","MAX","PERCENTILE_CONT","PERCENTILE_DISC","CentroidAggregate","EnvelopeAggregate","ConvexHullAggregate"],supportedNormalizationTypes:["field","log","naturalLog","percentOfTotal","squareRoot"]}},83221:(e,t,i)=>{i.d(t,{A:()=>m});var s=i(4576),n=i(49186),r=i(65529),o=i(53966),a=i(70328),l=i(19419),u=i(90708),d=i(6518),h=i(51441),c=i(37730);const f=(0,a.vt)();class m{constructor(e){this.geometryInfo=e,this._boundsStore=new d.F,this._featuresById=new Map,this._usedMemory=0,this.events=new r.bk,this.featureAdapter=c.T}get usedMemory(){return this._usedMemory}get geometryType(){return this.geometryInfo.geometryType}get hasM(){return this.geometryInfo.hasM}get hasZ(){return this.geometryInfo.hasZ}get numFeatures(){return this._featuresById.size}get fullBounds(){return this._boundsStore.fullBounds}get storeStatistics(){let e=0;return this._featuresById.forEach(t=>{null!=t.geometry&&t.geometry.coords&&(e+=t.geometry.coords.length)}),{featureCount:this._featuresById.size,vertexCount:e/(this.hasZ?this.hasM?4:3:this.hasM?3:2)}}getFullExtent(e){if(null==this.fullBounds)return null;const[t,i,s,n]=this.fullBounds;return{xmin:t,ymin:i,xmax:s,ymax:n,spatialReference:(0,h.ag)(e)}}add(e){this._add(e),this._emitChanged()}addMany(e){for(const t of e)this._add(t);this._emitChanged()}upsertMany(e){const t=e.map(e=>this._upsert(e));return this._emitChanged(),t.filter(s.Ru)}clear(){this._featuresById.clear(),this._boundsStore.clear(),this._emitChanged(),this._usedMemory=0}removeById(e){const t=this._featuresById.get(e);return t?(this._remove(t),this._emitChanged(),t):null}removeManyById(e){this._boundsStore.invalidateIndex();for(const t of e){const e=this._featuresById.get(t);e&&this._remove(e)}this._emitChanged()}forEachBounds(e,t){for(const i of e){const e=this._boundsStore.get(i.objectId);e&&t((0,a.Jt)(f,e))}}getFeature(e){return this._featuresById.get(e)}has(e){return this._featuresById.has(e)}forEach(e){this._featuresById.forEach(t=>e(t))}forEachInBounds(e,t){this._boundsStore.forEachInBounds(e,e=>{t(this._featuresById.get(e))})}_emitChanged(){this.events.emit("changed",void 0)}_add(e){if(!e)return;const t=e.objectId;if(null==t)return void o.A.getLogger("esri.layers.graphics.data.FeatureStore").error(new n.A("featurestore:invalid-feature","feature id is missing",{feature:e}));const i=this._featuresById.get(t);let s;if(i?(e.displayId=i.displayId,s=this._boundsStore.get(t),this._boundsStore.delete(t),this._usedMemory-=this.estimateFeatureUsedMemory?.(i)??0):null!=this.onFeatureAdd&&this.onFeatureAdd(e),!e.geometry?.coords?.length)return this._boundsStore.set(t,null),void this._featuresById.set(t,e);s=(0,u.jQ)(null!=s?s:(0,l.vt)(),e.geometry),null!=s&&this._boundsStore.set(t,s),this._featuresById.set(t,e),this._usedMemory+=this.estimateFeatureUsedMemory?.(e)??0}_upsert(e){const t=e?.objectId;if(null==t)return o.A.getLogger("esri.layers.graphics.data.FeatureStore").error(new n.A("featurestore:invalid-feature","feature id is missing",{feature:e})),null;const i=this._featuresById.get(t);if(!i)return this._add(e),e;this._usedMemory-=this.estimateFeatureUsedMemory?.(i)??0;const{geometry:s,attributes:r}=e;for(const e in r)i.attributes[e]=r[e];return s&&(i.geometry=s,this._boundsStore.set(t,(0,u.jQ)((0,l.vt)(),s)??null)),this._usedMemory+=this.estimateFeatureUsedMemory?.(i)??0,i}_remove(e){null!=this.onFeatureRemove&&this.onFeatureRemove(e);const t=e.objectId;return this._boundsStore.delete(t),this._featuresById.delete(t),this._usedMemory-=this.estimateFeatureUsedMemory?.(e)??0,e}}},93470:(e,t,i)=>{i.d(t,{Cb:()=>r,HW:()=>d,JR:()=>n,JZ:()=>l,WR:()=>a,b6:()=>h,fT:()=>s,nC:()=>u,yM:()=>o});const s=[252,146,31,255],n=[153,153,153,255],r={type:"esriSMS",style:"esriSMSCircle",size:6,color:s,outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[153,153,153,255]}},o={type:"esriSLS",style:"esriSLSSolid",width:.75,color:s},a={type:"esriSFS",style:"esriSFSSolid",color:[252,146,31,196],outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[255,255,255,191]}},l={type:"esriTS",color:[255,255,255,255],font:{family:"arial-unicode-ms",size:10,weight:"bold"},horizontalAlignment:"center",kerning:!0,haloColor:[0,0,0,255],haloSize:1,rotated:!1,text:"",xoffset:0,yoffset:0,angle:0},u={type:"esriSMS",style:"esriSMSCircle",color:[0,0,0,255],outline:null,size:10.5},d={type:"esriSLS",style:"esriSLSSolid",color:[0,0,0,255],width:1.5},h={type:"esriSFS",style:"esriSFSSolid",color:[0,0,0,255],outline:null}},98453:(e,t,i)=>{i.d(t,{m:()=>s});const s=new(i(66552).J)({esriFieldTypeSmallInteger:"small-integer",esriFieldTypeInteger:"integer",esriFieldTypeSingle:"single",esriFieldTypeDouble:"double",esriFieldTypeLong:"long",esriFieldTypeString:"string",esriFieldTypeDate:"date",esriFieldTypeOID:"oid",esriFieldTypeGeometry:"geometry",esriFieldTypeBlob:"blob",esriFieldTypeRaster:"raster",esriFieldTypeGUID:"guid",esriFieldTypeGlobalID:"global-id",esriFieldTypeXML:"xml",esriFieldTypeBigInteger:"big-integer",esriFieldTypeDateOnly:"date-only",esriFieldTypeTimeOnly:"time-only",esriFieldTypeTimestampOffset:"timestamp-offset"})}}]);
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[1360],{2272:(e,t,i)=>{i.d(t,{Dl:()=>u,gf:()=>h,jV:()=>l,lF:()=>d});var s=i(92602),n=i(70333),r=i(4718),o=i(84952),a=i(926);function l(e,t){return t?{...t,query:{...e,...t.query}}:{query:e}}function u(e){return"string"==typeof e?(0,o.An)(e):(0,r.o8)(e)}function d(e,t,i){const s={};for(const n in e){if("declaredClass"===n)continue;const r=e[n];if(null!=r&&"function"!=typeof r)if(Array.isArray(r))s[n]=r.map(e=>d(e));else if("object"==typeof r)if(r.toJSON){const e=r.toJSON(i?.[n]);s[n]=t?e:JSON.stringify(e)}else s[n]=t?r:JSON.stringify(r);else s[n]=r}return s}async function h(e,t,r){const o=function(e,t){return e?t&&(0,a.Qc)(e)?t:(0,a.CG)(e)??n.id?.findCredential(e)?.token:null}(e,t);if(o)return o;!n.id&&s.A.request.useIdentity&&await Promise.all([i.e(7330),i.e(168),i.e(4272)]).then(i.bind(i,74272));const l=await n.id.getCredential(e,r);return l?.token}},6518:(e,t,i)=>{i.d(t,{F:()=>a});var s=i(44208),n=i(75503),r=i(19419);const o={minX:0,minY:0,maxX:0,maxY:0};class a{constructor(){this._indexInvalid=!1,this._boundsToLoad=[],this._boundsById=new Map,this._idByBounds=new Map,this._index=new n.wq(9,(0,s.A)("esri-csp-restrictions")?e=>({minX:e[0],minY:e[1],maxX:e[2],maxY:e[3]}):["[0]","[1]","[2]","[3]"]),this._loadIndex=()=>{if(this._indexInvalid){const e=new Array(this._idByBounds.size);let t=0;this._idByBounds.forEach((i,s)=>{e[t++]=s}),this._indexInvalid=!1,this._index.clear(),this._index.load(e)}else this._boundsToLoad.length&&(this._index.load(Array.from(new Set(this._boundsToLoad.filter(e=>this._idByBounds.has(e))))),this._boundsToLoad.length=0)}}get fullBounds(){if(!this._boundsById.size)return null;const e=(0,r.Ie)();for(const t of this._boundsById.values())t&&(e[0]=Math.min(t[0],e[0]),e[1]=Math.min(t[1],e[1]),e[2]=Math.max(t[2],e[2]),e[3]=Math.max(t[3],e[3]));return e}get valid(){return!this._indexInvalid}clear(){this._indexInvalid=!1,this._boundsToLoad.length=0,this._boundsById.clear(),this._idByBounds.clear(),this._index.clear()}delete(e){const t=this._boundsById.get(e);this._boundsById.delete(e),t&&(this._idByBounds.delete(t),this._indexInvalid||this._index.remove(t))}forEachInBounds(e,t){this._loadIndex(),function(e,t,i){(function(e){o.minX=e[0],o.minY=e[1],o.maxX=e[2],o.maxY=e[3]})(t),e.search(o,i)}(this._index,e,e=>t(this._idByBounds.get(e)))}get(e){return this._boundsById.get(e)}has(e){return this._boundsById.has(e)}invalidateIndex(){this._indexInvalid||(this._indexInvalid=!0,this._boundsToLoad.length=0)}set(e,t){if(!this._indexInvalid){const t=this._boundsById.get(e);t&&(this._index.remove(t),this._idByBounds.delete(t))}this._boundsById.set(e,t),t&&(this._idByBounds.set(t,e),this._indexInvalid||(this._boundsToLoad.push(t),this._boundsToLoad.length>5e4&&this._loadIndex()))}}},29432:(e,t,i)=>{i.r(t),i.d(t,{default:()=>S});var s=i(49186),n=i(65864),r=i(21325),o=i(90708),a=i(33032),l=i(83221),u=i(31464),d=i(56390),h=i(64714),c=i(82832),f=i(95466),m=i(98453),p=i(30524),y=i(98623);const _=r.KK,g={xmin:-180,ymin:-90,xmax:180,ymax:90,spatialReference:r.KK},b={hasAttachments:!1,capabilities:"query, editing, create, delete, update",useStandardizedQueries:!0,supportsCoordinatesQuantization:!0,supportsReturningQueryGeometry:!0,advancedQueryCapabilities:{supportsQueryAttachments:!1,supportsQueryAttachmentOrderByFields:!1,supportsQueryAttachmentWithTypeWildcard:!1,supportsQueryBins:!0,supportsQueryPivot:!1,supportsStatistics:!0,supportsPercentileStatistics:!0,supportsReturningGeometryCentroid:!0,supportsQueryWithDistance:!0,supportsDistinct:!0,supportsReturningQueryExtent:!0,supportsReturningGeometryProperties:!1,supportsHavingClause:!0,supportsOrderBy:!0,supportsPagination:!0,supportsQueryWithResultType:!0,supportsSqlExpression:!0,supportsDisjointSpatialRel:!0,supportsQueryWithCacheHint:!0},queryBinsCapabilities:c.PC};function x(e){return(0,n.fT)(e)?null!=e.z:!!e.hasZ}function I(e){return(0,n.fT)(e)?null!=e.m:!!e.hasM}class S{constructor(){this._queryEngine=null,this._nextObjectId=null}destroy(){this._queryEngine?.destroy(),this._queryEngine=this._createDefaultAttributes=null}async load(e){const t=[],{features:i}=e,n=this._inferLayerProperties(i,e.fields),r=e.fields||[],o=null!=e.hasM?e.hasM:!!n.hasM,c=null!=e.hasZ?e.hasZ:!!n.hasZ,x=!e.spatialReference&&!n.spatialReference,I=x?_:e.spatialReference||n.spatialReference,S=x?g:null,B=e.geometryType||n.geometryType,M=!B;let F=e.objectIdField||n.objectIdField,v=e.timeInfo;const z=new f.A(r);if(!M&&(x&&t.push({name:"feature-layer:spatial-reference-not-found",message:"Spatial reference not provided or found in features. Defaults to WGS84"}),!B))throw new s.A("feature-layer:missing-property","geometryType not set and couldn't be inferred from the provided features");if(!F)throw new s.A("feature-layer:missing-property","objectIdField not set and couldn't be found in the provided fields");if(n.objectIdField&&F!==n.objectIdField&&(t.push({name:"feature-layer:duplicated-oid-field",message:`Provided objectIdField "${F}" doesn't match the field name "${n.objectIdField}", found in the provided fields`}),F=n.objectIdField),F&&!n.objectIdField){const e=z.get(F);e?(F=e.name,e.type="esriFieldTypeOID",e.editable=!1,e.nullable=!1):r.unshift({alias:F,name:F,type:"esriFieldTypeOID",editable:!1,nullable:!1})}for(const e of r){if(null==e.name&&(e.name=e.alias),null==e.alias&&(e.alias=e.name),!e.name)throw new s.A("feature-layer:invalid-field-name","field name is missing",{field:e});if(e.name===F&&(e.type="esriFieldTypeOID"),!m.m.jsonValues.includes(e.type))throw new s.A("feature-layer:invalid-field-type",`invalid type for field "${e.name}"`,{field:e});null==e.length&&(e.length=(0,p._b)(e))}const T={};for(const e of r)if("esriFieldTypeOID"!==e.type&&"esriFieldTypeGlobalID"!==e.type){const t=(0,p.lD)(e);void 0!==t&&(T[e.name]=t)}if(v){if(v.startTimeField){const e=z.get(v.startTimeField);e?(v.startTimeField=e.name,e.type="esriFieldTypeDate"):v.startTimeField=null}if(v.endTimeField){const e=z.get(v.endTimeField);e?(v.endTimeField=e.name,e.type="esriFieldTypeDate"):v.endTimeField=null}if(v.trackIdField){const e=z.get(v.trackIdField);e?v.trackIdField=e.name:(v.trackIdField=null,t.push({name:"feature-layer:invalid-timeInfo-trackIdField",message:"trackIdField is missing",details:{timeInfo:v}}))}v.startTimeField||v.endTimeField||(t.push({name:"feature-layer:invalid-timeInfo",message:"startTimeField and endTimeField are missing or invalid",details:{timeInfo:v}}),v=null)}const w=z.dateFields.length?{timeZoneIANA:e.dateFieldsTimeZone??y.n$}:null;this._createDefaultAttributes=(0,h.Vx)(T,F);const E={warnings:t,featureErrors:[],layerDefinition:{...b,drawingInfo:(0,h.F0)(B),templates:(0,h.e2)(T),extent:S,geometryType:B,objectIdField:F,fields:r,hasZ:c,hasM:o,timeInfo:v,dateFieldsTimeReference:w},assignedObjectIds:{}},A={type:"object-id",fieldName:F};if(this._queryEngine=new d.do({fieldsIndex:f.A.fromLayerJSON({fields:r,timeInfo:v,dateFieldsTimeReference:w}),geometryType:B,hasM:o,hasZ:c,featureIdInfo:A,spatialReference:I,featureStore:new l.A({geometryType:B,hasM:o,hasZ:c}),timeInfo:v}),!i?.length)return this._nextObjectId=a.L,E;const R=(0,a.H)(F,i);return this._nextObjectId=R+1,await(0,u.Nk)(i,I),this._loadInitialFeatures(E,i)}async applyEdits(e){const{spatialReference:t,geometryType:i}=this._queryEngine;return await Promise.all([(0,c.$1)(t,i),(0,u.Nk)(e.adds,t),(0,u.Nk)(e.updates,t)]),this._applyEdits(e)}queryFeatures(e,t={}){return this._queryEngine.executeQuery(e,t.signal)}queryFeatureCount(e,t={}){return this._queryEngine.executeQueryForCount(e,t.signal)}queryObjectIds(e,t={}){return this._queryEngine.executeQueryForIds(e,t.signal)}queryExtent(e,t={}){return this._queryEngine.executeQueryForExtent(e,t.signal)}querySnapping(e,t={}){return this._queryEngine.executeQueryForSnapping(e,t.signal)}queryAttributeBins(e,t={}){return this._queryEngine.executeAttributeBinsQuery(e,t.signal)}_inferLayerProperties(e,t){let i,s,r=null,o=null,a=null;for(const t of e){const e=t.geometry;if(null!=e&&(r||(r=(0,n.$B)(e)),o||(o=e.spatialReference),null==i&&(i=x(e)),null==s&&(s=I(e)),r&&o&&null!=i&&null!=s))break}if(t&&t.length){let e=null;t.some(t=>{const i="esriFieldTypeOID"===t.type,s=!t.type&&t.name&&"objectid"===t.name.toLowerCase();return e=t,i||s})&&(a=e.name)}return{geometryType:r,spatialReference:o,objectIdField:a,hasM:s,hasZ:i}}async _loadInitialFeatures(e,t){const{geometryType:i,hasM:s,hasZ:r,objectIdField:a,spatialReference:l,featureStore:d,fieldsIndex:h}=this._queryEngine,f=[],m={type:"object-id",fieldName:a};for(const s of t){if(null!=s.uid&&(e.assignedObjectIds[s.uid]=-1),s.geometry&&i!==(0,n.$B)(s.geometry)){e.featureErrors.push((0,c.Yx)("Incorrect geometry type."));continue}const t=this._createDefaultAttributes(),r=(0,c.MB)(h,t,s.attributes,!0);r?e.featureErrors.push(r):(this._assignObjectId(t,s.attributes,!0),s.attributes=t,null!=s.uid&&(e.assignedObjectIds[s.uid]=s.attributes[a]),null!=s.geometry&&(s.geometry=(0,u.Cv)(s.geometry,s.geometry.spatialReference,l)),f.push(s))}d.addMany((0,o.Di)([],f,i,r,s,m));const{fullExtent:p,timeExtent:y}=await this._queryEngine.fetchRecomputedExtents();if(e.layerDefinition.extent=p,y){const{start:t,end:i}=y;e.layerDefinition.timeInfo.timeExtent=[t,i]}return e}async _applyEdits(e){const{adds:t,updates:i,deletes:s}=e,n={addResults:[],deleteResults:[],updateResults:[],uidToObjectId:{}};if(t?.length&&this._applyAddEdits(n,t),i?.length&&this._applyUpdateEdits(n,i),s?.length){for(const e of s)n.deleteResults.push((0,c.bP)(e));this._queryEngine.featureStore.removeManyById(s)}const{fullExtent:r,timeExtent:o}=await this._queryEngine.fetchRecomputedExtents();return{extent:r,timeExtent:o,featureEditResults:n}}_applyAddEdits(e,t){const{addResults:i}=e,{geometryType:s,hasM:r,hasZ:a,objectIdField:l,spatialReference:d,featureStore:h,featureIdInfo:f,fieldsIndex:m}=this._queryEngine,p=[];for(const r of t){if(r.geometry&&s!==(0,n.$B)(r.geometry)){i.push((0,c.Yx)("Incorrect geometry type."));continue}const t=this._createDefaultAttributes(),o=(0,c.MB)(m,t,r.attributes);if(o)i.push(o);else{if(this._assignObjectId(t,r.attributes),r.attributes=t,null!=r.uid){const t=r.attributes[l];e.uidToObjectId[r.uid]=t}if(null!=r.geometry){const e=r.geometry.spatialReference??d;r.geometry=(0,u.Cv)((0,c.CR)(r.geometry,e),e,d)}p.push(r),i.push((0,c.bP)(r.attributes[l]))}}h.addMany((0,o.Di)([],p,s,a,r,f))}_applyUpdateEdits({updateResults:e},t){const{geometryType:i,hasM:s,hasZ:r,objectIdField:a,spatialReference:l,featureStore:d,fieldsIndex:h,featureIdInfo:f}=this._queryEngine;for(const m of t){const{attributes:t,geometry:p}=m,y=t?.[a];if(null==y){e.push((0,c.Yx)(`Identifier field ${a} missing`));continue}if(!d.has(y)){e.push((0,c.Yx)(`Feature with object id ${y} missing`));continue}const _=(0,o.oN)(d.getFeature(y),i,r,s);if(null!=p){if(i!==(0,n.$B)(p)){e.push((0,c.Yx)("Incorrect geometry type."));continue}const t=p.spatialReference??l;_.geometry=(0,u.Cv)((0,c.CR)(p,t),t,l)}if(t){const i=(0,c.MB)(h,_.attributes,t);if(i){e.push(i);continue}}d.add((0,o.E2)(_,i,r,s,f)),e.push((0,c.bP)(y))}}_assignObjectId(e,t,i=!1){const s=this._queryEngine.objectIdField;i&&t&&isFinite(t[s])?e[s]=t[s]:e[s]=this._nextObjectId++}}},33032:(e,t,i)=>{i.d(t,{H:()=>n,L:()=>s});const s=1;function n(e,t){let i=0;for(const s of t){const t=s.attributes?.[e];"number"==typeof t&&isFinite(t)&&(i=Math.max(i,t))}return i}},36708:(e,t,i)=>{i.d(t,{C_:()=>c,OH:()=>p,Vh:()=>y,on:()=>h,pc:()=>_,wB:()=>l,z7:()=>u});var s=i(37955),n=i(36563),r=i(97768),o=i(74887),a=i(14012);function l(e,t,i={}){return d(e,t,i,f)}function u(e,t,i={}){return d(e,t,i,m)}function d(e,t,i={},s){let n=null;const o=i.once?(e,i)=>{s(e)&&((0,r.xt)(n),t(e,i))}:(e,i)=>{s(e)&&t(e,i)};if(n=(0,a.Cn)(e,o,i.sync,i.equals),i.initial){const t=e();o(t,t)}return n}function h(e,t,i,o={}){let a=null,u=null,d=null;function h(){a&&u&&(u.remove(),o.onListenerRemove?.(a),a=null,u=null)}function c(e){o.once&&o.once&&(0,r.xt)(d),i(e)}const f=l(e,(e,i)=>{h(),(0,s.wb)(e)&&(a=e,u=(0,s.on)(e,t,c),o.onListenerAdd?.(e))},{sync:o.sync,initial:!0});return d=(0,n.hA)(()=>{f.remove(),h()}),d}function c(e,t){return function(e,t,i){if((0,o.G4)(i))return Promise.reject((0,o.NK)());const s=e();if(t?.(s))return Promise.resolve(s);let a=null;function l(){a=(0,r.xt)(a)}return new Promise((s,r)=>{a=(0,n.vE)([(0,o.u7)(i,()=>{l(),r((0,o.NK)())}),d(e,e=>{l(),s(e)},{sync:!1,once:!0},t??f)])})}(e,m,t)}function f(e){return!0}function m(e){return!!e}i(80559);const p={sync:!0},y={initial:!0},_={sync:!0,initial:!0}},37730:(e,t,i)=>{i.d(t,{T:()=>n});var s=i(43334);const n={getObjectId:e=>e.objectId,getAttributes:e=>e.attributes,getAttribute:(e,t)=>e.attributes[t],cloneWithGeometry:(e,t)=>new s.Om(t,e.attributes,null,e.objectId),getGeometry:e=>e.geometry,getCentroid:(e,t)=>e.ensureCentroid(t)}},64714:(e,t,i)=>{i.d(t,{F0:()=>a,Vx:()=>d,e2:()=>c,f:()=>f});var s=i(44208),n=i(4718),r=i(99352),o=i(93470);function a(e){return{renderer:{type:"simple",symbol:"esriGeometryPoint"===e||"esriGeometryMultipoint"===e?o.Cb:"esriGeometryPolyline"===e?o.yM:o.WR}}}const l=/^[_$a-zA-Z][_$a-zA-Z0-9]*$/;let u=1;function d(e,t){if((0,s.A)("esri-csp-restrictions"))return()=>({[t]:null,...e});try{let i=`this${h(t)} = null;`;for(const t in e)i+=`this${h(t)} = ${JSON.stringify(e[t])};`;const s=new Function(`\n return class AttributesClass$${u++} {\n constructor() {\n ${i};\n }\n }\n `)();return()=>new s}catch(i){return()=>({[t]:null,...e})}}function h(e){return l.test(e)?`.${e}`:`["${e}"]`}function c(e={}){return[{name:"New Feature",description:"",prototype:{attributes:(0,n.o8)(e)}}]}function f(e,t){return{analytics:{supportsCacheHint:!1},attachment:null,data:{isVersioned:!1,isBranchVersioned:!1,supportsAttachment:!1,supportsM:!1,supportsZ:e},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:t,supportsDelete:t,supportsEditing:t,supportsChangeTracking:!1,supportsQuery:!0,supportsQueryBins:!0,supportsQueryPivot:!1,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:t,supportsExceedsLimitStatistics:!0,supportsAsyncConvert3D:!1},query:r.F,queryRelated:{supportsCount:!0,supportsOrderBy:!0,supportsPagination:!0,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:r.P,editing:{supportsGeometryUpdate:t,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsAsyncApplyEdits:!1,zDefault:void 0}}}},66344:(e,t,i)=>{i.d(t,{q:()=>a});const s=!!(0,i(44208).A)("esri-tests-disable-gpu-memory-measurements");Symbol.iterator;class n{get size(){return this._size}constructor(e=10485760){this._maxSize=e,this._db=new Map,this._size=0,this._hit=0,this._miss=0,this._users=new Map,this._sizeLimits=new Map}destroy(){this.clearAll(),this._sizeLimits.clear(),this._users.clear(),this._db=null}register(e){this._users.set(e.id.slice(0,-1),e)}deregister(e){this.clear(e),this._sizeLimits.delete(e),this._users.delete(e.id.slice(0,-1))}get maxSize(){return this._maxSize}set maxSize(e){this._maxSize=Math.max(e,-1),this._checkSize()}getSize(e,t){const i=this._db.get(e.id+t);return i?.size??0}put(e,t,i,n,o){t=e.id+t;const a=this._db.get(t);if(a&&(this._size-=a.size,e.size-=a.size,this._db.delete(t),a.entry!==i&&this._notifyRemove(t,a.entry,a.size,0)),n>this._maxSize)return void this._notifyRemove(t,i,n,0);if(void 0===i)return void console.warn("Refusing to cache undefined entry ");if(!n||n<0)return s||console.warn(`Refusing to cache entry with size ${n} for key ${t}`),void this._notifyRemove(t,i,0,0);const l=1+Math.max(o,-4)- -3;this._db.set(t,new r(i,n,l)),this._size+=n,e.size+=n,this._checkSize()}updateSize(e,t){t=e.id+t;const i=this._db.get(t);if(!i)return;this._size-=i.size,e.size-=i.size;let s=i.entry.usedMemory;for(;s>this._maxSize;){const e=this._notifyRemove(t,i.entry,s,1);if(!(null!=e&&e>0))return void this._db.delete(t);s=e}i.size=s,this._size+=s,e.size+=s,this._checkSize()}pop(e,t){t=e.id+t;const i=this._db.get(t);if(i)return this._size-=i.size,e.size-=i.size,this._db.delete(t),++this._hit,i.entry;++this._miss}get(e,t){t=e.id+t;const i=this._db.get(t);if(void 0!==i)return this._db.delete(t),i.lives=i.lifetime,this._db.set(t,i),++this._hit,i.entry;++this._miss}peek(e,t){const i=this._db.get(e.id+t);return i?++this._hit:++this._miss,i?.entry}get performanceInfo(){const e={Size:Math.round(this._size/1048576)+"/"+Math.round(this._maxSize/1048576)+"MB","Hit rate":Math.round(100*this._getHitRate())+"%",Entries:this._db.size.toString()},t={},i=new Array;this._db.forEach((e,s)=>{const n=e.lifetime;i[n]=(i[n]||0)+e.size,this._users.forEach(i=>{const{id:n,name:r}=i;if(s.startsWith(n)){const i=t[r]||0;t[r]=i+e.size}})});const s={};this._users.forEach(e=>{const i=e.name;if("hitRate"in e&&"number"==typeof e.hitRate&&!isNaN(e.hitRate)&&e.hitRate>0){const n=t[i]||0;t[i]=n,s[i]=Math.round(100*e.hitRate)+"%"}else s[i]="0%"});const n=Object.keys(t);n.sort((e,i)=>t[i]-t[e]),n.forEach(i=>e[i]=Math.round(t[i]/2**20)+"MB / "+s[i]);for(let t=i.length-1;t>=0;--t){const s=i[t];s&&(e["Priority "+(t+-3-1)]=Math.round(s/this._size*100)+"%")}return e}resetStats(){this._hit=this._miss=0,this._users.forEach(e=>e.resetHitRate())}clear(e){const t=e.id;this._db.forEach((e,i)=>{i.startsWith(t)&&(this._size-=e.size,this._db.delete(i),this._notifyRemove(i,e.entry,e.size,0))}),e.size=0}clearAll(){this._db.forEach((e,t)=>this._notifyRemove(t,e.entry,e.size,0)),this._users.forEach(e=>e.size=0),this._size=0,this._db.clear()}*values(e){for(const[t,i]of this._db)t.startsWith(e.id)&&(yield i.entry)}_getHitRate(){return this._hit/(this._hit+this._miss)}_notifyRemove(e,t,i,s){const n=this._users.get(e.split(o)[0])?.removeFunc,r=n?.(t,s,i);return"number"==typeof r?r:null}_checkSize(){this._sizeLimits.forEach((e,t)=>this._checkSizeLimits(e,t)),this._checkSizeLimits(this.maxSize)}setMaxSize(e,t){null==t||t<=0?this._sizeLimits.delete(e):this._sizeLimits.set(e,t)}_checkSizeLimits(e,t){const i=t??this;if(i.size<=e)return;const s=t?.id;let n=!0;for(;n;){n=!1;for(const[r,a]of this._db)if(0===a.lifetime&&(!s||r.startsWith(s))){const s=t??this._users.get(r.split(o)[0]);if(this._purgeItem(r,a,s),i.size<=.9*e)return;n||=this._db.has(r)}}for(const[n,r]of this._db)if(!s||n.startsWith(s)){const s=t??this._users.get(n.split(o)[0]);if(this._purgeItem(n,r,s),i.size<=.9*e)return}}_purgeItem(e,t,i){if(this._db.delete(e),t.lives<=1){this._size-=t.size,i&&(i.size-=t.size);const s=this._notifyRemove(e,t.entry,t.size,1);null!=s&&s>0&&(this._size+=s,i&&(i.size+=s),t.lives=t.lifetime,t.size=s,this._db.set(e,t))}else--t.lives,this._db.set(e,t)}}new n(0);class r{constructor(e,t,i){this.entry=e,this.size=t,this.lifetime=i,this.lives=i}}const o=":";class a{constructor(e,t){this.removeFunc=t,this._storage=new n,this.id="",this.name="",this.size=0,this._storage.maxSize=e,this._storage.register(this)}destroy(){this._storage.deregister(this),this._storage.destroy(),this._storage=null}put(e,t,i=1){this._storage.put(this,e,t,i,1)}pop(e){return this._storage.pop(this,e)}get(e){return this._storage.get(this,e)}clear(){this._storage.clearAll()}get maxSize(){return this._storage.maxSize}set maxSize(e){this._storage.maxSize=e}resetHitRate(){}}},67482:(e,t,i)=>{function s(e){return null!=a(e)||null!=o(e)}function n(e){return l.test(e)}function r(e){return a(e)??o(e)}function o(e){const t=new Date(e);return function(e,t){if(Number.isNaN(e.getTime()))return!1;let i=!0;if(d&&/\d+\W*$/.test(t)){const e=t.match(/[a-zA-Z]{2,}/);if(e){let t=!1,s=0;for(;!t&&s<=e.length;)t=!u.test(e[s]),s++;i=!t}}return i}(t,e)?Number.isNaN(t.getTime())?null:t.getTime()-6e4*t.getTimezoneOffset():null}function a(e){const t=l.exec(e);if(!t?.groups)return null;const i=t.groups,s=+i.year,n=+i.month-1,r=+i.day,o=+(i.hours??"0"),a=+(i.minutes??"0"),u=+(i.seconds??"0");if(o>23)return null;if(a>59)return null;if(u>59)return null;const d=i.ms??"0",h=d?+d.padEnd(3,"0").slice(0,3):0;let c;if(i.isUTC||!i.offsetSign)c=Date.UTC(s,n,r,o,a,u,h);else{const e=+i.offsetHours,t=+i.offsetMinutes;c=6e4*("+"===i.offsetSign?-1:1)*(60*e+t)+Date.UTC(s,n,r,o,a,u,h)}return Number.isNaN(c)?null:c}i.d(t,{Br:()=>n,Cq:()=>s,_U:()=>r});const l=/^(?:(?<year>-?\d{4,})-(?<month>\d{2})-(?<day>\d{2}))(?:T(?<hours>\d{2}):(?<minutes>\d{2}):(?<seconds>\d{2})(?:\.(?<ms>\d+))?)?(?:(?<isUTC>Z)|(?:(?<offsetSign>\+|-)(?<offsetHours>\d{2}):(?<offsetMinutes>\d{2})))?$/,u=/^((jan(uary)?)|(feb(ruary)?)|(mar(ch)?)|(apr(il)?)|(may)|(jun(e)?)|(jul(y)?)|(aug(ust)?)|(sep(tember)?)|(oct(ober)?)|(nov(ember)?)|(dec(ember)?)|(am)|(pm)|(gmt)|(utc))$/i,d=!Number.isNaN(new Date("technology 10").getTime())},69540:(e,t,i)=>{i.d(t,{OU:()=>d,Pw:()=>h});var s=i(31635),n=i(69622),r=(i(44208),i(4718)),o=(i(53966),i(97768)),a=i(88620),l=i(64108);const u=Symbol("ClonableMixin"),d=e=>{var t;const i=e;let n=class extends i{constructor(){super(...arguments),this[t]=!0}static{t=u}clone(e){const t=(0,a.oY)(this);(0,o.Lw)(t,"unable to clone instance of non-accessor class");const i=t.metadata,s=t.store,n={},l=new Map;for(const t in i){const o=i[t],a=s?.originOf(t),u=o.clonable;if(o.readOnly||!1===u||7!==a&&0!==a&&5!==a&&4!==a)continue;const d=this[t];let h=null;if("function"==typeof u)h=u(d,e);else if("reference"===u)h=d;else if(h=(0,r.TU)(d,e),null!=d&&null==h)continue;0===a?l.set(t,h):n[t]=h}const u=new(0,Object.getPrototypeOf(this).constructor)(n);if(l.size){const e=(0,a.oY)(u)?.store;if(e)for(const[t,i]of l)e.set(t,i,0)}return u}};return n=(0,s.Cg)([(0,l.$)("esri.core.Clonable")],n),n},h=d(n.A)},75503:(e,t,i)=>{i.d(t,{EC:()=>F,wq:()=>a});var s=i(4576),n=i(21818),r=(i(44208),i(15142)),o=i(11006);class a{constructor(e=9,t){this._compareMinX=c,this._compareMinY=f,this._toBBox=e=>e,this._maxEntries=Math.max(4,e||9),this._minEntries=Math.max(2,Math.ceil(.4*this._maxEntries)),t&&("function"==typeof t?this._toBBox=t:this._initFormat(t)),this.clear()}destroy(){this.clear(),I.prune(),S.prune(),B.prune(),M.prune()}all(e){l(this._data,e)}search(e,t){let i=this._data;const s=this._toBBox;if(b(e,i))for(I.clear();i;){for(let n=0,r=i.children.length;n<r;n++){const r=i.children[n],o=i.leaf?s(r):r;b(e,o)&&(i.leaf?t(r):g(e,o)?l(r,t):I.push(r))}i=I.pop()}}collides(e){let t=this._data;const i=this._toBBox;if(!b(e,t))return!1;for(I.clear();t;){for(let s=0,n=t.children.length;s<n;s++){const n=t.children[s],r=t.leaf?i(n):n;if(b(e,r)){if(t.leaf||g(e,r))return!0;I.push(n)}}t=I.pop()}return!1}load(e){if(!e.length)return this;if(e.length<this._minEntries){for(let t=0,i=e.length;t<i;t++)this.insert(e[t]);return this}let t=this._build(e.slice(),0,e.length-1,0);if(this._data.children.length)if(this._data.height===t.height)this._splitRoot(this._data,t);else{if(this._data.height<t.height){const e=this._data;this._data=t,t=e}this._insert(t,this._data.height-t.height-1,!0)}else this._data=t;return this}insert(e){return e&&this._insert(e,this._data.height-1),this}clear(){return this._data=new z([]),this}remove(e){if(!e)return this;let t,i=this._data,r=null,o=0,a=!1;const l=this._toBBox(e);for(B.clear(),M.clear();i||B.length>0;){if(i||(i=B.pop(),r=B.data[B.length-1],o=M.pop()??0,a=!0),i.leaf&&(t=(0,s.qh)(i.children,(0,n.zI)(e),i.children.length,i.indexHint),-1!==t))return i.children.splice(t,1),B.push(i),this._condense(B),this;a||i.leaf||!g(i,l)?r?(o++,i=r.children[o],a=!1):i=null:(B.push(i),M.push(o),o=0,r=i,i=i.children[0])}return this}toJSON(){return this._data}fromJSON(e){return this._data=e,this}_build(e,t,i,s){const n=i-t+1;let r=this._maxEntries;if(n<=r){const s=new z(e.slice(t,i+1));return u(s,this._toBBox),s}s||(s=Math.ceil(Math.log(n)/Math.log(r)),r=Math.ceil(n/r**(s-1)));const o=new T([]);o.height=s;const a=Math.ceil(n/r),l=a*Math.ceil(Math.sqrt(r));x(e,t,i,l,this._compareMinX);for(let n=t;n<=i;n+=l){const t=Math.min(n+l-1,i);x(e,n,t,a,this._compareMinY);for(let i=n;i<=t;i+=a){const n=Math.min(i+a-1,t);o.children.push(this._build(e,i,n,s-1))}}return u(o,this._toBBox),o}_insert(e,t,i){const s=this._toBBox,n=i?e:s(e);B.clear();const r=function(e,t,i,s){for(;s.push(t),!0!==t.leaf&&s.length-1!==i;){let i,s=1/0,n=1/0;for(let r=0,o=t.children.length;r<o;r++){const o=t.children[r],a=m(o),l=y(e,o)-a;l<n?(n=l,s=a<s?a:s,i=o):l===n&&a<s&&(s=a,i=o)}t=i||t.children[0]}return t}(n,this._data,t,B);for(r.children.push(e),h(r,n);t>=0&&B.data[t].children.length>this._maxEntries;)this._split(B,t),t--;!function(e,t,i){for(let s=i;s>=0;s--)h(t.data[s],e)}(n,B,t)}_split(e,t){const i=e.data[t],s=i.children.length,n=this._minEntries;this._chooseSplitAxis(i,n,s);const r=this._chooseSplitIndex(i,n,s);if(!r)return;const o=i.children.splice(r,i.children.length-r),a=i.leaf?new z(o):new T(o);a.height=i.height,u(i,this._toBBox),u(a,this._toBBox),t?e.data[t-1].children.push(a):this._splitRoot(i,a)}_splitRoot(e,t){this._data=new T([e,t]),this._data.height=e.height+1,u(this._data,this._toBBox)}_chooseSplitIndex(e,t,i){let s,n,r;s=n=1/0;for(let o=t;o<=i-t;o++){const t=d(e,0,o,this._toBBox),a=d(e,o,i,this._toBBox),l=_(t,a),u=m(t)+m(a);l<s?(s=l,r=o,n=u<n?u:n):l===s&&u<n&&(n=u,r=o)}return r}_chooseSplitAxis(e,t,i){const s=e.leaf?this._compareMinX:c,n=e.leaf?this._compareMinY:f;this._allDistMargin(e,t,i,s)<this._allDistMargin(e,t,i,n)&&e.children.sort(s)}_allDistMargin(e,t,i,s){e.children.sort(s);const n=this._toBBox,r=d(e,0,t,n),o=d(e,i-t,i,n);let a=p(r)+p(o);for(let s=t;s<i-t;s++){const t=e.children[s];h(r,e.leaf?n(t):t),a+=p(r)}for(let s=i-t-1;s>=t;s--){const t=e.children[s];h(o,e.leaf?n(t):t),a+=p(o)}return a}_condense(e){for(let t=e.length-1;t>=0;t--){const i=e.data[t];if(0===i.children.length)if(t>0){const n=e.data[t-1],r=n.children;r.splice((0,s.qh)(r,i,r.length,n.indexHint),1)}else this.clear();else u(i,this._toBBox)}}_initFormat(e){const t=["return a"," - b",";"];this._compareMinX=new Function("a","b",t.join(e[0])),this._compareMinY=new Function("a","b",t.join(e[1])),this._toBBox=new Function("a","return {minX: a"+e[0]+", minY: a"+e[1]+", maxX: a"+e[2]+", maxY: a"+e[3]+"};")}}function l(e,t){let i=e;for(S.clear();i;){if(!0===i.leaf)for(const e of i.children)t((0,n.zI)(e));else S.pushArray(i.children);i=S.pop()??null}}function u(e,t){d(e,0,e.children.length,t,e)}function d(e,t,i,s,n){n||(n=new z([])),n.minX=1/0,n.minY=1/0,n.maxX=-1/0,n.maxY=-1/0;for(let r,o=t;o<i;o++)r=e.children[o],h(n,e.leaf?s(r):r);return n}function h(e,t){e.minX=Math.min(e.minX,t.minX),e.minY=Math.min(e.minY,t.minY),e.maxX=Math.max(e.maxX,t.maxX),e.maxY=Math.max(e.maxY,t.maxY)}function c(e,t){return e.minX-t.minX}function f(e,t){return e.minY-t.minY}function m(e){return(e.maxX-e.minX)*(e.maxY-e.minY)}function p(e){return e.maxX-e.minX+(e.maxY-e.minY)}function y(e,t){return(Math.max(t.maxX,e.maxX)-Math.min(t.minX,e.minX))*(Math.max(t.maxY,e.maxY)-Math.min(t.minY,e.minY))}function _(e,t){const i=Math.max(e.minX,t.minX),s=Math.max(e.minY,t.minY),n=Math.min(e.maxX,t.maxX),r=Math.min(e.maxY,t.maxY);return Math.max(0,n-i)*Math.max(0,r-s)}function g(e,t){return e.minX<=t.minX&&e.minY<=t.minY&&t.maxX<=e.maxX&&t.maxY<=e.maxY}function b(e,t){return t.minX<=e.maxX&&t.minY<=e.maxY&&t.maxX>=e.minX&&t.maxY>=e.minY}function x(e,t,i,s,n){const r=[t,i];for(;r.length;){const t=r.pop(),i=r.pop();if(t-i<=s)continue;const a=i+Math.ceil((t-i)/s/2)*s;(0,o.q)(e,a,i,t,n),r.push(i,a,a,t)}}const I=new r.A,S=new r.A,B=new r.A,M=new r.A({deallocator:void 0});class F{constructor(){this.minX=1/0,this.minY=1/0,this.maxX=-1/0,this.maxY=-1/0}}class v extends F{constructor(){super(...arguments),this.height=1,this.indexHint=new s.vW}}class z extends v{constructor(e){super(),this.children=e,this.leaf=!0}}class T extends v{constructor(e){super(),this.children=e,this.leaf=!1}}},82832:(e,t,i)=>{i.d(t,{$1:()=>y,CR:()=>p,MB:()=>c,PC:()=>_,Yx:()=>l,bP:()=>d});var s=i(67482),n=i(21325),r=i(30524);class o{constructor(e){this.description=e,this.code=null}}class a{constructor(e){this.globalId=null,this.objectId=null,this.success=!1,this.uniqueId=null,this.error=new o(e)}}function l(e){return new a(e)}class u{constructor(e){this.globalId=null,this.success=!0,this.objectId=this.uniqueId=e}}function d(e){return new u(e)}const h=new Set;function c(e,t,i,s=!1){h.clear();for(const n in i){const o=e.get(n);if(!o)continue;const a=f(o,i[n]);if(h.add(o.name),o&&(s||o.editable)){const e=(0,r.CJ)(o,a);if(e)return l((0,r.uo)(e,o,a));t[o.name]=a}}for(const t of e.requiredFields??[])if(!h.has(t.name))return l(`missing required field "${t.name}"`);return null}function f(e,t){let i=t;return(0,r.WA)(e)&&"string"==typeof t?i=parseFloat(t):(0,r.yM)(e)&&null!=t&&"string"!=typeof t?i=String(t):(0,r.vE)(e)&&"string"==typeof t&&(i=(0,s._U)(t)),(0,r.WX)(i)}let m;function p(e,t){if(!e||!(0,n.fn)(t))return e;if("rings"in e||"paths"in e){if(null==m)throw new TypeError("geometry engine not loaded");return m.simplify(t,e)}return e}async function y(e,t){!(0,n.fn)(e)||"esriGeometryPolygon"!==t&&"esriGeometryPolyline"!==t||await async function(){return null==m&&(m=await Promise.all([i.e(3209),i.e(7559)]).then(i.bind(i,47559))),m}()}const _={supportsAutoIntervalBin:!0,supportsFixedIntervalBin:!0,supportsFixedBoundariesBin:!0,supportsDateBin:!0,supportsStackBy:!0,supportsSplitBy:!0,supportsNormalization:!0,supportedStatisticTypes:["COUNT","SUM","AVG","VAR","STDDEV","MIN","MAX","PERCENTILE_CONT","PERCENTILE_DISC","CentroidAggregate","EnvelopeAggregate","ConvexHullAggregate"],supportedNormalizationTypes:["field","log","naturalLog","percentOfTotal","squareRoot"]}},83221:(e,t,i)=>{i.d(t,{A:()=>m});var s=i(4576),n=i(49186),r=i(65529),o=i(53966),a=i(70328),l=i(19419),u=i(90708),d=i(6518),h=i(51441),c=i(37730);const f=(0,a.vt)();class m{constructor(e){this.geometryInfo=e,this._boundsStore=new d.F,this._featuresById=new Map,this._usedMemory=0,this.events=new r.bk,this.featureAdapter=c.T}get usedMemory(){return this._usedMemory}get geometryType(){return this.geometryInfo.geometryType}get hasM(){return this.geometryInfo.hasM}get hasZ(){return this.geometryInfo.hasZ}get numFeatures(){return this._featuresById.size}get fullBounds(){return this._boundsStore.fullBounds}get storeStatistics(){let e=0;return this._featuresById.forEach(t=>{null!=t.geometry&&t.geometry.coords&&(e+=t.geometry.coords.length)}),{featureCount:this._featuresById.size,vertexCount:e/(this.hasZ?this.hasM?4:3:this.hasM?3:2)}}getFullExtent(e){if(null==this.fullBounds)return null;const[t,i,s,n]=this.fullBounds;return{xmin:t,ymin:i,xmax:s,ymax:n,spatialReference:(0,h.ag)(e)}}add(e){this._add(e),this._emitChanged()}addMany(e){for(const t of e)this._add(t);this._emitChanged()}upsertMany(e){const t=e.map(e=>this._upsert(e));return this._emitChanged(),t.filter(s.Ru)}clear(){this._featuresById.clear(),this._boundsStore.clear(),this._emitChanged(),this._usedMemory=0}removeById(e){const t=this._featuresById.get(e);return t?(this._remove(t),this._emitChanged(),t):null}removeManyById(e){this._boundsStore.invalidateIndex();for(const t of e){const e=this._featuresById.get(t);e&&this._remove(e)}this._emitChanged()}forEachBounds(e,t){for(const i of e){const e=this._boundsStore.get(i.objectId);e&&t((0,a.Jt)(f,e))}}getFeature(e){return this._featuresById.get(e)}has(e){return this._featuresById.has(e)}forEach(e){this._featuresById.forEach(t=>e(t))}forEachInBounds(e,t){this._boundsStore.forEachInBounds(e,e=>{t(this._featuresById.get(e))})}_emitChanged(){this.events.emit("changed",void 0)}_add(e){if(!e)return;const t=e.objectId;if(null==t)return void o.A.getLogger("esri.layers.graphics.data.FeatureStore").error(new n.A("featurestore:invalid-feature","feature id is missing",{feature:e}));const i=this._featuresById.get(t);let s;if(i?(e.displayId=i.displayId,s=this._boundsStore.get(t),this._boundsStore.delete(t),this._usedMemory-=this.estimateFeatureUsedMemory?.(i)??0):null!=this.onFeatureAdd&&this.onFeatureAdd(e),!e.geometry?.coords?.length)return this._boundsStore.set(t,null),void this._featuresById.set(t,e);s=(0,u.jQ)(null!=s?s:(0,l.vt)(),e.geometry),null!=s&&this._boundsStore.set(t,s),this._featuresById.set(t,e),this._usedMemory+=this.estimateFeatureUsedMemory?.(e)??0}_upsert(e){const t=e?.objectId;if(null==t)return o.A.getLogger("esri.layers.graphics.data.FeatureStore").error(new n.A("featurestore:invalid-feature","feature id is missing",{feature:e})),null;const i=this._featuresById.get(t);if(!i)return this._add(e),e;this._usedMemory-=this.estimateFeatureUsedMemory?.(i)??0;const{geometry:s,attributes:r}=e;for(const e in r)i.attributes[e]=r[e];return s&&(i.geometry=s,this._boundsStore.set(t,(0,u.jQ)((0,l.vt)(),s)??null)),this._usedMemory+=this.estimateFeatureUsedMemory?.(i)??0,i}_remove(e){null!=this.onFeatureRemove&&this.onFeatureRemove(e);const t=e.objectId;return this._boundsStore.delete(t),this._featuresById.delete(t),this._usedMemory-=this.estimateFeatureUsedMemory?.(e)??0,e}}},93470:(e,t,i)=>{i.d(t,{Cb:()=>r,HW:()=>d,JR:()=>n,JZ:()=>l,WR:()=>a,b6:()=>h,fT:()=>s,nC:()=>u,yM:()=>o});const s=[252,146,31,255],n=[153,153,153,255],r={type:"esriSMS",style:"esriSMSCircle",size:6,color:s,outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[153,153,153,255]}},o={type:"esriSLS",style:"esriSLSSolid",width:.75,color:s},a={type:"esriSFS",style:"esriSFSSolid",color:[252,146,31,196],outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[255,255,255,191]}},l={type:"esriTS",color:[255,255,255,255],font:{family:"arial-unicode-ms",size:10,weight:"bold"},horizontalAlignment:"center",kerning:!0,haloColor:[0,0,0,255],haloSize:1,rotated:!1,text:"",xoffset:0,yoffset:0,angle:0},u={type:"esriSMS",style:"esriSMSCircle",color:[0,0,0,255],outline:null,size:10.5},d={type:"esriSLS",style:"esriSLSSolid",color:[0,0,0,255],width:1.5},h={type:"esriSFS",style:"esriSFSSolid",color:[0,0,0,255],outline:null}},98453:(e,t,i)=>{i.d(t,{m:()=>s});const s=new(i(66552).J)({esriFieldTypeSmallInteger:"small-integer",esriFieldTypeInteger:"integer",esriFieldTypeSingle:"single",esriFieldTypeDouble:"double",esriFieldTypeLong:"long",esriFieldTypeString:"string",esriFieldTypeDate:"date",esriFieldTypeOID:"oid",esriFieldTypeGeometry:"geometry",esriFieldTypeBlob:"blob",esriFieldTypeRaster:"raster",esriFieldTypeGUID:"guid",esriFieldTypeGlobalID:"global-id",esriFieldTypeXML:"xml",esriFieldTypeBigInteger:"big-integer",esriFieldTypeDateOnly:"date-only",esriFieldTypeTimeOnly:"time-only",esriFieldTypeTimestampOffset:"timestamp-offset"})}}]);
|