import type { TodoClaim, TodoDefinition, TodoListDocument, TodoListView, TodoStatus } from "./types.ts"; export interface FileTodoStoreOptions { revisionSnapshotLimit?: number; lockTimeoutMs?: number; lockHeartbeatMs?: number; lockHook?: (phase: "published" | "acquired", listId: string) => Promise; lockNonce?: () => string; lockEnvironment?: LockEnvironment; } export interface LockIdentity { host: string; hostId: string; bootId: string; pidNamespace: string; processStartToken: string; } export interface ProcessProbe { status: "alive" | "missing" | "unknown"; startToken?: string; } export interface LockEnvironment { current(): Promise; probe(pid: number): Promise; now(): number; } export declare const TODO_LIST_NOT_FOUND = "todo-list-not-found"; export declare class TodoPersistenceError extends Error { readonly code: string; constructor(message: string, options?: ErrorOptions & { code?: string; }); } export declare class FileTodoStore { private readonly rootDir; private readonly revisionSnapshotLimit; private readonly lockTimeoutMs; private readonly lockHeartbeatMs; private readonly lockHook; private readonly lockNonce; private readonly lockEnvironment; private diagnostic; constructor(rootDir: string, options?: FileTodoStoreOptions); takeDiagnostic(): string | undefined; create(globalDirection: string, items: readonly TodoDefinition[], id?: string): Promise; read(id: string, revision?: number): Promise; view(id: string, revision?: number): Promise; add(id: string, items: readonly TodoDefinition[]): Promise; update(listId: string, taskId: string, patch: { subject?: string; description?: string | null; active_form?: string | null; depends_on?: string[]; acceptance_criteria?: string[] | null; status?: TodoStatus; expected_revision?: number; }): Promise; claim(listId: string, taskId: string, owner: string, expectedRevision?: number): Promise; release(listId: string, taskId: string): Promise; releaseIfOwned(listId: string, taskId: string, expectedOwner: string): Promise; transfer(listId: string, taskId: string, newOwner: string): Promise; reconcileOwners(listId: string, liveOwners: ReadonlySet): Promise; delete(listId: string, taskId: string): Promise; clone(sourceId: string, revision?: number, targetId?: string): Promise; removeList(id: string): Promise; private mutate; private readDocument; private writeDocument; private writeSnapshot; private readSnapshot; private atomicWrite; private atomicLockWrite; private atomicLockPublish; private withLock; private startLockHeartbeat; private listDir; private documentPath; private backupPath; } //# sourceMappingURL=store.d.ts.map