/** * Database migration system * Versioned schema updates for a single database */ import { SQLiteManager } from "./SQLiteManager.js"; export interface Migration { version: number; description: string; up: string; down?: string; checksum?: string; } export declare const migrations: Migration[]; export declare class MigrationManager { private db; constructor(db: SQLiteManager); /** * Get current schema version */ getCurrentVersion(): number; /** * Get all pending migrations sorted by version ascending */ getPendingMigrations(): Migration[]; /** * Apply a single migration with locking to prevent concurrent execution. * Uses BEGIN IMMEDIATE to acquire a write lock before checking/applying. */ applyMigration(migration: Migration): void; /** * Apply all pending migrations */ applyPendingMigrations(): void; /** * Rollback to a specific version */ rollbackTo(targetVersion: number): void; /** * Calculate migration checksum for verification */ private calculateChecksum; /** * Verify migration integrity */ verifyMigrations(): boolean; /** * Get migration history */ getHistory(): Array<{ version: number; description: string; applied_at: number; }>; } //# sourceMappingURL=migrations.d.ts.map