export type AtomicWritePoint = "after-file-sync" | "before-commit" | "after-commit" | "after-directory-sync"; export type AtomicFaultInjector = (point: AtomicWritePoint) => void | Promise; export interface AtomicJsonWriteOptions { readonly createOnly?: boolean; readonly fault?: AtomicFaultInjector; } /** * Writes one private JSON record through a same-directory atomic commit. * * `createOnly` uses an exclusive hard-link commit so a contender can never * replace an existing record. Replacement uses rename. In both cases the * complete file is synced before it becomes visible and the parent directory * is synced after the namespace mutation. */ export declare function writeAtomicJson(path: string, value: unknown, options?: AtomicJsonWriteOptions): Promise; export declare function readJson(path: string): Promise; export declare function syncDirectory(path: string): Promise; //# sourceMappingURL=atomic-json.d.ts.map