/**
 * ConflictTrace — runtime-backed record of a single detected conflict.
 *
 * @module domain/types/conflict/ConflictTrace
 */
import ConflictReceiptRef from './ConflictReceiptRef.ts';
import type ConflictTarget from './ConflictTarget.ts';
import type ConflictWinner from './ConflictWinner.ts';
import type ConflictParticipant from './ConflictParticipant.ts';
import type ConflictResolution from './ConflictResolution.ts';
/**
 * The fields accepted for a receipt reference. Either a
 * ConflictReceiptRef instance, or a plain carrier with the same
 * three fields — the evidence builder constructs the class around it.
 */
type ReceiptRefInput = ConflictReceiptRef | {
    patchSha: string;
    lamport: number;
    opIndex: number;
};
export type ConflictEvidenceInput = {
    level: string;
    patchRefs: string[];
    receiptRefs: ReceiptRefInput[];
};
type EvidencePayload = {
    level: string;
    patchRefs: readonly string[];
    receiptRefs: readonly ConflictReceiptRef[];
};
/**
 * A runtime-backed record of a single conflict detected by the analyzer.
 *
 * Instances are frozen on construction. Losers, evidence, and classification notes are deep-frozen.
 */
export default class ConflictTrace {
    readonly conflictId: string;
    readonly kind: string;
    readonly target: ConflictTarget;
    readonly winner: ConflictWinner;
    readonly losers: readonly ConflictParticipant[];
    readonly resolution: ConflictResolution;
    readonly whyFingerprint: string;
    readonly classificationNotes: readonly string[] | undefined;
    readonly evidence: Readonly<EvidencePayload>;
    /**
     * Creates a frozen ConflictTrace.
     */
    constructor({ conflictId, kind, target, winner, losers, resolution, whyFingerprint, classificationNotes, evidence }: {
        conflictId: string;
        kind: 'supersession' | 'eventual_override' | 'redundancy';
        target: ConflictTarget;
        winner: ConflictWinner;
        losers: ConflictParticipant[];
        resolution: ConflictResolution;
        whyFingerprint: string;
        classificationNotes?: string[];
        evidence: ConflictEvidenceInput;
    });
    /**
     * Tests whether the specified writer participated as winner or loser.
     */
    touchesWriter(writerId: string): boolean;
    /**
     * Compares two ConflictTraces for deterministic ordering by kind, target, winner, then id.
     */
    static compare(a: ConflictTrace, b: ConflictTrace): number;
}
export {};
