1#[allow(
39 non_camel_case_types,
40 non_snake_case,
41 clippy::pub_underscore_fields,
42 clippy::style,
43 clippy::empty_structs_with_brackets
44)]
45pub mod Misc {
46 use super::*;
47 use alloy::sol_types as alloy_sol_types;
48 #[rustfmt::skip]
54 #[allow(clippy::all)]
55 pub static BYTECODE: alloy_sol_types::private::Bytes = alloy_sol_types::private::Bytes::from_static(
56 b"`\x80\x80`@R4`\x17W`9\x90\x81`\x1C\x8290\x81PP\xF3[_\x80\xFD\xFE_\x80\xFD\xFE\xA2dipfsX\"\x12 \xF5R \x83\x01,c\xDA\08\x12\x9D\xD1\"\xAB\xAD\xBD\xE8aV\xA2D$ )\x19[\xB1#P*ldsolcC\0\x08\x1C\x003",
57 );
58 #[rustfmt::skip]
64 #[allow(clippy::all)]
65 pub static DEPLOYED_BYTECODE: alloy_sol_types::private::Bytes = alloy_sol_types::private::Bytes::from_static(
66 b"_\x80\xFD\xFE\xA2dipfsX\"\x12 \xF5R \x83\x01,c\xDA\08\x12\x9D\xD1\"\xAB\xAD\xBD\xE8aV\xA2D$ )\x19[\xB1#P*ldsolcC\0\x08\x1C\x003",
67 );
68 #[allow(non_camel_case_types, non_snake_case, clippy::pub_underscore_fields)]
73 #[derive(Clone)]
74 pub struct InvalidCodec {
75 #[allow(missing_docs)]
76 pub _0: u64,
77 }
78 #[allow(
79 non_camel_case_types,
80 non_snake_case,
81 clippy::pub_underscore_fields,
82 clippy::style
83 )]
84 const _: () = {
85 use alloy::sol_types as alloy_sol_types;
86 #[doc(hidden)]
87 type UnderlyingSolTuple<'a> = (alloy::sol_types::sol_data::Uint<64>,);
88 #[doc(hidden)]
89 type UnderlyingRustTuple<'a> = (u64,);
90 #[cfg(test)]
91 #[allow(dead_code, unreachable_patterns)]
92 fn _type_assertion(
93 _t: alloy_sol_types::private::AssertTypeEq<UnderlyingRustTuple>,
94 ) {
95 match _t {
96 alloy_sol_types::private::AssertTypeEq::<
97 <UnderlyingSolTuple as alloy_sol_types::SolType>::RustType,
98 >(_) => {}
99 }
100 }
101 #[automatically_derived]
102 #[doc(hidden)]
103 impl ::core::convert::From<InvalidCodec> for UnderlyingRustTuple<'_> {
104 fn from(value: InvalidCodec) -> Self {
105 (value._0,)
106 }
107 }
108 #[automatically_derived]
109 #[doc(hidden)]
110 impl ::core::convert::From<UnderlyingRustTuple<'_>> for InvalidCodec {
111 fn from(tuple: UnderlyingRustTuple<'_>) -> Self {
112 Self { _0: tuple.0 }
113 }
114 }
115 #[automatically_derived]
116 impl alloy_sol_types::SolError for InvalidCodec {
117 type Parameters<'a> = UnderlyingSolTuple<'a>;
118 type Token<'a> = <Self::Parameters<
119 'a,
120 > as alloy_sol_types::SolType>::Token<'a>;
121 const SIGNATURE: &'static str = "InvalidCodec(uint64)";
122 const SELECTOR: [u8; 4] = [241u8, 246u8, 188u8, 237u8];
123 #[inline]
124 fn new<'a>(
125 tuple: <Self::Parameters<'a> as alloy_sol_types::SolType>::RustType,
126 ) -> Self {
127 tuple.into()
128 }
129 #[inline]
130 fn tokenize(&self) -> Self::Token<'_> {
131 (
132 <alloy::sol_types::sol_data::Uint<
133 64,
134 > as alloy_sol_types::SolType>::tokenize(&self._0),
135 )
136 }
137 }
138 };
139 #[allow(non_camel_case_types, non_snake_case, clippy::pub_underscore_fields)]
144 #[derive(Clone)]
145 pub struct MethodNotHandled {
146 #[allow(missing_docs)]
147 pub _0: u64,
148 }
149 #[allow(
150 non_camel_case_types,
151 non_snake_case,
152 clippy::pub_underscore_fields,
153 clippy::style
154 )]
155 const _: () = {
156 use alloy::sol_types as alloy_sol_types;
157 #[doc(hidden)]
158 type UnderlyingSolTuple<'a> = (alloy::sol_types::sol_data::Uint<64>,);
159 #[doc(hidden)]
160 type UnderlyingRustTuple<'a> = (u64,);
161 #[cfg(test)]
162 #[allow(dead_code, unreachable_patterns)]
163 fn _type_assertion(
164 _t: alloy_sol_types::private::AssertTypeEq<UnderlyingRustTuple>,
165 ) {
166 match _t {
167 alloy_sol_types::private::AssertTypeEq::<
168 <UnderlyingSolTuple as alloy_sol_types::SolType>::RustType,
169 >(_) => {}
170 }
171 }
172 #[automatically_derived]
173 #[doc(hidden)]
174 impl ::core::convert::From<MethodNotHandled> for UnderlyingRustTuple<'_> {
175 fn from(value: MethodNotHandled) -> Self {
176 (value._0,)
177 }
178 }
179 #[automatically_derived]
180 #[doc(hidden)]
181 impl ::core::convert::From<UnderlyingRustTuple<'_>> for MethodNotHandled {
182 fn from(tuple: UnderlyingRustTuple<'_>) -> Self {
183 Self { _0: tuple.0 }
184 }
185 }
186 #[automatically_derived]
187 impl alloy_sol_types::SolError for MethodNotHandled {
188 type Parameters<'a> = UnderlyingSolTuple<'a>;
189 type Token<'a> = <Self::Parameters<
190 'a,
191 > as alloy_sol_types::SolType>::Token<'a>;
192 const SIGNATURE: &'static str = "MethodNotHandled(uint64)";
193 const SELECTOR: [u8; 4] = [250u8, 9u8, 55u8, 97u8];
194 #[inline]
195 fn new<'a>(
196 tuple: <Self::Parameters<'a> as alloy_sol_types::SolType>::RustType,
197 ) -> Self {
198 tuple.into()
199 }
200 #[inline]
201 fn tokenize(&self) -> Self::Token<'_> {
202 (
203 <alloy::sol_types::sol_data::Uint<
204 64,
205 > as alloy_sol_types::SolType>::tokenize(&self._0),
206 )
207 }
208 }
209 };
210 pub enum MiscErrors {
212 #[allow(missing_docs)]
213 InvalidCodec(InvalidCodec),
214 #[allow(missing_docs)]
215 MethodNotHandled(MethodNotHandled),
216 }
217 #[automatically_derived]
218 impl MiscErrors {
219 pub const SELECTORS: &'static [[u8; 4usize]] = &[
226 [241u8, 246u8, 188u8, 237u8],
227 [250u8, 9u8, 55u8, 97u8],
228 ];
229 }
230 #[automatically_derived]
231 impl alloy_sol_types::SolInterface for MiscErrors {
232 const NAME: &'static str = "MiscErrors";
233 const MIN_DATA_LENGTH: usize = 32usize;
234 const COUNT: usize = 2usize;
235 #[inline]
236 fn selector(&self) -> [u8; 4] {
237 match self {
238 Self::InvalidCodec(_) => {
239 <InvalidCodec as alloy_sol_types::SolError>::SELECTOR
240 }
241 Self::MethodNotHandled(_) => {
242 <MethodNotHandled as alloy_sol_types::SolError>::SELECTOR
243 }
244 }
245 }
246 #[inline]
247 fn selector_at(i: usize) -> ::core::option::Option<[u8; 4]> {
248 Self::SELECTORS.get(i).copied()
249 }
250 #[inline]
251 fn valid_selector(selector: [u8; 4]) -> bool {
252 Self::SELECTORS.binary_search(&selector).is_ok()
253 }
254 #[inline]
255 #[allow(non_snake_case)]
256 fn abi_decode_raw(
257 selector: [u8; 4],
258 data: &[u8],
259 validate: bool,
260 ) -> alloy_sol_types::Result<Self> {
261 static DECODE_SHIMS: &[fn(
262 &[u8],
263 bool,
264 ) -> alloy_sol_types::Result<MiscErrors>] = &[
265 {
266 fn InvalidCodec(
267 data: &[u8],
268 validate: bool,
269 ) -> alloy_sol_types::Result<MiscErrors> {
270 <InvalidCodec as alloy_sol_types::SolError>::abi_decode_raw(
271 data,
272 validate,
273 )
274 .map(MiscErrors::InvalidCodec)
275 }
276 InvalidCodec
277 },
278 {
279 fn MethodNotHandled(
280 data: &[u8],
281 validate: bool,
282 ) -> alloy_sol_types::Result<MiscErrors> {
283 <MethodNotHandled as alloy_sol_types::SolError>::abi_decode_raw(
284 data,
285 validate,
286 )
287 .map(MiscErrors::MethodNotHandled)
288 }
289 MethodNotHandled
290 },
291 ];
292 let Ok(idx) = Self::SELECTORS.binary_search(&selector) else {
293 return Err(
294 alloy_sol_types::Error::unknown_selector(
295 <Self as alloy_sol_types::SolInterface>::NAME,
296 selector,
297 ),
298 );
299 };
300 DECODE_SHIMS[idx](data, validate)
301 }
302 #[inline]
303 fn abi_encoded_size(&self) -> usize {
304 match self {
305 Self::InvalidCodec(inner) => {
306 <InvalidCodec as alloy_sol_types::SolError>::abi_encoded_size(inner)
307 }
308 Self::MethodNotHandled(inner) => {
309 <MethodNotHandled as alloy_sol_types::SolError>::abi_encoded_size(
310 inner,
311 )
312 }
313 }
314 }
315 #[inline]
316 fn abi_encode_raw(&self, out: &mut alloy_sol_types::private::Vec<u8>) {
317 match self {
318 Self::InvalidCodec(inner) => {
319 <InvalidCodec as alloy_sol_types::SolError>::abi_encode_raw(
320 inner,
321 out,
322 )
323 }
324 Self::MethodNotHandled(inner) => {
325 <MethodNotHandled as alloy_sol_types::SolError>::abi_encode_raw(
326 inner,
327 out,
328 )
329 }
330 }
331 }
332 }
333 use alloy::contract as alloy_contract;
334 #[inline]
338 pub const fn new<
339 T: alloy_contract::private::Transport + ::core::clone::Clone,
340 P: alloy_contract::private::Provider<T, N>,
341 N: alloy_contract::private::Network,
342 >(address: alloy_sol_types::private::Address, provider: P) -> MiscInstance<T, P, N> {
343 MiscInstance::<T, P, N>::new(address, provider)
344 }
345 #[inline]
351 pub fn deploy<
352 T: alloy_contract::private::Transport + ::core::clone::Clone,
353 P: alloy_contract::private::Provider<T, N>,
354 N: alloy_contract::private::Network,
355 >(
356 provider: P,
357 ) -> impl ::core::future::Future<
358 Output = alloy_contract::Result<MiscInstance<T, P, N>>,
359 > {
360 MiscInstance::<T, P, N>::deploy(provider)
361 }
362 #[inline]
368 pub fn deploy_builder<
369 T: alloy_contract::private::Transport + ::core::clone::Clone,
370 P: alloy_contract::private::Provider<T, N>,
371 N: alloy_contract::private::Network,
372 >(provider: P) -> alloy_contract::RawCallBuilder<T, P, N> {
373 MiscInstance::<T, P, N>::deploy_builder(provider)
374 }
375 #[derive(Clone)]
387 pub struct MiscInstance<T, P, N = alloy_contract::private::Ethereum> {
388 address: alloy_sol_types::private::Address,
389 provider: P,
390 _network_transport: ::core::marker::PhantomData<(N, T)>,
391 }
392 #[automatically_derived]
393 impl<T, P, N> ::core::fmt::Debug for MiscInstance<T, P, N> {
394 #[inline]
395 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
396 f.debug_tuple("MiscInstance").field(&self.address).finish()
397 }
398 }
399 #[automatically_derived]
401 impl<
402 T: alloy_contract::private::Transport + ::core::clone::Clone,
403 P: alloy_contract::private::Provider<T, N>,
404 N: alloy_contract::private::Network,
405 > MiscInstance<T, P, N> {
406 #[inline]
410 pub const fn new(
411 address: alloy_sol_types::private::Address,
412 provider: P,
413 ) -> Self {
414 Self {
415 address,
416 provider,
417 _network_transport: ::core::marker::PhantomData,
418 }
419 }
420 #[inline]
426 pub async fn deploy(
427 provider: P,
428 ) -> alloy_contract::Result<MiscInstance<T, P, N>> {
429 let call_builder = Self::deploy_builder(provider);
430 let contract_address = call_builder.deploy().await?;
431 Ok(Self::new(contract_address, call_builder.provider))
432 }
433 #[inline]
439 pub fn deploy_builder(provider: P) -> alloy_contract::RawCallBuilder<T, P, N> {
440 alloy_contract::RawCallBuilder::new_raw_deploy(
441 provider,
442 ::core::clone::Clone::clone(&BYTECODE),
443 )
444 }
445 #[inline]
447 pub const fn address(&self) -> &alloy_sol_types::private::Address {
448 &self.address
449 }
450 #[inline]
452 pub fn set_address(&mut self, address: alloy_sol_types::private::Address) {
453 self.address = address;
454 }
455 pub fn at(mut self, address: alloy_sol_types::private::Address) -> Self {
457 self.set_address(address);
458 self
459 }
460 #[inline]
462 pub const fn provider(&self) -> &P {
463 &self.provider
464 }
465 }
466 impl<T, P: ::core::clone::Clone, N> MiscInstance<T, &P, N> {
467 #[inline]
469 pub fn with_cloned_provider(self) -> MiscInstance<T, P, N> {
470 MiscInstance {
471 address: self.address,
472 provider: ::core::clone::Clone::clone(&self.provider),
473 _network_transport: ::core::marker::PhantomData,
474 }
475 }
476 }
477 #[automatically_derived]
479 impl<
480 T: alloy_contract::private::Transport + ::core::clone::Clone,
481 P: alloy_contract::private::Provider<T, N>,
482 N: alloy_contract::private::Network,
483 > MiscInstance<T, P, N> {
484 pub fn call_builder<C: alloy_sol_types::SolCall>(
489 &self,
490 call: &C,
491 ) -> alloy_contract::SolCallBuilder<T, &P, C, N> {
492 alloy_contract::SolCallBuilder::new_sol(&self.provider, &self.address, call)
493 }
494 }
495 #[automatically_derived]
497 impl<
498 T: alloy_contract::private::Transport + ::core::clone::Clone,
499 P: alloy_contract::private::Provider<T, N>,
500 N: alloy_contract::private::Network,
501 > MiscInstance<T, P, N> {
502 pub fn event_filter<E: alloy_sol_types::SolEvent>(
507 &self,
508 ) -> alloy_contract::Event<T, &P, E, N> {
509 alloy_contract::Event::new_sol(&self.provider, &self.address)
510 }
511 }
512}