// All material copyright Esri, All Rights Reserved, unless otherwise specified. // See https://js.arcgis.com/4.30/esri/copyright.txt for details. //>>built define(["exports","../../core/typedArrayUtil"],function(e,c){function p(a){let b=!0;for(const d of a){if(65536<=d)return c.isArray(a)?new Uint32Array(a):a;256<=d&&(b=!1)}return b?new Uint8Array(a):new Uint16Array(a)}function k(a){if(1===a)return l;if(af.length){f=new Uint32Array(Math.max(2*f.length,a));for(let b=0;bg.length&&(g=new Uint8Array(Math.max(2*g.length,a)));return new Uint8Array(g.buffer,0,a)}let f=(()=>{const a=new Uint32Array(131072);for(let b=0;b{const a=new Uint16Array(65536);for(let b=0;b{b=b&&0===n;d=d&&n===q;return!b&&!d});return b?m(a.length):d?k(a.length):c.isArray(a)||a.BYTES_PER_ELEMENT!==Uint16Array.BYTES_PER_ELEMENT?p(a):a};e.getContinuousIndexArray=k;e.getZeroIndexArray=m;e.newIndexArray=function(a){return a<=c.nativeArrayMaxSize?Array(a):65536>=a?new Uint16Array(a):new Uint32Array(a)};e.newIntArray=function(a){return a<=c.nativeArrayMaxSize?Array(a):new Uint32Array(a)};Object.defineProperty(e,Symbol.toStringTag,{value:"Module"})});