import type { LightConfig, SentryEvent, UserInfo } from '../types'; export declare class ConfigManager { private config; private contexts; private contextId; private contextReported; constructor(config: LightConfig); markContextReported(): void; get(key: K): LightConfig[K]; getAll(): LightConfig; set(key: K, value: LightConfig[K]): void; setUser(user: UserInfo | null): void; setTags(tags: Record): void; setTag(key: string, value: string): void; setExtra(key: string, value: unknown): void; shouldSample(): boolean; isIgnoredError(message: string): boolean; /** * 获取编码后的环境信息(延迟初始化,只在首次上报时计算) * 注意:env.ts 的 getContexts 已经返回编码后的数据 */ private getEncodedContext; /** * 将配置应用到事件 * @param event 事件对象 * @param includeFullContext 是否包含完整环境信息(批次内只有首个事件需要) */ applyToEvent(event: SentryEvent, includeFullContext?: boolean): SentryEvent; /** * 应用上下文分层策略:根据事件级别裁剪堆栈和 breadcrumbs */ private applyContextLevel; }