/** * Local-collection and interface-field collection helpers for TOCTOU detection. */ import * as ts from 'typescript'; /** Function-like node types that can have TOCTOU patterns */ export type FunctionLikeNode = ts.FunctionDeclaration | ts.MethodDeclaration | ts.ArrowFunction | ts.FunctionExpression; /** Check if node is a function-like node */ export declare function isFunctionLikeNode(node: ts.Node): node is FunctionLikeNode; /** Heuristic for in-process cache fields (`this.#cache`, `this.headerCache`, etc.). */ export declare function isInMemoryCacheReceiverText(text: string): boolean; /** Full dotted receiver chain for a property-access call target. */ export declare function getReceiverChainText(expr: ts.Expression): string | null; /** `const { byId } = this` aliases for class-owned Map/Set fields. */ export declare function collectThisCollectionFieldAliases(node: FunctionLikeNode, classCacheFields: ReadonlySet): Set; /** Map/Set names declared in enclosing functions (closure-visible locals). */ export declare function collectEnclosingLocalCollectionNames(node: FunctionLikeNode): Set; /** Collect local Map/Set variable names within a function. */ export declare function collectLocalCollectionNames(node: FunctionLikeNode): Set; export declare function collectClassInMemoryFieldNames(node: FunctionLikeNode): Set; /** Index file-local interface/type declarations to Map/Set field names. */ export declare function collectInterfaceCollectionFields(sourceFile: ts.SourceFile): Map>; /** Collect `.` keys for state-bag Map/Set fields. */ export declare function collectLocalObjectCollectionFieldKeys(node: FunctionLikeNode, interfaceCollectionFields: ReadonlyMap>): Set; //# sourceMappingURL=toctou-race-condition-collection.d.ts.map