import type { LogContext } from '@rocicorp/logger';
import type { Database } from '../../../zqlite/src/db.ts';
import type { LiteAndZqlSpec, LiteIndexSpec, LiteTableSpec } from './specs.ts';
export type LiteTableSpecWithReplicationStatus = LiteTableSpec & {
    readonly backfilling?: string[];
};
export declare function listTables(db: Database, useColumnMetadata?: boolean): LiteTableSpecWithReplicationStatus[];
export declare function listIndexes(db: Database): LiteIndexSpec[];
export type ZqlSpecOptions = {
    /**
     * Controls whether to include backfilling columns in the computed
     * LiteAndZqlSpec. In general, backfilling columns should be include
     * in "replication" logic (copying data from upstream to the replica),
     * and excluded from "sync" logic (sending data from the replica to
     * clients).
     */
    includeBackfillingColumns: boolean;
};
/**
 * Computes a TableSpec "view" of the replicated data that is
 * suitable for processing / consumption for the client. This
 * includes:
 * * excluding tables without a PRIMARY KEY or UNIQUE INDEX
 * * excluding columns with types that are not supported by ZQL
 * * choosing columns to use as the primary key amongst those
 *   in unique indexes
 *
 * @param tableSpecs an optional map to reset and populate
 * @param fullTables an optional map to receive the full table specs,
 *        which may include tables and columns that are not synced to
 *        the client because they lack a primary key or are of unsupported
 *        data types.
 */
export declare function computeZqlSpecs(lc: LogContext, replica: Database, opts: ZqlSpecOptions, tableSpecs?: Map<string, LiteAndZqlSpec>, fullTables?: Map<string, LiteTableSpec>): Map<string, LiteAndZqlSpec>;
export declare function computeZqlSpecsFromLiteSpecs(tables: LiteTableSpecWithReplicationStatus[], indexes: LiteIndexSpec[], { includeBackfillingColumns }: ZqlSpecOptions, tableSpecs?: Map<string, LiteAndZqlSpec>, fullTables?: Map<string, LiteTableSpec>, lc?: LogContext): Map<string, LiteAndZqlSpec>;
export declare function mustGetTableSpec(tableSpecs: Map<string, LiteAndZqlSpec>, tableName: string): LiteAndZqlSpec;
//# sourceMappingURL=lite-tables.d.ts.map