!function(e){"object"==typeof module&&"object"==typeof module.exports?e(require,exports):"function"==typeof define&&define.amd&&define(["require","exports","../../Validation","./ArcGisApiVersion","./tools"],e)}(function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var a=e("../../Validation"),s=e("./ArcGisApiVersion"),u=e("./tools"),e=(i.prototype.execute=function(e,t){var i=a.validation.urlOrLayer(e,s.isArcGisApiVersion3x),i=u.addToPath(i,"applyEdits"),o=(a.validation.array("features",e.features,a.validation.never),a.validation.string("gdbVersion",e.gdbVersion)),n=a.validation.number("timeout",e.timeout),e=a.validation.array("features",e.features,a.validation.never),n=u.post(i,{updates:e,gdbVersion:o},n,t.cancellationToken.signal);u.schedulePromiseCancellation(t,n);var r=this;return u.inline(n,function(e){r.onApplyEditsComplete(e);var t=e.updateResults&&e.updateResults.every(function(e){return e.success});return{results:e.updateResults,success:t}})},i.prototype.onApplyEditsComplete=function(e){},i.action="gcx:wf:arcgis::UpdateFeatures",i.suite="gcx:wf:builtin",i);function i(){}t.UpdateFeatures=e});