miden_node_proto/generated/
blockchain.rs

1// This file is @generated by prost-build.
2/// Represents a block.
3#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
4pub struct Block {
5    /// Block data encoded using \[winter_utils::Serializable\] implementation for
6    /// \[miden_objects::block::Block\].
7    #[prost(bytes = "vec", tag = "1")]
8    pub block: ::prost::alloc::vec::Vec<u8>,
9}
10/// Represents a block or nothing.
11#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
12pub struct MaybeBlock {
13    /// The requested block data encoded using \[winter_utils::Serializable\] implementation for
14    /// \[miden_objects::block::Block\].
15    #[prost(bytes = "vec", optional, tag = "1")]
16    pub block: ::core::option::Option<::prost::alloc::vec::Vec<u8>>,
17}
18/// Represents a block number.
19#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
20pub struct BlockNumber {
21    /// The block number of the target block.
22    #[prost(fixed32, tag = "1")]
23    pub block_num: u32,
24}
25/// Represents a block number or nothing.
26#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
27pub struct MaybeBlockNumber {
28    /// The block number of the target block.
29    #[prost(fixed32, optional, tag = "1")]
30    pub block_num: ::core::option::Option<u32>,
31}
32/// Represents a block header.
33#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
34pub struct BlockHeader {
35    /// Specifies the version of the protocol.
36    #[prost(uint32, tag = "1")]
37    pub version: u32,
38    /// The commitment of the previous blocks header.
39    #[prost(message, optional, tag = "2")]
40    pub prev_block_commitment: ::core::option::Option<super::primitives::Digest>,
41    /// A unique sequential number of the current block.
42    #[prost(fixed32, tag = "3")]
43    pub block_num: u32,
44    /// A commitment to an MMR of the entire chain where each block is a leaf.
45    #[prost(message, optional, tag = "4")]
46    pub chain_commitment: ::core::option::Option<super::primitives::Digest>,
47    /// A commitment to account database.
48    #[prost(message, optional, tag = "5")]
49    pub account_root: ::core::option::Option<super::primitives::Digest>,
50    /// A commitment to the nullifier database.
51    #[prost(message, optional, tag = "6")]
52    pub nullifier_root: ::core::option::Option<super::primitives::Digest>,
53    /// A commitment to all notes created in the current block.
54    #[prost(message, optional, tag = "7")]
55    pub note_root: ::core::option::Option<super::primitives::Digest>,
56    /// A commitment to a set of IDs of transactions which affected accounts in this block.
57    #[prost(message, optional, tag = "8")]
58    pub tx_commitment: ::core::option::Option<super::primitives::Digest>,
59    /// A commitment to a STARK proof attesting to the correct state transition.
60    #[prost(message, optional, tag = "9")]
61    pub proof_commitment: ::core::option::Option<super::primitives::Digest>,
62    /// A commitment to all transaction kernels supported by this block.
63    #[prost(message, optional, tag = "10")]
64    pub tx_kernel_commitment: ::core::option::Option<super::primitives::Digest>,
65    /// Fee parameters for block processing.
66    #[prost(message, optional, tag = "11")]
67    pub fee_parameters: ::core::option::Option<FeeParameters>,
68    /// The time when the block was created.
69    #[prost(fixed32, tag = "12")]
70    pub timestamp: u32,
71}
72/// Definition of the fee parameters.
73#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
74pub struct FeeParameters {
75    /// The faucet account ID which is used for native fee assets.
76    #[prost(message, optional, tag = "1")]
77    pub native_asset_id: ::core::option::Option<super::account::AccountId>,
78    /// The base fee (in base units) capturing the cost for the verification of a transaction.
79    #[prost(fixed32, tag = "2")]
80    pub verification_base_fee: u32,
81}