{"version":3,"sources":["node_modules/@arcgis/core/core/pbf.js"],"sourcesContent":["/*\nAll material copyright ESRI, All Rights Reserved, unless otherwise specified.\nSee https://js.arcgis.com/4.31/esri/copyright.txt for details.\n*/\nimport has from \"./has.js\";\nimport t from \"./ObjectPool.js\";\nvar e;\n!function (t) {\n t[t.varint = 0] = \"varint\", t[t.fixed64 = 1] = \"fixed64\", t[t.delimited = 2] = \"delimited\", t[t.fixed32 = 5] = \"fixed32\", t[t.unknown = 99] = \"unknown\";\n}(e || (e = {}));\nconst i = 4294967296,\n s = new TextDecoder(\"utf-8\"),\n r = has(\"safari\") || has(\"ios\") ? 6 : has(\"ff\") ? 12 : 32;\nclass n {\n constructor(t, i, s = 0, r = t ? t.byteLength : 0) {\n this._tag = 0, this._dataType = e.unknown, this._init(t, i, s, r);\n }\n _init(t, e, i, s) {\n this._data = t, this._dataView = e, this._pos = i, this._end = s;\n }\n asUnsafe() {\n return this;\n }\n clone() {\n return new n(this._data, this._dataView, this._pos, this._end);\n }\n pos() {\n return this._pos;\n }\n move(t) {\n this._pos = t;\n }\n nextTag(t) {\n for (;;) {\n if (this._pos === this._end) return !1;\n const e = this._decodeVarint();\n if (this._tag = e >> 3, this._dataType = 7 & e, !t || t === this._tag) break;\n this.skip();\n }\n return !0;\n }\n next() {\n if (this._pos === this._end) return !1;\n const t = this._decodeVarint();\n return this._tag = t >> 3, this._dataType = 7 & t, !0;\n }\n empty() {\n return this._pos >= this._end;\n }\n tag() {\n return this._tag;\n }\n getInt32() {\n return this._decodeVarint();\n }\n getInt64() {\n return this._decodeVarint();\n }\n getUInt32() {\n let t = 4294967295;\n if (t = (127 & this._data[this._pos]) >>> 0, this._data[this._pos++] < 128) return t;\n if (t = (t | (127 & this._data[this._pos]) << 7) >>> 0, this._data[this._pos++] < 128) return t;\n if (t = (t | (127 & this._data[this._pos]) << 14) >>> 0, this._data[this._pos++] < 128) return t;\n if (t = (t | (127 & this._data[this._pos]) << 21) >>> 0, this._data[this._pos++] < 128) return t;\n if (t = (t | (15 & this._data[this._pos]) << 28) >>> 0, this._data[this._pos++] < 128) return t;\n throw new Error(\"Varint overflow\");\n }\n getUInt64() {\n return this._decodeVarint();\n }\n getSInt32() {\n const t = this.getUInt32();\n return t >>> 1 ^ -(1 & t);\n }\n getSInt64() {\n return this._decodeSVarint();\n }\n getBool() {\n const t = 0 !== this._data[this._pos];\n return this._skip(1), t;\n }\n getEnum() {\n return this._decodeVarint();\n }\n getFixed64() {\n const t = this._dataView,\n e = this._pos,\n s = t.getUint32(e, !0) + t.getUint32(e + 4, !0) * i;\n return this._skip(8), s;\n }\n getSFixed64() {\n const t = this._dataView,\n e = this._pos,\n s = t.getUint32(e, !0) + t.getInt32(e + 4, !0) * i;\n return this._skip(8), s;\n }\n getDouble() {\n const t = this._dataView.getFloat64(this._pos, !0);\n return this._skip(8), t;\n }\n getFixed32() {\n const t = this._dataView.getUint32(this._pos, !0);\n return this._skip(4), t;\n }\n getSFixed32() {\n const t = this._dataView.getInt32(this._pos, !0);\n return this._skip(4), t;\n }\n getFloat() {\n const t = this._dataView.getFloat32(this._pos, !0);\n return this._skip(4), t;\n }\n getString() {\n const t = this._getLength(),\n e = this._pos,\n i = this._toString(this._data, e, e + t);\n return this._skip(t), i;\n }\n getBytes() {\n const t = this._getLength(),\n e = this._pos,\n i = this._toBytes(this._data, e, e + t);\n return this._skip(t), i;\n }\n getLength() {\n return this._getLengthUnsafe();\n }\n processMessageWithArgs(t, e, i, s) {\n const r = this.getMessage(),\n n = t(r, e, i, s);\n return r.release(), n;\n }\n processMessage(t) {\n const e = this.getMessage(),\n i = t(e);\n return e.release(), i;\n }\n getMessage() {\n const t = this._getLength(),\n e = n.pool.acquire();\n return e._init(this._data, this._dataView, this._pos, this._pos + t), this._skip(t), e;\n }\n release() {\n n.pool.release(this);\n }\n dataType() {\n return this._dataType;\n }\n skip() {\n switch (this._dataType) {\n case e.varint:\n this._decodeVarint();\n break;\n case e.fixed64:\n this._skip(8);\n break;\n case e.delimited:\n this._skip(this._getLength());\n break;\n case e.fixed32:\n this._skip(4);\n break;\n default:\n throw new Error(\"Invalid data type!\");\n }\n }\n skipLen(t) {\n this._skip(t);\n }\n _skip(t) {\n if (this._pos + t > this._end) throw new Error(\"Attempt to skip past the end of buffer!\");\n this._pos += t;\n }\n _decodeVarint() {\n const t = this._data;\n let e = this._pos,\n i = 0,\n s = 0;\n if (this._end - e >= 10) do {\n if (s = t[e++], i |= 127 & s, !(128 & s)) break;\n if (s = t[e++], i |= (127 & s) << 7, !(128 & s)) break;\n if (s = t[e++], i |= (127 & s) << 14, !(128 & s)) break;\n if (s = t[e++], i |= (127 & s) << 21, !(128 & s)) break;\n if (s = t[e++], i += 268435456 * (127 & s), !(128 & s)) break;\n if (s = t[e++], i += 34359738368 * (127 & s), !(128 & s)) break;\n if (s = t[e++], i += 4398046511104 * (127 & s), !(128 & s)) break;\n if (s = t[e++], i += 562949953421312 * (127 & s), !(128 & s)) break;\n if (s = t[e++], i += 72057594037927940 * (127 & s), !(128 & s)) break;\n if (s = t[e++], i += 0x8000000000000000 * (127 & s), !(128 & s)) break;\n throw new Error(\"Varint too long!\");\n } while (0);else {\n let r = 1;\n for (; e !== this._end && (s = t[e], 128 & s);) ++e, i += (127 & s) * r, r *= 128;\n if (e === this._end) throw new Error(\"Varint overrun!\");\n ++e, i += s * r;\n }\n return this._pos = e, i;\n }\n _decodeSVarint() {\n const t = this._data;\n let e,\n i = 0,\n s = 0;\n const r = 1 & t[this._pos];\n if (s = t[this._pos++], i |= 127 & s, !(128 & s)) return r ? -(i + 1) / 2 : i / 2;\n if (s = t[this._pos++], i |= (127 & s) << 7, !(128 & s)) return r ? -(i + 1) / 2 : i / 2;\n if (s = t[this._pos++], i |= (127 & s) << 14, !(128 & s)) return r ? -(i + 1) / 2 : i / 2;\n if (s = t[this._pos++], i |= (127 & s) << 21, !(128 & s)) return r ? -(i + 1) / 2 : i / 2;\n if (s = t[this._pos++], i += 268435456 * (127 & s), !(128 & s)) return r ? -(i + 1) / 2 : i / 2;\n if (s = t[this._pos++], i += 34359738368 * (127 & s), !(128 & s)) return r ? -(i + 1) / 2 : i / 2;\n if (s = t[this._pos++], i += 4398046511104 * (127 & s), !(128 & s)) return r ? -(i + 1) / 2 : i / 2;\n if (e = BigInt(i), s = t[this._pos++], e += 0x2000000000000n * BigInt(127 & s), !(128 & s)) return Number(r ? -(e + 1n) / 2n : e / 2n);\n if (s = t[this._pos++], e += 0x100000000000000n * BigInt(127 & s), !(128 & s)) return Number(r ? -(e + 1n) / 2n : e / 2n);\n if (s = t[this._pos++], e += 0x8000000000000000n * BigInt(127 & s), !(128 & s)) return Number(r ? -(e + 1n) / 2n : e / 2n);\n throw new Error(\"Varint too long!\");\n }\n _getLength() {\n if (this._dataType !== e.delimited) throw new Error(\"Not a delimited data type!\");\n return this._decodeVarint();\n }\n _getLengthUnsafe() {\n return this.getUInt32();\n }\n _toString(t, e, i) {\n if ((i = Math.min(this._end, i)) - e > r) {\n const r = t.subarray(e, i);\n return s.decode(r);\n }\n let n = \"\",\n h = \"\";\n for (let s = e; s < i; ++s) {\n const e = t[s];\n 128 & e ? h += \"%\" + e.toString(16) : (n += decodeURIComponent(h) + String.fromCharCode(e), h = \"\");\n }\n return h.length && (n += decodeURIComponent(h)), n;\n }\n _toBytes(t, e, i) {\n return i = Math.min(this._end, i), new Uint8Array(t.buffer, e, i - e);\n }\n}\nn.pool = new t(n, void 0, t => {\n t._data = null, t._dataView = null;\n});\nexport { n as default };"],"mappings":"gFAMA,IAAIA,GACH,SAAUC,EAAG,CACZA,EAAEA,EAAE,OAAS,CAAC,EAAI,SAAUA,EAAEA,EAAE,QAAU,CAAC,EAAI,UAAWA,EAAEA,EAAE,UAAY,CAAC,EAAI,YAAaA,EAAEA,EAAE,QAAU,CAAC,EAAI,UAAWA,EAAEA,EAAE,QAAU,EAAE,EAAI,SAChJ,GAAED,IAAMA,EAAI,CAAC,EAAE,EACf,IAAME,EAAI,WACRC,EAAI,IAAI,YAAY,O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