///
import { EventEmitter } from "events";
export interface Namespace> {
active: any;
set(key: K, value: N[K]): N[K];
get(key: K): N[K];
run(fn: (...args: any[]) => void): void;
runAndReturn(fn: (...args: any[]) => T): T;
runPromise(fn: (...args: any[]) => Promise): Promise;
bind(fn: F, context?: any): F; // eslint-disable-line @typescript-eslint/no-unsafe-function-type
bindEmitter(emitter: EventEmitter): void;
createContext(): any;
enter(context: any): void;
exit(context: any): void;
}
// eslint-disable-next-line @definitelytyped/no-unnecessary-generics
export function createNamespace>(name: string): Namespace;
// eslint-disable-next-line @definitelytyped/no-unnecessary-generics
export function getNamespace>(name: string): Namespace | undefined;
export function destroyNamespace(name: string): void;
export function reset(): void;