import { ChainForkConfig } from "@lodestar/config";
import { Db, FilterOptions, KeyValue, Repository } from "@lodestar/db";
import { Root, SignedBeaconBlock, Slot } from "@lodestar/types";
export interface BlockFilterOptions extends FilterOptions<Slot> {
    step?: number;
}
export type BlockArchiveBatchPutBinaryItem = KeyValue<Slot, Uint8Array> & {
    slot: Slot;
    blockRoot: Root;
    parentRoot: Root;
};
/**
 * Stores finalized blocks. Block slot is identifier.
 */
export declare class BlockArchiveRepository extends Repository<Slot, SignedBeaconBlock> {
    constructor(config: ChainForkConfig, db: Db);
    encodeValue(value: SignedBeaconBlock): Uint8Array;
    decodeValue(data: Uint8Array): SignedBeaconBlock;
    getId(value: SignedBeaconBlock): Slot;
    decodeKey(data: Uint8Array): number;
    put(key: Slot, value: SignedBeaconBlock): Promise<void>;
    batchPut(items: KeyValue<Slot, SignedBeaconBlock>[]): Promise<void>;
    batchPutBinary(items: BlockArchiveBatchPutBinaryItem[]): Promise<void>;
    remove(value: SignedBeaconBlock): Promise<void>;
    batchRemove(values: SignedBeaconBlock[]): Promise<void>;
    valuesStream(opts?: BlockFilterOptions): AsyncIterable<SignedBeaconBlock>;
    values(opts?: BlockFilterOptions): Promise<SignedBeaconBlock[]>;
    getByRoot(root: Root): Promise<SignedBeaconBlock | null>;
    getBinaryEntryByRoot(root: Root): Promise<KeyValue<Slot, Buffer> | null>;
    getByParentRoot(root: Root): Promise<SignedBeaconBlock | null>;
    getSlotByRoot(root: Root): Promise<Slot | null>;
    getSlotByParentRoot(root: Root): Promise<Slot | null>;
    private parseSlot;
    private getFirstSlot;
}
//# sourceMappingURL=blockArchive.d.ts.map