iota_grpc_types/proto/generated/
iota.grpc.v1.epoch.rs

1// Copyright (c) Mysten Labs, Inc.
2// Modifications Copyright (c) 2025 IOTA Stiftung
3// SPDX-License-Identifier: Apache-2.0
4
5// This file is @generated by prost-build.
6/// A member of a validator committee.
7#[non_exhaustive]
8#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
9pub struct ValidatorCommitteeMember {
10    /// The 96-byte Bls12381 public key for this validator.
11    #[prost(bytes = "bytes", optional, tag = "1")]
12    pub public_key: ::core::option::Option<::prost::bytes::Bytes>,
13    /// voting weight this validator possesses.
14    #[prost(uint64, optional, tag = "2")]
15    pub weight: ::core::option::Option<u64>,
16}
17#[non_exhaustive]
18#[derive(Clone, PartialEq, ::prost::Message)]
19pub struct ValidatorCommitteeMembers {
20    #[prost(message, repeated, tag = "1")]
21    pub members: ::prost::alloc::vec::Vec<ValidatorCommitteeMember>,
22}
23/// The validator set for a particular epoch.
24#[non_exhaustive]
25#[derive(Clone, PartialEq, ::prost::Message)]
26pub struct ValidatorCommittee {
27    /// The epoch where this committee governs.
28    #[prost(uint64, optional, tag = "1")]
29    pub epoch: ::core::option::Option<u64>,
30    /// The committee members.
31    #[prost(message, optional, tag = "2")]
32    pub members: ::core::option::Option<ValidatorCommitteeMembers>,
33}
34#[non_exhaustive]
35#[derive(Clone, PartialEq, ::prost::Message)]
36pub struct ProtocolFeatureFlags {
37    #[prost(btree_map = "string, bool", tag = "1")]
38    pub flags: ::prost::alloc::collections::BTreeMap<
39        ::prost::alloc::string::String,
40        bool,
41    >,
42}
43#[non_exhaustive]
44#[derive(Clone, PartialEq, ::prost::Message)]
45pub struct ProtocolAttributes {
46    #[prost(btree_map = "string, string", tag = "1")]
47    pub attributes: ::prost::alloc::collections::BTreeMap<
48        ::prost::alloc::string::String,
49        ::prost::alloc::string::String,
50    >,
51}
52#[non_exhaustive]
53#[derive(Clone, PartialEq, ::prost::Message)]
54pub struct ProtocolConfig {
55    #[prost(uint64, optional, tag = "1")]
56    pub protocol_version: ::core::option::Option<u64>,
57    #[prost(message, optional, tag = "2")]
58    pub feature_flags: ::core::option::Option<ProtocolFeatureFlags>,
59    #[prost(message, optional, tag = "3")]
60    pub attributes: ::core::option::Option<ProtocolAttributes>,
61}
62#[non_exhaustive]
63#[derive(Clone, PartialEq, ::prost::Message)]
64pub struct Epoch {
65    #[prost(uint64, optional, tag = "1")]
66    pub epoch: ::core::option::Option<u64>,
67    /// The committee governing this epoch.
68    #[prost(message, optional, tag = "2")]
69    pub committee: ::core::option::Option<ValidatorCommittee>,
70    /// Snapshot of IOTA's SystemState (`0x3::iota_system::SystemState`) at the
71    /// beginning of the epoch, for past epochs, or the current state for the
72    /// current epoch.
73    #[prost(message, optional, tag = "3")]
74    pub bcs_system_state: ::core::option::Option<super::bcs::BcsData>,
75    #[prost(uint64, optional, tag = "4")]
76    pub first_checkpoint: ::core::option::Option<u64>,
77    #[prost(uint64, optional, tag = "5")]
78    pub last_checkpoint: ::core::option::Option<u64>,
79    #[prost(message, optional, tag = "6")]
80    pub start: ::core::option::Option<::prost_types::Timestamp>,
81    #[prost(message, optional, tag = "7")]
82    pub end: ::core::option::Option<::prost_types::Timestamp>,
83    /// Reference gas price denominated in NANOS
84    #[prost(uint64, optional, tag = "8")]
85    pub reference_gas_price: ::core::option::Option<u64>,
86    #[prost(message, optional, tag = "9")]
87    pub protocol_config: ::core::option::Option<ProtocolConfig>,
88}