tendermint_proto/prost/v0_34/
tendermint.privval.rs1#[allow(clippy::derive_partial_eq_without_eq)]
3#[derive(Clone, PartialEq, ::prost::Message)]
4pub struct RemoteSignerError {
5 #[prost(int32, tag = "1")]
6 pub code: i32,
7 #[prost(string, tag = "2")]
8 pub description: ::prost::alloc::string::String,
9}
10#[allow(clippy::derive_partial_eq_without_eq)]
12#[derive(Clone, PartialEq, ::prost::Message)]
13pub struct PubKeyRequest {
14 #[prost(string, tag = "1")]
15 pub chain_id: ::prost::alloc::string::String,
16}
17#[allow(clippy::derive_partial_eq_without_eq)]
19#[derive(Clone, PartialEq, ::prost::Message)]
20pub struct PubKeyResponse {
21 #[prost(message, optional, tag = "1")]
22 pub pub_key: ::core::option::Option<super::crypto::PublicKey>,
23 #[prost(message, optional, tag = "2")]
24 pub error: ::core::option::Option<RemoteSignerError>,
25}
26#[allow(clippy::derive_partial_eq_without_eq)]
28#[derive(Clone, PartialEq, ::prost::Message)]
29pub struct SignVoteRequest {
30 #[prost(message, optional, tag = "1")]
31 pub vote: ::core::option::Option<super::types::Vote>,
32 #[prost(string, tag = "2")]
33 pub chain_id: ::prost::alloc::string::String,
34}
35#[allow(clippy::derive_partial_eq_without_eq)]
37#[derive(Clone, PartialEq, ::prost::Message)]
38pub struct SignedVoteResponse {
39 #[prost(message, optional, tag = "1")]
40 pub vote: ::core::option::Option<super::types::Vote>,
41 #[prost(message, optional, tag = "2")]
42 pub error: ::core::option::Option<RemoteSignerError>,
43}
44#[allow(clippy::derive_partial_eq_without_eq)]
46#[derive(Clone, PartialEq, ::prost::Message)]
47pub struct SignProposalRequest {
48 #[prost(message, optional, tag = "1")]
49 pub proposal: ::core::option::Option<super::types::Proposal>,
50 #[prost(string, tag = "2")]
51 pub chain_id: ::prost::alloc::string::String,
52}
53#[allow(clippy::derive_partial_eq_without_eq)]
55#[derive(Clone, PartialEq, ::prost::Message)]
56pub struct SignedProposalResponse {
57 #[prost(message, optional, tag = "1")]
58 pub proposal: ::core::option::Option<super::types::Proposal>,
59 #[prost(message, optional, tag = "2")]
60 pub error: ::core::option::Option<RemoteSignerError>,
61}
62#[allow(clippy::derive_partial_eq_without_eq)]
64#[derive(Clone, Copy, PartialEq, ::prost::Message)]
65pub struct PingRequest {}
66#[allow(clippy::derive_partial_eq_without_eq)]
68#[derive(Clone, Copy, PartialEq, ::prost::Message)]
69pub struct PingResponse {}
70#[allow(clippy::derive_partial_eq_without_eq)]
71#[derive(Clone, PartialEq, ::prost::Message)]
72pub struct Message {
73 #[prost(oneof = "message::Sum", tags = "1, 2, 3, 4, 5, 6, 7, 8")]
74 pub sum: ::core::option::Option<message::Sum>,
75}
76pub mod message {
78 #[allow(clippy::derive_partial_eq_without_eq)]
79 #[derive(Clone, PartialEq, ::prost::Oneof)]
80 pub enum Sum {
81 #[prost(message, tag = "1")]
82 PubKeyRequest(super::PubKeyRequest),
83 #[prost(message, tag = "2")]
84 PubKeyResponse(super::PubKeyResponse),
85 #[prost(message, tag = "3")]
86 SignVoteRequest(super::SignVoteRequest),
87 #[prost(message, tag = "4")]
88 SignedVoteResponse(super::SignedVoteResponse),
89 #[prost(message, tag = "5")]
90 SignProposalRequest(super::SignProposalRequest),
91 #[prost(message, tag = "6")]
92 SignedProposalResponse(super::SignedProposalResponse),
93 #[prost(message, tag = "7")]
94 PingRequest(super::PingRequest),
95 #[prost(message, tag = "8")]
96 PingResponse(super::PingResponse),
97 }
98}
99#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
100#[repr(i32)]
101pub enum Errors {
102 Unknown = 0,
103 UnexpectedResponse = 1,
104 NoConnection = 2,
105 ConnectionTimeout = 3,
106 ReadTimeout = 4,
107 WriteTimeout = 5,
108}
109impl Errors {
110 pub fn as_str_name(&self) -> &'static str {
115 match self {
116 Errors::Unknown => "ERRORS_UNKNOWN",
117 Errors::UnexpectedResponse => "ERRORS_UNEXPECTED_RESPONSE",
118 Errors::NoConnection => "ERRORS_NO_CONNECTION",
119 Errors::ConnectionTimeout => "ERRORS_CONNECTION_TIMEOUT",
120 Errors::ReadTimeout => "ERRORS_READ_TIMEOUT",
121 Errors::WriteTimeout => "ERRORS_WRITE_TIMEOUT",
122 }
123 }
124 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
126 match value {
127 "ERRORS_UNKNOWN" => Some(Self::Unknown),
128 "ERRORS_UNEXPECTED_RESPONSE" => Some(Self::UnexpectedResponse),
129 "ERRORS_NO_CONNECTION" => Some(Self::NoConnection),
130 "ERRORS_CONNECTION_TIMEOUT" => Some(Self::ConnectionTimeout),
131 "ERRORS_READ_TIMEOUT" => Some(Self::ReadTimeout),
132 "ERRORS_WRITE_TIMEOUT" => Some(Self::WriteTimeout),
133 _ => None,
134 }
135 }
136}