UNPKG

@arcgis/core

Version:

ArcGIS Maps SDK for JavaScript: A complete 2D and 3D mapping and data visualization API

3 lines (2 loc) 889 B
/* COPYRIGHT Esri - https://js.arcgis.com/5.0.19/LICENSE.txt */ import{removeUnordered as s}from"../../../../core/arrayUtils.js";class e{constructor(){this.adds=new Array,this.removes=new Array,this.updates=new Array}clear(){this.adds.length=0,this.removes.length=0,this.updates.length=0}prune(){this.clear()}get empty(){return 0===this.adds.length&&0===this.removes.length&&0===this.updates.length}}class t{}class r{constructor(s){this.pending=s,this.adds=new Array,this.removes=new Array,this.updates=new Array}clearAddsAndRemoves(){this.adds.forEach(e=>s(this.pending.adds,e)),this.removes.forEach(e=>s(this.pending.removes,e)),this.adds.length=0,this.removes.length=0}clearUpdates(){this.updates.forEach(e=>s(this.pending.updates,e)),this.updates.length=0}clear(){this.clearUpdates(),this.clearAddsAndRemoves()}}export{e as ChangeSet,r as MaterialChangeSet,t as RenderGeometryUpdate};