1pub use i_governor_compatibility_bravo::*;
2#[allow(
5 clippy::enum_variant_names,
6 clippy::too_many_arguments,
7 clippy::upper_case_acronyms,
8 clippy::type_complexity,
9 dead_code,
10 non_camel_case_types,
11)]
12pub mod i_governor_compatibility_bravo {
13 #[rustfmt::skip]
14 const __ABI: &str = "[{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"proposalId\",\"type\":\"uint256\",\"components\":[],\"indexed\":false}],\"type\":\"event\",\"name\":\"ProposalCanceled\",\"outputs\":[],\"anonymous\":false},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"proposalId\",\"type\":\"uint256\",\"components\":[],\"indexed\":false},{\"internalType\":\"address\",\"name\":\"proposer\",\"type\":\"address\",\"components\":[],\"indexed\":false},{\"internalType\":\"address[]\",\"name\":\"targets\",\"type\":\"address[]\",\"components\":[],\"indexed\":false},{\"internalType\":\"uint256[]\",\"name\":\"values\",\"type\":\"uint256[]\",\"components\":[],\"indexed\":false},{\"internalType\":\"string[]\",\"name\":\"signatures\",\"type\":\"string[]\",\"components\":[],\"indexed\":false},{\"internalType\":\"bytes[]\",\"name\":\"calldatas\",\"type\":\"bytes[]\",\"components\":[],\"indexed\":false},{\"internalType\":\"uint256\",\"name\":\"voteStart\",\"type\":\"uint256\",\"components\":[],\"indexed\":false},{\"internalType\":\"uint256\",\"name\":\"voteEnd\",\"type\":\"uint256\",\"components\":[],\"indexed\":false},{\"internalType\":\"string\",\"name\":\"description\",\"type\":\"string\",\"components\":[],\"indexed\":false}],\"type\":\"event\",\"name\":\"ProposalCreated\",\"outputs\":[],\"anonymous\":false},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"proposalId\",\"type\":\"uint256\",\"components\":[],\"indexed\":false}],\"type\":\"event\",\"name\":\"ProposalExecuted\",\"outputs\":[],\"anonymous\":false},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"voter\",\"type\":\"address\",\"components\":[],\"indexed\":true},{\"internalType\":\"uint256\",\"name\":\"proposalId\",\"type\":\"uint256\",\"components\":[],\"indexed\":false},{\"internalType\":\"uint8\",\"name\":\"support\",\"type\":\"uint8\",\"components\":[],\"indexed\":false},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\",\"components\":[],\"indexed\":false},{\"internalType\":\"string\",\"name\":\"reason\",\"type\":\"string\",\"components\":[],\"indexed\":false}],\"type\":\"event\",\"name\":\"VoteCast\",\"outputs\":[],\"anonymous\":false},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"voter\",\"type\":\"address\",\"components\":[],\"indexed\":true},{\"internalType\":\"uint256\",\"name\":\"proposalId\",\"type\":\"uint256\",\"components\":[],\"indexed\":false},{\"internalType\":\"uint8\",\"name\":\"support\",\"type\":\"uint8\",\"components\":[],\"indexed\":false},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\",\"components\":[],\"indexed\":false},{\"internalType\":\"string\",\"name\":\"reason\",\"type\":\"string\",\"components\":[],\"indexed\":false},{\"internalType\":\"bytes\",\"name\":\"params\",\"type\":\"bytes\",\"components\":[],\"indexed\":false}],\"type\":\"event\",\"name\":\"VoteCastWithParams\",\"outputs\":[],\"anonymous\":false},{\"inputs\":[],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"CLOCK_MODE\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\",\"components\":[]}]},{\"inputs\":[],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"COUNTING_MODE\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"proposalId\",\"type\":\"uint256\",\"components\":[]}],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"cancel\",\"outputs\":[]},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"targets\",\"type\":\"address[]\",\"components\":[]},{\"internalType\":\"uint256[]\",\"name\":\"values\",\"type\":\"uint256[]\",\"components\":[]},{\"internalType\":\"bytes[]\",\"name\":\"calldatas\",\"type\":\"bytes[]\",\"components\":[]},{\"internalType\":\"bytes32\",\"name\":\"descriptionHash\",\"type\":\"bytes32\",\"components\":[]}],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"cancel\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"proposalId\",\"type\":\"uint256\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"proposalId\",\"type\":\"uint256\",\"components\":[]},{\"internalType\":\"uint8\",\"name\":\"support\",\"type\":\"uint8\",\"components\":[]}],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"castVote\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"balance\",\"type\":\"uint256\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"proposalId\",\"type\":\"uint256\",\"components\":[]},{\"internalType\":\"uint8\",\"name\":\"support\",\"type\":\"uint8\",\"components\":[]},{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\",\"components\":[]},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\",\"components\":[]},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\",\"components\":[]}],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"castVoteBySig\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"balance\",\"type\":\"uint256\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"proposalId\",\"type\":\"uint256\",\"components\":[]},{\"internalType\":\"uint8\",\"name\":\"support\",\"type\":\"uint8\",\"components\":[]},{\"internalType\":\"string\",\"name\":\"reason\",\"type\":\"string\",\"components\":[]}],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"castVoteWithReason\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"balance\",\"type\":\"uint256\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"proposalId\",\"type\":\"uint256\",\"components\":[]},{\"internalType\":\"uint8\",\"name\":\"support\",\"type\":\"uint8\",\"components\":[]},{\"internalType\":\"string\",\"name\":\"reason\",\"type\":\"string\",\"components\":[]},{\"internalType\":\"bytes\",\"name\":\"params\",\"type\":\"bytes\",\"components\":[]}],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"castVoteWithReasonAndParams\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"balance\",\"type\":\"uint256\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"proposalId\",\"type\":\"uint256\",\"components\":[]},{\"internalType\":\"uint8\",\"name\":\"support\",\"type\":\"uint8\",\"components\":[]},{\"internalType\":\"string\",\"name\":\"reason\",\"type\":\"string\",\"components\":[]},{\"internalType\":\"bytes\",\"name\":\"params\",\"type\":\"bytes\",\"components\":[]},{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\",\"components\":[]},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\",\"components\":[]},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\",\"components\":[]}],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"castVoteWithReasonAndParamsBySig\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"balance\",\"type\":\"uint256\",\"components\":[]}]},{\"inputs\":[],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"clock\",\"outputs\":[{\"internalType\":\"uint48\",\"name\":\"\",\"type\":\"uint48\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"targets\",\"type\":\"address[]\",\"components\":[]},{\"internalType\":\"uint256[]\",\"name\":\"values\",\"type\":\"uint256[]\",\"components\":[]},{\"internalType\":\"bytes[]\",\"name\":\"calldatas\",\"type\":\"bytes[]\",\"components\":[]},{\"internalType\":\"bytes32\",\"name\":\"descriptionHash\",\"type\":\"bytes32\",\"components\":[]}],\"stateMutability\":\"payable\",\"type\":\"function\",\"name\":\"execute\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"proposalId\",\"type\":\"uint256\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"proposalId\",\"type\":\"uint256\",\"components\":[]}],\"stateMutability\":\"payable\",\"type\":\"function\",\"name\":\"execute\",\"outputs\":[]},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"proposalId\",\"type\":\"uint256\",\"components\":[]}],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"getActions\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"targets\",\"type\":\"address[]\",\"components\":[]},{\"internalType\":\"uint256[]\",\"name\":\"values\",\"type\":\"uint256[]\",\"components\":[]},{\"internalType\":\"string[]\",\"name\":\"signatures\",\"type\":\"string[]\",\"components\":[]},{\"internalType\":\"bytes[]\",\"name\":\"calldatas\",\"type\":\"bytes[]\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"proposalId\",\"type\":\"uint256\",\"components\":[]},{\"internalType\":\"address\",\"name\":\"voter\",\"type\":\"address\",\"components\":[]}],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"getReceipt\",\"outputs\":[{\"internalType\":\"struct IGovernorCompatibilityBravo.Receipt\",\"name\":\"\",\"type\":\"tuple\",\"components\":[{\"internalType\":\"bool\",\"name\":\"hasVoted\",\"type\":\"bool\",\"components\":[]},{\"internalType\":\"uint8\",\"name\":\"support\",\"type\":\"uint8\",\"components\":[]},{\"internalType\":\"uint96\",\"name\":\"votes\",\"type\":\"uint96\",\"components\":[]}]}]},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\",\"components\":[]},{\"internalType\":\"uint256\",\"name\":\"timepoint\",\"type\":\"uint256\",\"components\":[]}],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"getVotes\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\",\"components\":[]},{\"internalType\":\"uint256\",\"name\":\"timepoint\",\"type\":\"uint256\",\"components\":[]},{\"internalType\":\"bytes\",\"name\":\"params\",\"type\":\"bytes\",\"components\":[]}],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"getVotesWithParams\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"proposalId\",\"type\":\"uint256\",\"components\":[]},{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\",\"components\":[]}],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"hasVoted\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"targets\",\"type\":\"address[]\",\"components\":[]},{\"internalType\":\"uint256[]\",\"name\":\"values\",\"type\":\"uint256[]\",\"components\":[]},{\"internalType\":\"bytes[]\",\"name\":\"calldatas\",\"type\":\"bytes[]\",\"components\":[]},{\"internalType\":\"bytes32\",\"name\":\"descriptionHash\",\"type\":\"bytes32\",\"components\":[]}],\"stateMutability\":\"pure\",\"type\":\"function\",\"name\":\"hashProposal\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\",\"components\":[]}]},{\"inputs\":[],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"name\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"proposalId\",\"type\":\"uint256\",\"components\":[]}],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"proposalDeadline\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"proposalId\",\"type\":\"uint256\",\"components\":[]}],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"proposalProposer\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"proposalId\",\"type\":\"uint256\",\"components\":[]}],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"proposalSnapshot\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\",\"components\":[]}],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"proposals\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\",\"components\":[]},{\"internalType\":\"address\",\"name\":\"proposer\",\"type\":\"address\",\"components\":[]},{\"internalType\":\"uint256\",\"name\":\"eta\",\"type\":\"uint256\",\"components\":[]},{\"internalType\":\"uint256\",\"name\":\"startBlock\",\"type\":\"uint256\",\"components\":[]},{\"internalType\":\"uint256\",\"name\":\"endBlock\",\"type\":\"uint256\",\"components\":[]},{\"internalType\":\"uint256\",\"name\":\"forVotes\",\"type\":\"uint256\",\"components\":[]},{\"internalType\":\"uint256\",\"name\":\"againstVotes\",\"type\":\"uint256\",\"components\":[]},{\"internalType\":\"uint256\",\"name\":\"abstainVotes\",\"type\":\"uint256\",\"components\":[]},{\"internalType\":\"bool\",\"name\":\"canceled\",\"type\":\"bool\",\"components\":[]},{\"internalType\":\"bool\",\"name\":\"executed\",\"type\":\"bool\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"targets\",\"type\":\"address[]\",\"components\":[]},{\"internalType\":\"uint256[]\",\"name\":\"values\",\"type\":\"uint256[]\",\"components\":[]},{\"internalType\":\"bytes[]\",\"name\":\"calldatas\",\"type\":\"bytes[]\",\"components\":[]},{\"internalType\":\"string\",\"name\":\"description\",\"type\":\"string\",\"components\":[]}],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"propose\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"proposalId\",\"type\":\"uint256\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"targets\",\"type\":\"address[]\",\"components\":[]},{\"internalType\":\"uint256[]\",\"name\":\"values\",\"type\":\"uint256[]\",\"components\":[]},{\"internalType\":\"string[]\",\"name\":\"signatures\",\"type\":\"string[]\",\"components\":[]},{\"internalType\":\"bytes[]\",\"name\":\"calldatas\",\"type\":\"bytes[]\",\"components\":[]},{\"internalType\":\"string\",\"name\":\"description\",\"type\":\"string\",\"components\":[]}],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"propose\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"proposalId\",\"type\":\"uint256\",\"components\":[]}],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"queue\",\"outputs\":[]},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"timepoint\",\"type\":\"uint256\",\"components\":[]}],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"quorum\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\",\"components\":[]}]},{\"inputs\":[],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"quorumVotes\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"proposalId\",\"type\":\"uint256\",\"components\":[]}],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"state\",\"outputs\":[{\"internalType\":\"enum IGovernor.ProposalState\",\"name\":\"\",\"type\":\"uint8\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"interfaceId\",\"type\":\"bytes4\",\"components\":[]}],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\",\"components\":[]}]},{\"inputs\":[],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\",\"components\":[]}]},{\"inputs\":[],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"votingDelay\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\",\"components\":[]}]},{\"inputs\":[],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"votingPeriod\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\",\"components\":[]}]}]";
15 pub static IGOVERNORCOMPATIBILITYBRAVO_ABI: ::ethers_contract::Lazy<
17 ::ethers_core::abi::Abi,
18 > = ::ethers_contract::Lazy::new(|| {
19 ::ethers_core::utils::__serde_json::from_str(__ABI).expect("ABI is always valid")
20 });
21 pub struct IGovernorCompatibilityBravo<M>(::ethers_contract::Contract<M>);
22 impl<M> ::core::clone::Clone for IGovernorCompatibilityBravo<M> {
23 fn clone(&self) -> Self {
24 Self(::core::clone::Clone::clone(&self.0))
25 }
26 }
27 impl<M> ::core::ops::Deref for IGovernorCompatibilityBravo<M> {
28 type Target = ::ethers_contract::Contract<M>;
29 fn deref(&self) -> &Self::Target {
30 &self.0
31 }
32 }
33 impl<M> ::core::ops::DerefMut for IGovernorCompatibilityBravo<M> {
34 fn deref_mut(&mut self) -> &mut Self::Target {
35 &mut self.0
36 }
37 }
38 impl<M> ::core::fmt::Debug for IGovernorCompatibilityBravo<M> {
39 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
40 f.debug_tuple(stringify!(IGovernorCompatibilityBravo))
41 .field(&self.address())
42 .finish()
43 }
44 }
45 impl<M: ::ethers_providers::Middleware> IGovernorCompatibilityBravo<M> {
46 pub fn new<T: Into<::ethers_core::types::Address>>(
49 address: T,
50 client: ::std::sync::Arc<M>,
51 ) -> Self {
52 Self(
53 ::ethers_contract::Contract::new(
54 address.into(),
55 IGOVERNORCOMPATIBILITYBRAVO_ABI.clone(),
56 client,
57 ),
58 )
59 }
60 pub fn clock_mode(
62 &self,
63 ) -> ::ethers_contract::builders::ContractCall<M, ::std::string::String> {
64 self.0
65 .method_hash([75, 245, 215, 233], ())
66 .expect("method not found (this should never happen)")
67 }
68 pub fn counting_mode(
70 &self,
71 ) -> ::ethers_contract::builders::ContractCall<M, ::std::string::String> {
72 self.0
73 .method_hash([221, 78, 43, 165], ())
74 .expect("method not found (this should never happen)")
75 }
76 pub fn cancel(
78 &self,
79 proposal_id: ::ethers_core::types::U256,
80 ) -> ::ethers_contract::builders::ContractCall<M, ()> {
81 self.0
82 .method_hash([64, 229, 142, 229], proposal_id)
83 .expect("method not found (this should never happen)")
84 }
85 pub fn cancel_with_targets(
87 &self,
88 targets: ::std::vec::Vec<::ethers_core::types::Address>,
89 values: ::std::vec::Vec<::ethers_core::types::U256>,
90 calldatas: ::std::vec::Vec<::ethers_core::types::Bytes>,
91 description_hash: [u8; 32],
92 ) -> ::ethers_contract::builders::ContractCall<M, ::ethers_core::types::U256> {
93 self.0
94 .method_hash(
95 [69, 33, 21, 214],
96 (targets, values, calldatas, description_hash),
97 )
98 .expect("method not found (this should never happen)")
99 }
100 pub fn cast_vote(
102 &self,
103 proposal_id: ::ethers_core::types::U256,
104 support: u8,
105 ) -> ::ethers_contract::builders::ContractCall<M, ::ethers_core::types::U256> {
106 self.0
107 .method_hash([86, 120, 19, 136], (proposal_id, support))
108 .expect("method not found (this should never happen)")
109 }
110 pub fn cast_vote_by_sig(
112 &self,
113 proposal_id: ::ethers_core::types::U256,
114 support: u8,
115 v: u8,
116 r: [u8; 32],
117 s: [u8; 32],
118 ) -> ::ethers_contract::builders::ContractCall<M, ::ethers_core::types::U256> {
119 self.0
120 .method_hash([59, 204, 244, 253], (proposal_id, support, v, r, s))
121 .expect("method not found (this should never happen)")
122 }
123 pub fn cast_vote_with_reason(
125 &self,
126 proposal_id: ::ethers_core::types::U256,
127 support: u8,
128 reason: ::std::string::String,
129 ) -> ::ethers_contract::builders::ContractCall<M, ::ethers_core::types::U256> {
130 self.0
131 .method_hash([123, 60, 113, 211], (proposal_id, support, reason))
132 .expect("method not found (this should never happen)")
133 }
134 pub fn cast_vote_with_reason_and_params(
136 &self,
137 proposal_id: ::ethers_core::types::U256,
138 support: u8,
139 reason: ::std::string::String,
140 params: ::ethers_core::types::Bytes,
141 ) -> ::ethers_contract::builders::ContractCall<M, ::ethers_core::types::U256> {
142 self.0
143 .method_hash([95, 57, 138, 20], (proposal_id, support, reason, params))
144 .expect("method not found (this should never happen)")
145 }
146 pub fn cast_vote_with_reason_and_params_by_sig(
148 &self,
149 proposal_id: ::ethers_core::types::U256,
150 support: u8,
151 reason: ::std::string::String,
152 params: ::ethers_core::types::Bytes,
153 v: u8,
154 r: [u8; 32],
155 s: [u8; 32],
156 ) -> ::ethers_contract::builders::ContractCall<M, ::ethers_core::types::U256> {
157 self.0
158 .method_hash(
159 [3, 66, 1, 129],
160 (proposal_id, support, reason, params, v, r, s),
161 )
162 .expect("method not found (this should never happen)")
163 }
164 pub fn clock(&self) -> ::ethers_contract::builders::ContractCall<M, u64> {
166 self.0
167 .method_hash([145, 221, 173, 244], ())
168 .expect("method not found (this should never happen)")
169 }
170 pub fn execute_with_targets(
172 &self,
173 targets: ::std::vec::Vec<::ethers_core::types::Address>,
174 values: ::std::vec::Vec<::ethers_core::types::U256>,
175 calldatas: ::std::vec::Vec<::ethers_core::types::Bytes>,
176 description_hash: [u8; 32],
177 ) -> ::ethers_contract::builders::ContractCall<M, ::ethers_core::types::U256> {
178 self.0
179 .method_hash(
180 [38, 86, 34, 125],
181 (targets, values, calldatas, description_hash),
182 )
183 .expect("method not found (this should never happen)")
184 }
185 pub fn execute(
187 &self,
188 proposal_id: ::ethers_core::types::U256,
189 ) -> ::ethers_contract::builders::ContractCall<M, ()> {
190 self.0
191 .method_hash([254, 13, 148, 193], proposal_id)
192 .expect("method not found (this should never happen)")
193 }
194 pub fn get_actions(
196 &self,
197 proposal_id: ::ethers_core::types::U256,
198 ) -> ::ethers_contract::builders::ContractCall<
199 M,
200 (
201 ::std::vec::Vec<::ethers_core::types::Address>,
202 ::std::vec::Vec<::ethers_core::types::U256>,
203 ::std::vec::Vec<::std::string::String>,
204 ::std::vec::Vec<::ethers_core::types::Bytes>,
205 ),
206 > {
207 self.0
208 .method_hash([50, 141, 217, 130], proposal_id)
209 .expect("method not found (this should never happen)")
210 }
211 pub fn get_receipt(
213 &self,
214 proposal_id: ::ethers_core::types::U256,
215 voter: ::ethers_core::types::Address,
216 ) -> ::ethers_contract::builders::ContractCall<M, Receipt> {
217 self.0
218 .method_hash([226, 58, 154, 82], (proposal_id, voter))
219 .expect("method not found (this should never happen)")
220 }
221 pub fn get_votes(
223 &self,
224 account: ::ethers_core::types::Address,
225 timepoint: ::ethers_core::types::U256,
226 ) -> ::ethers_contract::builders::ContractCall<M, ::ethers_core::types::U256> {
227 self.0
228 .method_hash([235, 144, 25, 212], (account, timepoint))
229 .expect("method not found (this should never happen)")
230 }
231 pub fn get_votes_with_params(
233 &self,
234 account: ::ethers_core::types::Address,
235 timepoint: ::ethers_core::types::U256,
236 params: ::ethers_core::types::Bytes,
237 ) -> ::ethers_contract::builders::ContractCall<M, ::ethers_core::types::U256> {
238 self.0
239 .method_hash([154, 128, 42, 109], (account, timepoint, params))
240 .expect("method not found (this should never happen)")
241 }
242 pub fn has_voted(
244 &self,
245 proposal_id: ::ethers_core::types::U256,
246 account: ::ethers_core::types::Address,
247 ) -> ::ethers_contract::builders::ContractCall<M, bool> {
248 self.0
249 .method_hash([67, 133, 150, 50], (proposal_id, account))
250 .expect("method not found (this should never happen)")
251 }
252 pub fn hash_proposal(
254 &self,
255 targets: ::std::vec::Vec<::ethers_core::types::Address>,
256 values: ::std::vec::Vec<::ethers_core::types::U256>,
257 calldatas: ::std::vec::Vec<::ethers_core::types::Bytes>,
258 description_hash: [u8; 32],
259 ) -> ::ethers_contract::builders::ContractCall<M, ::ethers_core::types::U256> {
260 self.0
261 .method_hash(
262 [197, 144, 87, 228],
263 (targets, values, calldatas, description_hash),
264 )
265 .expect("method not found (this should never happen)")
266 }
267 pub fn name(
269 &self,
270 ) -> ::ethers_contract::builders::ContractCall<M, ::std::string::String> {
271 self.0
272 .method_hash([6, 253, 222, 3], ())
273 .expect("method not found (this should never happen)")
274 }
275 pub fn proposal_deadline(
277 &self,
278 proposal_id: ::ethers_core::types::U256,
279 ) -> ::ethers_contract::builders::ContractCall<M, ::ethers_core::types::U256> {
280 self.0
281 .method_hash([192, 31, 158, 55], proposal_id)
282 .expect("method not found (this should never happen)")
283 }
284 pub fn proposal_proposer(
286 &self,
287 proposal_id: ::ethers_core::types::U256,
288 ) -> ::ethers_contract::builders::ContractCall<
289 M,
290 ::ethers_core::types::Address,
291 > {
292 self.0
293 .method_hash([20, 52, 137, 208], proposal_id)
294 .expect("method not found (this should never happen)")
295 }
296 pub fn proposal_snapshot(
298 &self,
299 proposal_id: ::ethers_core::types::U256,
300 ) -> ::ethers_contract::builders::ContractCall<M, ::ethers_core::types::U256> {
301 self.0
302 .method_hash([45, 99, 246, 147], proposal_id)
303 .expect("method not found (this should never happen)")
304 }
305 pub fn proposals(
307 &self,
308 p0: ::ethers_core::types::U256,
309 ) -> ::ethers_contract::builders::ContractCall<
310 M,
311 (
312 ::ethers_core::types::U256,
313 ::ethers_core::types::Address,
314 ::ethers_core::types::U256,
315 ::ethers_core::types::U256,
316 ::ethers_core::types::U256,
317 ::ethers_core::types::U256,
318 ::ethers_core::types::U256,
319 ::ethers_core::types::U256,
320 bool,
321 bool,
322 ),
323 > {
324 self.0
325 .method_hash([1, 60, 240, 139], p0)
326 .expect("method not found (this should never happen)")
327 }
328 pub fn propose(
330 &self,
331 targets: ::std::vec::Vec<::ethers_core::types::Address>,
332 values: ::std::vec::Vec<::ethers_core::types::U256>,
333 calldatas: ::std::vec::Vec<::ethers_core::types::Bytes>,
334 description: ::std::string::String,
335 ) -> ::ethers_contract::builders::ContractCall<M, ::ethers_core::types::U256> {
336 self.0
337 .method_hash(
338 [125, 94, 129, 226],
339 (targets, values, calldatas, description),
340 )
341 .expect("method not found (this should never happen)")
342 }
343 pub fn propose_with_targets_and_values_and_signatures_and_calldatas(
345 &self,
346 targets: ::std::vec::Vec<::ethers_core::types::Address>,
347 values: ::std::vec::Vec<::ethers_core::types::U256>,
348 signatures: ::std::vec::Vec<::std::string::String>,
349 calldatas: ::std::vec::Vec<::ethers_core::types::Bytes>,
350 description: ::std::string::String,
351 ) -> ::ethers_contract::builders::ContractCall<M, ::ethers_core::types::U256> {
352 self.0
353 .method_hash(
354 [218, 149, 105, 26],
355 (targets, values, signatures, calldatas, description),
356 )
357 .expect("method not found (this should never happen)")
358 }
359 pub fn queue(
361 &self,
362 proposal_id: ::ethers_core::types::U256,
363 ) -> ::ethers_contract::builders::ContractCall<M, ()> {
364 self.0
365 .method_hash([221, 240, 176, 9], proposal_id)
366 .expect("method not found (this should never happen)")
367 }
368 pub fn quorum(
370 &self,
371 timepoint: ::ethers_core::types::U256,
372 ) -> ::ethers_contract::builders::ContractCall<M, ::ethers_core::types::U256> {
373 self.0
374 .method_hash([248, 206, 86, 10], timepoint)
375 .expect("method not found (this should never happen)")
376 }
377 pub fn quorum_votes(
379 &self,
380 ) -> ::ethers_contract::builders::ContractCall<M, ::ethers_core::types::U256> {
381 self.0
382 .method_hash([36, 188, 26, 100], ())
383 .expect("method not found (this should never happen)")
384 }
385 pub fn state(
387 &self,
388 proposal_id: ::ethers_core::types::U256,
389 ) -> ::ethers_contract::builders::ContractCall<M, u8> {
390 self.0
391 .method_hash([62, 79, 73, 230], proposal_id)
392 .expect("method not found (this should never happen)")
393 }
394 pub fn supports_interface(
396 &self,
397 interface_id: [u8; 4],
398 ) -> ::ethers_contract::builders::ContractCall<M, bool> {
399 self.0
400 .method_hash([1, 255, 201, 167], interface_id)
401 .expect("method not found (this should never happen)")
402 }
403 pub fn version(
405 &self,
406 ) -> ::ethers_contract::builders::ContractCall<M, ::std::string::String> {
407 self.0
408 .method_hash([84, 253, 77, 80], ())
409 .expect("method not found (this should never happen)")
410 }
411 pub fn voting_delay(
413 &self,
414 ) -> ::ethers_contract::builders::ContractCall<M, ::ethers_core::types::U256> {
415 self.0
416 .method_hash([57, 50, 171, 177], ())
417 .expect("method not found (this should never happen)")
418 }
419 pub fn voting_period(
421 &self,
422 ) -> ::ethers_contract::builders::ContractCall<M, ::ethers_core::types::U256> {
423 self.0
424 .method_hash([2, 162, 81, 163], ())
425 .expect("method not found (this should never happen)")
426 }
427 pub fn proposal_canceled_filter(
429 &self,
430 ) -> ::ethers_contract::builders::Event<
431 ::std::sync::Arc<M>,
432 M,
433 ProposalCanceledFilter,
434 > {
435 self.0.event()
436 }
437 pub fn proposal_created_filter(
439 &self,
440 ) -> ::ethers_contract::builders::Event<
441 ::std::sync::Arc<M>,
442 M,
443 ProposalCreatedFilter,
444 > {
445 self.0.event()
446 }
447 pub fn proposal_executed_filter(
449 &self,
450 ) -> ::ethers_contract::builders::Event<
451 ::std::sync::Arc<M>,
452 M,
453 ProposalExecutedFilter,
454 > {
455 self.0.event()
456 }
457 pub fn vote_cast_filter(
459 &self,
460 ) -> ::ethers_contract::builders::Event<::std::sync::Arc<M>, M, VoteCastFilter> {
461 self.0.event()
462 }
463 pub fn vote_cast_with_params_filter(
465 &self,
466 ) -> ::ethers_contract::builders::Event<
467 ::std::sync::Arc<M>,
468 M,
469 VoteCastWithParamsFilter,
470 > {
471 self.0.event()
472 }
473 pub fn events(
475 &self,
476 ) -> ::ethers_contract::builders::Event<
477 ::std::sync::Arc<M>,
478 M,
479 IGovernorCompatibilityBravoEvents,
480 > {
481 self.0.event_with_filter(::core::default::Default::default())
482 }
483 }
484 impl<M: ::ethers_providers::Middleware> From<::ethers_contract::Contract<M>>
485 for IGovernorCompatibilityBravo<M> {
486 fn from(contract: ::ethers_contract::Contract<M>) -> Self {
487 Self::new(contract.address(), contract.client())
488 }
489 }
490 #[derive(
491 Clone,
492 ::ethers_contract::EthEvent,
493 ::ethers_contract::EthDisplay,
494 Default,
495 Debug,
496 PartialEq,
497 Eq,
498 Hash
499 )]
500 #[ethevent(name = "ProposalCanceled", abi = "ProposalCanceled(uint256)")]
501 pub struct ProposalCanceledFilter {
502 pub proposal_id: ::ethers_core::types::U256,
503 }
504 #[derive(
505 Clone,
506 ::ethers_contract::EthEvent,
507 ::ethers_contract::EthDisplay,
508 Default,
509 Debug,
510 PartialEq,
511 Eq,
512 Hash
513 )]
514 #[ethevent(
515 name = "ProposalCreated",
516 abi = "ProposalCreated(uint256,address,address[],uint256[],string[],bytes[],uint256,uint256,string)"
517 )]
518 pub struct ProposalCreatedFilter {
519 pub proposal_id: ::ethers_core::types::U256,
520 pub proposer: ::ethers_core::types::Address,
521 pub targets: ::std::vec::Vec<::ethers_core::types::Address>,
522 pub values: ::std::vec::Vec<::ethers_core::types::U256>,
523 pub signatures: ::std::vec::Vec<::std::string::String>,
524 pub calldatas: ::std::vec::Vec<::ethers_core::types::Bytes>,
525 pub vote_start: ::ethers_core::types::U256,
526 pub vote_end: ::ethers_core::types::U256,
527 pub description: ::std::string::String,
528 }
529 #[derive(
530 Clone,
531 ::ethers_contract::EthEvent,
532 ::ethers_contract::EthDisplay,
533 Default,
534 Debug,
535 PartialEq,
536 Eq,
537 Hash
538 )]
539 #[ethevent(name = "ProposalExecuted", abi = "ProposalExecuted(uint256)")]
540 pub struct ProposalExecutedFilter {
541 pub proposal_id: ::ethers_core::types::U256,
542 }
543 #[derive(
544 Clone,
545 ::ethers_contract::EthEvent,
546 ::ethers_contract::EthDisplay,
547 Default,
548 Debug,
549 PartialEq,
550 Eq,
551 Hash
552 )]
553 #[ethevent(
554 name = "VoteCast",
555 abi = "VoteCast(address,uint256,uint8,uint256,string)"
556 )]
557 pub struct VoteCastFilter {
558 #[ethevent(indexed)]
559 pub voter: ::ethers_core::types::Address,
560 pub proposal_id: ::ethers_core::types::U256,
561 pub support: u8,
562 pub weight: ::ethers_core::types::U256,
563 pub reason: ::std::string::String,
564 }
565 #[derive(
566 Clone,
567 ::ethers_contract::EthEvent,
568 ::ethers_contract::EthDisplay,
569 Default,
570 Debug,
571 PartialEq,
572 Eq,
573 Hash
574 )]
575 #[ethevent(
576 name = "VoteCastWithParams",
577 abi = "VoteCastWithParams(address,uint256,uint8,uint256,string,bytes)"
578 )]
579 pub struct VoteCastWithParamsFilter {
580 #[ethevent(indexed)]
581 pub voter: ::ethers_core::types::Address,
582 pub proposal_id: ::ethers_core::types::U256,
583 pub support: u8,
584 pub weight: ::ethers_core::types::U256,
585 pub reason: ::std::string::String,
586 pub params: ::ethers_core::types::Bytes,
587 }
588 #[derive(Clone, ::ethers_contract::EthAbiType, Debug, PartialEq, Eq, Hash)]
590 pub enum IGovernorCompatibilityBravoEvents {
591 ProposalCanceledFilter(ProposalCanceledFilter),
592 ProposalCreatedFilter(ProposalCreatedFilter),
593 ProposalExecutedFilter(ProposalExecutedFilter),
594 VoteCastFilter(VoteCastFilter),
595 VoteCastWithParamsFilter(VoteCastWithParamsFilter),
596 }
597 impl ::ethers_contract::EthLogDecode for IGovernorCompatibilityBravoEvents {
598 fn decode_log(
599 log: &::ethers_core::abi::RawLog,
600 ) -> ::core::result::Result<Self, ::ethers_core::abi::Error> {
601 if let Ok(decoded) = ProposalCanceledFilter::decode_log(log) {
602 return Ok(
603 IGovernorCompatibilityBravoEvents::ProposalCanceledFilter(decoded),
604 );
605 }
606 if let Ok(decoded) = ProposalCreatedFilter::decode_log(log) {
607 return Ok(
608 IGovernorCompatibilityBravoEvents::ProposalCreatedFilter(decoded),
609 );
610 }
611 if let Ok(decoded) = ProposalExecutedFilter::decode_log(log) {
612 return Ok(
613 IGovernorCompatibilityBravoEvents::ProposalExecutedFilter(decoded),
614 );
615 }
616 if let Ok(decoded) = VoteCastFilter::decode_log(log) {
617 return Ok(IGovernorCompatibilityBravoEvents::VoteCastFilter(decoded));
618 }
619 if let Ok(decoded) = VoteCastWithParamsFilter::decode_log(log) {
620 return Ok(
621 IGovernorCompatibilityBravoEvents::VoteCastWithParamsFilter(decoded),
622 );
623 }
624 Err(::ethers_core::abi::Error::InvalidData)
625 }
626 }
627 impl ::core::fmt::Display for IGovernorCompatibilityBravoEvents {
628 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
629 match self {
630 Self::ProposalCanceledFilter(element) => {
631 ::core::fmt::Display::fmt(element, f)
632 }
633 Self::ProposalCreatedFilter(element) => {
634 ::core::fmt::Display::fmt(element, f)
635 }
636 Self::ProposalExecutedFilter(element) => {
637 ::core::fmt::Display::fmt(element, f)
638 }
639 Self::VoteCastFilter(element) => ::core::fmt::Display::fmt(element, f),
640 Self::VoteCastWithParamsFilter(element) => {
641 ::core::fmt::Display::fmt(element, f)
642 }
643 }
644 }
645 }
646 impl ::core::convert::From<ProposalCanceledFilter>
647 for IGovernorCompatibilityBravoEvents {
648 fn from(value: ProposalCanceledFilter) -> Self {
649 Self::ProposalCanceledFilter(value)
650 }
651 }
652 impl ::core::convert::From<ProposalCreatedFilter>
653 for IGovernorCompatibilityBravoEvents {
654 fn from(value: ProposalCreatedFilter) -> Self {
655 Self::ProposalCreatedFilter(value)
656 }
657 }
658 impl ::core::convert::From<ProposalExecutedFilter>
659 for IGovernorCompatibilityBravoEvents {
660 fn from(value: ProposalExecutedFilter) -> Self {
661 Self::ProposalExecutedFilter(value)
662 }
663 }
664 impl ::core::convert::From<VoteCastFilter> for IGovernorCompatibilityBravoEvents {
665 fn from(value: VoteCastFilter) -> Self {
666 Self::VoteCastFilter(value)
667 }
668 }
669 impl ::core::convert::From<VoteCastWithParamsFilter>
670 for IGovernorCompatibilityBravoEvents {
671 fn from(value: VoteCastWithParamsFilter) -> Self {
672 Self::VoteCastWithParamsFilter(value)
673 }
674 }
675 #[derive(
677 Clone,
678 ::ethers_contract::EthCall,
679 ::ethers_contract::EthDisplay,
680 Default,
681 Debug,
682 PartialEq,
683 Eq,
684 Hash
685 )]
686 #[ethcall(name = "CLOCK_MODE", abi = "CLOCK_MODE()")]
687 pub struct ClockModeCall;
688 #[derive(
690 Clone,
691 ::ethers_contract::EthCall,
692 ::ethers_contract::EthDisplay,
693 Default,
694 Debug,
695 PartialEq,
696 Eq,
697 Hash
698 )]
699 #[ethcall(name = "COUNTING_MODE", abi = "COUNTING_MODE()")]
700 pub struct CountingModeCall;
701 #[derive(
703 Clone,
704 ::ethers_contract::EthCall,
705 ::ethers_contract::EthDisplay,
706 Default,
707 Debug,
708 PartialEq,
709 Eq,
710 Hash
711 )]
712 #[ethcall(name = "cancel", abi = "cancel(uint256)")]
713 pub struct CancelCall {
714 pub proposal_id: ::ethers_core::types::U256,
715 }
716 #[derive(
718 Clone,
719 ::ethers_contract::EthCall,
720 ::ethers_contract::EthDisplay,
721 Default,
722 Debug,
723 PartialEq,
724 Eq,
725 Hash
726 )]
727 #[ethcall(name = "cancel", abi = "cancel(address[],uint256[],bytes[],bytes32)")]
728 pub struct CancelWithTargetsCall {
729 pub targets: ::std::vec::Vec<::ethers_core::types::Address>,
730 pub values: ::std::vec::Vec<::ethers_core::types::U256>,
731 pub calldatas: ::std::vec::Vec<::ethers_core::types::Bytes>,
732 pub description_hash: [u8; 32],
733 }
734 #[derive(
736 Clone,
737 ::ethers_contract::EthCall,
738 ::ethers_contract::EthDisplay,
739 Default,
740 Debug,
741 PartialEq,
742 Eq,
743 Hash
744 )]
745 #[ethcall(name = "castVote", abi = "castVote(uint256,uint8)")]
746 pub struct CastVoteCall {
747 pub proposal_id: ::ethers_core::types::U256,
748 pub support: u8,
749 }
750 #[derive(
752 Clone,
753 ::ethers_contract::EthCall,
754 ::ethers_contract::EthDisplay,
755 Default,
756 Debug,
757 PartialEq,
758 Eq,
759 Hash
760 )]
761 #[ethcall(
762 name = "castVoteBySig",
763 abi = "castVoteBySig(uint256,uint8,uint8,bytes32,bytes32)"
764 )]
765 pub struct CastVoteBySigCall {
766 pub proposal_id: ::ethers_core::types::U256,
767 pub support: u8,
768 pub v: u8,
769 pub r: [u8; 32],
770 pub s: [u8; 32],
771 }
772 #[derive(
774 Clone,
775 ::ethers_contract::EthCall,
776 ::ethers_contract::EthDisplay,
777 Default,
778 Debug,
779 PartialEq,
780 Eq,
781 Hash
782 )]
783 #[ethcall(
784 name = "castVoteWithReason",
785 abi = "castVoteWithReason(uint256,uint8,string)"
786 )]
787 pub struct CastVoteWithReasonCall {
788 pub proposal_id: ::ethers_core::types::U256,
789 pub support: u8,
790 pub reason: ::std::string::String,
791 }
792 #[derive(
794 Clone,
795 ::ethers_contract::EthCall,
796 ::ethers_contract::EthDisplay,
797 Default,
798 Debug,
799 PartialEq,
800 Eq,
801 Hash
802 )]
803 #[ethcall(
804 name = "castVoteWithReasonAndParams",
805 abi = "castVoteWithReasonAndParams(uint256,uint8,string,bytes)"
806 )]
807 pub struct CastVoteWithReasonAndParamsCall {
808 pub proposal_id: ::ethers_core::types::U256,
809 pub support: u8,
810 pub reason: ::std::string::String,
811 pub params: ::ethers_core::types::Bytes,
812 }
813 #[derive(
815 Clone,
816 ::ethers_contract::EthCall,
817 ::ethers_contract::EthDisplay,
818 Default,
819 Debug,
820 PartialEq,
821 Eq,
822 Hash
823 )]
824 #[ethcall(
825 name = "castVoteWithReasonAndParamsBySig",
826 abi = "castVoteWithReasonAndParamsBySig(uint256,uint8,string,bytes,uint8,bytes32,bytes32)"
827 )]
828 pub struct CastVoteWithReasonAndParamsBySigCall {
829 pub proposal_id: ::ethers_core::types::U256,
830 pub support: u8,
831 pub reason: ::std::string::String,
832 pub params: ::ethers_core::types::Bytes,
833 pub v: u8,
834 pub r: [u8; 32],
835 pub s: [u8; 32],
836 }
837 #[derive(
839 Clone,
840 ::ethers_contract::EthCall,
841 ::ethers_contract::EthDisplay,
842 Default,
843 Debug,
844 PartialEq,
845 Eq,
846 Hash
847 )]
848 #[ethcall(name = "clock", abi = "clock()")]
849 pub struct ClockCall;
850 #[derive(
852 Clone,
853 ::ethers_contract::EthCall,
854 ::ethers_contract::EthDisplay,
855 Default,
856 Debug,
857 PartialEq,
858 Eq,
859 Hash
860 )]
861 #[ethcall(name = "execute", abi = "execute(address[],uint256[],bytes[],bytes32)")]
862 pub struct ExecuteWithTargetsCall {
863 pub targets: ::std::vec::Vec<::ethers_core::types::Address>,
864 pub values: ::std::vec::Vec<::ethers_core::types::U256>,
865 pub calldatas: ::std::vec::Vec<::ethers_core::types::Bytes>,
866 pub description_hash: [u8; 32],
867 }
868 #[derive(
870 Clone,
871 ::ethers_contract::EthCall,
872 ::ethers_contract::EthDisplay,
873 Default,
874 Debug,
875 PartialEq,
876 Eq,
877 Hash
878 )]
879 #[ethcall(name = "execute", abi = "execute(uint256)")]
880 pub struct ExecuteCall {
881 pub proposal_id: ::ethers_core::types::U256,
882 }
883 #[derive(
885 Clone,
886 ::ethers_contract::EthCall,
887 ::ethers_contract::EthDisplay,
888 Default,
889 Debug,
890 PartialEq,
891 Eq,
892 Hash
893 )]
894 #[ethcall(name = "getActions", abi = "getActions(uint256)")]
895 pub struct GetActionsCall {
896 pub proposal_id: ::ethers_core::types::U256,
897 }
898 #[derive(
900 Clone,
901 ::ethers_contract::EthCall,
902 ::ethers_contract::EthDisplay,
903 Default,
904 Debug,
905 PartialEq,
906 Eq,
907 Hash
908 )]
909 #[ethcall(name = "getReceipt", abi = "getReceipt(uint256,address)")]
910 pub struct GetReceiptCall {
911 pub proposal_id: ::ethers_core::types::U256,
912 pub voter: ::ethers_core::types::Address,
913 }
914 #[derive(
916 Clone,
917 ::ethers_contract::EthCall,
918 ::ethers_contract::EthDisplay,
919 Default,
920 Debug,
921 PartialEq,
922 Eq,
923 Hash
924 )]
925 #[ethcall(name = "getVotes", abi = "getVotes(address,uint256)")]
926 pub struct GetVotesCall {
927 pub account: ::ethers_core::types::Address,
928 pub timepoint: ::ethers_core::types::U256,
929 }
930 #[derive(
932 Clone,
933 ::ethers_contract::EthCall,
934 ::ethers_contract::EthDisplay,
935 Default,
936 Debug,
937 PartialEq,
938 Eq,
939 Hash
940 )]
941 #[ethcall(
942 name = "getVotesWithParams",
943 abi = "getVotesWithParams(address,uint256,bytes)"
944 )]
945 pub struct GetVotesWithParamsCall {
946 pub account: ::ethers_core::types::Address,
947 pub timepoint: ::ethers_core::types::U256,
948 pub params: ::ethers_core::types::Bytes,
949 }
950 #[derive(
952 Clone,
953 ::ethers_contract::EthCall,
954 ::ethers_contract::EthDisplay,
955 Default,
956 Debug,
957 PartialEq,
958 Eq,
959 Hash
960 )]
961 #[ethcall(name = "hasVoted", abi = "hasVoted(uint256,address)")]
962 pub struct HasVotedCall {
963 pub proposal_id: ::ethers_core::types::U256,
964 pub account: ::ethers_core::types::Address,
965 }
966 #[derive(
968 Clone,
969 ::ethers_contract::EthCall,
970 ::ethers_contract::EthDisplay,
971 Default,
972 Debug,
973 PartialEq,
974 Eq,
975 Hash
976 )]
977 #[ethcall(
978 name = "hashProposal",
979 abi = "hashProposal(address[],uint256[],bytes[],bytes32)"
980 )]
981 pub struct HashProposalCall {
982 pub targets: ::std::vec::Vec<::ethers_core::types::Address>,
983 pub values: ::std::vec::Vec<::ethers_core::types::U256>,
984 pub calldatas: ::std::vec::Vec<::ethers_core::types::Bytes>,
985 pub description_hash: [u8; 32],
986 }
987 #[derive(
989 Clone,
990 ::ethers_contract::EthCall,
991 ::ethers_contract::EthDisplay,
992 Default,
993 Debug,
994 PartialEq,
995 Eq,
996 Hash
997 )]
998 #[ethcall(name = "name", abi = "name()")]
999 pub struct NameCall;
1000 #[derive(
1002 Clone,
1003 ::ethers_contract::EthCall,
1004 ::ethers_contract::EthDisplay,
1005 Default,
1006 Debug,
1007 PartialEq,
1008 Eq,
1009 Hash
1010 )]
1011 #[ethcall(name = "proposalDeadline", abi = "proposalDeadline(uint256)")]
1012 pub struct ProposalDeadlineCall {
1013 pub proposal_id: ::ethers_core::types::U256,
1014 }
1015 #[derive(
1017 Clone,
1018 ::ethers_contract::EthCall,
1019 ::ethers_contract::EthDisplay,
1020 Default,
1021 Debug,
1022 PartialEq,
1023 Eq,
1024 Hash
1025 )]
1026 #[ethcall(name = "proposalProposer", abi = "proposalProposer(uint256)")]
1027 pub struct ProposalProposerCall {
1028 pub proposal_id: ::ethers_core::types::U256,
1029 }
1030 #[derive(
1032 Clone,
1033 ::ethers_contract::EthCall,
1034 ::ethers_contract::EthDisplay,
1035 Default,
1036 Debug,
1037 PartialEq,
1038 Eq,
1039 Hash
1040 )]
1041 #[ethcall(name = "proposalSnapshot", abi = "proposalSnapshot(uint256)")]
1042 pub struct ProposalSnapshotCall {
1043 pub proposal_id: ::ethers_core::types::U256,
1044 }
1045 #[derive(
1047 Clone,
1048 ::ethers_contract::EthCall,
1049 ::ethers_contract::EthDisplay,
1050 Default,
1051 Debug,
1052 PartialEq,
1053 Eq,
1054 Hash
1055 )]
1056 #[ethcall(name = "proposals", abi = "proposals(uint256)")]
1057 pub struct ProposalsCall(pub ::ethers_core::types::U256);
1058 #[derive(
1060 Clone,
1061 ::ethers_contract::EthCall,
1062 ::ethers_contract::EthDisplay,
1063 Default,
1064 Debug,
1065 PartialEq,
1066 Eq,
1067 Hash
1068 )]
1069 #[ethcall(name = "propose", abi = "propose(address[],uint256[],bytes[],string)")]
1070 pub struct ProposeCall {
1071 pub targets: ::std::vec::Vec<::ethers_core::types::Address>,
1072 pub values: ::std::vec::Vec<::ethers_core::types::U256>,
1073 pub calldatas: ::std::vec::Vec<::ethers_core::types::Bytes>,
1074 pub description: ::std::string::String,
1075 }
1076 #[derive(
1078 Clone,
1079 ::ethers_contract::EthCall,
1080 ::ethers_contract::EthDisplay,
1081 Default,
1082 Debug,
1083 PartialEq,
1084 Eq,
1085 Hash
1086 )]
1087 #[ethcall(
1088 name = "propose",
1089 abi = "propose(address[],uint256[],string[],bytes[],string)"
1090 )]
1091 pub struct ProposeWithTargetsAndValuesAndSignaturesAndCalldatasCall {
1092 pub targets: ::std::vec::Vec<::ethers_core::types::Address>,
1093 pub values: ::std::vec::Vec<::ethers_core::types::U256>,
1094 pub signatures: ::std::vec::Vec<::std::string::String>,
1095 pub calldatas: ::std::vec::Vec<::ethers_core::types::Bytes>,
1096 pub description: ::std::string::String,
1097 }
1098 #[derive(
1100 Clone,
1101 ::ethers_contract::EthCall,
1102 ::ethers_contract::EthDisplay,
1103 Default,
1104 Debug,
1105 PartialEq,
1106 Eq,
1107 Hash
1108 )]
1109 #[ethcall(name = "queue", abi = "queue(uint256)")]
1110 pub struct QueueCall {
1111 pub proposal_id: ::ethers_core::types::U256,
1112 }
1113 #[derive(
1115 Clone,
1116 ::ethers_contract::EthCall,
1117 ::ethers_contract::EthDisplay,
1118 Default,
1119 Debug,
1120 PartialEq,
1121 Eq,
1122 Hash
1123 )]
1124 #[ethcall(name = "quorum", abi = "quorum(uint256)")]
1125 pub struct QuorumCall {
1126 pub timepoint: ::ethers_core::types::U256,
1127 }
1128 #[derive(
1130 Clone,
1131 ::ethers_contract::EthCall,
1132 ::ethers_contract::EthDisplay,
1133 Default,
1134 Debug,
1135 PartialEq,
1136 Eq,
1137 Hash
1138 )]
1139 #[ethcall(name = "quorumVotes", abi = "quorumVotes()")]
1140 pub struct QuorumVotesCall;
1141 #[derive(
1143 Clone,
1144 ::ethers_contract::EthCall,
1145 ::ethers_contract::EthDisplay,
1146 Default,
1147 Debug,
1148 PartialEq,
1149 Eq,
1150 Hash
1151 )]
1152 #[ethcall(name = "state", abi = "state(uint256)")]
1153 pub struct StateCall {
1154 pub proposal_id: ::ethers_core::types::U256,
1155 }
1156 #[derive(
1158 Clone,
1159 ::ethers_contract::EthCall,
1160 ::ethers_contract::EthDisplay,
1161 Default,
1162 Debug,
1163 PartialEq,
1164 Eq,
1165 Hash
1166 )]
1167 #[ethcall(name = "supportsInterface", abi = "supportsInterface(bytes4)")]
1168 pub struct SupportsInterfaceCall {
1169 pub interface_id: [u8; 4],
1170 }
1171 #[derive(
1173 Clone,
1174 ::ethers_contract::EthCall,
1175 ::ethers_contract::EthDisplay,
1176 Default,
1177 Debug,
1178 PartialEq,
1179 Eq,
1180 Hash
1181 )]
1182 #[ethcall(name = "version", abi = "version()")]
1183 pub struct VersionCall;
1184 #[derive(
1186 Clone,
1187 ::ethers_contract::EthCall,
1188 ::ethers_contract::EthDisplay,
1189 Default,
1190 Debug,
1191 PartialEq,
1192 Eq,
1193 Hash
1194 )]
1195 #[ethcall(name = "votingDelay", abi = "votingDelay()")]
1196 pub struct VotingDelayCall;
1197 #[derive(
1199 Clone,
1200 ::ethers_contract::EthCall,
1201 ::ethers_contract::EthDisplay,
1202 Default,
1203 Debug,
1204 PartialEq,
1205 Eq,
1206 Hash
1207 )]
1208 #[ethcall(name = "votingPeriod", abi = "votingPeriod()")]
1209 pub struct VotingPeriodCall;
1210 #[derive(Clone, ::ethers_contract::EthAbiType, Debug, PartialEq, Eq, Hash)]
1212 pub enum IGovernorCompatibilityBravoCalls {
1213 ClockMode(ClockModeCall),
1214 CountingMode(CountingModeCall),
1215 Cancel(CancelCall),
1216 CancelWithTargets(CancelWithTargetsCall),
1217 CastVote(CastVoteCall),
1218 CastVoteBySig(CastVoteBySigCall),
1219 CastVoteWithReason(CastVoteWithReasonCall),
1220 CastVoteWithReasonAndParams(CastVoteWithReasonAndParamsCall),
1221 CastVoteWithReasonAndParamsBySig(CastVoteWithReasonAndParamsBySigCall),
1222 Clock(ClockCall),
1223 ExecuteWithTargets(ExecuteWithTargetsCall),
1224 Execute(ExecuteCall),
1225 GetActions(GetActionsCall),
1226 GetReceipt(GetReceiptCall),
1227 GetVotes(GetVotesCall),
1228 GetVotesWithParams(GetVotesWithParamsCall),
1229 HasVoted(HasVotedCall),
1230 HashProposal(HashProposalCall),
1231 Name(NameCall),
1232 ProposalDeadline(ProposalDeadlineCall),
1233 ProposalProposer(ProposalProposerCall),
1234 ProposalSnapshot(ProposalSnapshotCall),
1235 Proposals(ProposalsCall),
1236 Propose(ProposeCall),
1237 ProposeWithTargetsAndValuesAndSignaturesAndCalldatas(
1238 ProposeWithTargetsAndValuesAndSignaturesAndCalldatasCall,
1239 ),
1240 Queue(QueueCall),
1241 Quorum(QuorumCall),
1242 QuorumVotes(QuorumVotesCall),
1243 State(StateCall),
1244 SupportsInterface(SupportsInterfaceCall),
1245 Version(VersionCall),
1246 VotingDelay(VotingDelayCall),
1247 VotingPeriod(VotingPeriodCall),
1248 }
1249 impl ::ethers_core::abi::AbiDecode for IGovernorCompatibilityBravoCalls {
1250 fn decode(
1251 data: impl AsRef<[u8]>,
1252 ) -> ::core::result::Result<Self, ::ethers_core::abi::AbiError> {
1253 let data = data.as_ref();
1254 if let Ok(decoded)
1255 = <ClockModeCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1256 return Ok(Self::ClockMode(decoded));
1257 }
1258 if let Ok(decoded)
1259 = <CountingModeCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1260 return Ok(Self::CountingMode(decoded));
1261 }
1262 if let Ok(decoded)
1263 = <CancelCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1264 return Ok(Self::Cancel(decoded));
1265 }
1266 if let Ok(decoded)
1267 = <CancelWithTargetsCall as ::ethers_core::abi::AbiDecode>::decode(
1268 data,
1269 ) {
1270 return Ok(Self::CancelWithTargets(decoded));
1271 }
1272 if let Ok(decoded)
1273 = <CastVoteCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1274 return Ok(Self::CastVote(decoded));
1275 }
1276 if let Ok(decoded)
1277 = <CastVoteBySigCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1278 return Ok(Self::CastVoteBySig(decoded));
1279 }
1280 if let Ok(decoded)
1281 = <CastVoteWithReasonCall as ::ethers_core::abi::AbiDecode>::decode(
1282 data,
1283 ) {
1284 return Ok(Self::CastVoteWithReason(decoded));
1285 }
1286 if let Ok(decoded)
1287 = <CastVoteWithReasonAndParamsCall as ::ethers_core::abi::AbiDecode>::decode(
1288 data,
1289 ) {
1290 return Ok(Self::CastVoteWithReasonAndParams(decoded));
1291 }
1292 if let Ok(decoded)
1293 = <CastVoteWithReasonAndParamsBySigCall as ::ethers_core::abi::AbiDecode>::decode(
1294 data,
1295 ) {
1296 return Ok(Self::CastVoteWithReasonAndParamsBySig(decoded));
1297 }
1298 if let Ok(decoded)
1299 = <ClockCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1300 return Ok(Self::Clock(decoded));
1301 }
1302 if let Ok(decoded)
1303 = <ExecuteWithTargetsCall as ::ethers_core::abi::AbiDecode>::decode(
1304 data,
1305 ) {
1306 return Ok(Self::ExecuteWithTargets(decoded));
1307 }
1308 if let Ok(decoded)
1309 = <ExecuteCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1310 return Ok(Self::Execute(decoded));
1311 }
1312 if let Ok(decoded)
1313 = <GetActionsCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1314 return Ok(Self::GetActions(decoded));
1315 }
1316 if let Ok(decoded)
1317 = <GetReceiptCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1318 return Ok(Self::GetReceipt(decoded));
1319 }
1320 if let Ok(decoded)
1321 = <GetVotesCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1322 return Ok(Self::GetVotes(decoded));
1323 }
1324 if let Ok(decoded)
1325 = <GetVotesWithParamsCall as ::ethers_core::abi::AbiDecode>::decode(
1326 data,
1327 ) {
1328 return Ok(Self::GetVotesWithParams(decoded));
1329 }
1330 if let Ok(decoded)
1331 = <HasVotedCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1332 return Ok(Self::HasVoted(decoded));
1333 }
1334 if let Ok(decoded)
1335 = <HashProposalCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1336 return Ok(Self::HashProposal(decoded));
1337 }
1338 if let Ok(decoded)
1339 = <NameCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1340 return Ok(Self::Name(decoded));
1341 }
1342 if let Ok(decoded)
1343 = <ProposalDeadlineCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1344 return Ok(Self::ProposalDeadline(decoded));
1345 }
1346 if let Ok(decoded)
1347 = <ProposalProposerCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1348 return Ok(Self::ProposalProposer(decoded));
1349 }
1350 if let Ok(decoded)
1351 = <ProposalSnapshotCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1352 return Ok(Self::ProposalSnapshot(decoded));
1353 }
1354 if let Ok(decoded)
1355 = <ProposalsCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1356 return Ok(Self::Proposals(decoded));
1357 }
1358 if let Ok(decoded)
1359 = <ProposeCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1360 return Ok(Self::Propose(decoded));
1361 }
1362 if let Ok(decoded)
1363 = <ProposeWithTargetsAndValuesAndSignaturesAndCalldatasCall as ::ethers_core::abi::AbiDecode>::decode(
1364 data,
1365 ) {
1366 return Ok(
1367 Self::ProposeWithTargetsAndValuesAndSignaturesAndCalldatas(decoded),
1368 );
1369 }
1370 if let Ok(decoded)
1371 = <QueueCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1372 return Ok(Self::Queue(decoded));
1373 }
1374 if let Ok(decoded)
1375 = <QuorumCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1376 return Ok(Self::Quorum(decoded));
1377 }
1378 if let Ok(decoded)
1379 = <QuorumVotesCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1380 return Ok(Self::QuorumVotes(decoded));
1381 }
1382 if let Ok(decoded)
1383 = <StateCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1384 return Ok(Self::State(decoded));
1385 }
1386 if let Ok(decoded)
1387 = <SupportsInterfaceCall as ::ethers_core::abi::AbiDecode>::decode(
1388 data,
1389 ) {
1390 return Ok(Self::SupportsInterface(decoded));
1391 }
1392 if let Ok(decoded)
1393 = <VersionCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1394 return Ok(Self::Version(decoded));
1395 }
1396 if let Ok(decoded)
1397 = <VotingDelayCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1398 return Ok(Self::VotingDelay(decoded));
1399 }
1400 if let Ok(decoded)
1401 = <VotingPeriodCall as ::ethers_core::abi::AbiDecode>::decode(data) {
1402 return Ok(Self::VotingPeriod(decoded));
1403 }
1404 Err(::ethers_core::abi::Error::InvalidData.into())
1405 }
1406 }
1407 impl ::ethers_core::abi::AbiEncode for IGovernorCompatibilityBravoCalls {
1408 fn encode(self) -> Vec<u8> {
1409 match self {
1410 Self::ClockMode(element) => {
1411 ::ethers_core::abi::AbiEncode::encode(element)
1412 }
1413 Self::CountingMode(element) => {
1414 ::ethers_core::abi::AbiEncode::encode(element)
1415 }
1416 Self::Cancel(element) => ::ethers_core::abi::AbiEncode::encode(element),
1417 Self::CancelWithTargets(element) => {
1418 ::ethers_core::abi::AbiEncode::encode(element)
1419 }
1420 Self::CastVote(element) => ::ethers_core::abi::AbiEncode::encode(element),
1421 Self::CastVoteBySig(element) => {
1422 ::ethers_core::abi::AbiEncode::encode(element)
1423 }
1424 Self::CastVoteWithReason(element) => {
1425 ::ethers_core::abi::AbiEncode::encode(element)
1426 }
1427 Self::CastVoteWithReasonAndParams(element) => {
1428 ::ethers_core::abi::AbiEncode::encode(element)
1429 }
1430 Self::CastVoteWithReasonAndParamsBySig(element) => {
1431 ::ethers_core::abi::AbiEncode::encode(element)
1432 }
1433 Self::Clock(element) => ::ethers_core::abi::AbiEncode::encode(element),
1434 Self::ExecuteWithTargets(element) => {
1435 ::ethers_core::abi::AbiEncode::encode(element)
1436 }
1437 Self::Execute(element) => ::ethers_core::abi::AbiEncode::encode(element),
1438 Self::GetActions(element) => {
1439 ::ethers_core::abi::AbiEncode::encode(element)
1440 }
1441 Self::GetReceipt(element) => {
1442 ::ethers_core::abi::AbiEncode::encode(element)
1443 }
1444 Self::GetVotes(element) => ::ethers_core::abi::AbiEncode::encode(element),
1445 Self::GetVotesWithParams(element) => {
1446 ::ethers_core::abi::AbiEncode::encode(element)
1447 }
1448 Self::HasVoted(element) => ::ethers_core::abi::AbiEncode::encode(element),
1449 Self::HashProposal(element) => {
1450 ::ethers_core::abi::AbiEncode::encode(element)
1451 }
1452 Self::Name(element) => ::ethers_core::abi::AbiEncode::encode(element),
1453 Self::ProposalDeadline(element) => {
1454 ::ethers_core::abi::AbiEncode::encode(element)
1455 }
1456 Self::ProposalProposer(element) => {
1457 ::ethers_core::abi::AbiEncode::encode(element)
1458 }
1459 Self::ProposalSnapshot(element) => {
1460 ::ethers_core::abi::AbiEncode::encode(element)
1461 }
1462 Self::Proposals(element) => {
1463 ::ethers_core::abi::AbiEncode::encode(element)
1464 }
1465 Self::Propose(element) => ::ethers_core::abi::AbiEncode::encode(element),
1466 Self::ProposeWithTargetsAndValuesAndSignaturesAndCalldatas(element) => {
1467 ::ethers_core::abi::AbiEncode::encode(element)
1468 }
1469 Self::Queue(element) => ::ethers_core::abi::AbiEncode::encode(element),
1470 Self::Quorum(element) => ::ethers_core::abi::AbiEncode::encode(element),
1471 Self::QuorumVotes(element) => {
1472 ::ethers_core::abi::AbiEncode::encode(element)
1473 }
1474 Self::State(element) => ::ethers_core::abi::AbiEncode::encode(element),
1475 Self::SupportsInterface(element) => {
1476 ::ethers_core::abi::AbiEncode::encode(element)
1477 }
1478 Self::Version(element) => ::ethers_core::abi::AbiEncode::encode(element),
1479 Self::VotingDelay(element) => {
1480 ::ethers_core::abi::AbiEncode::encode(element)
1481 }
1482 Self::VotingPeriod(element) => {
1483 ::ethers_core::abi::AbiEncode::encode(element)
1484 }
1485 }
1486 }
1487 }
1488 impl ::core::fmt::Display for IGovernorCompatibilityBravoCalls {
1489 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
1490 match self {
1491 Self::ClockMode(element) => ::core::fmt::Display::fmt(element, f),
1492 Self::CountingMode(element) => ::core::fmt::Display::fmt(element, f),
1493 Self::Cancel(element) => ::core::fmt::Display::fmt(element, f),
1494 Self::CancelWithTargets(element) => ::core::fmt::Display::fmt(element, f),
1495 Self::CastVote(element) => ::core::fmt::Display::fmt(element, f),
1496 Self::CastVoteBySig(element) => ::core::fmt::Display::fmt(element, f),
1497 Self::CastVoteWithReason(element) => {
1498 ::core::fmt::Display::fmt(element, f)
1499 }
1500 Self::CastVoteWithReasonAndParams(element) => {
1501 ::core::fmt::Display::fmt(element, f)
1502 }
1503 Self::CastVoteWithReasonAndParamsBySig(element) => {
1504 ::core::fmt::Display::fmt(element, f)
1505 }
1506 Self::Clock(element) => ::core::fmt::Display::fmt(element, f),
1507 Self::ExecuteWithTargets(element) => {
1508 ::core::fmt::Display::fmt(element, f)
1509 }
1510 Self::Execute(element) => ::core::fmt::Display::fmt(element, f),
1511 Self::GetActions(element) => ::core::fmt::Display::fmt(element, f),
1512 Self::GetReceipt(element) => ::core::fmt::Display::fmt(element, f),
1513 Self::GetVotes(element) => ::core::fmt::Display::fmt(element, f),
1514 Self::GetVotesWithParams(element) => {
1515 ::core::fmt::Display::fmt(element, f)
1516 }
1517 Self::HasVoted(element) => ::core::fmt::Display::fmt(element, f),
1518 Self::HashProposal(element) => ::core::fmt::Display::fmt(element, f),
1519 Self::Name(element) => ::core::fmt::Display::fmt(element, f),
1520 Self::ProposalDeadline(element) => ::core::fmt::Display::fmt(element, f),
1521 Self::ProposalProposer(element) => ::core::fmt::Display::fmt(element, f),
1522 Self::ProposalSnapshot(element) => ::core::fmt::Display::fmt(element, f),
1523 Self::Proposals(element) => ::core::fmt::Display::fmt(element, f),
1524 Self::Propose(element) => ::core::fmt::Display::fmt(element, f),
1525 Self::ProposeWithTargetsAndValuesAndSignaturesAndCalldatas(element) => {
1526 ::core::fmt::Display::fmt(element, f)
1527 }
1528 Self::Queue(element) => ::core::fmt::Display::fmt(element, f),
1529 Self::Quorum(element) => ::core::fmt::Display::fmt(element, f),
1530 Self::QuorumVotes(element) => ::core::fmt::Display::fmt(element, f),
1531 Self::State(element) => ::core::fmt::Display::fmt(element, f),
1532 Self::SupportsInterface(element) => ::core::fmt::Display::fmt(element, f),
1533 Self::Version(element) => ::core::fmt::Display::fmt(element, f),
1534 Self::VotingDelay(element) => ::core::fmt::Display::fmt(element, f),
1535 Self::VotingPeriod(element) => ::core::fmt::Display::fmt(element, f),
1536 }
1537 }
1538 }
1539 impl ::core::convert::From<ClockModeCall> for IGovernorCompatibilityBravoCalls {
1540 fn from(value: ClockModeCall) -> Self {
1541 Self::ClockMode(value)
1542 }
1543 }
1544 impl ::core::convert::From<CountingModeCall> for IGovernorCompatibilityBravoCalls {
1545 fn from(value: CountingModeCall) -> Self {
1546 Self::CountingMode(value)
1547 }
1548 }
1549 impl ::core::convert::From<CancelCall> for IGovernorCompatibilityBravoCalls {
1550 fn from(value: CancelCall) -> Self {
1551 Self::Cancel(value)
1552 }
1553 }
1554 impl ::core::convert::From<CancelWithTargetsCall>
1555 for IGovernorCompatibilityBravoCalls {
1556 fn from(value: CancelWithTargetsCall) -> Self {
1557 Self::CancelWithTargets(value)
1558 }
1559 }
1560 impl ::core::convert::From<CastVoteCall> for IGovernorCompatibilityBravoCalls {
1561 fn from(value: CastVoteCall) -> Self {
1562 Self::CastVote(value)
1563 }
1564 }
1565 impl ::core::convert::From<CastVoteBySigCall> for IGovernorCompatibilityBravoCalls {
1566 fn from(value: CastVoteBySigCall) -> Self {
1567 Self::CastVoteBySig(value)
1568 }
1569 }
1570 impl ::core::convert::From<CastVoteWithReasonCall>
1571 for IGovernorCompatibilityBravoCalls {
1572 fn from(value: CastVoteWithReasonCall) -> Self {
1573 Self::CastVoteWithReason(value)
1574 }
1575 }
1576 impl ::core::convert::From<CastVoteWithReasonAndParamsCall>
1577 for IGovernorCompatibilityBravoCalls {
1578 fn from(value: CastVoteWithReasonAndParamsCall) -> Self {
1579 Self::CastVoteWithReasonAndParams(value)
1580 }
1581 }
1582 impl ::core::convert::From<CastVoteWithReasonAndParamsBySigCall>
1583 for IGovernorCompatibilityBravoCalls {
1584 fn from(value: CastVoteWithReasonAndParamsBySigCall) -> Self {
1585 Self::CastVoteWithReasonAndParamsBySig(value)
1586 }
1587 }
1588 impl ::core::convert::From<ClockCall> for IGovernorCompatibilityBravoCalls {
1589 fn from(value: ClockCall) -> Self {
1590 Self::Clock(value)
1591 }
1592 }
1593 impl ::core::convert::From<ExecuteWithTargetsCall>
1594 for IGovernorCompatibilityBravoCalls {
1595 fn from(value: ExecuteWithTargetsCall) -> Self {
1596 Self::ExecuteWithTargets(value)
1597 }
1598 }
1599 impl ::core::convert::From<ExecuteCall> for IGovernorCompatibilityBravoCalls {
1600 fn from(value: ExecuteCall) -> Self {
1601 Self::Execute(value)
1602 }
1603 }
1604 impl ::core::convert::From<GetActionsCall> for IGovernorCompatibilityBravoCalls {
1605 fn from(value: GetActionsCall) -> Self {
1606 Self::GetActions(value)
1607 }
1608 }
1609 impl ::core::convert::From<GetReceiptCall> for IGovernorCompatibilityBravoCalls {
1610 fn from(value: GetReceiptCall) -> Self {
1611 Self::GetReceipt(value)
1612 }
1613 }
1614 impl ::core::convert::From<GetVotesCall> for IGovernorCompatibilityBravoCalls {
1615 fn from(value: GetVotesCall) -> Self {
1616 Self::GetVotes(value)
1617 }
1618 }
1619 impl ::core::convert::From<GetVotesWithParamsCall>
1620 for IGovernorCompatibilityBravoCalls {
1621 fn from(value: GetVotesWithParamsCall) -> Self {
1622 Self::GetVotesWithParams(value)
1623 }
1624 }
1625 impl ::core::convert::From<HasVotedCall> for IGovernorCompatibilityBravoCalls {
1626 fn from(value: HasVotedCall) -> Self {
1627 Self::HasVoted(value)
1628 }
1629 }
1630 impl ::core::convert::From<HashProposalCall> for IGovernorCompatibilityBravoCalls {
1631 fn from(value: HashProposalCall) -> Self {
1632 Self::HashProposal(value)
1633 }
1634 }
1635 impl ::core::convert::From<NameCall> for IGovernorCompatibilityBravoCalls {
1636 fn from(value: NameCall) -> Self {
1637 Self::Name(value)
1638 }
1639 }
1640 impl ::core::convert::From<ProposalDeadlineCall>
1641 for IGovernorCompatibilityBravoCalls {
1642 fn from(value: ProposalDeadlineCall) -> Self {
1643 Self::ProposalDeadline(value)
1644 }
1645 }
1646 impl ::core::convert::From<ProposalProposerCall>
1647 for IGovernorCompatibilityBravoCalls {
1648 fn from(value: ProposalProposerCall) -> Self {
1649 Self::ProposalProposer(value)
1650 }
1651 }
1652 impl ::core::convert::From<ProposalSnapshotCall>
1653 for IGovernorCompatibilityBravoCalls {
1654 fn from(value: ProposalSnapshotCall) -> Self {
1655 Self::ProposalSnapshot(value)
1656 }
1657 }
1658 impl ::core::convert::From<ProposalsCall> for IGovernorCompatibilityBravoCalls {
1659 fn from(value: ProposalsCall) -> Self {
1660 Self::Proposals(value)
1661 }
1662 }
1663 impl ::core::convert::From<ProposeCall> for IGovernorCompatibilityBravoCalls {
1664 fn from(value: ProposeCall) -> Self {
1665 Self::Propose(value)
1666 }
1667 }
1668 impl ::core::convert::From<ProposeWithTargetsAndValuesAndSignaturesAndCalldatasCall>
1669 for IGovernorCompatibilityBravoCalls {
1670 fn from(
1671 value: ProposeWithTargetsAndValuesAndSignaturesAndCalldatasCall,
1672 ) -> Self {
1673 Self::ProposeWithTargetsAndValuesAndSignaturesAndCalldatas(value)
1674 }
1675 }
1676 impl ::core::convert::From<QueueCall> for IGovernorCompatibilityBravoCalls {
1677 fn from(value: QueueCall) -> Self {
1678 Self::Queue(value)
1679 }
1680 }
1681 impl ::core::convert::From<QuorumCall> for IGovernorCompatibilityBravoCalls {
1682 fn from(value: QuorumCall) -> Self {
1683 Self::Quorum(value)
1684 }
1685 }
1686 impl ::core::convert::From<QuorumVotesCall> for IGovernorCompatibilityBravoCalls {
1687 fn from(value: QuorumVotesCall) -> Self {
1688 Self::QuorumVotes(value)
1689 }
1690 }
1691 impl ::core::convert::From<StateCall> for IGovernorCompatibilityBravoCalls {
1692 fn from(value: StateCall) -> Self {
1693 Self::State(value)
1694 }
1695 }
1696 impl ::core::convert::From<SupportsInterfaceCall>
1697 for IGovernorCompatibilityBravoCalls {
1698 fn from(value: SupportsInterfaceCall) -> Self {
1699 Self::SupportsInterface(value)
1700 }
1701 }
1702 impl ::core::convert::From<VersionCall> for IGovernorCompatibilityBravoCalls {
1703 fn from(value: VersionCall) -> Self {
1704 Self::Version(value)
1705 }
1706 }
1707 impl ::core::convert::From<VotingDelayCall> for IGovernorCompatibilityBravoCalls {
1708 fn from(value: VotingDelayCall) -> Self {
1709 Self::VotingDelay(value)
1710 }
1711 }
1712 impl ::core::convert::From<VotingPeriodCall> for IGovernorCompatibilityBravoCalls {
1713 fn from(value: VotingPeriodCall) -> Self {
1714 Self::VotingPeriod(value)
1715 }
1716 }
1717 #[derive(
1719 Clone,
1720 ::ethers_contract::EthAbiType,
1721 ::ethers_contract::EthAbiCodec,
1722 Default,
1723 Debug,
1724 PartialEq,
1725 Eq,
1726 Hash
1727 )]
1728 pub struct ClockModeReturn(pub ::std::string::String);
1729 #[derive(
1731 Clone,
1732 ::ethers_contract::EthAbiType,
1733 ::ethers_contract::EthAbiCodec,
1734 Default,
1735 Debug,
1736 PartialEq,
1737 Eq,
1738 Hash
1739 )]
1740 pub struct CountingModeReturn(pub ::std::string::String);
1741 #[derive(
1743 Clone,
1744 ::ethers_contract::EthAbiType,
1745 ::ethers_contract::EthAbiCodec,
1746 Default,
1747 Debug,
1748 PartialEq,
1749 Eq,
1750 Hash
1751 )]
1752 pub struct CancelWithTargetsReturn {
1753 pub proposal_id: ::ethers_core::types::U256,
1754 }
1755 #[derive(
1757 Clone,
1758 ::ethers_contract::EthAbiType,
1759 ::ethers_contract::EthAbiCodec,
1760 Default,
1761 Debug,
1762 PartialEq,
1763 Eq,
1764 Hash
1765 )]
1766 pub struct CastVoteReturn {
1767 pub balance: ::ethers_core::types::U256,
1768 }
1769 #[derive(
1771 Clone,
1772 ::ethers_contract::EthAbiType,
1773 ::ethers_contract::EthAbiCodec,
1774 Default,
1775 Debug,
1776 PartialEq,
1777 Eq,
1778 Hash
1779 )]
1780 pub struct CastVoteBySigReturn {
1781 pub balance: ::ethers_core::types::U256,
1782 }
1783 #[derive(
1785 Clone,
1786 ::ethers_contract::EthAbiType,
1787 ::ethers_contract::EthAbiCodec,
1788 Default,
1789 Debug,
1790 PartialEq,
1791 Eq,
1792 Hash
1793 )]
1794 pub struct CastVoteWithReasonReturn {
1795 pub balance: ::ethers_core::types::U256,
1796 }
1797 #[derive(
1799 Clone,
1800 ::ethers_contract::EthAbiType,
1801 ::ethers_contract::EthAbiCodec,
1802 Default,
1803 Debug,
1804 PartialEq,
1805 Eq,
1806 Hash
1807 )]
1808 pub struct CastVoteWithReasonAndParamsReturn {
1809 pub balance: ::ethers_core::types::U256,
1810 }
1811 #[derive(
1813 Clone,
1814 ::ethers_contract::EthAbiType,
1815 ::ethers_contract::EthAbiCodec,
1816 Default,
1817 Debug,
1818 PartialEq,
1819 Eq,
1820 Hash
1821 )]
1822 pub struct CastVoteWithReasonAndParamsBySigReturn {
1823 pub balance: ::ethers_core::types::U256,
1824 }
1825 #[derive(
1827 Clone,
1828 ::ethers_contract::EthAbiType,
1829 ::ethers_contract::EthAbiCodec,
1830 Default,
1831 Debug,
1832 PartialEq,
1833 Eq,
1834 Hash
1835 )]
1836 pub struct ClockReturn(pub u64);
1837 #[derive(
1839 Clone,
1840 ::ethers_contract::EthAbiType,
1841 ::ethers_contract::EthAbiCodec,
1842 Default,
1843 Debug,
1844 PartialEq,
1845 Eq,
1846 Hash
1847 )]
1848 pub struct ExecuteWithTargetsReturn {
1849 pub proposal_id: ::ethers_core::types::U256,
1850 }
1851 #[derive(
1853 Clone,
1854 ::ethers_contract::EthAbiType,
1855 ::ethers_contract::EthAbiCodec,
1856 Default,
1857 Debug,
1858 PartialEq,
1859 Eq,
1860 Hash
1861 )]
1862 pub struct GetActionsReturn {
1863 pub targets: ::std::vec::Vec<::ethers_core::types::Address>,
1864 pub values: ::std::vec::Vec<::ethers_core::types::U256>,
1865 pub signatures: ::std::vec::Vec<::std::string::String>,
1866 pub calldatas: ::std::vec::Vec<::ethers_core::types::Bytes>,
1867 }
1868 #[derive(
1870 Clone,
1871 ::ethers_contract::EthAbiType,
1872 ::ethers_contract::EthAbiCodec,
1873 Default,
1874 Debug,
1875 PartialEq,
1876 Eq,
1877 Hash
1878 )]
1879 pub struct GetReceiptReturn(pub Receipt);
1880 #[derive(
1882 Clone,
1883 ::ethers_contract::EthAbiType,
1884 ::ethers_contract::EthAbiCodec,
1885 Default,
1886 Debug,
1887 PartialEq,
1888 Eq,
1889 Hash
1890 )]
1891 pub struct GetVotesReturn(pub ::ethers_core::types::U256);
1892 #[derive(
1894 Clone,
1895 ::ethers_contract::EthAbiType,
1896 ::ethers_contract::EthAbiCodec,
1897 Default,
1898 Debug,
1899 PartialEq,
1900 Eq,
1901 Hash
1902 )]
1903 pub struct GetVotesWithParamsReturn(pub ::ethers_core::types::U256);
1904 #[derive(
1906 Clone,
1907 ::ethers_contract::EthAbiType,
1908 ::ethers_contract::EthAbiCodec,
1909 Default,
1910 Debug,
1911 PartialEq,
1912 Eq,
1913 Hash
1914 )]
1915 pub struct HasVotedReturn(pub bool);
1916 #[derive(
1918 Clone,
1919 ::ethers_contract::EthAbiType,
1920 ::ethers_contract::EthAbiCodec,
1921 Default,
1922 Debug,
1923 PartialEq,
1924 Eq,
1925 Hash
1926 )]
1927 pub struct HashProposalReturn(pub ::ethers_core::types::U256);
1928 #[derive(
1930 Clone,
1931 ::ethers_contract::EthAbiType,
1932 ::ethers_contract::EthAbiCodec,
1933 Default,
1934 Debug,
1935 PartialEq,
1936 Eq,
1937 Hash
1938 )]
1939 pub struct NameReturn(pub ::std::string::String);
1940 #[derive(
1942 Clone,
1943 ::ethers_contract::EthAbiType,
1944 ::ethers_contract::EthAbiCodec,
1945 Default,
1946 Debug,
1947 PartialEq,
1948 Eq,
1949 Hash
1950 )]
1951 pub struct ProposalDeadlineReturn(pub ::ethers_core::types::U256);
1952 #[derive(
1954 Clone,
1955 ::ethers_contract::EthAbiType,
1956 ::ethers_contract::EthAbiCodec,
1957 Default,
1958 Debug,
1959 PartialEq,
1960 Eq,
1961 Hash
1962 )]
1963 pub struct ProposalProposerReturn(pub ::ethers_core::types::Address);
1964 #[derive(
1966 Clone,
1967 ::ethers_contract::EthAbiType,
1968 ::ethers_contract::EthAbiCodec,
1969 Default,
1970 Debug,
1971 PartialEq,
1972 Eq,
1973 Hash
1974 )]
1975 pub struct ProposalSnapshotReturn(pub ::ethers_core::types::U256);
1976 #[derive(
1978 Clone,
1979 ::ethers_contract::EthAbiType,
1980 ::ethers_contract::EthAbiCodec,
1981 Default,
1982 Debug,
1983 PartialEq,
1984 Eq,
1985 Hash
1986 )]
1987 pub struct ProposalsReturn {
1988 pub id: ::ethers_core::types::U256,
1989 pub proposer: ::ethers_core::types::Address,
1990 pub eta: ::ethers_core::types::U256,
1991 pub start_block: ::ethers_core::types::U256,
1992 pub end_block: ::ethers_core::types::U256,
1993 pub for_votes: ::ethers_core::types::U256,
1994 pub against_votes: ::ethers_core::types::U256,
1995 pub abstain_votes: ::ethers_core::types::U256,
1996 pub canceled: bool,
1997 pub executed: bool,
1998 }
1999 #[derive(
2001 Clone,
2002 ::ethers_contract::EthAbiType,
2003 ::ethers_contract::EthAbiCodec,
2004 Default,
2005 Debug,
2006 PartialEq,
2007 Eq,
2008 Hash
2009 )]
2010 pub struct ProposeReturn {
2011 pub proposal_id: ::ethers_core::types::U256,
2012 }
2013 #[derive(
2015 Clone,
2016 ::ethers_contract::EthAbiType,
2017 ::ethers_contract::EthAbiCodec,
2018 Default,
2019 Debug,
2020 PartialEq,
2021 Eq,
2022 Hash
2023 )]
2024 pub struct ProposeWithTargetsAndValuesAndSignaturesAndCalldatasReturn(
2025 pub ::ethers_core::types::U256,
2026 );
2027 #[derive(
2029 Clone,
2030 ::ethers_contract::EthAbiType,
2031 ::ethers_contract::EthAbiCodec,
2032 Default,
2033 Debug,
2034 PartialEq,
2035 Eq,
2036 Hash
2037 )]
2038 pub struct QuorumReturn(pub ::ethers_core::types::U256);
2039 #[derive(
2041 Clone,
2042 ::ethers_contract::EthAbiType,
2043 ::ethers_contract::EthAbiCodec,
2044 Default,
2045 Debug,
2046 PartialEq,
2047 Eq,
2048 Hash
2049 )]
2050 pub struct QuorumVotesReturn(pub ::ethers_core::types::U256);
2051 #[derive(
2053 Clone,
2054 ::ethers_contract::EthAbiType,
2055 ::ethers_contract::EthAbiCodec,
2056 Default,
2057 Debug,
2058 PartialEq,
2059 Eq,
2060 Hash
2061 )]
2062 pub struct StateReturn(pub u8);
2063 #[derive(
2065 Clone,
2066 ::ethers_contract::EthAbiType,
2067 ::ethers_contract::EthAbiCodec,
2068 Default,
2069 Debug,
2070 PartialEq,
2071 Eq,
2072 Hash
2073 )]
2074 pub struct SupportsInterfaceReturn(pub bool);
2075 #[derive(
2077 Clone,
2078 ::ethers_contract::EthAbiType,
2079 ::ethers_contract::EthAbiCodec,
2080 Default,
2081 Debug,
2082 PartialEq,
2083 Eq,
2084 Hash
2085 )]
2086 pub struct VersionReturn(pub ::std::string::String);
2087 #[derive(
2089 Clone,
2090 ::ethers_contract::EthAbiType,
2091 ::ethers_contract::EthAbiCodec,
2092 Default,
2093 Debug,
2094 PartialEq,
2095 Eq,
2096 Hash
2097 )]
2098 pub struct VotingDelayReturn(pub ::ethers_core::types::U256);
2099 #[derive(
2101 Clone,
2102 ::ethers_contract::EthAbiType,
2103 ::ethers_contract::EthAbiCodec,
2104 Default,
2105 Debug,
2106 PartialEq,
2107 Eq,
2108 Hash
2109 )]
2110 pub struct VotingPeriodReturn(pub ::ethers_core::types::U256);
2111 #[derive(
2113 Clone,
2114 ::ethers_contract::EthAbiType,
2115 ::ethers_contract::EthAbiCodec,
2116 Default,
2117 Debug,
2118 PartialEq,
2119 Eq,
2120 Hash
2121 )]
2122 pub struct Receipt {
2123 pub has_voted: bool,
2124 pub support: u8,
2125 pub votes: u128,
2126 }
2127}