/* COPYRIGHT Esri - https://js.arcgis.com/5.1.2/LICENSE.txt */
import{convertUnit as e}from"../core/units.js";import{execute as t,executeMany as o,load as r,supportsCurves as s,isLoaded as a}from"../geometry/operators/gx/operatorGeodeticDensify.js";import{geodeticCurveType as n}from"../geometry/operators/support/geodeticCurveType.js";let i,p,u,c,m;function f(){return!!i&&a()}async function y(){if(!f()){const[e]=await Promise.all([import("../geometry/operators/support/apiConverter.js"),r()]);i=e.fromGeometry,p=e.fromSpatialReference,u=e.getSpatialReference,c=e.toGeometry,m=s()}}function l(o,r,s={}){const{curveType:a="geodesic",unit:m}=s;m&&(r=e(r,m,"meters"));const f=u(o);return c(t(i(o),r,p(f),n[a]),f)}function d(t,r,s={}){const{curveType:a="geodesic",unit:m}=s;m&&(r=e(r,m,"meters"));const f=t.map(i),y=u(t);return o(f,r,p(y),n[a]).map(e=>c(e,y))}const g=Object.freeze(Object.defineProperty({__proto__:null,execute:l,executeMany:d,isLoaded:f,load:y,get supportsCurves(){return m}},Symbol.toStringTag,{value:"Module"}));export{d as a,l as e,g,f as i,y as l,m as s};
