1#[allow(
97 non_camel_case_types,
98 non_snake_case,
99 clippy::pub_underscore_fields,
100 clippy::style,
101 clippy::empty_structs_with_brackets
102)]
103pub mod RankedFeed {
104 use super::*;
105 use alloy::sol_types as alloy_sol_types;
106 #[rustfmt::skip]
112 #[allow(clippy::all)]
113 pub static BYTECODE: alloy_sol_types::private::Bytes = alloy_sol_types::private::Bytes::from_static(
114 b"`\x80`@R4\x80\x15`\x0EW__\xFD[Pa\x07M\x80a\0\x1C_9_\xF3\xFE`\x80`@R4\x80\x15a\0\x0FW__\xFD[P`\x046\x10a\x004W_5`\xE0\x1C\x80c\xA1\x98\x1B\xF1\x14a\08W\x80c\xDF\xBA\xA2\xFB\x14a\0TW[__\xFD[a\0R`\x04\x806\x03\x81\x01\x90a\0M\x91\x90a\x04'V[a\0pV[\0[a\0n`\x04\x806\x03\x81\x01\x90a\0i\x91\x90a\x04\xB3V[a\x013V[\0[_a\0\x87\x823`\x01a\x023\x90\x92\x91\x90c\xFF\xFF\xFF\xFF\x16V[\x14a\0\xBEW`@Q\x7F|\x9A\x1C\xF9\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x81R`\x04\x01`@Q\x80\x91\x03\x90\xFD[a\0\xD6\x813`\x01\x80a\x02\xF9\x90\x93\x92\x91\x90c\xFF\xFF\xFF\xFF\x16V[a\0\xEC\x81`\x01_a\x03\xBF\x90\x92\x91\x90c\xFF\xFF\xFF\xFF\x16V[3s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x81\x7F\x98\xB6\xB1\x80ul\x84\x9B[\xFB\xBD+\xBD\t\x1F?\xE6K\t5\xAC\x19T\x18\xC0\xB6\x19\xB9\xB6a\xC7\x8D`@Q`@Q\x80\x91\x03\x90\xA3PV[_3\x83\x83`@Q` \x01a\x01I\x93\x92\x91\x90a\x05\xAFV[`@Q` \x81\x83\x03\x03\x81R\x90`@R\x80Q\x90` \x01 \x90P_a\x01x\x823`\x01a\x023\x90\x92\x91\x90c\xFF\xFF\xFF\xFF\x16V[\x14a\x01\xAFW`@Q\x7F|\x9A\x1C\xF9\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x81R`\x04\x01`@Q\x80\x91\x03\x90\xFD[a\x01\xC7\x813`\x01\x80a\x02\xF9\x90\x93\x92\x91\x90c\xFF\xFF\xFF\xFF\x16V[a\x01\xDD\x81`\x01_a\x03\xBF\x90\x92\x91\x90c\xFF\xFF\xFF\xFF\x16V[3s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x81\x7F\xEDno\xDF\x99\xCD^\x97\x14\\~Y\xAD\xE99#\xBE\x19yUzw\xE69\xED\x95\xA2\x03\xC7\xA8\xE8a\x85\x85`@Qa\x02&\x92\x91\x90a\x06$V[`@Q\x80\x91\x03\x90\xA3PPPV[_2s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x82s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x14a\x02\xA2W`@Q\x7F\x08\xC3y\xA0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x81R`\x04\x01a\x02\x99\x90a\x06\xC6V[`@Q\x80\x91\x03\x90\xFD[\x83_\x01_\x84\x81R` \x01\x90\x81R` \x01_ _\x83s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x81R` \x01\x90\x81R` \x01_ T\x90P\x93\x92PPPV[2s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x82s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x14a\x03gW`@Q\x7F\x08\xC3y\xA0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x81R`\x04\x01a\x03^\x90a\x06\xC6V[`@Q\x80\x91\x03\x90\xFD[\x80\x84_\x01_\x85\x81R` \x01\x90\x81R` \x01_ _\x84s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x81R` \x01\x90\x81R` \x01_ \x81\x90UPPPPPV[\x80\x83_\x01_\x84\x81R` \x01\x90\x81R` \x01_ _\x82\x82Ta\x03\xE0\x91\x90a\x07\x1AV[\x92PP\x81\x90UPPPPV[__\xFD[__\xFD[_\x81\x90P\x91\x90PV[a\x04\x06\x81a\x03\xF4V[\x81\x14a\x04\x10W__\xFD[PV[_\x815\x90Pa\x04!\x81a\x03\xFDV[\x92\x91PPV[_` \x82\x84\x03\x12\x15a\x04<Wa\x04;a\x03\xECV[[_a\x04I\x84\x82\x85\x01a\x04\x13V[\x91PP\x92\x91PPV[__\xFD[__\xFD[__\xFD[__\x83`\x1F\x84\x01\x12a\x04sWa\x04ra\x04RV[[\x825\x90Pg\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x11\x15a\x04\x90Wa\x04\x8Fa\x04VV[[` \x83\x01\x91P\x83`\x01\x82\x02\x83\x01\x11\x15a\x04\xACWa\x04\xABa\x04ZV[[\x92P\x92\x90PV[__` \x83\x85\x03\x12\x15a\x04\xC9Wa\x04\xC8a\x03\xECV[[_\x83\x015g\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x11\x15a\x04\xE6Wa\x04\xE5a\x03\xF0V[[a\x04\xF2\x85\x82\x86\x01a\x04^V[\x92P\x92PP\x92P\x92\x90PV[_s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x82\x16\x90P\x91\x90PV[_a\x05'\x82a\x04\xFEV[\x90P\x91\x90PV[_\x81``\x1B\x90P\x91\x90PV[_a\x05D\x82a\x05.V[\x90P\x91\x90PV[_a\x05U\x82a\x05:V[\x90P\x91\x90PV[a\x05ma\x05h\x82a\x05\x1DV[a\x05KV[\x82RPPV[_\x81\x90P\x92\x91PPV[\x82\x81\x837_\x83\x83\x01RPPPV[_a\x05\x96\x83\x85a\x05sV[\x93Pa\x05\xA3\x83\x85\x84a\x05}V[\x82\x84\x01\x90P\x93\x92PPPV[_a\x05\xBA\x82\x86a\x05\\V[`\x14\x82\x01\x91Pa\x05\xCB\x82\x84\x86a\x05\x8BV[\x91P\x81\x90P\x94\x93PPPPV[_\x82\x82R` \x82\x01\x90P\x92\x91PPV[_`\x1F\x19`\x1F\x83\x01\x16\x90P\x91\x90PV[_a\x06\x03\x83\x85a\x05\xD8V[\x93Pa\x06\x10\x83\x85\x84a\x05}V[a\x06\x19\x83a\x05\xE8V[\x84\x01\x90P\x93\x92PPPV[_` \x82\x01\x90P\x81\x81\x03_\x83\x01Ra\x06=\x81\x84\x86a\x05\xF8V[\x90P\x93\x92PPPV[_\x82\x82R` \x82\x01\x90P\x92\x91PPV[\x7FCannot access OwnedCounter owned_\x82\x01R\x7F by another address\0\0\0\0\0\0\0\0\0\0\0\0\0` \x82\x01RPV[_a\x06\xB0`3\x83a\x06FV[\x91Pa\x06\xBB\x82a\x06VV[`@\x82\x01\x90P\x91\x90PV[_` \x82\x01\x90P\x81\x81\x03_\x83\x01Ra\x06\xDD\x81a\x06\xA4V[\x90P\x91\x90PV[_\x81\x90P\x91\x90PV[\x7FNH{q\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0_R`\x11`\x04R`$_\xFD[_a\x07$\x82a\x06\xE4V[\x91Pa\x07/\x83a\x06\xE4V[\x92P\x82\x82\x01\x90P\x80\x82\x11\x15a\x07GWa\x07Fa\x06\xEDV[[\x92\x91PPV",
115 );
116 #[rustfmt::skip]
122 #[allow(clippy::all)]
123 pub static DEPLOYED_BYTECODE: alloy_sol_types::private::Bytes = alloy_sol_types::private::Bytes::from_static(
124 b"`\x80`@R4\x80\x15a\0\x0FW__\xFD[P`\x046\x10a\x004W_5`\xE0\x1C\x80c\xA1\x98\x1B\xF1\x14a\08W\x80c\xDF\xBA\xA2\xFB\x14a\0TW[__\xFD[a\0R`\x04\x806\x03\x81\x01\x90a\0M\x91\x90a\x04'V[a\0pV[\0[a\0n`\x04\x806\x03\x81\x01\x90a\0i\x91\x90a\x04\xB3V[a\x013V[\0[_a\0\x87\x823`\x01a\x023\x90\x92\x91\x90c\xFF\xFF\xFF\xFF\x16V[\x14a\0\xBEW`@Q\x7F|\x9A\x1C\xF9\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x81R`\x04\x01`@Q\x80\x91\x03\x90\xFD[a\0\xD6\x813`\x01\x80a\x02\xF9\x90\x93\x92\x91\x90c\xFF\xFF\xFF\xFF\x16V[a\0\xEC\x81`\x01_a\x03\xBF\x90\x92\x91\x90c\xFF\xFF\xFF\xFF\x16V[3s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x81\x7F\x98\xB6\xB1\x80ul\x84\x9B[\xFB\xBD+\xBD\t\x1F?\xE6K\t5\xAC\x19T\x18\xC0\xB6\x19\xB9\xB6a\xC7\x8D`@Q`@Q\x80\x91\x03\x90\xA3PV[_3\x83\x83`@Q` \x01a\x01I\x93\x92\x91\x90a\x05\xAFV[`@Q` \x81\x83\x03\x03\x81R\x90`@R\x80Q\x90` \x01 \x90P_a\x01x\x823`\x01a\x023\x90\x92\x91\x90c\xFF\xFF\xFF\xFF\x16V[\x14a\x01\xAFW`@Q\x7F|\x9A\x1C\xF9\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x81R`\x04\x01`@Q\x80\x91\x03\x90\xFD[a\x01\xC7\x813`\x01\x80a\x02\xF9\x90\x93\x92\x91\x90c\xFF\xFF\xFF\xFF\x16V[a\x01\xDD\x81`\x01_a\x03\xBF\x90\x92\x91\x90c\xFF\xFF\xFF\xFF\x16V[3s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x81\x7F\xEDno\xDF\x99\xCD^\x97\x14\\~Y\xAD\xE99#\xBE\x19yUzw\xE69\xED\x95\xA2\x03\xC7\xA8\xE8a\x85\x85`@Qa\x02&\x92\x91\x90a\x06$V[`@Q\x80\x91\x03\x90\xA3PPPV[_2s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x82s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x14a\x02\xA2W`@Q\x7F\x08\xC3y\xA0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x81R`\x04\x01a\x02\x99\x90a\x06\xC6V[`@Q\x80\x91\x03\x90\xFD[\x83_\x01_\x84\x81R` \x01\x90\x81R` \x01_ _\x83s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x81R` \x01\x90\x81R` \x01_ T\x90P\x93\x92PPPV[2s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x82s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x14a\x03gW`@Q\x7F\x08\xC3y\xA0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x81R`\x04\x01a\x03^\x90a\x06\xC6V[`@Q\x80\x91\x03\x90\xFD[\x80\x84_\x01_\x85\x81R` \x01\x90\x81R` \x01_ _\x84s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x81R` \x01\x90\x81R` \x01_ \x81\x90UPPPPPV[\x80\x83_\x01_\x84\x81R` \x01\x90\x81R` \x01_ _\x82\x82Ta\x03\xE0\x91\x90a\x07\x1AV[\x92PP\x81\x90UPPPPV[__\xFD[__\xFD[_\x81\x90P\x91\x90PV[a\x04\x06\x81a\x03\xF4V[\x81\x14a\x04\x10W__\xFD[PV[_\x815\x90Pa\x04!\x81a\x03\xFDV[\x92\x91PPV[_` \x82\x84\x03\x12\x15a\x04<Wa\x04;a\x03\xECV[[_a\x04I\x84\x82\x85\x01a\x04\x13V[\x91PP\x92\x91PPV[__\xFD[__\xFD[__\xFD[__\x83`\x1F\x84\x01\x12a\x04sWa\x04ra\x04RV[[\x825\x90Pg\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x11\x15a\x04\x90Wa\x04\x8Fa\x04VV[[` \x83\x01\x91P\x83`\x01\x82\x02\x83\x01\x11\x15a\x04\xACWa\x04\xABa\x04ZV[[\x92P\x92\x90PV[__` \x83\x85\x03\x12\x15a\x04\xC9Wa\x04\xC8a\x03\xECV[[_\x83\x015g\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x11\x15a\x04\xE6Wa\x04\xE5a\x03\xF0V[[a\x04\xF2\x85\x82\x86\x01a\x04^V[\x92P\x92PP\x92P\x92\x90PV[_s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x82\x16\x90P\x91\x90PV[_a\x05'\x82a\x04\xFEV[\x90P\x91\x90PV[_\x81``\x1B\x90P\x91\x90PV[_a\x05D\x82a\x05.V[\x90P\x91\x90PV[_a\x05U\x82a\x05:V[\x90P\x91\x90PV[a\x05ma\x05h\x82a\x05\x1DV[a\x05KV[\x82RPPV[_\x81\x90P\x92\x91PPV[\x82\x81\x837_\x83\x83\x01RPPPV[_a\x05\x96\x83\x85a\x05sV[\x93Pa\x05\xA3\x83\x85\x84a\x05}V[\x82\x84\x01\x90P\x93\x92PPPV[_a\x05\xBA\x82\x86a\x05\\V[`\x14\x82\x01\x91Pa\x05\xCB\x82\x84\x86a\x05\x8BV[\x91P\x81\x90P\x94\x93PPPPV[_\x82\x82R` \x82\x01\x90P\x92\x91PPV[_`\x1F\x19`\x1F\x83\x01\x16\x90P\x91\x90PV[_a\x06\x03\x83\x85a\x05\xD8V[\x93Pa\x06\x10\x83\x85\x84a\x05}V[a\x06\x19\x83a\x05\xE8V[\x84\x01\x90P\x93\x92PPPV[_` \x82\x01\x90P\x81\x81\x03_\x83\x01Ra\x06=\x81\x84\x86a\x05\xF8V[\x90P\x93\x92PPPV[_\x82\x82R` \x82\x01\x90P\x92\x91PPV[\x7FCannot access OwnedCounter owned_\x82\x01R\x7F by another address\0\0\0\0\0\0\0\0\0\0\0\0\0` \x82\x01RPV[_a\x06\xB0`3\x83a\x06FV[\x91Pa\x06\xBB\x82a\x06VV[`@\x82\x01\x90P\x91\x90PV[_` \x82\x01\x90P\x81\x81\x03_\x83\x01Ra\x06\xDD\x81a\x06\xA4V[\x90P\x91\x90PV[_\x81\x90P\x91\x90PV[\x7FNH{q\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0_R`\x11`\x04R`$_\xFD[_a\x07$\x82a\x06\xE4V[\x91Pa\x07/\x83a\x06\xE4V[\x92P\x82\x82\x01\x90P\x80\x82\x11\x15a\x07GWa\x07Fa\x06\xEDV[[\x92\x91PPV",
125 );
126 #[derive(serde::Serialize, serde::Deserialize)]
127 #[derive(Default, Debug, PartialEq, Eq, Hash)]
128 #[allow(non_camel_case_types, non_snake_case, clippy::pub_underscore_fields)]
133 #[derive(Clone)]
134 pub struct AlreadyVoted;
135 #[allow(
136 non_camel_case_types,
137 non_snake_case,
138 clippy::pub_underscore_fields,
139 clippy::style
140 )]
141 const _: () = {
142 use alloy::sol_types as alloy_sol_types;
143 #[doc(hidden)]
144 type UnderlyingSolTuple<'a> = ();
145 #[doc(hidden)]
146 type UnderlyingRustTuple<'a> = ();
147 #[cfg(test)]
148 #[allow(dead_code, unreachable_patterns)]
149 fn _type_assertion(
150 _t: alloy_sol_types::private::AssertTypeEq<UnderlyingRustTuple>,
151 ) {
152 match _t {
153 alloy_sol_types::private::AssertTypeEq::<
154 <UnderlyingSolTuple as alloy_sol_types::SolType>::RustType,
155 >(_) => {}
156 }
157 }
158 #[automatically_derived]
159 #[doc(hidden)]
160 impl ::core::convert::From<AlreadyVoted> for UnderlyingRustTuple<'_> {
161 fn from(value: AlreadyVoted) -> Self {
162 ()
163 }
164 }
165 #[automatically_derived]
166 #[doc(hidden)]
167 impl ::core::convert::From<UnderlyingRustTuple<'_>> for AlreadyVoted {
168 fn from(tuple: UnderlyingRustTuple<'_>) -> Self {
169 Self
170 }
171 }
172 #[automatically_derived]
173 impl alloy_sol_types::SolError for AlreadyVoted {
174 type Parameters<'a> = UnderlyingSolTuple<'a>;
175 type Token<'a> = <Self::Parameters<
176 'a,
177 > as alloy_sol_types::SolType>::Token<'a>;
178 const SIGNATURE: &'static str = "AlreadyVoted()";
179 const SELECTOR: [u8; 4] = [124u8, 154u8, 28u8, 249u8];
180 #[inline]
181 fn new<'a>(
182 tuple: <Self::Parameters<'a> as alloy_sol_types::SolType>::RustType,
183 ) -> Self {
184 tuple.into()
185 }
186 #[inline]
187 fn tokenize(&self) -> Self::Token<'_> {
188 ()
189 }
190 #[inline]
191 fn abi_decode_raw_validate(data: &[u8]) -> alloy_sol_types::Result<Self> {
192 <Self::Parameters<
193 '_,
194 > as alloy_sol_types::SolType>::abi_decode_sequence_validate(data)
195 .map(Self::new)
196 }
197 }
198 };
199 #[derive(serde::Serialize, serde::Deserialize)]
200 #[derive(Default, Debug, PartialEq, Eq, Hash)]
201 #[allow(
206 non_camel_case_types,
207 non_snake_case,
208 clippy::pub_underscore_fields,
209 clippy::style
210 )]
211 #[derive(Clone)]
212 pub struct PostCreated {
213 #[allow(missing_docs)]
214 pub post_id: alloy::sol_types::private::FixedBytes<32>,
215 #[allow(missing_docs)]
216 pub poster: alloy::sol_types::private::Address,
217 #[allow(missing_docs)]
218 pub post_data: alloy::sol_types::private::Bytes,
219 }
220 #[allow(
221 non_camel_case_types,
222 non_snake_case,
223 clippy::pub_underscore_fields,
224 clippy::style
225 )]
226 const _: () = {
227 use alloy::sol_types as alloy_sol_types;
228 #[automatically_derived]
229 impl alloy_sol_types::SolEvent for PostCreated {
230 type DataTuple<'a> = (alloy::sol_types::sol_data::Bytes,);
231 type DataToken<'a> = <Self::DataTuple<
232 'a,
233 > as alloy_sol_types::SolType>::Token<'a>;
234 type TopicList = (
235 alloy_sol_types::sol_data::FixedBytes<32>,
236 alloy::sol_types::sol_data::FixedBytes<32>,
237 alloy::sol_types::sol_data::Address,
238 );
239 const SIGNATURE: &'static str = "PostCreated(bytes32,address,bytes)";
240 const SIGNATURE_HASH: alloy_sol_types::private::B256 = alloy_sol_types::private::B256::new([
241 237u8, 110u8, 111u8, 223u8, 153u8, 205u8, 94u8, 151u8, 20u8, 92u8, 126u8,
242 89u8, 173u8, 233u8, 57u8, 35u8, 190u8, 25u8, 121u8, 85u8, 122u8, 119u8,
243 230u8, 57u8, 237u8, 149u8, 162u8, 3u8, 199u8, 168u8, 232u8, 97u8,
244 ]);
245 const ANONYMOUS: bool = false;
246 #[allow(unused_variables)]
247 #[inline]
248 fn new(
249 topics: <Self::TopicList as alloy_sol_types::SolType>::RustType,
250 data: <Self::DataTuple<'_> as alloy_sol_types::SolType>::RustType,
251 ) -> Self {
252 Self {
253 post_id: topics.1,
254 poster: topics.2,
255 post_data: data.0,
256 }
257 }
258 #[inline]
259 fn check_signature(
260 topics: &<Self::TopicList as alloy_sol_types::SolType>::RustType,
261 ) -> alloy_sol_types::Result<()> {
262 if topics.0 != Self::SIGNATURE_HASH {
263 return Err(
264 alloy_sol_types::Error::invalid_event_signature_hash(
265 Self::SIGNATURE,
266 topics.0,
267 Self::SIGNATURE_HASH,
268 ),
269 );
270 }
271 Ok(())
272 }
273 #[inline]
274 fn tokenize_body(&self) -> Self::DataToken<'_> {
275 (
276 <alloy::sol_types::sol_data::Bytes as alloy_sol_types::SolType>::tokenize(
277 &self.post_data,
278 ),
279 )
280 }
281 #[inline]
282 fn topics(&self) -> <Self::TopicList as alloy_sol_types::SolType>::RustType {
283 (Self::SIGNATURE_HASH.into(), self.post_id.clone(), self.poster.clone())
284 }
285 #[inline]
286 fn encode_topics_raw(
287 &self,
288 out: &mut [alloy_sol_types::abi::token::WordToken],
289 ) -> alloy_sol_types::Result<()> {
290 if out.len() < <Self::TopicList as alloy_sol_types::TopicList>::COUNT {
291 return Err(alloy_sol_types::Error::Overrun);
292 }
293 out[0usize] = alloy_sol_types::abi::token::WordToken(
294 Self::SIGNATURE_HASH,
295 );
296 out[1usize] = <alloy::sol_types::sol_data::FixedBytes<
297 32,
298 > as alloy_sol_types::EventTopic>::encode_topic(&self.post_id);
299 out[2usize] = <alloy::sol_types::sol_data::Address as alloy_sol_types::EventTopic>::encode_topic(
300 &self.poster,
301 );
302 Ok(())
303 }
304 }
305 #[automatically_derived]
306 impl alloy_sol_types::private::IntoLogData for PostCreated {
307 fn to_log_data(&self) -> alloy_sol_types::private::LogData {
308 From::from(self)
309 }
310 fn into_log_data(self) -> alloy_sol_types::private::LogData {
311 From::from(&self)
312 }
313 }
314 #[automatically_derived]
315 impl From<&PostCreated> for alloy_sol_types::private::LogData {
316 #[inline]
317 fn from(this: &PostCreated) -> alloy_sol_types::private::LogData {
318 alloy_sol_types::SolEvent::encode_log_data(this)
319 }
320 }
321 };
322 #[derive(serde::Serialize, serde::Deserialize)]
323 #[derive(Default, Debug, PartialEq, Eq, Hash)]
324 #[allow(
329 non_camel_case_types,
330 non_snake_case,
331 clippy::pub_underscore_fields,
332 clippy::style
333 )]
334 #[derive(Clone)]
335 pub struct PostVoted {
336 #[allow(missing_docs)]
337 pub post_id: alloy::sol_types::private::FixedBytes<32>,
338 #[allow(missing_docs)]
339 pub voter: alloy::sol_types::private::Address,
340 }
341 #[allow(
342 non_camel_case_types,
343 non_snake_case,
344 clippy::pub_underscore_fields,
345 clippy::style
346 )]
347 const _: () = {
348 use alloy::sol_types as alloy_sol_types;
349 #[automatically_derived]
350 impl alloy_sol_types::SolEvent for PostVoted {
351 type DataTuple<'a> = ();
352 type DataToken<'a> = <Self::DataTuple<
353 'a,
354 > as alloy_sol_types::SolType>::Token<'a>;
355 type TopicList = (
356 alloy_sol_types::sol_data::FixedBytes<32>,
357 alloy::sol_types::sol_data::FixedBytes<32>,
358 alloy::sol_types::sol_data::Address,
359 );
360 const SIGNATURE: &'static str = "PostVoted(bytes32,address)";
361 const SIGNATURE_HASH: alloy_sol_types::private::B256 = alloy_sol_types::private::B256::new([
362 152u8, 182u8, 177u8, 128u8, 117u8, 108u8, 132u8, 155u8, 91u8, 251u8,
363 189u8, 43u8, 189u8, 9u8, 31u8, 63u8, 230u8, 75u8, 9u8, 53u8, 172u8, 25u8,
364 84u8, 24u8, 192u8, 182u8, 25u8, 185u8, 182u8, 97u8, 199u8, 141u8,
365 ]);
366 const ANONYMOUS: bool = false;
367 #[allow(unused_variables)]
368 #[inline]
369 fn new(
370 topics: <Self::TopicList as alloy_sol_types::SolType>::RustType,
371 data: <Self::DataTuple<'_> as alloy_sol_types::SolType>::RustType,
372 ) -> Self {
373 Self {
374 post_id: topics.1,
375 voter: topics.2,
376 }
377 }
378 #[inline]
379 fn check_signature(
380 topics: &<Self::TopicList as alloy_sol_types::SolType>::RustType,
381 ) -> alloy_sol_types::Result<()> {
382 if topics.0 != Self::SIGNATURE_HASH {
383 return Err(
384 alloy_sol_types::Error::invalid_event_signature_hash(
385 Self::SIGNATURE,
386 topics.0,
387 Self::SIGNATURE_HASH,
388 ),
389 );
390 }
391 Ok(())
392 }
393 #[inline]
394 fn tokenize_body(&self) -> Self::DataToken<'_> {
395 ()
396 }
397 #[inline]
398 fn topics(&self) -> <Self::TopicList as alloy_sol_types::SolType>::RustType {
399 (Self::SIGNATURE_HASH.into(), self.post_id.clone(), self.voter.clone())
400 }
401 #[inline]
402 fn encode_topics_raw(
403 &self,
404 out: &mut [alloy_sol_types::abi::token::WordToken],
405 ) -> alloy_sol_types::Result<()> {
406 if out.len() < <Self::TopicList as alloy_sol_types::TopicList>::COUNT {
407 return Err(alloy_sol_types::Error::Overrun);
408 }
409 out[0usize] = alloy_sol_types::abi::token::WordToken(
410 Self::SIGNATURE_HASH,
411 );
412 out[1usize] = <alloy::sol_types::sol_data::FixedBytes<
413 32,
414 > as alloy_sol_types::EventTopic>::encode_topic(&self.post_id);
415 out[2usize] = <alloy::sol_types::sol_data::Address as alloy_sol_types::EventTopic>::encode_topic(
416 &self.voter,
417 );
418 Ok(())
419 }
420 }
421 #[automatically_derived]
422 impl alloy_sol_types::private::IntoLogData for PostVoted {
423 fn to_log_data(&self) -> alloy_sol_types::private::LogData {
424 From::from(self)
425 }
426 fn into_log_data(self) -> alloy_sol_types::private::LogData {
427 From::from(&self)
428 }
429 }
430 #[automatically_derived]
431 impl From<&PostVoted> for alloy_sol_types::private::LogData {
432 #[inline]
433 fn from(this: &PostVoted) -> alloy_sol_types::private::LogData {
434 alloy_sol_types::SolEvent::encode_log_data(this)
435 }
436 }
437 };
438 #[derive(serde::Serialize, serde::Deserialize)]
439 #[derive(Default, Debug, PartialEq, Eq, Hash)]
440 #[allow(non_camel_case_types, non_snake_case, clippy::pub_underscore_fields)]
445 #[derive(Clone)]
446 pub struct createPostCall {
447 #[allow(missing_docs)]
448 pub post_data: alloy::sol_types::private::Bytes,
449 }
450 #[allow(non_camel_case_types, non_snake_case, clippy::pub_underscore_fields)]
452 #[derive(Clone)]
453 pub struct createPostReturn {}
454 #[allow(
455 non_camel_case_types,
456 non_snake_case,
457 clippy::pub_underscore_fields,
458 clippy::style
459 )]
460 const _: () = {
461 use alloy::sol_types as alloy_sol_types;
462 {
463 #[doc(hidden)]
464 type UnderlyingSolTuple<'a> = (alloy::sol_types::sol_data::Bytes,);
465 #[doc(hidden)]
466 type UnderlyingRustTuple<'a> = (alloy::sol_types::private::Bytes,);
467 #[cfg(test)]
468 #[allow(dead_code, unreachable_patterns)]
469 fn _type_assertion(
470 _t: alloy_sol_types::private::AssertTypeEq<UnderlyingRustTuple>,
471 ) {
472 match _t {
473 alloy_sol_types::private::AssertTypeEq::<
474 <UnderlyingSolTuple as alloy_sol_types::SolType>::RustType,
475 >(_) => {}
476 }
477 }
478 #[automatically_derived]
479 #[doc(hidden)]
480 impl ::core::convert::From<createPostCall> for UnderlyingRustTuple<'_> {
481 fn from(value: createPostCall) -> Self {
482 (value.post_data,)
483 }
484 }
485 #[automatically_derived]
486 #[doc(hidden)]
487 impl ::core::convert::From<UnderlyingRustTuple<'_>> for createPostCall {
488 fn from(tuple: UnderlyingRustTuple<'_>) -> Self {
489 Self { post_data: tuple.0 }
490 }
491 }
492 }
493 {
494 #[doc(hidden)]
495 type UnderlyingSolTuple<'a> = ();
496 #[doc(hidden)]
497 type UnderlyingRustTuple<'a> = ();
498 #[cfg(test)]
499 #[allow(dead_code, unreachable_patterns)]
500 fn _type_assertion(
501 _t: alloy_sol_types::private::AssertTypeEq<UnderlyingRustTuple>,
502 ) {
503 match _t {
504 alloy_sol_types::private::AssertTypeEq::<
505 <UnderlyingSolTuple as alloy_sol_types::SolType>::RustType,
506 >(_) => {}
507 }
508 }
509 #[automatically_derived]
510 #[doc(hidden)]
511 impl ::core::convert::From<createPostReturn> for UnderlyingRustTuple<'_> {
512 fn from(value: createPostReturn) -> Self {
513 ()
514 }
515 }
516 #[automatically_derived]
517 #[doc(hidden)]
518 impl ::core::convert::From<UnderlyingRustTuple<'_>> for createPostReturn {
519 fn from(tuple: UnderlyingRustTuple<'_>) -> Self {
520 Self {}
521 }
522 }
523 }
524 impl createPostReturn {
525 fn _tokenize(
526 &self,
527 ) -> <createPostCall as alloy_sol_types::SolCall>::ReturnToken<'_> {
528 ()
529 }
530 }
531 #[automatically_derived]
532 impl alloy_sol_types::SolCall for createPostCall {
533 type Parameters<'a> = (alloy::sol_types::sol_data::Bytes,);
534 type Token<'a> = <Self::Parameters<
535 'a,
536 > as alloy_sol_types::SolType>::Token<'a>;
537 type Return = createPostReturn;
538 type ReturnTuple<'a> = ();
539 type ReturnToken<'a> = <Self::ReturnTuple<
540 'a,
541 > as alloy_sol_types::SolType>::Token<'a>;
542 const SIGNATURE: &'static str = "createPost(bytes)";
543 const SELECTOR: [u8; 4] = [223u8, 186u8, 162u8, 251u8];
544 #[inline]
545 fn new<'a>(
546 tuple: <Self::Parameters<'a> as alloy_sol_types::SolType>::RustType,
547 ) -> Self {
548 tuple.into()
549 }
550 #[inline]
551 fn tokenize(&self) -> Self::Token<'_> {
552 (
553 <alloy::sol_types::sol_data::Bytes as alloy_sol_types::SolType>::tokenize(
554 &self.post_data,
555 ),
556 )
557 }
558 #[inline]
559 fn tokenize_returns(ret: &Self::Return) -> Self::ReturnToken<'_> {
560 createPostReturn::_tokenize(ret)
561 }
562 #[inline]
563 fn abi_decode_returns(data: &[u8]) -> alloy_sol_types::Result<Self::Return> {
564 <Self::ReturnTuple<
565 '_,
566 > as alloy_sol_types::SolType>::abi_decode_sequence(data)
567 .map(Into::into)
568 }
569 #[inline]
570 fn abi_decode_returns_validate(
571 data: &[u8],
572 ) -> alloy_sol_types::Result<Self::Return> {
573 <Self::ReturnTuple<
574 '_,
575 > as alloy_sol_types::SolType>::abi_decode_sequence_validate(data)
576 .map(Into::into)
577 }
578 }
579 };
580 #[derive(serde::Serialize, serde::Deserialize)]
581 #[derive(Default, Debug, PartialEq, Eq, Hash)]
582 #[allow(non_camel_case_types, non_snake_case, clippy::pub_underscore_fields)]
587 #[derive(Clone)]
588 pub struct votePostCall {
589 #[allow(missing_docs)]
590 pub post_id: alloy::sol_types::private::FixedBytes<32>,
591 }
592 #[allow(non_camel_case_types, non_snake_case, clippy::pub_underscore_fields)]
594 #[derive(Clone)]
595 pub struct votePostReturn {}
596 #[allow(
597 non_camel_case_types,
598 non_snake_case,
599 clippy::pub_underscore_fields,
600 clippy::style
601 )]
602 const _: () = {
603 use alloy::sol_types as alloy_sol_types;
604 {
605 #[doc(hidden)]
606 type UnderlyingSolTuple<'a> = (alloy::sol_types::sol_data::FixedBytes<32>,);
607 #[doc(hidden)]
608 type UnderlyingRustTuple<'a> = (alloy::sol_types::private::FixedBytes<32>,);
609 #[cfg(test)]
610 #[allow(dead_code, unreachable_patterns)]
611 fn _type_assertion(
612 _t: alloy_sol_types::private::AssertTypeEq<UnderlyingRustTuple>,
613 ) {
614 match _t {
615 alloy_sol_types::private::AssertTypeEq::<
616 <UnderlyingSolTuple as alloy_sol_types::SolType>::RustType,
617 >(_) => {}
618 }
619 }
620 #[automatically_derived]
621 #[doc(hidden)]
622 impl ::core::convert::From<votePostCall> for UnderlyingRustTuple<'_> {
623 fn from(value: votePostCall) -> Self {
624 (value.post_id,)
625 }
626 }
627 #[automatically_derived]
628 #[doc(hidden)]
629 impl ::core::convert::From<UnderlyingRustTuple<'_>> for votePostCall {
630 fn from(tuple: UnderlyingRustTuple<'_>) -> Self {
631 Self { post_id: tuple.0 }
632 }
633 }
634 }
635 {
636 #[doc(hidden)]
637 type UnderlyingSolTuple<'a> = ();
638 #[doc(hidden)]
639 type UnderlyingRustTuple<'a> = ();
640 #[cfg(test)]
641 #[allow(dead_code, unreachable_patterns)]
642 fn _type_assertion(
643 _t: alloy_sol_types::private::AssertTypeEq<UnderlyingRustTuple>,
644 ) {
645 match _t {
646 alloy_sol_types::private::AssertTypeEq::<
647 <UnderlyingSolTuple as alloy_sol_types::SolType>::RustType,
648 >(_) => {}
649 }
650 }
651 #[automatically_derived]
652 #[doc(hidden)]
653 impl ::core::convert::From<votePostReturn> for UnderlyingRustTuple<'_> {
654 fn from(value: votePostReturn) -> Self {
655 ()
656 }
657 }
658 #[automatically_derived]
659 #[doc(hidden)]
660 impl ::core::convert::From<UnderlyingRustTuple<'_>> for votePostReturn {
661 fn from(tuple: UnderlyingRustTuple<'_>) -> Self {
662 Self {}
663 }
664 }
665 }
666 impl votePostReturn {
667 fn _tokenize(
668 &self,
669 ) -> <votePostCall as alloy_sol_types::SolCall>::ReturnToken<'_> {
670 ()
671 }
672 }
673 #[automatically_derived]
674 impl alloy_sol_types::SolCall for votePostCall {
675 type Parameters<'a> = (alloy::sol_types::sol_data::FixedBytes<32>,);
676 type Token<'a> = <Self::Parameters<
677 'a,
678 > as alloy_sol_types::SolType>::Token<'a>;
679 type Return = votePostReturn;
680 type ReturnTuple<'a> = ();
681 type ReturnToken<'a> = <Self::ReturnTuple<
682 'a,
683 > as alloy_sol_types::SolType>::Token<'a>;
684 const SIGNATURE: &'static str = "votePost(bytes32)";
685 const SELECTOR: [u8; 4] = [161u8, 152u8, 27u8, 241u8];
686 #[inline]
687 fn new<'a>(
688 tuple: <Self::Parameters<'a> as alloy_sol_types::SolType>::RustType,
689 ) -> Self {
690 tuple.into()
691 }
692 #[inline]
693 fn tokenize(&self) -> Self::Token<'_> {
694 (
695 <alloy::sol_types::sol_data::FixedBytes<
696 32,
697 > as alloy_sol_types::SolType>::tokenize(&self.post_id),
698 )
699 }
700 #[inline]
701 fn tokenize_returns(ret: &Self::Return) -> Self::ReturnToken<'_> {
702 votePostReturn::_tokenize(ret)
703 }
704 #[inline]
705 fn abi_decode_returns(data: &[u8]) -> alloy_sol_types::Result<Self::Return> {
706 <Self::ReturnTuple<
707 '_,
708 > as alloy_sol_types::SolType>::abi_decode_sequence(data)
709 .map(Into::into)
710 }
711 #[inline]
712 fn abi_decode_returns_validate(
713 data: &[u8],
714 ) -> alloy_sol_types::Result<Self::Return> {
715 <Self::ReturnTuple<
716 '_,
717 > as alloy_sol_types::SolType>::abi_decode_sequence_validate(data)
718 .map(Into::into)
719 }
720 }
721 };
722 #[derive(serde::Serialize, serde::Deserialize)]
724 #[derive()]
725 pub enum RankedFeedCalls {
726 #[allow(missing_docs)]
727 createPost(createPostCall),
728 #[allow(missing_docs)]
729 votePost(votePostCall),
730 }
731 #[automatically_derived]
732 impl RankedFeedCalls {
733 pub const SELECTORS: &'static [[u8; 4usize]] = &[
740 [161u8, 152u8, 27u8, 241u8],
741 [223u8, 186u8, 162u8, 251u8],
742 ];
743 }
744 #[automatically_derived]
745 impl alloy_sol_types::SolInterface for RankedFeedCalls {
746 const NAME: &'static str = "RankedFeedCalls";
747 const MIN_DATA_LENGTH: usize = 32usize;
748 const COUNT: usize = 2usize;
749 #[inline]
750 fn selector(&self) -> [u8; 4] {
751 match self {
752 Self::createPost(_) => {
753 <createPostCall as alloy_sol_types::SolCall>::SELECTOR
754 }
755 Self::votePost(_) => <votePostCall as alloy_sol_types::SolCall>::SELECTOR,
756 }
757 }
758 #[inline]
759 fn selector_at(i: usize) -> ::core::option::Option<[u8; 4]> {
760 Self::SELECTORS.get(i).copied()
761 }
762 #[inline]
763 fn valid_selector(selector: [u8; 4]) -> bool {
764 Self::SELECTORS.binary_search(&selector).is_ok()
765 }
766 #[inline]
767 #[allow(non_snake_case)]
768 fn abi_decode_raw(
769 selector: [u8; 4],
770 data: &[u8],
771 ) -> alloy_sol_types::Result<Self> {
772 static DECODE_SHIMS: &[fn(
773 &[u8],
774 ) -> alloy_sol_types::Result<RankedFeedCalls>] = &[
775 {
776 fn votePost(
777 data: &[u8],
778 ) -> alloy_sol_types::Result<RankedFeedCalls> {
779 <votePostCall as alloy_sol_types::SolCall>::abi_decode_raw(data)
780 .map(RankedFeedCalls::votePost)
781 }
782 votePost
783 },
784 {
785 fn createPost(
786 data: &[u8],
787 ) -> alloy_sol_types::Result<RankedFeedCalls> {
788 <createPostCall as alloy_sol_types::SolCall>::abi_decode_raw(
789 data,
790 )
791 .map(RankedFeedCalls::createPost)
792 }
793 createPost
794 },
795 ];
796 let Ok(idx) = Self::SELECTORS.binary_search(&selector) else {
797 return Err(
798 alloy_sol_types::Error::unknown_selector(
799 <Self as alloy_sol_types::SolInterface>::NAME,
800 selector,
801 ),
802 );
803 };
804 DECODE_SHIMS[idx](data)
805 }
806 #[inline]
807 #[allow(non_snake_case)]
808 fn abi_decode_raw_validate(
809 selector: [u8; 4],
810 data: &[u8],
811 ) -> alloy_sol_types::Result<Self> {
812 static DECODE_VALIDATE_SHIMS: &[fn(
813 &[u8],
814 ) -> alloy_sol_types::Result<RankedFeedCalls>] = &[
815 {
816 fn votePost(
817 data: &[u8],
818 ) -> alloy_sol_types::Result<RankedFeedCalls> {
819 <votePostCall as alloy_sol_types::SolCall>::abi_decode_raw_validate(
820 data,
821 )
822 .map(RankedFeedCalls::votePost)
823 }
824 votePost
825 },
826 {
827 fn createPost(
828 data: &[u8],
829 ) -> alloy_sol_types::Result<RankedFeedCalls> {
830 <createPostCall as alloy_sol_types::SolCall>::abi_decode_raw_validate(
831 data,
832 )
833 .map(RankedFeedCalls::createPost)
834 }
835 createPost
836 },
837 ];
838 let Ok(idx) = Self::SELECTORS.binary_search(&selector) else {
839 return Err(
840 alloy_sol_types::Error::unknown_selector(
841 <Self as alloy_sol_types::SolInterface>::NAME,
842 selector,
843 ),
844 );
845 };
846 DECODE_VALIDATE_SHIMS[idx](data)
847 }
848 #[inline]
849 fn abi_encoded_size(&self) -> usize {
850 match self {
851 Self::createPost(inner) => {
852 <createPostCall as alloy_sol_types::SolCall>::abi_encoded_size(inner)
853 }
854 Self::votePost(inner) => {
855 <votePostCall as alloy_sol_types::SolCall>::abi_encoded_size(inner)
856 }
857 }
858 }
859 #[inline]
860 fn abi_encode_raw(&self, out: &mut alloy_sol_types::private::Vec<u8>) {
861 match self {
862 Self::createPost(inner) => {
863 <createPostCall as alloy_sol_types::SolCall>::abi_encode_raw(
864 inner,
865 out,
866 )
867 }
868 Self::votePost(inner) => {
869 <votePostCall as alloy_sol_types::SolCall>::abi_encode_raw(
870 inner,
871 out,
872 )
873 }
874 }
875 }
876 }
877 #[derive(serde::Serialize, serde::Deserialize)]
879 #[derive(Debug, PartialEq, Eq, Hash)]
880 pub enum RankedFeedErrors {
881 #[allow(missing_docs)]
882 AlreadyVoted(AlreadyVoted),
883 }
884 #[automatically_derived]
885 impl RankedFeedErrors {
886 pub const SELECTORS: &'static [[u8; 4usize]] = &[[124u8, 154u8, 28u8, 249u8]];
893 }
894 #[automatically_derived]
895 impl alloy_sol_types::SolInterface for RankedFeedErrors {
896 const NAME: &'static str = "RankedFeedErrors";
897 const MIN_DATA_LENGTH: usize = 0usize;
898 const COUNT: usize = 1usize;
899 #[inline]
900 fn selector(&self) -> [u8; 4] {
901 match self {
902 Self::AlreadyVoted(_) => {
903 <AlreadyVoted as alloy_sol_types::SolError>::SELECTOR
904 }
905 }
906 }
907 #[inline]
908 fn selector_at(i: usize) -> ::core::option::Option<[u8; 4]> {
909 Self::SELECTORS.get(i).copied()
910 }
911 #[inline]
912 fn valid_selector(selector: [u8; 4]) -> bool {
913 Self::SELECTORS.binary_search(&selector).is_ok()
914 }
915 #[inline]
916 #[allow(non_snake_case)]
917 fn abi_decode_raw(
918 selector: [u8; 4],
919 data: &[u8],
920 ) -> alloy_sol_types::Result<Self> {
921 static DECODE_SHIMS: &[fn(
922 &[u8],
923 ) -> alloy_sol_types::Result<RankedFeedErrors>] = &[
924 {
925 fn AlreadyVoted(
926 data: &[u8],
927 ) -> alloy_sol_types::Result<RankedFeedErrors> {
928 <AlreadyVoted as alloy_sol_types::SolError>::abi_decode_raw(data)
929 .map(RankedFeedErrors::AlreadyVoted)
930 }
931 AlreadyVoted
932 },
933 ];
934 let Ok(idx) = Self::SELECTORS.binary_search(&selector) else {
935 return Err(
936 alloy_sol_types::Error::unknown_selector(
937 <Self as alloy_sol_types::SolInterface>::NAME,
938 selector,
939 ),
940 );
941 };
942 DECODE_SHIMS[idx](data)
943 }
944 #[inline]
945 #[allow(non_snake_case)]
946 fn abi_decode_raw_validate(
947 selector: [u8; 4],
948 data: &[u8],
949 ) -> alloy_sol_types::Result<Self> {
950 static DECODE_VALIDATE_SHIMS: &[fn(
951 &[u8],
952 ) -> alloy_sol_types::Result<RankedFeedErrors>] = &[
953 {
954 fn AlreadyVoted(
955 data: &[u8],
956 ) -> alloy_sol_types::Result<RankedFeedErrors> {
957 <AlreadyVoted as alloy_sol_types::SolError>::abi_decode_raw_validate(
958 data,
959 )
960 .map(RankedFeedErrors::AlreadyVoted)
961 }
962 AlreadyVoted
963 },
964 ];
965 let Ok(idx) = Self::SELECTORS.binary_search(&selector) else {
966 return Err(
967 alloy_sol_types::Error::unknown_selector(
968 <Self as alloy_sol_types::SolInterface>::NAME,
969 selector,
970 ),
971 );
972 };
973 DECODE_VALIDATE_SHIMS[idx](data)
974 }
975 #[inline]
976 fn abi_encoded_size(&self) -> usize {
977 match self {
978 Self::AlreadyVoted(inner) => {
979 <AlreadyVoted as alloy_sol_types::SolError>::abi_encoded_size(inner)
980 }
981 }
982 }
983 #[inline]
984 fn abi_encode_raw(&self, out: &mut alloy_sol_types::private::Vec<u8>) {
985 match self {
986 Self::AlreadyVoted(inner) => {
987 <AlreadyVoted as alloy_sol_types::SolError>::abi_encode_raw(
988 inner,
989 out,
990 )
991 }
992 }
993 }
994 }
995 #[derive(serde::Serialize, serde::Deserialize)]
997 #[derive(Debug, PartialEq, Eq, Hash)]
998 pub enum RankedFeedEvents {
999 #[allow(missing_docs)]
1000 PostCreated(PostCreated),
1001 #[allow(missing_docs)]
1002 PostVoted(PostVoted),
1003 }
1004 #[automatically_derived]
1005 impl RankedFeedEvents {
1006 pub const SELECTORS: &'static [[u8; 32usize]] = &[
1013 [
1014 152u8, 182u8, 177u8, 128u8, 117u8, 108u8, 132u8, 155u8, 91u8, 251u8,
1015 189u8, 43u8, 189u8, 9u8, 31u8, 63u8, 230u8, 75u8, 9u8, 53u8, 172u8, 25u8,
1016 84u8, 24u8, 192u8, 182u8, 25u8, 185u8, 182u8, 97u8, 199u8, 141u8,
1017 ],
1018 [
1019 237u8, 110u8, 111u8, 223u8, 153u8, 205u8, 94u8, 151u8, 20u8, 92u8, 126u8,
1020 89u8, 173u8, 233u8, 57u8, 35u8, 190u8, 25u8, 121u8, 85u8, 122u8, 119u8,
1021 230u8, 57u8, 237u8, 149u8, 162u8, 3u8, 199u8, 168u8, 232u8, 97u8,
1022 ],
1023 ];
1024 }
1025 #[automatically_derived]
1026 impl alloy_sol_types::SolEventInterface for RankedFeedEvents {
1027 const NAME: &'static str = "RankedFeedEvents";
1028 const COUNT: usize = 2usize;
1029 fn decode_raw_log(
1030 topics: &[alloy_sol_types::Word],
1031 data: &[u8],
1032 ) -> alloy_sol_types::Result<Self> {
1033 match topics.first().copied() {
1034 Some(<PostCreated as alloy_sol_types::SolEvent>::SIGNATURE_HASH) => {
1035 <PostCreated as alloy_sol_types::SolEvent>::decode_raw_log(
1036 topics,
1037 data,
1038 )
1039 .map(Self::PostCreated)
1040 }
1041 Some(<PostVoted as alloy_sol_types::SolEvent>::SIGNATURE_HASH) => {
1042 <PostVoted as alloy_sol_types::SolEvent>::decode_raw_log(
1043 topics,
1044 data,
1045 )
1046 .map(Self::PostVoted)
1047 }
1048 _ => {
1049 alloy_sol_types::private::Err(alloy_sol_types::Error::InvalidLog {
1050 name: <Self as alloy_sol_types::SolEventInterface>::NAME,
1051 log: alloy_sol_types::private::Box::new(
1052 alloy_sol_types::private::LogData::new_unchecked(
1053 topics.to_vec(),
1054 data.to_vec().into(),
1055 ),
1056 ),
1057 })
1058 }
1059 }
1060 }
1061 }
1062 #[automatically_derived]
1063 impl alloy_sol_types::private::IntoLogData for RankedFeedEvents {
1064 fn to_log_data(&self) -> alloy_sol_types::private::LogData {
1065 match self {
1066 Self::PostCreated(inner) => {
1067 alloy_sol_types::private::IntoLogData::to_log_data(inner)
1068 }
1069 Self::PostVoted(inner) => {
1070 alloy_sol_types::private::IntoLogData::to_log_data(inner)
1071 }
1072 }
1073 }
1074 fn into_log_data(self) -> alloy_sol_types::private::LogData {
1075 match self {
1076 Self::PostCreated(inner) => {
1077 alloy_sol_types::private::IntoLogData::into_log_data(inner)
1078 }
1079 Self::PostVoted(inner) => {
1080 alloy_sol_types::private::IntoLogData::into_log_data(inner)
1081 }
1082 }
1083 }
1084 }
1085 use alloy::contract as alloy_contract;
1086 #[inline]
1090 pub const fn new<
1091 P: alloy_contract::private::Provider<N>,
1092 N: alloy_contract::private::Network,
1093 >(
1094 address: alloy_sol_types::private::Address,
1095 provider: P,
1096 ) -> RankedFeedInstance<P, N> {
1097 RankedFeedInstance::<P, N>::new(address, provider)
1098 }
1099 #[inline]
1105 pub fn deploy<
1106 P: alloy_contract::private::Provider<N>,
1107 N: alloy_contract::private::Network,
1108 >(
1109 provider: P,
1110 ) -> impl ::core::future::Future<
1111 Output = alloy_contract::Result<RankedFeedInstance<P, N>>,
1112 > {
1113 RankedFeedInstance::<P, N>::deploy(provider)
1114 }
1115 #[inline]
1121 pub fn deploy_builder<
1122 P: alloy_contract::private::Provider<N>,
1123 N: alloy_contract::private::Network,
1124 >(provider: P) -> alloy_contract::RawCallBuilder<P, N> {
1125 RankedFeedInstance::<P, N>::deploy_builder(provider)
1126 }
1127 #[derive(Clone)]
1139 pub struct RankedFeedInstance<P, N = alloy_contract::private::Ethereum> {
1140 address: alloy_sol_types::private::Address,
1141 provider: P,
1142 _network: ::core::marker::PhantomData<N>,
1143 }
1144 #[automatically_derived]
1145 impl<P, N> ::core::fmt::Debug for RankedFeedInstance<P, N> {
1146 #[inline]
1147 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
1148 f.debug_tuple("RankedFeedInstance").field(&self.address).finish()
1149 }
1150 }
1151 #[automatically_derived]
1153 impl<
1154 P: alloy_contract::private::Provider<N>,
1155 N: alloy_contract::private::Network,
1156 > RankedFeedInstance<P, N> {
1157 #[inline]
1161 pub const fn new(
1162 address: alloy_sol_types::private::Address,
1163 provider: P,
1164 ) -> Self {
1165 Self {
1166 address,
1167 provider,
1168 _network: ::core::marker::PhantomData,
1169 }
1170 }
1171 #[inline]
1177 pub async fn deploy(
1178 provider: P,
1179 ) -> alloy_contract::Result<RankedFeedInstance<P, N>> {
1180 let call_builder = Self::deploy_builder(provider);
1181 let contract_address = call_builder.deploy().await?;
1182 Ok(Self::new(contract_address, call_builder.provider))
1183 }
1184 #[inline]
1190 pub fn deploy_builder(provider: P) -> alloy_contract::RawCallBuilder<P, N> {
1191 alloy_contract::RawCallBuilder::new_raw_deploy(
1192 provider,
1193 ::core::clone::Clone::clone(&BYTECODE),
1194 )
1195 }
1196 #[inline]
1198 pub const fn address(&self) -> &alloy_sol_types::private::Address {
1199 &self.address
1200 }
1201 #[inline]
1203 pub fn set_address(&mut self, address: alloy_sol_types::private::Address) {
1204 self.address = address;
1205 }
1206 pub fn at(mut self, address: alloy_sol_types::private::Address) -> Self {
1208 self.set_address(address);
1209 self
1210 }
1211 #[inline]
1213 pub const fn provider(&self) -> &P {
1214 &self.provider
1215 }
1216 }
1217 impl<P: ::core::clone::Clone, N> RankedFeedInstance<&P, N> {
1218 #[inline]
1220 pub fn with_cloned_provider(self) -> RankedFeedInstance<P, N> {
1221 RankedFeedInstance {
1222 address: self.address,
1223 provider: ::core::clone::Clone::clone(&self.provider),
1224 _network: ::core::marker::PhantomData,
1225 }
1226 }
1227 }
1228 #[automatically_derived]
1230 impl<
1231 P: alloy_contract::private::Provider<N>,
1232 N: alloy_contract::private::Network,
1233 > RankedFeedInstance<P, N> {
1234 pub fn call_builder<C: alloy_sol_types::SolCall>(
1239 &self,
1240 call: &C,
1241 ) -> alloy_contract::SolCallBuilder<&P, C, N> {
1242 alloy_contract::SolCallBuilder::new_sol(&self.provider, &self.address, call)
1243 }
1244 pub fn createPost(
1246 &self,
1247 post_data: alloy::sol_types::private::Bytes,
1248 ) -> alloy_contract::SolCallBuilder<&P, createPostCall, N> {
1249 self.call_builder(&createPostCall { post_data })
1250 }
1251 pub fn votePost(
1253 &self,
1254 post_id: alloy::sol_types::private::FixedBytes<32>,
1255 ) -> alloy_contract::SolCallBuilder<&P, votePostCall, N> {
1256 self.call_builder(&votePostCall { post_id })
1257 }
1258 }
1259 #[automatically_derived]
1261 impl<
1262 P: alloy_contract::private::Provider<N>,
1263 N: alloy_contract::private::Network,
1264 > RankedFeedInstance<P, N> {
1265 pub fn event_filter<E: alloy_sol_types::SolEvent>(
1270 &self,
1271 ) -> alloy_contract::Event<&P, E, N> {
1272 alloy_contract::Event::new_sol(&self.provider, &self.address)
1273 }
1274 pub fn PostCreated_filter(&self) -> alloy_contract::Event<&P, PostCreated, N> {
1276 self.event_filter::<PostCreated>()
1277 }
1278 pub fn PostVoted_filter(&self) -> alloy_contract::Event<&P, PostVoted, N> {
1280 self.event_filter::<PostVoted>()
1281 }
1282 }
1283}