@arcgis/core 4.33.0-next.20250501 → 4.33.0-next.20250503
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/assets/esri/core/workers/RemoteClient.js +1 -1
- package/assets/esri/core/workers/chunks/{0219c3f9408d3fa3c9a0.js → 03ee9d0407c230b885ed.js} +1 -1
- package/assets/esri/core/workers/chunks/{de16b771d2c8d816c738.js → 05c80002c37002ac99e8.js} +1 -1
- package/assets/esri/core/workers/chunks/{5d40c4783f58af1ae0dc.js → 0e8181e7fc1386d08ffc.js} +1 -1
- package/assets/esri/core/workers/chunks/{96e5d192c8d23c1e324f.js → 13e68c43acc8916520db.js} +1 -1
- package/assets/esri/core/workers/chunks/{e6a5911ea21bef32834b.js → 1bc22af4cc4effcbcf2b.js} +1 -1
- package/assets/esri/core/workers/chunks/{84f972d7851d982701a0.js → 1ca7e0d519ecbfe6976f.js} +1 -1
- package/assets/esri/core/workers/chunks/{9b2ab27159500315fbc1.js → 26850ec0917ee355ddb7.js} +1 -1
- package/assets/esri/core/workers/chunks/{1bd4fe77ba6fb25322e7.js → 29e2b105f55adafc3a6d.js} +1 -1
- package/assets/esri/core/workers/chunks/{5d63dfa5a60c88e03b28.js → 2c77a543a174e5bc736a.js} +1 -1
- package/assets/esri/core/workers/chunks/{d0ddf4f1c6a351b447c7.js → 30d7d2c7d6e9e5e2ecb9.js} +1 -1
- package/assets/esri/core/workers/chunks/3fb25912b274f264c84e.js +1 -0
- package/assets/esri/core/workers/chunks/{febae745a29a17ca130a.js → 4480e4b61affb3b2e9d6.js} +1 -1
- package/assets/esri/core/workers/chunks/{4d4a271351fd288277d2.js → 49085a0b3a74e158f32f.js} +1 -1
- package/assets/esri/core/workers/chunks/{392e64a573f67817db02.js → 4cb199b547e5b97e65fb.js} +1 -1
- package/assets/esri/core/workers/chunks/4df36ee2406861c7afa8.js +1 -0
- package/assets/esri/core/workers/chunks/{9652cfd4668b95036c87.js → 532088a72c3ddc50f3be.js} +1 -1
- package/assets/esri/core/workers/chunks/{ba917175ca2a6681501e.js → 563594357f3648652a5c.js} +1 -1
- package/assets/esri/core/workers/chunks/{abfc5f9ac16c3e885c5f.js → 56db71ea7eb8a5652d98.js} +1 -1
- package/assets/esri/core/workers/chunks/{e56647e61296643c5f84.js → 5719471414810b6a9aec.js} +1 -1
- package/assets/esri/core/workers/chunks/{235efd948ae470a6f238.js → 60b1365d25581ccf0485.js} +1 -1
- package/assets/esri/core/workers/chunks/{3795793643f4db64af0e.js → 63c25455b9cf1b3df76a.js} +1 -1
- package/assets/esri/core/workers/chunks/{909be86782af3deb448e.js → 654fe135d41af81daa13.js} +1 -1
- package/assets/esri/core/workers/chunks/{cd9343c78a7c3acdbbcd.js → 681b2662f6ce936afd7e.js} +1 -1
- package/assets/esri/core/workers/chunks/{65f2b22d8fc12e6d4a87.js → 7000d9158da929a16071.js} +1 -1
- package/assets/esri/core/workers/chunks/{7551011117c3d36ff3db.js → 743cdbff5c4616ddc2b4.js} +1 -1
- package/assets/esri/core/workers/chunks/{968956284f44187f0622.js → 8540fb31bd0b29ff1906.js} +1 -1
- package/assets/esri/core/workers/chunks/8c5cea49e48f8858f115.js +1 -0
- package/assets/esri/core/workers/chunks/{237a965bd41ba8903e03.js → 921c040d0497031fd8ff.js} +1 -1
- package/assets/esri/core/workers/chunks/{96d2a0777f5c418055fb.js → 92b48e3365d1cc933113.js} +1 -1
- package/assets/esri/core/workers/chunks/{5d485c07848164099859.js → 95a4da3150ad8e8e36d8.js} +1 -1
- package/assets/esri/core/workers/chunks/{46fb6ba8900286d18b6f.js → 9d564f79b82d427fc1da.js} +1 -1
- package/assets/esri/core/workers/chunks/{00612d6e05b1c8647668.js → 9fff43ffcd5602ccc50f.js} +1 -1
- package/assets/esri/core/workers/chunks/{653ff3e631fea8ad393a.js → a0db1f3ca29e34dfa16f.js} +12 -12
- package/assets/esri/core/workers/chunks/{1cc5c566e68f2255d035.js → a6ca68ef6311ffc365b2.js} +1 -1
- package/assets/esri/core/workers/chunks/{5a51c75a2932d9da001a.js → a8d043b73e087bee7c40.js} +1 -1
- package/assets/esri/core/workers/chunks/{581180668e0229dcdc14.js → bf190d672dcbaedc1a41.js} +1 -1
- package/assets/esri/core/workers/chunks/{ebfa4a0334401f5e004a.js → c12765e0c8b44e349c2a.js} +1 -1
- package/assets/esri/core/workers/chunks/{afddb94ff4e1a70022c7.js → c3b2b05996e2008adbe3.js} +1 -1
- package/assets/esri/core/workers/chunks/{4fb4884d2de42792abe3.js → d1a9e8db5ba403abe721.js} +1 -1
- package/assets/esri/core/workers/chunks/d35cd309ba7bb8968a22.js +1 -0
- package/assets/esri/core/workers/chunks/{6e6422eda398774acbc7.js → d60da671aba70485050e.js} +1 -1
- package/assets/esri/core/workers/chunks/{7a8df1225abd54ff68ed.js → db298b292a4e43cba72d.js} +1 -1
- package/assets/esri/core/workers/chunks/{2bda2cfc6e81818d7d33.js → dcaeb57c69d432118604.js} +1 -1
- package/assets/esri/core/workers/chunks/{fb455fd89b74b70a6a2b.js → e613df03ceb39e29befa.js} +1 -1
- package/assets/esri/core/workers/chunks/{05d7d8ff3e4cbad32580.js → e8dcaa7837b6fe7bff20.js} +1 -1
- package/assets/esri/core/workers/chunks/ec1a4b82cbc44ba45f83.js +1 -0
- package/assets/esri/core/workers/chunks/ec778cc7a55068f51937.js +1 -0
- package/assets/esri/core/workers/chunks/{51339193abddfe37745d.js → f2b63597ae956db74eb3.js} +1 -1
- package/assets/esri/geometry/support/pe-wasm.wasm +0 -0
- package/assets/esri/themes/base/widgets/_OrientedImageryViewer.scss +14 -1
- package/assets/esri/themes/base/widgets/_SelectionList.scss +34 -0
- package/assets/esri/themes/base/widgets/_SelectionToolbar.scss +6 -0
- package/assets/esri/themes/dark/main.css +1 -1
- package/assets/esri/themes/light/main.css +1 -1
- package/assets/esri/themes/light/view.css +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_en.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_en.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_en.json +1 -1
- package/chunks/Bufferer-CicaNej1.js +1 -1
- package/chunks/Distance2DCalculator-C1KHhZwD.js +1 -1
- package/chunks/Envelope.js +1 -1
- package/chunks/Envelope2D.js +1 -1
- package/chunks/GeodeticDistanceCalculator-CcF1gMZX.js +1 -1
- package/chunks/Geometry.js +1 -1
- package/chunks/GeometryCleaner-BEJM7I4l.js +1 -1
- package/chunks/OperatorClip.js +1 -1
- package/chunks/OperatorCrosses.js +1 -1
- package/chunks/OperatorCut.js +1 -1
- package/chunks/OperatorGeneralize.js +1 -1
- package/chunks/OperatorGeodesicBuffer.js +1 -1
- package/chunks/OperatorGeodeticArea.js +1 -1
- package/chunks/OperatorGeodeticDensifyByLength.js +1 -1
- package/chunks/OperatorGeodeticDistance.js +1 -1
- package/chunks/OperatorGeodeticLength.js +1 -1
- package/chunks/OperatorIntersects.js +1 -1
- package/chunks/OperatorMultiPartToSinglePart.js +1 -1
- package/chunks/OperatorOverlaps.js +1 -1
- package/chunks/OperatorProximity.js +1 -1
- package/chunks/OperatorProximityGeodesic.js +1 -1
- package/chunks/OperatorShapePreservingLength.js +1 -1
- package/chunks/OperatorShapePreservingProject.js +1 -1
- package/chunks/OperatorSimplifyOGC.js +1 -1
- package/chunks/OperatorTouches.js +1 -1
- package/chunks/OperatorWithin.js +1 -1
- package/chunks/Point2D.js +1 -1
- package/chunks/ProjectionTransformation.js +1 -1
- package/chunks/QuadraticBezier.js +1 -1
- package/chunks/SideCalculator2D-BNwb5gvz.js +1 -1
- package/chunks/Transformation2D.js +1 -1
- package/chunks/containsOperator.js +1 -1
- package/chunks/disjointOperator.js +1 -1
- package/chunks/equalsOperator.js +1 -1
- package/chunks/pe-wasm.js +1 -1
- package/chunks/pe.js +1 -1
- package/geometry/coordinateFormatter.js +1 -1
- package/geometry/operators/extendOperator.js +1 -1
- package/geometry/operators/gx/operatorAlphaShape.js +1 -1
- package/geometry/operators/gx/operatorAutoComplete.js +1 -1
- package/geometry/operators/gx/operatorBuffer.js +1 -1
- package/geometry/operators/gx/operatorDifference.js +1 -1
- package/geometry/operators/gx/operatorGraphicBuffer.js +1 -1
- package/geometry/operators/gx/operatorIntegrate.js +1 -1
- package/geometry/operators/gx/operatorIntersection.js +1 -1
- package/geometry/operators/gx/operatorLabelPoint.js +1 -1
- package/geometry/operators/gx/operatorLinesToPolygons.js +1 -1
- package/geometry/operators/gx/operatorLocateBetween.js +1 -1
- package/geometry/operators/gx/operatorMinimumBoundingCircle.js +1 -1
- package/geometry/operators/gx/operatorOffset.js +1 -1
- package/geometry/operators/gx/operatorPolygonOverlay.js +1 -1
- package/geometry/operators/gx/operatorPolygonSlicer.js +1 -1
- package/geometry/operators/gx/operatorSimplify.js +1 -1
- package/geometry/operators/gx/operatorSymmetricDifference.js +1 -1
- package/geometry/operators/gx/operatorUnion.js +1 -1
- package/geometry/operators/isNearOperator.js +1 -1
- package/geometry/operators/json/containsOperator.js +1 -1
- package/geometry/operators/json/disjointOperator.js +1 -1
- package/geometry/operators/reshapeOperator.js +1 -1
- package/geometry/operators/support/apiConverter.js +1 -1
- package/geometry/operators/support/initNoPeFactory.js +1 -1
- package/geometry/operators/support/jsonConverter.js +1 -1
- package/geometry/support/WKIDUnitConversion.js +1 -1
- package/interfaces.d.ts +31 -0
- package/package.json +1 -1
- package/support/revision.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/mesh/utils.js +1 -1
- package/views/3d/interactive/Manipulator3D.js +1 -1
- package/views/3d/interactive/visualElements/PointVisualElement.js +1 -1
- package/views/3d/layers/DrapedSubView3D.js +1 -1
- package/views/3d/layers/I3SMeshView3D.js +1 -1
- package/views/3d/layers/IntegratedMesh3DTilesLayerView3D.js +1 -1
- package/views/3d/layers/MediaLayerView3D.js +1 -1
- package/views/3d/layers/graphics/Graphics3DIconSymbolLayer.js +1 -1
- package/views/3d/layers/graphics/Graphics3DMeshFillSymbolLayer.js +1 -1
- package/views/3d/layers/graphics/Graphics3DObjectSymbolLayer.js +1 -1
- package/views/3d/layers/graphics/pipeline/rendering/FeaturePipelineRenderManager.js +1 -1
- package/views/3d/layers/graphics/pipeline/rendering/LodRenderer.js +1 -1
- package/views/3d/support/StreamTextureCollection.js +1 -1
- package/views/3d/support/TextureCollection.js +1 -1
- package/views/3d/webgl-engine/Stage.js +1 -1
- package/views/3d/webgl-engine/lib/ModelDirtySet.js +1 -1
- package/views/3d/webgl-engine/lib/TextTextureAtlas.js +1 -1
- package/views/3d/webgl-engine/lib/Texture.js +1 -1
- package/views/3d/webgl-engine/lib/TextureRepository.js +1 -1
- package/views/3d/webgl-engine/lib/WebGLLayer.js +1 -1
- package/views/3d/webgl-engine/parts/Model.js +1 -1
- package/widgets/Directions/css.js +5 -0
- package/widgets/Directions.js +1 -1
- package/widgets/FeatureForm/FeatureFormUtilityNetworkAssociations/UtilityNetworkAssociationItemList.js +1 -1
- package/widgets/OrientedImageryViewer/OrientedImageryViewerViewModel.js +1 -1
- package/widgets/OrientedImageryViewer/adapters/sketch/MeasurementAdapter.js +1 -1
- package/widgets/OrientedImageryViewer/adapters/sketch/TriangulatedMeasurementAdapter.js +5 -0
- package/widgets/OrientedImageryViewer/components/ImageMeasurementWidget.js +1 -1
- package/widgets/OrientedImageryViewer/css.js +1 -1
- package/widgets/OrientedImageryViewer/imageMeasurementUtils.js +1 -1
- package/widgets/OrientedImageryViewer/mixins/SketchHandlerMixin.js +1 -1
- package/widgets/OrientedImageryViewer/mixins/TriangulatedImageMeasurementMixin.js +5 -0
- package/widgets/OrientedImageryViewer/mixins/TriangulatedSketchHandlerMixin.js +5 -0
- package/widgets/OrientedImageryViewer.js +1 -1
- package/widgets/Sketch.js +1 -1
- package/widgets/support/SelectionList/LayerItem.js +1 -1
- package/widgets/support/SelectionList/SelectionListViewModel.js +1 -1
- package/widgets/support/SelectionList/VisibleElements.js +1 -1
- package/widgets/support/SelectionList.js +1 -1
- package/widgets/support/SelectionToolbar/SelectionToolbarViewModel.js +1 -1
- package/widgets/support/SelectionToolbar/VisibleElements.js +5 -0
- package/widgets/support/SelectionToolbar.js +1 -1
- package/widgets/support/Selector2D/SelectionOperation.js +1 -1
- package/assets/esri/core/workers/chunks/11b55e7e76e50fe11bbe.js +0 -1
- package/assets/esri/core/workers/chunks/7bfa18dd8771d4932533.js +0 -1
- package/assets/esri/core/workers/chunks/84d7ed2cf5fe23a0888f.js +0 -1
- package/assets/esri/core/workers/chunks/86931186095c23e47c0c.js +0 -1
- package/assets/esri/core/workers/chunks/a79511b926a2830bb160.js +0 -1
- package/assets/esri/core/workers/chunks/e3ef0451dcdc2e966628.js +0 -1
- package/views/3d/webgl-engine/lib/ContentObject.js +0 -5
- package/views/3d/webgl-engine/lib/ContentObjectType.js +0 -5
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[1088,4163,6061],{31088:(e,t,n)=>{n.r(t),n.d(t,{OperatorGeodeticDensifyByLength:()=>r,OperatorGeodeticDensifyCursor:()=>o});var s=n(76061),i=n(55537),a=n(12189);class r{getOperatorType(){return 10310}supportsCurves(){return!0}accelerateGeometry(e,t,n){return!1}canAccelerateGeometry(e){return!1}executeMany(e,t,n,s,i){return new o(e,n,s,t,-1,-1,i)}execute(e,t,n,a,r){const o=new s.S([e]),_=this.executeMany(o,t,n,a,r).next();return _||(0,i.c)("null output"),_}}class o extends s.G{constructor(e,t,n,s,a,r,o){super(),this.m_progressTracker=o,r>0&&(0,i.t)(""),4!==n&&a>0&&(0,i.t)(""),t||(0,i.a)(""),0===t.getCoordinateSystemType()&&(0,i.a)(""),s>0||a>0||(0,i.a)(""),this.m_index=-1,this.m_inputGeoms=e,this.m_spatialReference=t,this.m_curveType=n,this.m_maxLengthMeters=s,this.m_maxDeviationMeters=a,this.m_maxAngle=r}next(){{let e;for(;e=this.m_inputGeoms.next();)return(0,i.d)(e),this.m_index=this.m_inputGeoms.getGeometryID(),this.geodeticDensify(e);return null}}getGeometryID(){return this.m_index}tock(){return!0}getRank(){return 1}geodeticDensify(e){return(0,a.L)(e,this.m_spatialReference,this.m_curveType,this.m_maxLengthMeters,this.m_maxDeviationMeters,this.m_progressTracker)}}},47591:(e,t,n)=>{n.d(t,{O:()=>p});var s=n(55537),i=n(12189),a=n(35368),r=n(83661),o=n(95213),_=n(79187),h=n(5247),m=n(31139);function u(){return{m_pGcs:new r.P,m_xyz:new o.d,m_factor:Number.NaN,m_geoLength:Number.NaN,setValues:c,setLength:l,assign:g}}function c(e,t,n,s){this.m_factor=e,this.m_pGcs.assign(t),this.m_xyz.assign(s),this.m_geoLength=n}function l(e){this.m_geoLength=e}function g(e){this.m_pGcs.assign(e.m_pGcs),this.m_xyz.assign(e.m_xyz),this.m_factor=e.m_factor,this.m_geoLength=e.m_geoLength}class p{getOperatorType(){return 10315}supportsCurves(){return!0}accelerateGeometry(e,t,n){return!1}canAccelerateGeometry(e){return!1}_ExecuteShapePreservingLength(e,t,n,s,a){if(e.hasNonLinearSegments()&&(e=(new h.O).execute(e,0,t.getTolerance(0),0,a)),t.isPannable()){let s=90,r=-90;if(1===n.getUnit().getUnitToBaseFactor()&&(s*=Math.PI/180,r*=Math.PI/180),2===t.getCoordinateSystemType()){let e=null;const n=[0,0,0,0];e=t.getPECoordSys(),n[0]=0,n[1]=s,n[2]=0,n[3]=r,i.K.geogToProj(e,2,n),s=n[1],r=n[3]}const o=new _.Envelope2D;e.queryEnvelope(o),o.ymin=r,o.ymax=s,e=(new m.O).execute(e,o,t,a)}else{const n=t.getPCSHorizon();if((e=(new i.g).execute(e,n,t,a))===n){const t=e.clone();e=t}}return e.isEmpty()?0:this._ExecuteIterativeApproach(e,t,n,s,1,a)}_ExecuteIterativeApproach(e,t,n,a,_,h){const m=(0,i.J)();n.querySpheroidData(m);const c=m.majorSemiAxis,l=m.e2,g=n.getUnit().getUnitToBaseFactor(),p=(0,r.n)(u,40),P=(0,r.d)(40,Number.NaN),f=u(),E=u();let S;const x=[0,0,0,0],v=t.getPECoordSys(),N=new r.P,D=new r.P,A=new r.P,M=new r.P,C=new r.P;let T=0;const q=e.querySegmentIterator();for(;q.nextPath();)for(;q.hasNextSegment();){const e=q.nextSegment();N.assign(e.getStartXY()),D.assign(e.getEndXY()),2===t.getCoordinateSystemType()?(x[0]=N.x,x[1]=N.y,x[2]=D.x,x[3]=D.y,i.K.projToGeog(v,2,x),A.x=x[0]*g,A.y=x[1]*g,M.x=x[2]*g,M.y=x[3]*g):(A.setCoordsPoint2D(N),M.setCoordsPoint2D(D),A.scale(g),M.scale(g));const n=new o.d,a=new o.d;y(c,l,A,n),y(c,l,M,a);let r=d(c,n,a);f.setValues(0,A,Number.NaN,n),E.setValues(1,M,r,a),S=_,p[0].assign(E),P[0]=_;let h=0;for(;;){h>128&&(0,s.c)("iterations exceeded");const n=.5*(f.m_factor+E.m_factor),a=e.getCoord2D(n);2===t.getCoordinateSystemType()?(x[0]=a.x,x[1]=a.y,i.K.projToGeog(v,1,x),C.x=x[0]*g,C.y=x[1]*g):(C.setCoordsPoint2D(a),C.scale(g)),A.setCoordsPoint2D(f.m_pGcs),M.setCoordsPoint2D(E.m_pGcs);const m=new o.d;y(c,l,C,m);const u=d(c,f.m_xyz,m),N=d(c,E.m_xyz,m);r=E.m_geoLength,Number.isNaN(r)&&(r=d(c,f.m_xyz,E.m_xyz));const D=u+N,q=S===_&&D>=20&&Math.abs(D-r)>1e-8*(r+D);if(h+2<40&&(q||Math.abs(D-r)>0&&S>0))E.setLength(N),p[h].assign(E),E.setValues(n,C,u,m),p[++h].assign(E),q?(S=_,P[h]=_):(S--,P[h-1]=S,P[h]=S);else{if(T+=D,0===h)break;f.assign(E),E.assign(p[--h]),S=P[h]}}}return T}execute(e,t,n){if(t&&0!==t.getCoordinateSystemType()||(0,s.a)(""),e.isEmpty()||e.getDimension()<1)return 0;let r=null;const o=t.getGCS();o!==t&&(r=(0,i.w)(t,o,null));const _=e.getGeometryType();if(_===s.G.enumEnvelope){const s=new a.a;return s.addEnvelope(e,!1),this._ExecuteShapePreservingLength(s,t,o,r,n)}if((0,s.f)(_)){const s=new a.P;return s.addSegment(e,!0),this._ExecuteShapePreservingLength(s,t,o,r,n)}return this._ExecuteShapePreservingLength(e,t,o,r,n)}}function y(e,t,n,s){s.assign((0,i.y)(e,t,n))}function d(e,t,n){const s=e,i=new o.d;i.setSub(t,n);const a=i.length();return 2*s*Math.asin(a/(2*s))}},74163:(e,t,n)=>{n.r(t),n.d(t,{OperatorGeodeticArea:()=>q});var s=n(55537),i=n(35368),a=n(5247),r=n(12189),o=n(83661),_=n(79187),h=n(95213),m=n(31139),u=n(47591),c=n(90237),l=n(11878);n(90135),n(76061),n(31088),Symbol.dispose;class g{constructor(e,t,n,s,i=0,a=4){this.m_ptDistFrom=new o.P,this.m_segStartPt=new o.P,this.m_segEndPt=new o.P,this.m_geodeticLength=new r.P,this.m_az12=new r.P,this.m_minGeodeticDist=new r.P,this.m_segStartPt3d=new h.d,this.m_segEndPt3d=new h.d,this.m_sr=s,this.m_distCurveType=i,this.m_segCurveType=a,this.m_inputGCS=this.m_sr.getGCS(),this.m_rpu=this.m_inputGCS.getUnit().getUnitToBaseFactor(),this.m_bIsPannablePcs=2===this.m_sr.getCoordinateSystemType()&&this.m_sr.isPannable();const _=(0,r.J)();this.m_inputGCS.querySpheroidData(_),this.m_a=_.majorSemiAxis,this.m_eSquared=_.e2,this.setPointDistFrom(e),this.setSegmentEndPoints(t,n)}setSegmentEndPoints(e,t){this.m_segStartPt.assign(e),this.m_segEndPt.assign(t),this.m_bIsPannablePcs||(this.m_segStartPt.mulThis(this.m_rpu),this.m_segEndPt.mulThis(this.m_rpu)),2===this.m_segCurveType&&(this.m_segStartPt3d.assign((0,r.y)(this.m_a,this.m_eSquared,this.m_segStartPt)),this.m_segEndPt3d.assign((0,r.y)(this.m_a,this.m_eSquared,this.m_segEndPt))),this.calculateAndUpdateSegmentLength()}setPointDistFrom(e){this.m_ptDistFrom.assign(e),this.m_ptDistFrom.scale(this.m_rpu)}setSegmentCurveType(e){this.m_segCurveType=e}setDistanceCurveType(e){this.m_distCurveType=e}makeFunctor(){return e=>{let t;switch(this.m_segCurveType){case 0:case 1:case 3:{const n={stack:[],error:void 0,hasError:!1};try{const s=(0,c.b)(n,new r.P,!1),i=(0,c.b)(n,new r.P,!1);r.x.geodeticCoordinate(this.m_a,this.m_eSquared,this.m_segStartPt.x,this.m_segStartPt.y,this.m_geodeticLength.val*e,this.m_az12.val,s,i,this.m_segCurveType),t=new o.P(s.val,i.val);break}catch(e){n.error=e,n.hasError=!0}finally{(0,c.c)(n)}}case 2:{const n=h.d.lerp(this.m_segStartPt3d,this.m_segEndPt3d,e);t=(0,r.I)(this.m_a,this.m_eSquared,n);break}case 4:t=o.P.lerp(this.m_segStartPt,this.m_segEndPt,e),this.m_bIsPannablePcs&&((0,r.A)(this.m_sr,0,[t],1),t.mulThis(this.m_rpu));break;default:(0,s.c)("Invalid curve type")}return r.x.geodeticDistance(this.m_a,this.m_eSquared,this.m_ptDistFrom.x,this.m_ptDistFrom.y,t.x,t.y,this.m_minGeodeticDist,null,null,this.m_distCurveType),this.m_minGeodeticDist.val}}calculateAndUpdateSegmentLength(){switch(this.m_segCurveType){case 0:case 2:case 1:case 3:r.x.geodeticDistance(this.m_a,this.m_eSquared,this.m_segStartPt.x,this.m_segStartPt.y,this.m_segEndPt.x,this.m_segEndPt.y,this.m_geodeticLength,this.m_az12,null,this.m_segCurveType);break;case 4:this.m_geodeticLength.val=o.P.distance(this.m_segStartPt,this.m_segEndPt);break;default:(0,s.c)("Invalid curve type")}}[Symbol.dispose](){this.m_geodeticLength[Symbol.dispose](),this.m_az12[Symbol.dispose](),this.m_minGeodeticDist[Symbol.dispose]()}}Symbol.dispose;class p{constructor(e,t,n,s,i=100){this.m_startPt=e.clone(),this.m_endPt=t.clone(),this.m_cE2=s,this.m_cE=Math.sqrt(this.m_cE2),this.m_c1By2e=1/(2*this.m_cE),this.m_cRpu=n.getGCS().getUnit().getUnitToBaseFactor(),this.isPcs=2===n.getCoordinateSystemType(),this.PEProjcs=n.getPECoordSys(),this.m_points=(0,o.d)(2*i,Number.NaN)}setSegmentEndPoints(e,t){this.m_startPt.assign(e),this.m_endPt.assign(t)}makeFunctor(){return e=>{const t=[0,0];t[0]=this.m_startPt.x*(1-e)+this.m_endPt.x*e,t[1]=this.m_startPt.y*(1-e)+this.m_endPt.y*e,this.isPcs&&r.K.projToGeogCenter(this.PEProjcs,1,t,0);const n=Math.sin(t[1]*this.m_cRpu);return 0===this.m_cE2?n:-Math.log((1-this.m_cE*n)/(1+this.m_cE*n))*this.m_c1By2e+n/(1-this.m_cE2*n*n)}}}function y(e,t,n,s,i){const o=(new a.O).execute(e,t,0,0,i);let h;h=s?(new r.v).execute(o,s,i):o;const m=1===n.getUnit().getUnitToBaseFactor()?Math.PI/180:1,u=new _.Envelope2D;h.queryEnvelope(u);const c=new _.Envelope2D,l=new _.Envelope2D,g=new _.Envelope2D;c.setCoords({xmin:u.xmin,ymin:75*m,xmax:u.xmax,ymax:90*m}),l.setCoords({xmin:u.xmin,ymin:-60*m,xmax:u.xmax,ymax:75*m}),g.setCoords({xmin:u.xmin,ymin:-90*m,xmax:u.xmax,ymax:-60*m}),c.inflateCoords(.01*c.width(),0),l.inflateCoords(.01*l.width(),0),g.inflateCoords(.01*g.width(),0);let p=0;return p+=d(h,c,n,i),p+=d(h,l,n,i),p+=d(h,g,n,i),p}function d(e,t,n,i){const a=(new m.O).execute(e,t,n,i);if(null!==a&&!a.isEmpty()){const e=new _.Envelope2D;a.queryEnvelope(e);const{first:t,second:h}=function(e,t){const n=function(e,t){const n=e.getUnit().getUnitToBaseFactor(),i=t.getCenter();i.scale(180*n/Math.PI);const a=new o.P;a.x=0,a.y=0;let _=0;if(0===_){i.y>45?(a.y=o.p,_=0):i.y<-45?(a.y=-o.p,_=1):i.x>=45&&i.x<135?(a.x=o.p,_=2):i.x>=135||i.x<-135?(a.x=o.p,_=3):i.x<-45&&i.x>=-135?(a.x=-o.p,_=4):(a.x=0,_=5);const e=n*Math.sqrt((0,o.a)(t.xmin-t.xmax)+(0,o.a)(t.ymin-t.ymax)),s=a.clone(),r=t.getCenter();if(r.scale(n),_<2&&(s.x=r.x),o.P.distance(s,r)+.5*e>o.p)return null}const h=P[_];if(null!==h&&h.getGCS().equalHorizontal(e))return h;const m=e.getText(),u=a.x,c=a.y;let l=0,g=-1;6!==_?g=r.a6.PE_PRJ_LAMBERT_AZIMUTHAL_EQAREA:((0,s.g)(false),l=0,g=r.a6.PE_PRJ_CYLINDRICAL_EQAREA);const p=(0,r.aw)("EqualAreaPCS");let y;g===r.a6.PE_PRJ_LAMBERT_AZIMUTHAL_EQAREA?y=`PROJCS["${p}",${m},PROJECTION["Lambert_Azimuthal_Equal_Area"],PARAMETER["False_Easting",0],PARAMETER["False_Northing",0],PARAMETER["Central_Meridian",${u}],PARAMETER["Latitude_of_Origin",${c}],UNIT["Meter",1.0]]`:g===r.a6.PE_PRJ_CYLINDRICAL_EQAREA?y=`PROJCS["${p}",${m},PROJECTION["Cylindrical_Equal_Area"],PARAMETER["False_Easting",0],PARAMETER["False_Northing",0],PARAMETER["Central_Meridian",${u}],PARAMETER["Standard_Parallel_1",${l}],PARAMETER["Latitude_of_Origin",${c}],UNIT["Meter",1.0]]`:(0,s.c)("getEqualAreaPcsFixed");const d=(0,r.a)(y);return P[_]&&P[_].destroy(),P[_]=d,d}(e,t);if(null!==n)return(0,o.k)(n,!1);const i=e.getText(),a=e.getUnit().getUnitToBaseFactor(),_=(t.xmin+t.width()/2)*a,h=(t.ymin+t.height()/2)*a;let m=0,u=0,c=-1;t.ymin*a>=75*Math.PI/180||t.ymax*a<=-60*Math.PI/180?c=r.a6.PE_PRJ_LAMBERT_AZIMUTHAL_EQAREA:t.ymin>0||t.ymax<0?(m=(t.ymin+1/3*t.height())*a,u=(t.ymin+2/3*t.height())*a,c=r.a6.PE_PRJ_ALBERS):(m=(t.ymin+2/3*t.height())*a,c=r.a6.PE_PRJ_CYLINDRICAL_EQAREA);const l=(0,r.aw)("EqualAreaPCS");let g;return c===r.a6.PE_PRJ_LAMBERT_AZIMUTHAL_EQAREA?g=`PROJCS["${l}",${i},PROJECTION["Lambert_Azimuthal_Equal_Area"],PARAMETER["False_Easting",0],PARAMETER["False_Northing",0],PARAMETER["Central_Meridian",${_}],PARAMETER["Latitude_of_Origin",${h}],UNIT["Meter",1.0]]`:c===r.a6.PE_PRJ_ALBERS?g=`PROJCS["${l}",${i},PROJECTION["Albers"],PARAMETER["False_Easting",0],PARAMETER["False_Northing",0],PARAMETER["Central_Meridian",${_}],PARAMETER["Standard_Parallel_1",${m}],PARAMETER["Standard_Parallel_2",${u}],PARAMETER["Latitude_of_Origin",${h}],UNIT["Meter",1.0]]`:c===r.a6.PE_PRJ_CYLINDRICAL_EQAREA?g=`PROJCS["${l}",${i},PROJECTION["Cylindrical_Equal_Area"],PARAMETER["False_Easting",0],PARAMETER["False_Northing",0],PARAMETER["Central_Meridian",${_}],PARAMETER["Standard_Parallel_1",${m}],PARAMETER["Latitude_of_Origin",${h}],UNIT["Meter",1.0]]`:(0,s.c)("getEqualAreaPCSInstance"),(0,o.k)((0,r.a)(g),!0)}(n,e),m=(0,r.w)(n,t,null),u=(new r.v).execute(a,m,i).calculateArea2D();return h&&t.destroy(),u}return 0}const P=[null,null,null,null,null,null,null];class f{getOperatorType(){return 10314}supportsCurves(){return!0}accelerateGeometry(e,t,n){return!1}canAccelerateGeometry(e){return!1}execute(e,t,n){if(0===t.getCoordinateSystemType()&&(0,s.a)(""),e.isEmpty()||e.getDimension()<2)return 0;if((0,s.d)(e),e.getGeometryType()===s.G.enumEnvelope){const s=new i.a;return s.addEnvelope(e,!1),this.execute(s,t,n)}let c=e;e.getDescription().getAttributeCount()>1&&(c=e.clone(),c.dropAllAttributes());const l=(new a.O).execute(c,0,t.getTolerance(0),0,n);let g=null;const d=t.getGCS();d!==t&&(g=(0,r.w)(t,d));let P=(new r.O).execute(l,t,!1,n);return P.isEmpty()?0:(P===e&&(P=e.clone()),t.isPannable()?function(e,t,n){const s=new _.Envelope2D;e.queryEnvelope(s);const a=(0,h.c)(t,s,!0).total(),u=t.getPannableExtent();u.xmin=s.xmin-10*a,u.xmax=s.xmax+10*a;const c=(new m.O).execute(e,u,t,n).getImpl().querySegmentIterator();c.stripAttributes();const l=(0,r.J)();t.querySpheroidData(l);const g=l.e2,y=0===g?2:1,d=new o.P(0,0),P=new o.P(0,0),f=new o.K(0),E=new p(d,P,t,g,100);for(;c.nextPath();)for(;c.hasNextSegment();){const e=c.nextSegment();d.assign(e.getStartXY()),P.assign(e.getEndXY()),E.setSegmentEndPoints(d,P);const t=(0,i.v)(6,0,1,1e-12,1e-15,E.makeFunctor());f.pe((P.x-d.x)*t)}const S=l.majorSemiAxis;return y*S*S*(1-g)*Math.PI*f.getResult()/t.getPannableExtent().width()}(P,t,n):function(e,t,n,s,i){const a=function(e,t,n){const s=e.calculateLength2D(),i=(new u.O).execute(e,t,n)/25e3,a=s/e.getSegmentCount()*2;let r=Math.min(a,s/i);return 0===r&&(r=1),(0,o.k)(r,s/r)}(e,t,i);let r=y(e,a.first,n,s,i),_=1,h=0,m=0;do{if(_++,a.first*=.5,a.first<50*t.getTolerance(0))return r;a.second*=2,m=y(e,a.first,n,s,i),h=Math.abs(m-r),r=m}while(Math.abs(r)>1&&h>1e-8*Math.abs(r)&&(a.second<65e3&&_<8||_<4));return m}(P,t,d,g,n))}}function E(){return{m_p_PCS:new o.P,m_factor:Number.NaN,setValues:S,assign:x}}function S(e,t){this.m_factor=e,this.m_p_PCS.assign(t)}function x(e){this.m_factor=e.m_factor,this.m_p_PCS.assign(e.m_p_PCS)}class v{constructor(e,t,n,s){this.m_ptStart=new h.d,this.m_ptEnd=new h.d,this.m_ptStart.assign(t),this.m_ptEnd.assign(n),this.m_deltaX=this.m_ptEnd.x-this.m_ptStart.x,this.m_deltaY=this.m_ptEnd.y-this.m_ptStart.y,this.m_e=Math.sqrt(e),this.m_e2=e,this.m_c1MinusE2=1-e;const i=Math.sin(s);let a;a=0===this.m_e2?2*i:i*((0,o.y)(this.m_e*i)+1/(1-this.m_e2*i*i)),this.m_baseA=a}setSegmentEndPoints(e,t){this.m_ptStart.assign(e),this.m_ptEnd.assign(t),this.m_deltaX=this.m_ptEnd.x-this.m_ptStart.x,this.m_deltaY=this.m_ptEnd.y-this.m_ptStart.y}makeFunctor(){return e=>{const t=1-e,n=t*this.m_ptStart.x+e*this.m_ptEnd.x,s=t*this.m_ptStart.y+e*this.m_ptEnd.y,i=t*this.m_ptStart.z+e*this.m_ptEnd.z,a=n*n+s*s,r=i/Math.sqrt(i*i+this.m_c1MinusE2*this.m_c1MinusE2*a);let _;return _=0===this.m_e2?2*r:r*((0,o.y)(this.m_e*r)+1/(1-this.m_e2*r*r)),(this.m_deltaY*n-this.m_deltaX*s)/a*(_-this.m_baseA)}}}function N(){return{sin_phi:Number.NaN,one_p_sin_phi:Number.NaN,one_m_sin_phi:Number.NaN,one_m_e_2_sin_2_phi:Number.NaN,sin_half_phi_pf:Number.NaN,sin_half_phi_pz:Number.NaN,sin_half_asin_e_sin_phi_pf:Number.NaN,sin_half_asin_e_sin_phi_pz:Number.NaN,atanh_sin_phi:Number.NaN,atanh_esin_phi:Number.NaN,make_negative:!1,initialize:D,changeSign:A,assign:M,clone:C}}function D(e,t,n,s){const i=.5*e;this.sin_phi=Math.sin(e);const a=t*this.sin_phi,r=.5*Math.asin(a);this.one_p_sin_phi=1+this.sin_phi,this.one_m_sin_phi=1-this.sin_phi,this.one_m_e_2_sin_2_phi=(1+a)*(1-a),this.sin_half_phi_pf=Math.sin(i+n),this.sin_half_phi_pz=Math.sin(i+s),this.sin_half_asin_e_sin_phi_pf=Math.sin(r+n),this.sin_half_asin_e_sin_phi_pz=Math.sin(r+s),this.atanh_sin_phi=Math.log(this.sin_half_phi_pf/this.sin_half_phi_pz),this.atanh_esin_phi=Math.log(this.sin_half_asin_e_sin_phi_pf/this.sin_half_asin_e_sin_phi_pz)}function A(){this.sin_phi=-this.sin_phi;let e=this.one_p_sin_phi;this.one_p_sin_phi=this.one_m_sin_phi,this.one_m_sin_phi=e,e=this.sin_half_phi_pf,this.sin_half_phi_pf=this.sin_half_phi_pz,this.sin_half_phi_pz=e,e=this.sin_half_asin_e_sin_phi_pf,this.sin_half_asin_e_sin_phi_pf=this.sin_half_asin_e_sin_phi_pz,this.sin_half_asin_e_sin_phi_pz=e,this.atanh_sin_phi=-this.atanh_sin_phi,this.atanh_esin_phi=-this.atanh_esin_phi}function M(e){this.sin_phi=e.sin_phi,this.one_p_sin_phi=e.one_p_sin_phi,this.one_m_sin_phi=e.one_m_sin_phi,this.one_m_e_2_sin_2_phi=e.one_m_e_2_sin_2_phi,this.sin_half_phi_pf=e.sin_half_phi_pf,this.sin_half_phi_pz=e.sin_half_phi_pz,this.sin_half_asin_e_sin_phi_pf=e.sin_half_asin_e_sin_phi_pf,this.sin_half_asin_e_sin_phi_pz=e.sin_half_asin_e_sin_phi_pz,this.atanh_sin_phi=e.atanh_sin_phi,this.atanh_esin_phi=e.atanh_esin_phi,this.make_negative=e.make_negative}function C(){return{...this}}class T{constructor(e,t,n){this.m_transformPCS2GCS=null,this.m_scaleToRadians=new l.T,this.m_scaleToDegrees=new l.T,this.m_progressTracker=n,(0,s.g)(4!==t),this.m_curveType=t,this.m_inputSR=e,e&&0!==e.getCoordinateSystemType()||(0,s.a)(""),this.m_inputGCS=e.getGCS(),this.m_a=0,this.m_eSquared=0,this.m_b=0,this.m_rpu=0}executePolygonGeodeticArea(e){let t,n=e.clone();if(n.dropAllAttributes(),e.hasNonLinearSegments()&&(n=(new a.O).execute(n,0,this.m_inputSR.getTolerance(0),0,this.m_progressTracker)),this.m_inputSR.isPannable()){const e=new _.Envelope2D;n.queryEnvelope(e);const t=this.m_inputSR.getPannableExtent();if(!t.containsEnvelope(e)){const s=t.getCenterX()-e.getCenterX(),i=new l.T;i.setShiftCoords(s,0),n.applyTransformation(i),e.move(s,0);const a=new o.E;t.queryIntervalX(a);const _=new o.E;e.queryIntervalX(_),n=a.contains(_)?(0,r.F)(n,this.m_inputSR):(new r.v).foldInto360RangeGeodetic(n,this.m_inputSR,this.m_curveType)}}if(this.m_transformPCS2GCS?(n=(new r.O).execute(n,this.m_inputSR,!1,this.m_progressTracker),t=n.createInstance(),(0,r.N)(this.m_transformPCS2GCS,n,t,this.m_progressTracker)||(t=(new r.v).execute(n,this.m_transformPCS2GCS,this.m_progressTracker))):t=(new r.O).execute(n,this.m_inputGCS,!1,this.m_progressTracker),t.isEmpty())return 0;if(1===this.m_curveType){const e=(0,r.J)();return this.m_inputGCS.querySpheroidData(e),this.m_a=e.majorSemiAxis,this.m_eSquared=e.e2,this.loxodromeArea(t)}const s=t.getImpl();this.m_rpu=this.m_inputGCS.getUnit().getUnitToBaseFactor(),this.m_scaleToRadians.setScale(this.m_rpu),s.applyTransformation(this.m_scaleToRadians),this.m_scaleToDegrees=this.m_scaleToRadians,this.m_scaleToDegrees.invertThis();const i=(0,r.J)();if(this.m_inputGCS.querySpheroidData(i),this.m_a=i.majorSemiAxis,this.m_b=i.minorSemiAxis,this.m_eSquared=i.e2,2===this.m_curveType)return this.executeClippedPolygonGreatEllipticArea(t);{const e={stack:[],error:void 0,hasError:!1};try{const n=r.ax.unit(9101),s=this.m_inputGCS.getPECoordSys(),i=(0,c.b)(e,s.cloneAlterUnits(n),!1);let a,o,_=this.executeClippedPolygonGeodeticArea(t,i,0),h=0;do{h++,a=this.executeClippedPolygonGeodeticArea(t,i,h),o=Math.abs(a-_),_=a}while(Math.abs(a)>1&&o>1e-8*Math.abs(a)&&h<7);return a}catch(t){e.error=t,e.hasError=!0}finally{(0,c.c)(e)}}}executeClippedPolygonGeodeticArea(e,t,n){const s={stack:[],error:void 0,hasError:!1};try{const i=new _.Envelope2D;e.queryEnvelope(i);const a=(0,c.b)(s,this.getEqualAreaPCSInstance(t,i),!1),h=e.clone();(0,r.ay)(a,h);const m=50,u=h.getImpl().getAttributeStreamRef(0),l=e.getImpl().getAttributeStreamRef(0),g=(0,c.b)(s,new r.P,!1),p=(0,c.b)(s,new r.P,!1),y=40,d=[0,0],P=(0,o.n)(E,y),f=(0,o.d)(y,-1),S=E(),x=E();let v,N;const D=a;let A=h.calculateArea2D();const M=new o.K(0),C=.5*Math.PI,T=1e-10*Math.abs(A)+1e-6,q=e.getPathCount();let b,w,I,R;const G=new o.P,L=new o.P,B=new o.P,z=new o.P,O=new o.P,k=new o.P;let F,Y;for(w=e.getPathStart(0),b=0;b<q;b++,w=I)for(I=e.getPathEnd(b),u.queryPoint2D(I-1<<1,B),l.queryPoint2D(I-1<<1,G),Math.abs(G.y)>C&&(G.y=(0,o.f)(C,G.y)),R=w;R<I;R++,B.assign(z),G.assign(L)){if(u.queryPoint2D(R<<1,z),l.queryPoint2D(R<<1,L),Math.abs(L.y)>C&&(L.y=(0,o.f)(C,L.y)),F=o.P.distance(B,z),F<m||0===G.y&&0===L.y)continue;r.x.geodeticDistance(this.m_a,this.m_eSquared,G.x,G.y,L.x,L.y,g,p,null,this.m_curveType);const e=g.val,t=p.val;for(S.setValues(0,B),x.setValues(1,z),N=n,P[0].assign(x),f[0]=n,v=0;v>=0;){Y=.5*(S.m_factor+x.m_factor),r.x.geodeticCoordinate(this.m_a,this.m_eSquared,G.x,G.y,e*Y,t,g,p,this.m_curveType),O.x=g.val,O.y=p.val,d[0]=O.x,d[1]=O.y,r.K.geogToProj(D,1,d),k.x=d[0],k.y=d[1];const n=.5*-k.offset(S.m_p_PCS,x.m_p_PCS)*o.P.distance(S.m_p_PCS,x.m_p_PCS);if(M.pe(n),Math.abs(n)>T||Math.abs(n)>0&&N>0)x.setValues(Y,k),v++,P[v].assign(x),Math.abs(n)<=T?(N--,f[v-1]=N,f[v]=N):(N=f[v-1],f[v]=N);else{if(v<=0)break;S.assign(x),v--,x.assign(P[v]),N=f[v]}}}return A+=M.getResult(),Math.abs(A)}catch(e){s.error=e,s.hasError=!0}finally{(0,c.c)(s)}}executeClippedPolygonGreatEllipticArea(e){const t=[],n=[],s=new o.P,i=new o.P,a=(0,r.y)(1,this.m_eSquared,new o.P(0,.5*Math.PI)),m=new o.K(0),u=new o.K(0),c=new o.K(0),l=new h.d,g=new h.d,p=new _.Envelope2D;e.queryLooseEnvelope(p);let y=0;p.containsCoords(p.xmin,0)||(y=Math.abs(p.ymin)<Math.abs(p.ymax)?p.ymin:p.ymax);const d=new v(this.m_eSquared,l,g,y),P=this.m_a*this.m_a,f=e.getImpl().querySegmentIterator();for(f.stripAttributes();f.nextPath();)for(;f.hasNextSegment();){const e=f.nextSegment();s.assign(e.getStartXY()),i.assign(e.getEndXY()),i.x-s.x>Math.PI?s.x+=2*Math.PI:i.x-s.x<-Math.PI&&(i.x+=2*Math.PI),this.splitSegmentCrossingItegralThreshold(e,t,n);for(let e of t)l.assign((0,r.y)(this.m_a,this.m_eSquared,e.getStartXY())),g.assign((0,r.y)(this.m_a,this.m_eSquared,e.getEndXY())),d.setSegmentEndPoints(l,g),this.adaptiveIntegrationWithRomberg(d,m);for(let e of n){let t=e.getStartXY(),n=e.getEndXY(),s=y;t.y<0&&(n=(0,o.c)(t,t=n),t.y=-t.y,n.y=-n.y,s=-s);const i=(0,r.y)(1,this.m_eSquared,t),_=(0,r.y)(1,this.m_eSquared,n),m=Math.min(t.y,n.y),l=(0,r.az)(this.m_eSquared,t.x,n.x,s,m);u.pe(l);const g=Math.abs((0,r.az)(this.m_eSquared,t.x,n.x,m,o.p)),p=new h.d;p.setSub(i,a);const d=new h.d;d.setSub(_,a);const f=new h.d;f.setCrossProductVector(p,d);let E=P*(g-.5*f.length());E=(0,o.f)(E,n.x-t.x),c.pe(E)}t.length=0,n.length=0}return c.getResult()+P*(.5*(1-this.m_eSquared)*m.getResult()+u.getResult())}getEqualAreaPCSInstance(e,t){const n=t.getCenterX();let s,i;const a=t.height();let _,h;(_=t.ymin>45*Math.PI/180||t.ymax<45*-Math.PI/180)?s=(0,o.f)(.5*Math.PI,t.getCenterY()):(s=t.getCenterY(),i=t.ymin+a*(2/3));const m=(0,r.aw)("EqualAreaPCS"),u=e.toString();return h=_?r.ax.fromString(r.a6.PE_TYPE_PROJCS,`PROJCS["${m}", ${u}, PROJECTION["Lambert_Azimuthal_Equal_Area"],PARAMETER["False_Easting",0],PARAMETER["False_Northing", 0],PARAMETER["Central_Meridian", ${n}], PARAMETER["Latitude_of_Origin", ${s}], UNIT["Meter",1.0]]`):r.ax.fromString(r.a6.PE_TYPE_PROJCS,`PROJCS["${m}", ${u}, PROJECTION["Cylindrical_Equal_Area"],PARAMETER["False_Easting", 0],PARAMETER["False_Northing", 0],PARAMETER["Central_Meridian", ${n}],PARAMETER["Standard_Parallel_1", ${i}],PARAMETER["Latitude_of_Origin", ${s}],UNIT["Meter",1.0]]`),h}splitSegmentCrossingItegralThreshold(e,t,n){const s=100,a=400,_=(0,r.y)(this.m_a,this.m_eSquared,new o.P(0,o.p)),m=(0,r.y)(this.m_a,this.m_eSquared,new o.P(0,-o.p)),u=this.splitSegmentPassingThroughPole(e);for(let e of u){const u=e.getStartXY(),c=e.getEndXY(),l=(0,r.y)(this.m_a,this.m_eSquared,u),g=(0,r.y)(this.m_a,this.m_eSquared,c),p=new o.P,y=new h.d;let d=h.d.sqrDistance(_,l),P=h.d.sqrDistance(l,g);if(d<=s){if(!(P>a)){n.push(new i.L({start:u,end:c}));continue}y.assign(g.sub(l)),y.normalizeThis(),y.assign(l.add(y.mul(20))),p.assign((0,r.I)(this.m_a,this.m_eSquared,y)),n.push(new i.L({start:u,end:p})),u.assign(p)}if(l.assign((0,r.y)(this.m_a,this.m_eSquared,u)),d=h.d.sqrDistance(_,g),P=h.d.sqrDistance(l,g),d<=s){if(!(P>a)){n.push(new i.L({start:u,end:c}));continue}y.assign(g.sub(l)),y.normalizeThis(),y.assign(g.sub(y.mul(20))),p.assign((0,r.I)(this.m_a,this.m_eSquared,y)),n.push(new i.L({start:p,end:c})),c.assign(p)}if(l.assign((0,r.y)(this.m_a,this.m_eSquared,u)),g.assign((0,r.y)(this.m_a,this.m_eSquared,c)),d=h.d.sqrDistance(m,l),P=h.d.sqrDistance(l,g),d<=s){if(!(P>a)){n.push(new i.L({start:u,end:c}));continue}y.assign(g.sub(l)),y.normalizeThis(),y.assign(l.add(y.mul(20))),p.assign((0,r.I)(this.m_a,this.m_eSquared,y)),n.push(new i.L({start:u,end:p})),u.assign(p)}if(l.assign((0,r.y)(this.m_a,this.m_eSquared,u)),g.assign((0,r.y)(this.m_a,this.m_eSquared,c)),d=h.d.sqrDistance(m,g),P=h.d.sqrDistance(l,g),d<=s){if(!(P>a)){n.push(new i.L({start:u,end:c}));continue}y.assign(g.sub(l)),y.normalizeThis(),y.assign(g.sub(y.mul(20))),p.assign((0,r.I)(this.m_a,this.m_eSquared,y)),n.push(new i.L({start:p,end:c})),c.assign(p)}t.push(new i.L({start:u,end:c}))}}splitSegmentPassingThroughPole(e){const t={stack:[],error:void 0,hasError:!1};try{const n=[],s=new h.d,a=new h.d,_=new h.d,m=new o.P,u=20,l=3.124139361,p=10,y=e.getStartXY(),d=e.getEndXY(),P=(0,c.b)(t,new r.P,!1);if(r.x.geodeticDistance(this.m_a,this.m_eSquared,y.x,y.y,d.x,d.y,P,null,null,2),Math.abs(d.x-y.x)>l&&P.val>u){const e=new g(new o.P(0,90),y.divide(this.m_rpu),d.divide(this.m_rpu),this.m_inputGCS,2,2);let t=(0,r.B)(e.makeFunctor(),0,1,1e-10);if(t.second<=p&&t.first>0&&t.first<1)return s.assign((0,r.y)(this.m_a,this.m_eSquared,y)),a.assign((0,r.y)(this.m_a,this.m_eSquared,d)),(0,o.x)(s,a,t.first,_),m.assign((0,r.I)(this.m_a,this.m_eSquared,_)),n.push(new i.L({start:y,end:m})),n.push(new i.L({start:m,end:d})),n;if(e.setPointDistFrom(new o.P(0,-90)),t=(0,r.B)(e.makeFunctor(),0,1,1e-10),t.second<=p&&t.first>0&&t.first<1)return s.assign((0,r.y)(this.m_a,this.m_eSquared,y)),a.assign((0,r.y)(this.m_a,this.m_eSquared,d)),(0,o.x)(s,a,t.first,_),m.assign((0,r.I)(this.m_a,this.m_eSquared,_)),n.push(new i.L({start:y,end:m})),n.push(new i.L({start:m,end:d})),n}return n.push(new i.L({start:y,end:d})),n}catch(e){t.error=e,t.hasError=!0}finally{(0,c.c)(t)}}adaptiveIntegrationWithRomberg(e,t){const n=e.makeFunctor();let s=0,a=1,r=n(s),o=n(a);const _=1e-17,h=1e-14;let m=(s+a)/2,u=n(m),c=Math.abs(u-r),l=Math.abs(o-u),g=0;for(;g++<32&&(c/l<.1||l/c<.1);)c<l?(t.pe((0,i.v)(5,s,m,h,_,n)),s=m,r=u):(t.pe((0,i.v)(5,m,a,h,_,n)),a=m,o=u),m=(s+a)/2,u=Math.abs(n(m)),c=Math.abs(u-r),l=Math.abs(o-u);t.pe((0,i.v)(5,s,a,h,_,n))}loxodromeAreaHemi(e,t,n,s,i){const a=n.clone(),r=i.clone();let _,h,m,u,c,l,g,p,y,d,P,f,E,S,x,v;return a.make_negative&&a.changeSign(),r.make_negative&&r.changeSign(),P=s-t,1===Math.abs(a.sin_phi)||1===Math.abs(r.sin_phi)?e.half_qp*P:a.sin_phi===r.sin_phi?(d=.5*e.one_m_e_2*a.sin_phi*(1/a.one_m_e_2_sin_2_phi+(0,o.y)(e.e*a.sin_phi))*P,d):(x=Math.log(r.sin_half_phi_pf*a.sin_half_phi_pz/(r.sin_half_phi_pz*a.sin_half_phi_pf)),v=Math.log(r.sin_half_asin_e_sin_phi_pf*a.sin_half_asin_e_sin_phi_pz/(r.sin_half_asin_e_sin_phi_pz*a.sin_half_asin_e_sin_phi_pf)),1===this.m_eSquared?(c=0,_=.5*(x+r.sin_phi/r.one_m_e_2_sin_2_phi-a.sin_phi/a.one_m_e_2_sin_2_phi),h=0):(c=-2*e.atanh_e_over_e*(Math.log(r.one_p_sin_phi/a.one_p_sin_phi)-e.e*v),_=(x-e.e*v)/e.one_m_e_2,h=(Math.log(r.one_m_e_2_sin_2_phi/a.one_m_e_2_sin_2_phi)+c/e.atanh_e_over_e)/e.one_m_e_2),m=-v*(a.atanh_esin_phi+r.atanh_esin_phi),u=1/a.one_m_e_2_sin_2_phi-1/r.one_m_e_2_sin_2_phi,l=(0,o.z)(r.one_m_sin_phi/e.one_p_e,e.e)-(0,o.z)(a.one_m_sin_phi/e.one_p_e,e.e),g=(0,o.z)(r.one_p_sin_phi/e.one_p_e,e.e)-(0,o.z)(a.one_p_sin_phi/e.one_p_e,e.e),p=(0,o.z)(a.one_m_sin_phi/-e.one_m_e,e.e)-(0,o.z)(r.one_m_sin_phi/-e.one_m_e,e.e),y=(0,o.z)(a.one_p_sin_phi/-e.one_m_e,e.e)-(0,o.z)(r.one_p_sin_phi/-e.one_m_e,e.e),d=.25/_*(h+m+u+c+.5*(l+g+p+y)),d+=e.half_qp,f=.5*e.one_m_e_2*a.sin_phi*(1/a.one_m_e_2_sin_2_phi+(0,o.y)(e.e*a.sin_phi)),E=.5*e.one_m_e_2*r.sin_phi*(1/r.one_m_e_2_sin_2_phi+(0,o.y)(e.e*r.sin_phi)),E<f&&(S=f,f=E,E=S),d<f&&(d=f),d>E&&(d=E),d*=P,d)}loxodromeArea(e){const t=Math.PI/180;let n=0;const s={e:Number.NaN,one_p_e:Number.NaN,one_m_e:Number.NaN,one_m_e_2:Number.NaN,atanh_e_over_e:Number.NaN,half_qp:Number.NaN,f:Number.NaN,z:Number.NaN},i=N(),a=N();s.e=Math.sqrt(this.m_eSquared),s.one_p_e=1+s.e,s.one_m_e=1-s.e,s.one_m_e_2=1-this.m_eSquared,s.atanh_e_over_e=(0,o.y)(s.e),this.m_eSquared>=1?s.half_qp=1:s.half_qp=.5*(1+s.atanh_e_over_e*s.one_m_e_2),s.f=.25*Math.PI,s.z=.75*Math.PI,a.initialize(0,s.e,s.f,s.z);const r=e.getPathCount(),_=new o.P,h=new o.P,m=e.getImpl().getAttributeStreamRef(0);for(let o=0;o<r;o++){const r=e.getPathStart(o),u=e.getPathEnd(o);if(!(u-r<=1)){m.queryPoint2D(2*(u-1),_);for(let e=r;e<u;e++){m.queryPoint2D(2*e,h);const o=_.y*t,u=h.y*t;if(e===r?(i.initialize(o,s.e,s.f,s.z),i.make_negative=!1):i.assign(a),a.initialize(u,s.e,s.f,s.z),a.make_negative=!1,_.y*h.y<0){if(_.y>=90&&h.y<=-90||h.y>=90&&_.y<=-90)return Number.NaN;const e=N();e.initialize(0,s.e,s.f,s.z),e.make_negative=!1;const r=i.atanh_sin_phi-s.e*i.atanh_esin_phi,m=a.atanh_sin_phi-s.e*a.atanh_esin_phi,u=(m*_.x-r*h.x)/(m-r);o<0?(i.make_negative=!0,n-=this.loxodromeAreaHemi(s,_.x*t,i,u*t,e),i.make_negative=!1,n+=this.loxodromeAreaHemi(s,u*t,e,h.x*t,a)):(n+=this.loxodromeAreaHemi(s,_.x*t,i,u*t,e),a.make_negative=!0,n-=this.loxodromeAreaHemi(s,u*t,e,h.x*t,a),a.make_negative=!1)}else _.y>=0?n+=this.loxodromeAreaHemi(s,_.x*t,i,h.x*t,a):(i.make_negative=!0,a.make_negative=!0,n-=this.loxodromeAreaHemi(s,_.x*t,i,h.x*t,a),i.make_negative=!1,a.make_negative=!1);_.assign(h)}}}return this.m_a*n*this.m_a}calculate(e){if(e.isEmpty()||e.getDimension()<2)return 0;if(e.getGeometryType()===s.G.enumEnvelope){const t=new i.a;return t.addEnvelope(e,!1),this.calculate(t)}return this.m_inputSR!==this.m_inputGCS&&null===this.m_transformPCS2GCS&&(this.m_transformPCS2GCS=(0,r.w)(this.m_inputSR,this.m_inputGCS,null)),this.executePolygonGeodeticArea(e)}}class q{getOperatorType(){return 10311}supportsCurves(){return!0}accelerateGeometry(e,t,n){return!1}canAccelerateGeometry(e){return!1}execute(e,t,n,i){return(0,s.d)(e),4===n?(new f).execute(e,t,i):new T(t,n,i).calculate(e)}}},76061:(e,t,n)=>{n.d(t,{G:()=>s,S:()=>i});class s{*[Symbol.iterator](){let e=this.next();for(;e;)yield e,e=this.next()}}class i extends s{constructor(e){super(),this.m_iGeom=-1,this.m_aGeoms=e?e.slice():[]}next(){if(this.m_iGeom<this.m_aGeoms.length-1){const e=this.m_aGeoms[++this.m_iGeom];return this.m_aGeoms[this.m_iGeom]=null,e}return null}tock(){return!1}getGeometryID(){return this.m_iGeom}getRank(){return 1}}},90135:(e,t,n)=>{n.d(t,{D:()=>E,m:()=>m,s:()=>d,w:()=>y});var s=n(90237),i=n(55537),a=n(35368),r=n(12189),o=n(83661),_=n(79187),h=n(95213);function m(){return{outPoint:new o.P,index:-1,t:Number.NaN}}function u(e,t,n){return{outPoint:e.clone(),index:t,t:n}}function c(e,t,n,s){e.outPoint.assign(t),e.index=n,e.t=s}function l(e,t){e.outPoint.assign(t.outPoint),e.index=t.index,e.t=t.t}function g(e,t,n,s){e.index=n,e.t=s,t.queryCoord2D(e.t,e.outPoint)}function p(e,t){const n=m();l(n,e),l(e,t),l(t,n)}function y(e,t,n,s,a,o){if(e.getGeometryType()===i.G.enumPolygon){for(;s.nextPath();)if(s.hasNextSegment()){const t=s.nextSegment();if(0!==(0,r.h)(e,t.getEndXY(),0))return c(a,t.getEndXY(),-1,Number.NaN),c(o,t.getEndXY(),-1,Number.NaN),!0}s.resetToFirstPath()}if(t.getGeometryType()===i.G.enumPolygon){for(;n.nextPath();)if(n.hasNextSegment()){const e=n.nextSegment();if(0!==(0,r.h)(t,e.getEndXY(),0))return c(a,e.getEndXY(),-1,Number.NaN),c(o,e.getEndXY(),-1,Number.NaN),!0}n.resetToFirstPath()}return!1}function d(e){const t=e.getPathCount(),n=(0,o.d)(e.getSegmentCount(),0);let s=0;for(let i=0;i<t;++i){const t=s+e.getSegmentCountPath(i);for(let a=s,r=e.getPathStart(i);a<t;++a,++r)n[a]=r;s=t}return(0,a.s)(e.getPointCount(),n),n}function P(e,t){return!!Number.isNaN(t)||e<=t}function f(e){const t=new a.a;return t.addEnvelope(e,!1),t}class E{constructor(e,t){if(this.m_env2DgeometryA=null,this.m_env2DgeometryB=null,this.m_progressCounter=0,this.m_progressTracker=t,this.m_maxSqrDistance=e*e,this.m_maxDistance=e,this.m_bIsNearCalc=!1,Number.isNaN(this.m_maxDistance)?this.m_maxDistance=Number.POSITIVE_INFINITY:this.m_maxDistance=e,this.m_maxSqrDistance=this.m_maxDistance*this.m_maxDistance,Number.isFinite(this.m_maxSqrDistance)){let e=Math.sqrt(this.m_maxSqrDistance);for(;e<this.m_maxDistance;)this.m_maxSqrDistance*=1+Number.EPSILON,e=Math.sqrt(this.m_maxSqrDistance)}}calculate(e,t,n,s){if((e.getGeometryType()!==h.P.type||t.getGeometryType()!==h.P.type)&&(this.m_env2DgeometryA=new _.Envelope2D,this.m_env2DgeometryB=new _.Envelope2D,e.queryEnvelope(this.m_env2DgeometryA),t.queryEnvelope(this.m_env2DgeometryB),!P(this.m_env2DgeometryA.distanceFromEnvelope(this.m_env2DgeometryB),this.m_maxDistance)))return Number.POSITIVE_INFINITY;const i=u(new o.P,(0,o.j)(),Number.NaN),a=u(new o.P,(0,o.j)(),Number.NaN),r=this._ExecuteBruteForce(e,t,i,a);return P(r,this.m_maxDistance)?(null!==n&&l(n,i),null!==s&&l(s,a),r):Number.POSITIVE_INFINITY}isNear(e,t){if(this.m_bIsNearCalc=!0,e.isEmpty()||t.isEmpty())return!1;if(e===t)return!0;let n=!0;if(e.getGeometryType()!==h.P.type&&e.getGeometryType()!==h.E.type||t.getGeometryType()!==h.P.type&&t.getGeometryType()!==h.E.type||(n=!1),n){if(this.m_env2DgeometryA=new _.Envelope2D,this.m_env2DgeometryB=new _.Envelope2D,e.queryEnvelope(this.m_env2DgeometryA),t.queryEnvelope(this.m_env2DgeometryB),!(this.m_env2DgeometryA.sqrMaxMinDistanceEnvelope(this.m_env2DgeometryB)>this.m_maxSqrDistance))return!0;if(this.m_env2DgeometryA.sqrDistanceEnvelope(this.m_env2DgeometryB,null,null)>this.m_maxSqrDistance)return!1}const s=u(new o.P,(0,o.j)(),Number.NaN),i=u(new o.P,(0,o.j)(),Number.NaN);return this._ExecuteBruteForce(e,t,s,i)<=this.m_maxDistance}progress_(e=!1){}_ExecuteBruteForce(e,t,n,s){switch(e.getGeometryType()){case i.G.enumPoint:return this.distancePointGeometry(e,t,n,s);case i.G.enumMultiPoint:return this.distanceMultipointGeometry(e,t,n,s);case i.G.enumEnvelope:return this.distanceEnvelopeGeometry(e,t,n,s);case i.G.enumPolyline:case i.G.enumPolygon:return this.distanceMultipathGeometry(e,t,n,s);default:return Number.NaN}}distancePointGeometry(e,t,n,s){switch(t.getGeometryType()){case i.G.enumPoint:return this.distancePointPoint(e,t,n,s);case i.G.enumMultiPoint:return this.distancePointMultipoint(e,t,n,s);case i.G.enumPolyline:case i.G.enumPolygon:return this.distancePointMultipath(e,t,n,s);case i.G.enumEnvelope:return this.distancePointEnvelope(e,t,n,s);default:return Number.NaN}}distancePointPoint(e,t,n,s){const i=e.getXY(),a=t.getXY();return c(n,i,0,0),c(s,a,0,0),Math.sqrt(o.P.sqrDistance(i,a))}distancePointMultipoint(e,t,n,s){const i=e.getXY();let a=this.m_maxSqrDistance,r=a,_=!1;const h=t.getPointCount(),m=new o.P;for(let e=0;e<h;++e)if(t.queryXY(e,m),r=o.P.sqrDistance(i,m),this.m_bIsNearCalc){if(r<=a)return 0}else if(!(r>a)&&(!_&&r===a||r<a)&&(a=r,c(n,i,0,0),c(s,m,e,0),_=!0,0===a))return 0;return _?Math.sqrt(a):Number.POSITIVE_INFINITY}distancePointMultipath(e,t,n,s){const a=!this.m_env2DgeometryA.isIntersecting(this.m_env2DgeometryB),h=e.getXY();if(!a&&t.getGeometryType()===i.G.enumPolygon&&0!==(0,r.h)(t,h,0))return c(n,h,0,0),c(s,h,-1,Number.NaN),0;t.getImpl().getAccelerators();let m=this.m_maxSqrDistance,u=m,l=-1;const g=new _.Envelope2D,p=t.querySegmentIterator();let y=!1;for(;p.nextPath();)for(;p.hasNextSegment();){const e=p.nextSegment();e.queryEnvelope(g);const t=g.sqrDistance(h);if(t>m)continue;if(!this.m_bIsNearCalc&&y&&t===m)continue;l=e.getClosestCoordinate(h,!1);const i=e.getCoord2D(l);if(u=o.P.sqrDistance(h,i),this.m_bIsNearCalc){if(u<=m)return 0}else if(!(u>m)&&(!y||u<m)&&(m=u,c(n,h,0,0),c(s,i,p.getStartPointIndex(),l),y=!0,0===m))return 0}return y?Math.sqrt(m):Number.POSITIVE_INFINITY}distancePointEnvelope(e,t,n,s){const i=e.getXY();c(n,i,0,0),c(s,i,-1,Number.NaN);const a=t.asEnvelope2D();return a.contains(i)?0:Math.sqrt(a.sqrDistance(i,s.outPoint))}distanceMultipointGeometry(e,t,n,s){switch(t.getGeometryType()){case i.G.enumPoint:{this.m_env2DgeometryB=(0,o.c)(this.m_env2DgeometryA,this.m_env2DgeometryA=this.m_env2DgeometryB);const i=this.distancePointMultipoint(t,e,s,n);return this.m_env2DgeometryB=(0,o.c)(this.m_env2DgeometryA,this.m_env2DgeometryA=this.m_env2DgeometryB),i}case i.G.enumMultiPoint:return this.distanceMultipointMultipoint(e,t,n,s,1,1);case i.G.enumPolyline:case i.G.enumPolygon:return this.distanceMultipointMultipath(e,t,n,s);case i.G.enumEnvelope:return this.distanceMultipointMultipath(e,f(t),n,s);default:return Number.NaN}}distanceMultipointMultipoint(e,t,n,i,a,r){const _={stack:[],error:void 0,hasError:!1};try{if(this.m_bIsNearCalc&&1===a&&1===r){const s=Math.trunc((0,o.s)(Math.sqrt(e.getPointCount())+1,1,(0,o.i)())),a=Math.trunc((0,o.s)(Math.sqrt(t.getPointCount())+1,1,(0,o.i)()));if((s>=4||a>=4)&&this.distanceMultipointMultipoint(e,t,n,i,s,a)<=this.m_maxSqrDistance)return 0}let h=this.m_maxSqrDistance;const m=[e],u=[t],l=this.swapGeometriesIfBGtA(m,u);l&&(this.m_env2DgeometryB=(0,o.c)(this.m_env2DgeometryA,this.m_env2DgeometryA=this.m_env2DgeometryB),r=(0,o.c)(a,a=r),p(n,i)),(0,s.b)(_,(0,o.h)((()=>{p(n,i),this.m_env2DgeometryB=(0,o.c)(this.m_env2DgeometryA,this.m_env2DgeometryA=this.m_env2DgeometryB)}),!l),!1);const g=m[0].getImpl(),y=u[0].getImpl(),d=g.getPointCount(),P=y.getPointCount(),f=P>1;let E=!1;const S=new o.P,x=new o.P;for(let e=0;e<d;e+=a){if(g.queryXY(e,S),f){const e=this.m_env2DgeometryB.sqrDistance(S);if(this.m_bIsNearCalc){if(e>h)continue;if(this.m_env2DgeometryB.sqrMaxMinDistance(S)<=h)return 0}else if(e>=h)continue}for(let t=0;t<P;t+=r){y.queryXY(t,x);const s=o.P.sqrDistance(S,x);if(this.m_bIsNearCalc){if(s<=h)return 0}else if(!(s>h||E&&s===h)&&(!E||s<h)&&(c(n,S,e,0),c(i,x,t,0),E=!0,h=s,0===h))return E?Math.sqrt(h):Number.POSITIVE_INFINITY}}return E?Math.sqrt(h):Number.POSITIVE_INFINITY}catch(e){_.error=e,_.hasError=!0}finally{(0,s.c)(_)}}distanceMultipointMultipath(e,t,n,s){let a=!!this.m_env2DgeometryA.isIntersecting(this.m_env2DgeometryB)&&t.getGeometryType()===i.G.enumPolygon;const h=t.querySegmentIterator();h.stripAttributes();const m=new _.Envelope2D,u=new o.P;let l=this.m_maxSqrDistance;const g=e.getImpl(),p=g.getPointCount(),y=p>1;let d=!1;for(;h.nextPath();)for(;h.hasNextSegment();){const e=h.nextSegment();if(e.queryLooseEnvelope(m),y){const e=m.sqrDistanceEnvelope(this.m_env2DgeometryA,null,null);if(this.m_bIsNearCalc){if(e>l)continue}else if(e>l||d&&e===l)continue}for(let i=0;i<p;i++){if(g.queryXY(i,u),a&&0!==(0,r.h)(t,u,0))return c(n,u,-1,Number.NaN),c(s,u,i,0),0;{const e=m.sqrDistance(u);if(this.m_bIsNearCalc){if(e>l)continue}else if(e>l)continue}const o=e.getClosestCoordinate(u,!1),_=e.getCoord2D(o);u.subThis(_);const p=u.sqrLength();if(this.m_bIsNearCalc){if(p<=l)return 0}else if(!(p>l)&&(!d||p<l)&&(l=p,c(n,g.getXY(i),i,0),c(s,_,h.getStartPointIndex(),o),d=!0,0===l))return 0}a=!1}return d?Math.sqrt(l):Number.POSITIVE_INFINITY}distanceEnvelopeGeometry(e,t,n,s){switch(t.getGeometryType()){case i.G.enumPoint:return this.distancePointEnvelope(t,e,s,n);case i.G.enumMultiPoint:{this.m_env2DgeometryB=(0,o.c)(this.m_env2DgeometryA,this.m_env2DgeometryA=this.m_env2DgeometryB);const i=this.distanceMultipointMultipath(t,f(e),s,n);return this.m_env2DgeometryB=(0,o.c)(this.m_env2DgeometryA,this.m_env2DgeometryA=this.m_env2DgeometryB),i}case i.G.enumPolyline:case i.G.enumPolygon:return this.distanceMultipathMultipath(f(e),t,n,s);case i.G.enumEnvelope:return this.distanceEnvelopeEnvelope(e,t,n,s);default:return Number.NaN}}distanceEnvelopeEnvelope(e,t,n,s){n.t=Number.NaN,n.index=-1,s.t=Number.NaN,s.index=-1;const i=e.asEnvelope2D(),a=t.asEnvelope2D();return Math.sqrt(i.sqrDistanceEnvelope(a,n.outPoint,s.outPoint))}distanceMultipathGeometry(e,t,n,s){switch(t.getGeometryType()){case i.G.enumPoint:{this.m_env2DgeometryB=(0,o.c)(this.m_env2DgeometryA,this.m_env2DgeometryA=this.m_env2DgeometryB);const i=this.distancePointMultipath(t,e,s,n);return this.m_env2DgeometryB=(0,o.c)(this.m_env2DgeometryA,this.m_env2DgeometryA=this.m_env2DgeometryB),i}case i.G.enumMultiPoint:{this.m_env2DgeometryB=(0,o.c)(this.m_env2DgeometryA,this.m_env2DgeometryA=this.m_env2DgeometryB);const i=this.distanceMultipointMultipath(t,e,s,n);return this.m_env2DgeometryB=(0,o.c)(this.m_env2DgeometryA,this.m_env2DgeometryA=this.m_env2DgeometryB),i}case i.G.enumPolyline:case i.G.enumPolygon:return this.distanceMultipathMultipath(e,t,n,s);case i.G.enumEnvelope:return this.distanceMultipathMultipath(e,f(t),n,s);default:return Number.NaN}}distanceMultipathMultipath(e,t,n,i){const r={stack:[],error:void 0,hasError:!1};try{const h=[e],u=[t],c=this.swapGeometriesIfAGtB(h,u);c&&(this.m_env2DgeometryB=(0,o.c)(this.m_env2DgeometryA,this.m_env2DgeometryA=this.m_env2DgeometryB),p(n,i)),(0,s.b)(r,(0,o.h)((()=>{p(n,i),this.m_env2DgeometryB=(0,o.c)(this.m_env2DgeometryA,this.m_env2DgeometryA=this.m_env2DgeometryB)}),!c),!1);const P=h[0],f=u[0],E=P.querySegmentIterator();E.stripAttributes();const S=f.querySegmentIterator();if(S.stripAttributes(),this.m_bIsNearCalc&&this.m_env2DgeometryA.sqrMaxMinDistanceEnvelope(this.m_env2DgeometryB)<=this.m_maxSqrDistance)return 0;if(this.m_bIsNearCalc){const e=Math.trunc((0,o.s)(Math.sqrt(P.getPointCount())+1,1,(0,o.i)())),t=Math.trunc((0,o.s)(Math.sqrt(P.getPointCount())+1,1,(0,o.i)()));if(this.distanceMultipointMultipoint(P,f,n,i,e,t)<=this.m_maxSqrDistance)return 0}if(this.m_env2DgeometryA.isIntersecting(this.m_env2DgeometryB)){const e=m(),t=m();if(y(P,f,E,S,e,t))return l(n,e),l(i,t),0}const x=d(P),v=[],N=new a.S,D=new _.Envelope2D,A=new _.Envelope2D,M=new _.Envelope2D;let C=this.m_maxSqrDistance,T=!0,q=!1;for(let e=0,t=x.length;e<t;++e){P.querySegment(x[e],N,!0);const t=N.get();if(t.queryEnvelope(D),!(D.sqrDistanceEnvelope(this.m_env2DgeometryB,null,null)>C)){if(this.m_bIsNearCalc&&D.sqrMaxDistanceEnvelope(this.m_env2DgeometryB)<=C)return 0;for(;S.nextPath();){if(this.progress_(),T)f.queryPathEnvelope(S.getPathIndex(),M),v[S.getPathIndex()]=M.clone();else if(D.sqrDistanceEnvelope(v[S.getPathIndex()],null,null)>C)continue;for(;S.hasNextSegment();){const s=S.nextSegment();if(s.queryEnvelope(A),D.sqrDistanceEnvelope(A,null,null)<=C){const a=!D.isIntersecting(A),r=[0],o=[0];let _=t.distance(s,a,r,o);if(_*=_,this.m_bIsNearCalc&&_<=this.m_maxSqrDistance)return 0;if(_<C||_===C&&x[e]<n.index){if(q=!0,g(n,t,x[e],r[0]),g(i,s,S.getStartPointIndex(),o[0]),0===_)return 0;C=_}}}}S.resetToFirstPath(),T=!1}}return q?Math.sqrt(C):Number.POSITIVE_INFINITY}catch(e){r.error=e,r.hasError=!0}finally{(0,s.c)(r)}}swapGeometriesIfAGtB(e,t){return(0,i.v)(e[0])>(0,i.v)(t[0])&&(t[0]=(0,o.c)(e[0],e[0]=t[0]),!0)}swapGeometriesIfBGtA(e,t){return this.swapGeometriesIfAGtB(t,e)}}}}]);
|