import { DbServer } from './index.js';
import { SchemaTypeDef } from '@based/schema/def';
export type CsmtNodeRange = {
    file: string;
    typeId: number;
    start: number;
    end: number;
};
export declare const specialBlock = 2147483647;
export declare const destructureCsmtKey: (key: number) => number[];
export declare const makeCsmtKey: (typeId: number, start: number) => number;
export declare const makeCsmtKeyFromNodeId: (typeId: number, blockCapacity: number, nodeId: number) => number;
export declare function initCsmt(db: DbServer): {};
export declare function foreachBlock(db: DbServer, def: SchemaTypeDef, cb: (start: number, end: number, hash: Uint8Array) => void, includeEmptyBlocks?: boolean): void;
export declare function foreachDirtyBlock(db: DbServer, cb: (mtKey: number, typeId: number, start: number, end: number) => void): Promise<void>;
