import type { Profile } from "../profiles/types.js"; import { type UpdatePhase } from "./progress-file.js"; export interface InterruptedSwapDeps { alive: (pid: number) => boolean; /** لحظة إقلاع النظام بالملّي ثانية. */ bootTimeMs: () => number; stop: (profile: Profile) => Promise; } export interface InterruptedSwapResult { from: string; to: string; phase: UpdatePhase; /** المجلدات التي أُعيدت. */ restored: string[]; databaseRestored: boolean; /** ما تعذّرت إعادته — الأسوأ، ويُقال كما هو. */ stubborn: string[]; } /** * AR: يعيد الشجرة إن وجد تحديثًا مات أثناء التبديل، أو ‎null‎ إن لم يكن ثمّة ما يُعاد. **لا يرمي.** * EN: Restores the tree if it finds an update that died mid-swap, or `null` when there is nothing to * restore. **Never throws.** */ export declare function recoverInterruptedSwap(profile: Profile, deps?: InterruptedSwapDeps): Promise; //# sourceMappingURL=interrupted-swap.d.ts.map