import { StateDatabase } from "./database.js"; type LeaseRow = { generation: number; ownerType: string | null; ownerId: string | null; tokenHash: Buffer | null; expiresAt: number | null; }; export declare function isRecord(value: unknown): value is Record; export declare function isSequenceRow(value: unknown): value is { seq: number; }; export declare function validTimestamp(value?: string): string; export declare function epoch(value: string): number; /** Shared connection, project, and revision operations; domain stores own their rows. */ export declare abstract class ProjectStore { readonly filePath: string; readonly state: StateDatabase; private readonly ownsState; protected readonly projectId: string | null; private closed; constructor(filePath?: string, options?: { readOnly?: boolean; projectPath?: string; state?: StateDatabase; /** Server-only global view. Project-scoped mutations still require projectPath. */ global?: boolean; }); close(): void; private ensureProject; private findProject; protected requireProjectId(): string; protected requireLease(resourceId: string): LeaseRow; protected resourceRevision(resourceId: string): number; protected bumpResource(resourceId: string, expectedRevision: number, now: number): void; protected insertEvent(resourceId: string, revision: number, type: string, actorType: string, actorId: string | null, payload: unknown, now: number, leaseGeneration?: number): string; protected assertWritable(): void; } export {};