/*
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
See https://js.arcgis.com/4.24/esri/copyright.txt for details.
*/
define(["../../../../chunks/_rollupPluginBabelHelpers","./GraphicDisplayList","./WGLDisplayObject","./util/serializationUtils"],(function(i,t,s,e){"use strict";return function(){function n(){}var l=n.prototype;return l.computeDisplayList=function(){this._displayList=new t;for(const i of this.displayObjects)for(const t of i.displayRecords)this._displayList.addToList(t)},l.clone=function(){const i=new n;return this.displayObjects&&(i.displayObjects=this.displayObjects.map((i=>i.clone()))),i},l.serialize=function(i){return e.serializeList(i,this.displayObjects),i},l._deserializeObjects=function(i){const t=i.readInt32(),e=new Array(t),n=new Map;for(let l=0;l<e.length;++l){const t=s.deserialize(i);e[l]=t,n.set(t.id,t)}this.displayObjects=e,this._displayList=null,this._displayObjectRegistry=n},n.deserialize=function(i){const t=new n;return t._deserializeObjects(i),t},i._createClass(n,[{key:"displayObjectRegistry",get:function(){if(!this._displayObjectRegistry){this._displayObjectRegistry=new Map;for(const i of this.displayObjects)this._displayObjectRegistry.set(i.id,i)}return this._displayObjectRegistry}},{key:"displayList",get:function(){return this._displayList}}]),n}()}));
