/**
 * Incremental Scan Mode
 * Optimized scanning for PR workflows - only scan changed files and surface relevant findings
 */
import type { ScanFile, Vulnerability, ScanModeConfig } from '../../shared/types';
import { type FileDiff } from '../../shared/diff-parser';
/**
 * Options for incremental scanning
 */
export interface IncrementalScanOptions {
    /** Git diff output (if available) */
    diffContent?: string;
    /** List of changed file paths (alternative to diff) */
    changedFiles?: string[];
    /** Whether to only show findings on exactly changed lines (strict) or nearby (default) */
    strictLineMatching?: boolean;
    /** Context window for "near changed line" (default: 5) */
    contextWindow?: number;
    /** Whether to mark findings as "introduced in this PR" */
    markAsIntroduced?: boolean;
    /** Previous findings to compare against (for suppressing pre-existing issues) */
    previousFindings?: Vulnerability[];
}
/**
 * Result of incremental scan with additional PR-specific metadata
 */
export interface IncrementalScanResult {
    /** All findings (filtered to changed lines) */
    findings: Vulnerability[];
    /** Findings that are new in this PR */
    introduced: Vulnerability[];
    /** Findings that existed before (if previousFindings provided) */
    preExisting: Vulnerability[];
    /** Number of files scanned */
    filesScanned: number;
    /** Number of files that were changed */
    filesChanged: number;
    /** Parsed diff information */
    diffs: Map<string, FileDiff>;
    /** Scan duration in ms */
    duration: number;
}
/**
 * Run an incremental scan optimized for PR workflows
 *
 * This scans:
 * 1. All changed files (added + modified)
 * 2. Files that import changed files (for context)
 * 3. Middleware files (for auth context)
 *
 * And only surfaces findings on/near changed lines.
 */
export declare function runIncrementalScan(allFiles: ScanFile[], options: IncrementalScanOptions): Promise<IncrementalScanResult>;
/**
 * Create a PR-optimized scan config
 */
export declare function createPRScanConfig(changedFiles: string[], options?: Partial<ScanModeConfig>): ScanModeConfig;
/**
 * Format incremental scan result for PR comment
 */
export declare function formatIncrementalForPR(result: IncrementalScanResult): {
    summary: string;
    hasNewIssues: boolean;
    blockingIssues: number;
};
//# sourceMappingURL=incremental.d.ts.map