import{validation}from"../../Validation.js";import{inline}from"./tools.js";import{geodesicArea,planarArea}from"@arcgis/core/geometry/geometryEngineAsync";class AreaEngineTask{executeUsing(e,i,a){return(e?geodesicArea:planarArea)(i,a)}execute(e){var i=validation.exists("geometry",e.geometry),a=validation.boolean("geodesic",e.geodesic,!1),e=this.executeUsing(a,i,e.unit);return inline(e,function(e){return{area:e}})}}AreaEngineTask.action="gcx:wf:arcgis::AreaEngineTask",AreaEngineTask.suite="gcx:wf:builtin";export{AreaEngineTask};