define(["require","exports","tslib","../../Validation","./MapProvider","../../Hooks","./tools","./ArcGisApiVersion"],function(e,i,r,a,t,o,s,c){"use strict";Object.defineProperty(i,"__esModule",{value:!0});n.prototype.execute=function(e,i,r){var t=a.validation.id("layerId",e.layerId,void 0),o=r.create(),n=s.featuresToArray(a.validation.exists("features",e.features));return s.inline(o.load(),function(){if(t){var e=o.findLayer(t);return s.inline(e&&e.load(),function(){return e.removeFeatures(n),{}})}if(c.isArcGisApiVersion3x)for(var i=0,r=n;i<r.length;i++){var a=r[i];o.map.graphics.remove(a)}else o.view.graphics.removeMany(n)})},n.action="gcx:wf:arcgis::RemoveGraphics",n.suite="gcx:wf:builtin",t=r.__decorate([o.activate(t.MapProvider)],n);function n(){}i.RemoveGraphics=t});