/** * Input Pre-Resolver - Pre-resolves static stage inputs for performance optimisation * * This service analyses pipeline stages and pre-resolves inputs that don't depend * on previous stage outputs ($STAGE_* variables). This allows: * - File contents to be cached upfront * - Reduce resolution time during stage execution * - Early validation of input availability */ import type { PipelineStage } from '../types/command.types.js'; import type { VariableResolutionService } from './variable-resolution.service.js'; export interface PreResolvedInputs { /** Map of stage key to pre-resolved inputs */ stages: Map>; /** Map of file path to cached content */ fileCache: Map; /** Stages that have all inputs pre-resolved (no $STAGE_* dependencies) */ fullyResolvedStages: Set; } /** * Input Pre-Resolver Service * * Analyses pipeline stages and pre-resolves inputs that don't depend on * previous stage outputs, improving pipeline execution performance. */ export declare class InputPreResolver { private fileCache; private preResolvedInputs; /** * Pre-resolve static inputs for all stages in a pipeline * * @param stages - Pipeline stages to analyse * @param variableResolver - Variable resolver with current context * @returns PreResolvedInputs containing cached inputs and file contents */ preResolveStaticInputs(stages: PipelineStage[], variableResolver: VariableResolutionService): Promise; /** * Get pre-resolved inputs for a stage if available */ getPreResolvedInputs(stageKey: string): Record | undefined; /** * Get cached file content if available */ getCachedFileContent(filePath: string): string | undefined; /** * Check if inputs contain any $STAGE_* variable references */ private hasStageReferences; /** * Enrich inputs by reading file contents for file path arguments * Caches file contents for reuse */ private enrichInputsWithFileContents; /** * Clear cached data */ clear(): void; } export declare function getInputPreResolver(): InputPreResolver; export declare function resetInputPreResolver(): void; //# sourceMappingURL=input-pre-resolver.d.ts.map