diff --git a/.github/workflows/nodejs.yml b/.github/workflows/nodejs.yml index 99affb7..cc29524 100644 --- a/.github/workflows/nodejs.yml +++ b/.github/workflows/nodejs.yml @@ -26,6 +26,9 @@ jobs: # each workflow consists of 1+ jobs; by default, all jobs run in parallel - name: Install dependencies 📦 run: yarn install --frozen-lockfile + - name: Run prettier check + run: yarn prettier + - name: Install Foundry uses: foundry-rs/foundry-toolchain@v1 with: diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 7cecc27..5bd4d88 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -1,7 +1,12 @@ name: Publish package + on: release: types: [ published ] + +env: + CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }} + jobs: npm_publish: runs-on: ubuntu-latest @@ -28,3 +33,31 @@ jobs: - run: npm publish --access public env: NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} + + cargo_publish: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + with: + submodules: recursive + + - name: Use Node.js 18.x + uses: actions/setup-node@v3 + with: + node-version: 18.x + cache: "yarn" + cache-dependency-path: "yarn.lock" + + - name: Install dependencies 📦 + run: yarn install --frozen-lockfile + + - name: Install Foundry + uses: foundry-rs/foundry-toolchain@v1 + with: + version: nightly + + - name: Generate contract Rust bindings + run: forge bind -b src/bindings/ --module --overwrite + + - name: Publish to crates.io + run: cargo publish diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index dfbdfda..fa52843 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -8,11 +8,10 @@ on: env: CARGO_TERM_COLOR: always - INFURA_API_KEY: ${{ secrets.INFURA_API_KEY }} jobs: - build: - name: Rust Tests + lint: + name: Lint runs-on: ubuntu-latest timeout-minutes: 30 steps: @@ -20,6 +19,73 @@ jobs: with: submodules: recursive + - name: Use Node.js 18.x + uses: actions/setup-node@v3 + with: + node-version: 18.x + cache: "yarn" + cache-dependency-path: "yarn.lock" + + - name: Install dependencies 📦 + run: yarn install --frozen-lockfile + + - name: Install Foundry + uses: foundry-rs/foundry-toolchain@v1 + with: + version: nightly + + - name: Generate contract Rust bindings + run: forge bind -b src/bindings/ --module --overwrite + + - name: Cache Cargo registry + uses: actions/cache@v3 + with: + path: | + ~/.cargo/registry + ~/.cargo/git + target + key: ${{ runner.os }}-cargo-registry-${{ hashFiles('**/Cargo.lock') }} + restore-keys: | + ${{ runner.os }}-cargo-registry- + + - name: Install Rust toolchain + uses: actions-rs/toolchain@v1 + with: + profile: minimal + toolchain: nightly + override: true + components: clippy + + - name: Check lint + run: cargo clippy -- -D warnings + + test: + name: Test + runs-on: ubuntu-latest + timeout-minutes: 30 + steps: + - uses: actions/checkout@v3 + with: + submodules: recursive + + - name: Use Node.js 18.x + uses: actions/setup-node@v3 + with: + node-version: 18.x + cache: "yarn" + cache-dependency-path: "yarn.lock" + + - name: Install dependencies 📦 + run: yarn install --frozen-lockfile + + - name: Install Foundry + uses: foundry-rs/foundry-toolchain@v1 + with: + version: nightly + + - name: Generate contract Rust bindings + run: forge bind -b src/bindings/ --module --overwrite + - name: Cache Cargo registry uses: actions/cache@v3 with: @@ -32,7 +98,7 @@ jobs: ${{ runner.os }}-cargo-registry- - name: Build - run: cargo build --verbose + run: cargo build - name: Run tests - run: cargo test --verbose + run: cargo test diff --git a/.gitignore b/.gitignore index 478587f..f2709d4 100644 --- a/.gitignore +++ b/.gitignore @@ -136,6 +136,7 @@ dist # Foundry cache cache dry-run +src/bindings # Hardhat cache artifacts diff --git a/Cargo.lock b/Cargo.lock index 2a650aa..943c287 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -49,16 +49,15 @@ dependencies = [ [[package]] name = "anyhow" -version = "1.0.75" +version = "1.0.79" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4668cab20f66d8d020e1fbc0ebe47217433c1b6c8f2040faf858554e394ace6" +checksum = "080e9890a082662b09c1ad45f567faeeb47f22b5fb23895fbe1e651e718e25ca" [[package]] name = "aperture-lens" -version = "0.3.0" +version = "0.4.0" dependencies = [ "anyhow", - "dotenv", "ethers", "futures", "serde", @@ -82,13 +81,13 @@ dependencies = [ [[package]] name = "async-trait" -version = "0.1.74" +version = "0.1.77" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a66537f1bb974b254c98ed142ff995236e81b9d0fe4db0575f46612cb15eb0f9" +checksum = "c980ee35e870bd1a4d2c8294d4c04d0499e67bca1e4b5cefcc693c2fa00caea9" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.47", ] [[package]] @@ -282,9 +281,9 @@ dependencies = [ [[package]] name = "cargo-platform" -version = "0.1.5" +version = "0.1.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e34637b3140142bdf929fb439e8aa4ebad7651ebf7b1080b3930aa16ac1459ff" +checksum = "ceed8ef69d8518a5dda55c07425450b58a4e1946f4951eab6d7191ee86c2443d" dependencies = [ "serde", ] @@ -405,9 +404,9 @@ dependencies = [ [[package]] name = "const-oid" -version = "0.9.5" +version = "0.9.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "28c122c3980598d243d63d9a704629a2d748d101f278052ff068be5a4423ab6f" +checksum = "c2459377285ad874054d797f3ccebf984978aa39129f6eafde5cdc8315b612f8" [[package]] name = "constant_time_eq" @@ -451,9 +450,9 @@ dependencies = [ [[package]] name = "crossbeam-deque" -version = "0.8.3" +version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce6fd6f855243022dcecf8702fef0c297d4338e226845fe067f6341ad9fa0cef" +checksum = "fca89a0e215bab21874660c67903c5f143333cab1da83d041c7ded6053774751" dependencies = [ "cfg-if", "crossbeam-epoch", @@ -462,22 +461,20 @@ dependencies = [ [[package]] name = "crossbeam-epoch" -version = "0.9.15" +version = "0.9.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae211234986c545741a7dc064309f67ee1e5ad243d0e48335adc0484d960bcc7" +checksum = "0e3681d554572a651dda4186cd47240627c3d0114d45a95f6ad27f2f22e7548d" dependencies = [ "autocfg", "cfg-if", "crossbeam-utils", - "memoffset", - "scopeguard", ] [[package]] name = "crossbeam-utils" -version = "0.8.16" +version = "0.8.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a22b2d63d4d1dc0b7f1b6b2747dd0088008a9be28b6ddf0b1e7d335e3037294" +checksum = "c3a430a770ebd84726f584a90ee7f020d28db52c6d02138900f22341f866d39c" dependencies = [ "cfg-if", ] @@ -537,9 +534,9 @@ dependencies = [ [[package]] name = "deranged" -version = "0.3.10" +version = "0.3.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8eb30d70a07a3b04884d2677f06bec33509dc67ca60d92949e5535352d3191dc" +checksum = "b42b6fa04a440b495c8b04d0e71b707c585f83cb9cb28cf8cd0d976c315e31b4" dependencies = [ "powerfmt", ] @@ -615,12 +612,6 @@ dependencies = [ "winapi", ] -[[package]] -name = "dotenv" -version = "0.15.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77c90badedccf4105eca100756a0b1289e191f6fcbdadd3cee1d2f614f97da8f" - [[package]] name = "dunce" version = "1.0.4" @@ -854,7 +845,7 @@ dependencies = [ "reqwest", "serde", "serde_json", - "syn 2.0.39", + "syn 2.0.47", "toml", "walkdir", ] @@ -872,7 +863,7 @@ dependencies = [ "proc-macro2", "quote", "serde_json", - "syn 2.0.39", + "syn 2.0.47", ] [[package]] @@ -898,7 +889,7 @@ dependencies = [ "serde", "serde_json", "strum", - "syn 2.0.39", + "syn 2.0.47", "tempfile", "thiserror", "tiny-keccak", @@ -1038,9 +1029,9 @@ dependencies = [ [[package]] name = "eyre" -version = "0.6.9" +version = "0.6.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "80f656be11ddf91bd709454d15d5bd896fbaf4cc3314e69349e4d1569f5b46cd" +checksum = "b6267a1fa6f59179ea4afc8e50fd8612a3cc60bc858f786ff877a4a8cb042799" dependencies = [ "indenter", "once_cell", @@ -1123,9 +1114,9 @@ checksum = "e6d5a32815ae3f33302d95fdcb2ce17862f8c65363dcfd29360480ba1001fc9c" [[package]] name = "futures" -version = "0.3.29" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da0290714b38af9b4a7b094b8a37086d1b4e61f2df9122c3cad2577669145335" +checksum = "645c6916888f6cb6350d2550b80fb63e734897a8498abe35cfb732b6487804b0" dependencies = [ "futures-channel", "futures-core", @@ -1138,9 +1129,9 @@ dependencies = [ [[package]] name = "futures-channel" -version = "0.3.29" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff4dd66668b557604244583e3e1e1eada8c5c2e96a6d0d6653ede395b78bbacb" +checksum = "eac8f7d7865dcb88bd4373ab671c8cf4508703796caa2b1985a9ca867b3fcb78" dependencies = [ "futures-core", "futures-sink", @@ -1148,15 +1139,15 @@ dependencies = [ [[package]] name = "futures-core" -version = "0.3.29" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eb1d22c66e66d9d72e1758f0bd7d4fd0bee04cad842ee34587d68c07e45d088c" +checksum = "dfc6580bb841c5a68e9ef15c77ccc837b40a7504914d52e47b8b0e9bbda25a1d" [[package]] name = "futures-executor" -version = "0.3.29" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f4fb8693db0cf099eadcca0efe2a5a22e4550f98ed16aba6c48700da29597bc" +checksum = "a576fc72ae164fca6b9db127eaa9a9dda0d61316034f33a0a0d4eda41f02b01d" dependencies = [ "futures-core", "futures-task", @@ -1165,9 +1156,9 @@ dependencies = [ [[package]] name = "futures-io" -version = "0.3.29" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8bf34a163b5c4c52d0478a4d757da8fb65cabef42ba90515efee0f6f9fa45aaa" +checksum = "a44623e20b9681a318efdd71c299b6b222ed6f231972bfe2f224ebad6311f0c1" [[package]] name = "futures-locks" @@ -1181,26 +1172,26 @@ dependencies = [ [[package]] name = "futures-macro" -version = "0.3.29" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53b153fd91e4b0147f4aced87be237c98248656bb01050b96bf3ee89220a8ddb" +checksum = "87750cf4b7a4c0625b1529e4c543c2182106e4dedc60a2a6455e00d212c489ac" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.47", ] [[package]] name = "futures-sink" -version = "0.3.29" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e36d3378ee38c2a36ad710c5d30c2911d752cb941c00c72dbabfb786a7970817" +checksum = "9fb8e00e87438d937621c1c6269e53f536c14d3fbd6a042bb24879e57d474fb5" [[package]] name = "futures-task" -version = "0.3.29" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "efd193069b0ddadc69c46389b740bbccdd97203899b48d09c5f7969591d6bae2" +checksum = "38d84fa142264698cdce1a9f9172cf383a0c82de1bddcf3092901442c4097004" [[package]] name = "futures-timer" @@ -1214,9 +1205,9 @@ dependencies = [ [[package]] name = "futures-util" -version = "0.3.29" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a19526d624e703a3179b3d322efec918b6246ea0fa51d41124525f00f1cc8104" +checksum = "3d6401deb83407ab3da39eba7e33987a73c3df0c82b4bb5813ee871c19c41d48" dependencies = [ "futures-channel", "futures-core", @@ -1359,11 +1350,11 @@ dependencies = [ [[package]] name = "home" -version = "0.5.5" +version = "0.5.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5444c27eef6923071f7ebcc33e3444508466a76f7a2b93da00ed6e19f30c1ddb" +checksum = "e3d1354bf6b7235cb4a0576c2619fd4ed18183f689b12b006a0ee7329eeff9a5" dependencies = [ - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] [[package]] @@ -1379,9 +1370,9 @@ dependencies = [ [[package]] name = "http-body" -version = "0.4.5" +version = "0.4.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d5f38f16d184e36f2408a55281cd658ecbd3ca05cce6d6510a176eca393e26d1" +checksum = "7ceab25649e9960c0311ea418d17bee82c0dcec1bd053b5f9a66e265a693bed2" dependencies = [ "bytes", "http", @@ -1402,9 +1393,9 @@ checksum = "df3b46402a9d5adb4c86a0cf463f42e19994e3ee891101b1841f30a545cb49a9" [[package]] name = "hyper" -version = "0.14.27" +version = "0.14.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ffb1cfd654a8219eaef89881fdb3bb3b1cdc5fa75ded05d6933b2b382e395468" +checksum = "bf96e135eb83a2a8ddf766e426a841d8ddd7449d5f00d34ea02b41d2f19eef80" dependencies = [ "bytes", "futures-channel", @@ -1417,7 +1408,7 @@ dependencies = [ "httpdate", "itoa", "pin-project-lite", - "socket2 0.4.10", + "socket2", "tokio", "tower-service", "tracing", @@ -1528,13 +1519,13 @@ checksum = "8f518f335dce6725a761382244631d86cf0ccb2863413590b31338feb467f9c3" [[package]] name = "is-terminal" -version = "0.4.9" +version = "0.4.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cb0889898416213fab133e1d33a0e5858a48177452750691bde3666d0fdbaf8b" +checksum = "0bad00257d07be169d870ab665980b06cdb366d792ad690bf2e76876dc503455" dependencies = [ "hermit-abi", "rustix", - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] [[package]] @@ -1557,9 +1548,9 @@ dependencies = [ [[package]] name = "itoa" -version = "1.0.9" +version = "1.0.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af150ab688ff2122fcef229be89cb50dd66af9e01a4ff320cc137eecc9bacc38" +checksum = "b1a46d1a171d865aa5f83f92695765caa047a9b4cbae2cbf37dbd613a793fd4c" [[package]] name = "jobserver" @@ -1652,9 +1643,9 @@ checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" [[package]] name = "libc" -version = "0.2.150" +version = "0.2.151" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89d92a4743f9a61002fae18374ed11e7973f530cb3a3255fb354818118b2203c" +checksum = "302d7ab3130588088d277783b1e2d2e10c9e9e4a16dd9050e6ec93fb3e7048f4" [[package]] name = "libm" @@ -1707,18 +1698,9 @@ dependencies = [ [[package]] name = "memchr" -version = "2.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f665ee40bc4a3c5590afb1e9677db74a508659dfd71e126420da8274909a0167" - -[[package]] -name = "memoffset" -version = "0.9.0" +version = "2.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a634b1c61a95585bd15607c6ab0c4e5b226e695ff2800ba0cdccddf208c406c" -dependencies = [ - "autocfg", -] +checksum = "523dc4f511e55ab87b694dc30d0f820d60906ef06413f93d4d7a1385599cc149" [[package]] name = "mime" @@ -1737,9 +1719,9 @@ dependencies = [ [[package]] name = "mio" -version = "0.8.9" +version = "0.8.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3dce281c5e46beae905d4de1870d8b1509a9142b62eedf18b443b011ca8343d0" +checksum = "8f3d0b296e374a4e6f3c7b0a1f5a51d748a0d34c85e7dc48fc3fa9a87657fe09" dependencies = [ "libc", "wasi", @@ -1808,26 +1790,26 @@ version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6c11e44798ad209ccdd91fc192f0526a369a01234f7373e1b141c96d7cee4f0e" dependencies = [ - "proc-macro-crate 2.0.0", + "proc-macro-crate 2.0.1", "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.47", ] [[package]] name = "object" -version = "0.32.1" +version = "0.32.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9cf5f9dd3933bd50a9e1f149ec995f39ae2c496d31fd772c1fd45ebc27e902b0" +checksum = "a6a622008b6e321afc04970976f62ee297fdbaa6f95318ca343e3eebb9648441" dependencies = [ "memchr", ] [[package]] name = "once_cell" -version = "1.18.0" +version = "1.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd8b5dd2ae5ed71462c540258bedcb51965123ad7e7ccf4b9a8cafaa4a63576d" +checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" [[package]] name = "open-fastrlp" @@ -1880,7 +1862,7 @@ version = "3.6.9" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "be30eaf4b0a9fba5336683b38de57bb86d179a35862ba6bfcf57625d006bde5b" dependencies = [ - "proc-macro-crate 2.0.0", + "proc-macro-crate 2.0.1", "proc-macro2", "quote", "syn 1.0.109", @@ -2013,7 +1995,7 @@ dependencies = [ "phf_shared 0.11.2", "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.47", ] [[package]] @@ -2051,7 +2033,7 @@ checksum = "4359fd9c9171ec6e8c62926d6faaf553a8dc3f64e1507e76da7911b4f6a04405" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.47", ] [[package]] @@ -2078,9 +2060,9 @@ dependencies = [ [[package]] name = "pkg-config" -version = "0.3.27" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26072860ba924cbfa98ea39c8c19b4dd6a4a25423dbdf219c1eca91aa0cf6964" +checksum = "69d3587f8a9e599cc7ec2c00e331f71c4e69a5f9a4b8a6efd5b07466b9736f9a" [[package]] name = "powerfmt" @@ -2102,12 +2084,12 @@ checksum = "925383efa346730478fb4838dbe9137d2a47675ad789c546d150a6e1dd4ab31c" [[package]] name = "prettyplease" -version = "0.2.15" +version = "0.2.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae005bd773ab59b4725093fd7df83fd7892f7d8eafb48dbd7de6e024e4215f9d" +checksum = "a41cf62165e97c7f814d2221421dbb9afcbcdb0a88068e5ea206e19951c2cbb5" dependencies = [ "proc-macro2", - "syn 2.0.39", + "syn 2.0.47", ] [[package]] @@ -2136,11 +2118,12 @@ dependencies = [ [[package]] name = "proc-macro-crate" -version = "2.0.0" +version = "2.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7e8366a6159044a37876a2b9817124296703c586a5c92e2c53751fa06d8d43e8" +checksum = "97dc5fea232fc28d2f597b37c4876b348a40e33f3b02cc975c8d006d78d94b1a" dependencies = [ - "toml_edit 0.20.7", + "toml_datetime", + "toml_edit 0.20.2", ] [[package]] @@ -2169,9 +2152,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.70" +version = "1.0.75" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39278fbbf5fb4f646ce651690877f89d1c5811a3d4acb27700c1cb3cdb78fd3b" +checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" dependencies = [ "unicode-ident", ] @@ -2194,9 +2177,9 @@ dependencies = [ [[package]] name = "quote" -version = "1.0.33" +version = "1.0.35" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5267fca4496028628a95160fc423a33e8b2e6af8a5302579e322e4b520293cae" +checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" dependencies = [ "proc-macro2", ] @@ -2323,9 +2306,9 @@ checksum = "c08c74e62047bb2de4ff487b251e4a92e24f48745648451635cec7d591162d9f" [[package]] name = "reqwest" -version = "0.11.22" +version = "0.11.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "046cd98826c46c2ac8ddecae268eb5c2e58628688a5fc7a2643704a73faba95b" +checksum = "37b1ae8d9ac08420c66222fb9096fc5de435c3c48542bc5336c51892cffafb41" dependencies = [ "base64 0.21.5", "bytes", @@ -2454,9 +2437,9 @@ dependencies = [ [[package]] name = "rustix" -version = "0.38.26" +version = "0.38.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9470c4bf8246c8daf25f9598dca807fb6510347b1e1cfa55749113850c79d88a" +checksum = "72e572a5e8ca657d7366229cdde4bd14c4eb5499a9573d4d366fe1b599daa316" dependencies = [ "bitflags 2.4.1", "errno", @@ -2467,9 +2450,9 @@ dependencies = [ [[package]] name = "rustls" -version = "0.21.9" +version = "0.21.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "629648aced5775d558af50b2b4c7b02983a04b312126d45eeead26e7caa498b9" +checksum = "f9d5a6813c0759e4609cd494e8e725babae6a2ca7b62a5536a13daaec6fcb7ba" dependencies = [ "log", "ring 0.17.7", @@ -2504,9 +2487,9 @@ checksum = "7ffc183a10b4478d04cbbbfc96d0873219d962dd5accaff2ffbd4ceb7df837f4" [[package]] name = "ryu" -version = "1.0.15" +version = "1.0.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ad4cc8da4ef723ed60bced201181d83791ad433213d8c24efffda1eec85d741" +checksum = "f98d2aa92eebf49b69786be48e4477826b256916e84a57ff2a4f21923b48eb4c" [[package]] name = "salsa20" @@ -2594,9 +2577,9 @@ dependencies = [ [[package]] name = "semver" -version = "1.0.20" +version = "1.0.21" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "836fa6a3e1e547f9a2c4040802ec865b5d85f4014efe00555d7090a3dcaa1090" +checksum = "b97ed7a9823b74f99c7742f5336af7be5ecd3eeafcb1507d1fa93347b1d589b0" dependencies = [ "serde", ] @@ -2615,29 +2598,29 @@ checksum = "cd0b0ec5f1c1ca621c432a25813d8d60c88abe6d3e08a3eb9cf37d97a0fe3d73" [[package]] name = "serde" -version = "1.0.193" +version = "1.0.194" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "25dd9975e68d0cb5aa1120c288333fc98731bd1dd12f561e468ea4728c042b89" +checksum = "0b114498256798c94a0689e1a15fec6005dee8ac1f41de56404b67afc2a4b773" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.193" +version = "1.0.194" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "43576ca501357b9b071ac53cdc7da8ef0cbd9493d8df094cd821777ea6e894d3" +checksum = "a3385e45322e8f9931410f01b3031ec534c3947d0e94c18049af4d9f9907d4e0" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.47", ] [[package]] name = "serde_json" -version = "1.0.108" +version = "1.0.111" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d1c7e3eac408d115102c4c24ad393e0821bb3a5df4d506a80f85f7a742a526b" +checksum = "176e46fa42316f18edd598015a5166857fc835ec732f5215eac6b7bdbf0a84f4" dependencies = [ "itoa", "ryu", @@ -2646,9 +2629,9 @@ dependencies = [ [[package]] name = "serde_spanned" -version = "0.6.4" +version = "0.6.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "12022b835073e5b11e90a14f86838ceb1c8fb0325b72416845c487ac0fa95e80" +checksum = "eb3622f419d1296904700073ea6cc23ad690adbd66f13ea683df73298736f0c1" dependencies = [ "serde", ] @@ -2749,16 +2732,6 @@ version = "1.11.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" -[[package]] -name = "socket2" -version = "0.4.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9f7916fc008ca5542385b89a3d3ce689953c143e9304a9bf8beec1de48994c0d" -dependencies = [ - "libc", - "winapi", -] - [[package]] name = "socket2" version = "0.5.5" @@ -2843,7 +2816,7 @@ dependencies = [ "proc-macro2", "quote", "rustversion", - "syn 2.0.39", + "syn 2.0.47", ] [[package]] @@ -2885,9 +2858,9 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.39" +version = "2.0.47" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23e78b90f2fcf45d3e842032ce32e3f2d1545ba6636271dcbf24fa306d87be7a" +checksum = "1726efe18f42ae774cc644f330953a5e7b3c3003d3edcecf18850fe9d4dd9afb" dependencies = [ "proc-macro2", "quote", @@ -2923,15 +2896,15 @@ checksum = "55937e1799185b12863d447f42597ed69d9928686b8d88a1df17376a097d8369" [[package]] name = "tempfile" -version = "3.8.1" +version = "3.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ef1adac450ad7f4b3c28589471ade84f25f731a7a0fe30d71dfa9f60fd808e5" +checksum = "01ce4141aa927a6d1bd34a041795abd0db1cccba5d5f24b009f694bdf3a1f3fa" dependencies = [ "cfg-if", "fastrand", "redox_syscall", "rustix", - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] [[package]] @@ -2947,29 +2920,29 @@ dependencies = [ [[package]] name = "thiserror" -version = "1.0.50" +version = "1.0.56" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f9a7210f5c9a7156bb50aa36aed4c95afb51df0df00713949448cf9e97d382d2" +checksum = "d54378c645627613241d077a3a79db965db602882668f9136ac42af9ecb730ad" dependencies = [ "thiserror-impl", ] [[package]] name = "thiserror-impl" -version = "1.0.50" +version = "1.0.56" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "266b2e40bc00e5a6c09c3584011e08b06f123c00362c92b975ba9843aaaa14b8" +checksum = "fa0faa943b50f3db30a20aa7e265dbc66076993efed8463e8de414e5d06d3471" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.47", ] [[package]] name = "time" -version = "0.3.30" +version = "0.3.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4a34ab300f2dee6e562c10a046fc05e358b29f9bf92277f30c3c8d82275f6f5" +checksum = "f657ba42c3f86e7680e53c8cd3af8abbe56b5491790b46e22e19c0d57463583e" dependencies = [ "deranged", "itoa", @@ -2987,9 +2960,9 @@ checksum = "ef927ca75afb808a4d64dd374f00a2adf8d0fcff8e7b184af886c3c87ec4a3f3" [[package]] name = "time-macros" -version = "0.2.15" +version = "0.2.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ad70d68dba9e1f8aceda7aa6711965dfec1cac869f311a51bd08b3a2ccbce20" +checksum = "26197e33420244aeb70c3e8c78376ca46571bc4e701e4791c2cd9f57dcb3a43f" dependencies = [ "time-core", ] @@ -3020,9 +2993,9 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" [[package]] name = "tokio" -version = "1.35.0" +version = "1.35.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "841d45b238a16291a4e1584e61820b8ae57d696cc5015c459c229ccc6990cc1c" +checksum = "c89b4efa943be685f629b149f53829423f8f5531ea21249408e8e2f8671ec104" dependencies = [ "backtrace", "bytes", @@ -3032,7 +3005,7 @@ dependencies = [ "parking_lot", "pin-project-lite", "signal-hook-registry", - "socket2 0.5.5", + "socket2", "tokio-macros", "windows-sys 0.48.0", ] @@ -3045,7 +3018,7 @@ checksum = "5b8a1e28f2deaa14e508979454cb3a223b10b938b45af148bc0986de36f1923b" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.47", ] [[package]] @@ -3089,21 +3062,21 @@ dependencies = [ [[package]] name = "toml" -version = "0.8.8" +version = "0.8.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1a195ec8c9da26928f773888e0742ca3ca1040c6cd859c919c9f59c1954ab35" +checksum = "185d8ab0dfbb35cf1399a6344d8484209c088f75f8f68230da55d48d95d43e3d" dependencies = [ "serde", "serde_spanned", "toml_datetime", - "toml_edit 0.21.0", + "toml_edit 0.20.2", ] [[package]] name = "toml_datetime" -version = "0.6.5" +version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3550f4e9685620ac18a50ed434eb3aec30db8ba93b0287467bca5826ea25baf1" +checksum = "7cda73e2f1397b1262d6dfdcef8aafae14d1de7748d66822d3bfeeb6d03e5e4b" dependencies = [ "serde", ] @@ -3121,20 +3094,9 @@ dependencies = [ [[package]] name = "toml_edit" -version = "0.20.7" +version = "0.20.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70f427fce4d84c72b5b732388bf4a9f4531b53f74e2887e3ecb2481f68f66d81" -dependencies = [ - "indexmap", - "toml_datetime", - "winnow", -] - -[[package]] -name = "toml_edit" -version = "0.21.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d34d383cd00a163b4a5b85053df514d45bc330f6de7737edfe0a93311d1eaa03" +checksum = "396e4d48bbb2b7554c944bde63101b5ae446cff6ec4a24227428f15eb72ef338" dependencies = [ "indexmap", "serde", @@ -3168,7 +3130,7 @@ checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.47", ] [[package]] @@ -3192,9 +3154,9 @@ dependencies = [ [[package]] name = "try-lock" -version = "0.2.4" +version = "0.2.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3528ecfd12c466c6f163363caf2d02a71161dd5e1cc6ae7b34207ea2d42d81ed" +checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b" [[package]] name = "tungstenite" @@ -3242,9 +3204,9 @@ checksum = "eaea85b334db583fe3274d12b4cd1880032beab409c0d774be044d4480ab9a94" [[package]] name = "unicode-bidi" -version = "0.3.13" +version = "0.3.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92888ba5573ff080736b3648696b70cafad7d250551175acbaa4e0385b3e1460" +checksum = "6f2528f27a9eb2b21e69c95319b30bd0efd85d09c379741b0f78ea1d86be2416" [[package]] name = "unicode-ident" @@ -3358,7 +3320,7 @@ dependencies = [ "once_cell", "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.47", "wasm-bindgen-shared", ] @@ -3392,7 +3354,7 @@ checksum = "f0eb82fcb7930ae6219a7ecfd55b217f5f0893484b7a13022ebb2b2bf20b5283" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.47", "wasm-bindgen-backend", "wasm-bindgen-shared", ] @@ -3584,9 +3546,9 @@ checksum = "dff9641d1cd4be8d1a070daf9e3773c5f67e78b4d9d42263020c057706765c04" [[package]] name = "winnow" -version = "0.5.25" +version = "0.5.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b7e87b8dfbe3baffbe687eef2e164e32286eff31a5ee16463ce03d991643ec94" +checksum = "8434aeec7b290e8da5c3f0d628cb0eac6cabcb31d14bb74f779a08109a5914d6" dependencies = [ "memchr", ] diff --git a/Cargo.toml b/Cargo.toml index 92024da..b470cfb 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,14 +1,20 @@ [package] name = "aperture-lens" -version = "0.3.0" +version = "0.4.0" edition = "2021" +authors = ["Aperture Finance "] +description = "Contains ephemeral lens contracts that can be called without deployment and their Rust interfaces." license = "Apache-2.0" +readme = "README.md" repository = "https://github.com/Aperture-Finance/Aperture-Lens" +keywords = ["aperture", "ethereum", "solidity", "rust", "uniswap"] +include = ["src/**/*.rs"] [dependencies] -anyhow = "1.0.75" -dotenv = "0.15.0" -ethers = { version = "2.0.10", features = ["default"] } -futures = "0.3.29" -serde = { version = "1.0.192", features = ["derive"] } -tokio = { version = "1.35.0", features = ["full"] } +anyhow = "1" +ethers = { version = "2", features = ["default"] } +serde = { version = "1", features = ["derive"] } + +[dev-dependencies] +futures = "0.3" +tokio = { version = "1.35", features = ["full"] } diff --git a/package.json b/package.json index 54fe328..c601f11 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "aperture-lens", - "version": "0.3.0", + "version": "0.4.0", "description": "Contains ephemeral lens contracts that can be called without deployment and their interfaces in various Web3 libraries.", "author": "Aperture Finance ", "license": "Apache-2.0", @@ -25,7 +25,7 @@ "files": [ "contracts", "dist", - "src", + "src/**/*.ts", "!test", "LICENSE", "README.md" @@ -50,10 +50,10 @@ "@aperture_finance/uni-v3-lib": "^1.2.0", "@openzeppelin/contracts": "^5.0.1", "ethers": "5.7.2", - "viem": "^1.20.1" + "viem": "^2.0.0" }, "devDependencies": { - "@aperture_finance/uniswap-v3-automation-sdk": "^1.9.1", + "@aperture_finance/uniswap-v3-automation-sdk": "^1.13.1", "@ethersproject/abi": "5.7.0", "@ethersproject/providers": "5.7.2", "@nomicfoundation/hardhat-foundry": "^1.1.1", @@ -62,12 +62,12 @@ "@typechain/hardhat": "^7.0.0", "@types/chai": "^4.3.11", "@types/mocha": "^10.0.6", - "@types/node": "^20.10.4", + "@types/node": "^20.10.6", "chai": "^4.3.10", - "hardhat": "^2.19.2", + "hardhat": "^2.19.4", "mocha": "^10.2.0", "prettier": "^3.1.1", - "prettier-plugin-solidity": "^1.2.0", + "prettier-plugin-solidity": "^1.3.1", "ts-node": "^10.9.2", "typechain": "^8.3.2", "typescript": "^5.3.3" diff --git a/src/bindings/bit_math.rs b/src/bindings/bit_math.rs deleted file mode 100644 index 6ea0a56..0000000 --- a/src/bindings/bit_math.rs +++ /dev/null @@ -1,111 +0,0 @@ -pub use bit_math::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod bit_math { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::std::collections::BTreeMap::new(), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static BITMATH_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`-`7`\x0B\x82\x82\x829\x80Q`\0\x1A`s\x14`*WcNH{q`\xE0\x1B`\0R`\0`\x04R`$`\0\xFD[0`\0R`s\x81S\x82\x81\xF3\xFEs\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The bytecode of the contract. - pub static BITMATH_BYTECODE: ::ethers::core::types::Bytes = ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"s\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static BITMATH_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct BitMath(::ethers::contract::Contract); - impl ::core::clone::Clone for BitMath { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for BitMath { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for BitMath { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for BitMath { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(BitMath)) - .field(&self.address()) - .finish() - } - } - impl BitMath { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - BITMATH_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = - ::ethers::contract::ContractFactory::new(BITMATH_ABI.clone(), BITMATH_BYTECODE.clone().into(), client); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - } - impl From<::ethers::contract::Contract> for BitMath { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } -} diff --git a/src/bindings/ephemeral_all_positions_by_owner.rs b/src/bindings/ephemeral_all_positions_by_owner.rs deleted file mode 100644 index 3e7c57d..0000000 --- a/src/bindings/ephemeral_all_positions_by_owner.rs +++ /dev/null @@ -1,235 +0,0 @@ -pub use ephemeral_all_positions_by_owner::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod ephemeral_all_positions_by_owner { - pub use super::super::shared_types::*; - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::Some(::ethers::core::abi::ethabi::Constructor { - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("npm"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "contract INonfungiblePositionManager", - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - }, - ], - }), - functions: ::core::convert::From::from([( - ::std::borrow::ToOwned::to_owned("allPositions"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("allPositions"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("npm"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "contract INonfungiblePositionManager", - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("positions"), - kind: ::ethers::core::abi::ethabi::ParamType::Array(::std::boxed::Box::new( - ::ethers::core::abi::ethabi::ParamType::Tuple(::std::vec![ - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Address, - ::ethers::core::abi::ethabi::ParamType::Tuple(::std::vec![ - ::ethers::core::abi::ethabi::ParamType::Uint(96usize), - ::ethers::core::abi::ethabi::ParamType::Address, - ::ethers::core::abi::ethabi::ParamType::Address, - ::ethers::core::abi::ethabi::ParamType::Address, - ::ethers::core::abi::ethabi::ParamType::Uint(24usize), - ::ethers::core::abi::ethabi::ParamType::Int(24usize), - ::ethers::core::abi::ethabi::ParamType::Int(24usize), - ::ethers::core::abi::ethabi::ParamType::Uint(128usize), - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Uint(128usize), - ::ethers::core::abi::ethabi::ParamType::Uint(128usize), - ],), - ::ethers::core::abi::ethabi::ParamType::Tuple(::std::vec![ - ::ethers::core::abi::ethabi::ParamType::Uint(160usize), - ::ethers::core::abi::ethabi::ParamType::Int(24usize), - ::ethers::core::abi::ethabi::ParamType::Uint(16usize), - ::ethers::core::abi::ethabi::ParamType::Uint(16usize), - ::ethers::core::abi::ethabi::ParamType::Uint(16usize), - ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - ::ethers::core::abi::ethabi::ParamType::Bool, - ],), - ::ethers::core::abi::ethabi::ParamType::Uint(128usize), - ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - ],), - ),), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "struct PositionState[]" - ),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Payable, - },], - )]), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static EPHEMERALALLPOSITIONSBYOWNER_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`\x80`@R`@Qb\0\n\xA58\x03\x80b\0\n\xA5\x839\x81\x01`@\x81\x90Rb\0\0&\x91b\0\x08\nV[`\0b\0\x004\x83\x83b\0\0dV[\x90P`\0\x81`@Q` \x01b\0\0K\x91\x90b\0\x08IV[`@Q` \x81\x83\x03\x03\x81R\x90`@R\x90P\x80Q` \x82\x01\xFD[```\0b\0\0t\x84\x84b\0\x02+V[\x90P\x80`\x01`\x01`@\x1B\x03\x81\x11\x15b\0\0\x91Wb\0\0\x91b\0\nBV[`@Q\x90\x80\x82R\x80` \x02` \x01\x82\x01`@R\x80\x15b\0\x01\x94W\x81` \x01[b\0\x01\x80`@\x80Q`\xE0\x80\x82\x01\x83R`\0\x80\x83R` \x80\x84\x01\x82\x90R\x84Qa\x01\x80\x81\x01\x86R\x82\x81R\x90\x81\x01\x82\x90R\x80\x85\x01\x82\x90R``\x81\x01\x82\x90R`\x80\x81\x01\x82\x90R`\xA0\x81\x01\x82\x90R`\xC0\x81\x01\x82\x90R\x91\x82\x01\x81\x90Ra\x01\0\x82\x01\x81\x90Ra\x01 \x82\x01\x81\x90Ra\x01@\x82\x01\x81\x90Ra\x01`\x82\x01R\x90\x91\x82\x01\x90\x81R`@\x80Q`\xE0\x81\x01\x82R`\0\x80\x82R` \x82\x81\x01\x82\x90R\x92\x82\x01\x81\x90R``\x82\x01\x81\x90R`\x80\x82\x01\x81\x90R`\xA0\x82\x01\x81\x90R`\xC0\x82\x01R\x91\x01\x90\x81R`\0` \x82\x01\x81\x90R`@\x82\x01\x81\x90R``\x90\x91\x01R\x90V[\x81R` \x01\x90`\x01\x90\x03\x90\x81b\0\0\xB0W\x90P[P\x91P`\0[\x81\x81\x10\x15b\0\x02#W`\0b\0\x01\xB2\x86\x86\x84b\0\x02JV[\x90P`\0\x84\x83\x81Q\x81\x10b\0\x01\xCBWb\0\x01\xCBb\0\nXV[` \x02` \x01\x01Q\x90P\x85\x81` \x01\x90`\x01`\x01`\xA0\x1B\x03\x16\x90\x81`\x01`\x01`\xA0\x1B\x03\x16\x81RPPb\0\x02\n\x87\x83\x83`@\x01Qb\0\x02k` \x1B` \x1CV[Pb\0\x02\x18\x87\x83\x83b\0\x02\x91V[PP`\x01\x01b\0\x01\x9AV[PP\x92\x91PPV[`\0\x81b\0\x02B\x84cp\xA0\x821`\xE0\x1B\x83b\0\x04HV[\x94\x93PPPPV[`\0\x82b\0\x02b\x85c/t\\Y`\xE0\x1B\x83\x86b\0\x04wV[\x95\x94PPPPPV[c\x13?uq`\xE3\x1B`\0\x81\x81R`\x04\x84\x90R\x90a\x01\x80\x83`$\x84\x88Z\xFA\x95\x94PPPPPV[\x81\x81R`@\x81\x01Q`\0b\0\x03\x14b\0\x02\xAA\x86b\0\x04\xB1V[`@\x84\x01Q``\x85\x01Q`\x80\x86\x01Q`@\x80Q`\0\x94\x85R` \x93\x84R\x91\x81R``\x84 `\xFF`\xA0\x1B\x95\x90\x95\x17\x90\x93R\x92\x90R\x7F\xE3O\x19\x9B\x19\xB2\xB4\xF4\x7FhD&\x19\xD5UR}$Ox\xA3)~\xA8\x93%\xF8C\xF8{\x8BT\x81R`U`\x0B \x91\x90R`\x01`\x01`\xA0\x1B\x03\x16\x90V[\x90Pb\0\x03*`\x01`\x01`\xA0\x1B\x03\x82\x16b\0\x04\xCEV[`\x01`\x01`\x80\x1B\x03\x16`\x80\x84\x01R``\x83\x01Qb\0\x03J\x90\x82\x90b\0\x04\xE4V[`\xE0\x82\x01Q`\x01`\x01`\x80\x1B\x03\x16\x15b\0\x03\xFCW`\0\x80b\0\x03\x85\x83\x85`\xA0\x01Q\x86`\xC0\x01Q\x88``\x01Q` \x01Qb\0\x05\x0B` \x1B` \x1CV[\x91P\x91P`\0\x80b\0\x03\xAF\x86`\xE0\x01Q\x85\x85\x89a\x01\0\x01Q\x8Aa\x01 \x01Qb\0\x05\xF2` \x1B` \x1CV[\x91P\x91P\x81\x86a\x01@\x01\x81\x81Qb\0\x03\xC8\x91\x90b\0\nnV[`\x01`\x01`\x80\x1B\x03\x16\x90RPa\x01`\x86\x01\x80Q\x82\x91\x90b\0\x03\xEB\x90\x83\x90b\0\nnV[`\x01`\x01`\x80\x1B\x03\x16\x90RPPPPP[`@\x82\x01Qb\0\x04\x15\x90`\x01`\x01`\xA0\x1B\x03\x16b\0\x06;V[`\xFF\x16`\xA0\x84\x01R``\x82\x01Qb\0\x046\x90`\x01`\x01`\xA0\x1B\x03\x16b\0\x06;V[`\xFF\x16`\xC0\x90\x93\x01\x92\x90\x92RPPPPV[`\0\x82`\0R\x81`\x04R` `\0`$`\0\x87Z\xFAb\0\x04lW=`\0\x80>=`\0\xFD[PP`\0Q\x92\x91PPV[`\0\x83`\0R\x82`\x04R\x81`$R` `\0`D`\0\x88Z\xFAb\0\x04\x9FW=`\0\x80>=`\0\xFD[`\0Q\x90P`\0`$R\x94\x93PPPPV[`\0\x80b\0\x04\xC7\x83c\xC4Z\x01U`\xE0\x1Bb\0\x06aV[\x93\x92PPPV[`\0\x80b\0\x04\xC7\x83c\r42\x81`\xE1\x1Bb\0\x06aV[c8P\xC7\xBD`\xE0\x1B`\0\x81\x81R`\xE0\x90\x83\x90`\x04\x90\x86Z\xFAb\0\x05\x06W`\0\x80\xFD[PPPV[`\0\x80\x80b\0\x05$`\x01`\x01`\xA0\x1B\x03\x88\x16\x87b\0\x06\x86V[\x90P`\0b\0\x05=`\x01`\x01`\xA0\x1B\x03\x89\x16\x87b\0\x06\x86V[\x90P\x86`\x02\x0B\x85`\x02\x0B\x12\x15b\0\x05nW\x80`@\x01Q\x82`@\x01Q\x03\x93P\x80``\x01Q\x82``\x01Q\x03\x92Pb\0\x05\xE7V[\x85`\x02\x0B\x85`\x02\x0B\x12b\0\x05\x9CW\x81`@\x01Q\x81`@\x01Q\x03\x93P\x81``\x01Q\x81``\x01Q\x03\x92Pb\0\x05\xE7V[`@\x80\x82\x01Q\x90\x83\x01Qb\0\x05\xBA`\x01`\x01`\xA0\x1B\x03\x8B\x16b\0\x06\xE5V[\x03\x03\x93P\x80``\x01Q\x82``\x01Qb\0\x05\xE2\x8A`\x01`\x01`\xA0\x1B\x03\x16b\0\x07\0` \x1B` \x1CV[\x03\x03\x92P[PP\x94P\x94\x92PPPV[`\0\x80b\0\x06\x11`\x01`\x01`\x80\x1B\x03\x88\x16\x85\x88\x03`\x01`\x80\x1Bb\0\x07\x15V[\x91Pb\0\x06/`\x01`\x01`\x80\x1B\x03\x88\x16\x84\x87\x03`\x01`\x80\x1Bb\0\x07\x15V[\x90P\x95P\x95\x93PPPPV[`\x12`\0\x90\x81Rc1<\xE5g`\xE0\x1B` \x81\x81R\x80`\x04\x81\x86Z\xFA`\x05\x1BQ\x93\x92PPPV[`\0\x81`\0R` `\0`\x04`\0\x86Z\xFAb\0\x06|W`\0\x80\xFD[PP`\0Q\x91\x90PV[`@\x80Qa\x01\0\x81\x01\x82R`\0\x80\x82R` \x82\x01\x81\x90R\x91\x81\x01\x82\x90R``\x81\x01\x82\x90R`\x80\x81\x01\x82\x90R`\xA0\x81\x01\x82\x90R`\xC0\x81\x01\x82\x90R`\xE0\x81\x01\x91\x90\x91R`\x02\x82\x90\x0B\x81b\0\x02#\x85c\xF3\r\xBA\x93`\xE0\x1B\x84\x84a\x01\0b\0\x07$V[`\0b\0\x06\xFA\x82c\xF3\x05\x83\x99`\xE0\x1Bb\0\x06aV[\x92\x91PPV[`\0b\0\x06\xFA\x82cF\x14\x13\x19`\xE0\x1Bb\0\x06aV[`\0b\0\x02B\x84\x84\x84b\0\x07FV[\x83`\0R\x82`\x04R\x80\x82`$`\0\x88Z\xFAb\0\x07?W`\0\x80\xFD[PPPPPV[`\0\x83\x83\x02`\0\x19\x84\x86\t\x81\x81\x10\x82\x01\x90\x03\x80b\0\x07~W\x83b\0\x07rWc\xAEG\xF7\x02`\0R`\x04`\x1C\xFD[P\x82\x90\x04\x90Pb\0\x04\xC7V[\x80\x84\x11b\0\x07\x94Wc\xAEG\xF7\x02`\0R`\x04`\x1C\xFD[\x83\x85\x87\t`\0\x85\x81\x03\x86\x16\x95\x86\x90\x04\x95\x84\x83\x11\x90\x93\x03\x90\x83\x90\x03\x83\x90\x04`\x01\x01\x02\x92\x03\x04\x17`\x03\x83\x02`\x02\x90\x81\x18\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x90\x91\x03\x02\x02\x90P\x93\x92PPPV[`\x01`\x01`\xA0\x1B\x03\x81\x16\x81\x14b\0\x08\x07W`\0\x80\xFD[PV[`\0\x80`@\x83\x85\x03\x12\x15b\0\x08\x1EW`\0\x80\xFD[\x82Qb\0\x08+\x81b\0\x07\xF1V[` \x84\x01Q\x90\x92Pb\0\x08>\x81b\0\x07\xF1V[\x80\x91PP\x92P\x92\x90PV[` \x80\x82R\x82Q\x82\x82\x01\x81\x90R`\0\x91\x90`@\x90\x81\x85\x01\x90\x86\x84\x01\x85[\x82\x81\x10\x15b\0\n5W\x81Q\x80Q\x85R\x86\x81\x01Q`\x01`\x01`\xA0\x1B\x03\x16\x87\x86\x01R\x85\x81\x01Q\x80Q`\x01`\x01``\x1B\x03\x16\x87\x87\x01R\x87\x81\x01Q``b\0\x08\xB4\x81\x89\x01\x83`\x01`\x01`\xA0\x1B\x03\x16\x90RV[\x88\x83\x01Q\x91P`\x80b\0\x08\xD1\x81\x8A\x01\x84`\x01`\x01`\xA0\x1B\x03\x16\x90RV[\x81\x84\x01Q\x92P`\xA0b\0\x08\xEE\x81\x8B\x01\x85`\x01`\x01`\xA0\x1B\x03\x16\x90RV[\x81\x85\x01Q\x93P`\xC0b\0\t\x07\x81\x8C\x01\x86b\xFF\xFF\xFF\x16\x90RV[\x81\x86\x01Q\x94P`\xE0b\0\t\x1E\x81\x8D\x01\x87`\x02\x0B\x90RV[\x81\x87\x01Q\x95Pa\x01\0b\0\t6\x81\x8E\x01\x88`\x02\x0B\x90RV[\x90\x87\x01Q\x95Pa\x01 \x90b\0\tU\x8D\x83\x01\x88`\x01`\x01`\x80\x1B\x03\x16\x90RV[\x87\x01Qa\x01@\x8D\x81\x01\x91\x90\x91R\x90\x87\x01Qa\x01`\x80\x8E\x01\x91\x90\x91R\x90\x87\x01Q`\x01`\x01`\x80\x1B\x03\x90\x81\x16a\x01\x80\x8E\x01R\x96\x01Q\x86\x16a\x01\xA0\x8C\x01R\x92\x86\x01Q\x80Q`\x01`\x01`\xA0\x1B\x03\x16a\x01\xC0\x8C\x01R` \x81\x01Q`\x02\x0Ba\x01\xE0\x8C\x01R`@\x81\x01Qa\xFF\xFF\x90\x81\x16a\x02\0\x8D\x01R``\x82\x01Q\x81\x16a\x02 \x8D\x01R`\x80\x82\x01Q\x16a\x02@\x8C\x01R`\xA0\x81\x01Q`\xFF\x90\x81\x16a\x02`\x8D\x01R`\xC0\x90\x91\x01Q\x15\x15a\x02\x80\x8C\x01R\x91\x86\x01Q\x90\x94\x16a\x02\xA0\x8A\x01R\x92\x84\x01Q\x83\x16a\x02\xC0\x89\x01R\x92\x90\x92\x01Q\x16a\x02\xE0\x86\x01RPa\x03\0\x90\x93\x01\x92\x90\x85\x01\x90`\x01\x01b\0\x08fV[P\x91\x97\x96PPPPPPPV[cNH{q`\xE0\x1B`\0R`A`\x04R`$`\0\xFD[cNH{q`\xE0\x1B`\0R`2`\x04R`$`\0\xFD[`\x01`\x01`\x80\x1B\x03\x81\x81\x16\x83\x82\x16\x01\x90\x80\x82\x11\x15b\0\n\x9DWcNH{q`\xE0\x1B`\0R`\x11`\x04R`$`\0\xFD[P\x92\x91PPV\xFE"; - /// The bytecode of the contract. - pub static EPHEMERALALLPOSITIONSBYOWNER_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"`\x80`@R`\x046\x10a\0\x1EW`\x005`\xE0\x1C\x80c\xDD`$\xA4\x14a\0#W[`\0\x80\xFD[a\x006a\x0016`\x04a\t\x91V[a\0LV[`@Qa\0C\x91\x90a\t\xCAV[`@Q\x80\x91\x03\x90\xF3[```\0a\0Z\x84\x84a\x02\x15V[\x90P\x80g\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x11\x15a\0uWa\0ua\x0C\x12V[`@Q\x90\x80\x82R\x80` \x02` \x01\x82\x01`@R\x80\x15a\x01uW\x81` \x01[a\x01b`@\x80Q`\xE0\x80\x82\x01\x83R`\0\x80\x83R` \x80\x84\x01\x82\x90R\x84Qa\x01\x80\x81\x01\x86R\x82\x81R\x90\x81\x01\x82\x90R\x80\x85\x01\x82\x90R``\x81\x01\x82\x90R`\x80\x81\x01\x82\x90R`\xA0\x81\x01\x82\x90R`\xC0\x81\x01\x82\x90R\x91\x82\x01\x81\x90Ra\x01\0\x82\x01\x81\x90Ra\x01 \x82\x01\x81\x90Ra\x01@\x82\x01\x81\x90Ra\x01`\x82\x01R\x90\x91\x82\x01\x90\x81R`@\x80Q`\xE0\x81\x01\x82R`\0\x80\x82R` \x82\x81\x01\x82\x90R\x92\x82\x01\x81\x90R``\x82\x01\x81\x90R`\x80\x82\x01\x81\x90R`\xA0\x82\x01\x81\x90R`\xC0\x82\x01R\x91\x01\x90\x81R`\0` \x82\x01\x81\x90R`@\x82\x01\x81\x90R``\x90\x91\x01R\x90V[\x81R` \x01\x90`\x01\x90\x03\x90\x81a\0\x93W\x90P[P\x91P`\0[\x81\x81\x10\x15a\x02\rW`\0a\x01\x90\x86\x86\x84a\x02KV[\x90P`\0\x84\x83\x81Q\x81\x10a\x01\xA6Wa\x01\xA6a\x0CAV[` \x02` \x01\x01Q\x90P\x85\x81` \x01\x90s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x90\x81s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x81RPPa\x01\xF7\x87\x83\x83`@\x01Qa\x02\x83V[Pa\x02\x03\x87\x83\x83a\x02\xC2V[PP`\x01\x01a\x01{V[PP\x92\x91PPV[`\0\x81a\x02C\x84\x7Fp\xA0\x821\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\x83a\x04\xC1V[\x94\x93PPPPV[`\0\x82a\x02z\x85\x7F/t\\Y\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\x83\x86a\x04\xEFV[\x95\x94PPPPPV[\x7F\x99\xFB\xAB\x88\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`\0\x81\x81R`\x04\x84\x90R\x90a\x01\x80\x83`$\x84\x88Z\xFA\x95\x94PPPPPV[\x81\x81R`@\x81\x01Q`\0a\x03`a\x02\xD8\x86a\x05(V[\x83`@\x01Q\x84``\x01Q\x85`\x80\x01Q`@\x80Q`\0\x94\x85R` \x93\x84R\x91\x81R``\x84 t\xFF\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x95\x90\x95\x17\x90\x93R\x92\x90R\x7F\xE3O\x19\x9B\x19\xB2\xB4\xF4\x7FhD&\x19\xD5UR}$Ox\xA3)~\xA8\x93%\xF8C\xF8{\x8BT\x81R`U`\x0B \x91\x90Rs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x90V[\x90Pa\x03\x81\x81s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x05\\V[o\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16`\x80\x84\x01R``\x83\x01Qa\x03\xA8\x90\x82\x90a\x05\x89V[`\xE0\x82\x01Qo\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x15a\x04`W`\0\x80a\x03\xE3\x83\x85`\xA0\x01Q\x86`\xC0\x01Q\x88``\x01Q` \x01Qa\x05\xC8V[\x91P\x91P`\0\x80a\x04\x05\x86`\xE0\x01Q\x85\x85\x89a\x01\0\x01Q\x8Aa\x01 \x01Qa\x06\xD1V[\x91P\x91P\x81\x86a\x01@\x01\x81\x81Qa\x04\x1C\x91\x90a\x0CpV[o\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x90RPa\x01`\x86\x01\x80Q\x82\x91\x90a\x04F\x90\x83\x90a\x0CpV[o\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x90RPPPPP[a\x04\x83\x82`@\x01Qs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x07BV[`\xFF\x16`\xA0\x84\x01R``\x82\x01Qa\x04\xAF\x90s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x07BV[`\xFF\x16`\xC0\x90\x93\x01\x92\x90\x92RPPPPV[`\0\x82`\0R\x81`\x04R` `\0`$`\0\x87Z\xFAa\x04\xE4W=`\0\x80>=`\0\xFD[PP`\0Q\x92\x91PPV[`\0\x83`\0R\x82`\x04R\x81`$R` `\0`D`\0\x88Z\xFAa\x05\x16W=`\0\x80>=`\0\xFD[`\0Q\x90P`\0`$R\x94\x93PPPPV[`\0\x80a\x05U\x83\x7F\xC4Z\x01U\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\0a\x07\x81V[\x93\x92PPPV[`\0\x80a\x05U\x83\x7F\x1Ahe\x02\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\0a\x07\x81V[\x7F8P\xC7\xBD\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`\0\x81\x81R`\xE0\x90\x83\x90`\x04\x90\x86Z\xFAa\x05\xC3W`\0\x80\xFD[PPPV[`\0\x80\x80a\x05\xECs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x88\x16\x87a\x07\xA5V[\x90P`\0a\x06\x10s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x89\x16\x87a\x07\xA5V[\x90P\x86`\x02\x0B\x85`\x02\x0B\x12\x15a\x06?W\x80`@\x01Q\x82`@\x01Q\x03\x93P\x80``\x01Q\x82``\x01Q\x03\x92Pa\x06\xC6V[\x85`\x02\x0B\x85`\x02\x0B\x12a\x06kW\x81`@\x01Q\x81`@\x01Q\x03\x93P\x81``\x01Q\x81``\x01Q\x03\x92Pa\x06\xC6V[\x80`@\x01Q\x82`@\x01Qa\x06\x94\x8As\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x08\x1BV[\x03\x03\x93P\x80``\x01Q\x82``\x01Qa\x06\xC1\x8As\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x08MV[\x03\x03\x92P[PP\x94P\x94\x92PPPV[`\0\x80a\x07\x04o\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x88\x16\x85\x88\x03p\x01\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0a\x08yV[\x91Pa\x076o\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x88\x16\x84\x87\x03p\x01\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0a\x08yV[\x90P\x95P\x95\x93PPPPV[`\x12`\0\x90\x81R\x7F1<\xE5g\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` \x81\x81R\x80`\x04\x81\x86Z\xFA`\x05\x1BQ\x93\x92PPPV[`\0\x81`\0R` `\0`\x04`\0\x86Z\xFAa\x07\x9BW`\0\x80\xFD[PP`\0Q\x91\x90PV[`@\x80Qa\x01\0\x81\x01\x82R`\0\x80\x82R` \x82\x01\x81\x90R\x91\x81\x01\x82\x90R``\x81\x01\x82\x90R`\x80\x81\x01\x82\x90R`\xA0\x81\x01\x82\x90R`\xC0\x81\x01\x82\x90R`\xE0\x81\x01\x91\x90\x91R`\x02\x82\x90\x0B\x81a\x02\r\x85\x7F\xF3\r\xBA\x93\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\x84\x84a\x01\0a\x08\x86V[`\0a\x08G\x82\x7F\xF3\x05\x83\x99\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\0a\x07\x81V[\x92\x91PPV[`\0a\x08G\x82\x7FF\x14\x13\x19\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\0a\x07\x81V[`\0a\x02C\x84\x84\x84a\x08\xA7V[\x83`\0R\x82`\x04R\x80\x82`$`\0\x88Z\xFAa\x08\xA0W`\0\x80\xFD[PPPPPV[`\0\x83\x83\x02\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x84\x86\t\x81\x81\x10\x82\x01\x90\x03\x80a\x08\xFAW\x83a\x08\xEFWc\xAEG\xF7\x02`\0R`\x04`\x1C\xFD[P\x82\x90\x04\x90Pa\x05UV[\x80\x84\x11a\t\x0FWc\xAEG\xF7\x02`\0R`\x04`\x1C\xFD[\x83\x85\x87\t`\0\x85\x81\x03\x86\x16\x95\x86\x90\x04\x95\x84\x83\x11\x90\x93\x03\x90\x83\x90\x03\x83\x90\x04`\x01\x01\x02\x92\x03\x04\x17`\x03\x83\x02`\x02\x90\x81\x18\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x90\x91\x03\x02\x02\x90P\x93\x92PPPV[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x16\x81\x14a\t\x8EW`\0\x80\xFD[PV[`\0\x80`@\x83\x85\x03\x12\x15a\t\xA4W`\0\x80\xFD[\x825a\t\xAF\x81a\tlV[\x91P` \x83\x015a\t\xBF\x81a\tlV[\x80\x91PP\x92P\x92\x90PV[` \x80\x82R\x82Q\x82\x82\x01\x81\x90R`\0\x91\x90`@\x90\x81\x85\x01\x90\x86\x84\x01\x85[\x82\x81\x10\x15a\x0C\x05W\x81Q\x80Q\x85R\x86\x81\x01Qs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x87\x86\x01R\x85\x81\x01Q\x80Qk\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x87\x87\x01R\x87\x81\x01Q``a\nR\x81\x89\x01\x83s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x90RV[\x88\x83\x01Q\x91P`\x80a\n{\x81\x8A\x01\x84s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x90RV[\x81\x84\x01Q\x92P`\xA0a\n\xA4\x81\x8B\x01\x85s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x90RV[\x81\x85\x01Q\x93P`\xC0a\n\xBC\x81\x8C\x01\x86b\xFF\xFF\xFF\x16\x90RV[\x81\x86\x01Q\x94P`\xE0a\n\xD2\x81\x8D\x01\x87`\x02\x0B\x90RV[\x81\x87\x01Q\x95Pa\x01\0a\n\xE9\x81\x8E\x01\x88`\x02\x0B\x90RV[\x90\x87\x01Q\x95Pa\x01 \x90a\x0B\x10\x8D\x83\x01\x88o\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x90RV[\x87\x01Qa\x01@\x8D\x81\x01\x91\x90\x91R\x90\x87\x01Qa\x01`\x80\x8E\x01\x91\x90\x91R\x90\x87\x01Qo\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x90\x81\x16a\x01\x80\x8E\x01R\x96\x01Q\x86\x16a\x01\xA0\x8C\x01R\x92\x86\x01Q\x80Qs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x01\xC0\x8C\x01R` \x81\x01Q`\x02\x0Ba\x01\xE0\x8C\x01R`@\x81\x01Qa\xFF\xFF\x90\x81\x16a\x02\0\x8D\x01R``\x82\x01Q\x81\x16a\x02 \x8D\x01R`\x80\x82\x01Q\x16a\x02@\x8C\x01R`\xA0\x81\x01Q`\xFF\x90\x81\x16a\x02`\x8D\x01R`\xC0\x90\x91\x01Q\x15\x15a\x02\x80\x8C\x01R\x91\x86\x01Q\x90\x94\x16a\x02\xA0\x8A\x01R\x92\x84\x01Q\x83\x16a\x02\xC0\x89\x01R\x92\x90\x92\x01Q\x16a\x02\xE0\x86\x01RPa\x03\0\x90\x93\x01\x92\x90\x85\x01\x90`\x01\x01a\t\xE7V[P\x91\x97\x96PPPPPPPV[\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`\0R`A`\x04R`$`\0\xFD[\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`\0R`2`\x04R`$`\0\xFD[o\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x81\x16\x83\x82\x16\x01\x90\x80\x82\x11\x15a\x0C\xC0W\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`\0R`\x11`\x04R`$`\0\xFD[P\x92\x91PPV\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static EPHEMERALALLPOSITIONSBYOWNER_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct EphemeralAllPositionsByOwner(::ethers::contract::Contract); - impl ::core::clone::Clone for EphemeralAllPositionsByOwner { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for EphemeralAllPositionsByOwner { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for EphemeralAllPositionsByOwner { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for EphemeralAllPositionsByOwner { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(EphemeralAllPositionsByOwner)) - .field(&self.address()) - .finish() - } - } - impl EphemeralAllPositionsByOwner { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - EPHEMERALALLPOSITIONSBYOWNER_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - EPHEMERALALLPOSITIONSBYOWNER_ABI.clone(), - EPHEMERALALLPOSITIONSBYOWNER_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - ///Calls the contract's `allPositions` (0xdd6024a4) function - pub fn all_positions( - &self, - npm: ::ethers::core::types::Address, - owner: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall> { - self.0 - .method_hash([221, 96, 36, 164], (npm, owner)) - .expect("method not found (this should never happen)") - } - } - impl From<::ethers::contract::Contract> for EphemeralAllPositionsByOwner { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Container type for all input parameters for the `allPositions` function with signature `allPositions(address,address)` and selector `0xdd6024a4` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "allPositions", abi = "allPositions(address,address)")] - pub struct AllPositionsCall { - pub npm: ::ethers::core::types::Address, - pub owner: ::ethers::core::types::Address, - } - ///Container type for all return fields from the `allPositions` function with signature `allPositions(address,address)` and selector `0xdd6024a4` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct AllPositionsReturn { - pub positions: ::std::vec::Vec, - } -} diff --git a/src/bindings/ephemeral_get_populated_ticks_in_range.rs b/src/bindings/ephemeral_get_populated_ticks_in_range.rs deleted file mode 100644 index b5f4aa3..0000000 --- a/src/bindings/ephemeral_get_populated_ticks_in_range.rs +++ /dev/null @@ -1,246 +0,0 @@ -pub use ephemeral_get_populated_ticks_in_range::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod ephemeral_get_populated_ticks_in_range { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::Some(::ethers::core::abi::ethabi::Constructor { - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("pool"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("V3PoolCallee"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickLower"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickUpper"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ], - }), - functions: ::core::convert::From::from([( - ::std::borrow::ToOwned::to_owned("getPopulatedTicksInRange"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("getPopulatedTicksInRange",), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("pool"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "V3PoolCallee" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickLower"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickUpper"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("populatedTicks"), - kind: ::ethers::core::abi::ethabi::ParamType::Array(::std::boxed::Box::new( - ::ethers::core::abi::ethabi::ParamType::Tuple(::std::vec![ - ::ethers::core::abi::ethabi::ParamType::Int(24usize), - ::ethers::core::abi::ethabi::ParamType::Int(128usize), - ::ethers::core::abi::ethabi::ParamType::Uint(128usize), - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ],), - ),), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "struct PoolUtils.PopulatedTick[]", - ),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Payable, - },], - )]), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static EPHEMERALGETPOPULATEDTICKSINRANGE_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`\x80`@R`@Qb\0\x06\xF08\x03\x80b\0\x06\xF0\x839\x81\x01`@\x81\x90Rb\0\0&\x91b\0\x05'V[`\0b\0\x005\x84\x84\x84b\0\0eV[\x90P`\0\x81`@Q` \x01b\0\0L\x91\x90b\0\x05~V[`@Q` \x81\x83\x03\x03\x81R\x90`@R\x90P\x80Q` \x82\x01\xFD[``\x81`\x02\x0B\x83`\x02\x0B\x13\x15b\0\0{W`\0\x80\xFD[`\0\x84`\x01`\x01`\xA0\x1B\x03\x16c\xD0\xC9:|`@Q\x81c\xFF\xFF\xFF\xFF\x16`\xE0\x1B\x81R`\x04\x01` `@Q\x80\x83\x03\x81\x86Z\xFA\x15\x80\x15b\0\0\xBCW=`\0\x80>=`\0\xFD[PPPP`@Q=`\x1F\x19`\x1F\x82\x01\x16\x82\x01\x80`@RP\x81\x01\x90b\0\0\xE2\x91\x90b\0\x05\xFDV[\x90P\x80\x84\x07`\0\x90\x81\x13\x82\x86\x05\x03`\x02\x90\x81\x0B`\x08\x90\x81\x1D\x92\x84\x87\x07\x81\x13\x85\x88\x05\x03\x90\x92\x0B\x90\x1D\x90\x80b\0\x01\x18\x89\x85\x85b\0\x01\xF8V[\x91P\x91P\x80`\x01`\x01`@\x1B\x03\x81\x11\x15b\0\x017Wb\0\x017b\0\x06\"V[`@Q\x90\x80\x82R\x80` \x02` \x01\x82\x01`@R\x80\x15b\0\x01\x92W\x81` \x01[`@\x80Q`\xA0\x81\x01\x82R`\0\x80\x82R` \x80\x83\x01\x82\x90R\x92\x82\x01\x81\x90R``\x82\x01\x81\x90R`\x80\x82\x01R\x82R`\0\x19\x90\x92\x01\x91\x01\x81b\0\x01VW\x90P[P\x95P`\0\x84[\x84`\x01\x0B\x81`\x01\x0B\x13b\0\x01\xEAWb\0\x01\xDF\x8B\x82\x89\x87\x8A\x86\x03a\xFF\xFF\x16\x81Q\x81\x10b\0\x01\xC9Wb\0\x01\xC9b\0\x068V[` \x02` \x01\x01Q\x8C\x87b\0\x03\x90` \x1B` \x1CV[\x91P`\x01\x01b\0\x01\x99V[PPPPPPP\x93\x92PPPV[```\0b\0\x02\x08\x84\x84b\0\x06dV[b\0\x02\x15\x90`\x01b\0\x06\x90V[a\xFF\xFF\x16`\x01`\x01`@\x1B\x03\x81\x11\x15b\0\x023Wb\0\x023b\0\x06\"V[`@Q\x90\x80\x82R\x80` \x02` \x01\x82\x01`@R\x80\x15b\0\x02]W\x81` \x01` \x82\x02\x806\x837\x01\x90P[P\x91P\x83[\x83`\x01\x0B\x81`\x01\x0B\x13b\0\x03\x87W`\0b\0\x02\x87`\x01`\x01`\xA0\x1B\x03\x88\x16\x83b\0\x04\x03V[\x90P\x80\x84b\0\x02\x97\x88\x85b\0\x06dV[a\xFF\xFF\x16\x81Q\x81\x10b\0\x02\xAEWb\0\x02\xAEb\0\x068V[` \x90\x81\x02\x91\x90\x91\x01\x01R\x7F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x7FUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUU`\x01\x83\x90\x1C\x16\x82\x03`\x02\x81\x90\x1C\x7F33333333333333333333333333333333\x90\x81\x16\x91\x16\x01`\x04\x81\x90\x1C\x01\x16\x7F\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x02`\xF8\x1C`\0\x19\x82\x14`\x08\x1B\x17b\0\x03p\x90\x84b\0\x06\xB6V[\x92PP\x80b\0\x03\x7F\x90b\0\x06\xCCV[\x90Pb\0\x02bV[P\x93P\x93\x91PPV[`\0\x80[a\x01\0\x81\x10\x15b\0\x03\xF7W`\x01\x81\x1B\x85\x16\x15b\0\x03\xEEW`\0\x81\x88`\x08\x1B\x01\x87\x02\x90Pb\0\x03\xEC\x89\x82\x87\x87\x80`\x01\x01\x98P\x81Q\x81\x10b\0\x03\xD8Wb\0\x03\xD8b\0\x068V[` \x02` \x01\x01Qb\0\x04,` \x1B` \x1CV[P[`\x01\x01b\0\x03\x94V[P\x90\x96\x95PPPPPPV[`\0`\x01\x82\x90\x0Bb\0\x04!\x84c)\x9C\xE1K`\xE1\x1B\x83\x85` b\0\x04\x86V[PP`\0Q\x92\x91PPV[`\0b\0\x04C`\x01`\x01`\xA0\x1B\x03\x85\x16\x84b\0\x04\xA8V[`\x02\x93\x90\x93\x0B\x82RP` \x80\x83\x01Q`\x0F\x0B\x90\x82\x01R\x81Q`\x01`\x01`\x80\x1B\x03\x16`@\x80\x83\x01\x91\x90\x91R\x82\x01Q``\x80\x83\x01\x91\x90\x91R\x90\x91\x01Q`\x80\x90\x91\x01RPV[\x83`\0R\x82`\x04R\x80\x82`$`\0\x88Z\xFAb\0\x04\xA1W`\0\x80\xFD[PPPPPV[`@\x80Qa\x01\0\x81\x01\x82R`\0\x80\x82R` \x82\x01\x81\x90R\x91\x81\x01\x82\x90R``\x81\x01\x82\x90R`\x80\x81\x01\x82\x90R`\xA0\x81\x01\x82\x90R`\xC0\x81\x01\x82\x90R`\xE0\x81\x01\x91\x90\x91R`\x02\x82\x90\x0B\x81b\0\x05\x07\x85c\xF3\r\xBA\x93`\xE0\x1B\x84\x84a\x01\0b\0\x04\x86V[PP\x92\x91PPV[\x80Q`\x02\x81\x90\x0B\x81\x14b\0\x05\"W`\0\x80\xFD[\x91\x90PV[`\0\x80`\0``\x84\x86\x03\x12\x15b\0\x05=W`\0\x80\xFD[\x83Q`\x01`\x01`\xA0\x1B\x03\x81\x16\x81\x14b\0\x05UW`\0\x80\xFD[\x92Pb\0\x05e` \x85\x01b\0\x05\x0FV[\x91Pb\0\x05u`@\x85\x01b\0\x05\x0FV[\x90P\x92P\x92P\x92V[` \x80\x82R\x82Q\x82\x82\x01\x81\x90R`\0\x91\x90`@\x90\x81\x85\x01\x90\x86\x84\x01\x85[\x82\x81\x10\x15b\0\x05\xF0W\x81Q\x80Q`\x02\x0B\x85R\x86\x81\x01Q`\x0F\x0B\x87\x86\x01R\x85\x81\x01Q`\x01`\x01`\x80\x1B\x03\x16\x86\x86\x01R``\x80\x82\x01Q\x90\x86\x01R`\x80\x90\x81\x01Q\x90\x85\x01R`\xA0\x90\x93\x01\x92\x90\x85\x01\x90`\x01\x01b\0\x05\x9BV[P\x91\x97\x96PPPPPPPV[`\0` \x82\x84\x03\x12\x15b\0\x06\x10W`\0\x80\xFD[b\0\x06\x1B\x82b\0\x05\x0FV[\x93\x92PPPV[cNH{q`\xE0\x1B`\0R`A`\x04R`$`\0\xFD[cNH{q`\xE0\x1B`\0R`2`\x04R`$`\0\xFD[cNH{q`\xE0\x1B`\0R`\x11`\x04R`$`\0\xFD[`\x01\x82\x81\x0B\x90\x82\x90\x0B\x03a\x7F\xFF\x19\x81\x12a\x7F\xFF\x82\x13\x17\x15b\0\x06\x8AWb\0\x06\x8Ab\0\x06NV[\x92\x91PPV[`\x01\x81\x81\x0B\x90\x83\x90\x0B\x01a\x7F\xFF\x81\x13a\x7F\xFF\x19\x82\x12\x17\x15b\0\x06\x8AWb\0\x06\x8Ab\0\x06NV[\x80\x82\x01\x80\x82\x11\x15b\0\x06\x8AWb\0\x06\x8Ab\0\x06NV[`\0\x81`\x01\x0Ba\x7F\xFF\x81\x03b\0\x06\xE6Wb\0\x06\xE6b\0\x06NV[`\x01\x01\x92\x91PPV\xFE"; - /// The bytecode of the contract. - pub static EPHEMERALGETPOPULATEDTICKSINRANGE_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"`\x80`@R`\x046\x10a\0\x1EW`\x005`\xE0\x1C\x80c\xF2\xBB\0\x8B\x14a\0#W[`\0\x80\xFD[a\x006a\x0016`\x04a\x05fV[a\0LV[`@Qa\0C\x91\x90a\x05\xCAV[`@Q\x80\x91\x03\x90\xF3[``\x81`\x02\x0B\x83`\x02\x0B\x13\x15a\0aW`\0\x80\xFD[`\0\x84s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16c\xD0\xC9:|`@Q\x81c\xFF\xFF\xFF\xFF\x16`\xE0\x1B\x81R`\x04\x01` `@Q\x80\x83\x03\x81\x86Z\xFA\x15\x80\x15a\0\xAEW=`\0\x80>=`\0\xFD[PPPP`@Q=`\x1F\x19`\x1F\x82\x01\x16\x82\x01\x80`@RP\x81\x01\x90a\0\xD2\x91\x90a\x06PV[\x90P\x80\x84\x07`\0\x90\x81\x13\x82\x86\x05\x03`\x02\x90\x81\x0B`\x08\x90\x81\x1D\x92\x84\x87\x07\x81\x13\x85\x88\x05\x03\x90\x92\x0B\x90\x1D\x90\x80a\x01\x06\x89\x85\x85a\x01\xF3V[\x91P\x91P\x80g\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x11\x15a\x01#Wa\x01#a\x06tV[`@Q\x90\x80\x82R\x80` \x02` \x01\x82\x01`@R\x80\x15a\x01\x9AW\x81` \x01[`@\x80Q`\xA0\x81\x01\x82R`\0\x80\x82R` \x80\x83\x01\x82\x90R\x92\x82\x01\x81\x90R``\x82\x01\x81\x90R`\x80\x82\x01R\x82R\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x90\x92\x01\x91\x01\x81a\x01AW\x90P[P\x95P`\0\x84[\x84`\x01\x0B\x81`\x01\x0B\x13a\x01\xE5Wa\x01\xDB\x8B\x82\x89\x87\x8A\x86\x03a\xFF\xFF\x16\x81Q\x81\x10a\x01\xCCWa\x01\xCCa\x06\xA3V[` \x02` \x01\x01Q\x8C\x87a\x03\xA2V[\x91P`\x01\x01a\x01\xA1V[PPPPPPP\x93\x92PPPV[```\0a\x02\x01\x84\x84a\x07\x01V[a\x02\x0C\x90`\x01a\x07GV[a\xFF\xFF\x16g\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x11\x15a\x02(Wa\x02(a\x06tV[`@Q\x90\x80\x82R\x80` \x02` \x01\x82\x01`@R\x80\x15a\x02QW\x81` \x01` \x82\x02\x806\x837\x01\x90P[P\x91P\x83[\x83`\x01\x0B\x81`\x01\x0B\x13a\x03\x99W`\0a\x02\x85s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x88\x16\x83a\x04\x07V[\x90P\x80\x84a\x02\x93\x88\x85a\x07\x01V[a\xFF\xFF\x16\x81Q\x81\x10a\x02\xA7Wa\x02\xA7a\x06\xA3V[` \x90\x81\x02\x91\x90\x91\x01\x01R\x7F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x7FUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUU`\x01\x83\x90\x1C\x16\x82\x03`\x02\x81\x90\x1C\x7F33333333333333333333333333333333\x90\x81\x16\x91\x16\x01`\x04\x81\x90\x1C\x01\x16\x7F\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x02`\xF8\x1C\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x82\x14`\x08\x1B\x17a\x03\x85\x90\x84a\x07\x87V[\x92PP\x80a\x03\x92\x90a\x07\x9AV[\x90Pa\x02VV[P\x93P\x93\x91PPV[`\0\x80[a\x01\0\x81\x10\x15a\x03\xFBW`\x01\x81\x1B\x85\x16\x15a\x03\xF3W`\0\x81\x88`\x08\x1B\x01\x87\x02\x90Pa\x03\xF1\x89\x82\x87\x87\x80`\x01\x01\x98P\x81Q\x81\x10a\x03\xE4Wa\x03\xE4a\x06\xA3V[` \x02` \x01\x01Qa\x04GV[P[`\x01\x01a\x03\xA6V[P\x90\x96\x95PPPPPPV[`\0`\x01\x82\x90\x0Ba\x04<\x84\x7FS9\xC2\x96\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\x83\x85` a\x04\xB5V[PP`\0Q\x92\x91PPV[`\0a\x04is\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x85\x16\x84a\x04\xD6V[`\x02\x93\x90\x93\x0B\x82RP` \x80\x83\x01Q`\x0F\x0B\x90\x82\x01R\x81Qo\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16`@\x80\x83\x01\x91\x90\x91R\x82\x01Q``\x80\x83\x01\x91\x90\x91R\x90\x91\x01Q`\x80\x90\x91\x01RPV[\x83`\0R\x82`\x04R\x80\x82`$`\0\x88Z\xFAa\x04\xCFW`\0\x80\xFD[PPPPPV[`@\x80Qa\x01\0\x81\x01\x82R`\0\x80\x82R` \x82\x01\x81\x90R\x91\x81\x01\x82\x90R``\x81\x01\x82\x90R`\x80\x81\x01\x82\x90R`\xA0\x81\x01\x82\x90R`\xC0\x81\x01\x82\x90R`\xE0\x81\x01\x91\x90\x91R`\x02\x82\x90\x0B\x81a\x05L\x85\x7F\xF3\r\xBA\x93\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\x84\x84a\x01\0a\x04\xB5V[PP\x92\x91PPV[\x80`\x02\x0B\x81\x14a\x05cW`\0\x80\xFD[PV[`\0\x80`\0``\x84\x86\x03\x12\x15a\x05{W`\0\x80\xFD[\x835s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x16\x81\x14a\x05\x9FW`\0\x80\xFD[\x92P` \x84\x015a\x05\xAF\x81a\x05TV[\x91P`@\x84\x015a\x05\xBF\x81a\x05TV[\x80\x91PP\x92P\x92P\x92V[` \x80\x82R\x82Q\x82\x82\x01\x81\x90R`\0\x91\x90`@\x90\x81\x85\x01\x90\x86\x84\x01\x85[\x82\x81\x10\x15a\x06CW\x81Q\x80Q`\x02\x0B\x85R\x86\x81\x01Q`\x0F\x0B\x87\x86\x01R\x85\x81\x01Qo\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x86\x86\x01R``\x80\x82\x01Q\x90\x86\x01R`\x80\x90\x81\x01Q\x90\x85\x01R`\xA0\x90\x93\x01\x92\x90\x85\x01\x90`\x01\x01a\x05\xE7V[P\x91\x97\x96PPPPPPPV[`\0` \x82\x84\x03\x12\x15a\x06bW`\0\x80\xFD[\x81Qa\x06m\x81a\x05TV[\x93\x92PPPV[\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`\0R`A`\x04R`$`\0\xFD[\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`\0R`2`\x04R`$`\0\xFD[\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`\0R`\x11`\x04R`$`\0\xFD[`\x01\x82\x81\x0B\x90\x82\x90\x0B\x03\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\0\x81\x12a\x7F\xFF\x82\x13\x17\x15a\x07AWa\x07Aa\x06\xD2V[\x92\x91PPV[`\x01\x81\x81\x0B\x90\x83\x90\x0B\x01a\x7F\xFF\x81\x13\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\0\x82\x12\x17\x15a\x07AWa\x07Aa\x06\xD2V[\x80\x82\x01\x80\x82\x11\x15a\x07AWa\x07Aa\x06\xD2V[`\0\x81`\x01\x0Ba\x7F\xFF\x81\x03a\x07\xB1Wa\x07\xB1a\x06\xD2V[`\x01\x01\x92\x91PPV\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static EPHEMERALGETPOPULATEDTICKSINRANGE_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct EphemeralGetPopulatedTicksInRange(::ethers::contract::Contract); - impl ::core::clone::Clone for EphemeralGetPopulatedTicksInRange { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for EphemeralGetPopulatedTicksInRange { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for EphemeralGetPopulatedTicksInRange { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for EphemeralGetPopulatedTicksInRange { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(EphemeralGetPopulatedTicksInRange)) - .field(&self.address()) - .finish() - } - } - impl EphemeralGetPopulatedTicksInRange { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - EPHEMERALGETPOPULATEDTICKSINRANGE_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - EPHEMERALGETPOPULATEDTICKSINRANGE_ABI.clone(), - EPHEMERALGETPOPULATEDTICKSINRANGE_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - ///Calls the contract's `getPopulatedTicksInRange` (0xf2bb008b) function - pub fn get_populated_ticks_in_range( - &self, - pool: ::ethers::core::types::Address, - tick_lower: i32, - tick_upper: i32, - ) -> ::ethers::contract::builders::ContractCall> { - self.0 - .method_hash([242, 187, 0, 139], (pool, tick_lower, tick_upper)) - .expect("method not found (this should never happen)") - } - } - impl From<::ethers::contract::Contract> - for EphemeralGetPopulatedTicksInRange - { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Container type for all input parameters for the `getPopulatedTicksInRange` function with signature `getPopulatedTicksInRange(address,int24,int24)` and selector `0xf2bb008b` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall( - name = "getPopulatedTicksInRange", - abi = "getPopulatedTicksInRange(address,int24,int24)" - )] - pub struct GetPopulatedTicksInRangeCall { - pub pool: ::ethers::core::types::Address, - pub tick_lower: i32, - pub tick_upper: i32, - } - ///Container type for all return fields from the `getPopulatedTicksInRange` function with signature `getPopulatedTicksInRange(address,int24,int24)` and selector `0xf2bb008b` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct GetPopulatedTicksInRangeReturn { - pub populated_ticks: ::std::vec::Vec, - } - ///`PopulatedTick(int24,int128,uint128,uint256,uint256)` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct PopulatedTick { - pub tick: i32, - pub liquidity_net: i128, - pub liquidity_gross: u128, - pub fee_growth_outside_0x128: ::ethers::core::types::U256, - pub fee_growth_outside_1x128: ::ethers::core::types::U256, - } -} diff --git a/src/bindings/ephemeral_get_position.rs b/src/bindings/ephemeral_get_position.rs deleted file mode 100644 index b288ba9..0000000 --- a/src/bindings/ephemeral_get_position.rs +++ /dev/null @@ -1,233 +0,0 @@ -pub use ephemeral_get_position::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod ephemeral_get_position { - pub use super::super::shared_types::*; - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::Some(::ethers::core::abi::ethabi::Constructor { - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("npm"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "contract INonfungiblePositionManager", - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - }, - ], - }), - functions: ::core::convert::From::from([( - ::std::borrow::ToOwned::to_owned("getPosition"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("getPosition"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("npm"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "contract INonfungiblePositionManager", - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("state"), - kind: ::ethers::core::abi::ethabi::ParamType::Tuple(::std::vec![ - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Address, - ::ethers::core::abi::ethabi::ParamType::Tuple(::std::vec![ - ::ethers::core::abi::ethabi::ParamType::Uint(96usize), - ::ethers::core::abi::ethabi::ParamType::Address, - ::ethers::core::abi::ethabi::ParamType::Address, - ::ethers::core::abi::ethabi::ParamType::Address, - ::ethers::core::abi::ethabi::ParamType::Uint(24usize), - ::ethers::core::abi::ethabi::ParamType::Int(24usize), - ::ethers::core::abi::ethabi::ParamType::Int(24usize), - ::ethers::core::abi::ethabi::ParamType::Uint(128usize), - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Uint(128usize), - ::ethers::core::abi::ethabi::ParamType::Uint(128usize), - ],), - ::ethers::core::abi::ethabi::ParamType::Tuple(::std::vec![ - ::ethers::core::abi::ethabi::ParamType::Uint(160usize), - ::ethers::core::abi::ethabi::ParamType::Int(24usize), - ::ethers::core::abi::ethabi::ParamType::Uint(16usize), - ::ethers::core::abi::ethabi::ParamType::Uint(16usize), - ::ethers::core::abi::ethabi::ParamType::Uint(16usize), - ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - ::ethers::core::abi::ethabi::ParamType::Bool, - ],), - ::ethers::core::abi::ethabi::ParamType::Uint(128usize), - ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - ],), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "struct PositionState" - ),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Payable, - },], - )]), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static EPHEMERALGETPOSITION_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`\x80`@R`@Qb\0\t\x078\x03\x80b\0\t\x07\x839\x81\x01`@\x81\x90Rb\0\0&\x91b\0\x06\xE3V[`\0b\0\x004\x83\x83b\0\0dV[\x90P`\0\x81`@Q` \x01b\0\0K\x91\x90b\0\x07\x1FV[`@Q` \x81\x83\x03\x03\x81R\x90`@R\x90P\x80Q` \x82\x01\xFD[b\0\x014`@\x80Q`\xE0\x80\x82\x01\x83R`\0\x80\x83R` \x80\x84\x01\x82\x90R\x84Qa\x01\x80\x81\x01\x86R\x82\x81R\x90\x81\x01\x82\x90R\x80\x85\x01\x82\x90R``\x81\x01\x82\x90R`\x80\x81\x01\x82\x90R`\xA0\x81\x01\x82\x90R`\xC0\x81\x01\x82\x90R\x91\x82\x01\x81\x90Ra\x01\0\x82\x01\x81\x90Ra\x01 \x82\x01\x81\x90Ra\x01@\x82\x01\x81\x90Ra\x01`\x82\x01R\x90\x91\x82\x01\x90\x81R`@\x80Q`\xE0\x81\x01\x82R`\0\x80\x82R` \x82\x81\x01\x82\x90R\x92\x82\x01\x81\x90R``\x82\x01\x81\x90R`\x80\x82\x01\x81\x90R`\xA0\x82\x01\x81\x90R`\xC0\x82\x01R\x91\x01\x90\x81R`\0` \x82\x01\x81\x90R`@\x82\x01\x81\x90R``\x90\x91\x01R\x90V[b\0\x01@\x83\x83b\0\x01vV[`\x01`\x01`\xA0\x1B\x03\x16` \x82\x01R`@\x81\x01Qb\0\x01b\x90\x84\x90\x84\x90b\0\x01\x95V[Pb\0\x01p\x83\x83\x83b\0\x01\xBBV[\x92\x91PPV[`\0\x80b\0\x01\x8D\x84c1\xA9\x10\x8F`\xE1\x1B\x85b\0\x03rV[\x94\x93PPPPV[c\x13?uq`\xE3\x1B`\0\x81\x81R`\x04\x84\x90R\x90a\x01\x80\x83`$\x84\x88Z\xFA\x95\x94PPPPPV[\x81\x81R`@\x81\x01Q`\0b\0\x02>b\0\x01\xD4\x86b\0\x03\xA1V[`@\x84\x01Q``\x85\x01Q`\x80\x86\x01Q`@\x80Q`\0\x94\x85R` \x93\x84R\x91\x81R``\x84 `\xFF`\xA0\x1B\x95\x90\x95\x17\x90\x93R\x92\x90R\x7F\xE3O\x19\x9B\x19\xB2\xB4\xF4\x7FhD&\x19\xD5UR}$Ox\xA3)~\xA8\x93%\xF8C\xF8{\x8BT\x81R`U`\x0B \x91\x90R`\x01`\x01`\xA0\x1B\x03\x16\x90V[\x90Pb\0\x02T`\x01`\x01`\xA0\x1B\x03\x82\x16b\0\x03\xBEV[`\x01`\x01`\x80\x1B\x03\x16`\x80\x84\x01R``\x83\x01Qb\0\x02t\x90\x82\x90b\0\x03\xD4V[`\xE0\x82\x01Q`\x01`\x01`\x80\x1B\x03\x16\x15b\0\x03&W`\0\x80b\0\x02\xAF\x83\x85`\xA0\x01Q\x86`\xC0\x01Q\x88``\x01Q` \x01Qb\0\x03\xFB` \x1B` \x1CV[\x91P\x91P`\0\x80b\0\x02\xD9\x86`\xE0\x01Q\x85\x85\x89a\x01\0\x01Q\x8Aa\x01 \x01Qb\0\x04\xE2` \x1B` \x1CV[\x91P\x91P\x81\x86a\x01@\x01\x81\x81Qb\0\x02\xF2\x91\x90b\0\x08\xD7V[`\x01`\x01`\x80\x1B\x03\x16\x90RPa\x01`\x86\x01\x80Q\x82\x91\x90b\0\x03\x15\x90\x83\x90b\0\x08\xD7V[`\x01`\x01`\x80\x1B\x03\x16\x90RPPPPP[`@\x82\x01Qb\0\x03?\x90`\x01`\x01`\xA0\x1B\x03\x16b\0\x05+V[`\xFF\x16`\xA0\x84\x01R``\x82\x01Qb\0\x03`\x90`\x01`\x01`\xA0\x1B\x03\x16b\0\x05+V[`\xFF\x16`\xC0\x90\x93\x01\x92\x90\x92RPPPPV[`\0\x82`\0R\x81`\x04R` `\0`$`\0\x87Z\xFAb\0\x03\x96W=`\0\x80>=`\0\xFD[PP`\0Q\x92\x91PPV[`\0\x80b\0\x03\xB7\x83c\xC4Z\x01U`\xE0\x1Bb\0\x05QV[\x93\x92PPPV[`\0\x80b\0\x03\xB7\x83c\r42\x81`\xE1\x1Bb\0\x05QV[c8P\xC7\xBD`\xE0\x1B`\0\x81\x81R`\xE0\x90\x83\x90`\x04\x90\x86Z\xFAb\0\x03\xF6W`\0\x80\xFD[PPPV[`\0\x80\x80b\0\x04\x14`\x01`\x01`\xA0\x1B\x03\x88\x16\x87b\0\x05vV[\x90P`\0b\0\x04-`\x01`\x01`\xA0\x1B\x03\x89\x16\x87b\0\x05vV[\x90P\x86`\x02\x0B\x85`\x02\x0B\x12\x15b\0\x04^W\x80`@\x01Q\x82`@\x01Q\x03\x93P\x80``\x01Q\x82``\x01Q\x03\x92Pb\0\x04\xD7V[\x85`\x02\x0B\x85`\x02\x0B\x12b\0\x04\x8CW\x81`@\x01Q\x81`@\x01Q\x03\x93P\x81``\x01Q\x81``\x01Q\x03\x92Pb\0\x04\xD7V[`@\x80\x82\x01Q\x90\x83\x01Qb\0\x04\xAA`\x01`\x01`\xA0\x1B\x03\x8B\x16b\0\x05\xDDV[\x03\x03\x93P\x80``\x01Q\x82``\x01Qb\0\x04\xD2\x8A`\x01`\x01`\xA0\x1B\x03\x16b\0\x05\xF2` \x1B` \x1CV[\x03\x03\x92P[PP\x94P\x94\x92PPPV[`\0\x80b\0\x05\x01`\x01`\x01`\x80\x1B\x03\x88\x16\x85\x88\x03`\x01`\x80\x1Bb\0\x06\x07V[\x91Pb\0\x05\x1F`\x01`\x01`\x80\x1B\x03\x88\x16\x84\x87\x03`\x01`\x80\x1Bb\0\x06\x07V[\x90P\x95P\x95\x93PPPPV[`\x12`\0\x90\x81Rc1<\xE5g`\xE0\x1B` \x81\x81R\x80`\x04\x81\x86Z\xFA`\x05\x1BQ\x93\x92PPPV[`\0\x81`\0R` `\0`\x04`\0\x86Z\xFAb\0\x05lW`\0\x80\xFD[PP`\0Q\x91\x90PV[`@\x80Qa\x01\0\x81\x01\x82R`\0\x80\x82R` \x82\x01\x81\x90R\x91\x81\x01\x82\x90R``\x81\x01\x82\x90R`\x80\x81\x01\x82\x90R`\xA0\x81\x01\x82\x90R`\xC0\x81\x01\x82\x90R`\xE0\x81\x01\x91\x90\x91R`\x02\x82\x90\x0B\x81b\0\x05\xD5\x85c\xF3\r\xBA\x93`\xE0\x1B\x84\x84a\x01\0b\0\x06\x16V[PP\x92\x91PPV[`\0b\0\x01p\x82c\xF3\x05\x83\x99`\xE0\x1Bb\0\x05QV[`\0b\0\x01p\x82cF\x14\x13\x19`\xE0\x1Bb\0\x05QV[`\0b\0\x01\x8D\x84\x84\x84b\0\x068V[\x83`\0R\x82`\x04R\x80\x82`$`\0\x88Z\xFAb\0\x061W`\0\x80\xFD[PPPPPV[`\0\x83\x83\x02`\0\x19\x84\x86\t\x81\x81\x10\x82\x01\x90\x03\x80b\0\x06pW\x83b\0\x06dWc\xAEG\xF7\x02`\0R`\x04`\x1C\xFD[P\x82\x90\x04\x90Pb\0\x03\xB7V[\x80\x84\x11b\0\x06\x86Wc\xAEG\xF7\x02`\0R`\x04`\x1C\xFD[\x83\x85\x87\t`\0\x85\x81\x03\x86\x16\x95\x86\x90\x04\x95\x84\x83\x11\x90\x93\x03\x90\x83\x90\x03\x83\x90\x04`\x01\x01\x02\x92\x03\x04\x17`\x03\x83\x02`\x02\x90\x81\x18\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x90\x91\x03\x02\x02\x90P\x93\x92PPPV[`\0\x80`@\x83\x85\x03\x12\x15b\0\x06\xF7W`\0\x80\xFD[\x82Q`\x01`\x01`\xA0\x1B\x03\x81\x16\x81\x14b\0\x07\x0FW`\0\x80\xFD[` \x93\x90\x93\x01Q\x92\x94\x92\x93PPPV[\x81Q\x81R` \x80\x83\x01Q`\x01`\x01`\xA0\x1B\x03\x16\x90\x82\x01R`@\x80\x83\x01Q\x80Qa\x03\0\x84\x01\x92b\0\x07Z\x91\x90\x85\x01\x90`\x01`\x01``\x1B\x03\x16\x90RV[` \x81\x01Q`\x01`\x01`\xA0\x1B\x03\x81\x16``\x85\x01RP`@\x81\x01Q`\x01`\x01`\xA0\x1B\x03\x81\x16`\x80\x85\x01RP``\x81\x01Q`\x01`\x01`\xA0\x1B\x03\x81\x16`\xA0\x85\x01RP`\x80\x81\x01Qb\xFF\xFF\xFF\x81\x16`\xC0\x85\x01RP`\xA0\x81\x01Qb\0\x07\xBF`\xE0\x85\x01\x82`\x02\x0B\x90RV[P`\xC0\x81\x01Qa\x01\0b\0\x07\xD7\x81\x86\x01\x83`\x02\x0B\x90RV[`\xE0\x83\x01Q\x91Pa\x01 b\0\x07\xF6\x81\x87\x01\x84`\x01`\x01`\x80\x1B\x03\x16\x90RV[\x90\x83\x01Qa\x01@\x86\x81\x01\x91\x90\x91R\x90\x83\x01Qa\x01`\x80\x87\x01\x91\x90\x91R\x90\x83\x01Q`\x01`\x01`\x80\x1B\x03\x90\x81\x16a\x01\x80\x87\x01R\x92\x01Q\x91\x82\x16a\x01\xA0\x85\x01RPP``\x83\x81\x01Q\x80Q`\x01`\x01`\xA0\x1B\x03\x16a\x01\xC0\x85\x01R` \x81\x01Q`\x02\x0Ba\x01\xE0\x85\x01R`@\x81\x01Qa\xFF\xFF\x90\x81\x16a\x02\0\x86\x01R\x91\x81\x01Q\x82\x16a\x02 \x85\x01R`\x80\x80\x82\x01Q\x90\x92\x16a\x02@\x85\x01R`\xA0\x80\x82\x01Q`\xFF\x90\x81\x16a\x02`\x87\x01R`\xC0\x92\x83\x01Q\x15\x15a\x02\x80\x87\x01R\x92\x86\x01Q`\x01`\x01`\x80\x1B\x03\x16a\x02\xA0\x86\x01R\x85\x01Q\x82\x16a\x02\xC0\x85\x01R\x84\x01Q\x90\x81\x16a\x02\xE0\x84\x01R[P\x92\x91PPV[`\x01`\x01`\x80\x1B\x03\x81\x81\x16\x83\x82\x16\x01\x90\x80\x82\x11\x15b\0\x08\xD0WcNH{q`\xE0\x1B`\0R`\x11`\x04R`$`\0\xFD\xFE"; - /// The bytecode of the contract. - pub static EPHEMERALGETPOSITION_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"`\x80`@R`\x046\x10a\0\x1EW`\x005`\xE0\x1C\x80c:\xDB\xB5\xAF\x14a\0#W[`\0\x80\xFD[a\x006a\x0016`\x04a\x08LV[a\0LV[`@Qa\0C\x91\x90a\x08\x91V[`@Q\x80\x91\x03\x90\xF3[a\x01\x1B`@\x80Q`\xE0\x80\x82\x01\x83R`\0\x80\x83R` \x80\x84\x01\x82\x90R\x84Qa\x01\x80\x81\x01\x86R\x82\x81R\x90\x81\x01\x82\x90R\x80\x85\x01\x82\x90R``\x81\x01\x82\x90R`\x80\x81\x01\x82\x90R`\xA0\x81\x01\x82\x90R`\xC0\x81\x01\x82\x90R\x91\x82\x01\x81\x90Ra\x01\0\x82\x01\x81\x90Ra\x01 \x82\x01\x81\x90Ra\x01@\x82\x01\x81\x90Ra\x01`\x82\x01R\x90\x91\x82\x01\x90\x81R`@\x80Q`\xE0\x81\x01\x82R`\0\x80\x82R` \x82\x81\x01\x82\x90R\x92\x82\x01\x81\x90R``\x82\x01\x81\x90R`\x80\x82\x01\x81\x90R`\xA0\x82\x01\x81\x90R`\xC0\x82\x01R\x91\x01\x90\x81R`\0` \x82\x01\x81\x90R`@\x82\x01\x81\x90R``\x90\x91\x01R\x90V[a\x01%\x83\x83a\x01dV[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16` \x82\x01R`@\x81\x01Qa\x01R\x90\x84\x90\x84\x90a\x01\x9AV[Pa\x01^\x83\x83\x83a\x01\xD9V[\x92\x91PPV[`\0\x80a\x01\x92\x84\x7FcR!\x1E\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\x85a\x03\xD8V[\x94\x93PPPPV[\x7F\x99\xFB\xAB\x88\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`\0\x81\x81R`\x04\x84\x90R\x90a\x01\x80\x83`$\x84\x88Z\xFA\x95\x94PPPPPV[\x81\x81R`@\x81\x01Q`\0a\x02wa\x01\xEF\x86a\x04\x06V[\x83`@\x01Q\x84``\x01Q\x85`\x80\x01Q`@\x80Q`\0\x94\x85R` \x93\x84R\x91\x81R``\x84 t\xFF\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x95\x90\x95\x17\x90\x93R\x92\x90R\x7F\xE3O\x19\x9B\x19\xB2\xB4\xF4\x7FhD&\x19\xD5UR}$Ox\xA3)~\xA8\x93%\xF8C\xF8{\x8BT\x81R`U`\x0B \x91\x90Rs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x90V[\x90Pa\x02\x98\x81s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x04:V[o\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16`\x80\x84\x01R``\x83\x01Qa\x02\xBF\x90\x82\x90a\x04gV[`\xE0\x82\x01Qo\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x15a\x03wW`\0\x80a\x02\xFA\x83\x85`\xA0\x01Q\x86`\xC0\x01Q\x88``\x01Q` \x01Qa\x04\xA6V[\x91P\x91P`\0\x80a\x03\x1C\x86`\xE0\x01Q\x85\x85\x89a\x01\0\x01Q\x8Aa\x01 \x01Qa\x05\xAFV[\x91P\x91P\x81\x86a\x01@\x01\x81\x81Qa\x033\x91\x90a\n\xA7V[o\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x90RPa\x01`\x86\x01\x80Q\x82\x91\x90a\x03]\x90\x83\x90a\n\xA7V[o\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x90RPPPPP[a\x03\x9A\x82`@\x01Qs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x06 V[`\xFF\x16`\xA0\x84\x01R``\x82\x01Qa\x03\xC6\x90s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x06 V[`\xFF\x16`\xC0\x90\x93\x01\x92\x90\x92RPPPPV[`\0\x82`\0R\x81`\x04R` `\0`$`\0\x87Z\xFAa\x03\xFBW=`\0\x80>=`\0\xFD[PP`\0Q\x92\x91PPV[`\0\x80a\x043\x83\x7F\xC4Z\x01U\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\0a\x06_V[\x93\x92PPPV[`\0\x80a\x043\x83\x7F\x1Ahe\x02\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\0a\x06_V[\x7F8P\xC7\xBD\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`\0\x81\x81R`\xE0\x90\x83\x90`\x04\x90\x86Z\xFAa\x04\xA1W`\0\x80\xFD[PPPV[`\0\x80\x80a\x04\xCAs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x88\x16\x87a\x06\x83V[\x90P`\0a\x04\xEEs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x89\x16\x87a\x06\x83V[\x90P\x86`\x02\x0B\x85`\x02\x0B\x12\x15a\x05\x1DW\x80`@\x01Q\x82`@\x01Q\x03\x93P\x80``\x01Q\x82``\x01Q\x03\x92Pa\x05\xA4V[\x85`\x02\x0B\x85`\x02\x0B\x12a\x05IW\x81`@\x01Q\x81`@\x01Q\x03\x93P\x81``\x01Q\x81``\x01Q\x03\x92Pa\x05\xA4V[\x80`@\x01Q\x82`@\x01Qa\x05r\x8As\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x07\x01V[\x03\x03\x93P\x80``\x01Q\x82``\x01Qa\x05\x9F\x8As\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x07-V[\x03\x03\x92P[PP\x94P\x94\x92PPPV[`\0\x80a\x05\xE2o\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x88\x16\x85\x88\x03p\x01\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0a\x07YV[\x91Pa\x06\x14o\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x88\x16\x84\x87\x03p\x01\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0a\x07YV[\x90P\x95P\x95\x93PPPPV[`\x12`\0\x90\x81R\x7F1<\xE5g\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` \x81\x81R\x80`\x04\x81\x86Z\xFA`\x05\x1BQ\x93\x92PPPV[`\0\x81`\0R` `\0`\x04`\0\x86Z\xFAa\x06yW`\0\x80\xFD[PP`\0Q\x91\x90PV[`@\x80Qa\x01\0\x81\x01\x82R`\0\x80\x82R` \x82\x01\x81\x90R\x91\x81\x01\x82\x90R``\x81\x01\x82\x90R`\x80\x81\x01\x82\x90R`\xA0\x81\x01\x82\x90R`\xC0\x81\x01\x82\x90R`\xE0\x81\x01\x91\x90\x91R`\x02\x82\x90\x0B\x81a\x06\xF9\x85\x7F\xF3\r\xBA\x93\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\x84\x84a\x01\0a\x07fV[PP\x92\x91PPV[`\0a\x01^\x82\x7F\xF3\x05\x83\x99\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\0a\x06_V[`\0a\x01^\x82\x7FF\x14\x13\x19\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\0a\x06_V[`\0a\x01\x92\x84\x84\x84a\x07\x87V[\x83`\0R\x82`\x04R\x80\x82`$`\0\x88Z\xFAa\x07\x80W`\0\x80\xFD[PPPPPV[`\0\x83\x83\x02\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x84\x86\t\x81\x81\x10\x82\x01\x90\x03\x80a\x07\xDAW\x83a\x07\xCFWc\xAEG\xF7\x02`\0R`\x04`\x1C\xFD[P\x82\x90\x04\x90Pa\x043V[\x80\x84\x11a\x07\xEFWc\xAEG\xF7\x02`\0R`\x04`\x1C\xFD[\x83\x85\x87\t`\0\x85\x81\x03\x86\x16\x95\x86\x90\x04\x95\x84\x83\x11\x90\x93\x03\x90\x83\x90\x03\x83\x90\x04`\x01\x01\x02\x92\x03\x04\x17`\x03\x83\x02`\x02\x90\x81\x18\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x90\x91\x03\x02\x02\x90P\x93\x92PPPV[`\0\x80`@\x83\x85\x03\x12\x15a\x08_W`\0\x80\xFD[\x825s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x16\x81\x14a\x08\x83W`\0\x80\xFD[\x94` \x93\x90\x93\x015\x93PPPV[`\0a\x03\0\x82\x01\x90P\x82Q\x82Rs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF` \x84\x01Q\x16` \x83\x01R`@\x83\x01Qa\x08\xDE`@\x84\x01\x82Qk\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x90RV[` \x81\x01Qs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x16``\x85\x01RP`@\x81\x01Qs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x16`\x80\x85\x01RP``\x81\x01Qs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x16`\xA0\x85\x01RP`\x80\x81\x01Qb\xFF\xFF\xFF\x81\x16`\xC0\x85\x01RP`\xA0\x81\x01Qa\ti`\xE0\x85\x01\x82`\x02\x0B\x90RV[P`\xC0\x81\x01Qa\x01\0a\t\x80\x81\x86\x01\x83`\x02\x0B\x90RV[`\xE0\x83\x01Q\x91Pa\x01 a\t\xA7\x81\x87\x01\x84o\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x90RV[\x90\x83\x01Qa\x01@\x86\x81\x01\x91\x90\x91R\x90\x83\x01Qa\x01`\x80\x87\x01\x91\x90\x91R\x90\x83\x01Qo\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x90\x81\x16a\x01\x80\x87\x01R\x92\x01Q\x91\x82\x16a\x01\xA0\x85\x01RPP``\x83\x81\x01Q\x80Qs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x01\xC0\x85\x01R` \x81\x01Q`\x02\x0Ba\x01\xE0\x85\x01R`@\x81\x01Qa\xFF\xFF\x90\x81\x16a\x02\0\x86\x01R\x91\x81\x01Q\x82\x16a\x02 \x85\x01R`\x80\x80\x82\x01Q\x90\x92\x16a\x02@\x85\x01R`\xA0\x80\x82\x01Q`\xFF\x90\x81\x16a\x02`\x87\x01R`\xC0\x92\x83\x01Q\x15\x15a\x02\x80\x87\x01R\x92\x86\x01Qo\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x02\xA0\x86\x01R\x85\x01Q\x82\x16a\x02\xC0\x85\x01R\x84\x01Q\x90\x81\x16a\x02\xE0\x84\x01R[P\x92\x91PPV[o\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x81\x16\x83\x82\x16\x01\x90\x80\x82\x11\x15a\n\xA0W\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`\0R`\x11`\x04R`$`\0\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static EPHEMERALGETPOSITION_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct EphemeralGetPosition(::ethers::contract::Contract); - impl ::core::clone::Clone for EphemeralGetPosition { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for EphemeralGetPosition { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for EphemeralGetPosition { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for EphemeralGetPosition { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(EphemeralGetPosition)) - .field(&self.address()) - .finish() - } - } - impl EphemeralGetPosition { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - EPHEMERALGETPOSITION_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - EPHEMERALGETPOSITION_ABI.clone(), - EPHEMERALGETPOSITION_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - ///Calls the contract's `getPosition` (0x3adbb5af) function - pub fn get_position( - &self, - npm: ::ethers::core::types::Address, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([58, 219, 181, 175], (npm, token_id)) - .expect("method not found (this should never happen)") - } - } - impl From<::ethers::contract::Contract> for EphemeralGetPosition { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Container type for all input parameters for the `getPosition` function with signature `getPosition(address,uint256)` and selector `0x3adbb5af` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "getPosition", abi = "getPosition(address,uint256)")] - pub struct GetPositionCall { - pub npm: ::ethers::core::types::Address, - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all return fields from the `getPosition` function with signature `getPosition(address,uint256)` and selector `0x3adbb5af` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct GetPositionReturn { - pub state: PositionState, - } -} diff --git a/src/bindings/ephemeral_get_positions.rs b/src/bindings/ephemeral_get_positions.rs deleted file mode 100644 index c8ec5d2..0000000 --- a/src/bindings/ephemeral_get_positions.rs +++ /dev/null @@ -1,239 +0,0 @@ -pub use ephemeral_get_positions::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod ephemeral_get_positions { - pub use super::super::shared_types::*; - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::Some(::ethers::core::abi::ethabi::Constructor { - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("npm"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "contract INonfungiblePositionManager", - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenIds"), - kind: ::ethers::core::abi::ethabi::ParamType::Array(::std::boxed::Box::new( - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ),), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256[]"),), - }, - ], - }), - functions: ::core::convert::From::from([( - ::std::borrow::ToOwned::to_owned("getPositions"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("getPositions"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("npm"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "contract INonfungiblePositionManager", - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenIds"), - kind: ::ethers::core::abi::ethabi::ParamType::Array(::std::boxed::Box::new( - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ),), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256[]"),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("positions"), - kind: ::ethers::core::abi::ethabi::ParamType::Array(::std::boxed::Box::new( - ::ethers::core::abi::ethabi::ParamType::Tuple(::std::vec![ - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Address, - ::ethers::core::abi::ethabi::ParamType::Tuple(::std::vec![ - ::ethers::core::abi::ethabi::ParamType::Uint(96usize), - ::ethers::core::abi::ethabi::ParamType::Address, - ::ethers::core::abi::ethabi::ParamType::Address, - ::ethers::core::abi::ethabi::ParamType::Address, - ::ethers::core::abi::ethabi::ParamType::Uint(24usize), - ::ethers::core::abi::ethabi::ParamType::Int(24usize), - ::ethers::core::abi::ethabi::ParamType::Int(24usize), - ::ethers::core::abi::ethabi::ParamType::Uint(128usize), - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Uint(128usize), - ::ethers::core::abi::ethabi::ParamType::Uint(128usize), - ],), - ::ethers::core::abi::ethabi::ParamType::Tuple(::std::vec![ - ::ethers::core::abi::ethabi::ParamType::Uint(160usize), - ::ethers::core::abi::ethabi::ParamType::Int(24usize), - ::ethers::core::abi::ethabi::ParamType::Uint(16usize), - ::ethers::core::abi::ethabi::ParamType::Uint(16usize), - ::ethers::core::abi::ethabi::ParamType::Uint(16usize), - ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - ::ethers::core::abi::ethabi::ParamType::Bool, - ],), - ::ethers::core::abi::ethabi::ParamType::Uint(128usize), - ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - ],), - ),), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "struct PositionState[]" - ),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Payable, - },], - )]), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static EPHEMERALGETPOSITIONS_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`\x80`@R`@Qb\0\n\xF48\x03\x80b\0\n\xF4\x839\x81\x01`@\x81\x90Rb\0\0&\x91b\0\x07\xC1V[`\0b\0\x004\x83\x83b\0\0dV[\x90P`\0\x81`@Q` \x01b\0\0K\x91\x90b\0\x08\xAEV[`@Q` \x81\x83\x03\x03\x81R\x90`@R\x90P\x80Q` \x82\x01\xFD[\x80Q``\x90\x80`\x01`\x01`@\x1B\x03\x81\x11\x15b\0\0\x84Wb\0\0\x84b\0\x07\xABV[`@Q\x90\x80\x82R\x80` \x02` \x01\x82\x01`@R\x80\x15b\0\x01\x87W\x81` \x01[b\0\x01s`@\x80Q`\xE0\x80\x82\x01\x83R`\0\x80\x83R` \x80\x84\x01\x82\x90R\x84Qa\x01\x80\x81\x01\x86R\x82\x81R\x90\x81\x01\x82\x90R\x80\x85\x01\x82\x90R``\x81\x01\x82\x90R`\x80\x81\x01\x82\x90R`\xA0\x81\x01\x82\x90R`\xC0\x81\x01\x82\x90R\x91\x82\x01\x81\x90Ra\x01\0\x82\x01\x81\x90Ra\x01 \x82\x01\x81\x90Ra\x01@\x82\x01\x81\x90Ra\x01`\x82\x01R\x90\x91\x82\x01\x90\x81R`@\x80Q`\xE0\x81\x01\x82R`\0\x80\x82R` \x82\x81\x01\x82\x90R\x92\x82\x01\x81\x90R``\x82\x01\x81\x90R`\x80\x82\x01\x81\x90R`\xA0\x82\x01\x81\x90R`\xC0\x82\x01R\x91\x01\x90\x81R`\0` \x82\x01\x81\x90R`@\x82\x01\x81\x90R``\x90\x91\x01R\x90V[\x81R` \x01\x90`\x01\x90\x03\x90\x81b\0\0\xA3W\x90P[P\x91P`\0\x80[\x82\x81\x10\x15b\0\x02.W`\0\x85\x82\x81Q\x81\x10b\0\x01\xAEWb\0\x01\xAEb\0\n\xA7V[` \x02` \x01\x01Q\x90P`\0\x85\x84\x81Q\x81\x10b\0\x01\xCFWb\0\x01\xCFb\0\n\xA7V[` \x02` \x01\x01Q\x90Pb\0\x01\xF0\x88\x83\x83`@\x01Qb\0\x028` \x1B` \x1CV[\x15b\0\x02#W`\x01\x90\x93\x01\x92b\0\x02\x08\x88\x83b\0\x02^V[`\x01`\x01`\xA0\x1B\x03\x16` \x82\x01Rb\0\x02#\x88\x83\x83b\0\x02}V[PP`\x01\x01b\0\x01\x8EV[P\x82RP\x92\x91PPV[c\x13?uq`\xE3\x1B`\0\x81\x81R`\x04\x84\x90R\x90a\x01\x80\x83`$\x84\x88Z\xFA\x95\x94PPPPPV[`\0\x80b\0\x02u\x84c1\xA9\x10\x8F`\xE1\x1B\x85b\0\x044V[\x94\x93PPPPV[\x81\x81R`@\x81\x01Q`\0b\0\x03\0b\0\x02\x96\x86b\0\x04cV[`@\x84\x01Q``\x85\x01Q`\x80\x86\x01Q`@\x80Q`\0\x94\x85R` \x93\x84R\x91\x81R``\x84 `\xFF`\xA0\x1B\x95\x90\x95\x17\x90\x93R\x92\x90R\x7F\xE3O\x19\x9B\x19\xB2\xB4\xF4\x7FhD&\x19\xD5UR}$Ox\xA3)~\xA8\x93%\xF8C\xF8{\x8BT\x81R`U`\x0B \x91\x90R`\x01`\x01`\xA0\x1B\x03\x16\x90V[\x90Pb\0\x03\x16`\x01`\x01`\xA0\x1B\x03\x82\x16b\0\x04\x80V[`\x01`\x01`\x80\x1B\x03\x16`\x80\x84\x01R``\x83\x01Qb\0\x036\x90\x82\x90b\0\x04\x96V[`\xE0\x82\x01Q`\x01`\x01`\x80\x1B\x03\x16\x15b\0\x03\xE8W`\0\x80b\0\x03q\x83\x85`\xA0\x01Q\x86`\xC0\x01Q\x88``\x01Q` \x01Qb\0\x04\xBD` \x1B` \x1CV[\x91P\x91P`\0\x80b\0\x03\x9B\x86`\xE0\x01Q\x85\x85\x89a\x01\0\x01Q\x8Aa\x01 \x01Qb\0\x05\xA4` \x1B` \x1CV[\x91P\x91P\x81\x86a\x01@\x01\x81\x81Qb\0\x03\xB4\x91\x90b\0\n\xBDV[`\x01`\x01`\x80\x1B\x03\x16\x90RPa\x01`\x86\x01\x80Q\x82\x91\x90b\0\x03\xD7\x90\x83\x90b\0\n\xBDV[`\x01`\x01`\x80\x1B\x03\x16\x90RPPPPP[`@\x82\x01Qb\0\x04\x01\x90`\x01`\x01`\xA0\x1B\x03\x16b\0\x05\xEDV[`\xFF\x16`\xA0\x84\x01R``\x82\x01Qb\0\x04\"\x90`\x01`\x01`\xA0\x1B\x03\x16b\0\x05\xEDV[`\xFF\x16`\xC0\x90\x93\x01\x92\x90\x92RPPPPV[`\0\x82`\0R\x81`\x04R` `\0`$`\0\x87Z\xFAb\0\x04XW=`\0\x80>=`\0\xFD[PP`\0Q\x92\x91PPV[`\0\x80b\0\x04y\x83c\xC4Z\x01U`\xE0\x1Bb\0\x06\x13V[\x93\x92PPPV[`\0\x80b\0\x04y\x83c\r42\x81`\xE1\x1Bb\0\x06\x13V[c8P\xC7\xBD`\xE0\x1B`\0\x81\x81R`\xE0\x90\x83\x90`\x04\x90\x86Z\xFAb\0\x04\xB8W`\0\x80\xFD[PPPV[`\0\x80\x80b\0\x04\xD6`\x01`\x01`\xA0\x1B\x03\x88\x16\x87b\0\x068V[\x90P`\0b\0\x04\xEF`\x01`\x01`\xA0\x1B\x03\x89\x16\x87b\0\x068V[\x90P\x86`\x02\x0B\x85`\x02\x0B\x12\x15b\0\x05 W\x80`@\x01Q\x82`@\x01Q\x03\x93P\x80``\x01Q\x82``\x01Q\x03\x92Pb\0\x05\x99V[\x85`\x02\x0B\x85`\x02\x0B\x12b\0\x05NW\x81`@\x01Q\x81`@\x01Q\x03\x93P\x81``\x01Q\x81``\x01Q\x03\x92Pb\0\x05\x99V[`@\x80\x82\x01Q\x90\x83\x01Qb\0\x05l`\x01`\x01`\xA0\x1B\x03\x8B\x16b\0\x06\x9FV[\x03\x03\x93P\x80``\x01Q\x82``\x01Qb\0\x05\x94\x8A`\x01`\x01`\xA0\x1B\x03\x16b\0\x06\xBA` \x1B` \x1CV[\x03\x03\x92P[PP\x94P\x94\x92PPPV[`\0\x80b\0\x05\xC3`\x01`\x01`\x80\x1B\x03\x88\x16\x85\x88\x03`\x01`\x80\x1Bb\0\x06\xCFV[\x91Pb\0\x05\xE1`\x01`\x01`\x80\x1B\x03\x88\x16\x84\x87\x03`\x01`\x80\x1Bb\0\x06\xCFV[\x90P\x95P\x95\x93PPPPV[`\x12`\0\x90\x81Rc1<\xE5g`\xE0\x1B` \x81\x81R\x80`\x04\x81\x86Z\xFA`\x05\x1BQ\x93\x92PPPV[`\0\x81`\0R` `\0`\x04`\0\x86Z\xFAb\0\x06.W`\0\x80\xFD[PP`\0Q\x91\x90PV[`@\x80Qa\x01\0\x81\x01\x82R`\0\x80\x82R` \x82\x01\x81\x90R\x91\x81\x01\x82\x90R``\x81\x01\x82\x90R`\x80\x81\x01\x82\x90R`\xA0\x81\x01\x82\x90R`\xC0\x81\x01\x82\x90R`\xE0\x81\x01\x91\x90\x91R`\x02\x82\x90\x0B\x81b\0\x06\x97\x85c\xF3\r\xBA\x93`\xE0\x1B\x84\x84a\x01\0b\0\x06\xDEV[PP\x92\x91PPV[`\0b\0\x06\xB4\x82c\xF3\x05\x83\x99`\xE0\x1Bb\0\x06\x13V[\x92\x91PPV[`\0b\0\x06\xB4\x82cF\x14\x13\x19`\xE0\x1Bb\0\x06\x13V[`\0b\0\x02u\x84\x84\x84b\0\x07\0V[\x83`\0R\x82`\x04R\x80\x82`$`\0\x88Z\xFAb\0\x06\xF9W`\0\x80\xFD[PPPPPV[`\0\x83\x83\x02`\0\x19\x84\x86\t\x81\x81\x10\x82\x01\x90\x03\x80b\0\x078W\x83b\0\x07,Wc\xAEG\xF7\x02`\0R`\x04`\x1C\xFD[P\x82\x90\x04\x90Pb\0\x04yV[\x80\x84\x11b\0\x07NWc\xAEG\xF7\x02`\0R`\x04`\x1C\xFD[\x83\x85\x87\t`\0\x85\x81\x03\x86\x16\x95\x86\x90\x04\x95\x84\x83\x11\x90\x93\x03\x90\x83\x90\x03\x83\x90\x04`\x01\x01\x02\x92\x03\x04\x17`\x03\x83\x02`\x02\x90\x81\x18\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x90\x91\x03\x02\x02\x90P\x93\x92PPPV[cNH{q`\xE0\x1B`\0R`A`\x04R`$`\0\xFD[`\0\x80`@\x83\x85\x03\x12\x15b\0\x07\xD5W`\0\x80\xFD[\x82Q`\x01`\x01`\xA0\x1B\x03\x81\x16\x81\x14b\0\x07\xEDW`\0\x80\xFD[` \x84\x81\x01Q\x91\x93P\x90`\x01`\x01`@\x1B\x03\x80\x82\x11\x15b\0\x08\rW`\0\x80\xFD[\x81\x86\x01\x91P\x86`\x1F\x83\x01\x12b\0\x08\"W`\0\x80\xFD[\x81Q\x81\x81\x11\x15b\0\x087Wb\0\x087b\0\x07\xABV[\x80`\x05\x1B`@Q`\x1F\x19`?\x83\x01\x16\x81\x01\x81\x81\x10\x85\x82\x11\x17\x15b\0\x08_Wb\0\x08_b\0\x07\xABV[`@R\x91\x82R\x84\x82\x01\x92P\x83\x81\x01\x85\x01\x91\x89\x83\x11\x15b\0\x08~W`\0\x80\xFD[\x93\x85\x01\x93[\x82\x85\x10\x15b\0\x08\x9EW\x84Q\x84R\x93\x85\x01\x93\x92\x85\x01\x92b\0\x08\x83V[\x80\x96PPPPPPP\x92P\x92\x90PV[` \x80\x82R\x82Q\x82\x82\x01\x81\x90R`\0\x91\x90`@\x90\x81\x85\x01\x90\x86\x84\x01\x85[\x82\x81\x10\x15b\0\n\x9AW\x81Q\x80Q\x85R\x86\x81\x01Q`\x01`\x01`\xA0\x1B\x03\x16\x87\x86\x01R\x85\x81\x01Q\x80Q`\x01`\x01``\x1B\x03\x16\x87\x87\x01R\x87\x81\x01Q``b\0\t\x19\x81\x89\x01\x83`\x01`\x01`\xA0\x1B\x03\x16\x90RV[\x88\x83\x01Q\x91P`\x80b\0\t6\x81\x8A\x01\x84`\x01`\x01`\xA0\x1B\x03\x16\x90RV[\x81\x84\x01Q\x92P`\xA0b\0\tS\x81\x8B\x01\x85`\x01`\x01`\xA0\x1B\x03\x16\x90RV[\x81\x85\x01Q\x93P`\xC0b\0\tl\x81\x8C\x01\x86b\xFF\xFF\xFF\x16\x90RV[\x81\x86\x01Q\x94P`\xE0b\0\t\x83\x81\x8D\x01\x87`\x02\x0B\x90RV[\x81\x87\x01Q\x95Pa\x01\0b\0\t\x9B\x81\x8E\x01\x88`\x02\x0B\x90RV[\x90\x87\x01Q\x95Pa\x01 \x90b\0\t\xBA\x8D\x83\x01\x88`\x01`\x01`\x80\x1B\x03\x16\x90RV[\x87\x01Qa\x01@\x8D\x81\x01\x91\x90\x91R\x90\x87\x01Qa\x01`\x80\x8E\x01\x91\x90\x91R\x90\x87\x01Q`\x01`\x01`\x80\x1B\x03\x90\x81\x16a\x01\x80\x8E\x01R\x96\x01Q\x86\x16a\x01\xA0\x8C\x01R\x92\x86\x01Q\x80Q`\x01`\x01`\xA0\x1B\x03\x16a\x01\xC0\x8C\x01R` \x81\x01Q`\x02\x0Ba\x01\xE0\x8C\x01R`@\x81\x01Qa\xFF\xFF\x90\x81\x16a\x02\0\x8D\x01R``\x82\x01Q\x81\x16a\x02 \x8D\x01R`\x80\x82\x01Q\x16a\x02@\x8C\x01R`\xA0\x81\x01Q`\xFF\x90\x81\x16a\x02`\x8D\x01R`\xC0\x90\x91\x01Q\x15\x15a\x02\x80\x8C\x01R\x91\x86\x01Q\x90\x94\x16a\x02\xA0\x8A\x01R\x92\x84\x01Q\x83\x16a\x02\xC0\x89\x01R\x92\x90\x92\x01Q\x16a\x02\xE0\x86\x01RPa\x03\0\x90\x93\x01\x92\x90\x85\x01\x90`\x01\x01b\0\x08\xCBV[P\x91\x97\x96PPPPPPPV[cNH{q`\xE0\x1B`\0R`2`\x04R`$`\0\xFD[`\x01`\x01`\x80\x1B\x03\x81\x81\x16\x83\x82\x16\x01\x90\x80\x82\x11\x15b\0\n\xECWcNH{q`\xE0\x1B`\0R`\x11`\x04R`$`\0\xFD[P\x92\x91PPV\xFE"; - /// The bytecode of the contract. - pub static EPHEMERALGETPOSITIONS_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"`\x80`@R`\x046\x10a\0\x1EW`\x005`\xE0\x1C\x80c\xA3?\x97\xFE\x14a\0#W[`\0\x80\xFD[a\x006a\x0016`\x04a\t0V[a\0LV[`@Qa\0C\x91\x90a\n:V[`@Q\x80\x91\x03\x90\xF3[\x80Q``\x90\x80g\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x11\x15a\0jWa\0ja\t\x01V[`@Q\x90\x80\x82R\x80` \x02` \x01\x82\x01`@R\x80\x15a\x01jW\x81` \x01[a\x01W`@\x80Q`\xE0\x80\x82\x01\x83R`\0\x80\x83R` \x80\x84\x01\x82\x90R\x84Qa\x01\x80\x81\x01\x86R\x82\x81R\x90\x81\x01\x82\x90R\x80\x85\x01\x82\x90R``\x81\x01\x82\x90R`\x80\x81\x01\x82\x90R`\xA0\x81\x01\x82\x90R`\xC0\x81\x01\x82\x90R\x91\x82\x01\x81\x90Ra\x01\0\x82\x01\x81\x90Ra\x01 \x82\x01\x81\x90Ra\x01@\x82\x01\x81\x90Ra\x01`\x82\x01R\x90\x91\x82\x01\x90\x81R`@\x80Q`\xE0\x81\x01\x82R`\0\x80\x82R` \x82\x81\x01\x82\x90R\x92\x82\x01\x81\x90R``\x82\x01\x81\x90R`\x80\x82\x01\x81\x90R`\xA0\x82\x01\x81\x90R`\xC0\x82\x01R\x91\x01\x90\x81R`\0` \x82\x01\x81\x90R`@\x82\x01\x81\x90R``\x90\x91\x01R\x90V[\x81R` \x01\x90`\x01\x90\x03\x90\x81a\0\x88W\x90P[P\x91P`\0\x80[\x82\x81\x10\x15a\x02\tW`\0\x85\x82\x81Q\x81\x10a\x01\x8DWa\x01\x8Da\x0C\x82V[` \x02` \x01\x01Q\x90P`\0\x85\x84\x81Q\x81\x10a\x01\xABWa\x01\xABa\x0C\x82V[` \x02` \x01\x01Q\x90Pa\x01\xC4\x88\x83\x83`@\x01Qa\x02\x13V[\x15a\x01\xFFW\x83`\x01\x01\x93Pa\x01\xD9\x88\x83a\x02RV[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16` \x82\x01Ra\x01\xFF\x88\x83\x83a\x02\x88V[PP`\x01\x01a\x01qV[P\x82RP\x92\x91PPV[\x7F\x99\xFB\xAB\x88\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`\0\x81\x81R`\x04\x84\x90R\x90a\x01\x80\x83`$\x84\x88Z\xFA\x95\x94PPPPPV[`\0\x80a\x02\x80\x84\x7FcR!\x1E\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\x85a\x04\x87V[\x94\x93PPPPV[\x81\x81R`@\x81\x01Q`\0a\x03&a\x02\x9E\x86a\x04\xB5V[\x83`@\x01Q\x84``\x01Q\x85`\x80\x01Q`@\x80Q`\0\x94\x85R` \x93\x84R\x91\x81R``\x84 t\xFF\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x95\x90\x95\x17\x90\x93R\x92\x90R\x7F\xE3O\x19\x9B\x19\xB2\xB4\xF4\x7FhD&\x19\xD5UR}$Ox\xA3)~\xA8\x93%\xF8C\xF8{\x8BT\x81R`U`\x0B \x91\x90Rs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x90V[\x90Pa\x03G\x81s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x04\xE9V[o\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16`\x80\x84\x01R``\x83\x01Qa\x03n\x90\x82\x90a\x05\x16V[`\xE0\x82\x01Qo\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x15a\x04&W`\0\x80a\x03\xA9\x83\x85`\xA0\x01Q\x86`\xC0\x01Q\x88``\x01Q` \x01Qa\x05UV[\x91P\x91P`\0\x80a\x03\xCB\x86`\xE0\x01Q\x85\x85\x89a\x01\0\x01Q\x8Aa\x01 \x01Qa\x06^V[\x91P\x91P\x81\x86a\x01@\x01\x81\x81Qa\x03\xE2\x91\x90a\x0C\xB1V[o\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x90RPa\x01`\x86\x01\x80Q\x82\x91\x90a\x04\x0C\x90\x83\x90a\x0C\xB1V[o\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x90RPPPPP[a\x04I\x82`@\x01Qs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x06\xCFV[`\xFF\x16`\xA0\x84\x01R``\x82\x01Qa\x04u\x90s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x06\xCFV[`\xFF\x16`\xC0\x90\x93\x01\x92\x90\x92RPPPPV[`\0\x82`\0R\x81`\x04R` `\0`$`\0\x87Z\xFAa\x04\xAAW=`\0\x80>=`\0\xFD[PP`\0Q\x92\x91PPV[`\0\x80a\x04\xE2\x83\x7F\xC4Z\x01U\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\0a\x07\x0EV[\x93\x92PPPV[`\0\x80a\x04\xE2\x83\x7F\x1Ahe\x02\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\0a\x07\x0EV[\x7F8P\xC7\xBD\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`\0\x81\x81R`\xE0\x90\x83\x90`\x04\x90\x86Z\xFAa\x05PW`\0\x80\xFD[PPPV[`\0\x80\x80a\x05ys\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x88\x16\x87a\x072V[\x90P`\0a\x05\x9Ds\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x89\x16\x87a\x072V[\x90P\x86`\x02\x0B\x85`\x02\x0B\x12\x15a\x05\xCCW\x80`@\x01Q\x82`@\x01Q\x03\x93P\x80``\x01Q\x82``\x01Q\x03\x92Pa\x06SV[\x85`\x02\x0B\x85`\x02\x0B\x12a\x05\xF8W\x81`@\x01Q\x81`@\x01Q\x03\x93P\x81``\x01Q\x81``\x01Q\x03\x92Pa\x06SV[\x80`@\x01Q\x82`@\x01Qa\x06!\x8As\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x07\xB0V[\x03\x03\x93P\x80``\x01Q\x82``\x01Qa\x06N\x8As\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x07\xE2V[\x03\x03\x92P[PP\x94P\x94\x92PPPV[`\0\x80a\x06\x91o\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x88\x16\x85\x88\x03p\x01\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0a\x08\x0EV[\x91Pa\x06\xC3o\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x88\x16\x84\x87\x03p\x01\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0a\x08\x0EV[\x90P\x95P\x95\x93PPPPV[`\x12`\0\x90\x81R\x7F1<\xE5g\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` \x81\x81R\x80`\x04\x81\x86Z\xFA`\x05\x1BQ\x93\x92PPPV[`\0\x81`\0R` `\0`\x04`\0\x86Z\xFAa\x07(W`\0\x80\xFD[PP`\0Q\x91\x90PV[`@\x80Qa\x01\0\x81\x01\x82R`\0\x80\x82R` \x82\x01\x81\x90R\x91\x81\x01\x82\x90R``\x81\x01\x82\x90R`\x80\x81\x01\x82\x90R`\xA0\x81\x01\x82\x90R`\xC0\x81\x01\x82\x90R`\xE0\x81\x01\x91\x90\x91R`\x02\x82\x90\x0B\x81a\x07\xA8\x85\x7F\xF3\r\xBA\x93\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\x84\x84a\x01\0a\x08\x1BV[PP\x92\x91PPV[`\0a\x07\xDC\x82\x7F\xF3\x05\x83\x99\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\0a\x07\x0EV[\x92\x91PPV[`\0a\x07\xDC\x82\x7FF\x14\x13\x19\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\0a\x07\x0EV[`\0a\x02\x80\x84\x84\x84a\x08(::ethers::contract::Contract); - impl ::core::clone::Clone for EphemeralGetPositions { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for EphemeralGetPositions { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for EphemeralGetPositions { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for EphemeralGetPositions { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(EphemeralGetPositions)) - .field(&self.address()) - .finish() - } - } - impl EphemeralGetPositions { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - EPHEMERALGETPOSITIONS_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - EPHEMERALGETPOSITIONS_ABI.clone(), - EPHEMERALGETPOSITIONS_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - ///Calls the contract's `getPositions` (0xa33f97fe) function - pub fn get_positions( - &self, - npm: ::ethers::core::types::Address, - token_ids: ::std::vec::Vec<::ethers::core::types::U256>, - ) -> ::ethers::contract::builders::ContractCall> { - self.0 - .method_hash([163, 63, 151, 254], (npm, token_ids)) - .expect("method not found (this should never happen)") - } - } - impl From<::ethers::contract::Contract> for EphemeralGetPositions { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Container type for all input parameters for the `getPositions` function with signature `getPositions(address,uint256[])` and selector `0xa33f97fe` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "getPositions", abi = "getPositions(address,uint256[])")] - pub struct GetPositionsCall { - pub npm: ::ethers::core::types::Address, - pub token_ids: ::std::vec::Vec<::ethers::core::types::U256>, - } - ///Container type for all return fields from the `getPositions` function with signature `getPositions(address,uint256[])` and selector `0xa33f97fe` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct GetPositionsReturn { - pub positions: ::std::vec::Vec, - } -} diff --git a/src/bindings/ephemeral_pool_positions.rs b/src/bindings/ephemeral_pool_positions.rs deleted file mode 100644 index d0abd66..0000000 --- a/src/bindings/ephemeral_pool_positions.rs +++ /dev/null @@ -1,241 +0,0 @@ -pub use ephemeral_pool_positions::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod ephemeral_pool_positions { - pub use super::super::shared_types::*; - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::Some(::ethers::core::abi::ethabi::Constructor { - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("pool"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("V3PoolCallee"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("keys"), - kind: ::ethers::core::abi::ethabi::ParamType::Array(::std::boxed::Box::new( - ::ethers::core::abi::ethabi::ParamType::Tuple(::std::vec![ - ::ethers::core::abi::ethabi::ParamType::Address, - ::ethers::core::abi::ethabi::ParamType::Int(24usize), - ::ethers::core::abi::ethabi::ParamType::Int(24usize), - ],), - ),), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "struct PoolUtils.PositionKey[]", - ),), - }, - ], - }), - functions: ::core::convert::From::from([( - ::std::borrow::ToOwned::to_owned("getPositions"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("getPositions"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("pool"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "V3PoolCallee" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("keys"), - kind: ::ethers::core::abi::ethabi::ParamType::Array(::std::boxed::Box::new( - ::ethers::core::abi::ethabi::ParamType::Tuple(::std::vec![ - ::ethers::core::abi::ethabi::ParamType::Address, - ::ethers::core::abi::ethabi::ParamType::Int(24usize), - ::ethers::core::abi::ethabi::ParamType::Int(24usize), - ],), - ),), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "struct PoolUtils.PositionKey[]", - ),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("slots"), - kind: ::ethers::core::abi::ethabi::ParamType::Array(::std::boxed::Box::new( - ::ethers::core::abi::ethabi::ParamType::Tuple(::std::vec![ - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ],), - ),), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "struct PoolUtils.Slot[]" - ),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Payable, - },], - )]), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static EPHEMERALPOOLPOSITIONS_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`\x80`@R`@Qb\0\x05\x1B8\x03\x80b\0\x05\x1B\x839\x81\x01`@\x81\x90Rb\0\0&\x91b\0\x03\x9CV[`\0b\0\x004\x83\x83b\0\0dV[\x90P`\0\x81`@Q` \x01b\0\0K\x91\x90b\0\x04\xB3V[`@Q` \x81\x83\x03\x03\x81R\x90`@R\x90P\x80Q` \x82\x01\xFD[\x80Q``\x90`\x02\x81\x90\x1B`\x01`\x01`@\x1B\x03\x81\x11\x15b\0\0\x88Wb\0\0\x88b\0\x03\x10V[`@Q\x90\x80\x82R\x80` \x02` \x01\x82\x01`@R\x80\x15b\0\0\xCFW\x81` \x01[`@\x80Q\x80\x82\x01\x90\x91R`\0\x80\x82R` \x82\x01R\x81R` \x01\x90`\x01\x90\x03\x90\x81b\0\0\xA7W\x90P[P\x91P`\0\x80[\x82\x81\x10\x15b\0\x02fW`\0b\0\x01\x0E\x86\x83\x81Q\x81\x10b\0\0\xFAWb\0\0\xFAb\0\x05\x04V[` \x02` \x01\x01Qb\0\x02o` \x1B` \x1CV[`\0\x81\x81R`\x07` R`@\x81 \x91\x92Pb\0\x014`\x01`\x01`\xA0\x1B\x03\x8A\x16\x84b\0\x02\x8BV[`@\x80Q\x80\x82\x01\x90\x91R\x83\x81R\x81Q`\x01`\x01`\x80\x1B\x03\x16` \x82\x01R\x88Q`\x01\x88\x81\x01\x98\x95\x01\x94\x92\x93P\x90\x91\x89\x91\x81\x10b\0\x01tWb\0\x01tb\0\x05\x04V[` \x02` \x01\x01\x81\x90RP`@Q\x80`@\x01`@R\x80\x83\x80`\x01\x01\x94P\x81R` \x01\x82` \x01Q\x81RP\x87\x86\x80`\x01\x01\x97P\x81Q\x81\x10b\0\x01\xB9Wb\0\x01\xB9b\0\x05\x04V[` \x02` \x01\x01\x81\x90RP`@Q\x80`@\x01`@R\x80\x83\x80`\x01\x01\x94P\x81R` \x01\x82`@\x01Q\x81RP\x87\x86\x80`\x01\x01\x97P\x81Q\x81\x10b\0\x01\xFEWb\0\x01\xFEb\0\x05\x04V[` \x02` \x01\x01\x81\x90RP`\0``\x82\x01Q`\x80\x83\x01Q`\x80\x1B\x17\x90P`@Q\x80`@\x01`@R\x80\x84\x81R` \x01\x82\x81RP\x88\x87\x80`\x01\x01\x98P\x81Q\x81\x10b\0\x02KWb\0\x02Kb\0\x05\x04V[` \x02` \x01\x01\x81\x90RPPPPP\x80`\x01\x01\x90Pb\0\0\xD6V[PPP\x92\x91PPV[`@\x81\x01Q`\x06R` \x81\x01Q`\x03RQ`\0R`\x1A`\x0C \x90V[`@\x80Q`\xA0\x81\x01\x82R`\0\x80\x82R` \x82\x01\x81\x90R\x91\x81\x01\x82\x90R``\x81\x01\x82\x90R`\x80\x81\x01\x91\x90\x91R\x80b\0\x02\xCE\x84cQN\xA4\xBF`\xE0\x1B\x85\x84`\xA0b\0\x02\xD5V[P\x92\x91PPV[\x83`\0R\x82`\x04R\x80\x82`$`\0\x88Z\xFAb\0\x02\xF0W`\0\x80\xFD[PPPPPV[`\x01`\x01`\xA0\x1B\x03\x81\x16\x81\x14b\0\x03\rW`\0\x80\xFD[PV[cNH{q`\xE0\x1B`\0R`A`\x04R`$`\0\xFD[`@Q``\x81\x01`\x01`\x01`@\x1B\x03\x81\x11\x82\x82\x10\x17\x15b\0\x03KWb\0\x03Kb\0\x03\x10V[`@R\x90V[`@Q`\x1F\x82\x01`\x1F\x19\x16\x81\x01`\x01`\x01`@\x1B\x03\x81\x11\x82\x82\x10\x17\x15b\0\x03|Wb\0\x03|b\0\x03\x10V[`@R\x91\x90PV[\x80Q`\x02\x81\x90\x0B\x81\x14b\0\x03\x97W`\0\x80\xFD[\x91\x90PV[`\0\x80`@\x80\x84\x86\x03\x12\x15b\0\x03\xB1W`\0\x80\xFD[\x83Qb\0\x03\xBE\x81b\0\x02\xF7V[` \x85\x81\x01Q\x91\x94P\x90`\x01`\x01`@\x1B\x03\x80\x82\x11\x15b\0\x03\xDEW`\0\x80\xFD[\x81\x87\x01\x91P\x87`\x1F\x83\x01\x12b\0\x03\xF3W`\0\x80\xFD[\x81Q\x81\x81\x11\x15b\0\x04\x08Wb\0\x04\x08b\0\x03\x10V[b\0\x04\x18\x84\x82`\x05\x1B\x01b\0\x03QV[\x81\x81R\x84\x81\x01\x92P``\x91\x82\x02\x84\x01\x85\x01\x91\x8A\x83\x11\x15b\0\x048W`\0\x80\xFD[\x93\x85\x01\x93[\x82\x85\x10\x15b\0\x04\xA2W\x80\x85\x8C\x03\x12\x15b\0\x04WW`\0\x80\x81\xFD[b\0\x04ab\0\x03&V[\x85Qb\0\x04n\x81b\0\x02\xF7V[\x81Rb\0\x04}\x86\x88\x01b\0\x03\x84V[\x87\x82\x01Rb\0\x04\x8E\x88\x87\x01b\0\x03\x84V[\x81\x89\x01R\x84R\x93\x84\x01\x93\x92\x85\x01\x92b\0\x04=V[P\x80\x96PPPPPPP\x92P\x92\x90PV[` \x80\x82R\x82Q\x82\x82\x01\x81\x90R`\0\x91\x90`@\x90\x81\x85\x01\x90\x86\x84\x01\x85[\x82\x81\x10\x15b\0\x04\xF7W\x81Q\x80Q\x85R\x86\x01Q\x86\x85\x01R\x92\x84\x01\x92\x90\x85\x01\x90`\x01\x01b\0\x04\xD0V[P\x91\x97\x96PPPPPPPV[cNH{q`\xE0\x1B`\0R`2`\x04R`$`\0\xFD\xFE"; - /// The bytecode of the contract. - pub static EPHEMERALPOOLPOSITIONS_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"`\x80`@R`\x046\x10a\0\x1EW`\x005`\xE0\x1C\x80c\xC2A\xE2z\x14a\0#W[`\0\x80\xFD[a\x006a\x0016`\x04a\x03\xCAV[a\0LV[`@Qa\0C\x91\x90a\x04\xCAV[`@Q\x80\x91\x03\x90\xF3[\x80Q``\x90`\x02\x81\x90\x1Bg\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x11\x15a\0nWa\0na\x03\x0CV[`@Q\x90\x80\x82R\x80` \x02` \x01\x82\x01`@R\x80\x15a\0\xB3W\x81` \x01[`@\x80Q\x80\x82\x01\x90\x91R`\0\x80\x82R` \x82\x01R\x81R` \x01\x90`\x01\x90\x03\x90\x81a\0\x8CW\x90P[P\x91P`\0\x80[\x82\x81\x10\x15a\x02\\W`\0a\0\xFD\x86\x83\x81Q\x81\x10a\0\xD9Wa\0\xD9a\x05\x19V[` \x02` \x01\x01Q`@\x81\x01Q`\x06R` \x81\x01Q`\x03RQ`\0R`\x1A`\x0C \x90V[`\0\x81\x81R`\x07` R`@\x81 \x91\x92Pa\x01.s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x8A\x16\x84a\x02eV[`@\x80Q\x80\x82\x01\x90\x91R\x83\x81R\x81Qo\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16` \x82\x01R\x88Q`\x01\x88\x81\x01\x98\x95\x01\x94\x92\x93P\x90\x91\x89\x91\x81\x10a\x01tWa\x01ta\x05\x19V[` \x02` \x01\x01\x81\x90RP`@Q\x80`@\x01`@R\x80\x83\x80`\x01\x01\x94P\x81R` \x01\x82` \x01Q\x81RP\x87\x86\x80`\x01\x01\x97P\x81Q\x81\x10a\x01\xB6Wa\x01\xB6a\x05\x19V[` \x02` \x01\x01\x81\x90RP`@Q\x80`@\x01`@R\x80\x83\x80`\x01\x01\x94P\x81R` \x01\x82`@\x01Q\x81RP\x87\x86\x80`\x01\x01\x97P\x81Q\x81\x10a\x01\xF8Wa\x01\xF8a\x05\x19V[` \x02` \x01\x01\x81\x90RP`\0``\x82\x01Q`\x80\x83\x01Q`\x80\x1B\x17\x90P`@Q\x80`@\x01`@R\x80\x84\x81R` \x01\x82\x81RP\x88\x87\x80`\x01\x01\x98P\x81Q\x81\x10a\x02BWa\x02Ba\x05\x19V[` \x02` \x01\x01\x81\x90RPPPPP\x80`\x01\x01\x90Pa\0\xBAV[PPP\x92\x91PPV[`@\x80Q`\xA0\x81\x01\x82R`\0\x80\x82R` \x82\x01\x81\x90R\x91\x81\x01\x82\x90R``\x81\x01\x82\x90R`\x80\x81\x01\x91\x90\x91R\x80a\x02\xBF\x84\x7FQN\xA4\xBF\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\x85\x84`\xA0a\x02\xC6V[P\x92\x91PPV[\x83`\0R\x82`\x04R\x80\x82`$`\0\x88Z\xFAa\x02\xE0W`\0\x80\xFD[PPPPPV[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x16\x81\x14a\x03\tW`\0\x80\xFD[PV[\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`\0R`A`\x04R`$`\0\xFD[`@Q``\x81\x01g\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x11\x82\x82\x10\x17\x15a\x03^Wa\x03^a\x03\x0CV[`@R\x90V[`@Q`\x1F\x82\x01\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xE0\x16\x81\x01g\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x11\x82\x82\x10\x17\x15a\x03\xABWa\x03\xABa\x03\x0CV[`@R\x91\x90PV[\x805`\x02\x81\x90\x0B\x81\x14a\x03\xC5W`\0\x80\xFD[\x91\x90PV[`\0\x80`@\x80\x84\x86\x03\x12\x15a\x03\xDEW`\0\x80\xFD[\x835a\x03\xE9\x81a\x02\xE7V[\x92P` \x84\x81\x015g\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x82\x11\x15a\x04\x07W`\0\x80\xFD[\x81\x87\x01\x91P\x87`\x1F\x83\x01\x12a\x04\x1BW`\0\x80\xFD[\x815\x81\x81\x11\x15a\x04-Wa\x04-a\x03\x0CV[a\x04;\x84\x82`\x05\x1B\x01a\x03dV[\x81\x81R\x84\x81\x01\x92P``\x91\x82\x02\x84\x01\x85\x01\x91\x8A\x83\x11\x15a\x04ZW`\0\x80\xFD[\x93\x85\x01\x93[\x82\x85\x10\x15a\x04\xB9W\x80\x85\x8C\x03\x12\x15a\x04wW`\0\x80\x81\xFD[a\x04\x7Fa\x03;V[\x855a\x04\x8A\x81a\x02\xE7V[\x81Ra\x04\x97\x86\x88\x01a\x03\xB3V[\x87\x82\x01Ra\x04\xA6\x88\x87\x01a\x03\xB3V[\x81\x89\x01R\x84R\x93\x84\x01\x93\x92\x85\x01\x92a\x04_V[P\x80\x96PPPPPPP\x92P\x92\x90PV[` \x80\x82R\x82Q\x82\x82\x01\x81\x90R`\0\x91\x90`@\x90\x81\x85\x01\x90\x86\x84\x01\x85[\x82\x81\x10\x15a\x05\x0CW\x81Q\x80Q\x85R\x86\x01Q\x86\x85\x01R\x92\x84\x01\x92\x90\x85\x01\x90`\x01\x01a\x04\xE7V[P\x91\x97\x96PPPPPPPV[\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`\0R`2`\x04R`$`\0\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static EPHEMERALPOOLPOSITIONS_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct EphemeralPoolPositions(::ethers::contract::Contract); - impl ::core::clone::Clone for EphemeralPoolPositions { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for EphemeralPoolPositions { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for EphemeralPoolPositions { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for EphemeralPoolPositions { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(EphemeralPoolPositions)) - .field(&self.address()) - .finish() - } - } - impl EphemeralPoolPositions { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - EPHEMERALPOOLPOSITIONS_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - EPHEMERALPOOLPOSITIONS_ABI.clone(), - EPHEMERALPOOLPOSITIONS_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - ///Calls the contract's `getPositions` (0xc241e27a) function - pub fn get_positions( - &self, - pool: ::ethers::core::types::Address, - keys: ::std::vec::Vec, - ) -> ::ethers::contract::builders::ContractCall> { - self.0 - .method_hash([194, 65, 226, 122], (pool, keys)) - .expect("method not found (this should never happen)") - } - } - impl From<::ethers::contract::Contract> for EphemeralPoolPositions { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Container type for all input parameters for the `getPositions` function with signature `getPositions(address,(address,int24,int24)[])` and selector `0xc241e27a` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "getPositions", abi = "getPositions(address,(address,int24,int24)[])")] - pub struct GetPositionsCall { - pub pool: ::ethers::core::types::Address, - pub keys: ::std::vec::Vec, - } - ///Container type for all return fields from the `getPositions` function with signature `getPositions(address,(address,int24,int24)[])` and selector `0xc241e27a` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct GetPositionsReturn { - pub slots: ::std::vec::Vec, - } - ///`PositionKey(address,int24,int24)` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct PositionKey { - pub owner: ::ethers::core::types::Address, - pub tick_lower: i32, - pub tick_upper: i32, - } -} diff --git a/src/bindings/ephemeral_pool_slots.rs b/src/bindings/ephemeral_pool_slots.rs deleted file mode 100644 index b09916e..0000000 --- a/src/bindings/ephemeral_pool_slots.rs +++ /dev/null @@ -1,189 +0,0 @@ -pub use ephemeral_pool_slots::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod ephemeral_pool_slots { - pub use super::super::shared_types::*; - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::Some(::ethers::core::abi::ethabi::Constructor { - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("pool"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("V3PoolCallee"),), - },], - }), - functions: ::core::convert::From::from([( - ::std::borrow::ToOwned::to_owned("getSlots"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("getSlots"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("pool"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("V3PoolCallee"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("slots"), - kind: ::ethers::core::abi::ethabi::ParamType::Array(::std::boxed::Box::new( - ::ethers::core::abi::ethabi::ParamType::Tuple(::std::vec![ - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ],), - ),), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "struct PoolUtils.Slot[]" - ),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Payable, - },], - )]), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static EPHEMERALPOOLSLOTS_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`\x80`@R`@Qb\0\x05\xA98\x03\x80b\0\x05\xA9\x839\x81\x01`@\x81\x90Rb\0\0&\x91b\0\x05\0V[`\0b\0\x003\x82b\0\0cV[\x90P`\0\x81`@Q` \x01b\0\0J\x91\x90b\0\x05+V[`@Q` \x81\x83\x03\x03\x81R\x90`@R\x90P\x80Q` \x82\x01\xFD[```\0\x80\x80\x80\x80\x80\x80\x80b\0\0\x82`\x01`\x01`\xA0\x1B\x03\x8B\x16b\0\x03mV[a\xFF\xFF\x84\x16\x9EP\x95\x9CP\x93\x9AP\x91\x98P\x96P\x94P\x92P\x90Pb\xFF\xFF\xFF`\xA0\x1B`\xA0\x87\x90\x1B\x16`\xB8\x86\x90\x1B`\xC8\x86\x90\x1B`\xD8\x86\x90\x1B`\xE8\x86\x90\x1B`\xF0\x86\x90\x1B\x17\x17\x17\x17\x17\x87\x17`\x05\x89\x01`\x01`\x01`@\x1B\x03\x81\x11\x15b\0\0\xE5Wb\0\0\xE5b\0\x05|V[`@Q\x90\x80\x82R\x80` \x02` \x01\x82\x01`@R\x80\x15b\0\x01,W\x81` \x01[`@\x80Q\x80\x82\x01\x90\x91R`\0\x80\x82R` \x82\x01R\x81R` \x01\x90`\x01\x90\x03\x90\x81b\0\x01\x04W\x90P[P\x99P`@Q\x80`@\x01`@R\x80`\0\x81R` \x01\x82\x81RP\x8A`\0\x81Q\x81\x10b\0\x01[Wb\0\x01[b\0\x05\x92V[` \x02` \x01\x01\x81\x90RPPPPPPPPP`@Q\x80`@\x01`@R\x80`\x01\x81R` \x01b\0\x01\x9A\x85`\x01`\x01`\xA0\x1B\x03\x16b\0\x03\xD6` \x1B` \x1CV[\x81RP\x82`\x01\x81Q\x81\x10b\0\x01\xB3Wb\0\x01\xB3b\0\x05\x92V[` \x02` \x01\x01\x81\x90RP`@Q\x80`@\x01`@R\x80`\x02\x81R` \x01b\0\x01\xEA\x85`\x01`\x01`\xA0\x1B\x03\x16b\0\x03\xF1` \x1B` \x1CV[\x81RP\x82`\x02\x81Q\x81\x10b\0\x02\x03Wb\0\x02\x03b\0\x05\x92V[` \x90\x81\x02\x91\x90\x91\x01\x01R`\0\x80b\0\x02%`\x01`\x01`\xA0\x1B\x03\x86\x16b\0\x04\x06V[\x91P\x91P`\0\x82\x82`\x80\x1B\x17\x90P`@Q\x80`@\x01`@R\x80`\x03\x81R` \x01\x82\x81RP\x85`\x03\x81Q\x81\x10b\0\x02_Wb\0\x02_b\0\x05\x92V[` \x02` \x01\x01\x81\x90RPPPP`@Q\x80`@\x01`@R\x80`\x04\x81R` \x01b\0\x02\x99\x85`\x01`\x01`\xA0\x1B\x03\x16b\0\x04*` \x1B` \x1CV[`\x01`\x01`\x80\x1B\x03\x16\x81RP\x82`\x04\x81Q\x81\x10b\0\x02\xBBWb\0\x02\xBBb\0\x05\x92V[` \x02` \x01\x01\x81\x90RP`\0[\x81\x81\x10\x15b\0\x03fW`\0\x80\x80\x80b\0\x02\xEC`\x01`\x01`\xA0\x1B\x03\x89\x16\x86b\0\x04GV[\x93P\x93P\x93P\x93P`\0\x81`\xF8\x1B\x90P\x80\x83`X\x1B\x17\x90P\x80\x84f\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16` \x1B\x17\x90P\x80\x85\x17\x90P`@Q\x80`@\x01`@R\x80`\x08\x88\x01\x81R` \x01\x82\x81RP\x88\x87`\x05\x01\x81Q\x81\x10b\0\x03JWb\0\x03Jb\0\x05\x92V[` \x02` \x01\x01\x81\x90RPPPPPP\x80`\x01\x01\x90Pb\0\x02\xC9V[PP\x91\x90PV[`\0\x80`\0\x80`\0\x80`\0\x80c8P\xC7\xBD`\xE0\x1B\x90P`@Q\x81`\0R`\xE0\x81`\x04`\0\x8DZ\xFAb\0\x03\x9EW`\0\x80\xFD[\x80Q` \x82\x01Q`@\x83\x01Q``\x84\x01Q`\x80\x85\x01Q`\xA0\x86\x01Q`\xC0\x90\x96\x01Q\x94\x9F\x93\x9EP\x91\x9CP\x9AP\x98P\x91\x96P\x94P\x92PPPV[`\0b\0\x03\xEB\x82c\xF3\x05\x83\x99`\xE0\x1Bb\0\x04\x8CV[\x92\x91PPV[`\0b\0\x03\xEB\x82cF\x14\x13\x19`\xE0\x1Bb\0\x04\x8CV[`\0\x80\x80\x80b\0\x04\x1E\x85c\x1A\xD8\xB0;`\xE0\x1Bb\0\x04\xB1V[\x90\x96\x90\x95P\x93PPPPV[`\0\x80b\0\x04@\x83c\r42\x81`\xE1\x1Bb\0\x04\x8CV[\x93\x92PPPV[`@Q`\0\x90\x81\x90\x81\x90\x81\x90b\0\x04j\x87c%,\t\xD7`\xE0\x1B\x88\x84`\x80b\0\x04\xDEV[\x80Q` \x82\x01Q`@\x83\x01Q``\x90\x93\x01Q\x91\x99\x90\x98P\x91\x96P\x94P\x92PPPV[`\0\x81`\0R` `\0`\x04`\0\x86Z\xFAb\0\x04\xA7W`\0\x80\xFD[PP`\0Q\x91\x90PV[`\0\x80\x82`\0R`@`\0`\x04`\0\x87Z\xFAb\0\x04\xCDW`\0\x80\xFD[`\0Q\x91P` Q\x90P\x92P\x92\x90PV[\x83`\0R\x82`\x04R\x80\x82`$`\0\x88Z\xFAb\0\x04\xF9W`\0\x80\xFD[PPPPPV[`\0` \x82\x84\x03\x12\x15b\0\x05\x13W`\0\x80\xFD[\x81Q`\x01`\x01`\xA0\x1B\x03\x81\x16\x81\x14b\0\x04@W`\0\x80\xFD[` \x80\x82R\x82Q\x82\x82\x01\x81\x90R`\0\x91\x90`@\x90\x81\x85\x01\x90\x86\x84\x01\x85[\x82\x81\x10\x15b\0\x05oW\x81Q\x80Q\x85R\x86\x01Q\x86\x85\x01R\x92\x84\x01\x92\x90\x85\x01\x90`\x01\x01b\0\x05HV[P\x91\x97\x96PPPPPPPV[cNH{q`\xE0\x1B`\0R`A`\x04R`$`\0\xFD[cNH{q`\xE0\x1B`\0R`2`\x04R`$`\0\xFD\xFE"; - /// The bytecode of the contract. - pub static EPHEMERALPOOLSLOTS_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"`\x80`@R`\x046\x10a\0\x1EW`\x005`\xE0\x1C\x80c\x1D6\xF0\xF0\x14a\0#W[`\0\x80\xFD[a\x006a\x0016`\x04a\x05\x8DV[a\0LV[`@Qa\0C\x91\x90a\x05\xC3V[`@Q\x80\x91\x03\x90\xF3[```\0\x80`\0\x80`\0\x80`\0\x80a\0y\x8As\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x03\x8BV[a\xFF\xFF\x84\x16\x9EP\x95\x9CP\x93\x9AP\x91\x98P\x96P\x94P\x92P\x90Pv\xFF\xFF\xFF\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0`\xA0\x87\x90\x1B\x16`\xB8\x86\x90\x1B`\xC8\x86\x90\x1B`\xD8\x86\x90\x1B`\xE8\x86\x90\x1B`\xF0\x86\x90\x1B\x17\x17\x17\x17\x17\x87\x17`\x05\x89\x01g\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x11\x15a\0\xEBWa\0\xEBa\x06\x12V[`@Q\x90\x80\x82R\x80` \x02` \x01\x82\x01`@R\x80\x15a\x010W\x81` \x01[`@\x80Q\x80\x82\x01\x90\x91R`\0\x80\x82R` \x82\x01R\x81R` \x01\x90`\x01\x90\x03\x90\x81a\x01\tW\x90P[P\x99P`@Q\x80`@\x01`@R\x80`\0\x81R` \x01\x82\x81RP\x8A`\0\x81Q\x81\x10a\x01\\Wa\x01\\a\x06AV[` \x02` \x01\x01\x81\x90RPPPPPPPPP`@Q\x80`@\x01`@R\x80`\x01\x81R` \x01a\x01\xA0\x85s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x03\xF3V[\x81RP\x82`\x01\x81Q\x81\x10a\x01\xB6Wa\x01\xB6a\x06AV[` \x02` \x01\x01\x81\x90RP`@Q\x80`@\x01`@R\x80`\x02\x81R` \x01a\x01\xF2\x85s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x04%V[\x81RP\x82`\x02\x81Q\x81\x10a\x02\x08Wa\x02\x08a\x06AV[` \x02` \x01\x01\x81\x90RP`\0\x80a\x025\x85s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x04QV[\x91P\x91P`\0\x82\x82`\x80\x1B\x17\x90P`@Q\x80`@\x01`@R\x80`\x03\x81R` \x01\x82\x81RP\x85`\x03\x81Q\x81\x10a\x02lWa\x02la\x06AV[` \x02` \x01\x01\x81\x90RPPPP`@Q\x80`@\x01`@R\x80`\x04\x81R` \x01a\x02\xAB\x85s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x04\x8CV[o\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x81RP\x82`\x04\x81Q\x81\x10a\x02\xD3Wa\x02\xD3a\x06AV[` \x02` \x01\x01\x81\x90RP`\0[\x81\x81\x10\x15a\x03\x84W`\0\x80\x80\x80a\x03\x0Es\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x89\x16\x86a\x04\xC0V[\x93P\x93P\x93P\x93P`\0\x81`\xF8\x1B\x90P\x80\x83`X\x1B\x17\x90P\x80\x84f\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16` \x1B\x17\x90P\x80\x85\x17\x90P`@Q\x80`@\x01`@R\x80`\x08\x88\x01\x81R` \x01\x82\x81RP\x88\x87`\x05\x01\x81Q\x81\x10a\x03iWa\x03ia\x06AV[` \x02` \x01\x01\x81\x90RPPPPPP\x80`\x01\x01\x90Pa\x02\xE1V[PP\x91\x90PV[`\0\x80`\0\x80`\0\x80`\0\x80c8P\xC7\xBD`\xE0\x1B\x90P`@Q\x81`\0R`\xE0\x81`\x04`\0\x8DZ\xFAa\x03\xBBW`\0\x80\xFD[\x80Q` \x82\x01Q`@\x83\x01Q``\x84\x01Q`\x80\x85\x01Q`\xA0\x86\x01Q`\xC0\x90\x96\x01Q\x94\x9F\x93\x9EP\x91\x9CP\x9AP\x98P\x91\x96P\x94P\x92PPPV[`\0a\x04\x1F\x82\x7F\xF3\x05\x83\x99\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\0a\x05\x1CV[\x92\x91PPV[`\0a\x04\x1F\x82\x7FF\x14\x13\x19\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\0a\x05\x1CV[`\0\x80\x80\x80a\x04\x80\x85\x7F\x1A\xD8\xB0;\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\0a\x05@V[\x90\x96\x90\x95P\x93PPPPV[`\0\x80a\x04\xB9\x83\x7F\x1Ahe\x02\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\0a\x05\x1CV[\x93\x92PPPV[`@Q`\0\x90\x81\x90\x81\x90\x81\x90a\x04\xFA\x87\x7F%,\t\xD7\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\x88\x84`\x80a\x05lV[\x80Q` \x82\x01Q`@\x83\x01Q``\x90\x93\x01Q\x91\x99\x90\x98P\x91\x96P\x94P\x92PPPV[`\0\x81`\0R` `\0`\x04`\0\x86Z\xFAa\x056W`\0\x80\xFD[PP`\0Q\x91\x90PV[`\0\x80\x82`\0R`@`\0`\x04`\0\x87Z\xFAa\x05[W`\0\x80\xFD[`\0Q\x91P` Q\x90P\x92P\x92\x90PV[\x83`\0R\x82`\x04R\x80\x82`$`\0\x88Z\xFAa\x05\x86W`\0\x80\xFD[PPPPPV[`\0` \x82\x84\x03\x12\x15a\x05\x9FW`\0\x80\xFD[\x815s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x16\x81\x14a\x04\xB9W`\0\x80\xFD[` \x80\x82R\x82Q\x82\x82\x01\x81\x90R`\0\x91\x90`@\x90\x81\x85\x01\x90\x86\x84\x01\x85[\x82\x81\x10\x15a\x06\x05W\x81Q\x80Q\x85R\x86\x01Q\x86\x85\x01R\x92\x84\x01\x92\x90\x85\x01\x90`\x01\x01a\x05\xE0V[P\x91\x97\x96PPPPPPPV[\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`\0R`A`\x04R`$`\0\xFD[\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`\0R`2`\x04R`$`\0\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static EPHEMERALPOOLSLOTS_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct EphemeralPoolSlots(::ethers::contract::Contract); - impl ::core::clone::Clone for EphemeralPoolSlots { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for EphemeralPoolSlots { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for EphemeralPoolSlots { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for EphemeralPoolSlots { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(EphemeralPoolSlots)) - .field(&self.address()) - .finish() - } - } - impl EphemeralPoolSlots { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - EPHEMERALPOOLSLOTS_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - EPHEMERALPOOLSLOTS_ABI.clone(), - EPHEMERALPOOLSLOTS_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - ///Calls the contract's `getSlots` (0x1d36f0f0) function - pub fn get_slots( - &self, - pool: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall> { - self.0 - .method_hash([29, 54, 240, 240], pool) - .expect("method not found (this should never happen)") - } - } - impl From<::ethers::contract::Contract> for EphemeralPoolSlots { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Container type for all input parameters for the `getSlots` function with signature `getSlots(address)` and selector `0x1d36f0f0` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "getSlots", abi = "getSlots(address)")] - pub struct GetSlotsCall { - pub pool: ::ethers::core::types::Address, - } - ///Container type for all return fields from the `getSlots` function with signature `getSlots(address)` and selector `0x1d36f0f0` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct GetSlotsReturn { - pub slots: ::std::vec::Vec, - } -} diff --git a/src/bindings/ephemeral_pool_tick_bitmap.rs b/src/bindings/ephemeral_pool_tick_bitmap.rs deleted file mode 100644 index 7d223fc..0000000 --- a/src/bindings/ephemeral_pool_tick_bitmap.rs +++ /dev/null @@ -1,189 +0,0 @@ -pub use ephemeral_pool_tick_bitmap::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod ephemeral_pool_tick_bitmap { - pub use super::super::shared_types::*; - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::Some(::ethers::core::abi::ethabi::Constructor { - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("pool"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("V3PoolCallee"),), - },], - }), - functions: ::core::convert::From::from([( - ::std::borrow::ToOwned::to_owned("getTickBitmap"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("getTickBitmap"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("pool"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("V3PoolCallee"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("slots"), - kind: ::ethers::core::abi::ethabi::ParamType::Array(::std::boxed::Box::new( - ::ethers::core::abi::ethabi::ParamType::Tuple(::std::vec![ - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ],), - ),), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "struct PoolUtils.Slot[]" - ),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Payable, - },], - )]), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static EPHEMERALPOOLTICKBITMAP_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`\x80`@R`@Qa\x02\xF18\x03\x80a\x02\xF1\x839\x81\x01`@\x81\x90Ra\0\"\x91a\x02\"V[`\0a\0-\x82a\0[V[\x90P`\0\x81`@Q` \x01a\0B\x91\x90a\x02RV[`@Q` \x81\x83\x03\x03\x81R\x90`@R\x90P\x80Q` \x82\x01\xFD[```\0\x82`\x01`\x01`\xA0\x1B\x03\x16c\xD0\xC9:|`@Q\x81c\xFF\xFF\xFF\xFF\x16`\xE0\x1B\x81R`\x04\x01` `@Q\x80\x83\x03\x81\x86Z\xFA\x15\x80\x15a\0\x9DW=`\0\x80>=`\0\xFD[PPPP`@Q=`\x1F\x19`\x1F\x82\x01\x16\x82\x01\x80`@RP\x81\x01\x90a\0\xC1\x91\x90a\x02\xA1V[\x90P`\0\x80b\r\x89\xE7\x19\x83\x81\x07\x82\x13\x90\x84\x90\x05\x03`\x02\x90\x81\x0B`\x08\x90\x81\x1D\x91b\r\x89\xE8\x86\x81\x07\x85\x13\x90\x87\x90\x05\x03\x90\x0B\x90\x1D\x91P\x91P\x81\x81\x03`\x01\x01a\xFF\xFF\x16`\x01`\x01`@\x1B\x03\x81\x11\x15a\x01\x17Wa\x01\x17a\x02\xC4V[`@Q\x90\x80\x82R\x80` \x02` \x01\x82\x01`@R\x80\x15a\x01\\W\x81` \x01[`@\x80Q\x80\x82\x01\x90\x91R`\0\x80\x82R` \x82\x01R\x81R` \x01\x90`\x01\x90\x03\x90\x81a\x015W\x90P[P\x93P\x81[\x81`\x01\x0B\x81`\x01\x0B\x13a\x01\xD1W`\0\x81\x81R`\x06` \x90\x81R`@\x91\x82\x90 \x82Q\x80\x84\x01\x90\x93R\x80\x83R\x91\x90\x81\x01a\x01\xA2`\x01`\x01`\xA0\x1B\x03\x8A\x16\x85a\x01\xDAV[\x81RP\x86\x85\x84\x03a\xFF\xFF\x16\x81Q\x81\x10a\x01\xBDWa\x01\xBDa\x02\xDAV[` \x90\x81\x02\x91\x90\x91\x01\x01RP`\x01\x01a\x01aV[PPPP\x91\x90PV[`\0`\x01\x82\x90\x0Ba\x01\xF6\x84c)\x9C\xE1K`\xE1\x1B\x83\x85` a\x02\x01V[PP`\0Q\x92\x91PPV[\x83`\0R\x82`\x04R\x80\x82`$`\0\x88Z\xFAa\x02\x1BW`\0\x80\xFD[PPPPPV[`\0` \x82\x84\x03\x12\x15a\x024W`\0\x80\xFD[\x81Q`\x01`\x01`\xA0\x1B\x03\x81\x16\x81\x14a\x02KW`\0\x80\xFD[\x93\x92PPPV[` \x80\x82R\x82Q\x82\x82\x01\x81\x90R`\0\x91\x90`@\x90\x81\x85\x01\x90\x86\x84\x01\x85[\x82\x81\x10\x15a\x02\x94W\x81Q\x80Q\x85R\x86\x01Q\x86\x85\x01R\x92\x84\x01\x92\x90\x85\x01\x90`\x01\x01a\x02oV[P\x91\x97\x96PPPPPPPV[`\0` \x82\x84\x03\x12\x15a\x02\xB3W`\0\x80\xFD[\x81Q\x80`\x02\x0B\x81\x14a\x02KW`\0\x80\xFD[cNH{q`\xE0\x1B`\0R`A`\x04R`$`\0\xFD[cNH{q`\xE0\x1B`\0R`2`\x04R`$`\0\xFD\xFE"; - /// The bytecode of the contract. - pub static EPHEMERALPOOLTICKBITMAP_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"`\x80`@R`\x046\x10a\0\x1EW`\x005`\xE0\x1C\x80cfk]\xA3\x14a\0#W[`\0\x80\xFD[a\x006a\x0016`\x04a\x02nV[a\0LV[`@Qa\0C\x91\x90a\x02\xABV[`@Q\x80\x91\x03\x90\xF3[```\0\x82s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16c\xD0\xC9:|`@Q\x81c\xFF\xFF\xFF\xFF\x16`\xE0\x1B\x81R`\x04\x01` `@Q\x80\x83\x03\x81\x86Z\xFA\x15\x80\x15a\0\x9BW=`\0\x80>=`\0\xFD[PPPP`@Q=`\x1F\x19`\x1F\x82\x01\x16\x82\x01\x80`@RP\x81\x01\x90a\0\xBF\x91\x90a\x02\xFAV[\x90P`\0\x80\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xF2v\x18\x83\x81\x07\x82\x13\x90\x84\x90\x05\x03`\x02\x90\x81\x0B`\x08\x90\x81\x1D\x91b\r\x89\xE8\x86\x81\x07\x85\x13\x90\x87\x90\x05\x03\x90\x0B\x90\x1D\x91P\x91P\x81\x81\x03`\x01\x01a\xFF\xFF\x16g\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x11\x15a\x012Wa\x012a\x03\x1DV[`@Q\x90\x80\x82R\x80` \x02` \x01\x82\x01`@R\x80\x15a\x01wW\x81` \x01[`@\x80Q\x80\x82\x01\x90\x91R`\0\x80\x82R` \x82\x01R\x81R` \x01\x90`\x01\x90\x03\x90\x81a\x01PW\x90P[P\x93P\x81[\x81`\x01\x0B\x81`\x01\x0B\x13a\x02\x04W`\0\x81`\0R`\x06` R`@`\0 \x90P`@Q\x80`@\x01`@R\x80\x82\x81R` \x01a\x01\xD5\x84\x8As\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x02\r\x90\x91\x90c\xFF\xFF\xFF\xFF\x16V[\x81RP\x86\x85\x84\x03a\xFF\xFF\x16\x81Q\x81\x10a\x01\xF0Wa\x01\xF0a\x03LV[` \x90\x81\x02\x91\x90\x91\x01\x01RP`\x01\x01a\x01|V[PPPP\x91\x90PV[`\0`\x01\x82\x90\x0Ba\x02B\x84\x7FS9\xC2\x96\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\x83\x85` a\x02MV[PP`\0Q\x92\x91PPV[\x83`\0R\x82`\x04R\x80\x82`$`\0\x88Z\xFAa\x02gW`\0\x80\xFD[PPPPPV[`\0` \x82\x84\x03\x12\x15a\x02\x80W`\0\x80\xFD[\x815s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x16\x81\x14a\x02\xA4W`\0\x80\xFD[\x93\x92PPPV[` \x80\x82R\x82Q\x82\x82\x01\x81\x90R`\0\x91\x90`@\x90\x81\x85\x01\x90\x86\x84\x01\x85[\x82\x81\x10\x15a\x02\xEDW\x81Q\x80Q\x85R\x86\x01Q\x86\x85\x01R\x92\x84\x01\x92\x90\x85\x01\x90`\x01\x01a\x02\xC8V[P\x91\x97\x96PPPPPPPV[`\0` \x82\x84\x03\x12\x15a\x03\x0CW`\0\x80\xFD[\x81Q\x80`\x02\x0B\x81\x14a\x02\xA4W`\0\x80\xFD[\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`\0R`A`\x04R`$`\0\xFD[\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`\0R`2`\x04R`$`\0\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static EPHEMERALPOOLTICKBITMAP_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct EphemeralPoolTickBitmap(::ethers::contract::Contract); - impl ::core::clone::Clone for EphemeralPoolTickBitmap { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for EphemeralPoolTickBitmap { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for EphemeralPoolTickBitmap { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for EphemeralPoolTickBitmap { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(EphemeralPoolTickBitmap)) - .field(&self.address()) - .finish() - } - } - impl EphemeralPoolTickBitmap { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - EPHEMERALPOOLTICKBITMAP_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - EPHEMERALPOOLTICKBITMAP_ABI.clone(), - EPHEMERALPOOLTICKBITMAP_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - ///Calls the contract's `getTickBitmap` (0x666b5da3) function - pub fn get_tick_bitmap( - &self, - pool: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall> { - self.0 - .method_hash([102, 107, 93, 163], pool) - .expect("method not found (this should never happen)") - } - } - impl From<::ethers::contract::Contract> for EphemeralPoolTickBitmap { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Container type for all input parameters for the `getTickBitmap` function with signature `getTickBitmap(address)` and selector `0x666b5da3` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "getTickBitmap", abi = "getTickBitmap(address)")] - pub struct GetTickBitmapCall { - pub pool: ::ethers::core::types::Address, - } - ///Container type for all return fields from the `getTickBitmap` function with signature `getTickBitmap(address)` and selector `0x666b5da3` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct GetTickBitmapReturn { - pub slots: ::std::vec::Vec, - } -} diff --git a/src/bindings/ephemeral_pool_ticks.rs b/src/bindings/ephemeral_pool_ticks.rs deleted file mode 100644 index 59f25f0..0000000 --- a/src/bindings/ephemeral_pool_ticks.rs +++ /dev/null @@ -1,222 +0,0 @@ -pub use ephemeral_pool_ticks::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod ephemeral_pool_ticks { - pub use super::super::shared_types::*; - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::Some(::ethers::core::abi::ethabi::Constructor { - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("pool"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("V3PoolCallee"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickLower"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickUpper"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ], - }), - functions: ::core::convert::From::from([( - ::std::borrow::ToOwned::to_owned("getPopulatedTicksInRange"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("getPopulatedTicksInRange",), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("pool"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "V3PoolCallee" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickLower"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickUpper"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("slots"), - kind: ::ethers::core::abi::ethabi::ParamType::Array(::std::boxed::Box::new( - ::ethers::core::abi::ethabi::ParamType::Tuple(::std::vec![ - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ],), - ),), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "struct PoolUtils.Slot[]" - ),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Payable, - },], - )]), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static EPHEMERALPOOLTICKS_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`\x80`@R`@Qb\0\x07\x9B8\x03\x80b\0\x07\x9B\x839\x81\x01`@\x81\x90Rb\0\0&\x91b\0\x06\0V[`\0b\0\x005\x84\x84\x84b\0\0eV[\x90P`\0\x81`@Q` \x01b\0\0L\x91\x90b\0\x06WV[`@Q` \x81\x83\x03\x03\x81R\x90`@R\x90P\x80Q` \x82\x01\xFD[``\x81`\x02\x0B\x83`\x02\x0B\x13\x15b\0\0{W`\0\x80\xFD[`\0\x84`\x01`\x01`\xA0\x1B\x03\x16c\xD0\xC9:|`@Q\x81c\xFF\xFF\xFF\xFF\x16`\xE0\x1B\x81R`\x04\x01` `@Q\x80\x83\x03\x81\x86Z\xFA\x15\x80\x15b\0\0\xBCW=`\0\x80>=`\0\xFD[PPPP`@Q=`\x1F\x19`\x1F\x82\x01\x16\x82\x01\x80`@RP\x81\x01\x90b\0\0\xE2\x91\x90b\0\x06\xA8V[\x90P\x80\x84\x07`\0\x90\x81\x13\x82\x86\x05\x03`\x02\x90\x81\x0B`\x08\x90\x81\x1D\x92\x84\x87\x07\x81\x13\x85\x88\x05\x03\x90\x92\x0B\x90\x1D\x90\x80b\0\x01\x18\x89\x85\x85b\0\x01\xE8V[\x91P\x91P`\x02\x81\x90\x1B`\x01`\x01`@\x1B\x03\x81\x11\x15b\0\x01;Wb\0\x01;b\0\x06\xCDV[`@Q\x90\x80\x82R\x80` \x02` \x01\x82\x01`@R\x80\x15b\0\x01\x82W\x81` \x01[`@\x80Q\x80\x82\x01\x90\x91R`\0\x80\x82R` \x82\x01R\x81R` \x01\x90`\x01\x90\x03\x90\x81b\0\x01ZW\x90P[P\x95P`\0\x84[\x84`\x01\x0B\x81`\x01\x0B\x13b\0\x01\xDAWb\0\x01\xCF\x8B\x82\x89\x87\x8A\x86\x03a\xFF\xFF\x16\x81Q\x81\x10b\0\x01\xB9Wb\0\x01\xB9b\0\x06\xE3V[` \x02` \x01\x01Q\x8C\x87b\0\x03\x80` \x1B` \x1CV[\x91P`\x01\x01b\0\x01\x89V[PPPPPPP\x93\x92PPPV[```\0b\0\x01\xF8\x84\x84b\0\x07\x0FV[b\0\x02\x05\x90`\x01b\0\x07;V[a\xFF\xFF\x16`\x01`\x01`@\x1B\x03\x81\x11\x15b\0\x02#Wb\0\x02#b\0\x06\xCDV[`@Q\x90\x80\x82R\x80` \x02` \x01\x82\x01`@R\x80\x15b\0\x02MW\x81` \x01` \x82\x02\x806\x837\x01\x90P[P\x91P\x83[\x83`\x01\x0B\x81`\x01\x0B\x13b\0\x03wW`\0b\0\x02w`\x01`\x01`\xA0\x1B\x03\x88\x16\x83b\0\x056V[\x90P\x80\x84b\0\x02\x87\x88\x85b\0\x07\x0FV[a\xFF\xFF\x16\x81Q\x81\x10b\0\x02\x9EWb\0\x02\x9Eb\0\x06\xE3V[` \x90\x81\x02\x91\x90\x91\x01\x01R\x7F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x7FUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUU`\x01\x83\x90\x1C\x16\x82\x03`\x02\x81\x90\x1C\x7F33333333333333333333333333333333\x90\x81\x16\x91\x16\x01`\x04\x81\x90\x1C\x01\x16\x7F\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x02`\xF8\x1C`\0\x19\x82\x14`\x08\x1B\x17b\0\x03`\x90\x84b\0\x07aV[\x92PP\x80b\0\x03o\x90b\0\x07wV[\x90Pb\0\x02RV[P\x93P\x93\x91PPV[`\0\x80[a\x01\0\x81\x10\x15b\0\x05*W`\x01\x81\x1B\x85\x16\x15b\0\x05!W`\x08\x87\x90\x1B\x81\x01\x86\x02`\0b\0\x03\xBB`\x01`\x01`\xA0\x1B\x03\x8B\x16\x83b\0\x05_V[`\0\x83\x81R`\x05` \x90\x81R`@\x91\x82\x90 \x83Q\x82\x85\x01Q\x84Q\x80\x86\x01\x90\x95R\x82\x85R`\x80\x1B\x17\x91\x83\x01\x82\x90R\x89Q`\x01\x8A\x81\x01\x9A\x95\x96P\x90\x91\x01\x93\x91\x92\x91\x8A\x91\x81\x10b\0\x04\rWb\0\x04\rb\0\x06\xE3V[` \x02` \x01\x01\x81\x90RPP`@Q\x80`@\x01`@R\x80\x82\x80`\x01\x01\x93P\x81R` \x01\x83`@\x01Q\x81RP\x87\x87\x80`\x01\x01\x98P\x81Q\x81\x10b\0\x04SWb\0\x04Sb\0\x06\xE3V[` \x02` \x01\x01\x81\x90RP`@Q\x80`@\x01`@R\x80\x82\x80`\x01\x01\x93P\x81R` \x01\x83``\x01Q\x81RP\x87\x87\x80`\x01\x01\x98P\x81Q\x81\x10b\0\x04\x98Wb\0\x04\x98b\0\x06\xE3V[` \x02` \x01\x01\x81\x90RP`\0`\xE0\x83\x01Q\x80`\xF8\x1B\x91PP`\xC0\x83\x01Q\x81\x81`\xD8\x1B\x17\x91PP`\xA0\x83\x01Q\x81\x81`8\x1B\x17\x91PP`\x80\x83\x01Qf\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x81\x81\x17\x91PP`@Q\x80`@\x01`@R\x80\x83\x81R` \x01\x82\x81RP\x88\x88\x80`\x01\x01\x99P\x81Q\x81\x10b\0\x05\x11Wb\0\x05\x11b\0\x06\xE3V[` \x02` \x01\x01\x81\x90RPPPPP[`\x01\x01b\0\x03\x84V[P\x90\x96\x95PPPPPPV[`\0`\x01\x82\x90\x0Bb\0\x05T\x84c)\x9C\xE1K`\xE1\x1B\x83\x85` b\0\x05\xC6V[PP`\0Q\x92\x91PPV[`@\x80Qa\x01\0\x81\x01\x82R`\0\x80\x82R` \x82\x01\x81\x90R\x91\x81\x01\x82\x90R``\x81\x01\x82\x90R`\x80\x81\x01\x82\x90R`\xA0\x81\x01\x82\x90R`\xC0\x81\x01\x82\x90R`\xE0\x81\x01\x91\x90\x91R`\x02\x82\x90\x0B\x81b\0\x05\xBE\x85c\xF3\r\xBA\x93`\xE0\x1B\x84\x84a\x01\0b\0\x05\xC6V[PP\x92\x91PPV[\x83`\0R\x82`\x04R\x80\x82`$`\0\x88Z\xFAb\0\x05\xE1W`\0\x80\xFD[PPPPPV[\x80Q`\x02\x81\x90\x0B\x81\x14b\0\x05\xFBW`\0\x80\xFD[\x91\x90PV[`\0\x80`\0``\x84\x86\x03\x12\x15b\0\x06\x16W`\0\x80\xFD[\x83Q`\x01`\x01`\xA0\x1B\x03\x81\x16\x81\x14b\0\x06.W`\0\x80\xFD[\x92Pb\0\x06>` \x85\x01b\0\x05\xE8V[\x91Pb\0\x06N`@\x85\x01b\0\x05\xE8V[\x90P\x92P\x92P\x92V[` \x80\x82R\x82Q\x82\x82\x01\x81\x90R`\0\x91\x90`@\x90\x81\x85\x01\x90\x86\x84\x01\x85[\x82\x81\x10\x15b\0\x06\x9BW\x81Q\x80Q\x85R\x86\x01Q\x86\x85\x01R\x92\x84\x01\x92\x90\x85\x01\x90`\x01\x01b\0\x06tV[P\x91\x97\x96PPPPPPPV[`\0` \x82\x84\x03\x12\x15b\0\x06\xBBW`\0\x80\xFD[b\0\x06\xC6\x82b\0\x05\xE8V[\x93\x92PPPV[cNH{q`\xE0\x1B`\0R`A`\x04R`$`\0\xFD[cNH{q`\xE0\x1B`\0R`2`\x04R`$`\0\xFD[cNH{q`\xE0\x1B`\0R`\x11`\x04R`$`\0\xFD[`\x01\x82\x81\x0B\x90\x82\x90\x0B\x03a\x7F\xFF\x19\x81\x12a\x7F\xFF\x82\x13\x17\x15b\0\x075Wb\0\x075b\0\x06\xF9V[\x92\x91PPV[`\x01\x81\x81\x0B\x90\x83\x90\x0B\x01a\x7F\xFF\x81\x13a\x7F\xFF\x19\x82\x12\x17\x15b\0\x075Wb\0\x075b\0\x06\xF9V[\x80\x82\x01\x80\x82\x11\x15b\0\x075Wb\0\x075b\0\x06\xF9V[`\0\x81`\x01\x0Ba\x7F\xFF\x81\x03b\0\x07\x91Wb\0\x07\x91b\0\x06\xF9V[`\x01\x01\x92\x91PPV\xFE"; - /// The bytecode of the contract. - pub static EPHEMERALPOOLTICKS_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"`\x80`@R`\x046\x10a\0\x1EW`\x005`\xE0\x1C\x80c\xF2\xBB\0\x8B\x14a\0#W[`\0\x80\xFD[a\x006a\x0016`\x04a\x06\x17V[a\0LV[`@Qa\0C\x91\x90a\x06{V[`@Q\x80\x91\x03\x90\xF3[``\x81`\x02\x0B\x83`\x02\x0B\x13\x15a\0aW`\0\x80\xFD[`\0\x84s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16c\xD0\xC9:|`@Q\x81c\xFF\xFF\xFF\xFF\x16`\xE0\x1B\x81R`\x04\x01` `@Q\x80\x83\x03\x81\x86Z\xFA\x15\x80\x15a\0\xAEW=`\0\x80>=`\0\xFD[PPPP`@Q=`\x1F\x19`\x1F\x82\x01\x16\x82\x01\x80`@RP\x81\x01\x90a\0\xD2\x91\x90a\x06\xCAV[\x90P\x80\x84\x07`\0\x90\x81\x13\x82\x86\x05\x03`\x02\x90\x81\x0B`\x08\x90\x81\x1D\x92\x84\x87\x07\x81\x13\x85\x88\x05\x03\x90\x92\x0B\x90\x1D\x90\x80a\x01\x06\x89\x85\x85a\x01\xC5V[\x91P\x91P`\x02\x81\x90\x1Bg\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x11\x15a\x01'Wa\x01'a\x06\xEEV[`@Q\x90\x80\x82R\x80` \x02` \x01\x82\x01`@R\x80\x15a\x01lW\x81` \x01[`@\x80Q\x80\x82\x01\x90\x91R`\0\x80\x82R` \x82\x01R\x81R` \x01\x90`\x01\x90\x03\x90\x81a\x01EW\x90P[P\x95P`\0\x84[\x84`\x01\x0B\x81`\x01\x0B\x13a\x01\xB7Wa\x01\xAD\x8B\x82\x89\x87\x8A\x86\x03a\xFF\xFF\x16\x81Q\x81\x10a\x01\x9EWa\x01\x9Ea\x07\x1DV[` \x02` \x01\x01Q\x8C\x87a\x03tV[\x91P`\x01\x01a\x01sV[PPPPPPP\x93\x92PPPV[```\0a\x01\xD3\x84\x84a\x07{V[a\x01\xDE\x90`\x01a\x07\xC1V[a\xFF\xFF\x16g\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x11\x15a\x01\xFAWa\x01\xFAa\x06\xEEV[`@Q\x90\x80\x82R\x80` \x02` \x01\x82\x01`@R\x80\x15a\x02#W\x81` \x01` \x82\x02\x806\x837\x01\x90P[P\x91P\x83[\x83`\x01\x0B\x81`\x01\x0B\x13a\x03kW`\0a\x02Ws\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x88\x16\x83a\x05&V[\x90P\x80\x84a\x02e\x88\x85a\x07{V[a\xFF\xFF\x16\x81Q\x81\x10a\x02yWa\x02ya\x07\x1DV[` \x90\x81\x02\x91\x90\x91\x01\x01R\x7F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x0F\x7FUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUU`\x01\x83\x90\x1C\x16\x82\x03`\x02\x81\x90\x1C\x7F33333333333333333333333333333333\x90\x81\x16\x91\x16\x01`\x04\x81\x90\x1C\x01\x16\x7F\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x02`\xF8\x1C\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x82\x14`\x08\x1B\x17a\x03W\x90\x84a\x08\x01V[\x92PP\x80a\x03d\x90a\x08\x14V[\x90Pa\x02(V[P\x93P\x93\x91PPV[`\0\x80[a\x01\0\x81\x10\x15a\x05\x1AW`\x01\x81\x1B\x85\x16\x15a\x05\x12W`\x08\x87\x90\x1B\x81\x01\x86\x02`\0a\x03\xB8s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x8B\x16\x83a\x05fV[`\0\x83\x81R`\x05` \x90\x81R`@\x91\x82\x90 \x83Q\x82\x85\x01Q\x84Q\x80\x86\x01\x90\x95R\x82\x85R`\x80\x1B\x17\x91\x83\x01\x82\x90R\x89Q`\x01\x8A\x81\x01\x9A\x95\x96P\x90\x91\x01\x93\x91\x92\x91\x8A\x91\x81\x10a\x04\x07Wa\x04\x07a\x07\x1DV[` \x02` \x01\x01\x81\x90RPP`@Q\x80`@\x01`@R\x80\x82\x80`\x01\x01\x93P\x81R` \x01\x83`@\x01Q\x81RP\x87\x87\x80`\x01\x01\x98P\x81Q\x81\x10a\x04JWa\x04Ja\x07\x1DV[` \x02` \x01\x01\x81\x90RP`@Q\x80`@\x01`@R\x80\x82\x80`\x01\x01\x93P\x81R` \x01\x83``\x01Q\x81RP\x87\x87\x80`\x01\x01\x98P\x81Q\x81\x10a\x04\x8CWa\x04\x8Ca\x07\x1DV[` \x02` \x01\x01\x81\x90RP`\0`\xE0\x83\x01Q\x80`\xF8\x1B\x91PP`\xC0\x83\x01Q\x81\x81`\xD8\x1B\x17\x91PP`\xA0\x83\x01Q\x81\x81`8\x1B\x17\x91PP`\x80\x83\x01Qf\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x81\x81\x17\x91PP`@Q\x80`@\x01`@R\x80\x83\x81R` \x01\x82\x81RP\x88\x88\x80`\x01\x01\x99P\x81Q\x81\x10a\x05\x02Wa\x05\x02a\x07\x1DV[` \x02` \x01\x01\x81\x90RPPPPP[`\x01\x01a\x03xV[P\x90\x96\x95PPPPPPV[`\0`\x01\x82\x90\x0Ba\x05[\x84\x7FS9\xC2\x96\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\x83\x85` a\x05\xE4V[PP`\0Q\x92\x91PPV[`@\x80Qa\x01\0\x81\x01\x82R`\0\x80\x82R` \x82\x01\x81\x90R\x91\x81\x01\x82\x90R``\x81\x01\x82\x90R`\x80\x81\x01\x82\x90R`\xA0\x81\x01\x82\x90R`\xC0\x81\x01\x82\x90R`\xE0\x81\x01\x91\x90\x91R`\x02\x82\x90\x0B\x81a\x05\xDC\x85\x7F\xF3\r\xBA\x93\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\x84\x84a\x01\0a\x05\xE4V[PP\x92\x91PPV[\x83`\0R\x82`\x04R\x80\x82`$`\0\x88Z\xFAa\x05\xFEW`\0\x80\xFD[PPPPPV[\x80`\x02\x0B\x81\x14a\x06\x14W`\0\x80\xFD[PV[`\0\x80`\0``\x84\x86\x03\x12\x15a\x06,W`\0\x80\xFD[\x835s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x16\x81\x14a\x06PW`\0\x80\xFD[\x92P` \x84\x015a\x06`\x81a\x06\x05V[\x91P`@\x84\x015a\x06p\x81a\x06\x05V[\x80\x91PP\x92P\x92P\x92V[` \x80\x82R\x82Q\x82\x82\x01\x81\x90R`\0\x91\x90`@\x90\x81\x85\x01\x90\x86\x84\x01\x85[\x82\x81\x10\x15a\x06\xBDW\x81Q\x80Q\x85R\x86\x01Q\x86\x85\x01R\x92\x84\x01\x92\x90\x85\x01\x90`\x01\x01a\x06\x98V[P\x91\x97\x96PPPPPPPV[`\0` \x82\x84\x03\x12\x15a\x06\xDCW`\0\x80\xFD[\x81Qa\x06\xE7\x81a\x06\x05V[\x93\x92PPPV[\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`\0R`A`\x04R`$`\0\xFD[\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`\0R`2`\x04R`$`\0\xFD[\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`\0R`\x11`\x04R`$`\0\xFD[`\x01\x82\x81\x0B\x90\x82\x90\x0B\x03\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\0\x81\x12a\x7F\xFF\x82\x13\x17\x15a\x07\xBBWa\x07\xBBa\x07LV[\x92\x91PPV[`\x01\x81\x81\x0B\x90\x83\x90\x0B\x01a\x7F\xFF\x81\x13\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\0\x82\x12\x17\x15a\x07\xBBWa\x07\xBBa\x07LV[\x80\x82\x01\x80\x82\x11\x15a\x07\xBBWa\x07\xBBa\x07LV[`\0\x81`\x01\x0Ba\x7F\xFF\x81\x03a\x08+Wa\x08+a\x07LV[`\x01\x01\x92\x91PPV\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static EPHEMERALPOOLTICKS_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct EphemeralPoolTicks(::ethers::contract::Contract); - impl ::core::clone::Clone for EphemeralPoolTicks { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for EphemeralPoolTicks { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for EphemeralPoolTicks { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for EphemeralPoolTicks { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(EphemeralPoolTicks)) - .field(&self.address()) - .finish() - } - } - impl EphemeralPoolTicks { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - EPHEMERALPOOLTICKS_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - EPHEMERALPOOLTICKS_ABI.clone(), - EPHEMERALPOOLTICKS_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - ///Calls the contract's `getPopulatedTicksInRange` (0xf2bb008b) function - pub fn get_populated_ticks_in_range( - &self, - pool: ::ethers::core::types::Address, - tick_lower: i32, - tick_upper: i32, - ) -> ::ethers::contract::builders::ContractCall> { - self.0 - .method_hash([242, 187, 0, 139], (pool, tick_lower, tick_upper)) - .expect("method not found (this should never happen)") - } - } - impl From<::ethers::contract::Contract> for EphemeralPoolTicks { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Container type for all input parameters for the `getPopulatedTicksInRange` function with signature `getPopulatedTicksInRange(address,int24,int24)` and selector `0xf2bb008b` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall( - name = "getPopulatedTicksInRange", - abi = "getPopulatedTicksInRange(address,int24,int24)" - )] - pub struct GetPopulatedTicksInRangeCall { - pub pool: ::ethers::core::types::Address, - pub tick_lower: i32, - pub tick_upper: i32, - } - ///Container type for all return fields from the `getPopulatedTicksInRange` function with signature `getPopulatedTicksInRange(address,int24,int24)` and selector `0xf2bb008b` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct GetPopulatedTicksInRangeReturn { - pub slots: ::std::vec::Vec, - } -} diff --git a/src/bindings/ephemeral_storage_lens.rs b/src/bindings/ephemeral_storage_lens.rs deleted file mode 100644 index d1ae7ce..0000000 --- a/src/bindings/ephemeral_storage_lens.rs +++ /dev/null @@ -1,177 +0,0 @@ -pub use ephemeral_storage_lens::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod ephemeral_storage_lens { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([( - ::std::borrow::ToOwned::to_owned("extsload"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("extsload"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("slots"), - kind: ::ethers::core::abi::ethabi::ParamType::Array(::std::boxed::Box::new( - ::ethers::core::abi::ethabi::ParamType::FixedBytes(32usize), - ),), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes32[]"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Array(::std::boxed::Box::new( - ::ethers::core::abi::ethabi::ParamType::FixedBytes(32usize), - ),), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes32[]"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Payable, - },], - )]), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static EPHEMERALSTORAGELENS_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`\x80`@R4\x80\x15a\0\x10W`\0\x80\xFD[Pa\x01G\x80a\0 `\09`\0\xF3\xFE`\x80`@R`\x046\x10a\0\x1EW`\x005`\xE0\x1C\x80c\xDB\xD05\xFF\x14a\0#W[`\0\x80\xFD[a\x006a\x0016`\x04a\0\x81V[a\0LV[`@Qa\0C\x91\x90a\0\xF6V[`@Q\x80\x91\x03\x90\xF3[``` `\0R\x81` R\x81`\x05\x1B`@\x01`@\x84[\x81\x83\x14a\0zW\x805T\x82R` \x91\x82\x01\x91\x01a\0bV[PP\x80`\0\xF3[`\0\x80` \x83\x85\x03\x12\x15a\0\x94W`\0\x80\xFD[\x825g\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x82\x11\x15a\0\xACW`\0\x80\xFD[\x81\x85\x01\x91P\x85`\x1F\x83\x01\x12a\0\xC0W`\0\x80\xFD[\x815\x81\x81\x11\x15a\0\xCFW`\0\x80\xFD[\x86` \x82`\x05\x1B\x85\x01\x01\x11\x15a\0\xE4W`\0\x80\xFD[` \x92\x90\x92\x01\x96\x91\x95P\x90\x93PPPPV[` \x80\x82R\x82Q\x82\x82\x01\x81\x90R`\0\x91\x90\x84\x82\x01\x90`@\x85\x01\x90\x84[\x81\x81\x10\x15a\x01.W\x83Q\x83R\x92\x84\x01\x92\x91\x84\x01\x91`\x01\x01a\x01\x12V[P\x90\x96\x95PPPPPPV\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The bytecode of the contract. - pub static EPHEMERALSTORAGELENS_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"`\x80`@R`\x046\x10a\0\x1EW`\x005`\xE0\x1C\x80c\xDB\xD05\xFF\x14a\0#W[`\0\x80\xFD[a\x006a\x0016`\x04a\0\x81V[a\0LV[`@Qa\0C\x91\x90a\0\xF6V[`@Q\x80\x91\x03\x90\xF3[``` `\0R\x81` R\x81`\x05\x1B`@\x01`@\x84[\x81\x83\x14a\0zW\x805T\x82R` \x91\x82\x01\x91\x01a\0bV[PP\x80`\0\xF3[`\0\x80` \x83\x85\x03\x12\x15a\0\x94W`\0\x80\xFD[\x825g\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x82\x11\x15a\0\xACW`\0\x80\xFD[\x81\x85\x01\x91P\x85`\x1F\x83\x01\x12a\0\xC0W`\0\x80\xFD[\x815\x81\x81\x11\x15a\0\xCFW`\0\x80\xFD[\x86` \x82`\x05\x1B\x85\x01\x01\x11\x15a\0\xE4W`\0\x80\xFD[` \x92\x90\x92\x01\x96\x91\x95P\x90\x93PPPPV[` \x80\x82R\x82Q\x82\x82\x01\x81\x90R`\0\x91\x90\x84\x82\x01\x90`@\x85\x01\x90\x84[\x81\x81\x10\x15a\x01.W\x83Q\x83R\x92\x84\x01\x92\x91\x84\x01\x91`\x01\x01a\x01\x12V[P\x90\x96\x95PPPPPPV\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static EPHEMERALSTORAGELENS_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct EphemeralStorageLens(::ethers::contract::Contract); - impl ::core::clone::Clone for EphemeralStorageLens { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for EphemeralStorageLens { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for EphemeralStorageLens { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for EphemeralStorageLens { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(EphemeralStorageLens)) - .field(&self.address()) - .finish() - } - } - impl EphemeralStorageLens { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - EPHEMERALSTORAGELENS_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - EPHEMERALSTORAGELENS_ABI.clone(), - EPHEMERALSTORAGELENS_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - ///Calls the contract's `extsload` (0xdbd035ff) function - pub fn extsload( - &self, - slots: ::std::vec::Vec<[u8; 32]>, - ) -> ::ethers::contract::builders::ContractCall> { - self.0 - .method_hash([219, 208, 53, 255], slots) - .expect("method not found (this should never happen)") - } - } - impl From<::ethers::contract::Contract> for EphemeralStorageLens { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Container type for all input parameters for the `extsload` function with signature `extsload(bytes32[])` and selector `0xdbd035ff` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "extsload", abi = "extsload(bytes32[])")] - pub struct ExtsloadCall { - pub slots: ::std::vec::Vec<[u8; 32]>, - } - ///Container type for all return fields from the `extsload` function with signature `extsload(bytes32[])` and selector `0xdbd035ff` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct ExtsloadReturn(pub ::std::vec::Vec<[u8; 32]>); -} diff --git a/src/bindings/erc20_caller.rs b/src/bindings/erc20_caller.rs deleted file mode 100644 index 5c23db3..0000000 --- a/src/bindings/erc20_caller.rs +++ /dev/null @@ -1,116 +0,0 @@ -pub use erc20_caller::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod erc20_caller { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::std::collections::BTreeMap::new(), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static ERC20CALLER_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`-`7`\x0B\x82\x82\x829\x80Q`\0\x1A`s\x14`*WcNH{q`\xE0\x1B`\0R`\0`\x04R`$`\0\xFD[0`\0R`s\x81S\x82\x81\xF3\xFEs\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The bytecode of the contract. - pub static ERC20CALLER_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"s\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static ERC20CALLER_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct ERC20Caller(::ethers::contract::Contract); - impl ::core::clone::Clone for ERC20Caller { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for ERC20Caller { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for ERC20Caller { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for ERC20Caller { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(ERC20Caller)) - .field(&self.address()) - .finish() - } - } - impl ERC20Caller { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - ERC20CALLER_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - ERC20CALLER_ABI.clone(), - ERC20CALLER_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - } - impl From<::ethers::contract::Contract> for ERC20Caller { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } -} diff --git a/src/bindings/fixed_point_96.rs b/src/bindings/fixed_point_96.rs deleted file mode 100644 index b0c7eaa..0000000 --- a/src/bindings/fixed_point_96.rs +++ /dev/null @@ -1,116 +0,0 @@ -pub use fixed_point_96::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod fixed_point_96 { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::std::collections::BTreeMap::new(), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static FIXEDPOINT96_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`-`7`\x0B\x82\x82\x829\x80Q`\0\x1A`s\x14`*WcNH{q`\xE0\x1B`\0R`\0`\x04R`$`\0\xFD[0`\0R`s\x81S\x82\x81\xF3\xFEs\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The bytecode of the contract. - pub static FIXEDPOINT96_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"s\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static FIXEDPOINT96_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct FixedPoint96(::ethers::contract::Contract); - impl ::core::clone::Clone for FixedPoint96 { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for FixedPoint96 { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for FixedPoint96 { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for FixedPoint96 { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(FixedPoint96)) - .field(&self.address()) - .finish() - } - } - impl FixedPoint96 { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - FIXEDPOINT96_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - FIXEDPOINT96_ABI.clone(), - FIXEDPOINT96_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - } - impl From<::ethers::contract::Contract> for FixedPoint96 { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } -} diff --git a/src/bindings/fixed_point_math_lib.rs b/src/bindings/fixed_point_math_lib.rs deleted file mode 100644 index 96d15f8..0000000 --- a/src/bindings/fixed_point_math_lib.rs +++ /dev/null @@ -1,502 +0,0 @@ -pub use fixed_point_math_lib::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod fixed_point_math_lib { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::std::collections::BTreeMap::new(), - events: ::std::collections::BTreeMap::new(), - errors: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("DivFailed"), - ::std::vec![::ethers::core::abi::ethabi::AbiError { - name: ::std::borrow::ToOwned::to_owned("DivFailed"), - inputs: ::std::vec![], - },], - ), - ( - ::std::borrow::ToOwned::to_owned("DivWadFailed"), - ::std::vec![::ethers::core::abi::ethabi::AbiError { - name: ::std::borrow::ToOwned::to_owned("DivWadFailed"), - inputs: ::std::vec![], - },], - ), - ( - ::std::borrow::ToOwned::to_owned("ExpOverflow"), - ::std::vec![::ethers::core::abi::ethabi::AbiError { - name: ::std::borrow::ToOwned::to_owned("ExpOverflow"), - inputs: ::std::vec![], - },], - ), - ( - ::std::borrow::ToOwned::to_owned("FactorialOverflow"), - ::std::vec![::ethers::core::abi::ethabi::AbiError { - name: ::std::borrow::ToOwned::to_owned("FactorialOverflow"), - inputs: ::std::vec![], - },], - ), - ( - ::std::borrow::ToOwned::to_owned("FullMulDivFailed"), - ::std::vec![::ethers::core::abi::ethabi::AbiError { - name: ::std::borrow::ToOwned::to_owned("FullMulDivFailed"), - inputs: ::std::vec![], - },], - ), - ( - ::std::borrow::ToOwned::to_owned("LnWadUndefined"), - ::std::vec![::ethers::core::abi::ethabi::AbiError { - name: ::std::borrow::ToOwned::to_owned("LnWadUndefined"), - inputs: ::std::vec![], - },], - ), - ( - ::std::borrow::ToOwned::to_owned("MantissaOverflow"), - ::std::vec![::ethers::core::abi::ethabi::AbiError { - name: ::std::borrow::ToOwned::to_owned("MantissaOverflow"), - inputs: ::std::vec![], - },], - ), - ( - ::std::borrow::ToOwned::to_owned("MulDivFailed"), - ::std::vec![::ethers::core::abi::ethabi::AbiError { - name: ::std::borrow::ToOwned::to_owned("MulDivFailed"), - inputs: ::std::vec![], - },], - ), - ( - ::std::borrow::ToOwned::to_owned("MulWadFailed"), - ::std::vec![::ethers::core::abi::ethabi::AbiError { - name: ::std::borrow::ToOwned::to_owned("MulWadFailed"), - inputs: ::std::vec![], - },], - ), - ( - ::std::borrow::ToOwned::to_owned("RPowOverflow"), - ::std::vec![::ethers::core::abi::ethabi::AbiError { - name: ::std::borrow::ToOwned::to_owned("RPowOverflow"), - inputs: ::std::vec![], - },], - ), - ]), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static FIXEDPOINTMATHLIB_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`-`7`\x0B\x82\x82\x829\x80Q`\0\x1A`s\x14`*WcNH{q`\xE0\x1B`\0R`\0`\x04R`$`\0\xFD[0`\0R`s\x81S\x82\x81\xF3\xFEs\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The bytecode of the contract. - pub static FIXEDPOINTMATHLIB_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"s\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static FIXEDPOINTMATHLIB_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct FixedPointMathLib(::ethers::contract::Contract); - impl ::core::clone::Clone for FixedPointMathLib { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for FixedPointMathLib { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for FixedPointMathLib { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for FixedPointMathLib { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(FixedPointMathLib)) - .field(&self.address()) - .finish() - } - } - impl FixedPointMathLib { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - FIXEDPOINTMATHLIB_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - FIXEDPOINTMATHLIB_ABI.clone(), - FIXEDPOINTMATHLIB_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - } - impl From<::ethers::contract::Contract> for FixedPointMathLib { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Custom Error type `DivFailed` with signature `DivFailed()` and selector `0x65244e4e` - #[derive( - Clone, - ::ethers::contract::EthError, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[etherror(name = "DivFailed", abi = "DivFailed()")] - pub struct DivFailed; - ///Custom Error type `DivWadFailed` with signature `DivWadFailed()` and selector `0x7c5f487d` - #[derive( - Clone, - ::ethers::contract::EthError, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[etherror(name = "DivWadFailed", abi = "DivWadFailed()")] - pub struct DivWadFailed; - ///Custom Error type `ExpOverflow` with signature `ExpOverflow()` and selector `0xa37bfec9` - #[derive( - Clone, - ::ethers::contract::EthError, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[etherror(name = "ExpOverflow", abi = "ExpOverflow()")] - pub struct ExpOverflow; - ///Custom Error type `FactorialOverflow` with signature `FactorialOverflow()` and selector `0xaba0f2a2` - #[derive( - Clone, - ::ethers::contract::EthError, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[etherror(name = "FactorialOverflow", abi = "FactorialOverflow()")] - pub struct FactorialOverflow; - ///Custom Error type `FullMulDivFailed` with signature `FullMulDivFailed()` and selector `0xae47f702` - #[derive( - Clone, - ::ethers::contract::EthError, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[etherror(name = "FullMulDivFailed", abi = "FullMulDivFailed()")] - pub struct FullMulDivFailed; - ///Custom Error type `LnWadUndefined` with signature `LnWadUndefined()` and selector `0x1615e638` - #[derive( - Clone, - ::ethers::contract::EthError, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[etherror(name = "LnWadUndefined", abi = "LnWadUndefined()")] - pub struct LnWadUndefined; - ///Custom Error type `MantissaOverflow` with signature `MantissaOverflow()` and selector `0xce30380c` - #[derive( - Clone, - ::ethers::contract::EthError, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[etherror(name = "MantissaOverflow", abi = "MantissaOverflow()")] - pub struct MantissaOverflow; - ///Custom Error type `MulDivFailed` with signature `MulDivFailed()` and selector `0xad251c27` - #[derive( - Clone, - ::ethers::contract::EthError, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[etherror(name = "MulDivFailed", abi = "MulDivFailed()")] - pub struct MulDivFailed; - ///Custom Error type `MulWadFailed` with signature `MulWadFailed()` and selector `0xbac65e5b` - #[derive( - Clone, - ::ethers::contract::EthError, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[etherror(name = "MulWadFailed", abi = "MulWadFailed()")] - pub struct MulWadFailed; - ///Custom Error type `RPowOverflow` with signature `RPowOverflow()` and selector `0x49f7642b` - #[derive( - Clone, - ::ethers::contract::EthError, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[etherror(name = "RPowOverflow", abi = "RPowOverflow()")] - pub struct RPowOverflow; - ///Container type for all of the contract's custom errors - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum FixedPointMathLibErrors { - DivFailed(DivFailed), - DivWadFailed(DivWadFailed), - ExpOverflow(ExpOverflow), - FactorialOverflow(FactorialOverflow), - FullMulDivFailed(FullMulDivFailed), - LnWadUndefined(LnWadUndefined), - MantissaOverflow(MantissaOverflow), - MulDivFailed(MulDivFailed), - MulWadFailed(MulWadFailed), - RPowOverflow(RPowOverflow), - /// The standard solidity revert string, with selector - /// Error(string) -- 0x08c379a0 - RevertString(::std::string::String), - } - impl ::ethers::core::abi::AbiDecode for FixedPointMathLibErrors { - fn decode(data: impl AsRef<[u8]>) -> ::core::result::Result { - let data = data.as_ref(); - if let Ok(decoded) = <::std::string::String as ::ethers::core::abi::AbiDecode>::decode(data) { - return Ok(Self::RevertString(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::DivFailed(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::DivWadFailed(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::ExpOverflow(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::FactorialOverflow(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::FullMulDivFailed(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::LnWadUndefined(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::MantissaOverflow(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::MulDivFailed(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::MulWadFailed(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::RPowOverflow(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData.into()) - } - } - impl ::ethers::core::abi::AbiEncode for FixedPointMathLibErrors { - fn encode(self) -> ::std::vec::Vec { - match self { - Self::DivFailed(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::DivWadFailed(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::ExpOverflow(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::FactorialOverflow(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::FullMulDivFailed(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::LnWadUndefined(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::MantissaOverflow(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::MulDivFailed(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::MulWadFailed(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::RPowOverflow(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::RevertString(s) => ::ethers::core::abi::AbiEncode::encode(s), - } - } - } - impl ::ethers::contract::ContractRevert for FixedPointMathLibErrors { - fn valid_selector(selector: [u8; 4]) -> bool { - match selector { - [0x08, 0xc3, 0x79, 0xa0] => true, - _ if selector == ::selector() => true, - _ if selector == ::selector() => true, - _ if selector == ::selector() => true, - _ if selector == ::selector() => true, - _ if selector == ::selector() => true, - _ if selector == ::selector() => true, - _ if selector == ::selector() => true, - _ if selector == ::selector() => true, - _ if selector == ::selector() => true, - _ if selector == ::selector() => true, - _ => false, - } - } - } - impl ::core::fmt::Display for FixedPointMathLibErrors { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::DivFailed(element) => ::core::fmt::Display::fmt(element, f), - Self::DivWadFailed(element) => ::core::fmt::Display::fmt(element, f), - Self::ExpOverflow(element) => ::core::fmt::Display::fmt(element, f), - Self::FactorialOverflow(element) => ::core::fmt::Display::fmt(element, f), - Self::FullMulDivFailed(element) => ::core::fmt::Display::fmt(element, f), - Self::LnWadUndefined(element) => ::core::fmt::Display::fmt(element, f), - Self::MantissaOverflow(element) => ::core::fmt::Display::fmt(element, f), - Self::MulDivFailed(element) => ::core::fmt::Display::fmt(element, f), - Self::MulWadFailed(element) => ::core::fmt::Display::fmt(element, f), - Self::RPowOverflow(element) => ::core::fmt::Display::fmt(element, f), - Self::RevertString(s) => ::core::fmt::Display::fmt(s, f), - } - } - } - impl ::core::convert::From<::std::string::String> for FixedPointMathLibErrors { - fn from(value: String) -> Self { - Self::RevertString(value) - } - } - impl ::core::convert::From for FixedPointMathLibErrors { - fn from(value: DivFailed) -> Self { - Self::DivFailed(value) - } - } - impl ::core::convert::From for FixedPointMathLibErrors { - fn from(value: DivWadFailed) -> Self { - Self::DivWadFailed(value) - } - } - impl ::core::convert::From for FixedPointMathLibErrors { - fn from(value: ExpOverflow) -> Self { - Self::ExpOverflow(value) - } - } - impl ::core::convert::From for FixedPointMathLibErrors { - fn from(value: FactorialOverflow) -> Self { - Self::FactorialOverflow(value) - } - } - impl ::core::convert::From for FixedPointMathLibErrors { - fn from(value: FullMulDivFailed) -> Self { - Self::FullMulDivFailed(value) - } - } - impl ::core::convert::From for FixedPointMathLibErrors { - fn from(value: LnWadUndefined) -> Self { - Self::LnWadUndefined(value) - } - } - impl ::core::convert::From for FixedPointMathLibErrors { - fn from(value: MantissaOverflow) -> Self { - Self::MantissaOverflow(value) - } - } - impl ::core::convert::From for FixedPointMathLibErrors { - fn from(value: MulDivFailed) -> Self { - Self::MulDivFailed(value) - } - } - impl ::core::convert::From for FixedPointMathLibErrors { - fn from(value: MulWadFailed) -> Self { - Self::MulWadFailed(value) - } - } - impl ::core::convert::From for FixedPointMathLibErrors { - fn from(value: RPowOverflow) -> Self { - Self::RPowOverflow(value) - } - } -} diff --git a/src/bindings/full_math.rs b/src/bindings/full_math.rs deleted file mode 100644 index ce21647..0000000 --- a/src/bindings/full_math.rs +++ /dev/null @@ -1,135 +0,0 @@ -pub use full_math::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod full_math { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::std::collections::BTreeMap::new(), - events: ::std::collections::BTreeMap::new(), - errors: ::core::convert::From::from([( - ::std::borrow::ToOwned::to_owned("FullMulDivFailed"), - ::std::vec![::ethers::core::abi::ethabi::AbiError { - name: ::std::borrow::ToOwned::to_owned("FullMulDivFailed"), - inputs: ::std::vec![], - },], - )]), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static FULLMATH_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`-`7`\x0B\x82\x82\x829\x80Q`\0\x1A`s\x14`*WcNH{q`\xE0\x1B`\0R`\0`\x04R`$`\0\xFD[0`\0R`s\x81S\x82\x81\xF3\xFEs\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The bytecode of the contract. - pub static FULLMATH_BYTECODE: ::ethers::core::types::Bytes = ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"s\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static FULLMATH_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct FullMath(::ethers::contract::Contract); - impl ::core::clone::Clone for FullMath { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for FullMath { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for FullMath { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for FullMath { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(FullMath)) - .field(&self.address()) - .finish() - } - } - impl FullMath { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - FULLMATH_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - FULLMATH_ABI.clone(), - FULLMATH_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - } - impl From<::ethers::contract::Contract> for FullMath { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Custom Error type `FullMulDivFailed` with signature `FullMulDivFailed()` and selector `0xae47f702` - #[derive( - Clone, - ::ethers::contract::EthError, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[etherror(name = "FullMulDivFailed", abi = "FullMulDivFailed()")] - pub struct FullMulDivFailed; -} diff --git a/src/bindings/i_nonfungible_position_manager.rs b/src/bindings/i_nonfungible_position_manager.rs deleted file mode 100644 index fdfe6a2..0000000 --- a/src/bindings/i_nonfungible_position_manager.rs +++ /dev/null @@ -1,2952 +0,0 @@ -pub use i_nonfungible_position_manager::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod i_nonfungible_position_manager { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("DOMAIN_SEPARATOR"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("DOMAIN_SEPARATOR"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::FixedBytes(32usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes32"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("PERMIT_TYPEHASH"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("PERMIT_TYPEHASH"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::FixedBytes(32usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes32"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Pure, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("WETH9"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("WETH9"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("approve"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("approve"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("balanceOf"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("balanceOf"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("balance"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("burn"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("burn"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Payable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("collect"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("collect"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("params"), - kind: ::ethers::core::abi::ethabi::ParamType::Tuple(::std::vec![ - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Address, - ::ethers::core::abi::ethabi::ParamType::Uint(128usize), - ::ethers::core::abi::ethabi::ParamType::Uint(128usize), - ],), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "struct INonfungiblePositionManager.CollectParams", - ),), - },], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Payable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("createAndInitializePoolIfNecessary"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("createAndInitializePoolIfNecessary",), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("token0"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("token1"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("fee"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("sqrtPriceX96"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(160usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint160" - ),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("pool"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Payable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("decreaseLiquidity"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("decreaseLiquidity"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("params"), - kind: ::ethers::core::abi::ethabi::ParamType::Tuple(::std::vec![ - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Uint(128usize), - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ],), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "struct INonfungiblePositionManager.DecreaseLiquidityParams", - ),), - },], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Payable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("factory"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("factory"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("getApproved"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("getApproved"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("operator"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("increaseLiquidity"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("increaseLiquidity"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("params"), - kind: ::ethers::core::abi::ethabi::ParamType::Tuple(::std::vec![ - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ],), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "struct INonfungiblePositionManager.IncreaseLiquidityParams", - ),), - },], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("liquidity"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Payable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("isApprovedForAll"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("isApprovedForAll"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("operator"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("mint"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("mint"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("params"), - kind: ::ethers::core::abi::ethabi::ParamType::Tuple(::std::vec![ - ::ethers::core::abi::ethabi::ParamType::Address, - ::ethers::core::abi::ethabi::ParamType::Address, - ::ethers::core::abi::ethabi::ParamType::Uint(24usize), - ::ethers::core::abi::ethabi::ParamType::Int(24usize), - ::ethers::core::abi::ethabi::ParamType::Int(24usize), - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ::ethers::core::abi::ethabi::ParamType::Address, - ::ethers::core::abi::ethabi::ParamType::Uint(256usize), - ],), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "struct INonfungiblePositionManager.MintParams", - ),), - },], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("liquidity"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Payable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("name"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("name"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::String, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("string"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("ownerOf"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("ownerOf"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("permit"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("permit"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("spender"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("deadline"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("v"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint8"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("r"), - kind: ::ethers::core::abi::ethabi::ParamType::FixedBytes(32usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "bytes32" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("s"), - kind: ::ethers::core::abi::ethabi::ParamType::FixedBytes(32usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "bytes32" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Payable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("positions"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("positions"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("nonce"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(96usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint96"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("operator"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("token0"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("token1"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("fee"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickLower"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickUpper"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("liquidity"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("feeGrowthInside0LastX128",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("feeGrowthInside1LastX128",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokensOwed0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokensOwed1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("refundETH"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("refundETH"), - inputs: ::std::vec![], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Payable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("safeTransferFrom"), - ::std::vec![ - ::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("safeTransferFrom"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - }, - ::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("safeTransferFrom"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("data"), - kind: ::ethers::core::abi::ethabi::ParamType::Bytes, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "bytes" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - }, - ], - ), - ( - ::std::borrow::ToOwned::to_owned("setApprovalForAll"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("setApprovalForAll"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("operator"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("approved"), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("supportsInterface"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("supportsInterface"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("interfaceId"), - kind: ::ethers::core::abi::ethabi::ParamType::FixedBytes(4usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes4"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("sweepToken"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("sweepToken"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("token"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amountMinimum"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("recipient"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Payable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("symbol"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("symbol"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::String, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("string"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("tokenByIndex"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("tokenByIndex"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("index"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("tokenOfOwnerByIndex"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("tokenOfOwnerByIndex",), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("index"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("tokenURI"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("tokenURI"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::String, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("string"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("totalSupply"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("totalSupply"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("transferFrom"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("transferFrom"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("unwrapWETH9"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("unwrapWETH9"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amountMinimum"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("recipient"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Payable, - },], - ), - ]), - events: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("Approval"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Approval"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("approved"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: true, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("ApprovalForAll"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("ApprovalForAll"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("operator"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("approved"), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("Collect"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Collect"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("recipient"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("DecreaseLiquidity"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("DecreaseLiquidity"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("liquidity"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("IncreaseLiquidity"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("IncreaseLiquidity"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("liquidity"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("Transfer"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Transfer"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: true, - }, - ], - anonymous: false, - },], - ), - ]), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static INONFUNGIBLEPOSITIONMANAGER_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - pub struct INonfungiblePositionManager(::ethers::contract::Contract); - impl ::core::clone::Clone for INonfungiblePositionManager { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for INonfungiblePositionManager { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for INonfungiblePositionManager { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for INonfungiblePositionManager { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(INonfungiblePositionManager)) - .field(&self.address()) - .finish() - } - } - impl INonfungiblePositionManager { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - INONFUNGIBLEPOSITIONMANAGER_ABI.clone(), - client, - )) - } - ///Calls the contract's `DOMAIN_SEPARATOR` (0x3644e515) function - pub fn domain_separator(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([54, 68, 229, 21], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `PERMIT_TYPEHASH` (0x30adf81f) function - pub fn permit_typehash(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([48, 173, 248, 31], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `WETH9` (0x4aa4a4fc) function - pub fn weth9(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([74, 164, 164, 252], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `approve` (0x095ea7b3) function - pub fn approve( - &self, - to: ::ethers::core::types::Address, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([9, 94, 167, 179], (to, token_id)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `balanceOf` (0x70a08231) function - pub fn balance_of( - &self, - owner: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([112, 160, 130, 49], owner) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `burn` (0x42966c68) function - pub fn burn(&self, token_id: ::ethers::core::types::U256) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([66, 150, 108, 104], token_id) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `collect` (0xfc6f7865) function - pub fn collect( - &self, - params: CollectParams, - ) -> ::ethers::contract::builders::ContractCall - { - self.0 - .method_hash([252, 111, 120, 101], (params,)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `createAndInitializePoolIfNecessary` (0x13ead562) function - pub fn create_and_initialize_pool_if_necessary( - &self, - token_0: ::ethers::core::types::Address, - token_1: ::ethers::core::types::Address, - fee: u32, - sqrt_price_x96: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([19, 234, 213, 98], (token_0, token_1, fee, sqrt_price_x96)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `decreaseLiquidity` (0x0c49ccbe) function - pub fn decrease_liquidity( - &self, - params: DecreaseLiquidityParams, - ) -> ::ethers::contract::builders::ContractCall - { - self.0 - .method_hash([12, 73, 204, 190], (params,)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `factory` (0xc45a0155) function - pub fn factory(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([196, 90, 1, 85], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `getApproved` (0x081812fc) function - pub fn get_approved( - &self, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([8, 24, 18, 252], token_id) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `increaseLiquidity` (0x219f5d17) function - pub fn increase_liquidity( - &self, - params: IncreaseLiquidityParams, - ) -> ::ethers::contract::builders::ContractCall< - M, - (u128, ::ethers::core::types::U256, ::ethers::core::types::U256), - > { - self.0 - .method_hash([33, 159, 93, 23], (params,)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `isApprovedForAll` (0xe985e9c5) function - pub fn is_approved_for_all( - &self, - owner: ::ethers::core::types::Address, - operator: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([233, 133, 233, 197], (owner, operator)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `mint` (0x88316456) function - pub fn mint( - &self, - params: MintParams, - ) -> ::ethers::contract::builders::ContractCall< - M, - ( - ::ethers::core::types::U256, - u128, - ::ethers::core::types::U256, - ::ethers::core::types::U256, - ), - > { - self.0 - .method_hash([136, 49, 100, 86], (params,)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `name` (0x06fdde03) function - pub fn name(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([6, 253, 222, 3], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `ownerOf` (0x6352211e) function - pub fn owner_of( - &self, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([99, 82, 33, 30], token_id) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `permit` (0x7ac2ff7b) function - pub fn permit( - &self, - spender: ::ethers::core::types::Address, - token_id: ::ethers::core::types::U256, - deadline: ::ethers::core::types::U256, - v: u8, - r: [u8; 32], - s: [u8; 32], - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([122, 194, 255, 123], (spender, token_id, deadline, v, r, s)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `positions` (0x99fbab88) function - pub fn positions( - &self, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall< - M, - ( - u128, - ::ethers::core::types::Address, - ::ethers::core::types::Address, - ::ethers::core::types::Address, - u32, - i32, - i32, - u128, - ::ethers::core::types::U256, - ::ethers::core::types::U256, - u128, - u128, - ), - > { - self.0 - .method_hash([153, 251, 171, 136], token_id) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `refundETH` (0x12210e8a) function - pub fn refund_eth(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([18, 33, 14, 138], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `safeTransferFrom` (0x42842e0e) function - pub fn safe_transfer_from( - &self, - from: ::ethers::core::types::Address, - to: ::ethers::core::types::Address, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([66, 132, 46, 14], (from, to, token_id)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `safeTransferFrom` (0xb88d4fde) function - pub fn safe_transfer_from_with_from_and_to_and_data( - &self, - from: ::ethers::core::types::Address, - to: ::ethers::core::types::Address, - token_id: ::ethers::core::types::U256, - data: ::ethers::core::types::Bytes, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([184, 141, 79, 222], (from, to, token_id, data)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `setApprovalForAll` (0xa22cb465) function - pub fn set_approval_for_all( - &self, - operator: ::ethers::core::types::Address, - approved: bool, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([162, 44, 180, 101], (operator, approved)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `supportsInterface` (0x01ffc9a7) function - pub fn supports_interface(&self, interface_id: [u8; 4]) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([1, 255, 201, 167], interface_id) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `sweepToken` (0xdf2ab5bb) function - pub fn sweep_token( - &self, - token: ::ethers::core::types::Address, - amount_minimum: ::ethers::core::types::U256, - recipient: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([223, 42, 181, 187], (token, amount_minimum, recipient)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `symbol` (0x95d89b41) function - pub fn symbol(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([149, 216, 155, 65], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `tokenByIndex` (0x4f6ccce7) function - pub fn token_by_index( - &self, - index: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([79, 108, 204, 231], index) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `tokenOfOwnerByIndex` (0x2f745c59) function - pub fn token_of_owner_by_index( - &self, - owner: ::ethers::core::types::Address, - index: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([47, 116, 92, 89], (owner, index)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `tokenURI` (0xc87b56dd) function - pub fn token_uri( - &self, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([200, 123, 86, 221], token_id) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `totalSupply` (0x18160ddd) function - pub fn total_supply(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([24, 22, 13, 221], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `transferFrom` (0x23b872dd) function - pub fn transfer_from( - &self, - from: ::ethers::core::types::Address, - to: ::ethers::core::types::Address, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([35, 184, 114, 221], (from, to, token_id)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `unwrapWETH9` (0x49404b7c) function - pub fn unwrap_weth9( - &self, - amount_minimum: ::ethers::core::types::U256, - recipient: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([73, 64, 75, 124], (amount_minimum, recipient)) - .expect("method not found (this should never happen)") - } - ///Gets the contract's `Approval` event - pub fn approval_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, ApprovalFilter> { - self.0.event() - } - ///Gets the contract's `ApprovalForAll` event - pub fn approval_for_all_filter( - &self, - ) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, ApprovalForAllFilter> { - self.0.event() - } - ///Gets the contract's `Collect` event - pub fn collect_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, CollectFilter> { - self.0.event() - } - ///Gets the contract's `DecreaseLiquidity` event - pub fn decrease_liquidity_filter( - &self, - ) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, DecreaseLiquidityFilter> { - self.0.event() - } - ///Gets the contract's `IncreaseLiquidity` event - pub fn increase_liquidity_filter( - &self, - ) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, IncreaseLiquidityFilter> { - self.0.event() - } - ///Gets the contract's `Transfer` event - pub fn transfer_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, TransferFilter> { - self.0.event() - } - /// Returns an `Event` builder for all the events of this contract. - pub fn events( - &self, - ) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, INonfungiblePositionManagerEvents> { - self.0.event_with_filter(::core::default::Default::default()) - } - } - impl From<::ethers::contract::Contract> for INonfungiblePositionManager { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Approval", abi = "Approval(address,address,uint256)")] - pub struct ApprovalFilter { - #[ethevent(indexed)] - pub owner: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub approved: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub token_id: ::ethers::core::types::U256, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "ApprovalForAll", abi = "ApprovalForAll(address,address,bool)")] - pub struct ApprovalForAllFilter { - #[ethevent(indexed)] - pub owner: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub operator: ::ethers::core::types::Address, - pub approved: bool, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Collect", abi = "Collect(uint256,address,uint256,uint256)")] - pub struct CollectFilter { - #[ethevent(indexed)] - pub token_id: ::ethers::core::types::U256, - pub recipient: ::ethers::core::types::Address, - pub amount_0: ::ethers::core::types::U256, - pub amount_1: ::ethers::core::types::U256, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent( - name = "DecreaseLiquidity", - abi = "DecreaseLiquidity(uint256,uint128,uint256,uint256)" - )] - pub struct DecreaseLiquidityFilter { - #[ethevent(indexed)] - pub token_id: ::ethers::core::types::U256, - pub liquidity: u128, - pub amount_0: ::ethers::core::types::U256, - pub amount_1: ::ethers::core::types::U256, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent( - name = "IncreaseLiquidity", - abi = "IncreaseLiquidity(uint256,uint128,uint256,uint256)" - )] - pub struct IncreaseLiquidityFilter { - #[ethevent(indexed)] - pub token_id: ::ethers::core::types::U256, - pub liquidity: u128, - pub amount_0: ::ethers::core::types::U256, - pub amount_1: ::ethers::core::types::U256, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Transfer", abi = "Transfer(address,address,uint256)")] - pub struct TransferFilter { - #[ethevent(indexed)] - pub from: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub to: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all of the contract's events - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum INonfungiblePositionManagerEvents { - ApprovalFilter(ApprovalFilter), - ApprovalForAllFilter(ApprovalForAllFilter), - CollectFilter(CollectFilter), - DecreaseLiquidityFilter(DecreaseLiquidityFilter), - IncreaseLiquidityFilter(IncreaseLiquidityFilter), - TransferFilter(TransferFilter), - } - impl ::ethers::contract::EthLogDecode for INonfungiblePositionManagerEvents { - fn decode_log(log: &::ethers::core::abi::RawLog) -> ::core::result::Result { - if let Ok(decoded) = ApprovalFilter::decode_log(log) { - return Ok(INonfungiblePositionManagerEvents::ApprovalFilter(decoded)); - } - if let Ok(decoded) = ApprovalForAllFilter::decode_log(log) { - return Ok(INonfungiblePositionManagerEvents::ApprovalForAllFilter(decoded)); - } - if let Ok(decoded) = CollectFilter::decode_log(log) { - return Ok(INonfungiblePositionManagerEvents::CollectFilter(decoded)); - } - if let Ok(decoded) = DecreaseLiquidityFilter::decode_log(log) { - return Ok(INonfungiblePositionManagerEvents::DecreaseLiquidityFilter(decoded)); - } - if let Ok(decoded) = IncreaseLiquidityFilter::decode_log(log) { - return Ok(INonfungiblePositionManagerEvents::IncreaseLiquidityFilter(decoded)); - } - if let Ok(decoded) = TransferFilter::decode_log(log) { - return Ok(INonfungiblePositionManagerEvents::TransferFilter(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData) - } - } - impl ::core::fmt::Display for INonfungiblePositionManagerEvents { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::ApprovalFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::ApprovalForAllFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::CollectFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::DecreaseLiquidityFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::IncreaseLiquidityFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::TransferFilter(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for INonfungiblePositionManagerEvents { - fn from(value: ApprovalFilter) -> Self { - Self::ApprovalFilter(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerEvents { - fn from(value: ApprovalForAllFilter) -> Self { - Self::ApprovalForAllFilter(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerEvents { - fn from(value: CollectFilter) -> Self { - Self::CollectFilter(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerEvents { - fn from(value: DecreaseLiquidityFilter) -> Self { - Self::DecreaseLiquidityFilter(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerEvents { - fn from(value: IncreaseLiquidityFilter) -> Self { - Self::IncreaseLiquidityFilter(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerEvents { - fn from(value: TransferFilter) -> Self { - Self::TransferFilter(value) - } - } - ///Container type for all input parameters for the `DOMAIN_SEPARATOR` function with signature `DOMAIN_SEPARATOR()` and selector `0x3644e515` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "DOMAIN_SEPARATOR", abi = "DOMAIN_SEPARATOR()")] - pub struct DomainSeparatorCall; - ///Container type for all input parameters for the `PERMIT_TYPEHASH` function with signature `PERMIT_TYPEHASH()` and selector `0x30adf81f` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "PERMIT_TYPEHASH", abi = "PERMIT_TYPEHASH()")] - pub struct PermitTypehashCall; - ///Container type for all input parameters for the `WETH9` function with signature `WETH9()` and selector `0x4aa4a4fc` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "WETH9", abi = "WETH9()")] - pub struct Weth9Call; - ///Container type for all input parameters for the `approve` function with signature `approve(address,uint256)` and selector `0x095ea7b3` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "approve", abi = "approve(address,uint256)")] - pub struct ApproveCall { - pub to: ::ethers::core::types::Address, - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `balanceOf` function with signature `balanceOf(address)` and selector `0x70a08231` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "balanceOf", abi = "balanceOf(address)")] - pub struct BalanceOfCall { - pub owner: ::ethers::core::types::Address, - } - ///Container type for all input parameters for the `burn` function with signature `burn(uint256)` and selector `0x42966c68` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "burn", abi = "burn(uint256)")] - pub struct BurnCall { - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `collect` function with signature `collect((uint256,address,uint128,uint128))` and selector `0xfc6f7865` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "collect", abi = "collect((uint256,address,uint128,uint128))")] - pub struct CollectCall { - pub params: CollectParams, - } - ///Container type for all input parameters for the `createAndInitializePoolIfNecessary` function with signature `createAndInitializePoolIfNecessary(address,address,uint24,uint160)` and selector `0x13ead562` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall( - name = "createAndInitializePoolIfNecessary", - abi = "createAndInitializePoolIfNecessary(address,address,uint24,uint160)" - )] - pub struct CreateAndInitializePoolIfNecessaryCall { - pub token_0: ::ethers::core::types::Address, - pub token_1: ::ethers::core::types::Address, - pub fee: u32, - pub sqrt_price_x96: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `decreaseLiquidity` function with signature `decreaseLiquidity((uint256,uint128,uint256,uint256,uint256))` and selector `0x0c49ccbe` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall( - name = "decreaseLiquidity", - abi = "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256))" - )] - pub struct DecreaseLiquidityCall { - pub params: DecreaseLiquidityParams, - } - ///Container type for all input parameters for the `factory` function with signature `factory()` and selector `0xc45a0155` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "factory", abi = "factory()")] - pub struct FactoryCall; - ///Container type for all input parameters for the `getApproved` function with signature `getApproved(uint256)` and selector `0x081812fc` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "getApproved", abi = "getApproved(uint256)")] - pub struct GetApprovedCall { - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `increaseLiquidity` function with signature `increaseLiquidity((uint256,uint256,uint256,uint256,uint256,uint256))` and selector `0x219f5d17` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall( - name = "increaseLiquidity", - abi = "increaseLiquidity((uint256,uint256,uint256,uint256,uint256,uint256))" - )] - pub struct IncreaseLiquidityCall { - pub params: IncreaseLiquidityParams, - } - ///Container type for all input parameters for the `isApprovedForAll` function with signature `isApprovedForAll(address,address)` and selector `0xe985e9c5` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "isApprovedForAll", abi = "isApprovedForAll(address,address)")] - pub struct IsApprovedForAllCall { - pub owner: ::ethers::core::types::Address, - pub operator: ::ethers::core::types::Address, - } - ///Container type for all input parameters for the `mint` function with signature `mint((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256))` and selector `0x88316456` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall( - name = "mint", - abi = "mint((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256))" - )] - pub struct MintCall { - pub params: MintParams, - } - ///Container type for all input parameters for the `name` function with signature `name()` and selector `0x06fdde03` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "name", abi = "name()")] - pub struct NameCall; - ///Container type for all input parameters for the `ownerOf` function with signature `ownerOf(uint256)` and selector `0x6352211e` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "ownerOf", abi = "ownerOf(uint256)")] - pub struct OwnerOfCall { - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `permit` function with signature `permit(address,uint256,uint256,uint8,bytes32,bytes32)` and selector `0x7ac2ff7b` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "permit", abi = "permit(address,uint256,uint256,uint8,bytes32,bytes32)")] - pub struct PermitCall { - pub spender: ::ethers::core::types::Address, - pub token_id: ::ethers::core::types::U256, - pub deadline: ::ethers::core::types::U256, - pub v: u8, - pub r: [u8; 32], - pub s: [u8; 32], - } - ///Container type for all input parameters for the `positions` function with signature `positions(uint256)` and selector `0x99fbab88` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "positions", abi = "positions(uint256)")] - pub struct PositionsCall { - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `refundETH` function with signature `refundETH()` and selector `0x12210e8a` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "refundETH", abi = "refundETH()")] - pub struct RefundETHCall; - ///Container type for all input parameters for the `safeTransferFrom` function with signature `safeTransferFrom(address,address,uint256)` and selector `0x42842e0e` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "safeTransferFrom", abi = "safeTransferFrom(address,address,uint256)")] - pub struct SafeTransferFromCall { - pub from: ::ethers::core::types::Address, - pub to: ::ethers::core::types::Address, - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `safeTransferFrom` function with signature `safeTransferFrom(address,address,uint256,bytes)` and selector `0xb88d4fde` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "safeTransferFrom", abi = "safeTransferFrom(address,address,uint256,bytes)")] - pub struct SafeTransferFromWithFromAndToAndDataCall { - pub from: ::ethers::core::types::Address, - pub to: ::ethers::core::types::Address, - pub token_id: ::ethers::core::types::U256, - pub data: ::ethers::core::types::Bytes, - } - ///Container type for all input parameters for the `setApprovalForAll` function with signature `setApprovalForAll(address,bool)` and selector `0xa22cb465` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "setApprovalForAll", abi = "setApprovalForAll(address,bool)")] - pub struct SetApprovalForAllCall { - pub operator: ::ethers::core::types::Address, - pub approved: bool, - } - ///Container type for all input parameters for the `supportsInterface` function with signature `supportsInterface(bytes4)` and selector `0x01ffc9a7` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "supportsInterface", abi = "supportsInterface(bytes4)")] - pub struct SupportsInterfaceCall { - pub interface_id: [u8; 4], - } - ///Container type for all input parameters for the `sweepToken` function with signature `sweepToken(address,uint256,address)` and selector `0xdf2ab5bb` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "sweepToken", abi = "sweepToken(address,uint256,address)")] - pub struct SweepTokenCall { - pub token: ::ethers::core::types::Address, - pub amount_minimum: ::ethers::core::types::U256, - pub recipient: ::ethers::core::types::Address, - } - ///Container type for all input parameters for the `symbol` function with signature `symbol()` and selector `0x95d89b41` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "symbol", abi = "symbol()")] - pub struct SymbolCall; - ///Container type for all input parameters for the `tokenByIndex` function with signature `tokenByIndex(uint256)` and selector `0x4f6ccce7` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "tokenByIndex", abi = "tokenByIndex(uint256)")] - pub struct TokenByIndexCall { - pub index: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `tokenOfOwnerByIndex` function with signature `tokenOfOwnerByIndex(address,uint256)` and selector `0x2f745c59` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "tokenOfOwnerByIndex", abi = "tokenOfOwnerByIndex(address,uint256)")] - pub struct TokenOfOwnerByIndexCall { - pub owner: ::ethers::core::types::Address, - pub index: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `tokenURI` function with signature `tokenURI(uint256)` and selector `0xc87b56dd` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "tokenURI", abi = "tokenURI(uint256)")] - pub struct TokenURICall { - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `totalSupply` function with signature `totalSupply()` and selector `0x18160ddd` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "totalSupply", abi = "totalSupply()")] - pub struct TotalSupplyCall; - ///Container type for all input parameters for the `transferFrom` function with signature `transferFrom(address,address,uint256)` and selector `0x23b872dd` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "transferFrom", abi = "transferFrom(address,address,uint256)")] - pub struct TransferFromCall { - pub from: ::ethers::core::types::Address, - pub to: ::ethers::core::types::Address, - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `unwrapWETH9` function with signature `unwrapWETH9(uint256,address)` and selector `0x49404b7c` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "unwrapWETH9", abi = "unwrapWETH9(uint256,address)")] - pub struct UnwrapWETH9Call { - pub amount_minimum: ::ethers::core::types::U256, - pub recipient: ::ethers::core::types::Address, - } - ///Container type for all of the contract's call - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum INonfungiblePositionManagerCalls { - DomainSeparator(DomainSeparatorCall), - PermitTypehash(PermitTypehashCall), - Weth9(Weth9Call), - Approve(ApproveCall), - BalanceOf(BalanceOfCall), - Burn(BurnCall), - Collect(CollectCall), - CreateAndInitializePoolIfNecessary(CreateAndInitializePoolIfNecessaryCall), - DecreaseLiquidity(DecreaseLiquidityCall), - Factory(FactoryCall), - GetApproved(GetApprovedCall), - IncreaseLiquidity(IncreaseLiquidityCall), - IsApprovedForAll(IsApprovedForAllCall), - Mint(MintCall), - Name(NameCall), - OwnerOf(OwnerOfCall), - Permit(PermitCall), - Positions(PositionsCall), - RefundETH(RefundETHCall), - SafeTransferFrom(SafeTransferFromCall), - SafeTransferFromWithFromAndToAndData(SafeTransferFromWithFromAndToAndDataCall), - SetApprovalForAll(SetApprovalForAllCall), - SupportsInterface(SupportsInterfaceCall), - SweepToken(SweepTokenCall), - Symbol(SymbolCall), - TokenByIndex(TokenByIndexCall), - TokenOfOwnerByIndex(TokenOfOwnerByIndexCall), - TokenURI(TokenURICall), - TotalSupply(TotalSupplyCall), - TransferFrom(TransferFromCall), - UnwrapWETH9(UnwrapWETH9Call), - } - impl ::ethers::core::abi::AbiDecode for INonfungiblePositionManagerCalls { - fn decode(data: impl AsRef<[u8]>) -> ::core::result::Result { - let data = data.as_ref(); - if let Ok(decoded) = ::decode(data) { - return Ok(Self::DomainSeparator(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::PermitTypehash(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Weth9(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Approve(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::BalanceOf(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Burn(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Collect(decoded)); - } - if let Ok(decoded) = - ::decode(data) - { - return Ok(Self::CreateAndInitializePoolIfNecessary(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::DecreaseLiquidity(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Factory(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::GetApproved(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::IncreaseLiquidity(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::IsApprovedForAll(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Mint(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Name(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::OwnerOf(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Permit(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Positions(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::RefundETH(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SafeTransferFrom(decoded)); - } - if let Ok(decoded) = - ::decode(data) - { - return Ok(Self::SafeTransferFromWithFromAndToAndData(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SetApprovalForAll(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SupportsInterface(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SweepToken(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Symbol(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TokenByIndex(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TokenOfOwnerByIndex(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TokenURI(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TotalSupply(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TransferFrom(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::UnwrapWETH9(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData.into()) - } - } - impl ::ethers::core::abi::AbiEncode for INonfungiblePositionManagerCalls { - fn encode(self) -> Vec { - match self { - Self::DomainSeparator(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::PermitTypehash(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Weth9(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Approve(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::BalanceOf(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Burn(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Collect(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::CreateAndInitializePoolIfNecessary(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::DecreaseLiquidity(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Factory(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::GetApproved(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::IncreaseLiquidity(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::IsApprovedForAll(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Mint(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Name(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::OwnerOf(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Permit(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Positions(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::RefundETH(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SafeTransferFrom(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SafeTransferFromWithFromAndToAndData(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SetApprovalForAll(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SupportsInterface(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SweepToken(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Symbol(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TokenByIndex(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TokenOfOwnerByIndex(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TokenURI(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TotalSupply(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TransferFrom(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::UnwrapWETH9(element) => ::ethers::core::abi::AbiEncode::encode(element), - } - } - } - impl ::core::fmt::Display for INonfungiblePositionManagerCalls { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::DomainSeparator(element) => ::core::fmt::Display::fmt(element, f), - Self::PermitTypehash(element) => ::core::fmt::Display::fmt(element, f), - Self::Weth9(element) => ::core::fmt::Display::fmt(element, f), - Self::Approve(element) => ::core::fmt::Display::fmt(element, f), - Self::BalanceOf(element) => ::core::fmt::Display::fmt(element, f), - Self::Burn(element) => ::core::fmt::Display::fmt(element, f), - Self::Collect(element) => ::core::fmt::Display::fmt(element, f), - Self::CreateAndInitializePoolIfNecessary(element) => ::core::fmt::Display::fmt(element, f), - Self::DecreaseLiquidity(element) => ::core::fmt::Display::fmt(element, f), - Self::Factory(element) => ::core::fmt::Display::fmt(element, f), - Self::GetApproved(element) => ::core::fmt::Display::fmt(element, f), - Self::IncreaseLiquidity(element) => ::core::fmt::Display::fmt(element, f), - Self::IsApprovedForAll(element) => ::core::fmt::Display::fmt(element, f), - Self::Mint(element) => ::core::fmt::Display::fmt(element, f), - Self::Name(element) => ::core::fmt::Display::fmt(element, f), - Self::OwnerOf(element) => ::core::fmt::Display::fmt(element, f), - Self::Permit(element) => ::core::fmt::Display::fmt(element, f), - Self::Positions(element) => ::core::fmt::Display::fmt(element, f), - Self::RefundETH(element) => ::core::fmt::Display::fmt(element, f), - Self::SafeTransferFrom(element) => ::core::fmt::Display::fmt(element, f), - Self::SafeTransferFromWithFromAndToAndData(element) => ::core::fmt::Display::fmt(element, f), - Self::SetApprovalForAll(element) => ::core::fmt::Display::fmt(element, f), - Self::SupportsInterface(element) => ::core::fmt::Display::fmt(element, f), - Self::SweepToken(element) => ::core::fmt::Display::fmt(element, f), - Self::Symbol(element) => ::core::fmt::Display::fmt(element, f), - Self::TokenByIndex(element) => ::core::fmt::Display::fmt(element, f), - Self::TokenOfOwnerByIndex(element) => ::core::fmt::Display::fmt(element, f), - Self::TokenURI(element) => ::core::fmt::Display::fmt(element, f), - Self::TotalSupply(element) => ::core::fmt::Display::fmt(element, f), - Self::TransferFrom(element) => ::core::fmt::Display::fmt(element, f), - Self::UnwrapWETH9(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: DomainSeparatorCall) -> Self { - Self::DomainSeparator(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: PermitTypehashCall) -> Self { - Self::PermitTypehash(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: Weth9Call) -> Self { - Self::Weth9(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: ApproveCall) -> Self { - Self::Approve(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: BalanceOfCall) -> Self { - Self::BalanceOf(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: BurnCall) -> Self { - Self::Burn(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: CollectCall) -> Self { - Self::Collect(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: CreateAndInitializePoolIfNecessaryCall) -> Self { - Self::CreateAndInitializePoolIfNecessary(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: DecreaseLiquidityCall) -> Self { - Self::DecreaseLiquidity(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: FactoryCall) -> Self { - Self::Factory(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: GetApprovedCall) -> Self { - Self::GetApproved(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: IncreaseLiquidityCall) -> Self { - Self::IncreaseLiquidity(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: IsApprovedForAllCall) -> Self { - Self::IsApprovedForAll(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: MintCall) -> Self { - Self::Mint(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: NameCall) -> Self { - Self::Name(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: OwnerOfCall) -> Self { - Self::OwnerOf(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: PermitCall) -> Self { - Self::Permit(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: PositionsCall) -> Self { - Self::Positions(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: RefundETHCall) -> Self { - Self::RefundETH(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: SafeTransferFromCall) -> Self { - Self::SafeTransferFrom(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: SafeTransferFromWithFromAndToAndDataCall) -> Self { - Self::SafeTransferFromWithFromAndToAndData(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: SetApprovalForAllCall) -> Self { - Self::SetApprovalForAll(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: SupportsInterfaceCall) -> Self { - Self::SupportsInterface(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: SweepTokenCall) -> Self { - Self::SweepToken(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: SymbolCall) -> Self { - Self::Symbol(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: TokenByIndexCall) -> Self { - Self::TokenByIndex(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: TokenOfOwnerByIndexCall) -> Self { - Self::TokenOfOwnerByIndex(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: TokenURICall) -> Self { - Self::TokenURI(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: TotalSupplyCall) -> Self { - Self::TotalSupply(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: TransferFromCall) -> Self { - Self::TransferFrom(value) - } - } - impl ::core::convert::From for INonfungiblePositionManagerCalls { - fn from(value: UnwrapWETH9Call) -> Self { - Self::UnwrapWETH9(value) - } - } - ///Container type for all return fields from the `DOMAIN_SEPARATOR` function with signature `DOMAIN_SEPARATOR()` and selector `0x3644e515` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct DomainSeparatorReturn(pub [u8; 32]); - ///Container type for all return fields from the `PERMIT_TYPEHASH` function with signature `PERMIT_TYPEHASH()` and selector `0x30adf81f` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct PermitTypehashReturn(pub [u8; 32]); - ///Container type for all return fields from the `WETH9` function with signature `WETH9()` and selector `0x4aa4a4fc` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct Weth9Return(pub ::ethers::core::types::Address); - ///Container type for all return fields from the `balanceOf` function with signature `balanceOf(address)` and selector `0x70a08231` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct BalanceOfReturn { - pub balance: ::ethers::core::types::U256, - } - ///Container type for all return fields from the `collect` function with signature `collect((uint256,address,uint128,uint128))` and selector `0xfc6f7865` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct CollectReturn { - pub amount_0: ::ethers::core::types::U256, - pub amount_1: ::ethers::core::types::U256, - } - ///Container type for all return fields from the `createAndInitializePoolIfNecessary` function with signature `createAndInitializePoolIfNecessary(address,address,uint24,uint160)` and selector `0x13ead562` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct CreateAndInitializePoolIfNecessaryReturn { - pub pool: ::ethers::core::types::Address, - } - ///Container type for all return fields from the `decreaseLiquidity` function with signature `decreaseLiquidity((uint256,uint128,uint256,uint256,uint256))` and selector `0x0c49ccbe` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct DecreaseLiquidityReturn { - pub amount_0: ::ethers::core::types::U256, - pub amount_1: ::ethers::core::types::U256, - } - ///Container type for all return fields from the `factory` function with signature `factory()` and selector `0xc45a0155` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct FactoryReturn(pub ::ethers::core::types::Address); - ///Container type for all return fields from the `getApproved` function with signature `getApproved(uint256)` and selector `0x081812fc` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct GetApprovedReturn { - pub operator: ::ethers::core::types::Address, - } - ///Container type for all return fields from the `increaseLiquidity` function with signature `increaseLiquidity((uint256,uint256,uint256,uint256,uint256,uint256))` and selector `0x219f5d17` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct IncreaseLiquidityReturn { - pub liquidity: u128, - pub amount_0: ::ethers::core::types::U256, - pub amount_1: ::ethers::core::types::U256, - } - ///Container type for all return fields from the `isApprovedForAll` function with signature `isApprovedForAll(address,address)` and selector `0xe985e9c5` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct IsApprovedForAllReturn(pub bool); - ///Container type for all return fields from the `mint` function with signature `mint((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256))` and selector `0x88316456` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct MintReturn { - pub token_id: ::ethers::core::types::U256, - pub liquidity: u128, - pub amount_0: ::ethers::core::types::U256, - pub amount_1: ::ethers::core::types::U256, - } - ///Container type for all return fields from the `name` function with signature `name()` and selector `0x06fdde03` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct NameReturn(pub ::std::string::String); - ///Container type for all return fields from the `ownerOf` function with signature `ownerOf(uint256)` and selector `0x6352211e` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct OwnerOfReturn { - pub owner: ::ethers::core::types::Address, - } - ///Container type for all return fields from the `positions` function with signature `positions(uint256)` and selector `0x99fbab88` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct PositionsReturn { - pub nonce: u128, - pub operator: ::ethers::core::types::Address, - pub token_0: ::ethers::core::types::Address, - pub token_1: ::ethers::core::types::Address, - pub fee: u32, - pub tick_lower: i32, - pub tick_upper: i32, - pub liquidity: u128, - pub fee_growth_inside_0_last_x128: ::ethers::core::types::U256, - pub fee_growth_inside_1_last_x128: ::ethers::core::types::U256, - pub tokens_owed_0: u128, - pub tokens_owed_1: u128, - } - ///Container type for all return fields from the `supportsInterface` function with signature `supportsInterface(bytes4)` and selector `0x01ffc9a7` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct SupportsInterfaceReturn(pub bool); - ///Container type for all return fields from the `symbol` function with signature `symbol()` and selector `0x95d89b41` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct SymbolReturn(pub ::std::string::String); - ///Container type for all return fields from the `tokenByIndex` function with signature `tokenByIndex(uint256)` and selector `0x4f6ccce7` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct TokenByIndexReturn(pub ::ethers::core::types::U256); - ///Container type for all return fields from the `tokenOfOwnerByIndex` function with signature `tokenOfOwnerByIndex(address,uint256)` and selector `0x2f745c59` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct TokenOfOwnerByIndexReturn(pub ::ethers::core::types::U256); - ///Container type for all return fields from the `tokenURI` function with signature `tokenURI(uint256)` and selector `0xc87b56dd` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct TokenURIReturn(pub ::std::string::String); - ///Container type for all return fields from the `totalSupply` function with signature `totalSupply()` and selector `0x18160ddd` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct TotalSupplyReturn(pub ::ethers::core::types::U256); - ///`CollectParams(uint256,address,uint128,uint128)` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct CollectParams { - pub token_id: ::ethers::core::types::U256, - pub recipient: ::ethers::core::types::Address, - pub amount_0_max: u128, - pub amount_1_max: u128, - } - ///`DecreaseLiquidityParams(uint256,uint128,uint256,uint256,uint256)` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct DecreaseLiquidityParams { - pub token_id: ::ethers::core::types::U256, - pub liquidity: u128, - pub amount_0_min: ::ethers::core::types::U256, - pub amount_1_min: ::ethers::core::types::U256, - pub deadline: ::ethers::core::types::U256, - } - ///`IncreaseLiquidityParams(uint256,uint256,uint256,uint256,uint256,uint256)` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct IncreaseLiquidityParams { - pub token_id: ::ethers::core::types::U256, - pub amount_0_desired: ::ethers::core::types::U256, - pub amount_1_desired: ::ethers::core::types::U256, - pub amount_0_min: ::ethers::core::types::U256, - pub amount_1_min: ::ethers::core::types::U256, - pub deadline: ::ethers::core::types::U256, - } - ///`MintParams(address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256)` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct MintParams { - pub token_0: ::ethers::core::types::Address, - pub token_1: ::ethers::core::types::Address, - pub fee: u32, - pub tick_lower: i32, - pub tick_upper: i32, - pub amount_0_desired: ::ethers::core::types::U256, - pub amount_1_desired: ::ethers::core::types::U256, - pub amount_0_min: ::ethers::core::types::U256, - pub amount_1_min: ::ethers::core::types::U256, - pub recipient: ::ethers::core::types::Address, - pub deadline: ::ethers::core::types::U256, - } -} diff --git a/src/bindings/i_periphery_immutable_state.rs b/src/bindings/i_periphery_immutable_state.rs deleted file mode 100644 index 08b295f..0000000 --- a/src/bindings/i_periphery_immutable_state.rs +++ /dev/null @@ -1,212 +0,0 @@ -pub use i_periphery_immutable_state::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod i_periphery_immutable_state { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("WETH9"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("WETH9"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("factory"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("factory"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ]), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static IPERIPHERYIMMUTABLESTATE_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - pub struct IPeripheryImmutableState(::ethers::contract::Contract); - impl ::core::clone::Clone for IPeripheryImmutableState { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for IPeripheryImmutableState { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for IPeripheryImmutableState { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for IPeripheryImmutableState { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(IPeripheryImmutableState)) - .field(&self.address()) - .finish() - } - } - impl IPeripheryImmutableState { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - IPERIPHERYIMMUTABLESTATE_ABI.clone(), - client, - )) - } - ///Calls the contract's `WETH9` (0x4aa4a4fc) function - pub fn weth9(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([74, 164, 164, 252], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `factory` (0xc45a0155) function - pub fn factory(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([196, 90, 1, 85], ()) - .expect("method not found (this should never happen)") - } - } - impl From<::ethers::contract::Contract> for IPeripheryImmutableState { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Container type for all input parameters for the `WETH9` function with signature `WETH9()` and selector `0x4aa4a4fc` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "WETH9", abi = "WETH9()")] - pub struct Weth9Call; - ///Container type for all input parameters for the `factory` function with signature `factory()` and selector `0xc45a0155` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "factory", abi = "factory()")] - pub struct FactoryCall; - ///Container type for all of the contract's call - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum IPeripheryImmutableStateCalls { - Weth9(Weth9Call), - Factory(FactoryCall), - } - impl ::ethers::core::abi::AbiDecode for IPeripheryImmutableStateCalls { - fn decode(data: impl AsRef<[u8]>) -> ::core::result::Result { - let data = data.as_ref(); - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Weth9(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Factory(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData.into()) - } - } - impl ::ethers::core::abi::AbiEncode for IPeripheryImmutableStateCalls { - fn encode(self) -> Vec { - match self { - Self::Weth9(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Factory(element) => ::ethers::core::abi::AbiEncode::encode(element), - } - } - } - impl ::core::fmt::Display for IPeripheryImmutableStateCalls { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::Weth9(element) => ::core::fmt::Display::fmt(element, f), - Self::Factory(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for IPeripheryImmutableStateCalls { - fn from(value: Weth9Call) -> Self { - Self::Weth9(value) - } - } - impl ::core::convert::From for IPeripheryImmutableStateCalls { - fn from(value: FactoryCall) -> Self { - Self::Factory(value) - } - } - ///Container type for all return fields from the `WETH9` function with signature `WETH9()` and selector `0x4aa4a4fc` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct Weth9Return(pub ::ethers::core::types::Address); - ///Container type for all return fields from the `factory` function with signature `factory()` and selector `0xc45a0155` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct FactoryReturn(pub ::ethers::core::types::Address); -} diff --git a/src/bindings/i_periphery_payments.rs b/src/bindings/i_periphery_payments.rs deleted file mode 100644 index 9fd00db..0000000 --- a/src/bindings/i_periphery_payments.rs +++ /dev/null @@ -1,271 +0,0 @@ -pub use i_periphery_payments::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod i_periphery_payments { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("refundETH"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("refundETH"), - inputs: ::std::vec![], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Payable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("sweepToken"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("sweepToken"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("token"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amountMinimum"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("recipient"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Payable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("unwrapWETH9"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("unwrapWETH9"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amountMinimum"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("recipient"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Payable, - },], - ), - ]), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static IPERIPHERYPAYMENTS_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - pub struct IPeripheryPayments(::ethers::contract::Contract); - impl ::core::clone::Clone for IPeripheryPayments { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for IPeripheryPayments { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for IPeripheryPayments { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for IPeripheryPayments { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(IPeripheryPayments)) - .field(&self.address()) - .finish() - } - } - impl IPeripheryPayments { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - IPERIPHERYPAYMENTS_ABI.clone(), - client, - )) - } - ///Calls the contract's `refundETH` (0x12210e8a) function - pub fn refund_eth(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([18, 33, 14, 138], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `sweepToken` (0xdf2ab5bb) function - pub fn sweep_token( - &self, - token: ::ethers::core::types::Address, - amount_minimum: ::ethers::core::types::U256, - recipient: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([223, 42, 181, 187], (token, amount_minimum, recipient)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `unwrapWETH9` (0x49404b7c) function - pub fn unwrap_weth9( - &self, - amount_minimum: ::ethers::core::types::U256, - recipient: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([73, 64, 75, 124], (amount_minimum, recipient)) - .expect("method not found (this should never happen)") - } - } - impl From<::ethers::contract::Contract> for IPeripheryPayments { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Container type for all input parameters for the `refundETH` function with signature `refundETH()` and selector `0x12210e8a` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "refundETH", abi = "refundETH()")] - pub struct RefundETHCall; - ///Container type for all input parameters for the `sweepToken` function with signature `sweepToken(address,uint256,address)` and selector `0xdf2ab5bb` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "sweepToken", abi = "sweepToken(address,uint256,address)")] - pub struct SweepTokenCall { - pub token: ::ethers::core::types::Address, - pub amount_minimum: ::ethers::core::types::U256, - pub recipient: ::ethers::core::types::Address, - } - ///Container type for all input parameters for the `unwrapWETH9` function with signature `unwrapWETH9(uint256,address)` and selector `0x49404b7c` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "unwrapWETH9", abi = "unwrapWETH9(uint256,address)")] - pub struct UnwrapWETH9Call { - pub amount_minimum: ::ethers::core::types::U256, - pub recipient: ::ethers::core::types::Address, - } - ///Container type for all of the contract's call - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum IPeripheryPaymentsCalls { - RefundETH(RefundETHCall), - SweepToken(SweepTokenCall), - UnwrapWETH9(UnwrapWETH9Call), - } - impl ::ethers::core::abi::AbiDecode for IPeripheryPaymentsCalls { - fn decode(data: impl AsRef<[u8]>) -> ::core::result::Result { - let data = data.as_ref(); - if let Ok(decoded) = ::decode(data) { - return Ok(Self::RefundETH(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SweepToken(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::UnwrapWETH9(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData.into()) - } - } - impl ::ethers::core::abi::AbiEncode for IPeripheryPaymentsCalls { - fn encode(self) -> Vec { - match self { - Self::RefundETH(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SweepToken(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::UnwrapWETH9(element) => ::ethers::core::abi::AbiEncode::encode(element), - } - } - } - impl ::core::fmt::Display for IPeripheryPaymentsCalls { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::RefundETH(element) => ::core::fmt::Display::fmt(element, f), - Self::SweepToken(element) => ::core::fmt::Display::fmt(element, f), - Self::UnwrapWETH9(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for IPeripheryPaymentsCalls { - fn from(value: RefundETHCall) -> Self { - Self::RefundETH(value) - } - } - impl ::core::convert::From for IPeripheryPaymentsCalls { - fn from(value: SweepTokenCall) -> Self { - Self::SweepToken(value) - } - } - impl ::core::convert::From for IPeripheryPaymentsCalls { - fn from(value: UnwrapWETH9Call) -> Self { - Self::UnwrapWETH9(value) - } - } -} diff --git a/src/bindings/i_pool_initializer.rs b/src/bindings/i_pool_initializer.rs deleted file mode 100644 index 2ac78ab..0000000 --- a/src/bindings/i_pool_initializer.rs +++ /dev/null @@ -1,152 +0,0 @@ -pub use i_pool_initializer::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod i_pool_initializer { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([( - ::std::borrow::ToOwned::to_owned("createAndInitializePoolIfNecessary"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("createAndInitializePoolIfNecessary",), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("token0"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("token1"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("fee"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("sqrtPriceX96"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(160usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint160"),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("pool"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Payable, - },], - )]), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static IPOOLINITIALIZER_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - pub struct IPoolInitializer(::ethers::contract::Contract); - impl ::core::clone::Clone for IPoolInitializer { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for IPoolInitializer { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for IPoolInitializer { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for IPoolInitializer { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(IPoolInitializer)) - .field(&self.address()) - .finish() - } - } - impl IPoolInitializer { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - IPOOLINITIALIZER_ABI.clone(), - client, - )) - } - ///Calls the contract's `createAndInitializePoolIfNecessary` (0x13ead562) function - pub fn create_and_initialize_pool_if_necessary( - &self, - token_0: ::ethers::core::types::Address, - token_1: ::ethers::core::types::Address, - fee: u32, - sqrt_price_x96: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([19, 234, 213, 98], (token_0, token_1, fee, sqrt_price_x96)) - .expect("method not found (this should never happen)") - } - } - impl From<::ethers::contract::Contract> for IPoolInitializer { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Container type for all input parameters for the `createAndInitializePoolIfNecessary` function with signature `createAndInitializePoolIfNecessary(address,address,uint24,uint160)` and selector `0x13ead562` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall( - name = "createAndInitializePoolIfNecessary", - abi = "createAndInitializePoolIfNecessary(address,address,uint24,uint160)" - )] - pub struct CreateAndInitializePoolIfNecessaryCall { - pub token_0: ::ethers::core::types::Address, - pub token_1: ::ethers::core::types::Address, - pub fee: u32, - pub sqrt_price_x96: ::ethers::core::types::U256, - } - ///Container type for all return fields from the `createAndInitializePoolIfNecessary` function with signature `createAndInitializePoolIfNecessary(address,address,uint24,uint160)` and selector `0x13ead562` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct CreateAndInitializePoolIfNecessaryReturn { - pub pool: ::ethers::core::types::Address, - } -} diff --git a/src/bindings/i_uniswap_v3_factory.rs b/src/bindings/i_uniswap_v3_factory.rs deleted file mode 100644 index e4cb627..0000000 --- a/src/bindings/i_uniswap_v3_factory.rs +++ /dev/null @@ -1,714 +0,0 @@ -pub use i_uniswap_v3_factory::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod i_uniswap_v3_factory { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("createPool"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("createPool"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenA"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenB"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("fee"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint24"),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("pool"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("enableFeeAmount"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("enableFeeAmount"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("fee"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickSpacing"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("feeAmountTickSpacing"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("feeAmountTickSpacing",), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("fee"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint24"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("getPool"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("getPool"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenA"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenB"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("fee"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint24"),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("pool"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("owner"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("owner"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("setOwner"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("setOwner"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("_owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ]), - events: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("FeeAmountEnabled"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("FeeAmountEnabled"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("fee"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(24usize), - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tickSpacing"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - indexed: true, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("OwnerChanged"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("OwnerChanged"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("oldOwner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("newOwner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("PoolCreated"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("PoolCreated"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("token0"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("token1"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("fee"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(24usize), - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tickSpacing"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("pool"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: false, - }, - ], - anonymous: false, - },], - ), - ]), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static IUNISWAPV3FACTORY_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - pub struct IUniswapV3Factory(::ethers::contract::Contract); - impl ::core::clone::Clone for IUniswapV3Factory { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for IUniswapV3Factory { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for IUniswapV3Factory { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for IUniswapV3Factory { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(IUniswapV3Factory)) - .field(&self.address()) - .finish() - } - } - impl IUniswapV3Factory { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - IUNISWAPV3FACTORY_ABI.clone(), - client, - )) - } - ///Calls the contract's `createPool` (0xa1671295) function - pub fn create_pool( - &self, - token_a: ::ethers::core::types::Address, - token_b: ::ethers::core::types::Address, - fee: u32, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([161, 103, 18, 149], (token_a, token_b, fee)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `enableFeeAmount` (0x8a7c195f) function - pub fn enable_fee_amount( - &self, - fee: u32, - tick_spacing: i32, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([138, 124, 25, 95], (fee, tick_spacing)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `feeAmountTickSpacing` (0x22afcccb) function - pub fn fee_amount_tick_spacing(&self, fee: u32) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([34, 175, 204, 203], fee) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `getPool` (0x1698ee82) function - pub fn get_pool( - &self, - token_a: ::ethers::core::types::Address, - token_b: ::ethers::core::types::Address, - fee: u32, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([22, 152, 238, 130], (token_a, token_b, fee)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `owner` (0x8da5cb5b) function - pub fn owner(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([141, 165, 203, 91], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `setOwner` (0x13af4035) function - pub fn set_owner( - &self, - owner: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([19, 175, 64, 53], owner) - .expect("method not found (this should never happen)") - } - ///Gets the contract's `FeeAmountEnabled` event - pub fn fee_amount_enabled_filter( - &self, - ) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, FeeAmountEnabledFilter> { - self.0.event() - } - ///Gets the contract's `OwnerChanged` event - pub fn owner_changed_filter( - &self, - ) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, OwnerChangedFilter> { - self.0.event() - } - ///Gets the contract's `PoolCreated` event - pub fn pool_created_filter( - &self, - ) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, PoolCreatedFilter> { - self.0.event() - } - /// Returns an `Event` builder for all the events of this contract. - pub fn events(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, IUniswapV3FactoryEvents> { - self.0.event_with_filter(::core::default::Default::default()) - } - } - impl From<::ethers::contract::Contract> for IUniswapV3Factory { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "FeeAmountEnabled", abi = "FeeAmountEnabled(uint24,int24)")] - pub struct FeeAmountEnabledFilter { - #[ethevent(indexed)] - pub fee: u32, - #[ethevent(indexed)] - pub tick_spacing: i32, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "OwnerChanged", abi = "OwnerChanged(address,address)")] - pub struct OwnerChangedFilter { - #[ethevent(indexed)] - pub old_owner: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub new_owner: ::ethers::core::types::Address, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "PoolCreated", abi = "PoolCreated(address,address,uint24,int24,address)")] - pub struct PoolCreatedFilter { - #[ethevent(indexed)] - pub token_0: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub token_1: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub fee: u32, - pub tick_spacing: i32, - pub pool: ::ethers::core::types::Address, - } - ///Container type for all of the contract's events - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum IUniswapV3FactoryEvents { - FeeAmountEnabledFilter(FeeAmountEnabledFilter), - OwnerChangedFilter(OwnerChangedFilter), - PoolCreatedFilter(PoolCreatedFilter), - } - impl ::ethers::contract::EthLogDecode for IUniswapV3FactoryEvents { - fn decode_log(log: &::ethers::core::abi::RawLog) -> ::core::result::Result { - if let Ok(decoded) = FeeAmountEnabledFilter::decode_log(log) { - return Ok(IUniswapV3FactoryEvents::FeeAmountEnabledFilter(decoded)); - } - if let Ok(decoded) = OwnerChangedFilter::decode_log(log) { - return Ok(IUniswapV3FactoryEvents::OwnerChangedFilter(decoded)); - } - if let Ok(decoded) = PoolCreatedFilter::decode_log(log) { - return Ok(IUniswapV3FactoryEvents::PoolCreatedFilter(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData) - } - } - impl ::core::fmt::Display for IUniswapV3FactoryEvents { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::FeeAmountEnabledFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::OwnerChangedFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::PoolCreatedFilter(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for IUniswapV3FactoryEvents { - fn from(value: FeeAmountEnabledFilter) -> Self { - Self::FeeAmountEnabledFilter(value) - } - } - impl ::core::convert::From for IUniswapV3FactoryEvents { - fn from(value: OwnerChangedFilter) -> Self { - Self::OwnerChangedFilter(value) - } - } - impl ::core::convert::From for IUniswapV3FactoryEvents { - fn from(value: PoolCreatedFilter) -> Self { - Self::PoolCreatedFilter(value) - } - } - ///Container type for all input parameters for the `createPool` function with signature `createPool(address,address,uint24)` and selector `0xa1671295` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "createPool", abi = "createPool(address,address,uint24)")] - pub struct CreatePoolCall { - pub token_a: ::ethers::core::types::Address, - pub token_b: ::ethers::core::types::Address, - pub fee: u32, - } - ///Container type for all input parameters for the `enableFeeAmount` function with signature `enableFeeAmount(uint24,int24)` and selector `0x8a7c195f` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "enableFeeAmount", abi = "enableFeeAmount(uint24,int24)")] - pub struct EnableFeeAmountCall { - pub fee: u32, - pub tick_spacing: i32, - } - ///Container type for all input parameters for the `feeAmountTickSpacing` function with signature `feeAmountTickSpacing(uint24)` and selector `0x22afcccb` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "feeAmountTickSpacing", abi = "feeAmountTickSpacing(uint24)")] - pub struct FeeAmountTickSpacingCall { - pub fee: u32, - } - ///Container type for all input parameters for the `getPool` function with signature `getPool(address,address,uint24)` and selector `0x1698ee82` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "getPool", abi = "getPool(address,address,uint24)")] - pub struct GetPoolCall { - pub token_a: ::ethers::core::types::Address, - pub token_b: ::ethers::core::types::Address, - pub fee: u32, - } - ///Container type for all input parameters for the `owner` function with signature `owner()` and selector `0x8da5cb5b` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "owner", abi = "owner()")] - pub struct OwnerCall; - ///Container type for all input parameters for the `setOwner` function with signature `setOwner(address)` and selector `0x13af4035` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "setOwner", abi = "setOwner(address)")] - pub struct SetOwnerCall { - pub owner: ::ethers::core::types::Address, - } - ///Container type for all of the contract's call - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum IUniswapV3FactoryCalls { - CreatePool(CreatePoolCall), - EnableFeeAmount(EnableFeeAmountCall), - FeeAmountTickSpacing(FeeAmountTickSpacingCall), - GetPool(GetPoolCall), - Owner(OwnerCall), - SetOwner(SetOwnerCall), - } - impl ::ethers::core::abi::AbiDecode for IUniswapV3FactoryCalls { - fn decode(data: impl AsRef<[u8]>) -> ::core::result::Result { - let data = data.as_ref(); - if let Ok(decoded) = ::decode(data) { - return Ok(Self::CreatePool(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::EnableFeeAmount(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::FeeAmountTickSpacing(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::GetPool(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Owner(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SetOwner(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData.into()) - } - } - impl ::ethers::core::abi::AbiEncode for IUniswapV3FactoryCalls { - fn encode(self) -> Vec { - match self { - Self::CreatePool(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::EnableFeeAmount(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::FeeAmountTickSpacing(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::GetPool(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Owner(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SetOwner(element) => ::ethers::core::abi::AbiEncode::encode(element), - } - } - } - impl ::core::fmt::Display for IUniswapV3FactoryCalls { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::CreatePool(element) => ::core::fmt::Display::fmt(element, f), - Self::EnableFeeAmount(element) => ::core::fmt::Display::fmt(element, f), - Self::FeeAmountTickSpacing(element) => ::core::fmt::Display::fmt(element, f), - Self::GetPool(element) => ::core::fmt::Display::fmt(element, f), - Self::Owner(element) => ::core::fmt::Display::fmt(element, f), - Self::SetOwner(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for IUniswapV3FactoryCalls { - fn from(value: CreatePoolCall) -> Self { - Self::CreatePool(value) - } - } - impl ::core::convert::From for IUniswapV3FactoryCalls { - fn from(value: EnableFeeAmountCall) -> Self { - Self::EnableFeeAmount(value) - } - } - impl ::core::convert::From for IUniswapV3FactoryCalls { - fn from(value: FeeAmountTickSpacingCall) -> Self { - Self::FeeAmountTickSpacing(value) - } - } - impl ::core::convert::From for IUniswapV3FactoryCalls { - fn from(value: GetPoolCall) -> Self { - Self::GetPool(value) - } - } - impl ::core::convert::From for IUniswapV3FactoryCalls { - fn from(value: OwnerCall) -> Self { - Self::Owner(value) - } - } - impl ::core::convert::From for IUniswapV3FactoryCalls { - fn from(value: SetOwnerCall) -> Self { - Self::SetOwner(value) - } - } - ///Container type for all return fields from the `createPool` function with signature `createPool(address,address,uint24)` and selector `0xa1671295` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct CreatePoolReturn { - pub pool: ::ethers::core::types::Address, - } - ///Container type for all return fields from the `feeAmountTickSpacing` function with signature `feeAmountTickSpacing(uint24)` and selector `0x22afcccb` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct FeeAmountTickSpacingReturn(pub i32); - ///Container type for all return fields from the `getPool` function with signature `getPool(address,address,uint24)` and selector `0x1698ee82` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct GetPoolReturn { - pub pool: ::ethers::core::types::Address, - } - ///Container type for all return fields from the `owner` function with signature `owner()` and selector `0x8da5cb5b` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct OwnerReturn(pub ::ethers::core::types::Address); -} diff --git a/src/bindings/i_uniswap_v3_mint_callback.rs b/src/bindings/i_uniswap_v3_mint_callback.rs deleted file mode 100644 index 3042a2b..0000000 --- a/src/bindings/i_uniswap_v3_mint_callback.rs +++ /dev/null @@ -1,122 +0,0 @@ -pub use i_uniswap_v3_mint_callback::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod i_uniswap_v3_mint_callback { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([( - ::std::borrow::ToOwned::to_owned("uniswapV3MintCallback"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("uniswapV3MintCallback",), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount0Owed"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount1Owed"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("data"), - kind: ::ethers::core::abi::ethabi::ParamType::Bytes, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes"),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - )]), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static IUNISWAPV3MINTCALLBACK_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - pub struct IUniswapV3MintCallback(::ethers::contract::Contract); - impl ::core::clone::Clone for IUniswapV3MintCallback { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for IUniswapV3MintCallback { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for IUniswapV3MintCallback { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for IUniswapV3MintCallback { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(IUniswapV3MintCallback)) - .field(&self.address()) - .finish() - } - } - impl IUniswapV3MintCallback { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - IUNISWAPV3MINTCALLBACK_ABI.clone(), - client, - )) - } - ///Calls the contract's `uniswapV3MintCallback` (0xd3487997) function - pub fn uniswap_v3_mint_callback( - &self, - amount_0_owed: ::ethers::core::types::U256, - amount_1_owed: ::ethers::core::types::U256, - data: ::ethers::core::types::Bytes, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([211, 72, 121, 151], (amount_0_owed, amount_1_owed, data)) - .expect("method not found (this should never happen)") - } - } - impl From<::ethers::contract::Contract> for IUniswapV3MintCallback { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Container type for all input parameters for the `uniswapV3MintCallback` function with signature `uniswapV3MintCallback(uint256,uint256,bytes)` and selector `0xd3487997` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "uniswapV3MintCallback", abi = "uniswapV3MintCallback(uint256,uint256,bytes)")] - pub struct UniswapV3MintCallbackCall { - pub amount_0_owed: ::ethers::core::types::U256, - pub amount_1_owed: ::ethers::core::types::U256, - pub data: ::ethers::core::types::Bytes, - } -} diff --git a/src/bindings/i_uniswap_v3_pool.rs b/src/bindings/i_uniswap_v3_pool.rs deleted file mode 100644 index 96980fc..0000000 --- a/src/bindings/i_uniswap_v3_pool.rs +++ /dev/null @@ -1,2888 +0,0 @@ -pub use i_uniswap_v3_pool::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod i_uniswap_v3_pool { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("burn"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("burn"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickLower"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickUpper"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("collect"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("collect"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("recipient"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickLower"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickUpper"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount0Requested"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount1Requested"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("collectProtocol"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("collectProtocol"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("recipient"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount0Requested"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount1Requested"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("factory"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("factory"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("fee"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("fee"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint24"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("feeGrowthGlobal0X128"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("feeGrowthGlobal0X128",), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("feeGrowthGlobal1X128"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("feeGrowthGlobal1X128",), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("flash"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("flash"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("recipient"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("data"), - kind: ::ethers::core::abi::ethabi::ParamType::Bytes, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes"),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("increaseObservationCardinalityNext"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("increaseObservationCardinalityNext",), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("observationCardinalityNext",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(16usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint16"),), - },], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("initialize"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("initialize"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("sqrtPriceX96"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(160usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint160"),), - },], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("liquidity"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("liquidity"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint128"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("maxLiquidityPerTick"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("maxLiquidityPerTick",), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint128"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("mint"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("mint"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("recipient"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickLower"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickUpper"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("data"), - kind: ::ethers::core::abi::ethabi::ParamType::Bytes, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes"),), - }, - ], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("observations"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("observations"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("index"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("blockTimestamp"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(32usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint32"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickCumulative"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(56usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int56"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("secondsPerLiquidityCumulativeX128",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(160usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint160" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("initialized"), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("observe"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("observe"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("secondsAgos"), - kind: ::ethers::core::abi::ethabi::ParamType::Array(::std::boxed::Box::new( - ::ethers::core::abi::ethabi::ParamType::Uint(32usize), - ),), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint32[]"),), - },], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickCumulatives"), - kind: ::ethers::core::abi::ethabi::ParamType::Array(::std::boxed::Box::new( - ::ethers::core::abi::ethabi::ParamType::Int(56usize), - ),), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "int56[]" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("secondsPerLiquidityCumulativeX128s",), - kind: ::ethers::core::abi::ethabi::ParamType::Array(::std::boxed::Box::new( - ::ethers::core::abi::ethabi::ParamType::Uint(160usize), - ),), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint160[]" - ),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("positions"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("positions"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("key"), - kind: ::ethers::core::abi::ethabi::ParamType::FixedBytes(32usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes32"),), - },], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("_liquidity"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("feeGrowthInside0LastX128",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("feeGrowthInside1LastX128",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokensOwed0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokensOwed1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("protocolFees"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("protocolFees"), - inputs: ::std::vec![], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("token0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("token1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("setFeeProtocol"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("setFeeProtocol"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("feeProtocol0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint8"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("feeProtocol1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint8"),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("slot0"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("slot0"), - inputs: ::std::vec![], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("sqrtPriceX96"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(160usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint160" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tick"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("observationIndex"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(16usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint16"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("observationCardinality",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(16usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint16"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("observationCardinalityNext",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(16usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint16"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("feeProtocol"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint8"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("unlocked"), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("snapshotCumulativesInside"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("snapshotCumulativesInside",), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickLower"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickUpper"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickCumulativeInside",), - kind: ::ethers::core::abi::ethabi::ParamType::Int(56usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int56"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("secondsPerLiquidityInsideX128",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(160usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint160" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("secondsInside"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(32usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint32"),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("swap"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("swap"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("recipient"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("zeroForOne"), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amountSpecified"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(256usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int256"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("sqrtPriceLimitX96"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(160usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint160" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("data"), - kind: ::ethers::core::abi::ethabi::ParamType::Bytes, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes"),), - }, - ], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(256usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int256"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(256usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int256"),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("tickBitmap"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("tickBitmap"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("wordPosition"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(16usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int16"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("tickSpacing"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("tickSpacing"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("ticks"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("ticks"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tick"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - },], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("liquidityGross"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("liquidityNet"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(128usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int128"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("feeGrowthOutside0X128",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("feeGrowthOutside1X128",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickCumulativeOutside",), - kind: ::ethers::core::abi::ethabi::ParamType::Int(56usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int56"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("secondsPerLiquidityOutsideX128",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(160usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint160" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("secondsOutside"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(32usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint32"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("initialized"), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("token0"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("token0"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("token1"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("token1"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ]), - events: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("Burn"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Burn"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tickLower"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tickUpper"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("Collect"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Collect"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("recipient"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tickLower"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tickUpper"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("CollectProtocol"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("CollectProtocol"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("sender"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("recipient"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("Flash"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Flash"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("sender"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("recipient"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("paid0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("paid1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("IncreaseObservationCardinalityNext"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("IncreaseObservationCardinalityNext",), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("observationCardinalityNextOld",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(16usize), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("observationCardinalityNextNew",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(16usize), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("Initialize"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Initialize"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("sqrtPriceX96"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(160usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tick"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("Mint"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Mint"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("sender"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tickLower"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tickUpper"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("SetFeeProtocol"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("SetFeeProtocol"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("feeProtocol0Old"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("feeProtocol1Old"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("feeProtocol0New"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("feeProtocol1New"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("Swap"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Swap"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("sender"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("recipient"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(256usize), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(256usize), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("sqrtPriceX96"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(160usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("liquidity"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tick"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ]), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static IUNISWAPV3POOL_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - pub struct IUniswapV3Pool(::ethers::contract::Contract); - impl ::core::clone::Clone for IUniswapV3Pool { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for IUniswapV3Pool { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for IUniswapV3Pool { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for IUniswapV3Pool { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(IUniswapV3Pool)) - .field(&self.address()) - .finish() - } - } - impl IUniswapV3Pool { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - IUNISWAPV3POOL_ABI.clone(), - client, - )) - } - ///Calls the contract's `burn` (0xa34123a7) function - pub fn burn( - &self, - tick_lower: i32, - tick_upper: i32, - amount: u128, - ) -> ::ethers::contract::builders::ContractCall - { - self.0 - .method_hash([163, 65, 35, 167], (tick_lower, tick_upper, amount)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `collect` (0x4f1eb3d8) function - pub fn collect( - &self, - recipient: ::ethers::core::types::Address, - tick_lower: i32, - tick_upper: i32, - amount_0_requested: u128, - amount_1_requested: u128, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash( - [79, 30, 179, 216], - ( - recipient, - tick_lower, - tick_upper, - amount_0_requested, - amount_1_requested, - ), - ) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `collectProtocol` (0x85b66729) function - pub fn collect_protocol( - &self, - recipient: ::ethers::core::types::Address, - amount_0_requested: u128, - amount_1_requested: u128, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([133, 182, 103, 41], (recipient, amount_0_requested, amount_1_requested)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `factory` (0xc45a0155) function - pub fn factory(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([196, 90, 1, 85], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `fee` (0xddca3f43) function - pub fn fee(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([221, 202, 63, 67], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `feeGrowthGlobal0X128` (0xf3058399) function - pub fn fee_growth_global_0x128( - &self, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([243, 5, 131, 153], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `feeGrowthGlobal1X128` (0x46141319) function - pub fn fee_growth_global_1x128( - &self, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([70, 20, 19, 25], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `flash` (0x490e6cbc) function - pub fn flash( - &self, - recipient: ::ethers::core::types::Address, - amount_0: ::ethers::core::types::U256, - amount_1: ::ethers::core::types::U256, - data: ::ethers::core::types::Bytes, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([73, 14, 108, 188], (recipient, amount_0, amount_1, data)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `increaseObservationCardinalityNext` (0x32148f67) function - pub fn increase_observation_cardinality_next( - &self, - observation_cardinality_next: u16, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([50, 20, 143, 103], observation_cardinality_next) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `initialize` (0xf637731d) function - pub fn initialize( - &self, - sqrt_price_x96: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([246, 55, 115, 29], sqrt_price_x96) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `liquidity` (0x1a686502) function - pub fn liquidity(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([26, 104, 101, 2], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `maxLiquidityPerTick` (0x70cf754a) function - pub fn max_liquidity_per_tick(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([112, 207, 117, 74], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `mint` (0x3c8a7d8d) function - pub fn mint( - &self, - recipient: ::ethers::core::types::Address, - tick_lower: i32, - tick_upper: i32, - amount: u128, - data: ::ethers::core::types::Bytes, - ) -> ::ethers::contract::builders::ContractCall - { - self.0 - .method_hash([60, 138, 125, 141], (recipient, tick_lower, tick_upper, amount, data)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `observations` (0x252c09d7) function - pub fn observations( - &self, - index: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([37, 44, 9, 215], index) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `observe` (0x883bdbfd) function - pub fn observe( - &self, - seconds_agos: ::std::vec::Vec, - ) -> ::ethers::contract::builders::ContractCall< - M, - (::std::vec::Vec, ::std::vec::Vec<::ethers::core::types::U256>), - > { - self.0 - .method_hash([136, 59, 219, 253], seconds_agos) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `positions` (0x514ea4bf) function - pub fn positions( - &self, - key: [u8; 32], - ) -> ::ethers::contract::builders::ContractCall< - M, - ( - u128, - ::ethers::core::types::U256, - ::ethers::core::types::U256, - u128, - u128, - ), - > { - self.0 - .method_hash([81, 78, 164, 191], key) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `protocolFees` (0x1ad8b03b) function - pub fn protocol_fees(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([26, 216, 176, 59], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `setFeeProtocol` (0x8206a4d1) function - pub fn set_fee_protocol( - &self, - fee_protocol_0: u8, - fee_protocol_1: u8, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([130, 6, 164, 209], (fee_protocol_0, fee_protocol_1)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `slot0` (0x3850c7bd) function - pub fn slot_0( - &self, - ) -> ::ethers::contract::builders::ContractCall - { - self.0 - .method_hash([56, 80, 199, 189], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `snapshotCumulativesInside` (0xa38807f2) function - pub fn snapshot_cumulatives_inside( - &self, - tick_lower: i32, - tick_upper: i32, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([163, 136, 7, 242], (tick_lower, tick_upper)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `swap` (0x128acb08) function - pub fn swap( - &self, - recipient: ::ethers::core::types::Address, - zero_for_one: bool, - amount_specified: ::ethers::core::types::I256, - sqrt_price_limit_x96: ::ethers::core::types::U256, - data: ::ethers::core::types::Bytes, - ) -> ::ethers::contract::builders::ContractCall - { - self.0 - .method_hash( - [18, 138, 203, 8], - (recipient, zero_for_one, amount_specified, sqrt_price_limit_x96, data), - ) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `tickBitmap` (0x5339c296) function - pub fn tick_bitmap( - &self, - word_position: i16, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([83, 57, 194, 150], word_position) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `tickSpacing` (0xd0c93a7c) function - pub fn tick_spacing(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([208, 201, 58, 124], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `ticks` (0xf30dba93) function - pub fn ticks( - &self, - tick: i32, - ) -> ::ethers::contract::builders::ContractCall< - M, - ( - u128, - i128, - ::ethers::core::types::U256, - ::ethers::core::types::U256, - i64, - ::ethers::core::types::U256, - u32, - bool, - ), - > { - self.0 - .method_hash([243, 13, 186, 147], tick) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `token0` (0x0dfe1681) function - pub fn token_0(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([13, 254, 22, 129], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `token1` (0xd21220a7) function - pub fn token_1(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([210, 18, 32, 167], ()) - .expect("method not found (this should never happen)") - } - ///Gets the contract's `Burn` event - pub fn burn_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, BurnFilter> { - self.0.event() - } - ///Gets the contract's `Collect` event - pub fn collect_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, CollectFilter> { - self.0.event() - } - ///Gets the contract's `CollectProtocol` event - pub fn collect_protocol_filter( - &self, - ) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, CollectProtocolFilter> { - self.0.event() - } - ///Gets the contract's `Flash` event - pub fn flash_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, FlashFilter> { - self.0.event() - } - ///Gets the contract's `IncreaseObservationCardinalityNext` event - pub fn increase_observation_cardinality_next_filter( - &self, - ) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, IncreaseObservationCardinalityNextFilter> - { - self.0.event() - } - ///Gets the contract's `Initialize` event - pub fn initialize_filter( - &self, - ) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, InitializeFilter> { - self.0.event() - } - ///Gets the contract's `Mint` event - pub fn mint_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, MintFilter> { - self.0.event() - } - ///Gets the contract's `SetFeeProtocol` event - pub fn set_fee_protocol_filter( - &self, - ) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, SetFeeProtocolFilter> { - self.0.event() - } - ///Gets the contract's `Swap` event - pub fn swap_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, SwapFilter> { - self.0.event() - } - /// Returns an `Event` builder for all the events of this contract. - pub fn events(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, IUniswapV3PoolEvents> { - self.0.event_with_filter(::core::default::Default::default()) - } - } - impl From<::ethers::contract::Contract> for IUniswapV3Pool { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Burn", abi = "Burn(address,int24,int24,uint128,uint256,uint256)")] - pub struct BurnFilter { - #[ethevent(indexed)] - pub owner: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub tick_lower: i32, - #[ethevent(indexed)] - pub tick_upper: i32, - pub amount: u128, - pub amount_0: ::ethers::core::types::U256, - pub amount_1: ::ethers::core::types::U256, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Collect", abi = "Collect(address,address,int24,int24,uint128,uint128)")] - pub struct CollectFilter { - #[ethevent(indexed)] - pub owner: ::ethers::core::types::Address, - pub recipient: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub tick_lower: i32, - #[ethevent(indexed)] - pub tick_upper: i32, - pub amount_0: u128, - pub amount_1: u128, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "CollectProtocol", abi = "CollectProtocol(address,address,uint128,uint128)")] - pub struct CollectProtocolFilter { - #[ethevent(indexed)] - pub sender: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub recipient: ::ethers::core::types::Address, - pub amount_0: u128, - pub amount_1: u128, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Flash", abi = "Flash(address,address,uint256,uint256,uint256,uint256)")] - pub struct FlashFilter { - #[ethevent(indexed)] - pub sender: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub recipient: ::ethers::core::types::Address, - pub amount_0: ::ethers::core::types::U256, - pub amount_1: ::ethers::core::types::U256, - pub paid_0: ::ethers::core::types::U256, - pub paid_1: ::ethers::core::types::U256, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent( - name = "IncreaseObservationCardinalityNext", - abi = "IncreaseObservationCardinalityNext(uint16,uint16)" - )] - pub struct IncreaseObservationCardinalityNextFilter { - pub observation_cardinality_next_old: u16, - pub observation_cardinality_next_new: u16, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Initialize", abi = "Initialize(uint160,int24)")] - pub struct InitializeFilter { - pub sqrt_price_x96: ::ethers::core::types::U256, - pub tick: i32, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Mint", abi = "Mint(address,address,int24,int24,uint128,uint256,uint256)")] - pub struct MintFilter { - pub sender: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub owner: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub tick_lower: i32, - #[ethevent(indexed)] - pub tick_upper: i32, - pub amount: u128, - pub amount_0: ::ethers::core::types::U256, - pub amount_1: ::ethers::core::types::U256, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "SetFeeProtocol", abi = "SetFeeProtocol(uint8,uint8,uint8,uint8)")] - pub struct SetFeeProtocolFilter { - pub fee_protocol_0_old: u8, - pub fee_protocol_1_old: u8, - pub fee_protocol_0_new: u8, - pub fee_protocol_1_new: u8, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Swap", abi = "Swap(address,address,int256,int256,uint160,uint128,int24)")] - pub struct SwapFilter { - #[ethevent(indexed)] - pub sender: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub recipient: ::ethers::core::types::Address, - pub amount_0: ::ethers::core::types::I256, - pub amount_1: ::ethers::core::types::I256, - pub sqrt_price_x96: ::ethers::core::types::U256, - pub liquidity: u128, - pub tick: i32, - } - ///Container type for all of the contract's events - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum IUniswapV3PoolEvents { - BurnFilter(BurnFilter), - CollectFilter(CollectFilter), - CollectProtocolFilter(CollectProtocolFilter), - FlashFilter(FlashFilter), - IncreaseObservationCardinalityNextFilter(IncreaseObservationCardinalityNextFilter), - InitializeFilter(InitializeFilter), - MintFilter(MintFilter), - SetFeeProtocolFilter(SetFeeProtocolFilter), - SwapFilter(SwapFilter), - } - impl ::ethers::contract::EthLogDecode for IUniswapV3PoolEvents { - fn decode_log(log: &::ethers::core::abi::RawLog) -> ::core::result::Result { - if let Ok(decoded) = BurnFilter::decode_log(log) { - return Ok(IUniswapV3PoolEvents::BurnFilter(decoded)); - } - if let Ok(decoded) = CollectFilter::decode_log(log) { - return Ok(IUniswapV3PoolEvents::CollectFilter(decoded)); - } - if let Ok(decoded) = CollectProtocolFilter::decode_log(log) { - return Ok(IUniswapV3PoolEvents::CollectProtocolFilter(decoded)); - } - if let Ok(decoded) = FlashFilter::decode_log(log) { - return Ok(IUniswapV3PoolEvents::FlashFilter(decoded)); - } - if let Ok(decoded) = IncreaseObservationCardinalityNextFilter::decode_log(log) { - return Ok(IUniswapV3PoolEvents::IncreaseObservationCardinalityNextFilter(decoded)); - } - if let Ok(decoded) = InitializeFilter::decode_log(log) { - return Ok(IUniswapV3PoolEvents::InitializeFilter(decoded)); - } - if let Ok(decoded) = MintFilter::decode_log(log) { - return Ok(IUniswapV3PoolEvents::MintFilter(decoded)); - } - if let Ok(decoded) = SetFeeProtocolFilter::decode_log(log) { - return Ok(IUniswapV3PoolEvents::SetFeeProtocolFilter(decoded)); - } - if let Ok(decoded) = SwapFilter::decode_log(log) { - return Ok(IUniswapV3PoolEvents::SwapFilter(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData) - } - } - impl ::core::fmt::Display for IUniswapV3PoolEvents { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::BurnFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::CollectFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::CollectProtocolFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::FlashFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::IncreaseObservationCardinalityNextFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::InitializeFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::MintFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::SetFeeProtocolFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::SwapFilter(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for IUniswapV3PoolEvents { - fn from(value: BurnFilter) -> Self { - Self::BurnFilter(value) - } - } - impl ::core::convert::From for IUniswapV3PoolEvents { - fn from(value: CollectFilter) -> Self { - Self::CollectFilter(value) - } - } - impl ::core::convert::From for IUniswapV3PoolEvents { - fn from(value: CollectProtocolFilter) -> Self { - Self::CollectProtocolFilter(value) - } - } - impl ::core::convert::From for IUniswapV3PoolEvents { - fn from(value: FlashFilter) -> Self { - Self::FlashFilter(value) - } - } - impl ::core::convert::From for IUniswapV3PoolEvents { - fn from(value: IncreaseObservationCardinalityNextFilter) -> Self { - Self::IncreaseObservationCardinalityNextFilter(value) - } - } - impl ::core::convert::From for IUniswapV3PoolEvents { - fn from(value: InitializeFilter) -> Self { - Self::InitializeFilter(value) - } - } - impl ::core::convert::From for IUniswapV3PoolEvents { - fn from(value: MintFilter) -> Self { - Self::MintFilter(value) - } - } - impl ::core::convert::From for IUniswapV3PoolEvents { - fn from(value: SetFeeProtocolFilter) -> Self { - Self::SetFeeProtocolFilter(value) - } - } - impl ::core::convert::From for IUniswapV3PoolEvents { - fn from(value: SwapFilter) -> Self { - Self::SwapFilter(value) - } - } - ///Container type for all input parameters for the `burn` function with signature `burn(int24,int24,uint128)` and selector `0xa34123a7` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "burn", abi = "burn(int24,int24,uint128)")] - pub struct BurnCall { - pub tick_lower: i32, - pub tick_upper: i32, - pub amount: u128, - } - ///Container type for all input parameters for the `collect` function with signature `collect(address,int24,int24,uint128,uint128)` and selector `0x4f1eb3d8` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "collect", abi = "collect(address,int24,int24,uint128,uint128)")] - pub struct CollectCall { - pub recipient: ::ethers::core::types::Address, - pub tick_lower: i32, - pub tick_upper: i32, - pub amount_0_requested: u128, - pub amount_1_requested: u128, - } - ///Container type for all input parameters for the `collectProtocol` function with signature `collectProtocol(address,uint128,uint128)` and selector `0x85b66729` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "collectProtocol", abi = "collectProtocol(address,uint128,uint128)")] - pub struct CollectProtocolCall { - pub recipient: ::ethers::core::types::Address, - pub amount_0_requested: u128, - pub amount_1_requested: u128, - } - ///Container type for all input parameters for the `factory` function with signature `factory()` and selector `0xc45a0155` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "factory", abi = "factory()")] - pub struct FactoryCall; - ///Container type for all input parameters for the `fee` function with signature `fee()` and selector `0xddca3f43` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "fee", abi = "fee()")] - pub struct FeeCall; - ///Container type for all input parameters for the `feeGrowthGlobal0X128` function with signature `feeGrowthGlobal0X128()` and selector `0xf3058399` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "feeGrowthGlobal0X128", abi = "feeGrowthGlobal0X128()")] - pub struct FeeGrowthGlobal0X128Call; - ///Container type for all input parameters for the `feeGrowthGlobal1X128` function with signature `feeGrowthGlobal1X128()` and selector `0x46141319` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "feeGrowthGlobal1X128", abi = "feeGrowthGlobal1X128()")] - pub struct FeeGrowthGlobal1X128Call; - ///Container type for all input parameters for the `flash` function with signature `flash(address,uint256,uint256,bytes)` and selector `0x490e6cbc` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "flash", abi = "flash(address,uint256,uint256,bytes)")] - pub struct FlashCall { - pub recipient: ::ethers::core::types::Address, - pub amount_0: ::ethers::core::types::U256, - pub amount_1: ::ethers::core::types::U256, - pub data: ::ethers::core::types::Bytes, - } - ///Container type for all input parameters for the `increaseObservationCardinalityNext` function with signature `increaseObservationCardinalityNext(uint16)` and selector `0x32148f67` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall( - name = "increaseObservationCardinalityNext", - abi = "increaseObservationCardinalityNext(uint16)" - )] - pub struct IncreaseObservationCardinalityNextCall { - pub observation_cardinality_next: u16, - } - ///Container type for all input parameters for the `initialize` function with signature `initialize(uint160)` and selector `0xf637731d` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "initialize", abi = "initialize(uint160)")] - pub struct InitializeCall { - pub sqrt_price_x96: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `liquidity` function with signature `liquidity()` and selector `0x1a686502` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "liquidity", abi = "liquidity()")] - pub struct LiquidityCall; - ///Container type for all input parameters for the `maxLiquidityPerTick` function with signature `maxLiquidityPerTick()` and selector `0x70cf754a` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "maxLiquidityPerTick", abi = "maxLiquidityPerTick()")] - pub struct MaxLiquidityPerTickCall; - ///Container type for all input parameters for the `mint` function with signature `mint(address,int24,int24,uint128,bytes)` and selector `0x3c8a7d8d` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "mint", abi = "mint(address,int24,int24,uint128,bytes)")] - pub struct MintCall { - pub recipient: ::ethers::core::types::Address, - pub tick_lower: i32, - pub tick_upper: i32, - pub amount: u128, - pub data: ::ethers::core::types::Bytes, - } - ///Container type for all input parameters for the `observations` function with signature `observations(uint256)` and selector `0x252c09d7` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "observations", abi = "observations(uint256)")] - pub struct ObservationsCall { - pub index: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `observe` function with signature `observe(uint32[])` and selector `0x883bdbfd` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "observe", abi = "observe(uint32[])")] - pub struct ObserveCall { - pub seconds_agos: ::std::vec::Vec, - } - ///Container type for all input parameters for the `positions` function with signature `positions(bytes32)` and selector `0x514ea4bf` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "positions", abi = "positions(bytes32)")] - pub struct PositionsCall { - pub key: [u8; 32], - } - ///Container type for all input parameters for the `protocolFees` function with signature `protocolFees()` and selector `0x1ad8b03b` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "protocolFees", abi = "protocolFees()")] - pub struct ProtocolFeesCall; - ///Container type for all input parameters for the `setFeeProtocol` function with signature `setFeeProtocol(uint8,uint8)` and selector `0x8206a4d1` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "setFeeProtocol", abi = "setFeeProtocol(uint8,uint8)")] - pub struct SetFeeProtocolCall { - pub fee_protocol_0: u8, - pub fee_protocol_1: u8, - } - ///Container type for all input parameters for the `slot0` function with signature `slot0()` and selector `0x3850c7bd` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "slot0", abi = "slot0()")] - pub struct Slot0Call; - ///Container type for all input parameters for the `snapshotCumulativesInside` function with signature `snapshotCumulativesInside(int24,int24)` and selector `0xa38807f2` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "snapshotCumulativesInside", abi = "snapshotCumulativesInside(int24,int24)")] - pub struct SnapshotCumulativesInsideCall { - pub tick_lower: i32, - pub tick_upper: i32, - } - ///Container type for all input parameters for the `swap` function with signature `swap(address,bool,int256,uint160,bytes)` and selector `0x128acb08` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "swap", abi = "swap(address,bool,int256,uint160,bytes)")] - pub struct SwapCall { - pub recipient: ::ethers::core::types::Address, - pub zero_for_one: bool, - pub amount_specified: ::ethers::core::types::I256, - pub sqrt_price_limit_x96: ::ethers::core::types::U256, - pub data: ::ethers::core::types::Bytes, - } - ///Container type for all input parameters for the `tickBitmap` function with signature `tickBitmap(int16)` and selector `0x5339c296` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "tickBitmap", abi = "tickBitmap(int16)")] - pub struct TickBitmapCall { - pub word_position: i16, - } - ///Container type for all input parameters for the `tickSpacing` function with signature `tickSpacing()` and selector `0xd0c93a7c` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "tickSpacing", abi = "tickSpacing()")] - pub struct TickSpacingCall; - ///Container type for all input parameters for the `ticks` function with signature `ticks(int24)` and selector `0xf30dba93` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "ticks", abi = "ticks(int24)")] - pub struct TicksCall { - pub tick: i32, - } - ///Container type for all input parameters for the `token0` function with signature `token0()` and selector `0x0dfe1681` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "token0", abi = "token0()")] - pub struct Token0Call; - ///Container type for all input parameters for the `token1` function with signature `token1()` and selector `0xd21220a7` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "token1", abi = "token1()")] - pub struct Token1Call; - ///Container type for all of the contract's call - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum IUniswapV3PoolCalls { - Burn(BurnCall), - Collect(CollectCall), - CollectProtocol(CollectProtocolCall), - Factory(FactoryCall), - Fee(FeeCall), - FeeGrowthGlobal0X128(FeeGrowthGlobal0X128Call), - FeeGrowthGlobal1X128(FeeGrowthGlobal1X128Call), - Flash(FlashCall), - IncreaseObservationCardinalityNext(IncreaseObservationCardinalityNextCall), - Initialize(InitializeCall), - Liquidity(LiquidityCall), - MaxLiquidityPerTick(MaxLiquidityPerTickCall), - Mint(MintCall), - Observations(ObservationsCall), - Observe(ObserveCall), - Positions(PositionsCall), - ProtocolFees(ProtocolFeesCall), - SetFeeProtocol(SetFeeProtocolCall), - Slot0(Slot0Call), - SnapshotCumulativesInside(SnapshotCumulativesInsideCall), - Swap(SwapCall), - TickBitmap(TickBitmapCall), - TickSpacing(TickSpacingCall), - Ticks(TicksCall), - Token0(Token0Call), - Token1(Token1Call), - } - impl ::ethers::core::abi::AbiDecode for IUniswapV3PoolCalls { - fn decode(data: impl AsRef<[u8]>) -> ::core::result::Result { - let data = data.as_ref(); - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Burn(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Collect(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::CollectProtocol(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Factory(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Fee(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::FeeGrowthGlobal0X128(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::FeeGrowthGlobal1X128(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Flash(decoded)); - } - if let Ok(decoded) = - ::decode(data) - { - return Ok(Self::IncreaseObservationCardinalityNext(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Initialize(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Liquidity(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::MaxLiquidityPerTick(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Mint(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Observations(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Observe(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Positions(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::ProtocolFees(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SetFeeProtocol(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Slot0(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SnapshotCumulativesInside(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Swap(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TickBitmap(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TickSpacing(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Ticks(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Token0(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Token1(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData.into()) - } - } - impl ::ethers::core::abi::AbiEncode for IUniswapV3PoolCalls { - fn encode(self) -> Vec { - match self { - Self::Burn(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Collect(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::CollectProtocol(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Factory(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Fee(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::FeeGrowthGlobal0X128(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::FeeGrowthGlobal1X128(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Flash(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::IncreaseObservationCardinalityNext(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Initialize(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Liquidity(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::MaxLiquidityPerTick(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Mint(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Observations(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Observe(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Positions(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::ProtocolFees(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SetFeeProtocol(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Slot0(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SnapshotCumulativesInside(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Swap(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TickBitmap(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TickSpacing(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Ticks(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Token0(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Token1(element) => ::ethers::core::abi::AbiEncode::encode(element), - } - } - } - impl ::core::fmt::Display for IUniswapV3PoolCalls { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::Burn(element) => ::core::fmt::Display::fmt(element, f), - Self::Collect(element) => ::core::fmt::Display::fmt(element, f), - Self::CollectProtocol(element) => ::core::fmt::Display::fmt(element, f), - Self::Factory(element) => ::core::fmt::Display::fmt(element, f), - Self::Fee(element) => ::core::fmt::Display::fmt(element, f), - Self::FeeGrowthGlobal0X128(element) => ::core::fmt::Display::fmt(element, f), - Self::FeeGrowthGlobal1X128(element) => ::core::fmt::Display::fmt(element, f), - Self::Flash(element) => ::core::fmt::Display::fmt(element, f), - Self::IncreaseObservationCardinalityNext(element) => ::core::fmt::Display::fmt(element, f), - Self::Initialize(element) => ::core::fmt::Display::fmt(element, f), - Self::Liquidity(element) => ::core::fmt::Display::fmt(element, f), - Self::MaxLiquidityPerTick(element) => ::core::fmt::Display::fmt(element, f), - Self::Mint(element) => ::core::fmt::Display::fmt(element, f), - Self::Observations(element) => ::core::fmt::Display::fmt(element, f), - Self::Observe(element) => ::core::fmt::Display::fmt(element, f), - Self::Positions(element) => ::core::fmt::Display::fmt(element, f), - Self::ProtocolFees(element) => ::core::fmt::Display::fmt(element, f), - Self::SetFeeProtocol(element) => ::core::fmt::Display::fmt(element, f), - Self::Slot0(element) => ::core::fmt::Display::fmt(element, f), - Self::SnapshotCumulativesInside(element) => ::core::fmt::Display::fmt(element, f), - Self::Swap(element) => ::core::fmt::Display::fmt(element, f), - Self::TickBitmap(element) => ::core::fmt::Display::fmt(element, f), - Self::TickSpacing(element) => ::core::fmt::Display::fmt(element, f), - Self::Ticks(element) => ::core::fmt::Display::fmt(element, f), - Self::Token0(element) => ::core::fmt::Display::fmt(element, f), - Self::Token1(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: BurnCall) -> Self { - Self::Burn(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: CollectCall) -> Self { - Self::Collect(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: CollectProtocolCall) -> Self { - Self::CollectProtocol(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: FactoryCall) -> Self { - Self::Factory(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: FeeCall) -> Self { - Self::Fee(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: FeeGrowthGlobal0X128Call) -> Self { - Self::FeeGrowthGlobal0X128(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: FeeGrowthGlobal1X128Call) -> Self { - Self::FeeGrowthGlobal1X128(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: FlashCall) -> Self { - Self::Flash(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: IncreaseObservationCardinalityNextCall) -> Self { - Self::IncreaseObservationCardinalityNext(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: InitializeCall) -> Self { - Self::Initialize(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: LiquidityCall) -> Self { - Self::Liquidity(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: MaxLiquidityPerTickCall) -> Self { - Self::MaxLiquidityPerTick(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: MintCall) -> Self { - Self::Mint(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: ObservationsCall) -> Self { - Self::Observations(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: ObserveCall) -> Self { - Self::Observe(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: PositionsCall) -> Self { - Self::Positions(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: ProtocolFeesCall) -> Self { - Self::ProtocolFees(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: SetFeeProtocolCall) -> Self { - Self::SetFeeProtocol(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: Slot0Call) -> Self { - Self::Slot0(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: SnapshotCumulativesInsideCall) -> Self { - Self::SnapshotCumulativesInside(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: SwapCall) -> Self { - Self::Swap(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: TickBitmapCall) -> Self { - Self::TickBitmap(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: TickSpacingCall) -> Self { - Self::TickSpacing(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: TicksCall) -> Self { - Self::Ticks(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: Token0Call) -> Self { - Self::Token0(value) - } - } - impl ::core::convert::From for IUniswapV3PoolCalls { - fn from(value: Token1Call) -> Self { - Self::Token1(value) - } - } - ///Container type for all return fields from the `burn` function with signature `burn(int24,int24,uint128)` and selector `0xa34123a7` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct BurnReturn { - pub amount_0: ::ethers::core::types::U256, - pub amount_1: ::ethers::core::types::U256, - } - ///Container type for all return fields from the `collect` function with signature `collect(address,int24,int24,uint128,uint128)` and selector `0x4f1eb3d8` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct CollectReturn { - pub amount_0: u128, - pub amount_1: u128, - } - ///Container type for all return fields from the `collectProtocol` function with signature `collectProtocol(address,uint128,uint128)` and selector `0x85b66729` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct CollectProtocolReturn { - pub amount_0: u128, - pub amount_1: u128, - } - ///Container type for all return fields from the `factory` function with signature `factory()` and selector `0xc45a0155` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct FactoryReturn(pub ::ethers::core::types::Address); - ///Container type for all return fields from the `fee` function with signature `fee()` and selector `0xddca3f43` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct FeeReturn(pub u32); - ///Container type for all return fields from the `feeGrowthGlobal0X128` function with signature `feeGrowthGlobal0X128()` and selector `0xf3058399` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct FeeGrowthGlobal0X128Return(pub ::ethers::core::types::U256); - ///Container type for all return fields from the `feeGrowthGlobal1X128` function with signature `feeGrowthGlobal1X128()` and selector `0x46141319` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct FeeGrowthGlobal1X128Return(pub ::ethers::core::types::U256); - ///Container type for all return fields from the `liquidity` function with signature `liquidity()` and selector `0x1a686502` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct LiquidityReturn(pub u128); - ///Container type for all return fields from the `maxLiquidityPerTick` function with signature `maxLiquidityPerTick()` and selector `0x70cf754a` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct MaxLiquidityPerTickReturn(pub u128); - ///Container type for all return fields from the `mint` function with signature `mint(address,int24,int24,uint128,bytes)` and selector `0x3c8a7d8d` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct MintReturn { - pub amount_0: ::ethers::core::types::U256, - pub amount_1: ::ethers::core::types::U256, - } - ///Container type for all return fields from the `observations` function with signature `observations(uint256)` and selector `0x252c09d7` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct ObservationsReturn { - pub block_timestamp: u32, - pub tick_cumulative: i64, - pub seconds_per_liquidity_cumulative_x128: ::ethers::core::types::U256, - pub initialized: bool, - } - ///Container type for all return fields from the `observe` function with signature `observe(uint32[])` and selector `0x883bdbfd` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct ObserveReturn { - pub tick_cumulatives: ::std::vec::Vec, - pub seconds_per_liquidity_cumulative_x12_8s: ::std::vec::Vec<::ethers::core::types::U256>, - } - ///Container type for all return fields from the `positions` function with signature `positions(bytes32)` and selector `0x514ea4bf` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct PositionsReturn { - pub liquidity: u128, - pub fee_growth_inside_0_last_x128: ::ethers::core::types::U256, - pub fee_growth_inside_1_last_x128: ::ethers::core::types::U256, - pub tokens_owed_0: u128, - pub tokens_owed_1: u128, - } - ///Container type for all return fields from the `protocolFees` function with signature `protocolFees()` and selector `0x1ad8b03b` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct ProtocolFeesReturn { - pub token_0: u128, - pub token_1: u128, - } - ///Container type for all return fields from the `slot0` function with signature `slot0()` and selector `0x3850c7bd` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct Slot0Return { - pub sqrt_price_x96: ::ethers::core::types::U256, - pub tick: i32, - pub observation_index: u16, - pub observation_cardinality: u16, - pub observation_cardinality_next: u16, - pub fee_protocol: u8, - pub unlocked: bool, - } - ///Container type for all return fields from the `snapshotCumulativesInside` function with signature `snapshotCumulativesInside(int24,int24)` and selector `0xa38807f2` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct SnapshotCumulativesInsideReturn { - pub tick_cumulative_inside: i64, - pub seconds_per_liquidity_inside_x128: ::ethers::core::types::U256, - pub seconds_inside: u32, - } - ///Container type for all return fields from the `swap` function with signature `swap(address,bool,int256,uint160,bytes)` and selector `0x128acb08` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct SwapReturn { - pub amount_0: ::ethers::core::types::I256, - pub amount_1: ::ethers::core::types::I256, - } - ///Container type for all return fields from the `tickBitmap` function with signature `tickBitmap(int16)` and selector `0x5339c296` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct TickBitmapReturn(pub ::ethers::core::types::U256); - ///Container type for all return fields from the `tickSpacing` function with signature `tickSpacing()` and selector `0xd0c93a7c` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct TickSpacingReturn(pub i32); - ///Container type for all return fields from the `ticks` function with signature `ticks(int24)` and selector `0xf30dba93` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct TicksReturn { - pub liquidity_gross: u128, - pub liquidity_net: i128, - pub fee_growth_outside_0x128: ::ethers::core::types::U256, - pub fee_growth_outside_1x128: ::ethers::core::types::U256, - pub tick_cumulative_outside: i64, - pub seconds_per_liquidity_outside_x128: ::ethers::core::types::U256, - pub seconds_outside: u32, - pub initialized: bool, - } - ///Container type for all return fields from the `token0` function with signature `token0()` and selector `0x0dfe1681` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct Token0Return(pub ::ethers::core::types::Address); - ///Container type for all return fields from the `token1` function with signature `token1()` and selector `0xd21220a7` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct Token1Return(pub ::ethers::core::types::Address); -} diff --git a/src/bindings/i_uniswap_v3_pool_actions.rs b/src/bindings/i_uniswap_v3_pool_actions.rs deleted file mode 100644 index 2aaa91a..0000000 --- a/src/bindings/i_uniswap_v3_pool_actions.rs +++ /dev/null @@ -1,744 +0,0 @@ -pub use i_uniswap_v3_pool_actions::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod i_uniswap_v3_pool_actions { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("burn"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("burn"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickLower"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickUpper"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("collect"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("collect"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("recipient"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickLower"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickUpper"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount0Requested"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount1Requested"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("flash"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("flash"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("recipient"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("data"), - kind: ::ethers::core::abi::ethabi::ParamType::Bytes, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes"),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("increaseObservationCardinalityNext"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("increaseObservationCardinalityNext",), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("observationCardinalityNext",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(16usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint16"),), - },], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("initialize"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("initialize"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("sqrtPriceX96"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(160usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint160"),), - },], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("mint"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("mint"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("recipient"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickLower"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickUpper"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("data"), - kind: ::ethers::core::abi::ethabi::ParamType::Bytes, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes"),), - }, - ], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("swap"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("swap"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("recipient"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("zeroForOne"), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amountSpecified"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(256usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int256"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("sqrtPriceLimitX96"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(160usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint160" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("data"), - kind: ::ethers::core::abi::ethabi::ParamType::Bytes, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes"),), - }, - ], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(256usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int256"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(256usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int256"),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ]), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static IUNISWAPV3POOLACTIONS_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - pub struct IUniswapV3PoolActions(::ethers::contract::Contract); - impl ::core::clone::Clone for IUniswapV3PoolActions { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for IUniswapV3PoolActions { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for IUniswapV3PoolActions { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for IUniswapV3PoolActions { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(IUniswapV3PoolActions)) - .field(&self.address()) - .finish() - } - } - impl IUniswapV3PoolActions { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - IUNISWAPV3POOLACTIONS_ABI.clone(), - client, - )) - } - ///Calls the contract's `burn` (0xa34123a7) function - pub fn burn( - &self, - tick_lower: i32, - tick_upper: i32, - amount: u128, - ) -> ::ethers::contract::builders::ContractCall - { - self.0 - .method_hash([163, 65, 35, 167], (tick_lower, tick_upper, amount)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `collect` (0x4f1eb3d8) function - pub fn collect( - &self, - recipient: ::ethers::core::types::Address, - tick_lower: i32, - tick_upper: i32, - amount_0_requested: u128, - amount_1_requested: u128, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash( - [79, 30, 179, 216], - ( - recipient, - tick_lower, - tick_upper, - amount_0_requested, - amount_1_requested, - ), - ) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `flash` (0x490e6cbc) function - pub fn flash( - &self, - recipient: ::ethers::core::types::Address, - amount_0: ::ethers::core::types::U256, - amount_1: ::ethers::core::types::U256, - data: ::ethers::core::types::Bytes, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([73, 14, 108, 188], (recipient, amount_0, amount_1, data)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `increaseObservationCardinalityNext` (0x32148f67) function - pub fn increase_observation_cardinality_next( - &self, - observation_cardinality_next: u16, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([50, 20, 143, 103], observation_cardinality_next) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `initialize` (0xf637731d) function - pub fn initialize( - &self, - sqrt_price_x96: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([246, 55, 115, 29], sqrt_price_x96) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `mint` (0x3c8a7d8d) function - pub fn mint( - &self, - recipient: ::ethers::core::types::Address, - tick_lower: i32, - tick_upper: i32, - amount: u128, - data: ::ethers::core::types::Bytes, - ) -> ::ethers::contract::builders::ContractCall - { - self.0 - .method_hash([60, 138, 125, 141], (recipient, tick_lower, tick_upper, amount, data)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `swap` (0x128acb08) function - pub fn swap( - &self, - recipient: ::ethers::core::types::Address, - zero_for_one: bool, - amount_specified: ::ethers::core::types::I256, - sqrt_price_limit_x96: ::ethers::core::types::U256, - data: ::ethers::core::types::Bytes, - ) -> ::ethers::contract::builders::ContractCall - { - self.0 - .method_hash( - [18, 138, 203, 8], - (recipient, zero_for_one, amount_specified, sqrt_price_limit_x96, data), - ) - .expect("method not found (this should never happen)") - } - } - impl From<::ethers::contract::Contract> for IUniswapV3PoolActions { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Container type for all input parameters for the `burn` function with signature `burn(int24,int24,uint128)` and selector `0xa34123a7` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "burn", abi = "burn(int24,int24,uint128)")] - pub struct BurnCall { - pub tick_lower: i32, - pub tick_upper: i32, - pub amount: u128, - } - ///Container type for all input parameters for the `collect` function with signature `collect(address,int24,int24,uint128,uint128)` and selector `0x4f1eb3d8` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "collect", abi = "collect(address,int24,int24,uint128,uint128)")] - pub struct CollectCall { - pub recipient: ::ethers::core::types::Address, - pub tick_lower: i32, - pub tick_upper: i32, - pub amount_0_requested: u128, - pub amount_1_requested: u128, - } - ///Container type for all input parameters for the `flash` function with signature `flash(address,uint256,uint256,bytes)` and selector `0x490e6cbc` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "flash", abi = "flash(address,uint256,uint256,bytes)")] - pub struct FlashCall { - pub recipient: ::ethers::core::types::Address, - pub amount_0: ::ethers::core::types::U256, - pub amount_1: ::ethers::core::types::U256, - pub data: ::ethers::core::types::Bytes, - } - ///Container type for all input parameters for the `increaseObservationCardinalityNext` function with signature `increaseObservationCardinalityNext(uint16)` and selector `0x32148f67` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall( - name = "increaseObservationCardinalityNext", - abi = "increaseObservationCardinalityNext(uint16)" - )] - pub struct IncreaseObservationCardinalityNextCall { - pub observation_cardinality_next: u16, - } - ///Container type for all input parameters for the `initialize` function with signature `initialize(uint160)` and selector `0xf637731d` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "initialize", abi = "initialize(uint160)")] - pub struct InitializeCall { - pub sqrt_price_x96: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `mint` function with signature `mint(address,int24,int24,uint128,bytes)` and selector `0x3c8a7d8d` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "mint", abi = "mint(address,int24,int24,uint128,bytes)")] - pub struct MintCall { - pub recipient: ::ethers::core::types::Address, - pub tick_lower: i32, - pub tick_upper: i32, - pub amount: u128, - pub data: ::ethers::core::types::Bytes, - } - ///Container type for all input parameters for the `swap` function with signature `swap(address,bool,int256,uint160,bytes)` and selector `0x128acb08` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "swap", abi = "swap(address,bool,int256,uint160,bytes)")] - pub struct SwapCall { - pub recipient: ::ethers::core::types::Address, - pub zero_for_one: bool, - pub amount_specified: ::ethers::core::types::I256, - pub sqrt_price_limit_x96: ::ethers::core::types::U256, - pub data: ::ethers::core::types::Bytes, - } - ///Container type for all of the contract's call - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum IUniswapV3PoolActionsCalls { - Burn(BurnCall), - Collect(CollectCall), - Flash(FlashCall), - IncreaseObservationCardinalityNext(IncreaseObservationCardinalityNextCall), - Initialize(InitializeCall), - Mint(MintCall), - Swap(SwapCall), - } - impl ::ethers::core::abi::AbiDecode for IUniswapV3PoolActionsCalls { - fn decode(data: impl AsRef<[u8]>) -> ::core::result::Result { - let data = data.as_ref(); - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Burn(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Collect(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Flash(decoded)); - } - if let Ok(decoded) = - ::decode(data) - { - return Ok(Self::IncreaseObservationCardinalityNext(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Initialize(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Mint(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Swap(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData.into()) - } - } - impl ::ethers::core::abi::AbiEncode for IUniswapV3PoolActionsCalls { - fn encode(self) -> Vec { - match self { - Self::Burn(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Collect(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Flash(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::IncreaseObservationCardinalityNext(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Initialize(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Mint(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Swap(element) => ::ethers::core::abi::AbiEncode::encode(element), - } - } - } - impl ::core::fmt::Display for IUniswapV3PoolActionsCalls { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::Burn(element) => ::core::fmt::Display::fmt(element, f), - Self::Collect(element) => ::core::fmt::Display::fmt(element, f), - Self::Flash(element) => ::core::fmt::Display::fmt(element, f), - Self::IncreaseObservationCardinalityNext(element) => ::core::fmt::Display::fmt(element, f), - Self::Initialize(element) => ::core::fmt::Display::fmt(element, f), - Self::Mint(element) => ::core::fmt::Display::fmt(element, f), - Self::Swap(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for IUniswapV3PoolActionsCalls { - fn from(value: BurnCall) -> Self { - Self::Burn(value) - } - } - impl ::core::convert::From for IUniswapV3PoolActionsCalls { - fn from(value: CollectCall) -> Self { - Self::Collect(value) - } - } - impl ::core::convert::From for IUniswapV3PoolActionsCalls { - fn from(value: FlashCall) -> Self { - Self::Flash(value) - } - } - impl ::core::convert::From for IUniswapV3PoolActionsCalls { - fn from(value: IncreaseObservationCardinalityNextCall) -> Self { - Self::IncreaseObservationCardinalityNext(value) - } - } - impl ::core::convert::From for IUniswapV3PoolActionsCalls { - fn from(value: InitializeCall) -> Self { - Self::Initialize(value) - } - } - impl ::core::convert::From for IUniswapV3PoolActionsCalls { - fn from(value: MintCall) -> Self { - Self::Mint(value) - } - } - impl ::core::convert::From for IUniswapV3PoolActionsCalls { - fn from(value: SwapCall) -> Self { - Self::Swap(value) - } - } - ///Container type for all return fields from the `burn` function with signature `burn(int24,int24,uint128)` and selector `0xa34123a7` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct BurnReturn { - pub amount_0: ::ethers::core::types::U256, - pub amount_1: ::ethers::core::types::U256, - } - ///Container type for all return fields from the `collect` function with signature `collect(address,int24,int24,uint128,uint128)` and selector `0x4f1eb3d8` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct CollectReturn { - pub amount_0: u128, - pub amount_1: u128, - } - ///Container type for all return fields from the `mint` function with signature `mint(address,int24,int24,uint128,bytes)` and selector `0x3c8a7d8d` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct MintReturn { - pub amount_0: ::ethers::core::types::U256, - pub amount_1: ::ethers::core::types::U256, - } - ///Container type for all return fields from the `swap` function with signature `swap(address,bool,int256,uint160,bytes)` and selector `0x128acb08` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct SwapReturn { - pub amount_0: ::ethers::core::types::I256, - pub amount_1: ::ethers::core::types::I256, - } -} diff --git a/src/bindings/i_uniswap_v3_pool_derived_state.rs b/src/bindings/i_uniswap_v3_pool_derived_state.rs deleted file mode 100644 index 1c7b2bc..0000000 --- a/src/bindings/i_uniswap_v3_pool_derived_state.rs +++ /dev/null @@ -1,280 +0,0 @@ -pub use i_uniswap_v3_pool_derived_state::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod i_uniswap_v3_pool_derived_state { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("observe"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("observe"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("secondsAgos"), - kind: ::ethers::core::abi::ethabi::ParamType::Array(::std::boxed::Box::new( - ::ethers::core::abi::ethabi::ParamType::Uint(32usize), - ),), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint32[]"),), - },], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickCumulatives"), - kind: ::ethers::core::abi::ethabi::ParamType::Array(::std::boxed::Box::new( - ::ethers::core::abi::ethabi::ParamType::Int(56usize), - ),), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "int56[]" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("secondsPerLiquidityCumulativeX128s",), - kind: ::ethers::core::abi::ethabi::ParamType::Array(::std::boxed::Box::new( - ::ethers::core::abi::ethabi::ParamType::Uint(160usize), - ),), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint160[]" - ),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("snapshotCumulativesInside"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("snapshotCumulativesInside",), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickLower"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickUpper"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickCumulativeInside",), - kind: ::ethers::core::abi::ethabi::ParamType::Int(56usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int56"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("secondsPerLiquidityInsideX128",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(160usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint160" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("secondsInside"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(32usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint32"),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ]), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static IUNISWAPV3POOLDERIVEDSTATE_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - pub struct IUniswapV3PoolDerivedState(::ethers::contract::Contract); - impl ::core::clone::Clone for IUniswapV3PoolDerivedState { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for IUniswapV3PoolDerivedState { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for IUniswapV3PoolDerivedState { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for IUniswapV3PoolDerivedState { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(IUniswapV3PoolDerivedState)) - .field(&self.address()) - .finish() - } - } - impl IUniswapV3PoolDerivedState { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - IUNISWAPV3POOLDERIVEDSTATE_ABI.clone(), - client, - )) - } - ///Calls the contract's `observe` (0x883bdbfd) function - pub fn observe( - &self, - seconds_agos: ::std::vec::Vec, - ) -> ::ethers::contract::builders::ContractCall< - M, - (::std::vec::Vec, ::std::vec::Vec<::ethers::core::types::U256>), - > { - self.0 - .method_hash([136, 59, 219, 253], seconds_agos) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `snapshotCumulativesInside` (0xa38807f2) function - pub fn snapshot_cumulatives_inside( - &self, - tick_lower: i32, - tick_upper: i32, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([163, 136, 7, 242], (tick_lower, tick_upper)) - .expect("method not found (this should never happen)") - } - } - impl From<::ethers::contract::Contract> for IUniswapV3PoolDerivedState { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Container type for all input parameters for the `observe` function with signature `observe(uint32[])` and selector `0x883bdbfd` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "observe", abi = "observe(uint32[])")] - pub struct ObserveCall { - pub seconds_agos: ::std::vec::Vec, - } - ///Container type for all input parameters for the `snapshotCumulativesInside` function with signature `snapshotCumulativesInside(int24,int24)` and selector `0xa38807f2` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "snapshotCumulativesInside", abi = "snapshotCumulativesInside(int24,int24)")] - pub struct SnapshotCumulativesInsideCall { - pub tick_lower: i32, - pub tick_upper: i32, - } - ///Container type for all of the contract's call - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum IUniswapV3PoolDerivedStateCalls { - Observe(ObserveCall), - SnapshotCumulativesInside(SnapshotCumulativesInsideCall), - } - impl ::ethers::core::abi::AbiDecode for IUniswapV3PoolDerivedStateCalls { - fn decode(data: impl AsRef<[u8]>) -> ::core::result::Result { - let data = data.as_ref(); - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Observe(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SnapshotCumulativesInside(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData.into()) - } - } - impl ::ethers::core::abi::AbiEncode for IUniswapV3PoolDerivedStateCalls { - fn encode(self) -> Vec { - match self { - Self::Observe(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SnapshotCumulativesInside(element) => ::ethers::core::abi::AbiEncode::encode(element), - } - } - } - impl ::core::fmt::Display for IUniswapV3PoolDerivedStateCalls { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::Observe(element) => ::core::fmt::Display::fmt(element, f), - Self::SnapshotCumulativesInside(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for IUniswapV3PoolDerivedStateCalls { - fn from(value: ObserveCall) -> Self { - Self::Observe(value) - } - } - impl ::core::convert::From for IUniswapV3PoolDerivedStateCalls { - fn from(value: SnapshotCumulativesInsideCall) -> Self { - Self::SnapshotCumulativesInside(value) - } - } - ///Container type for all return fields from the `observe` function with signature `observe(uint32[])` and selector `0x883bdbfd` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct ObserveReturn { - pub tick_cumulatives: ::std::vec::Vec, - pub seconds_per_liquidity_cumulative_x12_8s: ::std::vec::Vec<::ethers::core::types::U256>, - } - ///Container type for all return fields from the `snapshotCumulativesInside` function with signature `snapshotCumulativesInside(int24,int24)` and selector `0xa38807f2` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct SnapshotCumulativesInsideReturn { - pub tick_cumulative_inside: i64, - pub seconds_per_liquidity_inside_x128: ::ethers::core::types::U256, - pub seconds_inside: u32, - } -} diff --git a/src/bindings/i_uniswap_v3_pool_events.rs b/src/bindings/i_uniswap_v3_pool_events.rs deleted file mode 100644 index a8b61a8..0000000 --- a/src/bindings/i_uniswap_v3_pool_events.rs +++ /dev/null @@ -1,726 +0,0 @@ -pub use i_uniswap_v3_pool_events::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod i_uniswap_v3_pool_events { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::std::collections::BTreeMap::new(), - events: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("Burn"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Burn"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tickLower"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tickUpper"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("Collect"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Collect"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("recipient"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tickLower"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tickUpper"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("CollectProtocol"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("CollectProtocol"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("sender"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("recipient"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("Flash"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Flash"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("sender"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("recipient"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("paid0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("paid1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("IncreaseObservationCardinalityNext"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("IncreaseObservationCardinalityNext",), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("observationCardinalityNextOld",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(16usize), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("observationCardinalityNextNew",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(16usize), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("Initialize"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Initialize"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("sqrtPriceX96"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(160usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tick"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("Mint"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Mint"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("sender"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tickLower"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tickUpper"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("SetFeeProtocol"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("SetFeeProtocol"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("feeProtocol0Old"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("feeProtocol1Old"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("feeProtocol0New"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("feeProtocol1New"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("Swap"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Swap"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("sender"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("recipient"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(256usize), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(256usize), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("sqrtPriceX96"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(160usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("liquidity"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - indexed: false, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tick"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ]), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static IUNISWAPV3POOLEVENTS_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - pub struct IUniswapV3PoolEvents(::ethers::contract::Contract); - impl ::core::clone::Clone for IUniswapV3PoolEvents { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for IUniswapV3PoolEvents { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for IUniswapV3PoolEvents { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for IUniswapV3PoolEvents { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(IUniswapV3PoolEvents)) - .field(&self.address()) - .finish() - } - } - impl IUniswapV3PoolEvents { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - IUNISWAPV3POOLEVENTS_ABI.clone(), - client, - )) - } - ///Gets the contract's `Burn` event - pub fn burn_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, BurnFilter> { - self.0.event() - } - ///Gets the contract's `Collect` event - pub fn collect_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, CollectFilter> { - self.0.event() - } - ///Gets the contract's `CollectProtocol` event - pub fn collect_protocol_filter( - &self, - ) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, CollectProtocolFilter> { - self.0.event() - } - ///Gets the contract's `Flash` event - pub fn flash_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, FlashFilter> { - self.0.event() - } - ///Gets the contract's `IncreaseObservationCardinalityNext` event - pub fn increase_observation_cardinality_next_filter( - &self, - ) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, IncreaseObservationCardinalityNextFilter> - { - self.0.event() - } - ///Gets the contract's `Initialize` event - pub fn initialize_filter( - &self, - ) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, InitializeFilter> { - self.0.event() - } - ///Gets the contract's `Mint` event - pub fn mint_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, MintFilter> { - self.0.event() - } - ///Gets the contract's `SetFeeProtocol` event - pub fn set_fee_protocol_filter( - &self, - ) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, SetFeeProtocolFilter> { - self.0.event() - } - ///Gets the contract's `Swap` event - pub fn swap_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, SwapFilter> { - self.0.event() - } - /// Returns an `Event` builder for all the events of this contract. - pub fn events( - &self, - ) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, IUniswapV3PoolEventsEvents> { - self.0.event_with_filter(::core::default::Default::default()) - } - } - impl From<::ethers::contract::Contract> for IUniswapV3PoolEvents { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Burn", abi = "Burn(address,int24,int24,uint128,uint256,uint256)")] - pub struct BurnFilter { - #[ethevent(indexed)] - pub owner: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub tick_lower: i32, - #[ethevent(indexed)] - pub tick_upper: i32, - pub amount: u128, - pub amount_0: ::ethers::core::types::U256, - pub amount_1: ::ethers::core::types::U256, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Collect", abi = "Collect(address,address,int24,int24,uint128,uint128)")] - pub struct CollectFilter { - #[ethevent(indexed)] - pub owner: ::ethers::core::types::Address, - pub recipient: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub tick_lower: i32, - #[ethevent(indexed)] - pub tick_upper: i32, - pub amount_0: u128, - pub amount_1: u128, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "CollectProtocol", abi = "CollectProtocol(address,address,uint128,uint128)")] - pub struct CollectProtocolFilter { - #[ethevent(indexed)] - pub sender: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub recipient: ::ethers::core::types::Address, - pub amount_0: u128, - pub amount_1: u128, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Flash", abi = "Flash(address,address,uint256,uint256,uint256,uint256)")] - pub struct FlashFilter { - #[ethevent(indexed)] - pub sender: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub recipient: ::ethers::core::types::Address, - pub amount_0: ::ethers::core::types::U256, - pub amount_1: ::ethers::core::types::U256, - pub paid_0: ::ethers::core::types::U256, - pub paid_1: ::ethers::core::types::U256, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent( - name = "IncreaseObservationCardinalityNext", - abi = "IncreaseObservationCardinalityNext(uint16,uint16)" - )] - pub struct IncreaseObservationCardinalityNextFilter { - pub observation_cardinality_next_old: u16, - pub observation_cardinality_next_new: u16, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Initialize", abi = "Initialize(uint160,int24)")] - pub struct InitializeFilter { - pub sqrt_price_x96: ::ethers::core::types::U256, - pub tick: i32, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Mint", abi = "Mint(address,address,int24,int24,uint128,uint256,uint256)")] - pub struct MintFilter { - pub sender: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub owner: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub tick_lower: i32, - #[ethevent(indexed)] - pub tick_upper: i32, - pub amount: u128, - pub amount_0: ::ethers::core::types::U256, - pub amount_1: ::ethers::core::types::U256, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "SetFeeProtocol", abi = "SetFeeProtocol(uint8,uint8,uint8,uint8)")] - pub struct SetFeeProtocolFilter { - pub fee_protocol_0_old: u8, - pub fee_protocol_1_old: u8, - pub fee_protocol_0_new: u8, - pub fee_protocol_1_new: u8, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Swap", abi = "Swap(address,address,int256,int256,uint160,uint128,int24)")] - pub struct SwapFilter { - #[ethevent(indexed)] - pub sender: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub recipient: ::ethers::core::types::Address, - pub amount_0: ::ethers::core::types::I256, - pub amount_1: ::ethers::core::types::I256, - pub sqrt_price_x96: ::ethers::core::types::U256, - pub liquidity: u128, - pub tick: i32, - } - ///Container type for all of the contract's events - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum IUniswapV3PoolEventsEvents { - BurnFilter(BurnFilter), - CollectFilter(CollectFilter), - CollectProtocolFilter(CollectProtocolFilter), - FlashFilter(FlashFilter), - IncreaseObservationCardinalityNextFilter(IncreaseObservationCardinalityNextFilter), - InitializeFilter(InitializeFilter), - MintFilter(MintFilter), - SetFeeProtocolFilter(SetFeeProtocolFilter), - SwapFilter(SwapFilter), - } - impl ::ethers::contract::EthLogDecode for IUniswapV3PoolEventsEvents { - fn decode_log(log: &::ethers::core::abi::RawLog) -> ::core::result::Result { - if let Ok(decoded) = BurnFilter::decode_log(log) { - return Ok(IUniswapV3PoolEventsEvents::BurnFilter(decoded)); - } - if let Ok(decoded) = CollectFilter::decode_log(log) { - return Ok(IUniswapV3PoolEventsEvents::CollectFilter(decoded)); - } - if let Ok(decoded) = CollectProtocolFilter::decode_log(log) { - return Ok(IUniswapV3PoolEventsEvents::CollectProtocolFilter(decoded)); - } - if let Ok(decoded) = FlashFilter::decode_log(log) { - return Ok(IUniswapV3PoolEventsEvents::FlashFilter(decoded)); - } - if let Ok(decoded) = IncreaseObservationCardinalityNextFilter::decode_log(log) { - return Ok(IUniswapV3PoolEventsEvents::IncreaseObservationCardinalityNextFilter( - decoded, - )); - } - if let Ok(decoded) = InitializeFilter::decode_log(log) { - return Ok(IUniswapV3PoolEventsEvents::InitializeFilter(decoded)); - } - if let Ok(decoded) = MintFilter::decode_log(log) { - return Ok(IUniswapV3PoolEventsEvents::MintFilter(decoded)); - } - if let Ok(decoded) = SetFeeProtocolFilter::decode_log(log) { - return Ok(IUniswapV3PoolEventsEvents::SetFeeProtocolFilter(decoded)); - } - if let Ok(decoded) = SwapFilter::decode_log(log) { - return Ok(IUniswapV3PoolEventsEvents::SwapFilter(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData) - } - } - impl ::core::fmt::Display for IUniswapV3PoolEventsEvents { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::BurnFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::CollectFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::CollectProtocolFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::FlashFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::IncreaseObservationCardinalityNextFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::InitializeFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::MintFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::SetFeeProtocolFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::SwapFilter(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for IUniswapV3PoolEventsEvents { - fn from(value: BurnFilter) -> Self { - Self::BurnFilter(value) - } - } - impl ::core::convert::From for IUniswapV3PoolEventsEvents { - fn from(value: CollectFilter) -> Self { - Self::CollectFilter(value) - } - } - impl ::core::convert::From for IUniswapV3PoolEventsEvents { - fn from(value: CollectProtocolFilter) -> Self { - Self::CollectProtocolFilter(value) - } - } - impl ::core::convert::From for IUniswapV3PoolEventsEvents { - fn from(value: FlashFilter) -> Self { - Self::FlashFilter(value) - } - } - impl ::core::convert::From for IUniswapV3PoolEventsEvents { - fn from(value: IncreaseObservationCardinalityNextFilter) -> Self { - Self::IncreaseObservationCardinalityNextFilter(value) - } - } - impl ::core::convert::From for IUniswapV3PoolEventsEvents { - fn from(value: InitializeFilter) -> Self { - Self::InitializeFilter(value) - } - } - impl ::core::convert::From for IUniswapV3PoolEventsEvents { - fn from(value: MintFilter) -> Self { - Self::MintFilter(value) - } - } - impl ::core::convert::From for IUniswapV3PoolEventsEvents { - fn from(value: SetFeeProtocolFilter) -> Self { - Self::SetFeeProtocolFilter(value) - } - } - impl ::core::convert::From for IUniswapV3PoolEventsEvents { - fn from(value: SwapFilter) -> Self { - Self::SwapFilter(value) - } - } -} diff --git a/src/bindings/i_uniswap_v3_pool_immutables.rs b/src/bindings/i_uniswap_v3_pool_immutables.rs deleted file mode 100644 index a3b02d0..0000000 --- a/src/bindings/i_uniswap_v3_pool_immutables.rs +++ /dev/null @@ -1,452 +0,0 @@ -pub use i_uniswap_v3_pool_immutables::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod i_uniswap_v3_pool_immutables { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("factory"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("factory"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("fee"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("fee"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint24"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("maxLiquidityPerTick"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("maxLiquidityPerTick",), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint128"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("tickSpacing"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("tickSpacing"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("token0"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("token0"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("token1"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("token1"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ]), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static IUNISWAPV3POOLIMMUTABLES_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - pub struct IUniswapV3PoolImmutables(::ethers::contract::Contract); - impl ::core::clone::Clone for IUniswapV3PoolImmutables { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for IUniswapV3PoolImmutables { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for IUniswapV3PoolImmutables { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for IUniswapV3PoolImmutables { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(IUniswapV3PoolImmutables)) - .field(&self.address()) - .finish() - } - } - impl IUniswapV3PoolImmutables { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - IUNISWAPV3POOLIMMUTABLES_ABI.clone(), - client, - )) - } - ///Calls the contract's `factory` (0xc45a0155) function - pub fn factory(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([196, 90, 1, 85], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `fee` (0xddca3f43) function - pub fn fee(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([221, 202, 63, 67], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `maxLiquidityPerTick` (0x70cf754a) function - pub fn max_liquidity_per_tick(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([112, 207, 117, 74], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `tickSpacing` (0xd0c93a7c) function - pub fn tick_spacing(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([208, 201, 58, 124], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `token0` (0x0dfe1681) function - pub fn token_0(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([13, 254, 22, 129], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `token1` (0xd21220a7) function - pub fn token_1(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([210, 18, 32, 167], ()) - .expect("method not found (this should never happen)") - } - } - impl From<::ethers::contract::Contract> for IUniswapV3PoolImmutables { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Container type for all input parameters for the `factory` function with signature `factory()` and selector `0xc45a0155` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "factory", abi = "factory()")] - pub struct FactoryCall; - ///Container type for all input parameters for the `fee` function with signature `fee()` and selector `0xddca3f43` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "fee", abi = "fee()")] - pub struct FeeCall; - ///Container type for all input parameters for the `maxLiquidityPerTick` function with signature `maxLiquidityPerTick()` and selector `0x70cf754a` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "maxLiquidityPerTick", abi = "maxLiquidityPerTick()")] - pub struct MaxLiquidityPerTickCall; - ///Container type for all input parameters for the `tickSpacing` function with signature `tickSpacing()` and selector `0xd0c93a7c` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "tickSpacing", abi = "tickSpacing()")] - pub struct TickSpacingCall; - ///Container type for all input parameters for the `token0` function with signature `token0()` and selector `0x0dfe1681` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "token0", abi = "token0()")] - pub struct Token0Call; - ///Container type for all input parameters for the `token1` function with signature `token1()` and selector `0xd21220a7` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "token1", abi = "token1()")] - pub struct Token1Call; - ///Container type for all of the contract's call - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum IUniswapV3PoolImmutablesCalls { - Factory(FactoryCall), - Fee(FeeCall), - MaxLiquidityPerTick(MaxLiquidityPerTickCall), - TickSpacing(TickSpacingCall), - Token0(Token0Call), - Token1(Token1Call), - } - impl ::ethers::core::abi::AbiDecode for IUniswapV3PoolImmutablesCalls { - fn decode(data: impl AsRef<[u8]>) -> ::core::result::Result { - let data = data.as_ref(); - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Factory(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Fee(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::MaxLiquidityPerTick(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TickSpacing(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Token0(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Token1(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData.into()) - } - } - impl ::ethers::core::abi::AbiEncode for IUniswapV3PoolImmutablesCalls { - fn encode(self) -> Vec { - match self { - Self::Factory(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Fee(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::MaxLiquidityPerTick(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TickSpacing(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Token0(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Token1(element) => ::ethers::core::abi::AbiEncode::encode(element), - } - } - } - impl ::core::fmt::Display for IUniswapV3PoolImmutablesCalls { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::Factory(element) => ::core::fmt::Display::fmt(element, f), - Self::Fee(element) => ::core::fmt::Display::fmt(element, f), - Self::MaxLiquidityPerTick(element) => ::core::fmt::Display::fmt(element, f), - Self::TickSpacing(element) => ::core::fmt::Display::fmt(element, f), - Self::Token0(element) => ::core::fmt::Display::fmt(element, f), - Self::Token1(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for IUniswapV3PoolImmutablesCalls { - fn from(value: FactoryCall) -> Self { - Self::Factory(value) - } - } - impl ::core::convert::From for IUniswapV3PoolImmutablesCalls { - fn from(value: FeeCall) -> Self { - Self::Fee(value) - } - } - impl ::core::convert::From for IUniswapV3PoolImmutablesCalls { - fn from(value: MaxLiquidityPerTickCall) -> Self { - Self::MaxLiquidityPerTick(value) - } - } - impl ::core::convert::From for IUniswapV3PoolImmutablesCalls { - fn from(value: TickSpacingCall) -> Self { - Self::TickSpacing(value) - } - } - impl ::core::convert::From for IUniswapV3PoolImmutablesCalls { - fn from(value: Token0Call) -> Self { - Self::Token0(value) - } - } - impl ::core::convert::From for IUniswapV3PoolImmutablesCalls { - fn from(value: Token1Call) -> Self { - Self::Token1(value) - } - } - ///Container type for all return fields from the `factory` function with signature `factory()` and selector `0xc45a0155` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct FactoryReturn(pub ::ethers::core::types::Address); - ///Container type for all return fields from the `fee` function with signature `fee()` and selector `0xddca3f43` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct FeeReturn(pub u32); - ///Container type for all return fields from the `maxLiquidityPerTick` function with signature `maxLiquidityPerTick()` and selector `0x70cf754a` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct MaxLiquidityPerTickReturn(pub u128); - ///Container type for all return fields from the `tickSpacing` function with signature `tickSpacing()` and selector `0xd0c93a7c` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct TickSpacingReturn(pub i32); - ///Container type for all return fields from the `token0` function with signature `token0()` and selector `0x0dfe1681` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct Token0Return(pub ::ethers::core::types::Address); - ///Container type for all return fields from the `token1` function with signature `token1()` and selector `0xd21220a7` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct Token1Return(pub ::ethers::core::types::Address); -} diff --git a/src/bindings/i_uniswap_v3_pool_owner_actions.rs b/src/bindings/i_uniswap_v3_pool_owner_actions.rs deleted file mode 100644 index 460f948..0000000 --- a/src/bindings/i_uniswap_v3_pool_owner_actions.rs +++ /dev/null @@ -1,257 +0,0 @@ -pub use i_uniswap_v3_pool_owner_actions::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod i_uniswap_v3_pool_owner_actions { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("collectProtocol"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("collectProtocol"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("recipient"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount0Requested"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount1Requested"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("setFeeProtocol"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("setFeeProtocol"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("feeProtocol0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint8"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("feeProtocol1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint8"),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ]), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static IUNISWAPV3POOLOWNERACTIONS_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - pub struct IUniswapV3PoolOwnerActions(::ethers::contract::Contract); - impl ::core::clone::Clone for IUniswapV3PoolOwnerActions { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for IUniswapV3PoolOwnerActions { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for IUniswapV3PoolOwnerActions { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for IUniswapV3PoolOwnerActions { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(IUniswapV3PoolOwnerActions)) - .field(&self.address()) - .finish() - } - } - impl IUniswapV3PoolOwnerActions { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - IUNISWAPV3POOLOWNERACTIONS_ABI.clone(), - client, - )) - } - ///Calls the contract's `collectProtocol` (0x85b66729) function - pub fn collect_protocol( - &self, - recipient: ::ethers::core::types::Address, - amount_0_requested: u128, - amount_1_requested: u128, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([133, 182, 103, 41], (recipient, amount_0_requested, amount_1_requested)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `setFeeProtocol` (0x8206a4d1) function - pub fn set_fee_protocol( - &self, - fee_protocol_0: u8, - fee_protocol_1: u8, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([130, 6, 164, 209], (fee_protocol_0, fee_protocol_1)) - .expect("method not found (this should never happen)") - } - } - impl From<::ethers::contract::Contract> for IUniswapV3PoolOwnerActions { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Container type for all input parameters for the `collectProtocol` function with signature `collectProtocol(address,uint128,uint128)` and selector `0x85b66729` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "collectProtocol", abi = "collectProtocol(address,uint128,uint128)")] - pub struct CollectProtocolCall { - pub recipient: ::ethers::core::types::Address, - pub amount_0_requested: u128, - pub amount_1_requested: u128, - } - ///Container type for all input parameters for the `setFeeProtocol` function with signature `setFeeProtocol(uint8,uint8)` and selector `0x8206a4d1` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "setFeeProtocol", abi = "setFeeProtocol(uint8,uint8)")] - pub struct SetFeeProtocolCall { - pub fee_protocol_0: u8, - pub fee_protocol_1: u8, - } - ///Container type for all of the contract's call - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum IUniswapV3PoolOwnerActionsCalls { - CollectProtocol(CollectProtocolCall), - SetFeeProtocol(SetFeeProtocolCall), - } - impl ::ethers::core::abi::AbiDecode for IUniswapV3PoolOwnerActionsCalls { - fn decode(data: impl AsRef<[u8]>) -> ::core::result::Result { - let data = data.as_ref(); - if let Ok(decoded) = ::decode(data) { - return Ok(Self::CollectProtocol(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SetFeeProtocol(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData.into()) - } - } - impl ::ethers::core::abi::AbiEncode for IUniswapV3PoolOwnerActionsCalls { - fn encode(self) -> Vec { - match self { - Self::CollectProtocol(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SetFeeProtocol(element) => ::ethers::core::abi::AbiEncode::encode(element), - } - } - } - impl ::core::fmt::Display for IUniswapV3PoolOwnerActionsCalls { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::CollectProtocol(element) => ::core::fmt::Display::fmt(element, f), - Self::SetFeeProtocol(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for IUniswapV3PoolOwnerActionsCalls { - fn from(value: CollectProtocolCall) -> Self { - Self::CollectProtocol(value) - } - } - impl ::core::convert::From for IUniswapV3PoolOwnerActionsCalls { - fn from(value: SetFeeProtocolCall) -> Self { - Self::SetFeeProtocol(value) - } - } - ///Container type for all return fields from the `collectProtocol` function with signature `collectProtocol(address,uint128,uint128)` and selector `0x85b66729` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct CollectProtocolReturn { - pub amount_0: u128, - pub amount_1: u128, - } -} diff --git a/src/bindings/i_uniswap_v3_pool_state.rs b/src/bindings/i_uniswap_v3_pool_state.rs deleted file mode 100644 index 6726c0b..0000000 --- a/src/bindings/i_uniswap_v3_pool_state.rs +++ /dev/null @@ -1,868 +0,0 @@ -pub use i_uniswap_v3_pool_state::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod i_uniswap_v3_pool_state { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("feeGrowthGlobal0X128"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("feeGrowthGlobal0X128",), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("feeGrowthGlobal1X128"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("feeGrowthGlobal1X128",), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("liquidity"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("liquidity"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint128"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("observations"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("observations"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("index"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("blockTimestamp"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(32usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint32"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickCumulative"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(56usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int56"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("secondsPerLiquidityCumulativeX128",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(160usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint160" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("initialized"), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("positions"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("positions"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("key"), - kind: ::ethers::core::abi::ethabi::ParamType::FixedBytes(32usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes32"),), - },], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("_liquidity"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("feeGrowthInside0LastX128",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("feeGrowthInside1LastX128",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokensOwed0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokensOwed1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("protocolFees"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("protocolFees"), - inputs: ::std::vec![], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("token0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("token1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("slot0"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("slot0"), - inputs: ::std::vec![], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("sqrtPriceX96"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(160usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint160" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tick"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("observationIndex"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(16usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint16"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("observationCardinality",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(16usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint16"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("observationCardinalityNext",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(16usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint16"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("feeProtocol"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint8"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("unlocked"), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("tickBitmap"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("tickBitmap"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("wordPosition"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(16usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int16"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("ticks"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("ticks"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tick"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - },], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("liquidityGross"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("liquidityNet"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(128usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int128"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("feeGrowthOutside0X128",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("feeGrowthOutside1X128",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickCumulativeOutside",), - kind: ::ethers::core::abi::ethabi::ParamType::Int(56usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int56"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("secondsPerLiquidityOutsideX128",), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(160usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint160" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("secondsOutside"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(32usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint32"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("initialized"), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ]), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static IUNISWAPV3POOLSTATE_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - pub struct IUniswapV3PoolState(::ethers::contract::Contract); - impl ::core::clone::Clone for IUniswapV3PoolState { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for IUniswapV3PoolState { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for IUniswapV3PoolState { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for IUniswapV3PoolState { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(IUniswapV3PoolState)) - .field(&self.address()) - .finish() - } - } - impl IUniswapV3PoolState { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - IUNISWAPV3POOLSTATE_ABI.clone(), - client, - )) - } - ///Calls the contract's `feeGrowthGlobal0X128` (0xf3058399) function - pub fn fee_growth_global_0x128( - &self, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([243, 5, 131, 153], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `feeGrowthGlobal1X128` (0x46141319) function - pub fn fee_growth_global_1x128( - &self, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([70, 20, 19, 25], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `liquidity` (0x1a686502) function - pub fn liquidity(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([26, 104, 101, 2], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `observations` (0x252c09d7) function - pub fn observations( - &self, - index: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([37, 44, 9, 215], index) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `positions` (0x514ea4bf) function - pub fn positions( - &self, - key: [u8; 32], - ) -> ::ethers::contract::builders::ContractCall< - M, - ( - u128, - ::ethers::core::types::U256, - ::ethers::core::types::U256, - u128, - u128, - ), - > { - self.0 - .method_hash([81, 78, 164, 191], key) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `protocolFees` (0x1ad8b03b) function - pub fn protocol_fees(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([26, 216, 176, 59], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `slot0` (0x3850c7bd) function - pub fn slot_0( - &self, - ) -> ::ethers::contract::builders::ContractCall - { - self.0 - .method_hash([56, 80, 199, 189], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `tickBitmap` (0x5339c296) function - pub fn tick_bitmap( - &self, - word_position: i16, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([83, 57, 194, 150], word_position) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `ticks` (0xf30dba93) function - pub fn ticks( - &self, - tick: i32, - ) -> ::ethers::contract::builders::ContractCall< - M, - ( - u128, - i128, - ::ethers::core::types::U256, - ::ethers::core::types::U256, - i64, - ::ethers::core::types::U256, - u32, - bool, - ), - > { - self.0 - .method_hash([243, 13, 186, 147], tick) - .expect("method not found (this should never happen)") - } - } - impl From<::ethers::contract::Contract> for IUniswapV3PoolState { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Container type for all input parameters for the `feeGrowthGlobal0X128` function with signature `feeGrowthGlobal0X128()` and selector `0xf3058399` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "feeGrowthGlobal0X128", abi = "feeGrowthGlobal0X128()")] - pub struct FeeGrowthGlobal0X128Call; - ///Container type for all input parameters for the `feeGrowthGlobal1X128` function with signature `feeGrowthGlobal1X128()` and selector `0x46141319` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "feeGrowthGlobal1X128", abi = "feeGrowthGlobal1X128()")] - pub struct FeeGrowthGlobal1X128Call; - ///Container type for all input parameters for the `liquidity` function with signature `liquidity()` and selector `0x1a686502` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "liquidity", abi = "liquidity()")] - pub struct LiquidityCall; - ///Container type for all input parameters for the `observations` function with signature `observations(uint256)` and selector `0x252c09d7` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "observations", abi = "observations(uint256)")] - pub struct ObservationsCall { - pub index: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `positions` function with signature `positions(bytes32)` and selector `0x514ea4bf` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "positions", abi = "positions(bytes32)")] - pub struct PositionsCall { - pub key: [u8; 32], - } - ///Container type for all input parameters for the `protocolFees` function with signature `protocolFees()` and selector `0x1ad8b03b` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "protocolFees", abi = "protocolFees()")] - pub struct ProtocolFeesCall; - ///Container type for all input parameters for the `slot0` function with signature `slot0()` and selector `0x3850c7bd` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "slot0", abi = "slot0()")] - pub struct Slot0Call; - ///Container type for all input parameters for the `tickBitmap` function with signature `tickBitmap(int16)` and selector `0x5339c296` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "tickBitmap", abi = "tickBitmap(int16)")] - pub struct TickBitmapCall { - pub word_position: i16, - } - ///Container type for all input parameters for the `ticks` function with signature `ticks(int24)` and selector `0xf30dba93` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "ticks", abi = "ticks(int24)")] - pub struct TicksCall { - pub tick: i32, - } - ///Container type for all of the contract's call - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum IUniswapV3PoolStateCalls { - FeeGrowthGlobal0X128(FeeGrowthGlobal0X128Call), - FeeGrowthGlobal1X128(FeeGrowthGlobal1X128Call), - Liquidity(LiquidityCall), - Observations(ObservationsCall), - Positions(PositionsCall), - ProtocolFees(ProtocolFeesCall), - Slot0(Slot0Call), - TickBitmap(TickBitmapCall), - Ticks(TicksCall), - } - impl ::ethers::core::abi::AbiDecode for IUniswapV3PoolStateCalls { - fn decode(data: impl AsRef<[u8]>) -> ::core::result::Result { - let data = data.as_ref(); - if let Ok(decoded) = ::decode(data) { - return Ok(Self::FeeGrowthGlobal0X128(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::FeeGrowthGlobal1X128(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Liquidity(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Observations(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Positions(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::ProtocolFees(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Slot0(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TickBitmap(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Ticks(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData.into()) - } - } - impl ::ethers::core::abi::AbiEncode for IUniswapV3PoolStateCalls { - fn encode(self) -> Vec { - match self { - Self::FeeGrowthGlobal0X128(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::FeeGrowthGlobal1X128(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Liquidity(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Observations(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Positions(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::ProtocolFees(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Slot0(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TickBitmap(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Ticks(element) => ::ethers::core::abi::AbiEncode::encode(element), - } - } - } - impl ::core::fmt::Display for IUniswapV3PoolStateCalls { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::FeeGrowthGlobal0X128(element) => ::core::fmt::Display::fmt(element, f), - Self::FeeGrowthGlobal1X128(element) => ::core::fmt::Display::fmt(element, f), - Self::Liquidity(element) => ::core::fmt::Display::fmt(element, f), - Self::Observations(element) => ::core::fmt::Display::fmt(element, f), - Self::Positions(element) => ::core::fmt::Display::fmt(element, f), - Self::ProtocolFees(element) => ::core::fmt::Display::fmt(element, f), - Self::Slot0(element) => ::core::fmt::Display::fmt(element, f), - Self::TickBitmap(element) => ::core::fmt::Display::fmt(element, f), - Self::Ticks(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for IUniswapV3PoolStateCalls { - fn from(value: FeeGrowthGlobal0X128Call) -> Self { - Self::FeeGrowthGlobal0X128(value) - } - } - impl ::core::convert::From for IUniswapV3PoolStateCalls { - fn from(value: FeeGrowthGlobal1X128Call) -> Self { - Self::FeeGrowthGlobal1X128(value) - } - } - impl ::core::convert::From for IUniswapV3PoolStateCalls { - fn from(value: LiquidityCall) -> Self { - Self::Liquidity(value) - } - } - impl ::core::convert::From for IUniswapV3PoolStateCalls { - fn from(value: ObservationsCall) -> Self { - Self::Observations(value) - } - } - impl ::core::convert::From for IUniswapV3PoolStateCalls { - fn from(value: PositionsCall) -> Self { - Self::Positions(value) - } - } - impl ::core::convert::From for IUniswapV3PoolStateCalls { - fn from(value: ProtocolFeesCall) -> Self { - Self::ProtocolFees(value) - } - } - impl ::core::convert::From for IUniswapV3PoolStateCalls { - fn from(value: Slot0Call) -> Self { - Self::Slot0(value) - } - } - impl ::core::convert::From for IUniswapV3PoolStateCalls { - fn from(value: TickBitmapCall) -> Self { - Self::TickBitmap(value) - } - } - impl ::core::convert::From for IUniswapV3PoolStateCalls { - fn from(value: TicksCall) -> Self { - Self::Ticks(value) - } - } - ///Container type for all return fields from the `feeGrowthGlobal0X128` function with signature `feeGrowthGlobal0X128()` and selector `0xf3058399` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct FeeGrowthGlobal0X128Return(pub ::ethers::core::types::U256); - ///Container type for all return fields from the `feeGrowthGlobal1X128` function with signature `feeGrowthGlobal1X128()` and selector `0x46141319` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct FeeGrowthGlobal1X128Return(pub ::ethers::core::types::U256); - ///Container type for all return fields from the `liquidity` function with signature `liquidity()` and selector `0x1a686502` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct LiquidityReturn(pub u128); - ///Container type for all return fields from the `observations` function with signature `observations(uint256)` and selector `0x252c09d7` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct ObservationsReturn { - pub block_timestamp: u32, - pub tick_cumulative: i64, - pub seconds_per_liquidity_cumulative_x128: ::ethers::core::types::U256, - pub initialized: bool, - } - ///Container type for all return fields from the `positions` function with signature `positions(bytes32)` and selector `0x514ea4bf` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct PositionsReturn { - pub liquidity: u128, - pub fee_growth_inside_0_last_x128: ::ethers::core::types::U256, - pub fee_growth_inside_1_last_x128: ::ethers::core::types::U256, - pub tokens_owed_0: u128, - pub tokens_owed_1: u128, - } - ///Container type for all return fields from the `protocolFees` function with signature `protocolFees()` and selector `0x1ad8b03b` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct ProtocolFeesReturn { - pub token_0: u128, - pub token_1: u128, - } - ///Container type for all return fields from the `slot0` function with signature `slot0()` and selector `0x3850c7bd` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct Slot0Return { - pub sqrt_price_x96: ::ethers::core::types::U256, - pub tick: i32, - pub observation_index: u16, - pub observation_cardinality: u16, - pub observation_cardinality_next: u16, - pub fee_protocol: u8, - pub unlocked: bool, - } - ///Container type for all return fields from the `tickBitmap` function with signature `tickBitmap(int16)` and selector `0x5339c296` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct TickBitmapReturn(pub ::ethers::core::types::U256); - ///Container type for all return fields from the `ticks` function with signature `ticks(int24)` and selector `0xf30dba93` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct TicksReturn { - pub liquidity_gross: u128, - pub liquidity_net: i128, - pub fee_growth_outside_0x128: ::ethers::core::types::U256, - pub fee_growth_outside_1x128: ::ethers::core::types::U256, - pub tick_cumulative_outside: i64, - pub seconds_per_liquidity_outside_x128: ::ethers::core::types::U256, - pub seconds_outside: u32, - pub initialized: bool, - } -} diff --git a/src/bindings/i_uniswap_v3_swap_callback.rs b/src/bindings/i_uniswap_v3_swap_callback.rs deleted file mode 100644 index 97863a7..0000000 --- a/src/bindings/i_uniswap_v3_swap_callback.rs +++ /dev/null @@ -1,122 +0,0 @@ -pub use i_uniswap_v3_swap_callback::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod i_uniswap_v3_swap_callback { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([( - ::std::borrow::ToOwned::to_owned("uniswapV3SwapCallback"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("uniswapV3SwapCallback",), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount0Delta"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(256usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int256"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount1Delta"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(256usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int256"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("data"), - kind: ::ethers::core::abi::ethabi::ParamType::Bytes, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes"),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - )]), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static IUNISWAPV3SWAPCALLBACK_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - pub struct IUniswapV3SwapCallback(::ethers::contract::Contract); - impl ::core::clone::Clone for IUniswapV3SwapCallback { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for IUniswapV3SwapCallback { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for IUniswapV3SwapCallback { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for IUniswapV3SwapCallback { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(IUniswapV3SwapCallback)) - .field(&self.address()) - .finish() - } - } - impl IUniswapV3SwapCallback { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - IUNISWAPV3SWAPCALLBACK_ABI.clone(), - client, - )) - } - ///Calls the contract's `uniswapV3SwapCallback` (0xfa461e33) function - pub fn uniswap_v3_swap_callback( - &self, - amount_0_delta: ::ethers::core::types::I256, - amount_1_delta: ::ethers::core::types::I256, - data: ::ethers::core::types::Bytes, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([250, 70, 30, 51], (amount_0_delta, amount_1_delta, data)) - .expect("method not found (this should never happen)") - } - } - impl From<::ethers::contract::Contract> for IUniswapV3SwapCallback { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Container type for all input parameters for the `uniswapV3SwapCallback` function with signature `uniswapV3SwapCallback(int256,int256,bytes)` and selector `0xfa461e33` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "uniswapV3SwapCallback", abi = "uniswapV3SwapCallback(int256,int256,bytes)")] - pub struct UniswapV3SwapCallbackCall { - pub amount_0_delta: ::ethers::core::types::I256, - pub amount_1_delta: ::ethers::core::types::I256, - pub data: ::ethers::core::types::Bytes, - } -} diff --git a/src/bindings/ierc165.rs b/src/bindings/ierc165.rs deleted file mode 100644 index 73eeb6c..0000000 --- a/src/bindings/ierc165.rs +++ /dev/null @@ -1,120 +0,0 @@ -pub use ierc165::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod ierc165 { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([( - ::std::borrow::ToOwned::to_owned("supportsInterface"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("supportsInterface"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("interfaceId"), - kind: ::ethers::core::abi::ethabi::ParamType::FixedBytes(4usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes4"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - )]), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static IERC165_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = ::ethers::contract::Lazy::new(__abi); - pub struct IERC165(::ethers::contract::Contract); - impl ::core::clone::Clone for IERC165 { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for IERC165 { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for IERC165 { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for IERC165 { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(IERC165)) - .field(&self.address()) - .finish() - } - } - impl IERC165 { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - IERC165_ABI.clone(), - client, - )) - } - ///Calls the contract's `supportsInterface` (0x01ffc9a7) function - pub fn supports_interface(&self, interface_id: [u8; 4]) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([1, 255, 201, 167], interface_id) - .expect("method not found (this should never happen)") - } - } - impl From<::ethers::contract::Contract> for IERC165 { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Container type for all input parameters for the `supportsInterface` function with signature `supportsInterface(bytes4)` and selector `0x01ffc9a7` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "supportsInterface", abi = "supportsInterface(bytes4)")] - pub struct SupportsInterfaceCall { - pub interface_id: [u8; 4], - } - ///Container type for all return fields from the `supportsInterface` function with signature `supportsInterface(bytes4)` and selector `0x01ffc9a7` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct SupportsInterfaceReturn(pub bool); -} diff --git a/src/bindings/ierc20.rs b/src/bindings/ierc20.rs deleted file mode 100644 index e9d0df7..0000000 --- a/src/bindings/ierc20.rs +++ /dev/null @@ -1,695 +0,0 @@ -pub use ierc20::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod ierc20 { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("allowance"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("allowance"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("spender"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("approve"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("approve"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("spender"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("value"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("balanceOf"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("balanceOf"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("account"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("totalSupply"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("totalSupply"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("transfer"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("transfer"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("value"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("transferFrom"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("transferFrom"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("value"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ]), - events: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("Approval"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Approval"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("spender"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("value"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("Transfer"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Transfer"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("value"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ]), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static IERC20_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = ::ethers::contract::Lazy::new(__abi); - pub struct IERC20(::ethers::contract::Contract); - impl ::core::clone::Clone for IERC20 { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for IERC20 { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for IERC20 { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for IERC20 { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(IERC20)) - .field(&self.address()) - .finish() - } - } - impl IERC20 { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - IERC20_ABI.clone(), - client, - )) - } - ///Calls the contract's `allowance` (0xdd62ed3e) function - pub fn allowance( - &self, - owner: ::ethers::core::types::Address, - spender: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([221, 98, 237, 62], (owner, spender)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `approve` (0x095ea7b3) function - pub fn approve( - &self, - spender: ::ethers::core::types::Address, - value: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([9, 94, 167, 179], (spender, value)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `balanceOf` (0x70a08231) function - pub fn balance_of( - &self, - account: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([112, 160, 130, 49], account) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `totalSupply` (0x18160ddd) function - pub fn total_supply(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([24, 22, 13, 221], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `transfer` (0xa9059cbb) function - pub fn transfer( - &self, - to: ::ethers::core::types::Address, - value: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([169, 5, 156, 187], (to, value)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `transferFrom` (0x23b872dd) function - pub fn transfer_from( - &self, - from: ::ethers::core::types::Address, - to: ::ethers::core::types::Address, - value: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([35, 184, 114, 221], (from, to, value)) - .expect("method not found (this should never happen)") - } - ///Gets the contract's `Approval` event - pub fn approval_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, ApprovalFilter> { - self.0.event() - } - ///Gets the contract's `Transfer` event - pub fn transfer_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, TransferFilter> { - self.0.event() - } - /// Returns an `Event` builder for all the events of this contract. - pub fn events(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, IERC20Events> { - self.0.event_with_filter(::core::default::Default::default()) - } - } - impl From<::ethers::contract::Contract> for IERC20 { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Approval", abi = "Approval(address,address,uint256)")] - pub struct ApprovalFilter { - #[ethevent(indexed)] - pub owner: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub spender: ::ethers::core::types::Address, - pub value: ::ethers::core::types::U256, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Transfer", abi = "Transfer(address,address,uint256)")] - pub struct TransferFilter { - #[ethevent(indexed)] - pub from: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub to: ::ethers::core::types::Address, - pub value: ::ethers::core::types::U256, - } - ///Container type for all of the contract's events - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum IERC20Events { - ApprovalFilter(ApprovalFilter), - TransferFilter(TransferFilter), - } - impl ::ethers::contract::EthLogDecode for IERC20Events { - fn decode_log(log: &::ethers::core::abi::RawLog) -> ::core::result::Result { - if let Ok(decoded) = ApprovalFilter::decode_log(log) { - return Ok(IERC20Events::ApprovalFilter(decoded)); - } - if let Ok(decoded) = TransferFilter::decode_log(log) { - return Ok(IERC20Events::TransferFilter(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData) - } - } - impl ::core::fmt::Display for IERC20Events { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::ApprovalFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::TransferFilter(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for IERC20Events { - fn from(value: ApprovalFilter) -> Self { - Self::ApprovalFilter(value) - } - } - impl ::core::convert::From for IERC20Events { - fn from(value: TransferFilter) -> Self { - Self::TransferFilter(value) - } - } - ///Container type for all input parameters for the `allowance` function with signature `allowance(address,address)` and selector `0xdd62ed3e` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "allowance", abi = "allowance(address,address)")] - pub struct AllowanceCall { - pub owner: ::ethers::core::types::Address, - pub spender: ::ethers::core::types::Address, - } - ///Container type for all input parameters for the `approve` function with signature `approve(address,uint256)` and selector `0x095ea7b3` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "approve", abi = "approve(address,uint256)")] - pub struct ApproveCall { - pub spender: ::ethers::core::types::Address, - pub value: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `balanceOf` function with signature `balanceOf(address)` and selector `0x70a08231` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "balanceOf", abi = "balanceOf(address)")] - pub struct BalanceOfCall { - pub account: ::ethers::core::types::Address, - } - ///Container type for all input parameters for the `totalSupply` function with signature `totalSupply()` and selector `0x18160ddd` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "totalSupply", abi = "totalSupply()")] - pub struct TotalSupplyCall; - ///Container type for all input parameters for the `transfer` function with signature `transfer(address,uint256)` and selector `0xa9059cbb` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "transfer", abi = "transfer(address,uint256)")] - pub struct TransferCall { - pub to: ::ethers::core::types::Address, - pub value: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `transferFrom` function with signature `transferFrom(address,address,uint256)` and selector `0x23b872dd` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "transferFrom", abi = "transferFrom(address,address,uint256)")] - pub struct TransferFromCall { - pub from: ::ethers::core::types::Address, - pub to: ::ethers::core::types::Address, - pub value: ::ethers::core::types::U256, - } - ///Container type for all of the contract's call - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum IERC20Calls { - Allowance(AllowanceCall), - Approve(ApproveCall), - BalanceOf(BalanceOfCall), - TotalSupply(TotalSupplyCall), - Transfer(TransferCall), - TransferFrom(TransferFromCall), - } - impl ::ethers::core::abi::AbiDecode for IERC20Calls { - fn decode(data: impl AsRef<[u8]>) -> ::core::result::Result { - let data = data.as_ref(); - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Allowance(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Approve(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::BalanceOf(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TotalSupply(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Transfer(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TransferFrom(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData.into()) - } - } - impl ::ethers::core::abi::AbiEncode for IERC20Calls { - fn encode(self) -> Vec { - match self { - Self::Allowance(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Approve(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::BalanceOf(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TotalSupply(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Transfer(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TransferFrom(element) => ::ethers::core::abi::AbiEncode::encode(element), - } - } - } - impl ::core::fmt::Display for IERC20Calls { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::Allowance(element) => ::core::fmt::Display::fmt(element, f), - Self::Approve(element) => ::core::fmt::Display::fmt(element, f), - Self::BalanceOf(element) => ::core::fmt::Display::fmt(element, f), - Self::TotalSupply(element) => ::core::fmt::Display::fmt(element, f), - Self::Transfer(element) => ::core::fmt::Display::fmt(element, f), - Self::TransferFrom(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for IERC20Calls { - fn from(value: AllowanceCall) -> Self { - Self::Allowance(value) - } - } - impl ::core::convert::From for IERC20Calls { - fn from(value: ApproveCall) -> Self { - Self::Approve(value) - } - } - impl ::core::convert::From for IERC20Calls { - fn from(value: BalanceOfCall) -> Self { - Self::BalanceOf(value) - } - } - impl ::core::convert::From for IERC20Calls { - fn from(value: TotalSupplyCall) -> Self { - Self::TotalSupply(value) - } - } - impl ::core::convert::From for IERC20Calls { - fn from(value: TransferCall) -> Self { - Self::Transfer(value) - } - } - impl ::core::convert::From for IERC20Calls { - fn from(value: TransferFromCall) -> Self { - Self::TransferFrom(value) - } - } - ///Container type for all return fields from the `allowance` function with signature `allowance(address,address)` and selector `0xdd62ed3e` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct AllowanceReturn(pub ::ethers::core::types::U256); - ///Container type for all return fields from the `approve` function with signature `approve(address,uint256)` and selector `0x095ea7b3` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct ApproveReturn(pub bool); - ///Container type for all return fields from the `balanceOf` function with signature `balanceOf(address)` and selector `0x70a08231` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct BalanceOfReturn(pub ::ethers::core::types::U256); - ///Container type for all return fields from the `totalSupply` function with signature `totalSupply()` and selector `0x18160ddd` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct TotalSupplyReturn(pub ::ethers::core::types::U256); - ///Container type for all return fields from the `transfer` function with signature `transfer(address,uint256)` and selector `0xa9059cbb` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct TransferReturn(pub bool); - ///Container type for all return fields from the `transferFrom` function with signature `transferFrom(address,address,uint256)` and selector `0x23b872dd` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct TransferFromReturn(pub bool); -} diff --git a/src/bindings/ierc20_metadata.rs b/src/bindings/ierc20_metadata.rs deleted file mode 100644 index c8e733a..0000000 --- a/src/bindings/ierc20_metadata.rs +++ /dev/null @@ -1,876 +0,0 @@ -pub use ierc20_metadata::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod ierc20_metadata { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("allowance"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("allowance"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("spender"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("approve"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("approve"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("spender"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("value"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("balanceOf"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("balanceOf"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("account"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("decimals"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("decimals"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint8"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("name"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("name"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::String, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("string"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("symbol"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("symbol"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::String, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("string"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("totalSupply"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("totalSupply"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("transfer"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("transfer"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("value"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("transferFrom"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("transferFrom"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("value"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ]), - events: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("Approval"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Approval"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("spender"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("value"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("Transfer"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Transfer"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("value"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ]), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static IERC20METADATA_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - pub struct IERC20Metadata(::ethers::contract::Contract); - impl ::core::clone::Clone for IERC20Metadata { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for IERC20Metadata { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for IERC20Metadata { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for IERC20Metadata { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(IERC20Metadata)) - .field(&self.address()) - .finish() - } - } - impl IERC20Metadata { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - IERC20METADATA_ABI.clone(), - client, - )) - } - ///Calls the contract's `allowance` (0xdd62ed3e) function - pub fn allowance( - &self, - owner: ::ethers::core::types::Address, - spender: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([221, 98, 237, 62], (owner, spender)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `approve` (0x095ea7b3) function - pub fn approve( - &self, - spender: ::ethers::core::types::Address, - value: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([9, 94, 167, 179], (spender, value)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `balanceOf` (0x70a08231) function - pub fn balance_of( - &self, - account: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([112, 160, 130, 49], account) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `decimals` (0x313ce567) function - pub fn decimals(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([49, 60, 229, 103], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `name` (0x06fdde03) function - pub fn name(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([6, 253, 222, 3], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `symbol` (0x95d89b41) function - pub fn symbol(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([149, 216, 155, 65], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `totalSupply` (0x18160ddd) function - pub fn total_supply(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([24, 22, 13, 221], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `transfer` (0xa9059cbb) function - pub fn transfer( - &self, - to: ::ethers::core::types::Address, - value: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([169, 5, 156, 187], (to, value)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `transferFrom` (0x23b872dd) function - pub fn transfer_from( - &self, - from: ::ethers::core::types::Address, - to: ::ethers::core::types::Address, - value: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([35, 184, 114, 221], (from, to, value)) - .expect("method not found (this should never happen)") - } - ///Gets the contract's `Approval` event - pub fn approval_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, ApprovalFilter> { - self.0.event() - } - ///Gets the contract's `Transfer` event - pub fn transfer_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, TransferFilter> { - self.0.event() - } - /// Returns an `Event` builder for all the events of this contract. - pub fn events(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, IERC20MetadataEvents> { - self.0.event_with_filter(::core::default::Default::default()) - } - } - impl From<::ethers::contract::Contract> for IERC20Metadata { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Approval", abi = "Approval(address,address,uint256)")] - pub struct ApprovalFilter { - #[ethevent(indexed)] - pub owner: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub spender: ::ethers::core::types::Address, - pub value: ::ethers::core::types::U256, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Transfer", abi = "Transfer(address,address,uint256)")] - pub struct TransferFilter { - #[ethevent(indexed)] - pub from: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub to: ::ethers::core::types::Address, - pub value: ::ethers::core::types::U256, - } - ///Container type for all of the contract's events - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum IERC20MetadataEvents { - ApprovalFilter(ApprovalFilter), - TransferFilter(TransferFilter), - } - impl ::ethers::contract::EthLogDecode for IERC20MetadataEvents { - fn decode_log(log: &::ethers::core::abi::RawLog) -> ::core::result::Result { - if let Ok(decoded) = ApprovalFilter::decode_log(log) { - return Ok(IERC20MetadataEvents::ApprovalFilter(decoded)); - } - if let Ok(decoded) = TransferFilter::decode_log(log) { - return Ok(IERC20MetadataEvents::TransferFilter(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData) - } - } - impl ::core::fmt::Display for IERC20MetadataEvents { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::ApprovalFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::TransferFilter(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for IERC20MetadataEvents { - fn from(value: ApprovalFilter) -> Self { - Self::ApprovalFilter(value) - } - } - impl ::core::convert::From for IERC20MetadataEvents { - fn from(value: TransferFilter) -> Self { - Self::TransferFilter(value) - } - } - ///Container type for all input parameters for the `allowance` function with signature `allowance(address,address)` and selector `0xdd62ed3e` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "allowance", abi = "allowance(address,address)")] - pub struct AllowanceCall { - pub owner: ::ethers::core::types::Address, - pub spender: ::ethers::core::types::Address, - } - ///Container type for all input parameters for the `approve` function with signature `approve(address,uint256)` and selector `0x095ea7b3` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "approve", abi = "approve(address,uint256)")] - pub struct ApproveCall { - pub spender: ::ethers::core::types::Address, - pub value: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `balanceOf` function with signature `balanceOf(address)` and selector `0x70a08231` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "balanceOf", abi = "balanceOf(address)")] - pub struct BalanceOfCall { - pub account: ::ethers::core::types::Address, - } - ///Container type for all input parameters for the `decimals` function with signature `decimals()` and selector `0x313ce567` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "decimals", abi = "decimals()")] - pub struct DecimalsCall; - ///Container type for all input parameters for the `name` function with signature `name()` and selector `0x06fdde03` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "name", abi = "name()")] - pub struct NameCall; - ///Container type for all input parameters for the `symbol` function with signature `symbol()` and selector `0x95d89b41` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "symbol", abi = "symbol()")] - pub struct SymbolCall; - ///Container type for all input parameters for the `totalSupply` function with signature `totalSupply()` and selector `0x18160ddd` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "totalSupply", abi = "totalSupply()")] - pub struct TotalSupplyCall; - ///Container type for all input parameters for the `transfer` function with signature `transfer(address,uint256)` and selector `0xa9059cbb` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "transfer", abi = "transfer(address,uint256)")] - pub struct TransferCall { - pub to: ::ethers::core::types::Address, - pub value: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `transferFrom` function with signature `transferFrom(address,address,uint256)` and selector `0x23b872dd` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "transferFrom", abi = "transferFrom(address,address,uint256)")] - pub struct TransferFromCall { - pub from: ::ethers::core::types::Address, - pub to: ::ethers::core::types::Address, - pub value: ::ethers::core::types::U256, - } - ///Container type for all of the contract's call - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum IERC20MetadataCalls { - Allowance(AllowanceCall), - Approve(ApproveCall), - BalanceOf(BalanceOfCall), - Decimals(DecimalsCall), - Name(NameCall), - Symbol(SymbolCall), - TotalSupply(TotalSupplyCall), - Transfer(TransferCall), - TransferFrom(TransferFromCall), - } - impl ::ethers::core::abi::AbiDecode for IERC20MetadataCalls { - fn decode(data: impl AsRef<[u8]>) -> ::core::result::Result { - let data = data.as_ref(); - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Allowance(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Approve(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::BalanceOf(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Decimals(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Name(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Symbol(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TotalSupply(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Transfer(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TransferFrom(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData.into()) - } - } - impl ::ethers::core::abi::AbiEncode for IERC20MetadataCalls { - fn encode(self) -> Vec { - match self { - Self::Allowance(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Approve(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::BalanceOf(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Decimals(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Name(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Symbol(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TotalSupply(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Transfer(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TransferFrom(element) => ::ethers::core::abi::AbiEncode::encode(element), - } - } - } - impl ::core::fmt::Display for IERC20MetadataCalls { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::Allowance(element) => ::core::fmt::Display::fmt(element, f), - Self::Approve(element) => ::core::fmt::Display::fmt(element, f), - Self::BalanceOf(element) => ::core::fmt::Display::fmt(element, f), - Self::Decimals(element) => ::core::fmt::Display::fmt(element, f), - Self::Name(element) => ::core::fmt::Display::fmt(element, f), - Self::Symbol(element) => ::core::fmt::Display::fmt(element, f), - Self::TotalSupply(element) => ::core::fmt::Display::fmt(element, f), - Self::Transfer(element) => ::core::fmt::Display::fmt(element, f), - Self::TransferFrom(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for IERC20MetadataCalls { - fn from(value: AllowanceCall) -> Self { - Self::Allowance(value) - } - } - impl ::core::convert::From for IERC20MetadataCalls { - fn from(value: ApproveCall) -> Self { - Self::Approve(value) - } - } - impl ::core::convert::From for IERC20MetadataCalls { - fn from(value: BalanceOfCall) -> Self { - Self::BalanceOf(value) - } - } - impl ::core::convert::From for IERC20MetadataCalls { - fn from(value: DecimalsCall) -> Self { - Self::Decimals(value) - } - } - impl ::core::convert::From for IERC20MetadataCalls { - fn from(value: NameCall) -> Self { - Self::Name(value) - } - } - impl ::core::convert::From for IERC20MetadataCalls { - fn from(value: SymbolCall) -> Self { - Self::Symbol(value) - } - } - impl ::core::convert::From for IERC20MetadataCalls { - fn from(value: TotalSupplyCall) -> Self { - Self::TotalSupply(value) - } - } - impl ::core::convert::From for IERC20MetadataCalls { - fn from(value: TransferCall) -> Self { - Self::Transfer(value) - } - } - impl ::core::convert::From for IERC20MetadataCalls { - fn from(value: TransferFromCall) -> Self { - Self::TransferFrom(value) - } - } - ///Container type for all return fields from the `allowance` function with signature `allowance(address,address)` and selector `0xdd62ed3e` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct AllowanceReturn(pub ::ethers::core::types::U256); - ///Container type for all return fields from the `approve` function with signature `approve(address,uint256)` and selector `0x095ea7b3` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct ApproveReturn(pub bool); - ///Container type for all return fields from the `balanceOf` function with signature `balanceOf(address)` and selector `0x70a08231` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct BalanceOfReturn(pub ::ethers::core::types::U256); - ///Container type for all return fields from the `decimals` function with signature `decimals()` and selector `0x313ce567` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct DecimalsReturn(pub u8); - ///Container type for all return fields from the `name` function with signature `name()` and selector `0x06fdde03` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct NameReturn(pub ::std::string::String); - ///Container type for all return fields from the `symbol` function with signature `symbol()` and selector `0x95d89b41` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct SymbolReturn(pub ::std::string::String); - ///Container type for all return fields from the `totalSupply` function with signature `totalSupply()` and selector `0x18160ddd` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct TotalSupplyReturn(pub ::ethers::core::types::U256); - ///Container type for all return fields from the `transfer` function with signature `transfer(address,uint256)` and selector `0xa9059cbb` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct TransferReturn(pub bool); - ///Container type for all return fields from the `transferFrom` function with signature `transferFrom(address,address,uint256)` and selector `0x23b872dd` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct TransferFromReturn(pub bool); -} diff --git a/src/bindings/ierc721.rs b/src/bindings/ierc721.rs deleted file mode 100644 index 1a9c90b..0000000 --- a/src/bindings/ierc721.rs +++ /dev/null @@ -1,1007 +0,0 @@ -pub use ierc721::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod ierc721 { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("approve"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("approve"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("balanceOf"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("balanceOf"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("balance"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("getApproved"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("getApproved"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("operator"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("isApprovedForAll"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("isApprovedForAll"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("operator"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("ownerOf"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("ownerOf"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("safeTransferFrom"), - ::std::vec![ - ::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("safeTransferFrom"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - }, - ::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("safeTransferFrom"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("data"), - kind: ::ethers::core::abi::ethabi::ParamType::Bytes, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "bytes" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - }, - ], - ), - ( - ::std::borrow::ToOwned::to_owned("setApprovalForAll"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("setApprovalForAll"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("operator"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("approved"), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("supportsInterface"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("supportsInterface"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("interfaceId"), - kind: ::ethers::core::abi::ethabi::ParamType::FixedBytes(4usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes4"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("transferFrom"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("transferFrom"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ]), - events: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("Approval"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Approval"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("approved"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: true, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("ApprovalForAll"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("ApprovalForAll"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("operator"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("approved"), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("Transfer"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Transfer"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: true, - }, - ], - anonymous: false, - },], - ), - ]), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static IERC721_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = ::ethers::contract::Lazy::new(__abi); - pub struct IERC721(::ethers::contract::Contract); - impl ::core::clone::Clone for IERC721 { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for IERC721 { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for IERC721 { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for IERC721 { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(IERC721)) - .field(&self.address()) - .finish() - } - } - impl IERC721 { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - IERC721_ABI.clone(), - client, - )) - } - ///Calls the contract's `approve` (0x095ea7b3) function - pub fn approve( - &self, - to: ::ethers::core::types::Address, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([9, 94, 167, 179], (to, token_id)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `balanceOf` (0x70a08231) function - pub fn balance_of( - &self, - owner: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([112, 160, 130, 49], owner) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `getApproved` (0x081812fc) function - pub fn get_approved( - &self, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([8, 24, 18, 252], token_id) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `isApprovedForAll` (0xe985e9c5) function - pub fn is_approved_for_all( - &self, - owner: ::ethers::core::types::Address, - operator: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([233, 133, 233, 197], (owner, operator)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `ownerOf` (0x6352211e) function - pub fn owner_of( - &self, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([99, 82, 33, 30], token_id) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `safeTransferFrom` (0x42842e0e) function - pub fn safe_transfer_from( - &self, - from: ::ethers::core::types::Address, - to: ::ethers::core::types::Address, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([66, 132, 46, 14], (from, to, token_id)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `safeTransferFrom` (0xb88d4fde) function - pub fn safe_transfer_from_with_from_and_to_and_data( - &self, - from: ::ethers::core::types::Address, - to: ::ethers::core::types::Address, - token_id: ::ethers::core::types::U256, - data: ::ethers::core::types::Bytes, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([184, 141, 79, 222], (from, to, token_id, data)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `setApprovalForAll` (0xa22cb465) function - pub fn set_approval_for_all( - &self, - operator: ::ethers::core::types::Address, - approved: bool, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([162, 44, 180, 101], (operator, approved)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `supportsInterface` (0x01ffc9a7) function - pub fn supports_interface(&self, interface_id: [u8; 4]) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([1, 255, 201, 167], interface_id) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `transferFrom` (0x23b872dd) function - pub fn transfer_from( - &self, - from: ::ethers::core::types::Address, - to: ::ethers::core::types::Address, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([35, 184, 114, 221], (from, to, token_id)) - .expect("method not found (this should never happen)") - } - ///Gets the contract's `Approval` event - pub fn approval_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, ApprovalFilter> { - self.0.event() - } - ///Gets the contract's `ApprovalForAll` event - pub fn approval_for_all_filter( - &self, - ) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, ApprovalForAllFilter> { - self.0.event() - } - ///Gets the contract's `Transfer` event - pub fn transfer_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, TransferFilter> { - self.0.event() - } - /// Returns an `Event` builder for all the events of this contract. - pub fn events(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, IERC721Events> { - self.0.event_with_filter(::core::default::Default::default()) - } - } - impl From<::ethers::contract::Contract> for IERC721 { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Approval", abi = "Approval(address,address,uint256)")] - pub struct ApprovalFilter { - #[ethevent(indexed)] - pub owner: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub approved: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub token_id: ::ethers::core::types::U256, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "ApprovalForAll", abi = "ApprovalForAll(address,address,bool)")] - pub struct ApprovalForAllFilter { - #[ethevent(indexed)] - pub owner: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub operator: ::ethers::core::types::Address, - pub approved: bool, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Transfer", abi = "Transfer(address,address,uint256)")] - pub struct TransferFilter { - #[ethevent(indexed)] - pub from: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub to: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all of the contract's events - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum IERC721Events { - ApprovalFilter(ApprovalFilter), - ApprovalForAllFilter(ApprovalForAllFilter), - TransferFilter(TransferFilter), - } - impl ::ethers::contract::EthLogDecode for IERC721Events { - fn decode_log(log: &::ethers::core::abi::RawLog) -> ::core::result::Result { - if let Ok(decoded) = ApprovalFilter::decode_log(log) { - return Ok(IERC721Events::ApprovalFilter(decoded)); - } - if let Ok(decoded) = ApprovalForAllFilter::decode_log(log) { - return Ok(IERC721Events::ApprovalForAllFilter(decoded)); - } - if let Ok(decoded) = TransferFilter::decode_log(log) { - return Ok(IERC721Events::TransferFilter(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData) - } - } - impl ::core::fmt::Display for IERC721Events { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::ApprovalFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::ApprovalForAllFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::TransferFilter(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for IERC721Events { - fn from(value: ApprovalFilter) -> Self { - Self::ApprovalFilter(value) - } - } - impl ::core::convert::From for IERC721Events { - fn from(value: ApprovalForAllFilter) -> Self { - Self::ApprovalForAllFilter(value) - } - } - impl ::core::convert::From for IERC721Events { - fn from(value: TransferFilter) -> Self { - Self::TransferFilter(value) - } - } - ///Container type for all input parameters for the `approve` function with signature `approve(address,uint256)` and selector `0x095ea7b3` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "approve", abi = "approve(address,uint256)")] - pub struct ApproveCall { - pub to: ::ethers::core::types::Address, - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `balanceOf` function with signature `balanceOf(address)` and selector `0x70a08231` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "balanceOf", abi = "balanceOf(address)")] - pub struct BalanceOfCall { - pub owner: ::ethers::core::types::Address, - } - ///Container type for all input parameters for the `getApproved` function with signature `getApproved(uint256)` and selector `0x081812fc` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "getApproved", abi = "getApproved(uint256)")] - pub struct GetApprovedCall { - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `isApprovedForAll` function with signature `isApprovedForAll(address,address)` and selector `0xe985e9c5` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "isApprovedForAll", abi = "isApprovedForAll(address,address)")] - pub struct IsApprovedForAllCall { - pub owner: ::ethers::core::types::Address, - pub operator: ::ethers::core::types::Address, - } - ///Container type for all input parameters for the `ownerOf` function with signature `ownerOf(uint256)` and selector `0x6352211e` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "ownerOf", abi = "ownerOf(uint256)")] - pub struct OwnerOfCall { - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `safeTransferFrom` function with signature `safeTransferFrom(address,address,uint256)` and selector `0x42842e0e` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "safeTransferFrom", abi = "safeTransferFrom(address,address,uint256)")] - pub struct SafeTransferFromCall { - pub from: ::ethers::core::types::Address, - pub to: ::ethers::core::types::Address, - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `safeTransferFrom` function with signature `safeTransferFrom(address,address,uint256,bytes)` and selector `0xb88d4fde` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "safeTransferFrom", abi = "safeTransferFrom(address,address,uint256,bytes)")] - pub struct SafeTransferFromWithFromAndToAndDataCall { - pub from: ::ethers::core::types::Address, - pub to: ::ethers::core::types::Address, - pub token_id: ::ethers::core::types::U256, - pub data: ::ethers::core::types::Bytes, - } - ///Container type for all input parameters for the `setApprovalForAll` function with signature `setApprovalForAll(address,bool)` and selector `0xa22cb465` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "setApprovalForAll", abi = "setApprovalForAll(address,bool)")] - pub struct SetApprovalForAllCall { - pub operator: ::ethers::core::types::Address, - pub approved: bool, - } - ///Container type for all input parameters for the `supportsInterface` function with signature `supportsInterface(bytes4)` and selector `0x01ffc9a7` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "supportsInterface", abi = "supportsInterface(bytes4)")] - pub struct SupportsInterfaceCall { - pub interface_id: [u8; 4], - } - ///Container type for all input parameters for the `transferFrom` function with signature `transferFrom(address,address,uint256)` and selector `0x23b872dd` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "transferFrom", abi = "transferFrom(address,address,uint256)")] - pub struct TransferFromCall { - pub from: ::ethers::core::types::Address, - pub to: ::ethers::core::types::Address, - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all of the contract's call - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum IERC721Calls { - Approve(ApproveCall), - BalanceOf(BalanceOfCall), - GetApproved(GetApprovedCall), - IsApprovedForAll(IsApprovedForAllCall), - OwnerOf(OwnerOfCall), - SafeTransferFrom(SafeTransferFromCall), - SafeTransferFromWithFromAndToAndData(SafeTransferFromWithFromAndToAndDataCall), - SetApprovalForAll(SetApprovalForAllCall), - SupportsInterface(SupportsInterfaceCall), - TransferFrom(TransferFromCall), - } - impl ::ethers::core::abi::AbiDecode for IERC721Calls { - fn decode(data: impl AsRef<[u8]>) -> ::core::result::Result { - let data = data.as_ref(); - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Approve(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::BalanceOf(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::GetApproved(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::IsApprovedForAll(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::OwnerOf(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SafeTransferFrom(decoded)); - } - if let Ok(decoded) = - ::decode(data) - { - return Ok(Self::SafeTransferFromWithFromAndToAndData(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SetApprovalForAll(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SupportsInterface(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TransferFrom(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData.into()) - } - } - impl ::ethers::core::abi::AbiEncode for IERC721Calls { - fn encode(self) -> Vec { - match self { - Self::Approve(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::BalanceOf(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::GetApproved(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::IsApprovedForAll(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::OwnerOf(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SafeTransferFrom(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SafeTransferFromWithFromAndToAndData(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SetApprovalForAll(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SupportsInterface(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TransferFrom(element) => ::ethers::core::abi::AbiEncode::encode(element), - } - } - } - impl ::core::fmt::Display for IERC721Calls { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::Approve(element) => ::core::fmt::Display::fmt(element, f), - Self::BalanceOf(element) => ::core::fmt::Display::fmt(element, f), - Self::GetApproved(element) => ::core::fmt::Display::fmt(element, f), - Self::IsApprovedForAll(element) => ::core::fmt::Display::fmt(element, f), - Self::OwnerOf(element) => ::core::fmt::Display::fmt(element, f), - Self::SafeTransferFrom(element) => ::core::fmt::Display::fmt(element, f), - Self::SafeTransferFromWithFromAndToAndData(element) => ::core::fmt::Display::fmt(element, f), - Self::SetApprovalForAll(element) => ::core::fmt::Display::fmt(element, f), - Self::SupportsInterface(element) => ::core::fmt::Display::fmt(element, f), - Self::TransferFrom(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for IERC721Calls { - fn from(value: ApproveCall) -> Self { - Self::Approve(value) - } - } - impl ::core::convert::From for IERC721Calls { - fn from(value: BalanceOfCall) -> Self { - Self::BalanceOf(value) - } - } - impl ::core::convert::From for IERC721Calls { - fn from(value: GetApprovedCall) -> Self { - Self::GetApproved(value) - } - } - impl ::core::convert::From for IERC721Calls { - fn from(value: IsApprovedForAllCall) -> Self { - Self::IsApprovedForAll(value) - } - } - impl ::core::convert::From for IERC721Calls { - fn from(value: OwnerOfCall) -> Self { - Self::OwnerOf(value) - } - } - impl ::core::convert::From for IERC721Calls { - fn from(value: SafeTransferFromCall) -> Self { - Self::SafeTransferFrom(value) - } - } - impl ::core::convert::From for IERC721Calls { - fn from(value: SafeTransferFromWithFromAndToAndDataCall) -> Self { - Self::SafeTransferFromWithFromAndToAndData(value) - } - } - impl ::core::convert::From for IERC721Calls { - fn from(value: SetApprovalForAllCall) -> Self { - Self::SetApprovalForAll(value) - } - } - impl ::core::convert::From for IERC721Calls { - fn from(value: SupportsInterfaceCall) -> Self { - Self::SupportsInterface(value) - } - } - impl ::core::convert::From for IERC721Calls { - fn from(value: TransferFromCall) -> Self { - Self::TransferFrom(value) - } - } - ///Container type for all return fields from the `balanceOf` function with signature `balanceOf(address)` and selector `0x70a08231` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct BalanceOfReturn { - pub balance: ::ethers::core::types::U256, - } - ///Container type for all return fields from the `getApproved` function with signature `getApproved(uint256)` and selector `0x081812fc` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct GetApprovedReturn { - pub operator: ::ethers::core::types::Address, - } - ///Container type for all return fields from the `isApprovedForAll` function with signature `isApprovedForAll(address,address)` and selector `0xe985e9c5` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct IsApprovedForAllReturn(pub bool); - ///Container type for all return fields from the `ownerOf` function with signature `ownerOf(uint256)` and selector `0x6352211e` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct OwnerOfReturn { - pub owner: ::ethers::core::types::Address, - } - ///Container type for all return fields from the `supportsInterface` function with signature `supportsInterface(bytes4)` and selector `0x01ffc9a7` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct SupportsInterfaceReturn(pub bool); -} diff --git a/src/bindings/ierc721_enumerable.rs b/src/bindings/ierc721_enumerable.rs deleted file mode 100644 index 3dd499b..0000000 --- a/src/bindings/ierc721_enumerable.rs +++ /dev/null @@ -1,1219 +0,0 @@ -pub use ierc721_enumerable::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod ierc721_enumerable { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("approve"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("approve"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("balanceOf"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("balanceOf"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("balance"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("getApproved"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("getApproved"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("operator"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("isApprovedForAll"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("isApprovedForAll"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("operator"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("ownerOf"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("ownerOf"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("safeTransferFrom"), - ::std::vec![ - ::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("safeTransferFrom"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - }, - ::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("safeTransferFrom"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("data"), - kind: ::ethers::core::abi::ethabi::ParamType::Bytes, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "bytes" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - }, - ], - ), - ( - ::std::borrow::ToOwned::to_owned("setApprovalForAll"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("setApprovalForAll"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("operator"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("approved"), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("supportsInterface"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("supportsInterface"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("interfaceId"), - kind: ::ethers::core::abi::ethabi::ParamType::FixedBytes(4usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes4"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("tokenByIndex"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("tokenByIndex"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("index"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("tokenOfOwnerByIndex"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("tokenOfOwnerByIndex",), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("index"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("totalSupply"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("totalSupply"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("transferFrom"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("transferFrom"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ]), - events: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("Approval"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Approval"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("approved"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: true, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("ApprovalForAll"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("ApprovalForAll"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("operator"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("approved"), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("Transfer"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Transfer"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: true, - }, - ], - anonymous: false, - },], - ), - ]), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static IERC721ENUMERABLE_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - pub struct IERC721Enumerable(::ethers::contract::Contract); - impl ::core::clone::Clone for IERC721Enumerable { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for IERC721Enumerable { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for IERC721Enumerable { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for IERC721Enumerable { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(IERC721Enumerable)) - .field(&self.address()) - .finish() - } - } - impl IERC721Enumerable { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - IERC721ENUMERABLE_ABI.clone(), - client, - )) - } - ///Calls the contract's `approve` (0x095ea7b3) function - pub fn approve( - &self, - to: ::ethers::core::types::Address, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([9, 94, 167, 179], (to, token_id)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `balanceOf` (0x70a08231) function - pub fn balance_of( - &self, - owner: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([112, 160, 130, 49], owner) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `getApproved` (0x081812fc) function - pub fn get_approved( - &self, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([8, 24, 18, 252], token_id) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `isApprovedForAll` (0xe985e9c5) function - pub fn is_approved_for_all( - &self, - owner: ::ethers::core::types::Address, - operator: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([233, 133, 233, 197], (owner, operator)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `ownerOf` (0x6352211e) function - pub fn owner_of( - &self, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([99, 82, 33, 30], token_id) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `safeTransferFrom` (0x42842e0e) function - pub fn safe_transfer_from( - &self, - from: ::ethers::core::types::Address, - to: ::ethers::core::types::Address, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([66, 132, 46, 14], (from, to, token_id)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `safeTransferFrom` (0xb88d4fde) function - pub fn safe_transfer_from_with_from_and_to_and_data( - &self, - from: ::ethers::core::types::Address, - to: ::ethers::core::types::Address, - token_id: ::ethers::core::types::U256, - data: ::ethers::core::types::Bytes, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([184, 141, 79, 222], (from, to, token_id, data)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `setApprovalForAll` (0xa22cb465) function - pub fn set_approval_for_all( - &self, - operator: ::ethers::core::types::Address, - approved: bool, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([162, 44, 180, 101], (operator, approved)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `supportsInterface` (0x01ffc9a7) function - pub fn supports_interface(&self, interface_id: [u8; 4]) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([1, 255, 201, 167], interface_id) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `tokenByIndex` (0x4f6ccce7) function - pub fn token_by_index( - &self, - index: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([79, 108, 204, 231], index) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `tokenOfOwnerByIndex` (0x2f745c59) function - pub fn token_of_owner_by_index( - &self, - owner: ::ethers::core::types::Address, - index: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([47, 116, 92, 89], (owner, index)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `totalSupply` (0x18160ddd) function - pub fn total_supply(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([24, 22, 13, 221], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `transferFrom` (0x23b872dd) function - pub fn transfer_from( - &self, - from: ::ethers::core::types::Address, - to: ::ethers::core::types::Address, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([35, 184, 114, 221], (from, to, token_id)) - .expect("method not found (this should never happen)") - } - ///Gets the contract's `Approval` event - pub fn approval_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, ApprovalFilter> { - self.0.event() - } - ///Gets the contract's `ApprovalForAll` event - pub fn approval_for_all_filter( - &self, - ) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, ApprovalForAllFilter> { - self.0.event() - } - ///Gets the contract's `Transfer` event - pub fn transfer_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, TransferFilter> { - self.0.event() - } - /// Returns an `Event` builder for all the events of this contract. - pub fn events(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, IERC721EnumerableEvents> { - self.0.event_with_filter(::core::default::Default::default()) - } - } - impl From<::ethers::contract::Contract> for IERC721Enumerable { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Approval", abi = "Approval(address,address,uint256)")] - pub struct ApprovalFilter { - #[ethevent(indexed)] - pub owner: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub approved: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub token_id: ::ethers::core::types::U256, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "ApprovalForAll", abi = "ApprovalForAll(address,address,bool)")] - pub struct ApprovalForAllFilter { - #[ethevent(indexed)] - pub owner: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub operator: ::ethers::core::types::Address, - pub approved: bool, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Transfer", abi = "Transfer(address,address,uint256)")] - pub struct TransferFilter { - #[ethevent(indexed)] - pub from: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub to: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all of the contract's events - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum IERC721EnumerableEvents { - ApprovalFilter(ApprovalFilter), - ApprovalForAllFilter(ApprovalForAllFilter), - TransferFilter(TransferFilter), - } - impl ::ethers::contract::EthLogDecode for IERC721EnumerableEvents { - fn decode_log(log: &::ethers::core::abi::RawLog) -> ::core::result::Result { - if let Ok(decoded) = ApprovalFilter::decode_log(log) { - return Ok(IERC721EnumerableEvents::ApprovalFilter(decoded)); - } - if let Ok(decoded) = ApprovalForAllFilter::decode_log(log) { - return Ok(IERC721EnumerableEvents::ApprovalForAllFilter(decoded)); - } - if let Ok(decoded) = TransferFilter::decode_log(log) { - return Ok(IERC721EnumerableEvents::TransferFilter(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData) - } - } - impl ::core::fmt::Display for IERC721EnumerableEvents { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::ApprovalFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::ApprovalForAllFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::TransferFilter(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for IERC721EnumerableEvents { - fn from(value: ApprovalFilter) -> Self { - Self::ApprovalFilter(value) - } - } - impl ::core::convert::From for IERC721EnumerableEvents { - fn from(value: ApprovalForAllFilter) -> Self { - Self::ApprovalForAllFilter(value) - } - } - impl ::core::convert::From for IERC721EnumerableEvents { - fn from(value: TransferFilter) -> Self { - Self::TransferFilter(value) - } - } - ///Container type for all input parameters for the `approve` function with signature `approve(address,uint256)` and selector `0x095ea7b3` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "approve", abi = "approve(address,uint256)")] - pub struct ApproveCall { - pub to: ::ethers::core::types::Address, - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `balanceOf` function with signature `balanceOf(address)` and selector `0x70a08231` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "balanceOf", abi = "balanceOf(address)")] - pub struct BalanceOfCall { - pub owner: ::ethers::core::types::Address, - } - ///Container type for all input parameters for the `getApproved` function with signature `getApproved(uint256)` and selector `0x081812fc` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "getApproved", abi = "getApproved(uint256)")] - pub struct GetApprovedCall { - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `isApprovedForAll` function with signature `isApprovedForAll(address,address)` and selector `0xe985e9c5` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "isApprovedForAll", abi = "isApprovedForAll(address,address)")] - pub struct IsApprovedForAllCall { - pub owner: ::ethers::core::types::Address, - pub operator: ::ethers::core::types::Address, - } - ///Container type for all input parameters for the `ownerOf` function with signature `ownerOf(uint256)` and selector `0x6352211e` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "ownerOf", abi = "ownerOf(uint256)")] - pub struct OwnerOfCall { - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `safeTransferFrom` function with signature `safeTransferFrom(address,address,uint256)` and selector `0x42842e0e` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "safeTransferFrom", abi = "safeTransferFrom(address,address,uint256)")] - pub struct SafeTransferFromCall { - pub from: ::ethers::core::types::Address, - pub to: ::ethers::core::types::Address, - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `safeTransferFrom` function with signature `safeTransferFrom(address,address,uint256,bytes)` and selector `0xb88d4fde` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "safeTransferFrom", abi = "safeTransferFrom(address,address,uint256,bytes)")] - pub struct SafeTransferFromWithFromAndToAndDataCall { - pub from: ::ethers::core::types::Address, - pub to: ::ethers::core::types::Address, - pub token_id: ::ethers::core::types::U256, - pub data: ::ethers::core::types::Bytes, - } - ///Container type for all input parameters for the `setApprovalForAll` function with signature `setApprovalForAll(address,bool)` and selector `0xa22cb465` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "setApprovalForAll", abi = "setApprovalForAll(address,bool)")] - pub struct SetApprovalForAllCall { - pub operator: ::ethers::core::types::Address, - pub approved: bool, - } - ///Container type for all input parameters for the `supportsInterface` function with signature `supportsInterface(bytes4)` and selector `0x01ffc9a7` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "supportsInterface", abi = "supportsInterface(bytes4)")] - pub struct SupportsInterfaceCall { - pub interface_id: [u8; 4], - } - ///Container type for all input parameters for the `tokenByIndex` function with signature `tokenByIndex(uint256)` and selector `0x4f6ccce7` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "tokenByIndex", abi = "tokenByIndex(uint256)")] - pub struct TokenByIndexCall { - pub index: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `tokenOfOwnerByIndex` function with signature `tokenOfOwnerByIndex(address,uint256)` and selector `0x2f745c59` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "tokenOfOwnerByIndex", abi = "tokenOfOwnerByIndex(address,uint256)")] - pub struct TokenOfOwnerByIndexCall { - pub owner: ::ethers::core::types::Address, - pub index: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `totalSupply` function with signature `totalSupply()` and selector `0x18160ddd` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "totalSupply", abi = "totalSupply()")] - pub struct TotalSupplyCall; - ///Container type for all input parameters for the `transferFrom` function with signature `transferFrom(address,address,uint256)` and selector `0x23b872dd` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "transferFrom", abi = "transferFrom(address,address,uint256)")] - pub struct TransferFromCall { - pub from: ::ethers::core::types::Address, - pub to: ::ethers::core::types::Address, - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all of the contract's call - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum IERC721EnumerableCalls { - Approve(ApproveCall), - BalanceOf(BalanceOfCall), - GetApproved(GetApprovedCall), - IsApprovedForAll(IsApprovedForAllCall), - OwnerOf(OwnerOfCall), - SafeTransferFrom(SafeTransferFromCall), - SafeTransferFromWithFromAndToAndData(SafeTransferFromWithFromAndToAndDataCall), - SetApprovalForAll(SetApprovalForAllCall), - SupportsInterface(SupportsInterfaceCall), - TokenByIndex(TokenByIndexCall), - TokenOfOwnerByIndex(TokenOfOwnerByIndexCall), - TotalSupply(TotalSupplyCall), - TransferFrom(TransferFromCall), - } - impl ::ethers::core::abi::AbiDecode for IERC721EnumerableCalls { - fn decode(data: impl AsRef<[u8]>) -> ::core::result::Result { - let data = data.as_ref(); - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Approve(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::BalanceOf(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::GetApproved(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::IsApprovedForAll(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::OwnerOf(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SafeTransferFrom(decoded)); - } - if let Ok(decoded) = - ::decode(data) - { - return Ok(Self::SafeTransferFromWithFromAndToAndData(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SetApprovalForAll(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SupportsInterface(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TokenByIndex(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TokenOfOwnerByIndex(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TotalSupply(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TransferFrom(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData.into()) - } - } - impl ::ethers::core::abi::AbiEncode for IERC721EnumerableCalls { - fn encode(self) -> Vec { - match self { - Self::Approve(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::BalanceOf(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::GetApproved(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::IsApprovedForAll(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::OwnerOf(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SafeTransferFrom(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SafeTransferFromWithFromAndToAndData(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SetApprovalForAll(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SupportsInterface(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TokenByIndex(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TokenOfOwnerByIndex(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TotalSupply(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TransferFrom(element) => ::ethers::core::abi::AbiEncode::encode(element), - } - } - } - impl ::core::fmt::Display for IERC721EnumerableCalls { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::Approve(element) => ::core::fmt::Display::fmt(element, f), - Self::BalanceOf(element) => ::core::fmt::Display::fmt(element, f), - Self::GetApproved(element) => ::core::fmt::Display::fmt(element, f), - Self::IsApprovedForAll(element) => ::core::fmt::Display::fmt(element, f), - Self::OwnerOf(element) => ::core::fmt::Display::fmt(element, f), - Self::SafeTransferFrom(element) => ::core::fmt::Display::fmt(element, f), - Self::SafeTransferFromWithFromAndToAndData(element) => ::core::fmt::Display::fmt(element, f), - Self::SetApprovalForAll(element) => ::core::fmt::Display::fmt(element, f), - Self::SupportsInterface(element) => ::core::fmt::Display::fmt(element, f), - Self::TokenByIndex(element) => ::core::fmt::Display::fmt(element, f), - Self::TokenOfOwnerByIndex(element) => ::core::fmt::Display::fmt(element, f), - Self::TotalSupply(element) => ::core::fmt::Display::fmt(element, f), - Self::TransferFrom(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for IERC721EnumerableCalls { - fn from(value: ApproveCall) -> Self { - Self::Approve(value) - } - } - impl ::core::convert::From for IERC721EnumerableCalls { - fn from(value: BalanceOfCall) -> Self { - Self::BalanceOf(value) - } - } - impl ::core::convert::From for IERC721EnumerableCalls { - fn from(value: GetApprovedCall) -> Self { - Self::GetApproved(value) - } - } - impl ::core::convert::From for IERC721EnumerableCalls { - fn from(value: IsApprovedForAllCall) -> Self { - Self::IsApprovedForAll(value) - } - } - impl ::core::convert::From for IERC721EnumerableCalls { - fn from(value: OwnerOfCall) -> Self { - Self::OwnerOf(value) - } - } - impl ::core::convert::From for IERC721EnumerableCalls { - fn from(value: SafeTransferFromCall) -> Self { - Self::SafeTransferFrom(value) - } - } - impl ::core::convert::From for IERC721EnumerableCalls { - fn from(value: SafeTransferFromWithFromAndToAndDataCall) -> Self { - Self::SafeTransferFromWithFromAndToAndData(value) - } - } - impl ::core::convert::From for IERC721EnumerableCalls { - fn from(value: SetApprovalForAllCall) -> Self { - Self::SetApprovalForAll(value) - } - } - impl ::core::convert::From for IERC721EnumerableCalls { - fn from(value: SupportsInterfaceCall) -> Self { - Self::SupportsInterface(value) - } - } - impl ::core::convert::From for IERC721EnumerableCalls { - fn from(value: TokenByIndexCall) -> Self { - Self::TokenByIndex(value) - } - } - impl ::core::convert::From for IERC721EnumerableCalls { - fn from(value: TokenOfOwnerByIndexCall) -> Self { - Self::TokenOfOwnerByIndex(value) - } - } - impl ::core::convert::From for IERC721EnumerableCalls { - fn from(value: TotalSupplyCall) -> Self { - Self::TotalSupply(value) - } - } - impl ::core::convert::From for IERC721EnumerableCalls { - fn from(value: TransferFromCall) -> Self { - Self::TransferFrom(value) - } - } - ///Container type for all return fields from the `balanceOf` function with signature `balanceOf(address)` and selector `0x70a08231` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct BalanceOfReturn { - pub balance: ::ethers::core::types::U256, - } - ///Container type for all return fields from the `getApproved` function with signature `getApproved(uint256)` and selector `0x081812fc` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct GetApprovedReturn { - pub operator: ::ethers::core::types::Address, - } - ///Container type for all return fields from the `isApprovedForAll` function with signature `isApprovedForAll(address,address)` and selector `0xe985e9c5` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct IsApprovedForAllReturn(pub bool); - ///Container type for all return fields from the `ownerOf` function with signature `ownerOf(uint256)` and selector `0x6352211e` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct OwnerOfReturn { - pub owner: ::ethers::core::types::Address, - } - ///Container type for all return fields from the `supportsInterface` function with signature `supportsInterface(bytes4)` and selector `0x01ffc9a7` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct SupportsInterfaceReturn(pub bool); - ///Container type for all return fields from the `tokenByIndex` function with signature `tokenByIndex(uint256)` and selector `0x4f6ccce7` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct TokenByIndexReturn(pub ::ethers::core::types::U256); - ///Container type for all return fields from the `tokenOfOwnerByIndex` function with signature `tokenOfOwnerByIndex(address,uint256)` and selector `0x2f745c59` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct TokenOfOwnerByIndexReturn(pub ::ethers::core::types::U256); - ///Container type for all return fields from the `totalSupply` function with signature `totalSupply()` and selector `0x18160ddd` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct TotalSupplyReturn(pub ::ethers::core::types::U256); -} diff --git a/src/bindings/ierc721_metadata.rs b/src/bindings/ierc721_metadata.rs deleted file mode 100644 index 4e247d7..0000000 --- a/src/bindings/ierc721_metadata.rs +++ /dev/null @@ -1,1197 +0,0 @@ -pub use ierc721_metadata::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod ierc721_metadata { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("approve"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("approve"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("balanceOf"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("balanceOf"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("balance"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("getApproved"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("getApproved"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("operator"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("isApprovedForAll"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("isApprovedForAll"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("operator"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("name"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("name"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::String, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("string"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("ownerOf"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("ownerOf"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("safeTransferFrom"), - ::std::vec![ - ::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("safeTransferFrom"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - }, - ::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("safeTransferFrom"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("data"), - kind: ::ethers::core::abi::ethabi::ParamType::Bytes, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "bytes" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - }, - ], - ), - ( - ::std::borrow::ToOwned::to_owned("setApprovalForAll"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("setApprovalForAll"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("operator"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("approved"), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("supportsInterface"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("supportsInterface"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("interfaceId"), - kind: ::ethers::core::abi::ethabi::ParamType::FixedBytes(4usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes4"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("symbol"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("symbol"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::String, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("string"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("tokenURI"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("tokenURI"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::String, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("string"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("transferFrom"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("transferFrom"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ]), - events: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("Approval"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Approval"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("approved"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: true, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("ApprovalForAll"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("ApprovalForAll"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("operator"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("approved"), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("Transfer"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Transfer"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: true, - }, - ], - anonymous: false, - },], - ), - ]), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static IERC721METADATA_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - pub struct IERC721Metadata(::ethers::contract::Contract); - impl ::core::clone::Clone for IERC721Metadata { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for IERC721Metadata { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for IERC721Metadata { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for IERC721Metadata { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(IERC721Metadata)) - .field(&self.address()) - .finish() - } - } - impl IERC721Metadata { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - IERC721METADATA_ABI.clone(), - client, - )) - } - ///Calls the contract's `approve` (0x095ea7b3) function - pub fn approve( - &self, - to: ::ethers::core::types::Address, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([9, 94, 167, 179], (to, token_id)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `balanceOf` (0x70a08231) function - pub fn balance_of( - &self, - owner: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([112, 160, 130, 49], owner) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `getApproved` (0x081812fc) function - pub fn get_approved( - &self, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([8, 24, 18, 252], token_id) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `isApprovedForAll` (0xe985e9c5) function - pub fn is_approved_for_all( - &self, - owner: ::ethers::core::types::Address, - operator: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([233, 133, 233, 197], (owner, operator)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `name` (0x06fdde03) function - pub fn name(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([6, 253, 222, 3], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `ownerOf` (0x6352211e) function - pub fn owner_of( - &self, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([99, 82, 33, 30], token_id) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `safeTransferFrom` (0x42842e0e) function - pub fn safe_transfer_from( - &self, - from: ::ethers::core::types::Address, - to: ::ethers::core::types::Address, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([66, 132, 46, 14], (from, to, token_id)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `safeTransferFrom` (0xb88d4fde) function - pub fn safe_transfer_from_with_from_and_to_and_data( - &self, - from: ::ethers::core::types::Address, - to: ::ethers::core::types::Address, - token_id: ::ethers::core::types::U256, - data: ::ethers::core::types::Bytes, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([184, 141, 79, 222], (from, to, token_id, data)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `setApprovalForAll` (0xa22cb465) function - pub fn set_approval_for_all( - &self, - operator: ::ethers::core::types::Address, - approved: bool, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([162, 44, 180, 101], (operator, approved)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `supportsInterface` (0x01ffc9a7) function - pub fn supports_interface(&self, interface_id: [u8; 4]) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([1, 255, 201, 167], interface_id) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `symbol` (0x95d89b41) function - pub fn symbol(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([149, 216, 155, 65], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `tokenURI` (0xc87b56dd) function - pub fn token_uri( - &self, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([200, 123, 86, 221], token_id) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `transferFrom` (0x23b872dd) function - pub fn transfer_from( - &self, - from: ::ethers::core::types::Address, - to: ::ethers::core::types::Address, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([35, 184, 114, 221], (from, to, token_id)) - .expect("method not found (this should never happen)") - } - ///Gets the contract's `Approval` event - pub fn approval_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, ApprovalFilter> { - self.0.event() - } - ///Gets the contract's `ApprovalForAll` event - pub fn approval_for_all_filter( - &self, - ) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, ApprovalForAllFilter> { - self.0.event() - } - ///Gets the contract's `Transfer` event - pub fn transfer_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, TransferFilter> { - self.0.event() - } - /// Returns an `Event` builder for all the events of this contract. - pub fn events(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, IERC721MetadataEvents> { - self.0.event_with_filter(::core::default::Default::default()) - } - } - impl From<::ethers::contract::Contract> for IERC721Metadata { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Approval", abi = "Approval(address,address,uint256)")] - pub struct ApprovalFilter { - #[ethevent(indexed)] - pub owner: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub approved: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub token_id: ::ethers::core::types::U256, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "ApprovalForAll", abi = "ApprovalForAll(address,address,bool)")] - pub struct ApprovalForAllFilter { - #[ethevent(indexed)] - pub owner: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub operator: ::ethers::core::types::Address, - pub approved: bool, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Transfer", abi = "Transfer(address,address,uint256)")] - pub struct TransferFilter { - #[ethevent(indexed)] - pub from: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub to: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all of the contract's events - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum IERC721MetadataEvents { - ApprovalFilter(ApprovalFilter), - ApprovalForAllFilter(ApprovalForAllFilter), - TransferFilter(TransferFilter), - } - impl ::ethers::contract::EthLogDecode for IERC721MetadataEvents { - fn decode_log(log: &::ethers::core::abi::RawLog) -> ::core::result::Result { - if let Ok(decoded) = ApprovalFilter::decode_log(log) { - return Ok(IERC721MetadataEvents::ApprovalFilter(decoded)); - } - if let Ok(decoded) = ApprovalForAllFilter::decode_log(log) { - return Ok(IERC721MetadataEvents::ApprovalForAllFilter(decoded)); - } - if let Ok(decoded) = TransferFilter::decode_log(log) { - return Ok(IERC721MetadataEvents::TransferFilter(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData) - } - } - impl ::core::fmt::Display for IERC721MetadataEvents { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::ApprovalFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::ApprovalForAllFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::TransferFilter(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for IERC721MetadataEvents { - fn from(value: ApprovalFilter) -> Self { - Self::ApprovalFilter(value) - } - } - impl ::core::convert::From for IERC721MetadataEvents { - fn from(value: ApprovalForAllFilter) -> Self { - Self::ApprovalForAllFilter(value) - } - } - impl ::core::convert::From for IERC721MetadataEvents { - fn from(value: TransferFilter) -> Self { - Self::TransferFilter(value) - } - } - ///Container type for all input parameters for the `approve` function with signature `approve(address,uint256)` and selector `0x095ea7b3` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "approve", abi = "approve(address,uint256)")] - pub struct ApproveCall { - pub to: ::ethers::core::types::Address, - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `balanceOf` function with signature `balanceOf(address)` and selector `0x70a08231` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "balanceOf", abi = "balanceOf(address)")] - pub struct BalanceOfCall { - pub owner: ::ethers::core::types::Address, - } - ///Container type for all input parameters for the `getApproved` function with signature `getApproved(uint256)` and selector `0x081812fc` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "getApproved", abi = "getApproved(uint256)")] - pub struct GetApprovedCall { - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `isApprovedForAll` function with signature `isApprovedForAll(address,address)` and selector `0xe985e9c5` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "isApprovedForAll", abi = "isApprovedForAll(address,address)")] - pub struct IsApprovedForAllCall { - pub owner: ::ethers::core::types::Address, - pub operator: ::ethers::core::types::Address, - } - ///Container type for all input parameters for the `name` function with signature `name()` and selector `0x06fdde03` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "name", abi = "name()")] - pub struct NameCall; - ///Container type for all input parameters for the `ownerOf` function with signature `ownerOf(uint256)` and selector `0x6352211e` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "ownerOf", abi = "ownerOf(uint256)")] - pub struct OwnerOfCall { - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `safeTransferFrom` function with signature `safeTransferFrom(address,address,uint256)` and selector `0x42842e0e` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "safeTransferFrom", abi = "safeTransferFrom(address,address,uint256)")] - pub struct SafeTransferFromCall { - pub from: ::ethers::core::types::Address, - pub to: ::ethers::core::types::Address, - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `safeTransferFrom` function with signature `safeTransferFrom(address,address,uint256,bytes)` and selector `0xb88d4fde` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "safeTransferFrom", abi = "safeTransferFrom(address,address,uint256,bytes)")] - pub struct SafeTransferFromWithFromAndToAndDataCall { - pub from: ::ethers::core::types::Address, - pub to: ::ethers::core::types::Address, - pub token_id: ::ethers::core::types::U256, - pub data: ::ethers::core::types::Bytes, - } - ///Container type for all input parameters for the `setApprovalForAll` function with signature `setApprovalForAll(address,bool)` and selector `0xa22cb465` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "setApprovalForAll", abi = "setApprovalForAll(address,bool)")] - pub struct SetApprovalForAllCall { - pub operator: ::ethers::core::types::Address, - pub approved: bool, - } - ///Container type for all input parameters for the `supportsInterface` function with signature `supportsInterface(bytes4)` and selector `0x01ffc9a7` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "supportsInterface", abi = "supportsInterface(bytes4)")] - pub struct SupportsInterfaceCall { - pub interface_id: [u8; 4], - } - ///Container type for all input parameters for the `symbol` function with signature `symbol()` and selector `0x95d89b41` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "symbol", abi = "symbol()")] - pub struct SymbolCall; - ///Container type for all input parameters for the `tokenURI` function with signature `tokenURI(uint256)` and selector `0xc87b56dd` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "tokenURI", abi = "tokenURI(uint256)")] - pub struct TokenURICall { - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `transferFrom` function with signature `transferFrom(address,address,uint256)` and selector `0x23b872dd` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "transferFrom", abi = "transferFrom(address,address,uint256)")] - pub struct TransferFromCall { - pub from: ::ethers::core::types::Address, - pub to: ::ethers::core::types::Address, - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all of the contract's call - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum IERC721MetadataCalls { - Approve(ApproveCall), - BalanceOf(BalanceOfCall), - GetApproved(GetApprovedCall), - IsApprovedForAll(IsApprovedForAllCall), - Name(NameCall), - OwnerOf(OwnerOfCall), - SafeTransferFrom(SafeTransferFromCall), - SafeTransferFromWithFromAndToAndData(SafeTransferFromWithFromAndToAndDataCall), - SetApprovalForAll(SetApprovalForAllCall), - SupportsInterface(SupportsInterfaceCall), - Symbol(SymbolCall), - TokenURI(TokenURICall), - TransferFrom(TransferFromCall), - } - impl ::ethers::core::abi::AbiDecode for IERC721MetadataCalls { - fn decode(data: impl AsRef<[u8]>) -> ::core::result::Result { - let data = data.as_ref(); - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Approve(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::BalanceOf(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::GetApproved(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::IsApprovedForAll(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Name(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::OwnerOf(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SafeTransferFrom(decoded)); - } - if let Ok(decoded) = - ::decode(data) - { - return Ok(Self::SafeTransferFromWithFromAndToAndData(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SetApprovalForAll(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SupportsInterface(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Symbol(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TokenURI(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TransferFrom(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData.into()) - } - } - impl ::ethers::core::abi::AbiEncode for IERC721MetadataCalls { - fn encode(self) -> Vec { - match self { - Self::Approve(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::BalanceOf(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::GetApproved(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::IsApprovedForAll(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Name(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::OwnerOf(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SafeTransferFrom(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SafeTransferFromWithFromAndToAndData(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SetApprovalForAll(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SupportsInterface(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Symbol(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TokenURI(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TransferFrom(element) => ::ethers::core::abi::AbiEncode::encode(element), - } - } - } - impl ::core::fmt::Display for IERC721MetadataCalls { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::Approve(element) => ::core::fmt::Display::fmt(element, f), - Self::BalanceOf(element) => ::core::fmt::Display::fmt(element, f), - Self::GetApproved(element) => ::core::fmt::Display::fmt(element, f), - Self::IsApprovedForAll(element) => ::core::fmt::Display::fmt(element, f), - Self::Name(element) => ::core::fmt::Display::fmt(element, f), - Self::OwnerOf(element) => ::core::fmt::Display::fmt(element, f), - Self::SafeTransferFrom(element) => ::core::fmt::Display::fmt(element, f), - Self::SafeTransferFromWithFromAndToAndData(element) => ::core::fmt::Display::fmt(element, f), - Self::SetApprovalForAll(element) => ::core::fmt::Display::fmt(element, f), - Self::SupportsInterface(element) => ::core::fmt::Display::fmt(element, f), - Self::Symbol(element) => ::core::fmt::Display::fmt(element, f), - Self::TokenURI(element) => ::core::fmt::Display::fmt(element, f), - Self::TransferFrom(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for IERC721MetadataCalls { - fn from(value: ApproveCall) -> Self { - Self::Approve(value) - } - } - impl ::core::convert::From for IERC721MetadataCalls { - fn from(value: BalanceOfCall) -> Self { - Self::BalanceOf(value) - } - } - impl ::core::convert::From for IERC721MetadataCalls { - fn from(value: GetApprovedCall) -> Self { - Self::GetApproved(value) - } - } - impl ::core::convert::From for IERC721MetadataCalls { - fn from(value: IsApprovedForAllCall) -> Self { - Self::IsApprovedForAll(value) - } - } - impl ::core::convert::From for IERC721MetadataCalls { - fn from(value: NameCall) -> Self { - Self::Name(value) - } - } - impl ::core::convert::From for IERC721MetadataCalls { - fn from(value: OwnerOfCall) -> Self { - Self::OwnerOf(value) - } - } - impl ::core::convert::From for IERC721MetadataCalls { - fn from(value: SafeTransferFromCall) -> Self { - Self::SafeTransferFrom(value) - } - } - impl ::core::convert::From for IERC721MetadataCalls { - fn from(value: SafeTransferFromWithFromAndToAndDataCall) -> Self { - Self::SafeTransferFromWithFromAndToAndData(value) - } - } - impl ::core::convert::From for IERC721MetadataCalls { - fn from(value: SetApprovalForAllCall) -> Self { - Self::SetApprovalForAll(value) - } - } - impl ::core::convert::From for IERC721MetadataCalls { - fn from(value: SupportsInterfaceCall) -> Self { - Self::SupportsInterface(value) - } - } - impl ::core::convert::From for IERC721MetadataCalls { - fn from(value: SymbolCall) -> Self { - Self::Symbol(value) - } - } - impl ::core::convert::From for IERC721MetadataCalls { - fn from(value: TokenURICall) -> Self { - Self::TokenURI(value) - } - } - impl ::core::convert::From for IERC721MetadataCalls { - fn from(value: TransferFromCall) -> Self { - Self::TransferFrom(value) - } - } - ///Container type for all return fields from the `balanceOf` function with signature `balanceOf(address)` and selector `0x70a08231` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct BalanceOfReturn { - pub balance: ::ethers::core::types::U256, - } - ///Container type for all return fields from the `getApproved` function with signature `getApproved(uint256)` and selector `0x081812fc` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct GetApprovedReturn { - pub operator: ::ethers::core::types::Address, - } - ///Container type for all return fields from the `isApprovedForAll` function with signature `isApprovedForAll(address,address)` and selector `0xe985e9c5` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct IsApprovedForAllReturn(pub bool); - ///Container type for all return fields from the `name` function with signature `name()` and selector `0x06fdde03` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct NameReturn(pub ::std::string::String); - ///Container type for all return fields from the `ownerOf` function with signature `ownerOf(uint256)` and selector `0x6352211e` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct OwnerOfReturn { - pub owner: ::ethers::core::types::Address, - } - ///Container type for all return fields from the `supportsInterface` function with signature `supportsInterface(bytes4)` and selector `0x01ffc9a7` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct SupportsInterfaceReturn(pub bool); - ///Container type for all return fields from the `symbol` function with signature `symbol()` and selector `0x95d89b41` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct SymbolReturn(pub ::std::string::String); - ///Container type for all return fields from the `tokenURI` function with signature `tokenURI(uint256)` and selector `0xc87b56dd` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct TokenURIReturn(pub ::std::string::String); -} diff --git a/src/bindings/ierc721_permit.rs b/src/bindings/ierc721_permit.rs deleted file mode 100644 index d604e8d..0000000 --- a/src/bindings/ierc721_permit.rs +++ /dev/null @@ -1,1226 +0,0 @@ -pub use ierc721_permit::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod ierc721_permit { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("DOMAIN_SEPARATOR"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("DOMAIN_SEPARATOR"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::FixedBytes(32usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes32"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("PERMIT_TYPEHASH"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("PERMIT_TYPEHASH"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::FixedBytes(32usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes32"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Pure, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("approve"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("approve"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("balanceOf"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("balanceOf"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("balance"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("getApproved"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("getApproved"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("operator"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("isApprovedForAll"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("isApprovedForAll"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("operator"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("ownerOf"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("ownerOf"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("permit"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("permit"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("spender"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("deadline"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("v"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint8"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("r"), - kind: ::ethers::core::abi::ethabi::ParamType::FixedBytes(32usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "bytes32" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("s"), - kind: ::ethers::core::abi::ethabi::ParamType::FixedBytes(32usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "bytes32" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Payable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("safeTransferFrom"), - ::std::vec![ - ::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("safeTransferFrom"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - }, - ::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("safeTransferFrom"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("data"), - kind: ::ethers::core::abi::ethabi::ParamType::Bytes, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "bytes" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - }, - ], - ), - ( - ::std::borrow::ToOwned::to_owned("setApprovalForAll"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("setApprovalForAll"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("operator"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("approved"), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("supportsInterface"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("supportsInterface"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("interfaceId"), - kind: ::ethers::core::abi::ethabi::ParamType::FixedBytes(4usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes4"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("transferFrom"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("transferFrom"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ]), - events: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("Approval"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Approval"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("approved"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: true, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("ApprovalForAll"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("ApprovalForAll"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("operator"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("approved"), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("Transfer"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Transfer"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("tokenId"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: true, - }, - ], - anonymous: false, - },], - ), - ]), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static IERC721PERMIT_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - pub struct IERC721Permit(::ethers::contract::Contract); - impl ::core::clone::Clone for IERC721Permit { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for IERC721Permit { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for IERC721Permit { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for IERC721Permit { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(IERC721Permit)) - .field(&self.address()) - .finish() - } - } - impl IERC721Permit { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - IERC721PERMIT_ABI.clone(), - client, - )) - } - ///Calls the contract's `DOMAIN_SEPARATOR` (0x3644e515) function - pub fn domain_separator(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([54, 68, 229, 21], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `PERMIT_TYPEHASH` (0x30adf81f) function - pub fn permit_typehash(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([48, 173, 248, 31], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `approve` (0x095ea7b3) function - pub fn approve( - &self, - to: ::ethers::core::types::Address, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([9, 94, 167, 179], (to, token_id)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `balanceOf` (0x70a08231) function - pub fn balance_of( - &self, - owner: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([112, 160, 130, 49], owner) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `getApproved` (0x081812fc) function - pub fn get_approved( - &self, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([8, 24, 18, 252], token_id) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `isApprovedForAll` (0xe985e9c5) function - pub fn is_approved_for_all( - &self, - owner: ::ethers::core::types::Address, - operator: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([233, 133, 233, 197], (owner, operator)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `ownerOf` (0x6352211e) function - pub fn owner_of( - &self, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([99, 82, 33, 30], token_id) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `permit` (0x7ac2ff7b) function - pub fn permit( - &self, - spender: ::ethers::core::types::Address, - token_id: ::ethers::core::types::U256, - deadline: ::ethers::core::types::U256, - v: u8, - r: [u8; 32], - s: [u8; 32], - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([122, 194, 255, 123], (spender, token_id, deadline, v, r, s)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `safeTransferFrom` (0x42842e0e) function - pub fn safe_transfer_from( - &self, - from: ::ethers::core::types::Address, - to: ::ethers::core::types::Address, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([66, 132, 46, 14], (from, to, token_id)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `safeTransferFrom` (0xb88d4fde) function - pub fn safe_transfer_from_with_from_and_to_and_data( - &self, - from: ::ethers::core::types::Address, - to: ::ethers::core::types::Address, - token_id: ::ethers::core::types::U256, - data: ::ethers::core::types::Bytes, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([184, 141, 79, 222], (from, to, token_id, data)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `setApprovalForAll` (0xa22cb465) function - pub fn set_approval_for_all( - &self, - operator: ::ethers::core::types::Address, - approved: bool, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([162, 44, 180, 101], (operator, approved)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `supportsInterface` (0x01ffc9a7) function - pub fn supports_interface(&self, interface_id: [u8; 4]) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([1, 255, 201, 167], interface_id) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `transferFrom` (0x23b872dd) function - pub fn transfer_from( - &self, - from: ::ethers::core::types::Address, - to: ::ethers::core::types::Address, - token_id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([35, 184, 114, 221], (from, to, token_id)) - .expect("method not found (this should never happen)") - } - ///Gets the contract's `Approval` event - pub fn approval_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, ApprovalFilter> { - self.0.event() - } - ///Gets the contract's `ApprovalForAll` event - pub fn approval_for_all_filter( - &self, - ) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, ApprovalForAllFilter> { - self.0.event() - } - ///Gets the contract's `Transfer` event - pub fn transfer_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, TransferFilter> { - self.0.event() - } - /// Returns an `Event` builder for all the events of this contract. - pub fn events(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, IERC721PermitEvents> { - self.0.event_with_filter(::core::default::Default::default()) - } - } - impl From<::ethers::contract::Contract> for IERC721Permit { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Approval", abi = "Approval(address,address,uint256)")] - pub struct ApprovalFilter { - #[ethevent(indexed)] - pub owner: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub approved: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub token_id: ::ethers::core::types::U256, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "ApprovalForAll", abi = "ApprovalForAll(address,address,bool)")] - pub struct ApprovalForAllFilter { - #[ethevent(indexed)] - pub owner: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub operator: ::ethers::core::types::Address, - pub approved: bool, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Transfer", abi = "Transfer(address,address,uint256)")] - pub struct TransferFilter { - #[ethevent(indexed)] - pub from: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub to: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all of the contract's events - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum IERC721PermitEvents { - ApprovalFilter(ApprovalFilter), - ApprovalForAllFilter(ApprovalForAllFilter), - TransferFilter(TransferFilter), - } - impl ::ethers::contract::EthLogDecode for IERC721PermitEvents { - fn decode_log(log: &::ethers::core::abi::RawLog) -> ::core::result::Result { - if let Ok(decoded) = ApprovalFilter::decode_log(log) { - return Ok(IERC721PermitEvents::ApprovalFilter(decoded)); - } - if let Ok(decoded) = ApprovalForAllFilter::decode_log(log) { - return Ok(IERC721PermitEvents::ApprovalForAllFilter(decoded)); - } - if let Ok(decoded) = TransferFilter::decode_log(log) { - return Ok(IERC721PermitEvents::TransferFilter(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData) - } - } - impl ::core::fmt::Display for IERC721PermitEvents { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::ApprovalFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::ApprovalForAllFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::TransferFilter(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for IERC721PermitEvents { - fn from(value: ApprovalFilter) -> Self { - Self::ApprovalFilter(value) - } - } - impl ::core::convert::From for IERC721PermitEvents { - fn from(value: ApprovalForAllFilter) -> Self { - Self::ApprovalForAllFilter(value) - } - } - impl ::core::convert::From for IERC721PermitEvents { - fn from(value: TransferFilter) -> Self { - Self::TransferFilter(value) - } - } - ///Container type for all input parameters for the `DOMAIN_SEPARATOR` function with signature `DOMAIN_SEPARATOR()` and selector `0x3644e515` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "DOMAIN_SEPARATOR", abi = "DOMAIN_SEPARATOR()")] - pub struct DomainSeparatorCall; - ///Container type for all input parameters for the `PERMIT_TYPEHASH` function with signature `PERMIT_TYPEHASH()` and selector `0x30adf81f` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "PERMIT_TYPEHASH", abi = "PERMIT_TYPEHASH()")] - pub struct PermitTypehashCall; - ///Container type for all input parameters for the `approve` function with signature `approve(address,uint256)` and selector `0x095ea7b3` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "approve", abi = "approve(address,uint256)")] - pub struct ApproveCall { - pub to: ::ethers::core::types::Address, - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `balanceOf` function with signature `balanceOf(address)` and selector `0x70a08231` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "balanceOf", abi = "balanceOf(address)")] - pub struct BalanceOfCall { - pub owner: ::ethers::core::types::Address, - } - ///Container type for all input parameters for the `getApproved` function with signature `getApproved(uint256)` and selector `0x081812fc` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "getApproved", abi = "getApproved(uint256)")] - pub struct GetApprovedCall { - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `isApprovedForAll` function with signature `isApprovedForAll(address,address)` and selector `0xe985e9c5` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "isApprovedForAll", abi = "isApprovedForAll(address,address)")] - pub struct IsApprovedForAllCall { - pub owner: ::ethers::core::types::Address, - pub operator: ::ethers::core::types::Address, - } - ///Container type for all input parameters for the `ownerOf` function with signature `ownerOf(uint256)` and selector `0x6352211e` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "ownerOf", abi = "ownerOf(uint256)")] - pub struct OwnerOfCall { - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `permit` function with signature `permit(address,uint256,uint256,uint8,bytes32,bytes32)` and selector `0x7ac2ff7b` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "permit", abi = "permit(address,uint256,uint256,uint8,bytes32,bytes32)")] - pub struct PermitCall { - pub spender: ::ethers::core::types::Address, - pub token_id: ::ethers::core::types::U256, - pub deadline: ::ethers::core::types::U256, - pub v: u8, - pub r: [u8; 32], - pub s: [u8; 32], - } - ///Container type for all input parameters for the `safeTransferFrom` function with signature `safeTransferFrom(address,address,uint256)` and selector `0x42842e0e` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "safeTransferFrom", abi = "safeTransferFrom(address,address,uint256)")] - pub struct SafeTransferFromCall { - pub from: ::ethers::core::types::Address, - pub to: ::ethers::core::types::Address, - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `safeTransferFrom` function with signature `safeTransferFrom(address,address,uint256,bytes)` and selector `0xb88d4fde` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "safeTransferFrom", abi = "safeTransferFrom(address,address,uint256,bytes)")] - pub struct SafeTransferFromWithFromAndToAndDataCall { - pub from: ::ethers::core::types::Address, - pub to: ::ethers::core::types::Address, - pub token_id: ::ethers::core::types::U256, - pub data: ::ethers::core::types::Bytes, - } - ///Container type for all input parameters for the `setApprovalForAll` function with signature `setApprovalForAll(address,bool)` and selector `0xa22cb465` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "setApprovalForAll", abi = "setApprovalForAll(address,bool)")] - pub struct SetApprovalForAllCall { - pub operator: ::ethers::core::types::Address, - pub approved: bool, - } - ///Container type for all input parameters for the `supportsInterface` function with signature `supportsInterface(bytes4)` and selector `0x01ffc9a7` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "supportsInterface", abi = "supportsInterface(bytes4)")] - pub struct SupportsInterfaceCall { - pub interface_id: [u8; 4], - } - ///Container type for all input parameters for the `transferFrom` function with signature `transferFrom(address,address,uint256)` and selector `0x23b872dd` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "transferFrom", abi = "transferFrom(address,address,uint256)")] - pub struct TransferFromCall { - pub from: ::ethers::core::types::Address, - pub to: ::ethers::core::types::Address, - pub token_id: ::ethers::core::types::U256, - } - ///Container type for all of the contract's call - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum IERC721PermitCalls { - DomainSeparator(DomainSeparatorCall), - PermitTypehash(PermitTypehashCall), - Approve(ApproveCall), - BalanceOf(BalanceOfCall), - GetApproved(GetApprovedCall), - IsApprovedForAll(IsApprovedForAllCall), - OwnerOf(OwnerOfCall), - Permit(PermitCall), - SafeTransferFrom(SafeTransferFromCall), - SafeTransferFromWithFromAndToAndData(SafeTransferFromWithFromAndToAndDataCall), - SetApprovalForAll(SetApprovalForAllCall), - SupportsInterface(SupportsInterfaceCall), - TransferFrom(TransferFromCall), - } - impl ::ethers::core::abi::AbiDecode for IERC721PermitCalls { - fn decode(data: impl AsRef<[u8]>) -> ::core::result::Result { - let data = data.as_ref(); - if let Ok(decoded) = ::decode(data) { - return Ok(Self::DomainSeparator(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::PermitTypehash(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Approve(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::BalanceOf(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::GetApproved(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::IsApprovedForAll(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::OwnerOf(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Permit(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SafeTransferFrom(decoded)); - } - if let Ok(decoded) = - ::decode(data) - { - return Ok(Self::SafeTransferFromWithFromAndToAndData(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SetApprovalForAll(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SupportsInterface(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TransferFrom(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData.into()) - } - } - impl ::ethers::core::abi::AbiEncode for IERC721PermitCalls { - fn encode(self) -> Vec { - match self { - Self::DomainSeparator(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::PermitTypehash(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Approve(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::BalanceOf(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::GetApproved(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::IsApprovedForAll(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::OwnerOf(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Permit(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SafeTransferFrom(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SafeTransferFromWithFromAndToAndData(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SetApprovalForAll(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SupportsInterface(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TransferFrom(element) => ::ethers::core::abi::AbiEncode::encode(element), - } - } - } - impl ::core::fmt::Display for IERC721PermitCalls { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::DomainSeparator(element) => ::core::fmt::Display::fmt(element, f), - Self::PermitTypehash(element) => ::core::fmt::Display::fmt(element, f), - Self::Approve(element) => ::core::fmt::Display::fmt(element, f), - Self::BalanceOf(element) => ::core::fmt::Display::fmt(element, f), - Self::GetApproved(element) => ::core::fmt::Display::fmt(element, f), - Self::IsApprovedForAll(element) => ::core::fmt::Display::fmt(element, f), - Self::OwnerOf(element) => ::core::fmt::Display::fmt(element, f), - Self::Permit(element) => ::core::fmt::Display::fmt(element, f), - Self::SafeTransferFrom(element) => ::core::fmt::Display::fmt(element, f), - Self::SafeTransferFromWithFromAndToAndData(element) => ::core::fmt::Display::fmt(element, f), - Self::SetApprovalForAll(element) => ::core::fmt::Display::fmt(element, f), - Self::SupportsInterface(element) => ::core::fmt::Display::fmt(element, f), - Self::TransferFrom(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for IERC721PermitCalls { - fn from(value: DomainSeparatorCall) -> Self { - Self::DomainSeparator(value) - } - } - impl ::core::convert::From for IERC721PermitCalls { - fn from(value: PermitTypehashCall) -> Self { - Self::PermitTypehash(value) - } - } - impl ::core::convert::From for IERC721PermitCalls { - fn from(value: ApproveCall) -> Self { - Self::Approve(value) - } - } - impl ::core::convert::From for IERC721PermitCalls { - fn from(value: BalanceOfCall) -> Self { - Self::BalanceOf(value) - } - } - impl ::core::convert::From for IERC721PermitCalls { - fn from(value: GetApprovedCall) -> Self { - Self::GetApproved(value) - } - } - impl ::core::convert::From for IERC721PermitCalls { - fn from(value: IsApprovedForAllCall) -> Self { - Self::IsApprovedForAll(value) - } - } - impl ::core::convert::From for IERC721PermitCalls { - fn from(value: OwnerOfCall) -> Self { - Self::OwnerOf(value) - } - } - impl ::core::convert::From for IERC721PermitCalls { - fn from(value: PermitCall) -> Self { - Self::Permit(value) - } - } - impl ::core::convert::From for IERC721PermitCalls { - fn from(value: SafeTransferFromCall) -> Self { - Self::SafeTransferFrom(value) - } - } - impl ::core::convert::From for IERC721PermitCalls { - fn from(value: SafeTransferFromWithFromAndToAndDataCall) -> Self { - Self::SafeTransferFromWithFromAndToAndData(value) - } - } - impl ::core::convert::From for IERC721PermitCalls { - fn from(value: SetApprovalForAllCall) -> Self { - Self::SetApprovalForAll(value) - } - } - impl ::core::convert::From for IERC721PermitCalls { - fn from(value: SupportsInterfaceCall) -> Self { - Self::SupportsInterface(value) - } - } - impl ::core::convert::From for IERC721PermitCalls { - fn from(value: TransferFromCall) -> Self { - Self::TransferFrom(value) - } - } - ///Container type for all return fields from the `DOMAIN_SEPARATOR` function with signature `DOMAIN_SEPARATOR()` and selector `0x3644e515` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct DomainSeparatorReturn(pub [u8; 32]); - ///Container type for all return fields from the `PERMIT_TYPEHASH` function with signature `PERMIT_TYPEHASH()` and selector `0x30adf81f` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct PermitTypehashReturn(pub [u8; 32]); - ///Container type for all return fields from the `balanceOf` function with signature `balanceOf(address)` and selector `0x70a08231` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct BalanceOfReturn { - pub balance: ::ethers::core::types::U256, - } - ///Container type for all return fields from the `getApproved` function with signature `getApproved(uint256)` and selector `0x081812fc` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct GetApprovedReturn { - pub operator: ::ethers::core::types::Address, - } - ///Container type for all return fields from the `isApprovedForAll` function with signature `isApprovedForAll(address,address)` and selector `0xe985e9c5` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct IsApprovedForAllReturn(pub bool); - ///Container type for all return fields from the `ownerOf` function with signature `ownerOf(uint256)` and selector `0x6352211e` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct OwnerOfReturn { - pub owner: ::ethers::core::types::Address, - } - ///Container type for all return fields from the `supportsInterface` function with signature `supportsInterface(bytes4)` and selector `0x01ffc9a7` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct SupportsInterfaceReturn(pub bool); -} diff --git a/src/bindings/ierc721_token_receiver.rs b/src/bindings/ierc721_token_receiver.rs deleted file mode 100644 index 6b599e2..0000000 --- a/src/bindings/ierc721_token_receiver.rs +++ /dev/null @@ -1,147 +0,0 @@ -pub use ierc721_token_receiver::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod ierc721_token_receiver { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([( - ::std::borrow::ToOwned::to_owned("onERC721Received"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("onERC721Received"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Bytes, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes"),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::FixedBytes(4usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes4"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - )]), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static IERC721TOKENRECEIVER_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - pub struct IERC721TokenReceiver(::ethers::contract::Contract); - impl ::core::clone::Clone for IERC721TokenReceiver { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for IERC721TokenReceiver { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for IERC721TokenReceiver { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for IERC721TokenReceiver { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(IERC721TokenReceiver)) - .field(&self.address()) - .finish() - } - } - impl IERC721TokenReceiver { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - IERC721TOKENRECEIVER_ABI.clone(), - client, - )) - } - ///Calls the contract's `onERC721Received` (0x150b7a02) function - pub fn on_erc721_received( - &self, - p0: ::ethers::core::types::Address, - p1: ::ethers::core::types::Address, - p2: ::ethers::core::types::U256, - p3: ::ethers::core::types::Bytes, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([21, 11, 122, 2], (p0, p1, p2, p3)) - .expect("method not found (this should never happen)") - } - } - impl From<::ethers::contract::Contract> for IERC721TokenReceiver { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Container type for all input parameters for the `onERC721Received` function with signature `onERC721Received(address,address,uint256,bytes)` and selector `0x150b7a02` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "onERC721Received", abi = "onERC721Received(address,address,uint256,bytes)")] - pub struct OnERC721ReceivedCall( - pub ::ethers::core::types::Address, - pub ::ethers::core::types::Address, - pub ::ethers::core::types::U256, - pub ::ethers::core::types::Bytes, - ); - ///Container type for all return fields from the `onERC721Received` function with signature `onERC721Received(address,address,uint256,bytes)` and selector `0x150b7a02` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct OnERC721ReceivedReturn(pub [u8; 4]); -} diff --git a/src/bindings/lib_bit.rs b/src/bindings/lib_bit.rs deleted file mode 100644 index 2a0f869..0000000 --- a/src/bindings/lib_bit.rs +++ /dev/null @@ -1,111 +0,0 @@ -pub use lib_bit::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod lib_bit { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::std::collections::BTreeMap::new(), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static LIBBIT_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`-`7`\x0B\x82\x82\x829\x80Q`\0\x1A`s\x14`*WcNH{q`\xE0\x1B`\0R`\0`\x04R`$`\0\xFD[0`\0R`s\x81S\x82\x81\xF3\xFEs\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The bytecode of the contract. - pub static LIBBIT_BYTECODE: ::ethers::core::types::Bytes = ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"s\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static LIBBIT_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct LibBit(::ethers::contract::Contract); - impl ::core::clone::Clone for LibBit { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for LibBit { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for LibBit { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for LibBit { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(LibBit)) - .field(&self.address()) - .finish() - } - } - impl LibBit { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - LIBBIT_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = - ::ethers::contract::ContractFactory::new(LIBBIT_ABI.clone(), LIBBIT_BYTECODE.clone().into(), client); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - } - impl From<::ethers::contract::Contract> for LibBit { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } -} diff --git a/src/bindings/liquidity_amounts.rs b/src/bindings/liquidity_amounts.rs deleted file mode 100644 index e831503..0000000 --- a/src/bindings/liquidity_amounts.rs +++ /dev/null @@ -1,116 +0,0 @@ -pub use liquidity_amounts::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod liquidity_amounts { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::std::collections::BTreeMap::new(), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static LIQUIDITYAMOUNTS_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`-`7`\x0B\x82\x82\x829\x80Q`\0\x1A`s\x14`*WcNH{q`\xE0\x1B`\0R`\0`\x04R`$`\0\xFD[0`\0R`s\x81S\x82\x81\xF3\xFEs\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The bytecode of the contract. - pub static LIQUIDITYAMOUNTS_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"s\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static LIQUIDITYAMOUNTS_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct LiquidityAmounts(::ethers::contract::Contract); - impl ::core::clone::Clone for LiquidityAmounts { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for LiquidityAmounts { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for LiquidityAmounts { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for LiquidityAmounts { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(LiquidityAmounts)) - .field(&self.address()) - .finish() - } - } - impl LiquidityAmounts { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - LIQUIDITYAMOUNTS_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - LIQUIDITYAMOUNTS_ABI.clone(), - LIQUIDITYAMOUNTS_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - } - impl From<::ethers::contract::Contract> for LiquidityAmounts { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } -} diff --git a/src/bindings/mock_erc20.rs b/src/bindings/mock_erc20.rs deleted file mode 100644 index 9b26701..0000000 --- a/src/bindings/mock_erc20.rs +++ /dev/null @@ -1,1222 +0,0 @@ -pub use mock_erc20::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod mock_erc20 { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("DOMAIN_SEPARATOR"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("DOMAIN_SEPARATOR"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::FixedBytes(32usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes32"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("allowance"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("allowance"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("approve"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("approve"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("spender"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("balanceOf"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("balanceOf"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("decimals"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("decimals"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint8"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("initialize"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("initialize"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("_name"), - kind: ::ethers::core::abi::ethabi::ParamType::String, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("string"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("_symbol"), - kind: ::ethers::core::abi::ethabi::ParamType::String, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("string"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("_decimals"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint8"),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("name"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("name"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::String, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("string"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("nonces"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("nonces"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("permit"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("permit"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("spender"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("value"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("deadline"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("v"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(8usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint8"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("r"), - kind: ::ethers::core::abi::ethabi::ParamType::FixedBytes(32usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "bytes32" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("s"), - kind: ::ethers::core::abi::ethabi::ParamType::FixedBytes(32usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "bytes32" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("symbol"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("symbol"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::String, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("string"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("totalSupply"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("totalSupply"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("transfer"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("transfer"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("transferFrom"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("transferFrom"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ]), - events: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("Approval"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Approval"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("spender"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("Transfer"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Transfer"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("amount"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: false, - }, - ], - anonymous: false, - },], - ), - ]), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static MOCKERC20_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`\x80`@R4\x80\x15a\0\x10W`\0\x80\xFD[Pa\x11~\x80a\0 `\09`\0\xF3\xFE`\x80`@R4\x80\x15a\0\x10W`\0\x80\xFD[P`\x046\x10a\0\xDFW`\x005`\xE0\x1C\x80c6D\xE5\x15\x11a\0\x8CW\x80c\x95\xD8\x9BA\x11a\0fW\x80c\x95\xD8\x9BA\x14a\x01\xCBW\x80c\xA9\x05\x9C\xBB\x14a\x01\xD3W\x80c\xD5\x05\xAC\xCF\x14a\x01\xE6W\x80c\xDDb\xED>\x14a\x01\xF9W`\0\x80\xFD[\x80c6D\xE5\x15\x14a\x01\x83W\x80cp\xA0\x821\x14a\x01\x8BW\x80c~\xCE\xBE\0\x14a\x01\xABW`\0\x80\xFD[\x80c\x18\x16\r\xDD\x11a\0\xBDW\x80c\x18\x16\r\xDD\x14a\x01:W\x80c#\xB8r\xDD\x14a\x01QW\x80c1<\xE5g\x14a\x01dW`\0\x80\xFD[\x80c\x06\xFD\xDE\x03\x14a\0\xE4W\x80c\t^\xA7\xB3\x14a\x01\x02W\x80c\x16$\xF6\xC6\x14a\x01%W[`\0\x80\xFD[a\0\xECa\x02$V[`@Qa\0\xF9\x91\x90a\x0B\x7FV[`@Q\x80\x91\x03\x90\xF3[a\x01\x15a\x01\x106`\x04a\x0C\x15V[a\x02\xB2V[`@Q\x90\x15\x15\x81R` \x01a\0\xF9V[a\x018a\x0136`\x04a\r*V[a\x03,V[\0[a\x01C`\x03T\x81V[`@Q\x90\x81R` \x01a\0\xF9V[a\x01\x15a\x01_6`\x04a\r\x9EV[a\x04+V[`\x02Ta\x01q\x90`\xFF\x16\x81V[`@Q`\xFF\x90\x91\x16\x81R` \x01a\0\xF9V[a\x01Ca\x05\x9FV[a\x01Ca\x01\x996`\x04a\r\xDAV[`\x04` R`\0\x90\x81R`@\x90 T\x81V[a\x01Ca\x01\xB96`\x04a\r\xDAV[`\x08` R`\0\x90\x81R`@\x90 T\x81V[a\0\xECa\x05\xC5V[a\x01\x15a\x01\xE16`\x04a\x0C\x15V[a\x05\xD2V[a\x018a\x01\xF46`\x04a\r\xF5V[a\x06\x83V[a\x01Ca\x02\x076`\x04a\x0E_V[`\x05` \x90\x81R`\0\x92\x83R`@\x80\x84 \x90\x91R\x90\x82R\x90 T\x81V[`\0\x80Ta\x021\x90a\x0E\x92V[\x80`\x1F\x01` \x80\x91\x04\x02` \x01`@Q\x90\x81\x01`@R\x80\x92\x91\x90\x81\x81R` \x01\x82\x80Ta\x02]\x90a\x0E\x92V[\x80\x15a\x02\xAAW\x80`\x1F\x10a\x02\x7FWa\x01\0\x80\x83T\x04\x02\x83R\x91` \x01\x91a\x02\xAAV[\x82\x01\x91\x90`\0R` `\0 \x90[\x81T\x81R\x90`\x01\x01\x90` \x01\x80\x83\x11a\x02\x8DW\x82\x90\x03`\x1F\x16\x82\x01\x91[PPPPP\x81V[3`\0\x81\x81R`\x05` \x90\x81R`@\x80\x83 s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x87\x16\x80\x85R\x92R\x80\x83 \x85\x90UQ\x91\x92\x90\x91\x7F\x8C[\xE1\xE5\xEB\xEC}[\xD1OqB}\x1E\x84\xF3\xDD\x03\x14\xC0\xF7\xB2)\x1E[ \n\xC8\xC7\xC3\xB9%\x90a\x03\x1A\x90\x86\x81R` \x01\x90V[`@Q\x80\x91\x03\x90\xA3P`\x01[\x92\x91PPV[`\tT`\xFF\x16\x15a\x03\x9EW`@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\x82\x01R`\x13`$\x82\x01R\x7FALREADY_INITIALIZED\0\0\0\0\0\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01[`@Q\x80\x91\x03\x90\xFD[`\0a\x03\xAA\x84\x82a\x0F6V[P`\x01a\x03\xB7\x83\x82a\x0F6V[P`\x02\x80T\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\0\x16`\xFF\x83\x16\x17\x90Ua\x03\xEDa\t\xC9V[`\x06Ua\x03\xF8a\t\xE2V[`\x07UPP`\t\x80T\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\0\x16`\x01\x17\x90UPV[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x83\x16`\0\x90\x81R`\x05` \x90\x81R`@\x80\x83 3\x84R\x90\x91R\x81 T\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x14a\x04\xBFWa\x04\x8D\x81\x84a\n\x85V[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x86\x16`\0\x90\x81R`\x05` \x90\x81R`@\x80\x83 3\x84R\x90\x91R\x90 U[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x85\x16`\0\x90\x81R`\x04` R`@\x90 Ta\x04\xEF\x90\x84a\n\x85V[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x87\x16`\0\x90\x81R`\x04` R`@\x80\x82 \x93\x90\x93U\x90\x86\x16\x81R Ta\x05+\x90\x84a\x0B\x02V[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x86\x16`\0\x81\x81R`\x04` R`@\x90\x81\x90 \x93\x90\x93U\x91Q\x90\x87\x16\x90\x7F\xDD\xF2R\xAD\x1B\xE2\xC8\x9Bi\xC2\xB0h\xFC7\x8D\xAA\x95+\xA7\xF1c\xC4\xA1\x16(\xF5ZM\xF5#\xB3\xEF\x90a\x05\x8C\x90\x87\x81R` \x01\x90V[`@Q\x80\x91\x03\x90\xA3P`\x01\x94\x93PPPPV[`\0`\x06Ta\x05\xACa\t\xC9V[\x14a\x05\xBEWa\x05\xB9a\t\xE2V[\x90P\x90V[P`\x07T\x90V[`\x01\x80Ta\x021\x90a\x0E\x92V[3`\0\x90\x81R`\x04` R`@\x81 Ta\x05\xEC\x90\x83a\n\x85V[3`\0\x90\x81R`\x04` R`@\x80\x82 \x92\x90\x92Us\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x85\x16\x81R Ta\x06%\x90\x83a\x0B\x02V[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x84\x16`\0\x81\x81R`\x04` R`@\x90\x81\x90 \x92\x90\x92U\x90Q3\x90\x7F\xDD\xF2R\xAD\x1B\xE2\xC8\x9Bi\xC2\xB0h\xFC7\x8D\xAA\x95+\xA7\xF1c\xC4\xA1\x16(\xF5ZM\xF5#\xB3\xEF\x90a\x03\x1A\x90\x86\x81R` \x01\x90V[B\x84\x10\x15a\x06\xEDW`@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\x82\x01R`\x17`$\x82\x01R\x7FPERMIT_DEADLINE_EXPIRED\0\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01a\x03\x95V[`\0`\x01a\x06\xF9a\x05\x9FV[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x8A\x16`\0\x90\x81R`\x08` R`@\x81 \x80T\x7Fnq\xED\xAE\x12\xB1\xB9\x7FM\x1F`7\x0F\xEF\x10\x10_\xA2\xFA\xAE\x01&\x11J\x16\x9Cd\x84]a&\xC9\x92\x8D\x92\x8D\x92\x8D\x92\x90\x91\x90a\x07T\x83a\x10\x7FV[\x90\x91UP`@\x80Q` \x81\x01\x96\x90\x96Rs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x94\x85\x16\x90\x86\x01R\x92\x90\x91\x16``\x84\x01R`\x80\x83\x01R`\xA0\x82\x01R`\xC0\x81\x01\x88\x90R`\xE0\x01`@Q` \x81\x83\x03\x03\x81R\x90`@R\x80Q\x90` \x01 `@Q` \x01a\x07\xF5\x92\x91\x90\x7F\x19\x01\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\0\0\x81R`\x02\x81\x01\x92\x90\x92R`\"\x82\x01R`B\x01\x90V[`@\x80Q\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xE0\x81\x84\x03\x01\x81R\x82\x82R\x80Q` \x91\x82\x01 `\0\x84R\x90\x83\x01\x80\x83RR`\xFF\x87\x16\x90\x82\x01R``\x81\x01\x85\x90R`\x80\x81\x01\x84\x90R`\xA0\x01` `@Q` \x81\x03\x90\x80\x84\x03\x90\x85Z\xFA\x15\x80\x15a\x08qW=`\0\x80>=`\0\xFD[PP`@Q\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xE0\x01Q\x91PPs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x16\x15\x80\x15\x90a\x08\xECWP\x87s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x81s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x14[a\tRW`@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\x82\x01R`\x0E`$\x82\x01R\x7FINVALID_SIGNER\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01a\x03\x95V[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x81\x16`\0\x90\x81R`\x05` \x90\x81R`@\x80\x83 \x8B\x85\x16\x80\x85R\x90\x83R\x92\x81\x90 \x8A\x90UQ\x89\x81R\x91\x92\x8B\x16\x91\x7F\x8C[\xE1\xE5\xEB\xEC}[\xD1OqB}\x1E\x84\xF3\xDD\x03\x14\xC0\xF7\xB2)\x1E[ \n\xC8\xC7\xC3\xB9%\x91\x01`@Q\x80\x91\x03\x90\xA3PPPPPPPPV[`\0a\x0B{\x80a\t\xDBc\xFF\xFF\xFF\xFF\x82\x16V[\x92PPP\x90V[`\0\x7F\x8Bs\xC3\xC6\x9B\xB8\xFE=Q.\xCCL\xF7Y\xCCy#\x9F{\x17\x9B\x0F\xFA\xCA\xA9\xA7]R+9@\x0F`\0`@Qa\n\x14\x91\x90a\x10\xB7V[`@Q\x80\x91\x03\x90 \x7F\xC8\x9E\xFD\xAAT\xC0\xF2\x0Cz\xDFa(\x82\xDF\tP\xF5\xA9Qc~\x03\x07\xCD\xCBLg/)\x8B\x8B\xC6a\nEa\t\xC9V[`@\x80Q` \x81\x01\x95\x90\x95R\x84\x01\x92\x90\x92R``\x83\x01R`\x80\x82\x01R0`\xA0\x82\x01R`\xC0\x01`@Q` \x81\x83\x03\x03\x81R\x90`@R\x80Q\x90` \x01 \x90P\x90V[`\0\x81\x83\x10\x15a\n\xF1W`@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\x82\x01R`\x1C`$\x82\x01R\x7FERC20: subtraction underflow\0\0\0\0`D\x82\x01R`d\x01a\x03\x95V[a\n\xFB\x82\x84a\x11KV[\x93\x92PPPV[`\0\x80a\x0B\x0F\x83\x85a\x11^V[\x90P\x83\x81\x10\x15a\n\xFBW`@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\x82\x01R`\x18`$\x82\x01R\x7FERC20: addition overflow\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01a\x03\x95V[F\x90V[`\0` \x80\x83R\x83Q\x80` \x85\x01R`\0[\x81\x81\x10\x15a\x0B\xADW\x85\x81\x01\x83\x01Q\x85\x82\x01`@\x01R\x82\x01a\x0B\x91V[P`\0`@\x82\x86\x01\x01R`@\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xE0`\x1F\x83\x01\x16\x85\x01\x01\x92PPP\x92\x91PPV[\x805s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x16\x81\x14a\x0C\x10W`\0\x80\xFD[\x91\x90PV[`\0\x80`@\x83\x85\x03\x12\x15a\x0C(W`\0\x80\xFD[a\x0C1\x83a\x0B\xECV[\x94` \x93\x90\x93\x015\x93PPPV[\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`\0R`A`\x04R`$`\0\xFD[`\0\x82`\x1F\x83\x01\x12a\x0C\x7FW`\0\x80\xFD[\x815g\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x82\x11\x15a\x0C\x9AWa\x0C\x9Aa\x0C?V[`@Q`\x1F\x83\x01\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xE0\x90\x81\x16`?\x01\x16\x81\x01\x90\x82\x82\x11\x81\x83\x10\x17\x15a\x0C\xE0Wa\x0C\xE0a\x0C?V[\x81`@R\x83\x81R\x86` \x85\x88\x01\x01\x11\x15a\x0C\xF9W`\0\x80\xFD[\x83` \x87\x01` \x83\x017`\0` \x85\x83\x01\x01R\x80\x94PPPPP\x92\x91PPV[\x805`\xFF\x81\x16\x81\x14a\x0C\x10W`\0\x80\xFD[`\0\x80`\0``\x84\x86\x03\x12\x15a\r?W`\0\x80\xFD[\x835g\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x82\x11\x15a\rWW`\0\x80\xFD[a\rc\x87\x83\x88\x01a\x0CnV[\x94P` \x86\x015\x91P\x80\x82\x11\x15a\ryW`\0\x80\xFD[Pa\r\x86\x86\x82\x87\x01a\x0CnV[\x92PPa\r\x95`@\x85\x01a\r\x19V[\x90P\x92P\x92P\x92V[`\0\x80`\0``\x84\x86\x03\x12\x15a\r\xB3W`\0\x80\xFD[a\r\xBC\x84a\x0B\xECV[\x92Pa\r\xCA` \x85\x01a\x0B\xECV[\x91P`@\x84\x015\x90P\x92P\x92P\x92V[`\0` \x82\x84\x03\x12\x15a\r\xECW`\0\x80\xFD[a\n\xFB\x82a\x0B\xECV[`\0\x80`\0\x80`\0\x80`\0`\xE0\x88\x8A\x03\x12\x15a\x0E\x10W`\0\x80\xFD[a\x0E\x19\x88a\x0B\xECV[\x96Pa\x0E'` \x89\x01a\x0B\xECV[\x95P`@\x88\x015\x94P``\x88\x015\x93Pa\x0EC`\x80\x89\x01a\r\x19V[\x92P`\xA0\x88\x015\x91P`\xC0\x88\x015\x90P\x92\x95\x98\x91\x94\x97P\x92\x95PV[`\0\x80`@\x83\x85\x03\x12\x15a\x0ErW`\0\x80\xFD[a\x0E{\x83a\x0B\xECV[\x91Pa\x0E\x89` \x84\x01a\x0B\xECV[\x90P\x92P\x92\x90PV[`\x01\x81\x81\x1C\x90\x82\x16\x80a\x0E\xA6W`\x7F\x82\x16\x91P[` \x82\x10\x81\x03a\x0E\xDFW\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`\0R`\"`\x04R`$`\0\xFD[P\x91\x90PV[`\x1F\x82\x11\x15a\x0F1W`\0\x81`\0R` `\0 `\x1F\x85\x01`\x05\x1C\x81\x01` \x86\x10\x15a\x0F\x0EWP\x80[`\x1F\x85\x01`\x05\x1C\x82\x01\x91P[\x81\x81\x10\x15a\x0F-W\x82\x81U`\x01\x01a\x0F\x1AV[PPP[PPPV[\x81Qg\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x11\x15a\x0FPWa\x0FPa\x0C?V[a\x0Fd\x81a\x0F^\x84Ta\x0E\x92V[\x84a\x0E\xE5V[` \x80`\x1F\x83\x11`\x01\x81\x14a\x0F\xB7W`\0\x84\x15a\x0F\x81WP\x85\x83\x01Q[\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF`\x03\x86\x90\x1B\x1C\x19\x16`\x01\x85\x90\x1B\x17\x85Ua\x0F-V[`\0\x85\x81R` \x81 \x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xE0\x86\x16\x91[\x82\x81\x10\x15a\x10\x04W\x88\x86\x01Q\x82U\x94\x84\x01\x94`\x01\x90\x91\x01\x90\x84\x01a\x0F\xE5V[P\x85\x82\x10\x15a\x10@W\x87\x85\x01Q\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF`\x03\x88\x90\x1B`\xF8\x16\x1C\x19\x16\x81U[PPPPP`\x01\x90\x81\x1B\x01\x90UPV[\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`\0R`\x11`\x04R`$`\0\xFD[`\0\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x82\x03a\x10\xB0Wa\x10\xB0a\x10PV[P`\x01\x01\x90V[`\0\x80\x83Ta\x10\xC5\x81a\x0E\x92V[`\x01\x82\x81\x16\x80\x15a\x10\xDDW`\x01\x81\x14a\x11\x10Wa\x11?V[\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\0\x84\x16\x87R\x82\x15\x15\x83\x02\x87\x01\x94Pa\x11?V[\x87`\0R` \x80`\0 `\0[\x85\x81\x10\x15a\x116W\x81T\x8A\x82\x01R\x90\x84\x01\x90\x82\x01a\x11\x1DV[PPP\x82\x87\x01\x94P[P\x92\x96\x95PPPPPPV[\x81\x81\x03\x81\x81\x11\x15a\x03&Wa\x03&a\x10PV[\x80\x82\x01\x80\x82\x11\x15a\x03&Wa\x03&a\x10PV\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The bytecode of the contract. - pub static MOCKERC20_BYTECODE: ::ethers::core::types::Bytes = ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"`\x80`@R4\x80\x15a\0\x10W`\0\x80\xFD[P`\x046\x10a\0\xDFW`\x005`\xE0\x1C\x80c6D\xE5\x15\x11a\0\x8CW\x80c\x95\xD8\x9BA\x11a\0fW\x80c\x95\xD8\x9BA\x14a\x01\xCBW\x80c\xA9\x05\x9C\xBB\x14a\x01\xD3W\x80c\xD5\x05\xAC\xCF\x14a\x01\xE6W\x80c\xDDb\xED>\x14a\x01\xF9W`\0\x80\xFD[\x80c6D\xE5\x15\x14a\x01\x83W\x80cp\xA0\x821\x14a\x01\x8BW\x80c~\xCE\xBE\0\x14a\x01\xABW`\0\x80\xFD[\x80c\x18\x16\r\xDD\x11a\0\xBDW\x80c\x18\x16\r\xDD\x14a\x01:W\x80c#\xB8r\xDD\x14a\x01QW\x80c1<\xE5g\x14a\x01dW`\0\x80\xFD[\x80c\x06\xFD\xDE\x03\x14a\0\xE4W\x80c\t^\xA7\xB3\x14a\x01\x02W\x80c\x16$\xF6\xC6\x14a\x01%W[`\0\x80\xFD[a\0\xECa\x02$V[`@Qa\0\xF9\x91\x90a\x0B\x7FV[`@Q\x80\x91\x03\x90\xF3[a\x01\x15a\x01\x106`\x04a\x0C\x15V[a\x02\xB2V[`@Q\x90\x15\x15\x81R` \x01a\0\xF9V[a\x018a\x0136`\x04a\r*V[a\x03,V[\0[a\x01C`\x03T\x81V[`@Q\x90\x81R` \x01a\0\xF9V[a\x01\x15a\x01_6`\x04a\r\x9EV[a\x04+V[`\x02Ta\x01q\x90`\xFF\x16\x81V[`@Q`\xFF\x90\x91\x16\x81R` \x01a\0\xF9V[a\x01Ca\x05\x9FV[a\x01Ca\x01\x996`\x04a\r\xDAV[`\x04` R`\0\x90\x81R`@\x90 T\x81V[a\x01Ca\x01\xB96`\x04a\r\xDAV[`\x08` R`\0\x90\x81R`@\x90 T\x81V[a\0\xECa\x05\xC5V[a\x01\x15a\x01\xE16`\x04a\x0C\x15V[a\x05\xD2V[a\x018a\x01\xF46`\x04a\r\xF5V[a\x06\x83V[a\x01Ca\x02\x076`\x04a\x0E_V[`\x05` \x90\x81R`\0\x92\x83R`@\x80\x84 \x90\x91R\x90\x82R\x90 T\x81V[`\0\x80Ta\x021\x90a\x0E\x92V[\x80`\x1F\x01` \x80\x91\x04\x02` \x01`@Q\x90\x81\x01`@R\x80\x92\x91\x90\x81\x81R` \x01\x82\x80Ta\x02]\x90a\x0E\x92V[\x80\x15a\x02\xAAW\x80`\x1F\x10a\x02\x7FWa\x01\0\x80\x83T\x04\x02\x83R\x91` \x01\x91a\x02\xAAV[\x82\x01\x91\x90`\0R` `\0 \x90[\x81T\x81R\x90`\x01\x01\x90` \x01\x80\x83\x11a\x02\x8DW\x82\x90\x03`\x1F\x16\x82\x01\x91[PPPPP\x81V[3`\0\x81\x81R`\x05` \x90\x81R`@\x80\x83 s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x87\x16\x80\x85R\x92R\x80\x83 \x85\x90UQ\x91\x92\x90\x91\x7F\x8C[\xE1\xE5\xEB\xEC}[\xD1OqB}\x1E\x84\xF3\xDD\x03\x14\xC0\xF7\xB2)\x1E[ \n\xC8\xC7\xC3\xB9%\x90a\x03\x1A\x90\x86\x81R` \x01\x90V[`@Q\x80\x91\x03\x90\xA3P`\x01[\x92\x91PPV[`\tT`\xFF\x16\x15a\x03\x9EW`@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\x82\x01R`\x13`$\x82\x01R\x7FALREADY_INITIALIZED\0\0\0\0\0\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01[`@Q\x80\x91\x03\x90\xFD[`\0a\x03\xAA\x84\x82a\x0F6V[P`\x01a\x03\xB7\x83\x82a\x0F6V[P`\x02\x80T\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\0\x16`\xFF\x83\x16\x17\x90Ua\x03\xEDa\t\xC9V[`\x06Ua\x03\xF8a\t\xE2V[`\x07UPP`\t\x80T\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\0\x16`\x01\x17\x90UPV[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x83\x16`\0\x90\x81R`\x05` \x90\x81R`@\x80\x83 3\x84R\x90\x91R\x81 T\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x14a\x04\xBFWa\x04\x8D\x81\x84a\n\x85V[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x86\x16`\0\x90\x81R`\x05` \x90\x81R`@\x80\x83 3\x84R\x90\x91R\x90 U[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x85\x16`\0\x90\x81R`\x04` R`@\x90 Ta\x04\xEF\x90\x84a\n\x85V[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x87\x16`\0\x90\x81R`\x04` R`@\x80\x82 \x93\x90\x93U\x90\x86\x16\x81R Ta\x05+\x90\x84a\x0B\x02V[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x86\x16`\0\x81\x81R`\x04` R`@\x90\x81\x90 \x93\x90\x93U\x91Q\x90\x87\x16\x90\x7F\xDD\xF2R\xAD\x1B\xE2\xC8\x9Bi\xC2\xB0h\xFC7\x8D\xAA\x95+\xA7\xF1c\xC4\xA1\x16(\xF5ZM\xF5#\xB3\xEF\x90a\x05\x8C\x90\x87\x81R` \x01\x90V[`@Q\x80\x91\x03\x90\xA3P`\x01\x94\x93PPPPV[`\0`\x06Ta\x05\xACa\t\xC9V[\x14a\x05\xBEWa\x05\xB9a\t\xE2V[\x90P\x90V[P`\x07T\x90V[`\x01\x80Ta\x021\x90a\x0E\x92V[3`\0\x90\x81R`\x04` R`@\x81 Ta\x05\xEC\x90\x83a\n\x85V[3`\0\x90\x81R`\x04` R`@\x80\x82 \x92\x90\x92Us\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x85\x16\x81R Ta\x06%\x90\x83a\x0B\x02V[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x84\x16`\0\x81\x81R`\x04` R`@\x90\x81\x90 \x92\x90\x92U\x90Q3\x90\x7F\xDD\xF2R\xAD\x1B\xE2\xC8\x9Bi\xC2\xB0h\xFC7\x8D\xAA\x95+\xA7\xF1c\xC4\xA1\x16(\xF5ZM\xF5#\xB3\xEF\x90a\x03\x1A\x90\x86\x81R` \x01\x90V[B\x84\x10\x15a\x06\xEDW`@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\x82\x01R`\x17`$\x82\x01R\x7FPERMIT_DEADLINE_EXPIRED\0\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01a\x03\x95V[`\0`\x01a\x06\xF9a\x05\x9FV[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x8A\x16`\0\x90\x81R`\x08` R`@\x81 \x80T\x7Fnq\xED\xAE\x12\xB1\xB9\x7FM\x1F`7\x0F\xEF\x10\x10_\xA2\xFA\xAE\x01&\x11J\x16\x9Cd\x84]a&\xC9\x92\x8D\x92\x8D\x92\x8D\x92\x90\x91\x90a\x07T\x83a\x10\x7FV[\x90\x91UP`@\x80Q` \x81\x01\x96\x90\x96Rs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x94\x85\x16\x90\x86\x01R\x92\x90\x91\x16``\x84\x01R`\x80\x83\x01R`\xA0\x82\x01R`\xC0\x81\x01\x88\x90R`\xE0\x01`@Q` \x81\x83\x03\x03\x81R\x90`@R\x80Q\x90` \x01 `@Q` \x01a\x07\xF5\x92\x91\x90\x7F\x19\x01\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\0\0\x81R`\x02\x81\x01\x92\x90\x92R`\"\x82\x01R`B\x01\x90V[`@\x80Q\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xE0\x81\x84\x03\x01\x81R\x82\x82R\x80Q` \x91\x82\x01 `\0\x84R\x90\x83\x01\x80\x83RR`\xFF\x87\x16\x90\x82\x01R``\x81\x01\x85\x90R`\x80\x81\x01\x84\x90R`\xA0\x01` `@Q` \x81\x03\x90\x80\x84\x03\x90\x85Z\xFA\x15\x80\x15a\x08qW=`\0\x80>=`\0\xFD[PP`@Q\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xE0\x01Q\x91PPs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x16\x15\x80\x15\x90a\x08\xECWP\x87s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x81s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x14[a\tRW`@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\x82\x01R`\x0E`$\x82\x01R\x7FINVALID_SIGNER\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01a\x03\x95V[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x81\x16`\0\x90\x81R`\x05` \x90\x81R`@\x80\x83 \x8B\x85\x16\x80\x85R\x90\x83R\x92\x81\x90 \x8A\x90UQ\x89\x81R\x91\x92\x8B\x16\x91\x7F\x8C[\xE1\xE5\xEB\xEC}[\xD1OqB}\x1E\x84\xF3\xDD\x03\x14\xC0\xF7\xB2)\x1E[ \n\xC8\xC7\xC3\xB9%\x91\x01`@Q\x80\x91\x03\x90\xA3PPPPPPPPV[`\0a\x0B{\x80a\t\xDBc\xFF\xFF\xFF\xFF\x82\x16V[\x92PPP\x90V[`\0\x7F\x8Bs\xC3\xC6\x9B\xB8\xFE=Q.\xCCL\xF7Y\xCCy#\x9F{\x17\x9B\x0F\xFA\xCA\xA9\xA7]R+9@\x0F`\0`@Qa\n\x14\x91\x90a\x10\xB7V[`@Q\x80\x91\x03\x90 \x7F\xC8\x9E\xFD\xAAT\xC0\xF2\x0Cz\xDFa(\x82\xDF\tP\xF5\xA9Qc~\x03\x07\xCD\xCBLg/)\x8B\x8B\xC6a\nEa\t\xC9V[`@\x80Q` \x81\x01\x95\x90\x95R\x84\x01\x92\x90\x92R``\x83\x01R`\x80\x82\x01R0`\xA0\x82\x01R`\xC0\x01`@Q` \x81\x83\x03\x03\x81R\x90`@R\x80Q\x90` \x01 \x90P\x90V[`\0\x81\x83\x10\x15a\n\xF1W`@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\x82\x01R`\x1C`$\x82\x01R\x7FERC20: subtraction underflow\0\0\0\0`D\x82\x01R`d\x01a\x03\x95V[a\n\xFB\x82\x84a\x11KV[\x93\x92PPPV[`\0\x80a\x0B\x0F\x83\x85a\x11^V[\x90P\x83\x81\x10\x15a\n\xFBW`@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\x82\x01R`\x18`$\x82\x01R\x7FERC20: addition overflow\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01a\x03\x95V[F\x90V[`\0` \x80\x83R\x83Q\x80` \x85\x01R`\0[\x81\x81\x10\x15a\x0B\xADW\x85\x81\x01\x83\x01Q\x85\x82\x01`@\x01R\x82\x01a\x0B\x91V[P`\0`@\x82\x86\x01\x01R`@\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xE0`\x1F\x83\x01\x16\x85\x01\x01\x92PPP\x92\x91PPV[\x805s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x16\x81\x14a\x0C\x10W`\0\x80\xFD[\x91\x90PV[`\0\x80`@\x83\x85\x03\x12\x15a\x0C(W`\0\x80\xFD[a\x0C1\x83a\x0B\xECV[\x94` \x93\x90\x93\x015\x93PPPV[\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`\0R`A`\x04R`$`\0\xFD[`\0\x82`\x1F\x83\x01\x12a\x0C\x7FW`\0\x80\xFD[\x815g\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x82\x11\x15a\x0C\x9AWa\x0C\x9Aa\x0C?V[`@Q`\x1F\x83\x01\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xE0\x90\x81\x16`?\x01\x16\x81\x01\x90\x82\x82\x11\x81\x83\x10\x17\x15a\x0C\xE0Wa\x0C\xE0a\x0C?V[\x81`@R\x83\x81R\x86` \x85\x88\x01\x01\x11\x15a\x0C\xF9W`\0\x80\xFD[\x83` \x87\x01` \x83\x017`\0` \x85\x83\x01\x01R\x80\x94PPPPP\x92\x91PPV[\x805`\xFF\x81\x16\x81\x14a\x0C\x10W`\0\x80\xFD[`\0\x80`\0``\x84\x86\x03\x12\x15a\r?W`\0\x80\xFD[\x835g\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x82\x11\x15a\rWW`\0\x80\xFD[a\rc\x87\x83\x88\x01a\x0CnV[\x94P` \x86\x015\x91P\x80\x82\x11\x15a\ryW`\0\x80\xFD[Pa\r\x86\x86\x82\x87\x01a\x0CnV[\x92PPa\r\x95`@\x85\x01a\r\x19V[\x90P\x92P\x92P\x92V[`\0\x80`\0``\x84\x86\x03\x12\x15a\r\xB3W`\0\x80\xFD[a\r\xBC\x84a\x0B\xECV[\x92Pa\r\xCA` \x85\x01a\x0B\xECV[\x91P`@\x84\x015\x90P\x92P\x92P\x92V[`\0` \x82\x84\x03\x12\x15a\r\xECW`\0\x80\xFD[a\n\xFB\x82a\x0B\xECV[`\0\x80`\0\x80`\0\x80`\0`\xE0\x88\x8A\x03\x12\x15a\x0E\x10W`\0\x80\xFD[a\x0E\x19\x88a\x0B\xECV[\x96Pa\x0E'` \x89\x01a\x0B\xECV[\x95P`@\x88\x015\x94P``\x88\x015\x93Pa\x0EC`\x80\x89\x01a\r\x19V[\x92P`\xA0\x88\x015\x91P`\xC0\x88\x015\x90P\x92\x95\x98\x91\x94\x97P\x92\x95PV[`\0\x80`@\x83\x85\x03\x12\x15a\x0ErW`\0\x80\xFD[a\x0E{\x83a\x0B\xECV[\x91Pa\x0E\x89` \x84\x01a\x0B\xECV[\x90P\x92P\x92\x90PV[`\x01\x81\x81\x1C\x90\x82\x16\x80a\x0E\xA6W`\x7F\x82\x16\x91P[` \x82\x10\x81\x03a\x0E\xDFW\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`\0R`\"`\x04R`$`\0\xFD[P\x91\x90PV[`\x1F\x82\x11\x15a\x0F1W`\0\x81`\0R` `\0 `\x1F\x85\x01`\x05\x1C\x81\x01` \x86\x10\x15a\x0F\x0EWP\x80[`\x1F\x85\x01`\x05\x1C\x82\x01\x91P[\x81\x81\x10\x15a\x0F-W\x82\x81U`\x01\x01a\x0F\x1AV[PPP[PPPV[\x81Qg\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x11\x15a\x0FPWa\x0FPa\x0C?V[a\x0Fd\x81a\x0F^\x84Ta\x0E\x92V[\x84a\x0E\xE5V[` \x80`\x1F\x83\x11`\x01\x81\x14a\x0F\xB7W`\0\x84\x15a\x0F\x81WP\x85\x83\x01Q[\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF`\x03\x86\x90\x1B\x1C\x19\x16`\x01\x85\x90\x1B\x17\x85Ua\x0F-V[`\0\x85\x81R` \x81 \x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xE0\x86\x16\x91[\x82\x81\x10\x15a\x10\x04W\x88\x86\x01Q\x82U\x94\x84\x01\x94`\x01\x90\x91\x01\x90\x84\x01a\x0F\xE5V[P\x85\x82\x10\x15a\x10@W\x87\x85\x01Q\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF`\x03\x88\x90\x1B`\xF8\x16\x1C\x19\x16\x81U[PPPPP`\x01\x90\x81\x1B\x01\x90UPV[\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`\0R`\x11`\x04R`$`\0\xFD[`\0\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x82\x03a\x10\xB0Wa\x10\xB0a\x10PV[P`\x01\x01\x90V[`\0\x80\x83Ta\x10\xC5\x81a\x0E\x92V[`\x01\x82\x81\x16\x80\x15a\x10\xDDW`\x01\x81\x14a\x11\x10Wa\x11?V[\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\0\x84\x16\x87R\x82\x15\x15\x83\x02\x87\x01\x94Pa\x11?V[\x87`\0R` \x80`\0 `\0[\x85\x81\x10\x15a\x116W\x81T\x8A\x82\x01R\x90\x84\x01\x90\x82\x01a\x11\x1DV[PPP\x82\x87\x01\x94P[P\x92\x96\x95PPPPPPV[\x81\x81\x03\x81\x81\x11\x15a\x03&Wa\x03&a\x10PV[\x80\x82\x01\x80\x82\x11\x15a\x03&Wa\x03&a\x10PV\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static MOCKERC20_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct MockERC20(::ethers::contract::Contract); - impl ::core::clone::Clone for MockERC20 { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for MockERC20 { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for MockERC20 { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for MockERC20 { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(MockERC20)) - .field(&self.address()) - .finish() - } - } - impl MockERC20 { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - MOCKERC20_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - MOCKERC20_ABI.clone(), - MOCKERC20_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - ///Calls the contract's `DOMAIN_SEPARATOR` (0x3644e515) function - pub fn domain_separator(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([54, 68, 229, 21], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `allowance` (0xdd62ed3e) function - pub fn allowance( - &self, - p0: ::ethers::core::types::Address, - p1: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([221, 98, 237, 62], (p0, p1)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `approve` (0x095ea7b3) function - pub fn approve( - &self, - spender: ::ethers::core::types::Address, - amount: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([9, 94, 167, 179], (spender, amount)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `balanceOf` (0x70a08231) function - pub fn balance_of( - &self, - p0: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([112, 160, 130, 49], p0) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `decimals` (0x313ce567) function - pub fn decimals(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([49, 60, 229, 103], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `initialize` (0x1624f6c6) function - pub fn initialize( - &self, - name: ::std::string::String, - symbol: ::std::string::String, - decimals: u8, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([22, 36, 246, 198], (name, symbol, decimals)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `name` (0x06fdde03) function - pub fn name(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([6, 253, 222, 3], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `nonces` (0x7ecebe00) function - pub fn nonces( - &self, - p0: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([126, 206, 190, 0], p0) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `permit` (0xd505accf) function - pub fn permit( - &self, - owner: ::ethers::core::types::Address, - spender: ::ethers::core::types::Address, - value: ::ethers::core::types::U256, - deadline: ::ethers::core::types::U256, - v: u8, - r: [u8; 32], - s: [u8; 32], - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([213, 5, 172, 207], (owner, spender, value, deadline, v, r, s)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `symbol` (0x95d89b41) function - pub fn symbol(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([149, 216, 155, 65], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `totalSupply` (0x18160ddd) function - pub fn total_supply(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([24, 22, 13, 221], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `transfer` (0xa9059cbb) function - pub fn transfer( - &self, - to: ::ethers::core::types::Address, - amount: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([169, 5, 156, 187], (to, amount)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `transferFrom` (0x23b872dd) function - pub fn transfer_from( - &self, - from: ::ethers::core::types::Address, - to: ::ethers::core::types::Address, - amount: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([35, 184, 114, 221], (from, to, amount)) - .expect("method not found (this should never happen)") - } - ///Gets the contract's `Approval` event - pub fn approval_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, ApprovalFilter> { - self.0.event() - } - ///Gets the contract's `Transfer` event - pub fn transfer_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, TransferFilter> { - self.0.event() - } - /// Returns an `Event` builder for all the events of this contract. - pub fn events(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, MockERC20Events> { - self.0.event_with_filter(::core::default::Default::default()) - } - } - impl From<::ethers::contract::Contract> for MockERC20 { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Approval", abi = "Approval(address,address,uint256)")] - pub struct ApprovalFilter { - #[ethevent(indexed)] - pub owner: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub spender: ::ethers::core::types::Address, - pub amount: ::ethers::core::types::U256, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Transfer", abi = "Transfer(address,address,uint256)")] - pub struct TransferFilter { - #[ethevent(indexed)] - pub from: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub to: ::ethers::core::types::Address, - pub amount: ::ethers::core::types::U256, - } - ///Container type for all of the contract's events - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum MockERC20Events { - ApprovalFilter(ApprovalFilter), - TransferFilter(TransferFilter), - } - impl ::ethers::contract::EthLogDecode for MockERC20Events { - fn decode_log(log: &::ethers::core::abi::RawLog) -> ::core::result::Result { - if let Ok(decoded) = ApprovalFilter::decode_log(log) { - return Ok(MockERC20Events::ApprovalFilter(decoded)); - } - if let Ok(decoded) = TransferFilter::decode_log(log) { - return Ok(MockERC20Events::TransferFilter(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData) - } - } - impl ::core::fmt::Display for MockERC20Events { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::ApprovalFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::TransferFilter(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for MockERC20Events { - fn from(value: ApprovalFilter) -> Self { - Self::ApprovalFilter(value) - } - } - impl ::core::convert::From for MockERC20Events { - fn from(value: TransferFilter) -> Self { - Self::TransferFilter(value) - } - } - ///Container type for all input parameters for the `DOMAIN_SEPARATOR` function with signature `DOMAIN_SEPARATOR()` and selector `0x3644e515` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "DOMAIN_SEPARATOR", abi = "DOMAIN_SEPARATOR()")] - pub struct DomainSeparatorCall; - ///Container type for all input parameters for the `allowance` function with signature `allowance(address,address)` and selector `0xdd62ed3e` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "allowance", abi = "allowance(address,address)")] - pub struct AllowanceCall(pub ::ethers::core::types::Address, pub ::ethers::core::types::Address); - ///Container type for all input parameters for the `approve` function with signature `approve(address,uint256)` and selector `0x095ea7b3` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "approve", abi = "approve(address,uint256)")] - pub struct ApproveCall { - pub spender: ::ethers::core::types::Address, - pub amount: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `balanceOf` function with signature `balanceOf(address)` and selector `0x70a08231` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "balanceOf", abi = "balanceOf(address)")] - pub struct BalanceOfCall(pub ::ethers::core::types::Address); - ///Container type for all input parameters for the `decimals` function with signature `decimals()` and selector `0x313ce567` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "decimals", abi = "decimals()")] - pub struct DecimalsCall; - ///Container type for all input parameters for the `initialize` function with signature `initialize(string,string,uint8)` and selector `0x1624f6c6` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "initialize", abi = "initialize(string,string,uint8)")] - pub struct InitializeCall { - pub name: ::std::string::String, - pub symbol: ::std::string::String, - pub decimals: u8, - } - ///Container type for all input parameters for the `name` function with signature `name()` and selector `0x06fdde03` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "name", abi = "name()")] - pub struct NameCall; - ///Container type for all input parameters for the `nonces` function with signature `nonces(address)` and selector `0x7ecebe00` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "nonces", abi = "nonces(address)")] - pub struct NoncesCall(pub ::ethers::core::types::Address); - ///Container type for all input parameters for the `permit` function with signature `permit(address,address,uint256,uint256,uint8,bytes32,bytes32)` and selector `0xd505accf` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall( - name = "permit", - abi = "permit(address,address,uint256,uint256,uint8,bytes32,bytes32)" - )] - pub struct PermitCall { - pub owner: ::ethers::core::types::Address, - pub spender: ::ethers::core::types::Address, - pub value: ::ethers::core::types::U256, - pub deadline: ::ethers::core::types::U256, - pub v: u8, - pub r: [u8; 32], - pub s: [u8; 32], - } - ///Container type for all input parameters for the `symbol` function with signature `symbol()` and selector `0x95d89b41` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "symbol", abi = "symbol()")] - pub struct SymbolCall; - ///Container type for all input parameters for the `totalSupply` function with signature `totalSupply()` and selector `0x18160ddd` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "totalSupply", abi = "totalSupply()")] - pub struct TotalSupplyCall; - ///Container type for all input parameters for the `transfer` function with signature `transfer(address,uint256)` and selector `0xa9059cbb` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "transfer", abi = "transfer(address,uint256)")] - pub struct TransferCall { - pub to: ::ethers::core::types::Address, - pub amount: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `transferFrom` function with signature `transferFrom(address,address,uint256)` and selector `0x23b872dd` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "transferFrom", abi = "transferFrom(address,address,uint256)")] - pub struct TransferFromCall { - pub from: ::ethers::core::types::Address, - pub to: ::ethers::core::types::Address, - pub amount: ::ethers::core::types::U256, - } - ///Container type for all of the contract's call - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum MockERC20Calls { - DomainSeparator(DomainSeparatorCall), - Allowance(AllowanceCall), - Approve(ApproveCall), - BalanceOf(BalanceOfCall), - Decimals(DecimalsCall), - Initialize(InitializeCall), - Name(NameCall), - Nonces(NoncesCall), - Permit(PermitCall), - Symbol(SymbolCall), - TotalSupply(TotalSupplyCall), - Transfer(TransferCall), - TransferFrom(TransferFromCall), - } - impl ::ethers::core::abi::AbiDecode for MockERC20Calls { - fn decode(data: impl AsRef<[u8]>) -> ::core::result::Result { - let data = data.as_ref(); - if let Ok(decoded) = ::decode(data) { - return Ok(Self::DomainSeparator(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Allowance(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Approve(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::BalanceOf(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Decimals(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Initialize(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Name(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Nonces(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Permit(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Symbol(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TotalSupply(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Transfer(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TransferFrom(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData.into()) - } - } - impl ::ethers::core::abi::AbiEncode for MockERC20Calls { - fn encode(self) -> Vec { - match self { - Self::DomainSeparator(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Allowance(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Approve(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::BalanceOf(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Decimals(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Initialize(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Name(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Nonces(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Permit(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Symbol(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TotalSupply(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Transfer(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TransferFrom(element) => ::ethers::core::abi::AbiEncode::encode(element), - } - } - } - impl ::core::fmt::Display for MockERC20Calls { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::DomainSeparator(element) => ::core::fmt::Display::fmt(element, f), - Self::Allowance(element) => ::core::fmt::Display::fmt(element, f), - Self::Approve(element) => ::core::fmt::Display::fmt(element, f), - Self::BalanceOf(element) => ::core::fmt::Display::fmt(element, f), - Self::Decimals(element) => ::core::fmt::Display::fmt(element, f), - Self::Initialize(element) => ::core::fmt::Display::fmt(element, f), - Self::Name(element) => ::core::fmt::Display::fmt(element, f), - Self::Nonces(element) => ::core::fmt::Display::fmt(element, f), - Self::Permit(element) => ::core::fmt::Display::fmt(element, f), - Self::Symbol(element) => ::core::fmt::Display::fmt(element, f), - Self::TotalSupply(element) => ::core::fmt::Display::fmt(element, f), - Self::Transfer(element) => ::core::fmt::Display::fmt(element, f), - Self::TransferFrom(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for MockERC20Calls { - fn from(value: DomainSeparatorCall) -> Self { - Self::DomainSeparator(value) - } - } - impl ::core::convert::From for MockERC20Calls { - fn from(value: AllowanceCall) -> Self { - Self::Allowance(value) - } - } - impl ::core::convert::From for MockERC20Calls { - fn from(value: ApproveCall) -> Self { - Self::Approve(value) - } - } - impl ::core::convert::From for MockERC20Calls { - fn from(value: BalanceOfCall) -> Self { - Self::BalanceOf(value) - } - } - impl ::core::convert::From for MockERC20Calls { - fn from(value: DecimalsCall) -> Self { - Self::Decimals(value) - } - } - impl ::core::convert::From for MockERC20Calls { - fn from(value: InitializeCall) -> Self { - Self::Initialize(value) - } - } - impl ::core::convert::From for MockERC20Calls { - fn from(value: NameCall) -> Self { - Self::Name(value) - } - } - impl ::core::convert::From for MockERC20Calls { - fn from(value: NoncesCall) -> Self { - Self::Nonces(value) - } - } - impl ::core::convert::From for MockERC20Calls { - fn from(value: PermitCall) -> Self { - Self::Permit(value) - } - } - impl ::core::convert::From for MockERC20Calls { - fn from(value: SymbolCall) -> Self { - Self::Symbol(value) - } - } - impl ::core::convert::From for MockERC20Calls { - fn from(value: TotalSupplyCall) -> Self { - Self::TotalSupply(value) - } - } - impl ::core::convert::From for MockERC20Calls { - fn from(value: TransferCall) -> Self { - Self::Transfer(value) - } - } - impl ::core::convert::From for MockERC20Calls { - fn from(value: TransferFromCall) -> Self { - Self::TransferFrom(value) - } - } - ///Container type for all return fields from the `DOMAIN_SEPARATOR` function with signature `DOMAIN_SEPARATOR()` and selector `0x3644e515` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct DomainSeparatorReturn(pub [u8; 32]); - ///Container type for all return fields from the `allowance` function with signature `allowance(address,address)` and selector `0xdd62ed3e` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct AllowanceReturn(pub ::ethers::core::types::U256); - ///Container type for all return fields from the `approve` function with signature `approve(address,uint256)` and selector `0x095ea7b3` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct ApproveReturn(pub bool); - ///Container type for all return fields from the `balanceOf` function with signature `balanceOf(address)` and selector `0x70a08231` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct BalanceOfReturn(pub ::ethers::core::types::U256); - ///Container type for all return fields from the `decimals` function with signature `decimals()` and selector `0x313ce567` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct DecimalsReturn(pub u8); - ///Container type for all return fields from the `name` function with signature `name()` and selector `0x06fdde03` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct NameReturn(pub ::std::string::String); - ///Container type for all return fields from the `nonces` function with signature `nonces(address)` and selector `0x7ecebe00` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct NoncesReturn(pub ::ethers::core::types::U256); - ///Container type for all return fields from the `symbol` function with signature `symbol()` and selector `0x95d89b41` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct SymbolReturn(pub ::std::string::String); - ///Container type for all return fields from the `totalSupply` function with signature `totalSupply()` and selector `0x18160ddd` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct TotalSupplyReturn(pub ::ethers::core::types::U256); - ///Container type for all return fields from the `transfer` function with signature `transfer(address,uint256)` and selector `0xa9059cbb` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct TransferReturn(pub bool); - ///Container type for all return fields from the `transferFrom` function with signature `transferFrom(address,address,uint256)` and selector `0x23b872dd` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct TransferFromReturn(pub bool); -} diff --git a/src/bindings/mock_erc721.rs b/src/bindings/mock_erc721.rs deleted file mode 100644 index 757da05..0000000 --- a/src/bindings/mock_erc721.rs +++ /dev/null @@ -1,1297 +0,0 @@ -pub use mock_erc721::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod mock_erc721 { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("approve"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("approve"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("spender"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("id"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("balanceOf"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("balanceOf"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("getApproved"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("getApproved"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("initialize"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("initialize"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("_name"), - kind: ::ethers::core::abi::ethabi::ParamType::String, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("string"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("_symbol"), - kind: ::ethers::core::abi::ethabi::ParamType::String, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("string"),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("isApprovedForAll"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("isApprovedForAll"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("name"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("name"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::String, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("string"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("ownerOf"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("ownerOf"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("id"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("safeTransferFrom"), - ::std::vec![ - ::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("safeTransferFrom"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("id"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - }, - ::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("safeTransferFrom"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("id"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("data"), - kind: ::ethers::core::abi::ethabi::ParamType::Bytes, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "bytes" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - }, - ], - ), - ( - ::std::borrow::ToOwned::to_owned("setApprovalForAll"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("setApprovalForAll"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("operator"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("approved"), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("supportsInterface"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("supportsInterface"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("interfaceId"), - kind: ::ethers::core::abi::ethabi::ParamType::FixedBytes(4usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes4"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bool"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::Pure, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("symbol"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("symbol"), - inputs: ::std::vec![], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::String, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("string"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("tokenURI"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("tokenURI"), - inputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("id"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("uint256"),), - },], - outputs: ::std::vec![::ethers::core::abi::ethabi::Param { - name: ::std::string::String::new(), - kind: ::ethers::core::abi::ethabi::ParamType::String, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("string"),), - },], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("transferFrom"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("transferFrom"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("id"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - outputs: ::std::vec![], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::NonPayable, - },], - ), - ]), - events: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("Approval"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Approval"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("spender"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("id"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: true, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("ApprovalForAll"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("ApprovalForAll"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("operator"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("approved"), - kind: ::ethers::core::abi::ethabi::ParamType::Bool, - indexed: false, - }, - ], - anonymous: false, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("Transfer"), - ::std::vec![::ethers::core::abi::ethabi::Event { - name: ::std::borrow::ToOwned::to_owned("Transfer"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("from"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("to"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - indexed: true, - }, - ::ethers::core::abi::ethabi::EventParam { - name: ::std::borrow::ToOwned::to_owned("id"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - indexed: true, - }, - ], - anonymous: false, - },], - ), - ]), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static MOCKERC721_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`\x80`@R4\x80\x15a\0\x10W`\0\x80\xFD[Pa\x13\xE0\x80a\0 `\09`\0\xF3\xFE`\x80`@R4\x80\x15a\0\x10W`\0\x80\xFD[P`\x046\x10a\0\xEAW`\x005`\xE0\x1C\x80ccR!\x1E\x11a\0\x8CW\x80c\xA2,\xB4e\x11a\0fW\x80c\xA2,\xB4e\x14a\x02\x11W\x80c\xB8\x8DO\xDE\x14a\x02$W\x80c\xC8{V\xDD\x14a\x027W\x80c\xE9\x85\xE9\xC5\x14a\x02KW`\0\x80\xFD[\x80ccR!\x1E\x14a\x01\xD5W\x80cp\xA0\x821\x14a\x01\xE8W\x80c\x95\xD8\x9BA\x14a\x02\tW`\0\x80\xFD[\x80c\t^\xA7\xB3\x11a\0\xC8W\x80c\t^\xA7\xB3\x14a\x01\x87W\x80c#\xB8r\xDD\x14a\x01\x9CW\x80cB\x84.\x0E\x14a\x01\xAFW\x80cL\xD8\x8Bv\x14a\x01\xC2W`\0\x80\xFD[\x80c\x01\xFF\xC9\xA7\x14a\0\xEFW\x80c\x06\xFD\xDE\x03\x14a\x01\x17W\x80c\x08\x18\x12\xFC\x14a\x01,W[`\0\x80\xFD[a\x01\x02a\0\xFD6`\x04a\r\x89V[a\x02yV[`@Q\x90\x15\x15\x81R` \x01[`@Q\x80\x91\x03\x90\xF3[a\x01\x1Fa\x03^V[`@Qa\x01\x0E\x91\x90a\x0E\x11V[a\x01ba\x01:6`\x04a\x0E$V[`\x04` R`\0\x90\x81R`@\x90 Ts\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x81V[`@Qs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x90\x91\x16\x81R` \x01a\x01\x0EV[a\x01\x9Aa\x01\x956`\x04a\x0EaV[a\x03\xECV[\0[a\x01\x9Aa\x01\xAA6`\x04a\x0E\x8BV[a\x05;V[a\x01\x9Aa\x01\xBD6`\x04a\x0E\x8BV[a\x080V[a\x01\x9Aa\x01\xD06`\x04a\x0F\xAAV[a\t\x84V[a\x01ba\x01\xE36`\x04a\x0E$V[a\n:V[a\x01\xFBa\x01\xF66`\x04a\x10\x0EV[a\n\xCBV[`@Q\x90\x81R` \x01a\x01\x0EV[a\x01\x1Fa\x0BsV[a\x01\x9Aa\x02\x1F6`\x04a\x10)V[a\x0B\x80V[a\x01\x9Aa\x0226`\x04a\x10eV[a\x0C\x17V[a\x01\x1Fa\x02E6`\x04a\x0E$V[P``\x90V[a\x01\x02a\x02Y6`\x04a\x10\xE1V[`\x05` \x90\x81R`\0\x92\x83R`@\x80\x84 \x90\x91R\x90\x82R\x90 T`\xFF\x16\x81V[`\0\x7F\x01\xFF\xC9\xA7\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\x7F\xFF\xFF\xFF\xFF\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\x83\x16\x14\x80a\x03\x0CWP\x7F\x80\xACX\xCD\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\x7F\xFF\xFF\xFF\xFF\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\x83\x16\x14[\x80a\x03XWP\x7F[^\x13\x9F\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\x7F\xFF\xFF\xFF\xFF\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\x83\x16\x14[\x92\x91PPV[`\0\x80Ta\x03k\x90a\x11\x14V[\x80`\x1F\x01` \x80\x91\x04\x02` \x01`@Q\x90\x81\x01`@R\x80\x92\x91\x90\x81\x81R` \x01\x82\x80Ta\x03\x97\x90a\x11\x14V[\x80\x15a\x03\xE4W\x80`\x1F\x10a\x03\xB9Wa\x01\0\x80\x83T\x04\x02\x83R\x91` \x01\x91a\x03\xE4V[\x82\x01\x91\x90`\0R` `\0 \x90[\x81T\x81R\x90`\x01\x01\x90` \x01\x80\x83\x11a\x03\xC7W\x82\x90\x03`\x1F\x16\x82\x01\x91[PPPPP\x81V[`\0\x81\x81R`\x02` R`@\x90 Ts\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x163\x81\x14\x80a\x04OWPs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x16`\0\x90\x81R`\x05` \x90\x81R`@\x80\x83 3\x84R\x90\x91R\x90 T`\xFF\x16[a\x04\xBAW`@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\x82\x01R`\x0E`$\x82\x01R\x7FNOT_AUTHORIZED\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01[`@Q\x80\x91\x03\x90\xFD[`\0\x82\x81R`\x04` R`@\x80\x82 \x80T\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x16s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x87\x81\x16\x91\x82\x17\x90\x92U\x91Q\x85\x93\x91\x85\x16\x91\x7F\x8C[\xE1\xE5\xEB\xEC}[\xD1OqB}\x1E\x84\xF3\xDD\x03\x14\xC0\xF7\xB2)\x1E[ \n\xC8\xC7\xC3\xB9%\x91\xA4PPPV[`\0\x81\x81R`\x02` R`@\x90 Ts\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x84\x81\x16\x91\x16\x14a\x05\xCBW`@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\x82\x01R`\n`$\x82\x01R\x7FWRONG_FROM\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01a\x04\xB1V[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x82\x16a\x06HW`@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\x82\x01R`\x11`$\x82\x01R\x7FINVALID_RECIPIENT\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01a\x04\xB1V[3s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x84\x16\x14\x80a\x06\x9CWPs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x83\x16`\0\x90\x81R`\x05` \x90\x81R`@\x80\x83 3\x84R\x90\x91R\x90 T`\xFF\x16[\x80a\x06\xCAWP`\0\x81\x81R`\x04` R`@\x90 Ts\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x163\x14[a\x070W`@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\x82\x01R`\x0E`$\x82\x01R\x7FNOT_AUTHORIZED\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01a\x04\xB1V[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x83\x16`\0\x90\x81R`\x03` R`@\x81 \x80T\x91a\x07a\x83a\x11\x96V[\x90\x91UPPs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x82\x16`\0\x90\x81R`\x03` R`@\x81 \x80T\x91a\x07\x97\x83a\x11\xCBV[\x90\x91UPP`\0\x81\x81R`\x02` \x90\x81R`@\x80\x83 \x80Ts\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x88\x16\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x92\x83\x16\x81\x17\x90\x93U`\x04\x90\x94R\x82\x85 \x80T\x90\x91\x16\x90U\x90Q\x84\x93\x91\x92\x87\x16\x91\x7F\xDD\xF2R\xAD\x1B\xE2\xC8\x9Bi\xC2\xB0h\xFC7\x8D\xAA\x95+\xA7\xF1c\xC4\xA1\x16(\xF5ZM\xF5#\xB3\xEF\x91\xA4PPPV[a\x08;\x83\x83\x83a\x05;V[\x81;\x15\x80a\t\x19WP`@Q\x7F\x15\x0Bz\x02\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\x80\x82R3`\x04\x83\x01Rs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x85\x81\x16`$\x84\x01R`D\x83\x01\x84\x90R`\x80`d\x84\x01R`\0`\x84\x84\x01R\x90\x91\x90\x84\x16\x90c\x15\x0Bz\x02\x90`\xA4\x01` `@Q\x80\x83\x03\x81`\0\x87Z\xF1\x15\x80\x15a\x08\xD1W=`\0\x80>=`\0\xFD[PPPP`@Q=`\x1F\x19`\x1F\x82\x01\x16\x82\x01\x80`@RP\x81\x01\x90a\x08\xF5\x91\x90a\x12\x03V[\x7F\xFF\xFF\xFF\xFF\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\x16\x14[a\t\x7FW`@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\x82\x01R`\x10`$\x82\x01R\x7FUNSAFE_RECIPIENT\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01a\x04\xB1V[PPPV[`\x06T`\xFF\x16\x15a\t\xF1W`@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\x82\x01R`\x13`$\x82\x01R\x7FALREADY_INITIALIZED\0\0\0\0\0\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01a\x04\xB1V[`\0a\t\xFD\x83\x82a\x12pV[P`\x01a\n\n\x82\x82a\x12pV[PP`\x06\x80T\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\0\x16`\x01\x17\x90UPV[`\0\x81\x81R`\x02` R`@\x90 Ts\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x80a\n\xC6W`@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\x82\x01R`\n`$\x82\x01R\x7FNOT_MINTED\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01a\x04\xB1V[\x91\x90PV[`\0s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x82\x16a\x0BJW`@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\x82\x01R`\x0C`$\x82\x01R\x7FZERO_ADDRESS\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01a\x04\xB1V[Ps\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16`\0\x90\x81R`\x03` R`@\x90 T\x90V[`\x01\x80Ta\x03k\x90a\x11\x14V[3`\0\x81\x81R`\x05` \x90\x81R`@\x80\x83 s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x87\x16\x80\x85R\x90\x83R\x92\x81\x90 \x80T\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\0\x16\x86\x15\x15\x90\x81\x17\x90\x91U\x90Q\x90\x81R\x91\x92\x91\x7F\x170~\xAB9\xABa\x07\xE8\x89\x98E\xAD=Y\xBD\x96S\xF2\0\xF2 \x92\x04\x89\xCA+Y7il1\x91\x01`@Q\x80\x91\x03\x90\xA3PPV[a\x0C\"\x84\x84\x84a\x05;V[\x82;\x15\x80a\x0C\xECWP`@Q\x7F\x15\x0Bz\x02\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\x80\x82R\x90s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x85\x16\x90c\x15\x0Bz\x02\x90a\x0C\x85\x903\x90\x89\x90\x88\x90\x88\x90`\x04\x01a\x13\x8AV[` `@Q\x80\x83\x03\x81`\0\x87Z\xF1\x15\x80\x15a\x0C\xA4W=`\0\x80>=`\0\xFD[PPPP`@Q=`\x1F\x19`\x1F\x82\x01\x16\x82\x01\x80`@RP\x81\x01\x90a\x0C\xC8\x91\x90a\x12\x03V[\x7F\xFF\xFF\xFF\xFF\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\x16\x14[a\rRW`@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\x82\x01R`\x10`$\x82\x01R\x7FUNSAFE_RECIPIENT\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01a\x04\xB1V[PPPPV[\x7F\xFF\xFF\xFF\xFF\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\x81\x16\x81\x14a\r\x86W`\0\x80\xFD[PV[`\0` \x82\x84\x03\x12\x15a\r\x9BW`\0\x80\xFD[\x815a\r\xA6\x81a\rXV[\x93\x92PPPV[`\0\x81Q\x80\x84R`\0[\x81\x81\x10\x15a\r\xD3W` \x81\x85\x01\x81\x01Q\x86\x83\x01\x82\x01R\x01a\r\xB7V[P`\0` \x82\x86\x01\x01R` \x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xE0`\x1F\x83\x01\x16\x85\x01\x01\x91PP\x92\x91PPV[` \x81R`\0a\r\xA6` \x83\x01\x84a\r\xADV[`\0` \x82\x84\x03\x12\x15a\x0E6W`\0\x80\xFD[P5\x91\x90PV[\x805s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x16\x81\x14a\n\xC6W`\0\x80\xFD[`\0\x80`@\x83\x85\x03\x12\x15a\x0EtW`\0\x80\xFD[a\x0E}\x83a\x0E=V[\x94` \x93\x90\x93\x015\x93PPPV[`\0\x80`\0``\x84\x86\x03\x12\x15a\x0E\xA0W`\0\x80\xFD[a\x0E\xA9\x84a\x0E=V[\x92Pa\x0E\xB7` \x85\x01a\x0E=V[\x91P`@\x84\x015\x90P\x92P\x92P\x92V[\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`\0R`A`\x04R`$`\0\xFD[`\0g\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x84\x11\x15a\x0F\x11Wa\x0F\x11a\x0E\xC7V[`@Q`\x1F\x85\x01\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xE0\x90\x81\x16`?\x01\x16\x81\x01\x90\x82\x82\x11\x81\x83\x10\x17\x15a\x0FWWa\x0FWa\x0E\xC7V[\x81`@R\x80\x93P\x85\x81R\x86\x86\x86\x01\x11\x15a\x0FpW`\0\x80\xFD[\x85\x85` \x83\x017`\0` \x87\x83\x01\x01RPPP\x93\x92PPPV[`\0\x82`\x1F\x83\x01\x12a\x0F\x9BW`\0\x80\xFD[a\r\xA6\x83\x835` \x85\x01a\x0E\xF6V[`\0\x80`@\x83\x85\x03\x12\x15a\x0F\xBDW`\0\x80\xFD[\x825g\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x82\x11\x15a\x0F\xD5W`\0\x80\xFD[a\x0F\xE1\x86\x83\x87\x01a\x0F\x8AV[\x93P` \x85\x015\x91P\x80\x82\x11\x15a\x0F\xF7W`\0\x80\xFD[Pa\x10\x04\x85\x82\x86\x01a\x0F\x8AV[\x91PP\x92P\x92\x90PV[`\0` \x82\x84\x03\x12\x15a\x10 W`\0\x80\xFD[a\r\xA6\x82a\x0E=V[`\0\x80`@\x83\x85\x03\x12\x15a\x10W\x88\x86\x01Q\x82U\x94\x84\x01\x94`\x01\x90\x91\x01\x90\x84\x01a\x13\x1FV[P\x85\x82\x10\x15a\x13zW\x87\x85\x01Q\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF`\x03\x88\x90\x1B`\xF8\x16\x1C\x19\x16\x81U[PPPPP`\x01\x90\x81\x1B\x01\x90UPV[`\0s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x87\x16\x83R\x80\x86\x16` \x84\x01RP\x83`@\x83\x01R`\x80``\x83\x01Ra\x13\xC9`\x80\x83\x01\x84a\r\xADV[\x96\x95PPPPPPV\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The bytecode of the contract. - pub static MOCKERC721_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"`\x80`@R4\x80\x15a\0\x10W`\0\x80\xFD[P`\x046\x10a\0\xEAW`\x005`\xE0\x1C\x80ccR!\x1E\x11a\0\x8CW\x80c\xA2,\xB4e\x11a\0fW\x80c\xA2,\xB4e\x14a\x02\x11W\x80c\xB8\x8DO\xDE\x14a\x02$W\x80c\xC8{V\xDD\x14a\x027W\x80c\xE9\x85\xE9\xC5\x14a\x02KW`\0\x80\xFD[\x80ccR!\x1E\x14a\x01\xD5W\x80cp\xA0\x821\x14a\x01\xE8W\x80c\x95\xD8\x9BA\x14a\x02\tW`\0\x80\xFD[\x80c\t^\xA7\xB3\x11a\0\xC8W\x80c\t^\xA7\xB3\x14a\x01\x87W\x80c#\xB8r\xDD\x14a\x01\x9CW\x80cB\x84.\x0E\x14a\x01\xAFW\x80cL\xD8\x8Bv\x14a\x01\xC2W`\0\x80\xFD[\x80c\x01\xFF\xC9\xA7\x14a\0\xEFW\x80c\x06\xFD\xDE\x03\x14a\x01\x17W\x80c\x08\x18\x12\xFC\x14a\x01,W[`\0\x80\xFD[a\x01\x02a\0\xFD6`\x04a\r\x89V[a\x02yV[`@Q\x90\x15\x15\x81R` \x01[`@Q\x80\x91\x03\x90\xF3[a\x01\x1Fa\x03^V[`@Qa\x01\x0E\x91\x90a\x0E\x11V[a\x01ba\x01:6`\x04a\x0E$V[`\x04` R`\0\x90\x81R`@\x90 Ts\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x81V[`@Qs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x90\x91\x16\x81R` \x01a\x01\x0EV[a\x01\x9Aa\x01\x956`\x04a\x0EaV[a\x03\xECV[\0[a\x01\x9Aa\x01\xAA6`\x04a\x0E\x8BV[a\x05;V[a\x01\x9Aa\x01\xBD6`\x04a\x0E\x8BV[a\x080V[a\x01\x9Aa\x01\xD06`\x04a\x0F\xAAV[a\t\x84V[a\x01ba\x01\xE36`\x04a\x0E$V[a\n:V[a\x01\xFBa\x01\xF66`\x04a\x10\x0EV[a\n\xCBV[`@Q\x90\x81R` \x01a\x01\x0EV[a\x01\x1Fa\x0BsV[a\x01\x9Aa\x02\x1F6`\x04a\x10)V[a\x0B\x80V[a\x01\x9Aa\x0226`\x04a\x10eV[a\x0C\x17V[a\x01\x1Fa\x02E6`\x04a\x0E$V[P``\x90V[a\x01\x02a\x02Y6`\x04a\x10\xE1V[`\x05` \x90\x81R`\0\x92\x83R`@\x80\x84 \x90\x91R\x90\x82R\x90 T`\xFF\x16\x81V[`\0\x7F\x01\xFF\xC9\xA7\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\x7F\xFF\xFF\xFF\xFF\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\x83\x16\x14\x80a\x03\x0CWP\x7F\x80\xACX\xCD\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\x7F\xFF\xFF\xFF\xFF\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\x83\x16\x14[\x80a\x03XWP\x7F[^\x13\x9F\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\x7F\xFF\xFF\xFF\xFF\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\x83\x16\x14[\x92\x91PPV[`\0\x80Ta\x03k\x90a\x11\x14V[\x80`\x1F\x01` \x80\x91\x04\x02` \x01`@Q\x90\x81\x01`@R\x80\x92\x91\x90\x81\x81R` \x01\x82\x80Ta\x03\x97\x90a\x11\x14V[\x80\x15a\x03\xE4W\x80`\x1F\x10a\x03\xB9Wa\x01\0\x80\x83T\x04\x02\x83R\x91` \x01\x91a\x03\xE4V[\x82\x01\x91\x90`\0R` `\0 \x90[\x81T\x81R\x90`\x01\x01\x90` \x01\x80\x83\x11a\x03\xC7W\x82\x90\x03`\x1F\x16\x82\x01\x91[PPPPP\x81V[`\0\x81\x81R`\x02` R`@\x90 Ts\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x163\x81\x14\x80a\x04OWPs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x16`\0\x90\x81R`\x05` \x90\x81R`@\x80\x83 3\x84R\x90\x91R\x90 T`\xFF\x16[a\x04\xBAW`@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\x82\x01R`\x0E`$\x82\x01R\x7FNOT_AUTHORIZED\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01[`@Q\x80\x91\x03\x90\xFD[`\0\x82\x81R`\x04` R`@\x80\x82 \x80T\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x16s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x87\x81\x16\x91\x82\x17\x90\x92U\x91Q\x85\x93\x91\x85\x16\x91\x7F\x8C[\xE1\xE5\xEB\xEC}[\xD1OqB}\x1E\x84\xF3\xDD\x03\x14\xC0\xF7\xB2)\x1E[ \n\xC8\xC7\xC3\xB9%\x91\xA4PPPV[`\0\x81\x81R`\x02` R`@\x90 Ts\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x84\x81\x16\x91\x16\x14a\x05\xCBW`@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\x82\x01R`\n`$\x82\x01R\x7FWRONG_FROM\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01a\x04\xB1V[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x82\x16a\x06HW`@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\x82\x01R`\x11`$\x82\x01R\x7FINVALID_RECIPIENT\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01a\x04\xB1V[3s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x84\x16\x14\x80a\x06\x9CWPs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x83\x16`\0\x90\x81R`\x05` \x90\x81R`@\x80\x83 3\x84R\x90\x91R\x90 T`\xFF\x16[\x80a\x06\xCAWP`\0\x81\x81R`\x04` R`@\x90 Ts\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x163\x14[a\x070W`@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\x82\x01R`\x0E`$\x82\x01R\x7FNOT_AUTHORIZED\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01a\x04\xB1V[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x83\x16`\0\x90\x81R`\x03` R`@\x81 \x80T\x91a\x07a\x83a\x11\x96V[\x90\x91UPPs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x82\x16`\0\x90\x81R`\x03` R`@\x81 \x80T\x91a\x07\x97\x83a\x11\xCBV[\x90\x91UPP`\0\x81\x81R`\x02` \x90\x81R`@\x80\x83 \x80Ts\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x88\x16\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x92\x83\x16\x81\x17\x90\x93U`\x04\x90\x94R\x82\x85 \x80T\x90\x91\x16\x90U\x90Q\x84\x93\x91\x92\x87\x16\x91\x7F\xDD\xF2R\xAD\x1B\xE2\xC8\x9Bi\xC2\xB0h\xFC7\x8D\xAA\x95+\xA7\xF1c\xC4\xA1\x16(\xF5ZM\xF5#\xB3\xEF\x91\xA4PPPV[a\x08;\x83\x83\x83a\x05;V[\x81;\x15\x80a\t\x19WP`@Q\x7F\x15\x0Bz\x02\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\x80\x82R3`\x04\x83\x01Rs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x85\x81\x16`$\x84\x01R`D\x83\x01\x84\x90R`\x80`d\x84\x01R`\0`\x84\x84\x01R\x90\x91\x90\x84\x16\x90c\x15\x0Bz\x02\x90`\xA4\x01` `@Q\x80\x83\x03\x81`\0\x87Z\xF1\x15\x80\x15a\x08\xD1W=`\0\x80>=`\0\xFD[PPPP`@Q=`\x1F\x19`\x1F\x82\x01\x16\x82\x01\x80`@RP\x81\x01\x90a\x08\xF5\x91\x90a\x12\x03V[\x7F\xFF\xFF\xFF\xFF\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\x16\x14[a\t\x7FW`@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\x82\x01R`\x10`$\x82\x01R\x7FUNSAFE_RECIPIENT\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01a\x04\xB1V[PPPV[`\x06T`\xFF\x16\x15a\t\xF1W`@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\x82\x01R`\x13`$\x82\x01R\x7FALREADY_INITIALIZED\0\0\0\0\0\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01a\x04\xB1V[`\0a\t\xFD\x83\x82a\x12pV[P`\x01a\n\n\x82\x82a\x12pV[PP`\x06\x80T\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\0\x16`\x01\x17\x90UPV[`\0\x81\x81R`\x02` R`@\x90 Ts\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x80a\n\xC6W`@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\x82\x01R`\n`$\x82\x01R\x7FNOT_MINTED\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01a\x04\xB1V[\x91\x90PV[`\0s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x82\x16a\x0BJW`@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\x82\x01R`\x0C`$\x82\x01R\x7FZERO_ADDRESS\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01a\x04\xB1V[Ps\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16`\0\x90\x81R`\x03` R`@\x90 T\x90V[`\x01\x80Ta\x03k\x90a\x11\x14V[3`\0\x81\x81R`\x05` \x90\x81R`@\x80\x83 s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x87\x16\x80\x85R\x90\x83R\x92\x81\x90 \x80T\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\0\x16\x86\x15\x15\x90\x81\x17\x90\x91U\x90Q\x90\x81R\x91\x92\x91\x7F\x170~\xAB9\xABa\x07\xE8\x89\x98E\xAD=Y\xBD\x96S\xF2\0\xF2 \x92\x04\x89\xCA+Y7il1\x91\x01`@Q\x80\x91\x03\x90\xA3PPV[a\x0C\"\x84\x84\x84a\x05;V[\x82;\x15\x80a\x0C\xECWP`@Q\x7F\x15\x0Bz\x02\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\x80\x82R\x90s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x85\x16\x90c\x15\x0Bz\x02\x90a\x0C\x85\x903\x90\x89\x90\x88\x90\x88\x90`\x04\x01a\x13\x8AV[` `@Q\x80\x83\x03\x81`\0\x87Z\xF1\x15\x80\x15a\x0C\xA4W=`\0\x80>=`\0\xFD[PPPP`@Q=`\x1F\x19`\x1F\x82\x01\x16\x82\x01\x80`@RP\x81\x01\x90a\x0C\xC8\x91\x90a\x12\x03V[\x7F\xFF\xFF\xFF\xFF\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\x16\x14[a\rRW`@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\x82\x01R`\x10`$\x82\x01R\x7FUNSAFE_RECIPIENT\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0`D\x82\x01R`d\x01a\x04\xB1V[PPPPV[\x7F\xFF\xFF\xFF\xFF\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\x81\x16\x81\x14a\r\x86W`\0\x80\xFD[PV[`\0` \x82\x84\x03\x12\x15a\r\x9BW`\0\x80\xFD[\x815a\r\xA6\x81a\rXV[\x93\x92PPPV[`\0\x81Q\x80\x84R`\0[\x81\x81\x10\x15a\r\xD3W` \x81\x85\x01\x81\x01Q\x86\x83\x01\x82\x01R\x01a\r\xB7V[P`\0` \x82\x86\x01\x01R` \x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xE0`\x1F\x83\x01\x16\x85\x01\x01\x91PP\x92\x91PPV[` \x81R`\0a\r\xA6` \x83\x01\x84a\r\xADV[`\0` \x82\x84\x03\x12\x15a\x0E6W`\0\x80\xFD[P5\x91\x90PV[\x805s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x16\x81\x14a\n\xC6W`\0\x80\xFD[`\0\x80`@\x83\x85\x03\x12\x15a\x0EtW`\0\x80\xFD[a\x0E}\x83a\x0E=V[\x94` \x93\x90\x93\x015\x93PPPV[`\0\x80`\0``\x84\x86\x03\x12\x15a\x0E\xA0W`\0\x80\xFD[a\x0E\xA9\x84a\x0E=V[\x92Pa\x0E\xB7` \x85\x01a\x0E=V[\x91P`@\x84\x015\x90P\x92P\x92P\x92V[\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`\0R`A`\x04R`$`\0\xFD[`\0g\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x84\x11\x15a\x0F\x11Wa\x0F\x11a\x0E\xC7V[`@Q`\x1F\x85\x01\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xE0\x90\x81\x16`?\x01\x16\x81\x01\x90\x82\x82\x11\x81\x83\x10\x17\x15a\x0FWWa\x0FWa\x0E\xC7V[\x81`@R\x80\x93P\x85\x81R\x86\x86\x86\x01\x11\x15a\x0FpW`\0\x80\xFD[\x85\x85` \x83\x017`\0` \x87\x83\x01\x01RPPP\x93\x92PPPV[`\0\x82`\x1F\x83\x01\x12a\x0F\x9BW`\0\x80\xFD[a\r\xA6\x83\x835` \x85\x01a\x0E\xF6V[`\0\x80`@\x83\x85\x03\x12\x15a\x0F\xBDW`\0\x80\xFD[\x825g\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x82\x11\x15a\x0F\xD5W`\0\x80\xFD[a\x0F\xE1\x86\x83\x87\x01a\x0F\x8AV[\x93P` \x85\x015\x91P\x80\x82\x11\x15a\x0F\xF7W`\0\x80\xFD[Pa\x10\x04\x85\x82\x86\x01a\x0F\x8AV[\x91PP\x92P\x92\x90PV[`\0` \x82\x84\x03\x12\x15a\x10 W`\0\x80\xFD[a\r\xA6\x82a\x0E=V[`\0\x80`@\x83\x85\x03\x12\x15a\x10W\x88\x86\x01Q\x82U\x94\x84\x01\x94`\x01\x90\x91\x01\x90\x84\x01a\x13\x1FV[P\x85\x82\x10\x15a\x13zW\x87\x85\x01Q\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF`\x03\x88\x90\x1B`\xF8\x16\x1C\x19\x16\x81U[PPPPP`\x01\x90\x81\x1B\x01\x90UPV[`\0s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x87\x16\x83R\x80\x86\x16` \x84\x01RP\x83`@\x83\x01R`\x80``\x83\x01Ra\x13\xC9`\x80\x83\x01\x84a\r\xADV[\x96\x95PPPPPPV\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static MOCKERC721_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct MockERC721(::ethers::contract::Contract); - impl ::core::clone::Clone for MockERC721 { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for MockERC721 { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for MockERC721 { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for MockERC721 { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(MockERC721)) - .field(&self.address()) - .finish() - } - } - impl MockERC721 { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - MOCKERC721_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - MOCKERC721_ABI.clone(), - MOCKERC721_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - ///Calls the contract's `approve` (0x095ea7b3) function - pub fn approve( - &self, - spender: ::ethers::core::types::Address, - id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([9, 94, 167, 179], (spender, id)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `balanceOf` (0x70a08231) function - pub fn balance_of( - &self, - owner: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([112, 160, 130, 49], owner) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `getApproved` (0x081812fc) function - pub fn get_approved( - &self, - p0: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([8, 24, 18, 252], p0) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `initialize` (0x4cd88b76) function - pub fn initialize( - &self, - name: ::std::string::String, - symbol: ::std::string::String, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([76, 216, 139, 118], (name, symbol)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `isApprovedForAll` (0xe985e9c5) function - pub fn is_approved_for_all( - &self, - p0: ::ethers::core::types::Address, - p1: ::ethers::core::types::Address, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([233, 133, 233, 197], (p0, p1)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `name` (0x06fdde03) function - pub fn name(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([6, 253, 222, 3], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `ownerOf` (0x6352211e) function - pub fn owner_of( - &self, - id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([99, 82, 33, 30], id) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `safeTransferFrom` (0x42842e0e) function - pub fn safe_transfer_from( - &self, - from: ::ethers::core::types::Address, - to: ::ethers::core::types::Address, - id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([66, 132, 46, 14], (from, to, id)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `safeTransferFrom` (0xb88d4fde) function - pub fn safe_transfer_from_with_from_and_to_and_data( - &self, - from: ::ethers::core::types::Address, - to: ::ethers::core::types::Address, - id: ::ethers::core::types::U256, - data: ::ethers::core::types::Bytes, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([184, 141, 79, 222], (from, to, id, data)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `setApprovalForAll` (0xa22cb465) function - pub fn set_approval_for_all( - &self, - operator: ::ethers::core::types::Address, - approved: bool, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([162, 44, 180, 101], (operator, approved)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `supportsInterface` (0x01ffc9a7) function - pub fn supports_interface(&self, interface_id: [u8; 4]) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([1, 255, 201, 167], interface_id) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `symbol` (0x95d89b41) function - pub fn symbol(&self) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([149, 216, 155, 65], ()) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `tokenURI` (0xc87b56dd) function - pub fn token_uri( - &self, - id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([200, 123, 86, 221], id) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `transferFrom` (0x23b872dd) function - pub fn transfer_from( - &self, - from: ::ethers::core::types::Address, - to: ::ethers::core::types::Address, - id: ::ethers::core::types::U256, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([35, 184, 114, 221], (from, to, id)) - .expect("method not found (this should never happen)") - } - ///Gets the contract's `Approval` event - pub fn approval_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, ApprovalFilter> { - self.0.event() - } - ///Gets the contract's `ApprovalForAll` event - pub fn approval_for_all_filter( - &self, - ) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, ApprovalForAllFilter> { - self.0.event() - } - ///Gets the contract's `Transfer` event - pub fn transfer_filter(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, TransferFilter> { - self.0.event() - } - /// Returns an `Event` builder for all the events of this contract. - pub fn events(&self) -> ::ethers::contract::builders::Event<::std::sync::Arc, M, MockERC721Events> { - self.0.event_with_filter(::core::default::Default::default()) - } - } - impl From<::ethers::contract::Contract> for MockERC721 { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Approval", abi = "Approval(address,address,uint256)")] - pub struct ApprovalFilter { - #[ethevent(indexed)] - pub owner: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub spender: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub id: ::ethers::core::types::U256, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "ApprovalForAll", abi = "ApprovalForAll(address,address,bool)")] - pub struct ApprovalForAllFilter { - #[ethevent(indexed)] - pub owner: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub operator: ::ethers::core::types::Address, - pub approved: bool, - } - #[derive( - Clone, - ::ethers::contract::EthEvent, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethevent(name = "Transfer", abi = "Transfer(address,address,uint256)")] - pub struct TransferFilter { - #[ethevent(indexed)] - pub from: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub to: ::ethers::core::types::Address, - #[ethevent(indexed)] - pub id: ::ethers::core::types::U256, - } - ///Container type for all of the contract's events - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum MockERC721Events { - ApprovalFilter(ApprovalFilter), - ApprovalForAllFilter(ApprovalForAllFilter), - TransferFilter(TransferFilter), - } - impl ::ethers::contract::EthLogDecode for MockERC721Events { - fn decode_log(log: &::ethers::core::abi::RawLog) -> ::core::result::Result { - if let Ok(decoded) = ApprovalFilter::decode_log(log) { - return Ok(MockERC721Events::ApprovalFilter(decoded)); - } - if let Ok(decoded) = ApprovalForAllFilter::decode_log(log) { - return Ok(MockERC721Events::ApprovalForAllFilter(decoded)); - } - if let Ok(decoded) = TransferFilter::decode_log(log) { - return Ok(MockERC721Events::TransferFilter(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData) - } - } - impl ::core::fmt::Display for MockERC721Events { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::ApprovalFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::ApprovalForAllFilter(element) => ::core::fmt::Display::fmt(element, f), - Self::TransferFilter(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for MockERC721Events { - fn from(value: ApprovalFilter) -> Self { - Self::ApprovalFilter(value) - } - } - impl ::core::convert::From for MockERC721Events { - fn from(value: ApprovalForAllFilter) -> Self { - Self::ApprovalForAllFilter(value) - } - } - impl ::core::convert::From for MockERC721Events { - fn from(value: TransferFilter) -> Self { - Self::TransferFilter(value) - } - } - ///Container type for all input parameters for the `approve` function with signature `approve(address,uint256)` and selector `0x095ea7b3` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "approve", abi = "approve(address,uint256)")] - pub struct ApproveCall { - pub spender: ::ethers::core::types::Address, - pub id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `balanceOf` function with signature `balanceOf(address)` and selector `0x70a08231` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "balanceOf", abi = "balanceOf(address)")] - pub struct BalanceOfCall { - pub owner: ::ethers::core::types::Address, - } - ///Container type for all input parameters for the `getApproved` function with signature `getApproved(uint256)` and selector `0x081812fc` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "getApproved", abi = "getApproved(uint256)")] - pub struct GetApprovedCall(pub ::ethers::core::types::U256); - ///Container type for all input parameters for the `initialize` function with signature `initialize(string,string)` and selector `0x4cd88b76` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "initialize", abi = "initialize(string,string)")] - pub struct InitializeCall { - pub name: ::std::string::String, - pub symbol: ::std::string::String, - } - ///Container type for all input parameters for the `isApprovedForAll` function with signature `isApprovedForAll(address,address)` and selector `0xe985e9c5` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "isApprovedForAll", abi = "isApprovedForAll(address,address)")] - pub struct IsApprovedForAllCall(pub ::ethers::core::types::Address, pub ::ethers::core::types::Address); - ///Container type for all input parameters for the `name` function with signature `name()` and selector `0x06fdde03` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "name", abi = "name()")] - pub struct NameCall; - ///Container type for all input parameters for the `ownerOf` function with signature `ownerOf(uint256)` and selector `0x6352211e` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "ownerOf", abi = "ownerOf(uint256)")] - pub struct OwnerOfCall { - pub id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `safeTransferFrom` function with signature `safeTransferFrom(address,address,uint256)` and selector `0x42842e0e` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "safeTransferFrom", abi = "safeTransferFrom(address,address,uint256)")] - pub struct SafeTransferFromCall { - pub from: ::ethers::core::types::Address, - pub to: ::ethers::core::types::Address, - pub id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `safeTransferFrom` function with signature `safeTransferFrom(address,address,uint256,bytes)` and selector `0xb88d4fde` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "safeTransferFrom", abi = "safeTransferFrom(address,address,uint256,bytes)")] - pub struct SafeTransferFromWithFromAndToAndDataCall { - pub from: ::ethers::core::types::Address, - pub to: ::ethers::core::types::Address, - pub id: ::ethers::core::types::U256, - pub data: ::ethers::core::types::Bytes, - } - ///Container type for all input parameters for the `setApprovalForAll` function with signature `setApprovalForAll(address,bool)` and selector `0xa22cb465` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "setApprovalForAll", abi = "setApprovalForAll(address,bool)")] - pub struct SetApprovalForAllCall { - pub operator: ::ethers::core::types::Address, - pub approved: bool, - } - ///Container type for all input parameters for the `supportsInterface` function with signature `supportsInterface(bytes4)` and selector `0x01ffc9a7` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "supportsInterface", abi = "supportsInterface(bytes4)")] - pub struct SupportsInterfaceCall { - pub interface_id: [u8; 4], - } - ///Container type for all input parameters for the `symbol` function with signature `symbol()` and selector `0x95d89b41` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "symbol", abi = "symbol()")] - pub struct SymbolCall; - ///Container type for all input parameters for the `tokenURI` function with signature `tokenURI(uint256)` and selector `0xc87b56dd` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "tokenURI", abi = "tokenURI(uint256)")] - pub struct TokenURICall { - pub id: ::ethers::core::types::U256, - } - ///Container type for all input parameters for the `transferFrom` function with signature `transferFrom(address,address,uint256)` and selector `0x23b872dd` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "transferFrom", abi = "transferFrom(address,address,uint256)")] - pub struct TransferFromCall { - pub from: ::ethers::core::types::Address, - pub to: ::ethers::core::types::Address, - pub id: ::ethers::core::types::U256, - } - ///Container type for all of the contract's call - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum MockERC721Calls { - Approve(ApproveCall), - BalanceOf(BalanceOfCall), - GetApproved(GetApprovedCall), - Initialize(InitializeCall), - IsApprovedForAll(IsApprovedForAllCall), - Name(NameCall), - OwnerOf(OwnerOfCall), - SafeTransferFrom(SafeTransferFromCall), - SafeTransferFromWithFromAndToAndData(SafeTransferFromWithFromAndToAndDataCall), - SetApprovalForAll(SetApprovalForAllCall), - SupportsInterface(SupportsInterfaceCall), - Symbol(SymbolCall), - TokenURI(TokenURICall), - TransferFrom(TransferFromCall), - } - impl ::ethers::core::abi::AbiDecode for MockERC721Calls { - fn decode(data: impl AsRef<[u8]>) -> ::core::result::Result { - let data = data.as_ref(); - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Approve(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::BalanceOf(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::GetApproved(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Initialize(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::IsApprovedForAll(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Name(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::OwnerOf(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SafeTransferFrom(decoded)); - } - if let Ok(decoded) = - ::decode(data) - { - return Ok(Self::SafeTransferFromWithFromAndToAndData(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SetApprovalForAll(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::SupportsInterface(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::Symbol(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TokenURI(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TransferFrom(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData.into()) - } - } - impl ::ethers::core::abi::AbiEncode for MockERC721Calls { - fn encode(self) -> Vec { - match self { - Self::Approve(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::BalanceOf(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::GetApproved(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Initialize(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::IsApprovedForAll(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Name(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::OwnerOf(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SafeTransferFrom(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SafeTransferFromWithFromAndToAndData(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SetApprovalForAll(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::SupportsInterface(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::Symbol(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TokenURI(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TransferFrom(element) => ::ethers::core::abi::AbiEncode::encode(element), - } - } - } - impl ::core::fmt::Display for MockERC721Calls { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::Approve(element) => ::core::fmt::Display::fmt(element, f), - Self::BalanceOf(element) => ::core::fmt::Display::fmt(element, f), - Self::GetApproved(element) => ::core::fmt::Display::fmt(element, f), - Self::Initialize(element) => ::core::fmt::Display::fmt(element, f), - Self::IsApprovedForAll(element) => ::core::fmt::Display::fmt(element, f), - Self::Name(element) => ::core::fmt::Display::fmt(element, f), - Self::OwnerOf(element) => ::core::fmt::Display::fmt(element, f), - Self::SafeTransferFrom(element) => ::core::fmt::Display::fmt(element, f), - Self::SafeTransferFromWithFromAndToAndData(element) => ::core::fmt::Display::fmt(element, f), - Self::SetApprovalForAll(element) => ::core::fmt::Display::fmt(element, f), - Self::SupportsInterface(element) => ::core::fmt::Display::fmt(element, f), - Self::Symbol(element) => ::core::fmt::Display::fmt(element, f), - Self::TokenURI(element) => ::core::fmt::Display::fmt(element, f), - Self::TransferFrom(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for MockERC721Calls { - fn from(value: ApproveCall) -> Self { - Self::Approve(value) - } - } - impl ::core::convert::From for MockERC721Calls { - fn from(value: BalanceOfCall) -> Self { - Self::BalanceOf(value) - } - } - impl ::core::convert::From for MockERC721Calls { - fn from(value: GetApprovedCall) -> Self { - Self::GetApproved(value) - } - } - impl ::core::convert::From for MockERC721Calls { - fn from(value: InitializeCall) -> Self { - Self::Initialize(value) - } - } - impl ::core::convert::From for MockERC721Calls { - fn from(value: IsApprovedForAllCall) -> Self { - Self::IsApprovedForAll(value) - } - } - impl ::core::convert::From for MockERC721Calls { - fn from(value: NameCall) -> Self { - Self::Name(value) - } - } - impl ::core::convert::From for MockERC721Calls { - fn from(value: OwnerOfCall) -> Self { - Self::OwnerOf(value) - } - } - impl ::core::convert::From for MockERC721Calls { - fn from(value: SafeTransferFromCall) -> Self { - Self::SafeTransferFrom(value) - } - } - impl ::core::convert::From for MockERC721Calls { - fn from(value: SafeTransferFromWithFromAndToAndDataCall) -> Self { - Self::SafeTransferFromWithFromAndToAndData(value) - } - } - impl ::core::convert::From for MockERC721Calls { - fn from(value: SetApprovalForAllCall) -> Self { - Self::SetApprovalForAll(value) - } - } - impl ::core::convert::From for MockERC721Calls { - fn from(value: SupportsInterfaceCall) -> Self { - Self::SupportsInterface(value) - } - } - impl ::core::convert::From for MockERC721Calls { - fn from(value: SymbolCall) -> Self { - Self::Symbol(value) - } - } - impl ::core::convert::From for MockERC721Calls { - fn from(value: TokenURICall) -> Self { - Self::TokenURI(value) - } - } - impl ::core::convert::From for MockERC721Calls { - fn from(value: TransferFromCall) -> Self { - Self::TransferFrom(value) - } - } - ///Container type for all return fields from the `balanceOf` function with signature `balanceOf(address)` and selector `0x70a08231` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct BalanceOfReturn(pub ::ethers::core::types::U256); - ///Container type for all return fields from the `getApproved` function with signature `getApproved(uint256)` and selector `0x081812fc` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct GetApprovedReturn(pub ::ethers::core::types::Address); - ///Container type for all return fields from the `isApprovedForAll` function with signature `isApprovedForAll(address,address)` and selector `0xe985e9c5` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct IsApprovedForAllReturn(pub bool); - ///Container type for all return fields from the `name` function with signature `name()` and selector `0x06fdde03` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct NameReturn(pub ::std::string::String); - ///Container type for all return fields from the `ownerOf` function with signature `ownerOf(uint256)` and selector `0x6352211e` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct OwnerOfReturn { - pub owner: ::ethers::core::types::Address, - } - ///Container type for all return fields from the `supportsInterface` function with signature `supportsInterface(bytes4)` and selector `0x01ffc9a7` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct SupportsInterfaceReturn(pub bool); - ///Container type for all return fields from the `symbol` function with signature `symbol()` and selector `0x95d89b41` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct SymbolReturn(pub ::std::string::String); - ///Container type for all return fields from the `tokenURI` function with signature `tokenURI(uint256)` and selector `0xc87b56dd` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct TokenURIReturn(pub ::std::string::String); -} diff --git a/src/bindings/mod.rs b/src/bindings/mod.rs deleted file mode 100644 index 7b08acf..0000000 --- a/src/bindings/mod.rs +++ /dev/null @@ -1,58 +0,0 @@ -#![allow(clippy::all)] -//! This module contains abigen! generated bindings for solidity contracts. -//! This is autogenerated code. -//! Do not manually edit these files. -//! These files may be overwritten by the codegen system at any time. -pub mod bit_math; -pub mod ephemeral_all_positions_by_owner; -pub mod ephemeral_get_populated_ticks_in_range; -pub mod ephemeral_get_position; -pub mod ephemeral_get_positions; -pub mod ephemeral_pool_positions; -pub mod ephemeral_pool_slots; -pub mod ephemeral_pool_tick_bitmap; -pub mod ephemeral_pool_ticks; -pub mod ephemeral_storage_lens; -pub mod erc20_caller; -pub mod fixed_point_96; -pub mod fixed_point_math_lib; -pub mod full_math; -pub mod i_nonfungible_position_manager; -pub mod i_periphery_immutable_state; -pub mod i_periphery_payments; -pub mod i_pool_initializer; -pub mod i_uniswap_v3_factory; -pub mod i_uniswap_v3_mint_callback; -pub mod i_uniswap_v3_pool; -pub mod i_uniswap_v3_pool_actions; -pub mod i_uniswap_v3_pool_derived_state; -pub mod i_uniswap_v3_pool_events; -pub mod i_uniswap_v3_pool_immutables; -pub mod i_uniswap_v3_pool_owner_actions; -pub mod i_uniswap_v3_pool_state; -pub mod i_uniswap_v3_swap_callback; -pub mod ierc165; -pub mod ierc20; -pub mod ierc20_metadata; -pub mod ierc721; -pub mod ierc721_enumerable; -pub mod ierc721_metadata; -pub mod ierc721_permit; -pub mod ierc721_token_receiver; -pub mod lib_bit; -pub mod liquidity_amounts; -pub mod mock_erc20; -pub mod mock_erc721; -pub mod npm_caller; -pub mod pool_address; -pub mod pool_caller; -pub mod pool_utils; -pub mod position_lens; -pub mod position_utils; -pub mod safe_cast; -pub mod safe_transfer_lib; -pub mod shared_types; -pub mod ternary_lib; -pub mod tick_bitmap; -pub mod tick_math; -pub mod unsafe_math; diff --git a/src/bindings/npm_caller.rs b/src/bindings/npm_caller.rs deleted file mode 100644 index 7017040..0000000 --- a/src/bindings/npm_caller.rs +++ /dev/null @@ -1,114 +0,0 @@ -pub use npm_caller::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod npm_caller { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::std::collections::BTreeMap::new(), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static NPMCALLER_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`-`7`\x0B\x82\x82\x829\x80Q`\0\x1A`s\x14`*WcNH{q`\xE0\x1B`\0R`\0`\x04R`$`\0\xFD[0`\0R`s\x81S\x82\x81\xF3\xFEs\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The bytecode of the contract. - pub static NPMCALLER_BYTECODE: ::ethers::core::types::Bytes = ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"s\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static NPMCALLER_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct NPMCaller(::ethers::contract::Contract); - impl ::core::clone::Clone for NPMCaller { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for NPMCaller { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for NPMCaller { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for NPMCaller { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(NPMCaller)) - .field(&self.address()) - .finish() - } - } - impl NPMCaller { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - NPMCALLER_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - NPMCALLER_ABI.clone(), - NPMCALLER_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - } - impl From<::ethers::contract::Contract> for NPMCaller { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } -} diff --git a/src/bindings/pool_address.rs b/src/bindings/pool_address.rs deleted file mode 100644 index 519a9ea..0000000 --- a/src/bindings/pool_address.rs +++ /dev/null @@ -1,116 +0,0 @@ -pub use pool_address::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod pool_address { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::std::collections::BTreeMap::new(), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static POOLADDRESS_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`-`7`\x0B\x82\x82\x829\x80Q`\0\x1A`s\x14`*WcNH{q`\xE0\x1B`\0R`\0`\x04R`$`\0\xFD[0`\0R`s\x81S\x82\x81\xF3\xFEs\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The bytecode of the contract. - pub static POOLADDRESS_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"s\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static POOLADDRESS_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct PoolAddress(::ethers::contract::Contract); - impl ::core::clone::Clone for PoolAddress { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for PoolAddress { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for PoolAddress { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for PoolAddress { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(PoolAddress)) - .field(&self.address()) - .finish() - } - } - impl PoolAddress { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - POOLADDRESS_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - POOLADDRESS_ABI.clone(), - POOLADDRESS_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - } - impl From<::ethers::contract::Contract> for PoolAddress { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } -} diff --git a/src/bindings/pool_caller.rs b/src/bindings/pool_caller.rs deleted file mode 100644 index 6db50dd..0000000 --- a/src/bindings/pool_caller.rs +++ /dev/null @@ -1,116 +0,0 @@ -pub use pool_caller::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod pool_caller { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::std::collections::BTreeMap::new(), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static POOLCALLER_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`-`7`\x0B\x82\x82\x829\x80Q`\0\x1A`s\x14`*WcNH{q`\xE0\x1B`\0R`\0`\x04R`$`\0\xFD[0`\0R`s\x81S\x82\x81\xF3\xFEs\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The bytecode of the contract. - pub static POOLCALLER_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"s\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static POOLCALLER_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct PoolCaller(::ethers::contract::Contract); - impl ::core::clone::Clone for PoolCaller { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for PoolCaller { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for PoolCaller { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for PoolCaller { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(PoolCaller)) - .field(&self.address()) - .finish() - } - } - impl PoolCaller { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - POOLCALLER_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - POOLCALLER_ABI.clone(), - POOLCALLER_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - } - impl From<::ethers::contract::Contract> for PoolCaller { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } -} diff --git a/src/bindings/pool_utils.rs b/src/bindings/pool_utils.rs deleted file mode 100644 index 5c68b20..0000000 --- a/src/bindings/pool_utils.rs +++ /dev/null @@ -1,66 +0,0 @@ -pub use pool_utils::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod pool_utils { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::std::collections::BTreeMap::new(), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static POOLUTILS_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = ::ethers::contract::Lazy::new(__abi); - pub struct PoolUtils(::ethers::contract::Contract); - impl ::core::clone::Clone for PoolUtils { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for PoolUtils { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for PoolUtils { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for PoolUtils { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(PoolUtils)) - .field(&self.address()) - .finish() - } - } - impl PoolUtils { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - POOLUTILS_ABI.clone(), - client, - )) - } - } - impl From<::ethers::contract::Contract> for PoolUtils { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } -} diff --git a/src/bindings/position_lens.rs b/src/bindings/position_lens.rs deleted file mode 100644 index a344176..0000000 --- a/src/bindings/position_lens.rs +++ /dev/null @@ -1,362 +0,0 @@ -pub use position_lens::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod position_lens { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("getFeesOwed"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("getFeesOwed"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("pool"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "V3PoolCallee" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickLower"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickUpper"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokensOwed0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tokensOwed1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(128usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint128" - ),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ( - ::std::borrow::ToOwned::to_owned("getTotalAmounts"), - ::std::vec![::ethers::core::abi::ethabi::Function { - name: ::std::borrow::ToOwned::to_owned("getTotalAmounts"), - inputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("pool"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "V3PoolCallee" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("owner"), - kind: ::ethers::core::abi::ethabi::ParamType::Address, - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "address" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickLower"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("tickUpper"), - kind: ::ethers::core::abi::ethabi::ParamType::Int(24usize), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned("int24"),), - }, - ], - outputs: ::std::vec![ - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount0"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ::ethers::core::abi::ethabi::Param { - name: ::std::borrow::ToOwned::to_owned("amount1"), - kind: ::ethers::core::abi::ethabi::ParamType::Uint(256usize,), - internal_type: ::core::option::Option::Some(::std::borrow::ToOwned::to_owned( - "uint256" - ),), - }, - ], - constant: ::core::option::Option::None, - state_mutability: ::ethers::core::abi::ethabi::StateMutability::View, - },], - ), - ]), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static POSITIONLENS_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`\x80`@R4\x80\x15a\0\x10W`\0\x80\xFD[Pa\x0C\xB4\x80a\0 `\09`\0\xF3\xFE`\x80`@R4\x80\x15a\0\x10W`\0\x80\xFD[P`\x046\x10a\x006W`\x005`\xE0\x1C\x80c\x95\xBAQ\xBD\x14a\0;W\x80c\xC6\xA66e\x14a\0hW[`\0\x80\xFD[a\0Na\0I6`\x04a\x0C\x15V[a\0\xA4V[`@\x80Q\x92\x83R` \x83\x01\x91\x90\x91R\x01[`@Q\x80\x91\x03\x90\xF3[a\0{a\0v6`\x04a\x0C\x15V[a\x01\xDAV[`@\x80Qo\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x93\x84\x16\x81R\x92\x90\x91\x16` \x83\x01R\x01a\0_V[`\0\x80`\0a\0\xFF`@Q\x80``\x01`@R\x80\x88s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x81R` \x01\x87`\x02\x0B\x81R` \x01\x86`\x02\x0B\x81RP`@\x81\x01Q`\x06R` \x81\x01Q`\x03RQ`\0R`\x1A`\x0C \x90V[\x90P`\0a\x01#s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x89\x16\x83a\x02\xD8V[\x90P`\0a\x01F\x89s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x039V[P\x82Q\x90\x91Po\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x15a\x01\xCEWa\x01\x86\x81a\x01s\x89`\x02\x0Ba\x03tV[a\x01\x7F\x89`\x02\x0Ba\x03tV[\x85Qa\x06wV[\x90\x95P\x93P`\0\x80a\x01\x9A\x8B\x8B\x8B\x8Ba\x01\xDAV[o\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x91\x82\x16\x93P\x16\x90Pa\x01\xBD\x82\x88a\x0CmV[\x96Pa\x01\xC9\x81\x87a\x0CmV[\x95PPP[PPP\x94P\x94\x92PPPV[`\0\x80`\0a\x025`@Q\x80``\x01`@R\x80\x88s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x81R` \x01\x87`\x02\x0B\x81R` \x01\x86`\x02\x0B\x81RP`@\x81\x01Q`\x06R` \x81\x01Q`\x03RQ`\0R`\x1A`\x0C \x90V[\x90P`\0a\x02Ys\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x89\x16\x83a\x02\xD8V[\x90P`\0a\x02|\x89s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x039V[\x83Q\x90\x92Po\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x15\x90Pa\x01\xCEW`\0\x80a\x02\xA9\x8B\x8A\x8A\x86a\x07%V[\x91P\x91Pa\x02\xC6\x84`\0\x01Q\x83\x83\x87` \x01Q\x88`@\x01Qa\x08.V[\x90\x9C\x90\x9BP\x99PPPPPPPPPPV[`@\x80Q`\xA0\x81\x01\x82R`\0\x80\x82R` \x82\x01\x81\x90R\x91\x81\x01\x82\x90R``\x81\x01\x82\x90R`\x80\x81\x01\x91\x90\x91R\x80a\x032\x84\x7FQN\xA4\xBF\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\x85\x84`\xA0a\x08\x9FV[P\x92\x91PPV[`\0\x80\x80\x80a\x03h\x85\x7F8P\xC7\xBD\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\0a\x08\xC0V[\x90\x96\x90\x95P\x93PPPPV[`\0`\x02\x82\x90\x0B\x81\x81\x12\x82\x03\x80\x82\x01\x18b\r\x89\xE8\x81\x11\x15a\x03\xA7Wc\x08\xC3y\xA0`\0R` \x80Ra\x01T`AR`E`\x1C\xFD[\x7F\xFF\xFC\xB93\xBDo\xAD7\xAA-\x16-\x1AY@\x01\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0`\x80`\x07\x83\x90\x1B\x16\x1Cp\x01\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16`\x02\x82\x16\x15a\x04\x03Wo\xFF\xF9rr7=A2Y\xA4i\x90X\x0E!:\x02`\x80\x1C[`\x04\x82\x16\x15a\x04\"Wo\xFF\xF2\xE5\x0F_ei2\xEF\x125|\xF3\xC7\xFD\xCC\x02`\x80\x1C[`\x08\x82\x16\x15a\x04AWo\xFF\xE5\xCA\xCA~\x10\xE4\xE6\x1C6$\xEA\xA0\x94\x1C\xD0\x02`\x80\x1C[`\x10\x82\x16\x15a\x04`Wo\xFF\xCB\x98C\xD6\x0FaY\xC9\xDBX\x83\\\x92fD\x02`\x80\x1C[` \x82\x16\x15a\x04\x7FWo\xFF\x97;A\xFA\x98\xC0\x81G.h\x96\xDF\xB2T\xC0\x02`\x80\x1C[`@\x82\x16\x15a\x04\x9EWo\xFF.\xA1df\xC9j8C\xECx\xB3&\xB5(a\x02`\x80\x1C[`\x80\x82\x16\x15a\x04\xBDWo\xFE]\xEE\x04j\x99\xA2\xA8\x11\xC4a\xF1\x96\x9C0S\x02`\x80\x1C[a\x01\0\x82\x16\x15a\x04\xDDWo\xFC\xBE\x86\xC7\x90\n\x88\xAE\xDC\xFF\xC8;G\x9A\xA3\xA4\x02`\x80\x1C[a\x02\0\x82\x16\x15a\x04\xFDWo\xF9\x87\xA7%:\xC4\x13\x17o+\x07L\xF7\x81^T\x02`\x80\x1C[a\x04\0\x82\x16\x15a\x05\x1DWo\xF39+\x08\"\xB7\0\x05\x94\x0Cz9\x8EKp\xF3\x02`\x80\x1C[a\x08\0\x82\x16\x15a\x05=Wo\xE7\x15\x94u\xA2\xC2\x9BtC\xB2\x9C\x7F\xA6\xE8\x89\xD9\x02`\x80\x1C[a\x10\0\x82\x16\x15a\x05]Wo\xD0\x97\xF3\xBD\xFD \"\xB8\x84Z\xD8\xF7\x92\xAAX%\x02`\x80\x1C[a \0\x82\x16\x15a\x05}Wo\xA9\xF7FF-\x87\x0F\xDF\x8Ae\xDC\x1F\x90\xE0a\xE5\x02`\x80\x1C[a@\0\x82\x16\x15a\x05\x9DWop\xD8i\xA1V\xD2\xA1\xB8\x90\xBB=\xF6+\xAF2\xF7\x02`\x80\x1C[a\x80\0\x82\x16\x15a\x05\xBDWo1\xBE\x13_\x97\xD0\x8F\xD9\x81#\x15\x05T/\xCF\xA6\x02`\x80\x1C[b\x01\0\0\x82\x16\x15a\x05\xDEWo\t\xAAP\x8B[z\x84\xE1\xC6w\xDET\xF3\xE9\x9B\xC9\x02`\x80\x1C[b\x02\0\0\x82\x16\x15a\x05\xFEWn]j\xF8\xDE\xDB\x81\x19f\x99\xC3)\"^\xE6\x04\x02`\x80\x1C[b\x04\0\0\x82\x16\x15a\x06\x1DWm\"\x16\xE5\x84\xF5\xFA\x1E\xA9&\x04\x1B\xED\xFE\x98\x02`\x80\x1C[b\x08\0\0\x82\x16\x15a\x06:Wk\x04\x8A\x17\x03\x91\xF7\xDCBDN\x8F\xA2\x02`\x80\x1C[`\0\x83\x13\x15a\x06fW\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x04[c\xFF\xFF\xFF\xFF\x01` \x1C\x94\x93PPPPV[\x82\x82\x10\x83\x83\x18\x02\x92\x83\x18\x92\x90\x91\x18\x90`\0\x80s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x86\x16\x90\x87\x16\x11a\x06\xBBWa\x06\xB4\x85\x85\x85a\x08\xECV[\x91Pa\x07\x1CV[\x83s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x86s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x10\x15a\x07\x0EWa\x06\xFA\x86\x85\x85a\x08\xECV[\x91Pa\x07\x07\x85\x87\x85a\tZV[\x90Pa\x07\x1CV[a\x07\x19\x85\x85\x85a\tZV[\x90P[\x94P\x94\x92PPPV[`\0\x80\x80a\x07Is\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x88\x16\x87a\t\xA2V[\x90P`\0a\x07ms\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x89\x16\x87a\t\xA2V[\x90P\x86`\x02\x0B\x85`\x02\x0B\x12\x15a\x07\x9CW\x80`@\x01Q\x82`@\x01Q\x03\x93P\x80``\x01Q\x82``\x01Q\x03\x92Pa\x08#V[\x85`\x02\x0B\x85`\x02\x0B\x12a\x07\xC8W\x81`@\x01Q\x81`@\x01Q\x03\x93P\x81``\x01Q\x81``\x01Q\x03\x92Pa\x08#V[\x80`@\x01Q\x82`@\x01Qa\x07\xF1\x8As\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\n V[\x03\x03\x93P\x80``\x01Q\x82``\x01Qa\x08\x1E\x8As\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\nRV[\x03\x03\x92P[PP\x94P\x94\x92PPPV[`\0\x80a\x08ao\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x88\x16\x85\x88\x03p\x01\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0a\n~V[\x91Pa\x08\x93o\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x88\x16\x84\x87\x03p\x01\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0a\n~V[\x90P\x95P\x95\x93PPPPV[\x83`\0R\x82`\x04R\x80\x82`$`\0\x88Z\xFAa\x08\xB9W`\0\x80\xFD[PPPPPV[`\0\x80\x82`\0R`@`\0`\x04`\0\x87Z\xFAa\x08\xDBW`\0\x80\xFD[`\0Q\x91P` Q\x90P\x92P\x92\x90PV[\x82\x82\x10\x83\x83\x18\x02\x92\x83\x18\x92\x90\x91\x18\x90`\0a\tPs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x86\x16\x90a\tL\x90{\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\0\0\0\0\0\0\0\0\0\0\0\0``\x87\x90\x1B\x16\x90\x87\x16\x83\x81\x03\x90a\n~V[\x04\x90V[\x90P[\x93\x92PPPV[\x82\x82\x10\x83\x83\x18\x02\x92\x83\x18\x92\x90\x91\x18\x90`\0a\tPo\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x83\x16s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x87\x16\x90\x86\x16\x03a\n\x8BV[`@\x80Qa\x01\0\x81\x01\x82R`\0\x80\x82R` \x82\x01\x81\x90R\x91\x81\x01\x82\x90R``\x81\x01\x82\x90R`\x80\x81\x01\x82\x90R`\xA0\x81\x01\x82\x90R`\xC0\x81\x01\x82\x90R`\xE0\x81\x01\x91\x90\x91R`\x02\x82\x90\x0B\x81a\n\x18\x85\x7F\xF3\r\xBA\x93\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\x84\x84a\x01\0a\x08\x9FV[PP\x92\x91PPV[`\0a\nL\x82\x7F\xF3\x05\x83\x99\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\0a\n\xF0V[\x92\x91PPV[`\0a\nL\x82\x7FF\x14\x13\x19\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\0a\n\xF0V[`\0a\tP\x84\x84\x84a\x0B\x14V[`\0\x82\x82\x02\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x83\x85\t\x81\x81\x10\x82\x01\x90\x03l\x01\0\0\0\0\0\0\0\0\0\0\0\0\x81\x10a\n\xDDWc\xAEG\xF7\x02`\0R`\x04`\x1C\xFD[\x80`\xA0\x1B\x82``\x1C\x17\x92PPP\x92\x91PPV[`\0\x81`\0R` `\0`\x04`\0\x86Z\xFAa\x0B\nW`\0\x80\xFD[PP`\0Q\x91\x90PV[`\0\x83\x83\x02\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x84\x86\t\x81\x81\x10\x82\x01\x90\x03\x80a\x0BgW\x83a\x0B\\Wc\xAEG\xF7\x02`\0R`\x04`\x1C\xFD[P\x82\x90\x04\x90Pa\tSV[\x80\x84\x11a\x0B|Wc\xAEG\xF7\x02`\0R`\x04`\x1C\xFD[\x83\x85\x87\t`\0\x85\x81\x03\x86\x16\x95\x86\x90\x04\x95\x84\x83\x11\x90\x93\x03\x90\x83\x90\x03\x83\x90\x04`\x01\x01\x02\x92\x03\x04\x17`\x03\x83\x02`\x02\x90\x81\x18\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x90\x91\x03\x02\x02\x90P\x93\x92PPPV[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x16\x81\x14a\x0B\xFBW`\0\x80\xFD[PV[\x805`\x02\x81\x90\x0B\x81\x14a\x0C\x10W`\0\x80\xFD[\x91\x90PV[`\0\x80`\0\x80`\x80\x85\x87\x03\x12\x15a\x0C+W`\0\x80\xFD[\x845a\x0C6\x81a\x0B\xD9V[\x93P` \x85\x015a\x0CF\x81a\x0B\xD9V[\x92Pa\x0CT`@\x86\x01a\x0B\xFEV[\x91Pa\x0Cb``\x86\x01a\x0B\xFEV[\x90P\x92\x95\x91\x94P\x92PV[\x80\x82\x01\x80\x82\x11\x15a\nLW\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`\0R`\x11`\x04R`$`\0\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The bytecode of the contract. - pub static POSITIONLENS_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"`\x80`@R4\x80\x15a\0\x10W`\0\x80\xFD[P`\x046\x10a\x006W`\x005`\xE0\x1C\x80c\x95\xBAQ\xBD\x14a\0;W\x80c\xC6\xA66e\x14a\0hW[`\0\x80\xFD[a\0Na\0I6`\x04a\x0C\x15V[a\0\xA4V[`@\x80Q\x92\x83R` \x83\x01\x91\x90\x91R\x01[`@Q\x80\x91\x03\x90\xF3[a\0{a\0v6`\x04a\x0C\x15V[a\x01\xDAV[`@\x80Qo\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x93\x84\x16\x81R\x92\x90\x91\x16` \x83\x01R\x01a\0_V[`\0\x80`\0a\0\xFF`@Q\x80``\x01`@R\x80\x88s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x81R` \x01\x87`\x02\x0B\x81R` \x01\x86`\x02\x0B\x81RP`@\x81\x01Q`\x06R` \x81\x01Q`\x03RQ`\0R`\x1A`\x0C \x90V[\x90P`\0a\x01#s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x89\x16\x83a\x02\xD8V[\x90P`\0a\x01F\x89s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x039V[P\x82Q\x90\x91Po\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x15a\x01\xCEWa\x01\x86\x81a\x01s\x89`\x02\x0Ba\x03tV[a\x01\x7F\x89`\x02\x0Ba\x03tV[\x85Qa\x06wV[\x90\x95P\x93P`\0\x80a\x01\x9A\x8B\x8B\x8B\x8Ba\x01\xDAV[o\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x91\x82\x16\x93P\x16\x90Pa\x01\xBD\x82\x88a\x0CmV[\x96Pa\x01\xC9\x81\x87a\x0CmV[\x95PPP[PPP\x94P\x94\x92PPPV[`\0\x80`\0a\x025`@Q\x80``\x01`@R\x80\x88s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x81R` \x01\x87`\x02\x0B\x81R` \x01\x86`\x02\x0B\x81RP`@\x81\x01Q`\x06R` \x81\x01Q`\x03RQ`\0R`\x1A`\x0C \x90V[\x90P`\0a\x02Ys\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x89\x16\x83a\x02\xD8V[\x90P`\0a\x02|\x89s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\x039V[\x83Q\x90\x92Po\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x15\x90Pa\x01\xCEW`\0\x80a\x02\xA9\x8B\x8A\x8A\x86a\x07%V[\x91P\x91Pa\x02\xC6\x84`\0\x01Q\x83\x83\x87` \x01Q\x88`@\x01Qa\x08.V[\x90\x9C\x90\x9BP\x99PPPPPPPPPPV[`@\x80Q`\xA0\x81\x01\x82R`\0\x80\x82R` \x82\x01\x81\x90R\x91\x81\x01\x82\x90R``\x81\x01\x82\x90R`\x80\x81\x01\x91\x90\x91R\x80a\x032\x84\x7FQN\xA4\xBF\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\x85\x84`\xA0a\x08\x9FV[P\x92\x91PPV[`\0\x80\x80\x80a\x03h\x85\x7F8P\xC7\xBD\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\0a\x08\xC0V[\x90\x96\x90\x95P\x93PPPPV[`\0`\x02\x82\x90\x0B\x81\x81\x12\x82\x03\x80\x82\x01\x18b\r\x89\xE8\x81\x11\x15a\x03\xA7Wc\x08\xC3y\xA0`\0R` \x80Ra\x01T`AR`E`\x1C\xFD[\x7F\xFF\xFC\xB93\xBDo\xAD7\xAA-\x16-\x1AY@\x01\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0`\x80`\x07\x83\x90\x1B\x16\x1Cp\x01\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16`\x02\x82\x16\x15a\x04\x03Wo\xFF\xF9rr7=A2Y\xA4i\x90X\x0E!:\x02`\x80\x1C[`\x04\x82\x16\x15a\x04\"Wo\xFF\xF2\xE5\x0F_ei2\xEF\x125|\xF3\xC7\xFD\xCC\x02`\x80\x1C[`\x08\x82\x16\x15a\x04AWo\xFF\xE5\xCA\xCA~\x10\xE4\xE6\x1C6$\xEA\xA0\x94\x1C\xD0\x02`\x80\x1C[`\x10\x82\x16\x15a\x04`Wo\xFF\xCB\x98C\xD6\x0FaY\xC9\xDBX\x83\\\x92fD\x02`\x80\x1C[` \x82\x16\x15a\x04\x7FWo\xFF\x97;A\xFA\x98\xC0\x81G.h\x96\xDF\xB2T\xC0\x02`\x80\x1C[`@\x82\x16\x15a\x04\x9EWo\xFF.\xA1df\xC9j8C\xECx\xB3&\xB5(a\x02`\x80\x1C[`\x80\x82\x16\x15a\x04\xBDWo\xFE]\xEE\x04j\x99\xA2\xA8\x11\xC4a\xF1\x96\x9C0S\x02`\x80\x1C[a\x01\0\x82\x16\x15a\x04\xDDWo\xFC\xBE\x86\xC7\x90\n\x88\xAE\xDC\xFF\xC8;G\x9A\xA3\xA4\x02`\x80\x1C[a\x02\0\x82\x16\x15a\x04\xFDWo\xF9\x87\xA7%:\xC4\x13\x17o+\x07L\xF7\x81^T\x02`\x80\x1C[a\x04\0\x82\x16\x15a\x05\x1DWo\xF39+\x08\"\xB7\0\x05\x94\x0Cz9\x8EKp\xF3\x02`\x80\x1C[a\x08\0\x82\x16\x15a\x05=Wo\xE7\x15\x94u\xA2\xC2\x9BtC\xB2\x9C\x7F\xA6\xE8\x89\xD9\x02`\x80\x1C[a\x10\0\x82\x16\x15a\x05]Wo\xD0\x97\xF3\xBD\xFD \"\xB8\x84Z\xD8\xF7\x92\xAAX%\x02`\x80\x1C[a \0\x82\x16\x15a\x05}Wo\xA9\xF7FF-\x87\x0F\xDF\x8Ae\xDC\x1F\x90\xE0a\xE5\x02`\x80\x1C[a@\0\x82\x16\x15a\x05\x9DWop\xD8i\xA1V\xD2\xA1\xB8\x90\xBB=\xF6+\xAF2\xF7\x02`\x80\x1C[a\x80\0\x82\x16\x15a\x05\xBDWo1\xBE\x13_\x97\xD0\x8F\xD9\x81#\x15\x05T/\xCF\xA6\x02`\x80\x1C[b\x01\0\0\x82\x16\x15a\x05\xDEWo\t\xAAP\x8B[z\x84\xE1\xC6w\xDET\xF3\xE9\x9B\xC9\x02`\x80\x1C[b\x02\0\0\x82\x16\x15a\x05\xFEWn]j\xF8\xDE\xDB\x81\x19f\x99\xC3)\"^\xE6\x04\x02`\x80\x1C[b\x04\0\0\x82\x16\x15a\x06\x1DWm\"\x16\xE5\x84\xF5\xFA\x1E\xA9&\x04\x1B\xED\xFE\x98\x02`\x80\x1C[b\x08\0\0\x82\x16\x15a\x06:Wk\x04\x8A\x17\x03\x91\xF7\xDCBDN\x8F\xA2\x02`\x80\x1C[`\0\x83\x13\x15a\x06fW\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x04[c\xFF\xFF\xFF\xFF\x01` \x1C\x94\x93PPPPV[\x82\x82\x10\x83\x83\x18\x02\x92\x83\x18\x92\x90\x91\x18\x90`\0\x80s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x86\x16\x90\x87\x16\x11a\x06\xBBWa\x06\xB4\x85\x85\x85a\x08\xECV[\x91Pa\x07\x1CV[\x83s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x86s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16\x10\x15a\x07\x0EWa\x06\xFA\x86\x85\x85a\x08\xECV[\x91Pa\x07\x07\x85\x87\x85a\tZV[\x90Pa\x07\x1CV[a\x07\x19\x85\x85\x85a\tZV[\x90P[\x94P\x94\x92PPPV[`\0\x80\x80a\x07Is\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x88\x16\x87a\t\xA2V[\x90P`\0a\x07ms\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x89\x16\x87a\t\xA2V[\x90P\x86`\x02\x0B\x85`\x02\x0B\x12\x15a\x07\x9CW\x80`@\x01Q\x82`@\x01Q\x03\x93P\x80``\x01Q\x82``\x01Q\x03\x92Pa\x08#V[\x85`\x02\x0B\x85`\x02\x0B\x12a\x07\xC8W\x81`@\x01Q\x81`@\x01Q\x03\x93P\x81``\x01Q\x81``\x01Q\x03\x92Pa\x08#V[\x80`@\x01Q\x82`@\x01Qa\x07\xF1\x8As\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\n V[\x03\x03\x93P\x80``\x01Q\x82``\x01Qa\x08\x1E\x8As\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x16a\nRV[\x03\x03\x92P[PP\x94P\x94\x92PPPV[`\0\x80a\x08ao\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x88\x16\x85\x88\x03p\x01\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0a\n~V[\x91Pa\x08\x93o\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x88\x16\x84\x87\x03p\x01\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0a\n~V[\x90P\x95P\x95\x93PPPPV[\x83`\0R\x82`\x04R\x80\x82`$`\0\x88Z\xFAa\x08\xB9W`\0\x80\xFD[PPPPPV[`\0\x80\x82`\0R`@`\0`\x04`\0\x87Z\xFAa\x08\xDBW`\0\x80\xFD[`\0Q\x91P` Q\x90P\x92P\x92\x90PV[\x82\x82\x10\x83\x83\x18\x02\x92\x83\x18\x92\x90\x91\x18\x90`\0a\tPs\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x86\x16\x90a\tL\x90{\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\0\0\0\0\0\0\0\0\0\0\0\0``\x87\x90\x1B\x16\x90\x87\x16\x83\x81\x03\x90a\n~V[\x04\x90V[\x90P[\x93\x92PPPV[\x82\x82\x10\x83\x83\x18\x02\x92\x83\x18\x92\x90\x91\x18\x90`\0a\tPo\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x83\x16s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x87\x16\x90\x86\x16\x03a\n\x8BV[`@\x80Qa\x01\0\x81\x01\x82R`\0\x80\x82R` \x82\x01\x81\x90R\x91\x81\x01\x82\x90R``\x81\x01\x82\x90R`\x80\x81\x01\x82\x90R`\xA0\x81\x01\x82\x90R`\xC0\x81\x01\x82\x90R`\xE0\x81\x01\x91\x90\x91R`\x02\x82\x90\x0B\x81a\n\x18\x85\x7F\xF3\r\xBA\x93\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\x84\x84a\x01\0a\x08\x9FV[PP\x92\x91PPV[`\0a\nL\x82\x7F\xF3\x05\x83\x99\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\0a\n\xF0V[\x92\x91PPV[`\0a\nL\x82\x7FF\x14\x13\x19\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\0a\n\xF0V[`\0a\tP\x84\x84\x84a\x0B\x14V[`\0\x82\x82\x02\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x83\x85\t\x81\x81\x10\x82\x01\x90\x03l\x01\0\0\0\0\0\0\0\0\0\0\0\0\x81\x10a\n\xDDWc\xAEG\xF7\x02`\0R`\x04`\x1C\xFD[\x80`\xA0\x1B\x82``\x1C\x17\x92PPP\x92\x91PPV[`\0\x81`\0R` `\0`\x04`\0\x86Z\xFAa\x0B\nW`\0\x80\xFD[PP`\0Q\x91\x90PV[`\0\x83\x83\x02\x7F\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x84\x86\t\x81\x81\x10\x82\x01\x90\x03\x80a\x0BgW\x83a\x0B\\Wc\xAEG\xF7\x02`\0R`\x04`\x1C\xFD[P\x82\x90\x04\x90Pa\tSV[\x80\x84\x11a\x0B|Wc\xAEG\xF7\x02`\0R`\x04`\x1C\xFD[\x83\x85\x87\t`\0\x85\x81\x03\x86\x16\x95\x86\x90\x04\x95\x84\x83\x11\x90\x93\x03\x90\x83\x90\x03\x83\x90\x04`\x01\x01\x02\x92\x03\x04\x17`\x03\x83\x02`\x02\x90\x81\x18\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x82\x03\x02\x80\x85\x02\x90\x91\x03\x02\x02\x90P\x93\x92PPPV[s\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x16\x81\x14a\x0B\xFBW`\0\x80\xFD[PV[\x805`\x02\x81\x90\x0B\x81\x14a\x0C\x10W`\0\x80\xFD[\x91\x90PV[`\0\x80`\0\x80`\x80\x85\x87\x03\x12\x15a\x0C+W`\0\x80\xFD[\x845a\x0C6\x81a\x0B\xD9V[\x93P` \x85\x015a\x0CF\x81a\x0B\xD9V[\x92Pa\x0CT`@\x86\x01a\x0B\xFEV[\x91Pa\x0Cb``\x86\x01a\x0B\xFEV[\x90P\x92\x95\x91\x94P\x92PV[\x80\x82\x01\x80\x82\x11\x15a\nLW\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`\0R`\x11`\x04R`$`\0\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static POSITIONLENS_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct PositionLens(::ethers::contract::Contract); - impl ::core::clone::Clone for PositionLens { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for PositionLens { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for PositionLens { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for PositionLens { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(PositionLens)) - .field(&self.address()) - .finish() - } - } - impl PositionLens { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - POSITIONLENS_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - POSITIONLENS_ABI.clone(), - POSITIONLENS_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - ///Calls the contract's `getFeesOwed` (0xc6a63665) function - pub fn get_fees_owed( - &self, - pool: ::ethers::core::types::Address, - owner: ::ethers::core::types::Address, - tick_lower: i32, - tick_upper: i32, - ) -> ::ethers::contract::builders::ContractCall { - self.0 - .method_hash([198, 166, 54, 101], (pool, owner, tick_lower, tick_upper)) - .expect("method not found (this should never happen)") - } - ///Calls the contract's `getTotalAmounts` (0x95ba51bd) function - pub fn get_total_amounts( - &self, - pool: ::ethers::core::types::Address, - owner: ::ethers::core::types::Address, - tick_lower: i32, - tick_upper: i32, - ) -> ::ethers::contract::builders::ContractCall - { - self.0 - .method_hash([149, 186, 81, 189], (pool, owner, tick_lower, tick_upper)) - .expect("method not found (this should never happen)") - } - } - impl From<::ethers::contract::Contract> for PositionLens { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Container type for all input parameters for the `getFeesOwed` function with signature `getFeesOwed(address,address,int24,int24)` and selector `0xc6a63665` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "getFeesOwed", abi = "getFeesOwed(address,address,int24,int24)")] - pub struct GetFeesOwedCall { - pub pool: ::ethers::core::types::Address, - pub owner: ::ethers::core::types::Address, - pub tick_lower: i32, - pub tick_upper: i32, - } - ///Container type for all input parameters for the `getTotalAmounts` function with signature `getTotalAmounts(address,address,int24,int24)` and selector `0x95ba51bd` - #[derive( - Clone, - ::ethers::contract::EthCall, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[ethcall(name = "getTotalAmounts", abi = "getTotalAmounts(address,address,int24,int24)")] - pub struct GetTotalAmountsCall { - pub pool: ::ethers::core::types::Address, - pub owner: ::ethers::core::types::Address, - pub tick_lower: i32, - pub tick_upper: i32, - } - ///Container type for all of the contract's call - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum PositionLensCalls { - GetFeesOwed(GetFeesOwedCall), - GetTotalAmounts(GetTotalAmountsCall), - } - impl ::ethers::core::abi::AbiDecode for PositionLensCalls { - fn decode(data: impl AsRef<[u8]>) -> ::core::result::Result { - let data = data.as_ref(); - if let Ok(decoded) = ::decode(data) { - return Ok(Self::GetFeesOwed(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::GetTotalAmounts(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData.into()) - } - } - impl ::ethers::core::abi::AbiEncode for PositionLensCalls { - fn encode(self) -> Vec { - match self { - Self::GetFeesOwed(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::GetTotalAmounts(element) => ::ethers::core::abi::AbiEncode::encode(element), - } - } - } - impl ::core::fmt::Display for PositionLensCalls { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::GetFeesOwed(element) => ::core::fmt::Display::fmt(element, f), - Self::GetTotalAmounts(element) => ::core::fmt::Display::fmt(element, f), - } - } - } - impl ::core::convert::From for PositionLensCalls { - fn from(value: GetFeesOwedCall) -> Self { - Self::GetFeesOwed(value) - } - } - impl ::core::convert::From for PositionLensCalls { - fn from(value: GetTotalAmountsCall) -> Self { - Self::GetTotalAmounts(value) - } - } - ///Container type for all return fields from the `getFeesOwed` function with signature `getFeesOwed(address,address,int24,int24)` and selector `0xc6a63665` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct GetFeesOwedReturn { - pub tokens_owed_0: u128, - pub tokens_owed_1: u128, - } - ///Container type for all return fields from the `getTotalAmounts` function with signature `getTotalAmounts(address,address,int24,int24)` and selector `0x95ba51bd` - #[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - pub struct GetTotalAmountsReturn { - pub amount_0: ::ethers::core::types::U256, - pub amount_1: ::ethers::core::types::U256, - } -} diff --git a/src/bindings/position_utils.rs b/src/bindings/position_utils.rs deleted file mode 100644 index 4ff3545..0000000 --- a/src/bindings/position_utils.rs +++ /dev/null @@ -1,67 +0,0 @@ -pub use position_utils::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod position_utils { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::std::collections::BTreeMap::new(), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static POSITIONUTILS_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - pub struct PositionUtils(::ethers::contract::Contract); - impl ::core::clone::Clone for PositionUtils { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for PositionUtils { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for PositionUtils { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for PositionUtils { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(PositionUtils)) - .field(&self.address()) - .finish() - } - } - impl PositionUtils { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - POSITIONUTILS_ABI.clone(), - client, - )) - } - } - impl From<::ethers::contract::Contract> for PositionUtils { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } -} diff --git a/src/bindings/safe_cast.rs b/src/bindings/safe_cast.rs deleted file mode 100644 index 7af5698..0000000 --- a/src/bindings/safe_cast.rs +++ /dev/null @@ -1,114 +0,0 @@ -pub use safe_cast::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod safe_cast { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::std::collections::BTreeMap::new(), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static SAFECAST_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`-`7`\x0B\x82\x82\x829\x80Q`\0\x1A`s\x14`*WcNH{q`\xE0\x1B`\0R`\0`\x04R`$`\0\xFD[0`\0R`s\x81S\x82\x81\xF3\xFEs\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The bytecode of the contract. - pub static SAFECAST_BYTECODE: ::ethers::core::types::Bytes = ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"s\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static SAFECAST_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct SafeCast(::ethers::contract::Contract); - impl ::core::clone::Clone for SafeCast { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for SafeCast { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for SafeCast { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for SafeCast { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(SafeCast)) - .field(&self.address()) - .finish() - } - } - impl SafeCast { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - SAFECAST_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - SAFECAST_ABI.clone(), - SAFECAST_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - } - impl From<::ethers::contract::Contract> for SafeCast { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } -} diff --git a/src/bindings/safe_transfer_lib.rs b/src/bindings/safe_transfer_lib.rs deleted file mode 100644 index ae4ad3e..0000000 --- a/src/bindings/safe_transfer_lib.rs +++ /dev/null @@ -1,298 +0,0 @@ -pub use safe_transfer_lib::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod safe_transfer_lib { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::std::collections::BTreeMap::new(), - events: ::std::collections::BTreeMap::new(), - errors: ::core::convert::From::from([ - ( - ::std::borrow::ToOwned::to_owned("ApproveFailed"), - ::std::vec![::ethers::core::abi::ethabi::AbiError { - name: ::std::borrow::ToOwned::to_owned("ApproveFailed"), - inputs: ::std::vec![], - },], - ), - ( - ::std::borrow::ToOwned::to_owned("ETHTransferFailed"), - ::std::vec![::ethers::core::abi::ethabi::AbiError { - name: ::std::borrow::ToOwned::to_owned("ETHTransferFailed"), - inputs: ::std::vec![], - },], - ), - ( - ::std::borrow::ToOwned::to_owned("TransferFailed"), - ::std::vec![::ethers::core::abi::ethabi::AbiError { - name: ::std::borrow::ToOwned::to_owned("TransferFailed"), - inputs: ::std::vec![], - },], - ), - ( - ::std::borrow::ToOwned::to_owned("TransferFromFailed"), - ::std::vec![::ethers::core::abi::ethabi::AbiError { - name: ::std::borrow::ToOwned::to_owned("TransferFromFailed"), - inputs: ::std::vec![], - },], - ), - ]), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static SAFETRANSFERLIB_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`-`7`\x0B\x82\x82\x829\x80Q`\0\x1A`s\x14`*WcNH{q`\xE0\x1B`\0R`\0`\x04R`$`\0\xFD[0`\0R`s\x81S\x82\x81\xF3\xFEs\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The bytecode of the contract. - pub static SAFETRANSFERLIB_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"s\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static SAFETRANSFERLIB_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct SafeTransferLib(::ethers::contract::Contract); - impl ::core::clone::Clone for SafeTransferLib { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for SafeTransferLib { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for SafeTransferLib { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for SafeTransferLib { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(SafeTransferLib)) - .field(&self.address()) - .finish() - } - } - impl SafeTransferLib { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - SAFETRANSFERLIB_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - SAFETRANSFERLIB_ABI.clone(), - SAFETRANSFERLIB_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - } - impl From<::ethers::contract::Contract> for SafeTransferLib { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } - ///Custom Error type `ApproveFailed` with signature `ApproveFailed()` and selector `0x3e3f8f73` - #[derive( - Clone, - ::ethers::contract::EthError, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[etherror(name = "ApproveFailed", abi = "ApproveFailed()")] - pub struct ApproveFailed; - ///Custom Error type `ETHTransferFailed` with signature `ETHTransferFailed()` and selector `0xb12d13eb` - #[derive( - Clone, - ::ethers::contract::EthError, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[etherror(name = "ETHTransferFailed", abi = "ETHTransferFailed()")] - pub struct ETHTransferFailed; - ///Custom Error type `TransferFailed` with signature `TransferFailed()` and selector `0x90b8ec18` - #[derive( - Clone, - ::ethers::contract::EthError, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[etherror(name = "TransferFailed", abi = "TransferFailed()")] - pub struct TransferFailed; - ///Custom Error type `TransferFromFailed` with signature `TransferFromFailed()` and selector `0x7939f424` - #[derive( - Clone, - ::ethers::contract::EthError, - ::ethers::contract::EthDisplay, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, - )] - #[etherror(name = "TransferFromFailed", abi = "TransferFromFailed()")] - pub struct TransferFromFailed; - ///Container type for all of the contract's custom errors - #[derive( - Clone, ::ethers::contract::EthAbiType, serde::Serialize, serde::Deserialize, Debug, PartialEq, Eq, Hash, - )] - pub enum SafeTransferLibErrors { - ApproveFailed(ApproveFailed), - ETHTransferFailed(ETHTransferFailed), - TransferFailed(TransferFailed), - TransferFromFailed(TransferFromFailed), - /// The standard solidity revert string, with selector - /// Error(string) -- 0x08c379a0 - RevertString(::std::string::String), - } - impl ::ethers::core::abi::AbiDecode for SafeTransferLibErrors { - fn decode(data: impl AsRef<[u8]>) -> ::core::result::Result { - let data = data.as_ref(); - if let Ok(decoded) = <::std::string::String as ::ethers::core::abi::AbiDecode>::decode(data) { - return Ok(Self::RevertString(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::ApproveFailed(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::ETHTransferFailed(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TransferFailed(decoded)); - } - if let Ok(decoded) = ::decode(data) { - return Ok(Self::TransferFromFailed(decoded)); - } - Err(::ethers::core::abi::Error::InvalidData.into()) - } - } - impl ::ethers::core::abi::AbiEncode for SafeTransferLibErrors { - fn encode(self) -> ::std::vec::Vec { - match self { - Self::ApproveFailed(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::ETHTransferFailed(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TransferFailed(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::TransferFromFailed(element) => ::ethers::core::abi::AbiEncode::encode(element), - Self::RevertString(s) => ::ethers::core::abi::AbiEncode::encode(s), - } - } - } - impl ::ethers::contract::ContractRevert for SafeTransferLibErrors { - fn valid_selector(selector: [u8; 4]) -> bool { - match selector { - [0x08, 0xc3, 0x79, 0xa0] => true, - _ if selector == ::selector() => true, - _ if selector == ::selector() => true, - _ if selector == ::selector() => true, - _ if selector == ::selector() => true, - _ => false, - } - } - } - impl ::core::fmt::Display for SafeTransferLibErrors { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - match self { - Self::ApproveFailed(element) => ::core::fmt::Display::fmt(element, f), - Self::ETHTransferFailed(element) => ::core::fmt::Display::fmt(element, f), - Self::TransferFailed(element) => ::core::fmt::Display::fmt(element, f), - Self::TransferFromFailed(element) => ::core::fmt::Display::fmt(element, f), - Self::RevertString(s) => ::core::fmt::Display::fmt(s, f), - } - } - } - impl ::core::convert::From<::std::string::String> for SafeTransferLibErrors { - fn from(value: String) -> Self { - Self::RevertString(value) - } - } - impl ::core::convert::From for SafeTransferLibErrors { - fn from(value: ApproveFailed) -> Self { - Self::ApproveFailed(value) - } - } - impl ::core::convert::From for SafeTransferLibErrors { - fn from(value: ETHTransferFailed) -> Self { - Self::ETHTransferFailed(value) - } - } - impl ::core::convert::From for SafeTransferLibErrors { - fn from(value: TransferFailed) -> Self { - Self::TransferFailed(value) - } - } - impl ::core::convert::From for SafeTransferLibErrors { - fn from(value: TransferFromFailed) -> Self { - Self::TransferFromFailed(value) - } - } -} diff --git a/src/bindings/shared_types.rs b/src/bindings/shared_types.rs deleted file mode 100644 index 222d34f..0000000 --- a/src/bindings/shared_types.rs +++ /dev/null @@ -1,88 +0,0 @@ -///`Slot(uint256,uint256)` -#[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, -)] -pub struct Slot { - pub slot: ::ethers::core::types::U256, - pub data: ::ethers::core::types::U256, -} -///`PositionFull(uint96,address,address,address,uint24,int24,int24,uint128,uint256,uint256,uint128,uint128)` -#[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, -)] -pub struct PositionFull { - pub nonce: u128, - pub operator: ::ethers::core::types::Address, - pub token_0: ::ethers::core::types::Address, - pub token_1: ::ethers::core::types::Address, - pub fee: u32, - pub tick_lower: i32, - pub tick_upper: i32, - pub liquidity: u128, - pub fee_growth_inside_0_last_x128: ::ethers::core::types::U256, - pub fee_growth_inside_1_last_x128: ::ethers::core::types::U256, - pub tokens_owed_0: u128, - pub tokens_owed_1: u128, -} -///`PositionState(uint256,address,(uint96,address,address,address,uint24,int24,int24,uint128,uint256,uint256,uint128,uint128),(uint160,int24,uint16,uint16,uint16,uint8,bool),uint128,uint8,uint8)` -#[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, -)] -pub struct PositionState { - pub token_id: ::ethers::core::types::U256, - pub owner: ::ethers::core::types::Address, - pub position: PositionFull, - pub slot_0: Slot0, - pub active_liquidity: u128, - pub decimals_0: u8, - pub decimals_1: u8, -} -///`Slot0(uint160,int24,uint16,uint16,uint16,uint8,bool)` -#[derive( - Clone, - ::ethers::contract::EthAbiType, - ::ethers::contract::EthAbiCodec, - serde::Serialize, - serde::Deserialize, - Default, - Debug, - PartialEq, - Eq, - Hash, -)] -pub struct Slot0 { - pub sqrt_price_x96: ::ethers::core::types::U256, - pub tick: i32, - pub observation_index: u16, - pub observation_cardinality: u16, - pub observation_cardinality_next: u16, - pub fee_protocol: u8, - pub unlocked: bool, -} diff --git a/src/bindings/ternary_lib.rs b/src/bindings/ternary_lib.rs deleted file mode 100644 index 5345d05..0000000 --- a/src/bindings/ternary_lib.rs +++ /dev/null @@ -1,116 +0,0 @@ -pub use ternary_lib::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod ternary_lib { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::std::collections::BTreeMap::new(), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static TERNARYLIB_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`-`7`\x0B\x82\x82\x829\x80Q`\0\x1A`s\x14`*WcNH{q`\xE0\x1B`\0R`\0`\x04R`$`\0\xFD[0`\0R`s\x81S\x82\x81\xF3\xFEs\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The bytecode of the contract. - pub static TERNARYLIB_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"s\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static TERNARYLIB_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct TernaryLib(::ethers::contract::Contract); - impl ::core::clone::Clone for TernaryLib { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for TernaryLib { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for TernaryLib { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for TernaryLib { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(TernaryLib)) - .field(&self.address()) - .finish() - } - } - impl TernaryLib { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - TERNARYLIB_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - TERNARYLIB_ABI.clone(), - TERNARYLIB_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - } - impl From<::ethers::contract::Contract> for TernaryLib { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } -} diff --git a/src/bindings/tick_bitmap.rs b/src/bindings/tick_bitmap.rs deleted file mode 100644 index a6e2dfc..0000000 --- a/src/bindings/tick_bitmap.rs +++ /dev/null @@ -1,116 +0,0 @@ -pub use tick_bitmap::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod tick_bitmap { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::std::collections::BTreeMap::new(), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static TICKBITMAP_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`-`7`\x0B\x82\x82\x829\x80Q`\0\x1A`s\x14`*WcNH{q`\xE0\x1B`\0R`\0`\x04R`$`\0\xFD[0`\0R`s\x81S\x82\x81\xF3\xFEs\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The bytecode of the contract. - pub static TICKBITMAP_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"s\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static TICKBITMAP_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct TickBitmap(::ethers::contract::Contract); - impl ::core::clone::Clone for TickBitmap { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for TickBitmap { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for TickBitmap { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for TickBitmap { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(TickBitmap)) - .field(&self.address()) - .finish() - } - } - impl TickBitmap { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - TICKBITMAP_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - TICKBITMAP_ABI.clone(), - TICKBITMAP_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - } - impl From<::ethers::contract::Contract> for TickBitmap { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } -} diff --git a/src/bindings/tick_math.rs b/src/bindings/tick_math.rs deleted file mode 100644 index f11f8b1..0000000 --- a/src/bindings/tick_math.rs +++ /dev/null @@ -1,114 +0,0 @@ -pub use tick_math::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod tick_math { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::std::collections::BTreeMap::new(), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static TICKMATH_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`-`7`\x0B\x82\x82\x829\x80Q`\0\x1A`s\x14`*WcNH{q`\xE0\x1B`\0R`\0`\x04R`$`\0\xFD[0`\0R`s\x81S\x82\x81\xF3\xFEs\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The bytecode of the contract. - pub static TICKMATH_BYTECODE: ::ethers::core::types::Bytes = ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"s\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static TICKMATH_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct TickMath(::ethers::contract::Contract); - impl ::core::clone::Clone for TickMath { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for TickMath { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for TickMath { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for TickMath { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(TickMath)) - .field(&self.address()) - .finish() - } - } - impl TickMath { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - TICKMATH_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - TICKMATH_ABI.clone(), - TICKMATH_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - } - impl From<::ethers::contract::Contract> for TickMath { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } -} diff --git a/src/bindings/unsafe_math.rs b/src/bindings/unsafe_math.rs deleted file mode 100644 index 82bd6d8..0000000 --- a/src/bindings/unsafe_math.rs +++ /dev/null @@ -1,116 +0,0 @@ -pub use unsafe_math::*; -/// This module was auto-generated with ethers-rs Abigen. -/// More information at: -#[allow( - clippy::enum_variant_names, - clippy::too_many_arguments, - clippy::upper_case_acronyms, - clippy::type_complexity, - dead_code, - non_camel_case_types -)] -pub mod unsafe_math { - #[allow(deprecated)] - fn __abi() -> ::ethers::core::abi::Abi { - ::ethers::core::abi::ethabi::Contract { - constructor: ::core::option::Option::None, - functions: ::std::collections::BTreeMap::new(), - events: ::std::collections::BTreeMap::new(), - errors: ::std::collections::BTreeMap::new(), - receive: false, - fallback: false, - } - } - ///The parsed JSON ABI of the contract. - pub static UNSAFEMATH_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = - ::ethers::contract::Lazy::new(__abi); - #[rustfmt::skip] - const __BYTECODE: &[u8] = b"`-`7`\x0B\x82\x82\x829\x80Q`\0\x1A`s\x14`*WcNH{q`\xE0\x1B`\0R`\0`\x04R`$`\0\xFD[0`\0R`s\x81S\x82\x81\xF3\xFEs\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The bytecode of the contract. - pub static UNSAFEMATH_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__BYTECODE); - #[rustfmt::skip] - const __DEPLOYED_BYTECODE: &[u8] = b"s\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x000\x14`\x80`@R`\0\x80\xFD\xFE\xA1dsolcC\0\x08\x16\0\n"; - /// The deployed bytecode of the contract. - pub static UNSAFEMATH_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = - ::ethers::core::types::Bytes::from_static(__DEPLOYED_BYTECODE); - pub struct UnsafeMath(::ethers::contract::Contract); - impl ::core::clone::Clone for UnsafeMath { - fn clone(&self) -> Self { - Self(::core::clone::Clone::clone(&self.0)) - } - } - impl ::core::ops::Deref for UnsafeMath { - type Target = ::ethers::contract::Contract; - fn deref(&self) -> &Self::Target { - &self.0 - } - } - impl ::core::ops::DerefMut for UnsafeMath { - fn deref_mut(&mut self) -> &mut Self::Target { - &mut self.0 - } - } - impl ::core::fmt::Debug for UnsafeMath { - fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { - f.debug_tuple(::core::stringify!(UnsafeMath)) - .field(&self.address()) - .finish() - } - } - impl UnsafeMath { - /// Creates a new contract instance with the specified `ethers` client at - /// `address`. The contract derefs to a `ethers::Contract` object. - pub fn new>(address: T, client: ::std::sync::Arc) -> Self { - Self(::ethers::contract::Contract::new( - address.into(), - UNSAFEMATH_ABI.clone(), - client, - )) - } - /// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. - /// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction - /// - /// Notes: - /// - If there are no constructor arguments, you should pass `()` as the argument. - /// - The default poll duration is 7 seconds. - /// - The default number of confirmations is 1 block. - /// - /// - /// # Example - /// - /// Generate contract bindings with `abigen!` and deploy a new contract instance. - /// - /// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. - /// - /// ```ignore - /// # async fn deploy(client: ::std::sync::Arc) { - /// abigen!(Greeter, "../greeter.json"); - /// - /// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); - /// let msg = greeter_contract.greet().call().await.unwrap(); - /// # } - /// ``` - pub fn deploy( - client: ::std::sync::Arc, - constructor_args: T, - ) -> ::core::result::Result< - ::ethers::contract::builders::ContractDeployer, - ::ethers::contract::ContractError, - > { - let factory = ::ethers::contract::ContractFactory::new( - UNSAFEMATH_ABI.clone(), - UNSAFEMATH_BYTECODE.clone().into(), - client, - ); - let deployer = factory.deploy(constructor_args)?; - let deployer = ::ethers::contract::ContractDeployer::new(deployer); - Ok(deployer) - } - } - impl From<::ethers::contract::Contract> for UnsafeMath { - fn from(contract: ::ethers::contract::Contract) -> Self { - Self::new(contract.address(), contract.client()) - } - } -} diff --git a/src/pool_lens.rs b/src/pool_lens.rs index 6a5ab99..2e95ec7 100644 --- a/src/pool_lens.rs +++ b/src/pool_lens.rs @@ -80,26 +80,14 @@ mod tests { use super::*; use crate::bindings::i_uniswap_v3_pool::{IUniswapV3Pool, MintFilter}; use anyhow::Result; - use dotenv::dotenv; use futures::future::join_all; const POOL_ADDRESS: &str = "0x88e6A0c2dDD26FEEb64F039a2c41296FcB3f5640"; static BLOCK_NUMBER: Lazy = Lazy::new(|| BlockId::from(17000000)); - static RPC_URL: Lazy = Lazy::new(|| { - dotenv().ok(); - format!( - "https://mainnet.infura.io/v3/{}", - std::env::var("INFURA_API_KEY").unwrap() - ) - }); - - async fn make_provider() -> Arc> { - Arc::new(Provider::::connect(&*RPC_URL).await) - } #[tokio::test] async fn test_get_populated_ticks_in_range() -> Result<()> { - let client = make_provider().await; + let client = Arc::new(MAINNET.provider()); let pool = IUniswapV3Pool::new(POOL_ADDRESS.parse::
()?, client.clone()); let (_, tick_current, _, _, _, _, _) = pool.slot_0().block(BlockId::from(*BLOCK_NUMBER)).call().await?; let ticks = get_populated_ticks_in_range( @@ -151,7 +139,7 @@ mod tests { #[tokio::test] async fn test_get_static_slots() -> Result<()> { - let client = make_provider().await; + let client = Arc::new(MAINNET.provider()); let slots = get_static_slots(POOL_ADDRESS.parse()?, client.clone(), Some(*BLOCK_NUMBER)).await?; verify_slots(slots, client).await; Ok(()) @@ -159,7 +147,7 @@ mod tests { #[tokio::test] async fn test_get_ticks_slots() -> Result<()> { - let client = make_provider().await; + let client = Arc::new(MAINNET.provider()); let slots = get_ticks_slots( POOL_ADDRESS.parse()?, -887272, @@ -174,7 +162,7 @@ mod tests { #[tokio::test] async fn test_get_tick_bitmap_slots() -> Result<()> { - let client = make_provider().await; + let client = Arc::new(MAINNET.provider()); let slots = get_tick_bitmap_slots(POOL_ADDRESS.parse()?, client.clone(), Some(*BLOCK_NUMBER)).await?; verify_slots(slots, client).await; Ok(()) @@ -182,7 +170,7 @@ mod tests { #[tokio::test] async fn test_get_positions_slots() -> Result<()> { - let client = make_provider().await; + let client = Arc::new(MAINNET.provider()); let filter = MintFilter::new::<&Provider, Provider>( Filter::new().from_block(17000000 - 10000).to_block(17000000), &client, diff --git a/src/position_lens.rs b/src/position_lens.rs index 59870c5..93da95b 100644 --- a/src/position_lens.rs +++ b/src/position_lens.rs @@ -72,7 +72,6 @@ mod tests { shared_types::{PositionFull, Slot0}, }; use anyhow::Result; - use dotenv::dotenv; use ethers::{ abi::{encode, Token}, utils::{get_create2_address_from_hash, keccak256}, @@ -84,17 +83,6 @@ mod tests { static POOL_INIT_CODE_HASH: Lazy = Lazy::new(|| Bytes::from_str("0xe34f199b19b2b4f47f68442619d555527d244f78a3297ea89325f843f87b8b54").unwrap()); static BLOCK_NUMBER: Lazy = Lazy::new(|| BlockId::from(17000000)); - static RPC_URL: Lazy = Lazy::new(|| { - dotenv().ok(); - format!( - "https://mainnet.infura.io/v3/{}", - std::env::var("INFURA_API_KEY").unwrap() - ) - }); - - async fn make_provider() -> Arc> { - Arc::new(Provider::::connect(&*RPC_URL).await) - } /// Computes the address of a Uniswap V3 pool given the factory address, the two tokens, and the fee. /// @@ -130,7 +118,7 @@ mod tests { #[tokio::test] async fn test_get_position_details() -> Result<()> { - let client = make_provider().await; + let client = Arc::new(MAINNET.provider()); let PositionState { token_id, position: PositionFull { @@ -215,7 +203,7 @@ mod tests { #[tokio::test] async fn test_get_positions() -> Result<()> { - let client = make_provider().await; + let client = Arc::new(MAINNET.provider()); let positions = get_positions( NPM_ADDRESS.parse()?, (1..100).map(|i| i.into()).collect(), @@ -229,7 +217,7 @@ mod tests { #[tokio::test] async fn test_get_all_positions_by_owner() -> Result<()> { - let client = make_provider().await; + let client = Arc::new(MAINNET.provider()); let npm = INonfungiblePositionManager::new(NPM_ADDRESS.parse::
()?, client.clone()); let total_supply = npm.total_supply().block(*BLOCK_NUMBER).call().await?; let owner = npm.owner_of(total_supply.sub(1)).block(*BLOCK_NUMBER).call().await?; diff --git a/src/storage_lens.rs b/src/storage_lens.rs index f78e83e..f4dd156 100644 --- a/src/storage_lens.rs +++ b/src/storage_lens.rs @@ -33,26 +33,14 @@ pub async fn get_storage_at( mod tests { use super::*; use anyhow::Result; - use dotenv::dotenv; use futures::future::join_all; const POOL_ADDRESS: &str = "0x88e6A0c2dDD26FEEb64F039a2c41296FcB3f5640"; static BLOCK_NUMBER: Lazy = Lazy::new(|| BlockId::from(17000000)); - static RPC_URL: Lazy = Lazy::new(|| { - dotenv().ok(); - format!( - "https://mainnet.infura.io/v3/{}", - std::env::var("INFURA_API_KEY").unwrap() - ) - }); - - async fn make_provider() -> Arc> { - Arc::new(Provider::::connect(&*RPC_URL).await) - } #[tokio::test] async fn test_get_storage_at() -> Result<()> { - let client = make_provider().await; + let client = Arc::new(MAINNET.provider()); let slots = get_storage_at( POOL_ADDRESS.parse::
()?, (0..10).map(|i| H256::from_low_u64_be(i).to_fixed_bytes()).collect(), diff --git a/src/viem/caller.ts b/src/viem/caller.ts index 096a3c0..f046190 100644 --- a/src/viem/caller.ts +++ b/src/viem/caller.ts @@ -1,7 +1,7 @@ import { Abi, AbiFunction } from "abitype"; import { CallExecutionError, - ContractFunctionResult, + ContractFunctionReturnType, EncodeDeployDataParameters, Hex, PublicClient, @@ -20,9 +20,10 @@ export async function callEphemeralContract( deployParams: EncodeDeployDataParameters, publicClient: PublicClient, blockNumber?: bigint, -): Promise> { +): Promise> { try { await publicClient.call({ + // @ts-ignore data: encodeDeployData(deployParams), blockNumber, }); @@ -31,10 +32,11 @@ export async function callEphemeralContract( if ("data" in baseError) { const abiFunctions = deployParams.abi.filter((x) => x.type === "function"); if (abiFunctions.length === 1) { + // @ts-ignore return decodeFunctionResult({ abi: abiFunctions as [AbiFunction], data: baseError.data as Hex, - }) as ContractFunctionResult; + }); } else { throw new Error("abi should contain exactly one function"); } diff --git a/test/hardhat/test.ts b/test/hardhat/test.ts index 0c264fc..34dc62d 100644 --- a/test/hardhat/test.ts +++ b/test/hardhat/test.ts @@ -2,7 +2,7 @@ import { ApertureSupportedChainId, getChainInfo, viem } from "@aperture_finance/ import { TickMath } from "@uniswap/v3-sdk"; import { expect } from "chai"; import { config as dotenvConfig } from "dotenv"; -import { ContractFunctionResult, createPublicClient, getContract, http, toHex } from "viem"; +import { ContractFunctionReturnType, createPublicClient, getContract, http, toHex } from "viem"; import { getAllPositionsByOwner, getPopulatedTicksInRange, @@ -36,7 +36,7 @@ describe("Pool lens test", () => { const poolContract = getContract({ address: pool, abi: IUniswapV3Pool__factory.abi, - publicClient, + client: publicClient, }); const npm = viem.getNPM(chainId, publicClient); @@ -77,13 +77,13 @@ describe("Pool lens test", () => { const [_sqrtPriceX96, _tick] = await getContract({ address: viem.computePoolAddress(uniswap_v3_factory, token0, token1, fee), abi: IUniswapV3Pool__factory.abi, - publicClient, + client: publicClient, }).read.slot0({ blockNumber }); expect(sqrtPriceX96).to.be.eq(_sqrtPriceX96); expect(tick).to.be.eq(_tick); }); - async function verifyPositionDetails(posArr: ContractFunctionResult) { + async function verifyPositionDetails(posArr: ContractFunctionReturnType) { await Promise.all( posArr.map(async ({ tokenId, position }) => { const [, , token0, token1, fee, tickLower, tickUpper, liquidity] = await npm.read.positions([tokenId], { @@ -121,7 +121,7 @@ describe("Pool lens test", () => { await verifyPositionDetails(posArr); }); - async function verifySlots(slots: ContractFunctionResult) { + async function verifySlots(slots: ContractFunctionReturnType) { expect(slots.some(({ data }) => data > 0)).to.be.true; const address = pool; const altSlots = await Promise.all( diff --git a/yarn.lock b/yarn.lock index 87773b3..b6ee9cd 100644 --- a/yarn.lock +++ b/yarn.lock @@ -17,18 +17,18 @@ "@uniswap/v3-periphery" "^1.4.4" solady "^0.0.138" -"@aperture_finance/uniswap-v3-automation-sdk@^1.9.1": - version "1.9.1" - resolved "https://registry.yarnpkg.com/@aperture_finance/uniswap-v3-automation-sdk/-/uniswap-v3-automation-sdk-1.9.1.tgz#1602caedcb2c50359e54d1dda9e3c1953e8a4cda" - integrity sha512-HB/jmfkzg1H43a6wwqOueHlRfAXorSrKwp6mGuegTXHN9UBObeIUDkEJAfCXpW3seEHg03ltRi0NDzLf8dvnOQ== +"@aperture_finance/uniswap-v3-automation-sdk@^1.13.1": + version "1.13.1" + resolved "https://registry.yarnpkg.com/@aperture_finance/uniswap-v3-automation-sdk/-/uniswap-v3-automation-sdk-1.13.1.tgz#451454e05e745c8c97808e9af0f3a4302e9cab15" + integrity sha512-FTLBaVfV+Ah3RYrVEt+4Co5iGA3QWfWuglz62bgXKqaiF7FHSYV7vGIWQGuTeVKepvgp78A1VIf+VEMXSCJoUQ== dependencies: "@uniswap/v3-sdk" "^3.10.0" - aperture-lens "^0.1.5" + aperture-lens "^0.3.0" axios "^1.6.2" big.js "^6.2.1" ethers "5.7.2" json-stable-stringify "^1.1.0" - viem "^1.20.0" + viem "^1.20.3" zod "^3.22.4" "@chainsafe/as-sha256@^0.3.1": @@ -811,12 +811,10 @@ "@sentry/types" "5.30.0" tslib "^1.9.3" -"@solidity-parser/parser@^0.16.2": - version "0.16.2" - resolved "https://registry.yarnpkg.com/@solidity-parser/parser/-/parser-0.16.2.tgz#42cb1e3d88b3e8029b0c9befff00b634cd92d2fa" - integrity sha512-PI9NfoA3P8XK2VBkK5oIfRgKDsicwDZfkVq9ZTBCQYGOP1N2owgY2dyLGyU5/J/hQs8KRk55kdmvTLjy3Mu3vg== - dependencies: - antlr4ts "^0.5.0-alpha.4" +"@solidity-parser/parser@^0.17.0": + version "0.17.0" + resolved "https://registry.yarnpkg.com/@solidity-parser/parser/-/parser-0.17.0.tgz#52a2fcc97ff609f72011014e4c5b485ec52243ef" + integrity sha512-Nko8R0/kUo391jsEHHxrGM07QFdnPGvlmox4rmH0kNiNAashItAilhy4Mv4pK5gQmW5f4sXAF58fwJbmlkGcVw== "@tsconfig/node10@^1.0.7": version "1.0.9" @@ -882,10 +880,10 @@ resolved "https://registry.yarnpkg.com/@types/mocha/-/mocha-10.0.6.tgz#818551d39113081048bdddbef96701b4e8bb9d1b" integrity sha512-dJvrYWxP/UcXm36Qn36fxhUKu8A/xMRXVT2cliFF1Z7UA9liG5Psj3ezNSZw+5puH2czDXRLcXQxf8JbJt0ejg== -"@types/node@*", "@types/node@^20.10.4": - version "20.10.4" - resolved "https://registry.yarnpkg.com/@types/node/-/node-20.10.4.tgz#b246fd84d55d5b1b71bf51f964bd514409347198" - integrity sha512-D08YG6rr8X90YB56tSIuBaddy/UXAA9RKJoFvrsnogAum/0pmjkgi4+2nx96A330FmioegBWmEYQ+syqCFaveg== +"@types/node@*", "@types/node@^20.10.6": + version "20.10.6" + resolved "https://registry.yarnpkg.com/@types/node/-/node-20.10.6.tgz#a3ec84c22965802bf763da55b2394424f22bfbb5" + integrity sha512-Vac8H+NlRNNlAmDfGUP7b5h/KA+AtWIzuXy0E6OyP8f1tCLYAtPvKRRDJjAPqhpCb0t6U2j7/xqAuLEebW2kiw== dependencies: undici-types "~5.26.4" @@ -922,9 +920,9 @@ integrity sha512-f6UIliwBbRsgVLxIaBANF6w09tYqc6Y/qXdsrbEmXHyFA7ILiKrIwRFXe1yOg8M3cksgVsO9N7yuL2DdCGQKBA== "@uniswap/sdk-core@^4": - version "4.0.9" - resolved "https://registry.yarnpkg.com/@uniswap/sdk-core/-/sdk-core-4.0.9.tgz#7aef87de6d944307ce9bd57d1e1adfdcb2fed3ee" - integrity sha512-/0K+u3ZWokpj9VyRuGwrwx7jy31auJdsw5UbKnvHqUSfejrp6XhmMPNOElPgL6jiUhAN1NhVHfjX01tNHFxeLA== + version "4.0.10" + resolved "https://registry.yarnpkg.com/@uniswap/sdk-core/-/sdk-core-4.0.10.tgz#6173cc39d4e6b5ed679775447bb96a5b3c3fb2f2" + integrity sha512-RiobXJKXvVVb+wfNM09Ik8djOMOuRQGfyRP5pHgUjojicK/7nscZILjZ87DjVCGjXEoD8yTSIps0UAQuz6pJIw== dependencies: "@ethersproject/address" "^5.0.2" big.js "^5.2.2" @@ -994,6 +992,11 @@ "@uniswap/v3-core" "1.0.0" "@uniswap/v3-periphery" "^1.0.1" +abitype@0.10.0: + version "0.10.0" + resolved "https://registry.yarnpkg.com/abitype/-/abitype-0.10.0.tgz#d3504747cc81df2acaa6c460250ef7bc9219a77c" + integrity sha512-QvMHEUzgI9nPj9TWtUGnS2scas80/qaL5PBxGdwWhhvzqXfOph+IEiiiWrzuisu3U3JgDQVruW9oLbJoQ3oZ3A== + abitype@0.9.8: version "0.9.8" resolved "https://registry.yarnpkg.com/abitype/-/abitype-0.9.8.tgz#1f120b6b717459deafd213dfbf3a3dd1bf10ae8c" @@ -1018,9 +1021,9 @@ acorn-walk@^8.1.1: integrity sha512-TgUZgYvqZprrl7YldZNoa9OciCAyZR+Ejm9eXzKCmjsF5IKp/wgQ7Z/ZpjpGTIUPwrHQIcYeI8qDh4PsEwxMbw== acorn@^8.4.1: - version "8.11.2" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.11.2.tgz#ca0d78b51895be5390a5903c5b3bdcdaf78ae40b" - integrity sha512-nc0Axzp/0FILLEVsm4fNwLCwMttvhEI263QtVPQcbpfZZ3ts0hLsZGOpE6czNlid7CJ9MlyH8reXkpsf3YUY4w== + version "8.11.3" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.11.3.tgz#71e0b14e13a4ec160724b38fb7b0f233b1b81d7a" + integrity sha512-Y9rRfJG5jcKOE0CLisYbojUjIrIEE7AGMzA/Sm4BslANhbS+cDMpgBdcPT91oJ7OuJ9hYJBx59RjbhxVnrF8Xg== adm-zip@^0.4.16: version "0.4.16" @@ -1083,11 +1086,6 @@ ansi-styles@^4.0.0, ansi-styles@^4.1.0: dependencies: color-convert "^2.0.1" -antlr4ts@^0.5.0-alpha.4: - version "0.5.0-alpha.4" - resolved "https://registry.yarnpkg.com/antlr4ts/-/antlr4ts-0.5.0-alpha.4.tgz#71702865a87478ed0b40c0709f422cf14d51652a" - integrity sha512-WPQDt1B74OfPv/IMS2ekXAKkTZIHl88uMetg6q3OTqgFxZ/dxDXI0EWLyZid/1Pe6hTftyg5N7gel5wNAGxXyQ== - anymatch@~3.1.2: version "3.1.3" resolved "https://registry.yarnpkg.com/anymatch/-/anymatch-3.1.3.tgz#790c58b19ba1720a84205b57c618d5ad8524973e" @@ -1096,15 +1094,15 @@ anymatch@~3.1.2: normalize-path "^3.0.0" picomatch "^2.0.4" -aperture-lens@^0.1.5: - version "0.1.5" - resolved "https://registry.yarnpkg.com/aperture-lens/-/aperture-lens-0.1.5.tgz#f85fc26928713255019214635f0dc25baba1a046" - integrity sha512-LWDeGVpVCTskbf5ANJPt+IXPRfqKUTG3pX1Q70bYxcbKVfD049L403uMQiXZSI92uAnf/SUEGXzXrgx+dp+qag== +aperture-lens@^0.3.0: + version "0.3.0" + resolved "https://registry.yarnpkg.com/aperture-lens/-/aperture-lens-0.3.0.tgz#cc7d76fb84fece4064505cdef882d5a1c18f8f9a" + integrity sha512-nUkPpgy5G25XyHwll1jC02g/lpWs/zaDsCOzOYJv5WvNmOIJUeQ7lNTdbE/01s1+ro+ZJFOE4hLB9C++9G3zzQ== dependencies: "@aperture_finance/uni-v3-lib" "^1.2.0" "@openzeppelin/contracts" "^5.0.1" ethers "5.7.2" - viem "^1.20.0" + viem "^1.20.1" arg@^4.1.0: version "4.1.3" @@ -1142,11 +1140,11 @@ at-least-node@^1.0.0: integrity sha512-+q/t7Ekv1EDY2l6Gda6LLiX14rU9TV20Wa3ofeQmwPFZbOMo9DXrLbOjFaaclkXKWidIaopwAObQDqwWtGUjqg== axios@^1.6.2: - version "1.6.2" - resolved "https://registry.yarnpkg.com/axios/-/axios-1.6.2.tgz#de67d42c755b571d3e698df1b6504cde9b0ee9f2" - integrity sha512-7i24Ri4pmDRfJTR7LDBhsOTtcm+9kjX5WiY1X3wIisx6G9So3pfMkEiU7emUBe46oceVImccTEM3k6C5dbVW8A== + version "1.6.4" + resolved "https://registry.yarnpkg.com/axios/-/axios-1.6.4.tgz#184ee1f63d412caffcf30d2c50982253c3ee86e0" + integrity sha512-heJnIs6N4aa1eSthhN9M5ioILu8Wi8vmQW9iHQ9NUvfkJb0lEEDUiIdQNAuBtfUt3FxReaKdpQA5DbmMOqzF/A== dependencies: - follow-redirects "^1.15.0" + follow-redirects "^1.15.4" form-data "^4.0.0" proxy-from-env "^1.1.0" @@ -1770,10 +1768,10 @@ flat@^5.0.2: resolved "https://registry.yarnpkg.com/flat/-/flat-5.0.2.tgz#8ca6fe332069ffa9d324c327198c598259ceb241" integrity sha512-b6suED+5/3rTpUBdG1gupIl8MPFCAMA0QXwmljLhvCUKcUvdE4gWky9zpuGCcXHOsz4J9wPGNWq6OKpmIzz3hQ== -follow-redirects@^1.12.1, follow-redirects@^1.15.0: - version "1.15.3" - resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.15.3.tgz#fe2f3ef2690afce7e82ed0b44db08165b207123a" - integrity sha512-1VzOtuEM8pC9SFU1E+8KfTjZyMztRsgEfwQl44z8A25uy13jSzTj6dyK2Df52iV0vgHCfBwLhDWevLn95w5v6Q== +follow-redirects@^1.12.1, follow-redirects@^1.15.4: + version "1.15.4" + resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.15.4.tgz#cdc7d308bf6493126b17ea2191ea0ccf3e535adf" + integrity sha512-Cr4D/5wlrb0z9dgERpUL3LrmPKVDsETIJhaCMeDfuFYcqa5bldGV6wBsAN6X/vxlXQtFBMrXdXxdL8CbDTGniw== form-data@^4.0.0: version "4.0.0" @@ -1926,10 +1924,10 @@ hardhat-watcher@^2.1.1: dependencies: chokidar "^3.5.3" -hardhat@^2.19.2: - version "2.19.2" - resolved "https://registry.yarnpkg.com/hardhat/-/hardhat-2.19.2.tgz#815819e4efd234941d495decb718b358d572e2c8" - integrity sha512-CRU3+0Cc8Qh9UpxKd8cLADDPes7ZDtKj4dTK+ERtLBomEzhRPLWklJn4VKOwjre9/k8GNd/e9DYxpfuzcxbXPQ== +hardhat@^2.19.4: + version "2.19.4" + resolved "https://registry.yarnpkg.com/hardhat/-/hardhat-2.19.4.tgz#5112c30295d8be2e18e55d847373c50483ed1902" + integrity sha512-fTQJpqSt3Xo9Mn/WrdblNGAfcANM6XC3tAEi6YogB4s02DmTf93A8QsGb8uR0KR8TFcpcS8lgiW4ugAIYpnbrQ== dependencies: "@ethersproject/abi" "^5.1.2" "@metamask/eth-sig-util" "^4.0.0" @@ -2572,14 +2570,14 @@ picomatch@^2.0.4, picomatch@^2.2.1: resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.1.tgz#3ba3833733646d9d3e4995946c1365a67fb07a42" integrity sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA== -prettier-plugin-solidity@^1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/prettier-plugin-solidity/-/prettier-plugin-solidity-1.2.0.tgz#dc620b4fc7708a60687a87cdc803e57a1856b6fd" - integrity sha512-fgxcUZpVAP+LlRfy5JI5oaAkXGkmsje2VJ5krv/YMm+rcTZbIUwFguSw5f+WFuttMjpDm6wB4UL7WVkArEfiVA== +prettier-plugin-solidity@^1.3.1: + version "1.3.1" + resolved "https://registry.yarnpkg.com/prettier-plugin-solidity/-/prettier-plugin-solidity-1.3.1.tgz#59944d3155b249f7f234dee29f433524b9a4abcf" + integrity sha512-MN4OP5I2gHAzHZG1wcuJl0FsLS3c4Cc5494bbg+6oQWBPuEamjwDvmGfFMZ6NFzsh3Efd9UUxeT7ImgjNH4ozA== dependencies: - "@solidity-parser/parser" "^0.16.2" + "@solidity-parser/parser" "^0.17.0" semver "^7.5.4" - solidity-comments-extractor "^0.0.7" + solidity-comments-extractor "^0.0.8" prettier@^2.3.1: version "2.8.8" @@ -2791,10 +2789,10 @@ solc@0.7.3: semver "^5.5.0" tmp "0.0.33" -solidity-comments-extractor@^0.0.7: - version "0.0.7" - resolved "https://registry.yarnpkg.com/solidity-comments-extractor/-/solidity-comments-extractor-0.0.7.tgz#99d8f1361438f84019795d928b931f4e5c39ca19" - integrity sha512-wciNMLg/Irp8OKGrh3S2tfvZiZ0NEyILfcRCXCD4mp7SgK/i9gzLfhY2hY7VMCQJ3kH9UB9BzNdibIVMchzyYw== +solidity-comments-extractor@^0.0.8: + version "0.0.8" + resolved "https://registry.yarnpkg.com/solidity-comments-extractor/-/solidity-comments-extractor-0.0.8.tgz#f6e148ab0c49f30c1abcbecb8b8df01ed8e879f8" + integrity sha512-htM7Vn6LhHreR+EglVMd2s+sZhcXAirB1Zlyrv5zBuTxieCvjfnRpd7iZk75m/u6NOlEyQ94C6TWbBn2cY7w8g== source-map-support@^0.5.13: version "0.5.21" @@ -3068,10 +3066,10 @@ v8-compile-cache-lib@^3.0.1: resolved "https://registry.yarnpkg.com/v8-compile-cache-lib/-/v8-compile-cache-lib-3.0.1.tgz#6336e8d71965cb3d35a1bbb7868445a7c05264bf" integrity sha512-wa7YjyUGfNZngI/vtK0UHAN+lgDCxBPCylVXGp0zu59Fz5aiGtNXaq3DhIov063MorB+VfufLh3JlF2KdTK3xg== -viem@^1.20.0, viem@^1.20.1: - version "1.20.1" - resolved "https://registry.yarnpkg.com/viem/-/viem-1.20.1.tgz#ea92f9bab2fded4be556be4d4be724805d11780e" - integrity sha512-PaYyfuCVkNFzdaVoV8HefMIt5YtjIG6UPqxOz0rYchN52cD05YcRJlO0h/XrehQfo8ib2RSOkZ0ChJ6Adlh1Jg== +viem@^1.20.1, viem@^1.20.3: + version "1.21.4" + resolved "https://registry.yarnpkg.com/viem/-/viem-1.21.4.tgz#883760e9222540a5a7e0339809202b45fe6a842d" + integrity sha512-BNVYdSaUjeS2zKQgPs+49e5JKocfo60Ib2yiXOWBT6LuVxY1I/6fFX3waEtpXvL1Xn4qu+BVitVtMh9lyThyhQ== dependencies: "@adraffy/ens-normalize" "1.10.0" "@noble/curves" "1.2.0" @@ -3082,6 +3080,20 @@ viem@^1.20.0, viem@^1.20.1: isows "1.0.3" ws "8.13.0" +viem@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/viem/-/viem-2.0.0.tgz#1871512fbb4baa48164dc96765cc548dbfa964a8" + integrity sha512-WYPwVAs/wrQE1Li9mgHMZaZTnRZuyPJMauIhnpZKeZgtx7f+bWU3uvVSR5kxTf1aBFdaTuRc/umzX2ucQUurnA== + dependencies: + "@adraffy/ens-normalize" "1.10.0" + "@noble/curves" "1.2.0" + "@noble/hashes" "1.3.2" + "@scure/bip32" "1.3.2" + "@scure/bip39" "1.2.1" + abitype "0.10.0" + isows "1.0.3" + ws "8.13.0" + wordwrapjs@^4.0.0: version "4.0.1" resolved "https://registry.yarnpkg.com/wordwrapjs/-/wordwrapjs-4.0.1.tgz#d9790bccfb110a0fc7836b5ebce0937b37a8b98f"