/// <reference types="node" resolution-mode="require"/>
/// <reference types="node" resolution-mode="require"/>
import { AppendOnlyTreeSnapshot, BlockHeader } from '@aztec/circuits.js';
import { Fr } from '@aztec/foundation/fields';
import { BufferReader } from '@aztec/foundation/serialize';
import { z } from 'zod';
import { Body } from './body.js';
/**
 * The data that makes up the rollup proof, with encoder decoder functions.
 */
export declare class L2Block {
    /** Snapshot of archive tree after the block is applied. */
    archive: AppendOnlyTreeSnapshot;
    /** L2 block header. */
    header: BlockHeader;
    /** L2 block body. */
    body: Body;
    constructor(
    /** Snapshot of archive tree after the block is applied. */
    archive: AppendOnlyTreeSnapshot, 
    /** L2 block header. */
    header: BlockHeader, 
    /** L2 block body. */
    body: Body);
    static get schema(): z.ZodEffects<z.ZodObject<{
        archive: z.ZodEffects<z.ZodObject<{
            root: z.ZodType<Fr, any, string>;
            nextAvailableLeafIndex: z.ZodPipeline<z.ZodUnion<[z.ZodBigInt, z.ZodNumber, z.ZodString]>, z.ZodNumber>;
        }, "strip", z.ZodTypeAny, {
            root: Fr;
            nextAvailableLeafIndex: number;
        }, {
            root: string;
            nextAvailableLeafIndex: string | number | bigint;
        }>, AppendOnlyTreeSnapshot, {
            root: string;
            nextAvailableLeafIndex: string | number | bigint;
        }>;
        header: z.ZodEffects<z.ZodObject<{
            lastArchive: z.ZodEffects<z.ZodObject<{
                root: z.ZodType<Fr, any, string>;
                nextAvailableLeafIndex: z.ZodPipeline<z.ZodUnion<[z.ZodBigInt, z.ZodNumber, z.ZodString]>, z.ZodNumber>;
            }, "strip", z.ZodTypeAny, {
                root: Fr;
                nextAvailableLeafIndex: number;
            }, {
                root: string;
                nextAvailableLeafIndex: string | number | bigint;
            }>, AppendOnlyTreeSnapshot, {
                root: string;
                nextAvailableLeafIndex: string | number | bigint;
            }>;
            contentCommitment: z.ZodEffects<z.ZodObject<{
                numTxs: z.ZodType<Fr, any, string>;
                blobsHash: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Buffer, string>, z.ZodEffects<z.ZodObject<{
                    type: z.ZodLiteral<"Buffer">;
                    data: z.ZodArray<z.ZodNumber, "many">;
                }, "strip", z.ZodTypeAny, {
                    type: "Buffer";
                    data: number[];
                }, {
                    type: "Buffer";
                    data: number[];
                }>, Buffer, {
                    type: "Buffer";
                    data: number[];
                }>]>;
                inHash: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Buffer, string>, z.ZodEffects<z.ZodObject<{
                    type: z.ZodLiteral<"Buffer">;
                    data: z.ZodArray<z.ZodNumber, "many">;
                }, "strip", z.ZodTypeAny, {
                    type: "Buffer";
                    data: number[];
                }, {
                    type: "Buffer";
                    data: number[];
                }>, Buffer, {
                    type: "Buffer";
                    data: number[];
                }>]>;
                outHash: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Buffer, string>, z.ZodEffects<z.ZodObject<{
                    type: z.ZodLiteral<"Buffer">;
                    data: z.ZodArray<z.ZodNumber, "many">;
                }, "strip", z.ZodTypeAny, {
                    type: "Buffer";
                    data: number[];
                }, {
                    type: "Buffer";
                    data: number[];
                }>, Buffer, {
                    type: "Buffer";
                    data: number[];
                }>]>;
            }, "strip", z.ZodTypeAny, {
                numTxs: Fr;
                blobsHash: Buffer;
                inHash: Buffer;
                outHash: Buffer;
            }, {
                numTxs: string;
                blobsHash: string | {
                    type: "Buffer";
                    data: number[];
                };
                inHash: string | {
                    type: "Buffer";
                    data: number[];
                };
                outHash: string | {
                    type: "Buffer"; /**
                     * Computes the start state hash (should equal contract data before block).
                     * @returns The start state hash for the L2 block.
                     */
                    data: number[];
                };
            }>, import("@aztec/circuits.js").ContentCommitment, {
                numTxs: string;
                blobsHash: string | {
                    type: "Buffer";
                    data: number[];
                };
                inHash: string | {
                    type: "Buffer";
                    data: number[];
                };
                outHash: string | {
                    type: "Buffer";
                    data: number[];
                };
            }>;
            state: z.ZodEffects<z.ZodObject<{
                l1ToL2MessageTree: z.ZodEffects<z.ZodObject<{
                    root: z.ZodType<Fr, any, string>;
                    nextAvailableLeafIndex: z.ZodPipeline<z.ZodUnion<[z.ZodBigInt, z.ZodNumber, z.ZodString]>, z.ZodNumber>;
                }, "strip", z.ZodTypeAny, {
                    root: Fr;
                    nextAvailableLeafIndex: number;
                }, {
                    root: string;
                    nextAvailableLeafIndex: string | number | bigint;
                }>, AppendOnlyTreeSnapshot, {
                    root: string;
                    nextAvailableLeafIndex: string | number | bigint;
                }>;
                partial: z.ZodEffects<z.ZodObject<{
                    noteHashTree: z.ZodEffects<z.ZodObject<{
                        root: z.ZodType<Fr, any, string>;
                        nextAvailableLeafIndex: z.ZodPipeline<z.ZodUnion<[z.ZodBigInt, z.ZodNumber, z.ZodString]>, z.ZodNumber>;
                    }, "strip", z.ZodTypeAny, {
                        root: Fr;
                        nextAvailableLeafIndex: number;
                    }, {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    }>, AppendOnlyTreeSnapshot, {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    }>;
                    nullifierTree: z.ZodEffects<z.ZodObject<{
                        root: z.ZodType<Fr, any, string>;
                        nextAvailableLeafIndex: z.ZodPipeline<z.ZodUnion<[z.ZodBigInt, z.ZodNumber, z.ZodString]>, z.ZodNumber>;
                    }, "strip", z.ZodTypeAny, {
                        root: Fr;
                        nextAvailableLeafIndex: number;
                    }, {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    }>, AppendOnlyTreeSnapshot, {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    }>;
                    publicDataTree: z.ZodEffects<z.ZodObject<{
                        root: z.ZodType<Fr, any, string>;
                        nextAvailableLeafIndex: z.ZodPipeline<z.ZodUnion<[z.ZodBigInt, z.ZodNumber, z.ZodString]>, z.ZodNumber>;
                    }, "strip", z.ZodTypeAny, {
                        root: Fr;
                        nextAvailableLeafIndex: number;
                    }, {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    }>, AppendOnlyTreeSnapshot, {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    }>;
                }, "strip", z.ZodTypeAny, {
                    noteHashTree: AppendOnlyTreeSnapshot;
                    nullifierTree: AppendOnlyTreeSnapshot;
                    publicDataTree: AppendOnlyTreeSnapshot;
                }, {
                    noteHashTree: {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    };
                    nullifierTree: {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    };
                    publicDataTree: {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    };
                }>, import("@aztec/circuits.js").PartialStateReference, {
                    noteHashTree: {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    };
                    nullifierTree: {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    };
                    publicDataTree: {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    };
                }>;
            }, "strip", z.ZodTypeAny, {
                l1ToL2MessageTree: AppendOnlyTreeSnapshot;
                partial: import("@aztec/circuits.js").PartialStateReference;
            }, {
                l1ToL2MessageTree: {
                    root: string;
                    nextAvailableLeafIndex: string | number | bigint;
                };
                partial: {
                    noteHashTree: {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    };
                    nullifierTree: {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    };
                    publicDataTree: {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    };
                };
            }>, import("@aztec/circuits.js").StateReference, {
                l1ToL2MessageTree: {
                    root: string;
                    nextAvailableLeafIndex: string | number | bigint;
                };
                partial: {
                    noteHashTree: {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    };
                    nullifierTree: {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    };
                    publicDataTree: {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    };
                };
            }>;
            globalVariables: z.ZodEffects<z.ZodObject<{
                chainId: z.ZodType<Fr, any, string>;
                version: z.ZodType<Fr, any, string>;
                blockNumber: z.ZodType<Fr, any, string>;
                slotNumber: z.ZodType<Fr, any, string>;
                timestamp: z.ZodType<Fr, any, string>;
                coinbase: z.ZodType<import("@aztec/circuits.js").EthAddress, any, string>;
                feeRecipient: z.ZodType<import("@aztec/circuits.js").AztecAddress, any, string>;
                gasFees: z.ZodEffects<z.ZodObject<{
                    feePerDaGas: z.ZodType<Fr, any, string>;
                    feePerL2Gas: z.ZodType<Fr, any, string>;
                }, "strip", z.ZodTypeAny, {
                    feePerDaGas: Fr;
                    feePerL2Gas: Fr;
                }, {
                    feePerDaGas: string;
                    feePerL2Gas: string;
                }>, import("@aztec/circuits.js").GasFees, {
                    feePerDaGas: string;
                    feePerL2Gas: string;
                }>;
            }, "strip", z.ZodTypeAny, {
                version: Fr;
                chainId: Fr;
                blockNumber: Fr;
                slotNumber: Fr;
                timestamp: Fr;
                coinbase: import("@aztec/circuits.js").EthAddress;
                feeRecipient: import("@aztec/circuits.js").AztecAddress;
                gasFees: import("@aztec/circuits.js").GasFees;
            }, {
                version: string;
                chainId: string;
                blockNumber: string;
                slotNumber: string;
                timestamp: string;
                coinbase: string;
                feeRecipient: string;
                gasFees: {
                    feePerDaGas: string;
                    feePerL2Gas: string;
                };
            }>, import("@aztec/circuits.js").GlobalVariables, {
                version: string;
                chainId: string;
                blockNumber: string;
                slotNumber: string;
                timestamp: string;
                coinbase: string;
                feeRecipient: string;
                gasFees: {
                    feePerDaGas: string;
                    feePerL2Gas: string;
                };
            }>;
            totalFees: z.ZodType<Fr, any, string>;
            totalManaUsed: z.ZodType<Fr, any, string>;
        }, "strip", z.ZodTypeAny, {
            lastArchive: AppendOnlyTreeSnapshot;
            contentCommitment: import("@aztec/circuits.js").ContentCommitment;
            state: import("@aztec/circuits.js").StateReference;
            globalVariables: import("@aztec/circuits.js").GlobalVariables;
            totalFees: Fr;
            totalManaUsed: Fr;
        }, {
            lastArchive: {
                root: string;
                nextAvailableLeafIndex: string | number | bigint;
            };
            contentCommitment: {
                numTxs: string;
                blobsHash: string | {
                    type: "Buffer";
                    data: number[];
                };
                inHash: string | {
                    type: "Buffer";
                    data: number[];
                };
                outHash: string | {
                    type: "Buffer";
                    data: number[];
                };
            };
            state: {
                l1ToL2MessageTree: {
                    root: string;
                    nextAvailableLeafIndex: string | number | bigint;
                };
                partial: {
                    noteHashTree: {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    };
                    nullifierTree: {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    };
                    publicDataTree: {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    };
                };
            };
            globalVariables: {
                version: string;
                chainId: string;
                blockNumber: string;
                slotNumber: string;
                timestamp: string;
                coinbase: string;
                feeRecipient: string;
                gasFees: {
                    feePerDaGas: string;
                    feePerL2Gas: string;
                };
            };
            totalFees: string;
            totalManaUsed: string;
        }>, BlockHeader, {
            lastArchive: {
                root: string;
                nextAvailableLeafIndex: string | number | bigint;
            };
            contentCommitment: {
                numTxs: string;
                blobsHash: string | {
                    type: "Buffer";
                    data: number[];
                };
                inHash: string | {
                    type: "Buffer";
                    data: number[];
                };
                outHash: string | {
                    type: "Buffer";
                    data: number[];
                };
            };
            state: {
                l1ToL2MessageTree: {
                    root: string;
                    nextAvailableLeafIndex: string | number | bigint;
                };
                partial: {
                    noteHashTree: {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    };
                    nullifierTree: {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    };
                    publicDataTree: {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    };
                };
            };
            globalVariables: {
                version: string;
                chainId: string;
                blockNumber: string;
                slotNumber: string;
                timestamp: string;
                coinbase: string;
                feeRecipient: string;
                gasFees: {
                    feePerDaGas: string;
                    feePerL2Gas: string;
                };
            };
            totalFees: string;
            totalManaUsed: string;
        }>;
        body: import("@aztec/foundation/schemas").ZodFor<Body>;
    }, "strip", z.ZodTypeAny, {
        archive: AppendOnlyTreeSnapshot;
        header: BlockHeader;
        body: Body;
    }, {
        archive: {
            root: string;
            nextAvailableLeafIndex: string | number | bigint;
        };
        header: {
            lastArchive: {
                root: string;
                nextAvailableLeafIndex: string | number | bigint;
            };
            contentCommitment: {
                numTxs: string;
                blobsHash: string | {
                    type: "Buffer";
                    data: number[];
                };
                inHash: string | {
                    type: "Buffer";
                    data: number[];
                };
                outHash: string | {
                    type: "Buffer";
                    data: number[];
                };
            };
            state: {
                l1ToL2MessageTree: {
                    root: string;
                    nextAvailableLeafIndex: string | number | bigint;
                };
                partial: {
                    noteHashTree: {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    };
                    nullifierTree: {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    };
                    publicDataTree: {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    };
                };
            };
            globalVariables: {
                version: string;
                chainId: string;
                blockNumber: string;
                slotNumber: string;
                timestamp: string;
                coinbase: string;
                feeRecipient: string;
                gasFees: {
                    feePerDaGas: string;
                    feePerL2Gas: string;
                };
            };
            totalFees: string;
            totalManaUsed: string;
        };
        body?: any;
    }>, L2Block, {
        archive: {
            root: string;
            nextAvailableLeafIndex: string | number | bigint;
        };
        header: {
            lastArchive: {
                root: string;
                nextAvailableLeafIndex: string | number | bigint;
            };
            contentCommitment: {
                numTxs: string;
                blobsHash: string | {
                    type: "Buffer";
                    data: number[];
                };
                inHash: string | {
                    type: "Buffer";
                    data: number[];
                };
                outHash: string | {
                    type: "Buffer";
                    data: number[];
                };
            };
            state: {
                l1ToL2MessageTree: {
                    root: string;
                    nextAvailableLeafIndex: string | number | bigint;
                };
                partial: {
                    noteHashTree: {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    };
                    nullifierTree: {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    };
                    publicDataTree: {
                        root: string;
                        nextAvailableLeafIndex: string | number | bigint;
                    };
                };
            };
            globalVariables: {
                version: string;
                chainId: string;
                blockNumber: string;
                slotNumber: string;
                timestamp: string;
                coinbase: string;
                feeRecipient: string;
                gasFees: {
                    feePerDaGas: string;
                    feePerL2Gas: string;
                };
            };
            totalFees: string;
            totalManaUsed: string;
        };
        body?: any;
    }>;
    /**
     * Deserializes a block from a buffer
     * @returns A deserialized L2 block.
     */
    static fromBuffer(buf: Buffer | BufferReader): L2Block;
    /**
     * Serializes a block
     * @returns A serialized L2 block as a Buffer.
     */
    toBuffer(): Buffer;
    /**
     * Deserializes L2 block from a buffer.
     * @param str - A serialized L2 block.
     * @returns Deserialized L2 block.
     */
    static fromString(str: string): L2Block;
    /**
     * Serializes a block to a string.
     * @returns A serialized L2 block as a string.
     */
    toString(): string;
    /**
     * Creates an L2 block containing random data.
     * @param l2BlockNum - The number of the L2 block.
     * @param txsPerBlock - The number of transactions to include in the block.
     * @param numPublicCallsPerTx - The number of public function calls to include in each transaction.
     * @param numUnencryptedLogsPerCall - The number of unencrypted logs per 1 public function invocation.
     * @param inHash - The hash of the L1 to L2 messages subtree which got inserted in this block.
     * @returns The L2 block.
     */
    static random(l2BlockNum: number, txsPerBlock?: number, numPublicCallsPerTx?: number, numUnencryptedLogsPerCall?: number, inHash?: Buffer | undefined, slotNumber?: number | undefined): L2Block;
    /**
     * Creates an L2 block containing empty data.
     * @returns The L2 block.
     */
    static empty(): L2Block;
    get number(): number;
    /**
     * Returns the block's hash (hash of block header).
     * @returns The block's hash.
     */
    hash(): Fr;
    /**
     * Computes the public inputs hash for the L2 block.
     * The same output as the hash of RootRollupPublicInputs.
     * TODO(Miranda): Check where/if this is used (v diff now with epochs and blobs)
     * @returns The public input hash for the L2 block as a field element.
     */
    getPublicInputsHash(): Fr;
    /**
     * Computes the start state hash (should equal contract data before block).
     * @returns The start state hash for the L2 block.
     */
    getStartStateHash(): Buffer;
    /**
     * Computes the end state hash (should equal contract data after block).
     * @returns The end state hash for the L2 block.
     */
    getEndStateHash(): Buffer;
    /**
     * Returns stats used for logging.
     * @returns Stats on tx count, number, and log size and count.
     */
    getStats(): {
        unencryptedLogCount: number;
        unencryptedLogSize: number;
        contractClassLogCount: number;
        contractClassLogSize: number;
        txCount: number;
        blockNumber: number;
        blockTimestamp: number;
    };
}
//# sourceMappingURL=l2_block.d.ts.map