diff --git a/.prettierignore b/.prettierignore index 1324c5d2..0d8b5db2 100644 --- a/.prettierignore +++ b/.prettierignore @@ -1,6 +1,7 @@ # Hardhat typechain generated code typechain-types/ typechain-typesV3/ +typechain-typesV4/ typechain-typesMMVault/ # Jest coverage report diff --git a/README.md b/README.md index dffdeea2..201c0a96 100644 --- a/README.md +++ b/README.md @@ -98,6 +98,7 @@ success Unregistered "@aperture_finance/uniswap-v3-automation-sdk". - **V2**: Custom Solver - **V3**: Migrate from feeBips to feeAmount +- **V4**: Advanced automan features required for DecreaseLiquiditySingle ## Contributing diff --git a/package.json b/package.json index 36b8b501..9c475349 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@aperture_finance/uniswap-v3-automation-sdk", - "version": "3.14.8doubleSolvere", + "version": "3.15.0automanV4a", "description": "SDK for Aperture's CLMM automation platform", "author": "Aperture Finance ", "license": "MIT", @@ -11,6 +11,7 @@ "scripts": { "build": "tsc --build && tsc-alias", "clean": "tsc --build --clean", + "compile": "tsc --build && tsc-alias", "test": "yarn test:jest && yarn test:hardhat", "test:jest": "jest", "test:hardhat": "npx hardhat test", diff --git a/src/chain.ts b/src/chain.ts index be5cf0a7..7605710c 100644 --- a/src/chain.ts +++ b/src/chain.ts @@ -63,7 +63,7 @@ export interface AmmInfo { optimalSwapRouter?: Address; // Aperture's Automan contract address. apertureAutoman: Address; - apertureAutomanV3: Address; + apertureAutomanV4: Address; // The subgraph URL for the AMM. Currently unset for all AMMs as there are no public, free endpoints. subgraph_url?: string; } @@ -108,7 +108,7 @@ const CHAIN_ID_TO_INFO: { apertureAutoman: getAddress( '0x00000000Ede6d8D217c60f93191C060747324bca', ), - apertureAutomanV3: getAddress( + apertureAutomanV4: getAddress( '0x00000070ee937917c1d9bD91729ce1Dd9A77d8e3', ), }, @@ -125,7 +125,7 @@ const CHAIN_ID_TO_INFO: { apertureAutoman: getAddress( '0x000000EEd287174A06550eabE6A00074255CaB34', ), - apertureAutomanV3: getAddress( + apertureAutomanV4: getAddress( '0x00000076a5FEfF94a54834fe1b2803a6Da672e03', ), }, @@ -161,8 +161,8 @@ const CHAIN_ID_TO_INFO: { apertureAutoman: getAddress( '0x00000000Ede6d8D217c60f93191C060747324bca', ), - apertureAutomanV3: getAddress( - '0x00000070ee937917c1d9bD91729ce1Dd9A77d8e3', + apertureAutomanV4: getAddress( + '0x00000054D9fBb1cEF6E7d3CD53df50977801C6f4', ), }, }, @@ -197,7 +197,7 @@ const CHAIN_ID_TO_INFO: { apertureAutoman: getAddress( '0x0000000002F4Dd78bA85fE4B662983816c9Ae95F', ), - apertureAutomanV3: getAddress( + apertureAutomanV4: getAddress( '0x00000070ee937917c1d9bD91729ce1Dd9A77d8e3', ), }, @@ -233,7 +233,7 @@ const CHAIN_ID_TO_INFO: { apertureAutoman: getAddress( '0x0000000002F4Dd78bA85fE4B662983816c9Ae95F', ), - apertureAutomanV3: getAddress( + apertureAutomanV4: getAddress( '0x00000070ee937917c1d9bD91729ce1Dd9A77d8e3', ), }, @@ -252,7 +252,7 @@ const CHAIN_ID_TO_INFO: { apertureAutoman: getAddress( '0x000000A117EDD4AA34C39f87eFa66A521c590DA1', ), - apertureAutomanV3: getAddress( + apertureAutomanV4: getAddress( '0x0000003d82D9fb11e644B84195218DfD3aeC3f73', ), }, @@ -288,7 +288,7 @@ const CHAIN_ID_TO_INFO: { apertureAutoman: getAddress( '0x000000000580f20d53f6d2eC56d12A5Fa75Ac8cF', ), - apertureAutomanV3: getAddress( + apertureAutomanV4: getAddress( '0x000000E2F3Dd82130669b730Bdf170D12DF35233', ), }, @@ -305,7 +305,7 @@ const CHAIN_ID_TO_INFO: { apertureAutoman: getAddress( '0x000000EEd287174A06550eabE6A00074255CaB34', ), - apertureAutomanV3: getAddress( + apertureAutomanV4: getAddress( '0x00000076a5FEfF94a54834fe1b2803a6Da672e03', ), }, @@ -341,7 +341,7 @@ const CHAIN_ID_TO_INFO: { apertureAutoman: getAddress( '0x00000000EDb4489cB49FE07246f39345c9f838cD', ), - apertureAutomanV3: getAddress( + apertureAutomanV4: getAddress( '0x000000C51119E2bDE2419C5e6fD273a81B79A8E3', ), }, @@ -360,8 +360,8 @@ const CHAIN_ID_TO_INFO: { apertureAutoman: getAddress( '0x00000000C733A397F38271c2Eb4CA56193b769Cb', ), - apertureAutomanV3: getAddress( - '0x000000ca99cf8E1E53B4b7999180Db3e1D032333', + apertureAutomanV4: getAddress( + '0x00000063e8cA29E95233D00DAF1A51588b9911c4', ), }, }, @@ -396,7 +396,7 @@ const CHAIN_ID_TO_INFO: { apertureAutoman: getAddress( '0x00000000035daa51254bEc3dE4FC1Cd277b35705', ), - apertureAutomanV3: getAddress( + apertureAutomanV4: getAddress( '0x00000075Cd3dAd5805699d0E1C5734e27B3264e3', ), }, @@ -432,7 +432,7 @@ const CHAIN_ID_TO_INFO: { apertureAutoman: getAddress( '0x0000000004276d0052eFdBA3E65a6f87fd55C5B7', ), - apertureAutomanV3: getAddress( + apertureAutomanV4: getAddress( '0x000000bf0E089A0991baB3CD0E111213c71a5aD3', ), }, @@ -469,7 +469,7 @@ const CHAIN_ID_TO_INFO: { apertureAutoman: getAddress( '0x00000000c04A561724F4Ea1181cA6E2E74E70FC1', ), - apertureAutomanV3: getAddress( + apertureAutomanV4: getAddress( '0x0000000000000000000000000000000000000000', ), }, @@ -504,7 +504,7 @@ const CHAIN_ID_TO_INFO: { apertureAutoman: getAddress( '0x000000001e433b4a86F252B54D2151Aa21ABB1C2', ), - apertureAutomanV3: getAddress( + apertureAutomanV4: getAddress( '0x00000027bC53f021F3564180f347425eDAA20883', ), }, diff --git a/src/index.ts b/src/index.ts index b7476379..aec1e831 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1,15 +1,15 @@ import { - Automan__factory as AutomanV3__factory, - IPCSV3Automan__factory as IPCSV3AutomanV3__factory, - ISlipStreamAutoman__factory as ISlipStreamAutomanV3__factory, - IUniV3Automan__factory as IUniV3AutomanV3__factory, - PCSV3Automan as PCSV3AutomanV3, - PCSV3Automan__factory as PCSV3AutomanV3__factory, - SlipStreamAutoman as SlipStreamAutomanV3, - SlipStreamAutoman__factory as SlipStreamAutomanV3__factory, - UniV3Automan as UniV3AutomanV3, - UniV3Automan__factory as UniV3AutomanV3__factory, -} from './typechain-typesV3'; + Automan__factory as AutomanV4__factory, + IPCSV3Automan__factory as IPCSV3AutomanV4__factory, + ISlipStreamAutoman__factory as ISlipStreamAutomanV4__factory, + IUniV3Automan__factory as IUniV3AutomanV4__factory, + PCSV3Automan as PCSV3AutomanV4, + PCSV3Automan__factory as PCSV3AutomanV4__factory, + SlipStreamAutoman as SlipStreamAutomanV4, + SlipStreamAutoman__factory as SlipStreamAutomanV4__factory, + UniV3Automan as UniV3AutomanV4, + UniV3Automan__factory as UniV3AutomanV4__factory, +} from './typechain-typesV4'; export * from './automan_client'; export * from './constants'; @@ -27,16 +27,16 @@ export * from './ioc'; export * from './logger'; export * from './data'; export { - AutomanV3__factory, - UniV3AutomanV3, - PCSV3AutomanV3, - SlipStreamAutomanV3, - IPCSV3AutomanV3__factory, - ISlipStreamAutomanV3__factory, - IUniV3AutomanV3__factory, - PCSV3AutomanV3__factory, - SlipStreamAutomanV3__factory, - UniV3AutomanV3__factory, + AutomanV4__factory, + UniV3AutomanV4, + PCSV3AutomanV4, + SlipStreamAutomanV4, + IPCSV3AutomanV4__factory, + ISlipStreamAutomanV4__factory, + IUniV3AutomanV4__factory, + PCSV3AutomanV4__factory, + SlipStreamAutomanV4__factory, + UniV3AutomanV4__factory, }; export { ApertureMMVault, diff --git a/src/typechain-typesV4/@aperture_finance/index.ts b/src/typechain-typesV4/@aperture_finance/index.ts new file mode 100644 index 00000000..6159af85 --- /dev/null +++ b/src/typechain-typesV4/@aperture_finance/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as uniV3Lib from "./uni-v3-lib"; +export type { uniV3Lib }; diff --git a/src/typechain-typesV4/@aperture_finance/uni-v3-lib/index.ts b/src/typechain-typesV4/@aperture_finance/uni-v3-lib/index.ts new file mode 100644 index 00000000..f68cafed --- /dev/null +++ b/src/typechain-typesV4/@aperture_finance/uni-v3-lib/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as src from "./src"; +export type { src }; diff --git a/src/typechain-typesV4/@aperture_finance/uni-v3-lib/src/FullMath.ts b/src/typechain-typesV4/@aperture_finance/uni-v3-lib/src/FullMath.ts new file mode 100644 index 00000000..f256c83a --- /dev/null +++ b/src/typechain-typesV4/@aperture_finance/uni-v3-lib/src/FullMath.ts @@ -0,0 +1,55 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { BaseContract, Signer, utils } from "ethers"; + +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export interface FullMathInterface extends utils.Interface { + functions: {}; + + events: {}; +} + +export interface FullMath extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: FullMathInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: {}; + + callStatic: {}; + + filters: {}; + + estimateGas: {}; + + populateTransaction: {}; +} diff --git a/src/typechain-typesV4/@aperture_finance/uni-v3-lib/src/index.ts b/src/typechain-typesV4/@aperture_finance/uni-v3-lib/src/index.ts new file mode 100644 index 00000000..f567e4eb --- /dev/null +++ b/src/typechain-typesV4/@aperture_finance/uni-v3-lib/src/index.ts @@ -0,0 +1,6 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as interfaces from "./interfaces"; +export type { interfaces }; +export type { FullMath } from "./FullMath"; diff --git a/src/typechain-typesV4/@aperture_finance/uni-v3-lib/src/interfaces/ICommonNonfungiblePositionManager.ts b/src/typechain-typesV4/@aperture_finance/uni-v3-lib/src/interfaces/ICommonNonfungiblePositionManager.ts new file mode 100644 index 00000000..747ccd9f --- /dev/null +++ b/src/typechain-typesV4/@aperture_finance/uni-v3-lib/src/interfaces/ICommonNonfungiblePositionManager.ts @@ -0,0 +1,1206 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../common"; + +export declare namespace ICommonNonfungiblePositionManager { + export type CollectParamsStruct = { + tokenId: BigNumberish; + recipient: string; + amount0Max: BigNumberish; + amount1Max: BigNumberish; + }; + + export type CollectParamsStructOutput = [ + BigNumber, + string, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + recipient: string; + amount0Max: BigNumber; + amount1Max: BigNumber; + }; + + export type DecreaseLiquidityParamsStruct = { + tokenId: BigNumberish; + liquidity: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + deadline: BigNumberish; + }; + + export type DecreaseLiquidityParamsStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + deadline: BigNumber; + }; + + export type IncreaseLiquidityParamsStruct = { + tokenId: BigNumberish; + amount0Desired: BigNumberish; + amount1Desired: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + deadline: BigNumberish; + }; + + export type IncreaseLiquidityParamsStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + amount0Desired: BigNumber; + amount1Desired: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + deadline: BigNumber; + }; +} + +export interface ICommonNonfungiblePositionManagerInterface + extends utils.Interface { + functions: { + "DOMAIN_SEPARATOR()": FunctionFragment; + "PERMIT_TYPEHASH()": FunctionFragment; + "WETH9()": FunctionFragment; + "approve(address,uint256)": FunctionFragment; + "balanceOf(address)": FunctionFragment; + "burn(uint256)": FunctionFragment; + "collect((uint256,address,uint128,uint128))": FunctionFragment; + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256))": FunctionFragment; + "factory()": FunctionFragment; + "getApproved(uint256)": FunctionFragment; + "increaseLiquidity((uint256,uint256,uint256,uint256,uint256,uint256))": FunctionFragment; + "isApprovedForAll(address,address)": FunctionFragment; + "name()": FunctionFragment; + "ownerOf(uint256)": FunctionFragment; + "permit(address,uint256,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "refundETH()": FunctionFragment; + "safeTransferFrom(address,address,uint256)": FunctionFragment; + "safeTransferFrom(address,address,uint256,bytes)": FunctionFragment; + "setApprovalForAll(address,bool)": FunctionFragment; + "supportsInterface(bytes4)": FunctionFragment; + "sweepToken(address,uint256,address)": FunctionFragment; + "symbol()": FunctionFragment; + "tokenByIndex(uint256)": FunctionFragment; + "tokenOfOwnerByIndex(address,uint256)": FunctionFragment; + "tokenURI(uint256)": FunctionFragment; + "totalSupply()": FunctionFragment; + "transferFrom(address,address,uint256)": FunctionFragment; + "unwrapWETH9(uint256,address)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "DOMAIN_SEPARATOR" + | "PERMIT_TYPEHASH" + | "WETH9" + | "approve" + | "balanceOf" + | "burn" + | "collect" + | "decreaseLiquidity" + | "factory" + | "getApproved" + | "increaseLiquidity" + | "isApprovedForAll" + | "name" + | "ownerOf" + | "permit" + | "refundETH" + | "safeTransferFrom(address,address,uint256)" + | "safeTransferFrom(address,address,uint256,bytes)" + | "setApprovalForAll" + | "supportsInterface" + | "sweepToken" + | "symbol" + | "tokenByIndex" + | "tokenOfOwnerByIndex" + | "tokenURI" + | "totalSupply" + | "transferFrom" + | "unwrapWETH9" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "DOMAIN_SEPARATOR", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "PERMIT_TYPEHASH", + values?: undefined + ): string; + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData( + functionFragment: "approve", + values: [string, BigNumberish] + ): string; + encodeFunctionData(functionFragment: "balanceOf", values: [string]): string; + encodeFunctionData(functionFragment: "burn", values: [BigNumberish]): string; + encodeFunctionData( + functionFragment: "collect", + values: [ICommonNonfungiblePositionManager.CollectParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidity", + values: [ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct] + ): string; + encodeFunctionData(functionFragment: "factory", values?: undefined): string; + encodeFunctionData( + functionFragment: "getApproved", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidity", + values: [ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "isApprovedForAll", + values: [string, string] + ): string; + encodeFunctionData(functionFragment: "name", values?: undefined): string; + encodeFunctionData( + functionFragment: "ownerOf", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "permit", + values: [ + string, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData(functionFragment: "refundETH", values?: undefined): string; + encodeFunctionData( + functionFragment: "safeTransferFrom(address,address,uint256)", + values: [string, string, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "safeTransferFrom(address,address,uint256,bytes)", + values: [string, string, BigNumberish, BytesLike] + ): string; + encodeFunctionData( + functionFragment: "setApprovalForAll", + values: [string, boolean] + ): string; + encodeFunctionData( + functionFragment: "supportsInterface", + values: [BytesLike] + ): string; + encodeFunctionData( + functionFragment: "sweepToken", + values: [string, BigNumberish, string] + ): string; + encodeFunctionData(functionFragment: "symbol", values?: undefined): string; + encodeFunctionData( + functionFragment: "tokenByIndex", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "tokenOfOwnerByIndex", + values: [string, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "tokenURI", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "totalSupply", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "transferFrom", + values: [string, string, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "unwrapWETH9", + values: [BigNumberish, string] + ): string; + + decodeFunctionResult( + functionFragment: "DOMAIN_SEPARATOR", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "PERMIT_TYPEHASH", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "approve", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "balanceOf", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "burn", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "collect", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidity", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "factory", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "getApproved", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidity", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "isApprovedForAll", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "name", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "ownerOf", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "permit", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "refundETH", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "safeTransferFrom(address,address,uint256)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "safeTransferFrom(address,address,uint256,bytes)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setApprovalForAll", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "supportsInterface", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "sweepToken", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "symbol", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "tokenByIndex", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "tokenOfOwnerByIndex", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "tokenURI", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "totalSupply", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "transferFrom", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "unwrapWETH9", + data: BytesLike + ): Result; + + events: { + "Approval(address,address,uint256)": EventFragment; + "ApprovalForAll(address,address,bool)": EventFragment; + "Collect(uint256,address,uint256,uint256)": EventFragment; + "DecreaseLiquidity(uint256,uint128,uint256,uint256)": EventFragment; + "IncreaseLiquidity(uint256,uint128,uint256,uint256)": EventFragment; + "Transfer(address,address,uint256)": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "Approval"): EventFragment; + getEvent(nameOrSignatureOrTopic: "ApprovalForAll"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Collect"): EventFragment; + getEvent(nameOrSignatureOrTopic: "DecreaseLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "IncreaseLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Transfer"): EventFragment; +} + +export interface ApprovalEventObject { + owner: string; + approved: string; + tokenId: BigNumber; +} +export type ApprovalEvent = TypedEvent< + [string, string, BigNumber], + ApprovalEventObject +>; + +export type ApprovalEventFilter = TypedEventFilter; + +export interface ApprovalForAllEventObject { + owner: string; + operator: string; + approved: boolean; +} +export type ApprovalForAllEvent = TypedEvent< + [string, string, boolean], + ApprovalForAllEventObject +>; + +export type ApprovalForAllEventFilter = TypedEventFilter; + +export interface CollectEventObject { + tokenId: BigNumber; + recipient: string; + amount0: BigNumber; + amount1: BigNumber; +} +export type CollectEvent = TypedEvent< + [BigNumber, string, BigNumber, BigNumber], + CollectEventObject +>; + +export type CollectEventFilter = TypedEventFilter; + +export interface DecreaseLiquidityEventObject { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; +} +export type DecreaseLiquidityEvent = TypedEvent< + [BigNumber, BigNumber, BigNumber, BigNumber], + DecreaseLiquidityEventObject +>; + +export type DecreaseLiquidityEventFilter = + TypedEventFilter; + +export interface IncreaseLiquidityEventObject { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; +} +export type IncreaseLiquidityEvent = TypedEvent< + [BigNumber, BigNumber, BigNumber, BigNumber], + IncreaseLiquidityEventObject +>; + +export type IncreaseLiquidityEventFilter = + TypedEventFilter; + +export interface TransferEventObject { + from: string; + to: string; + tokenId: BigNumber; +} +export type TransferEvent = TypedEvent< + [string, string, BigNumber], + TransferEventObject +>; + +export type TransferEventFilter = TypedEventFilter; + +export interface ICommonNonfungiblePositionManager extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: ICommonNonfungiblePositionManagerInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise<[string]>; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise<[string]>; + + WETH9(overrides?: CallOverrides): Promise<[string]>; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf( + owner: string, + overrides?: CallOverrides + ): Promise<[BigNumber] & { balance: BigNumber }>; + + burn( + tokenId: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + collect( + params: ICommonNonfungiblePositionManager.CollectParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + decreaseLiquidity( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise<[string]>; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise<[string] & { operator: string }>; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise<[boolean]>; + + name(overrides?: CallOverrides): Promise<[string]>; + + ownerOf( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise<[string] & { owner: string }>; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + refundETH( + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise<[boolean]>; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + symbol(overrides?: CallOverrides): Promise<[string]>; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise<[BigNumber]>; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise<[BigNumber]>; + + tokenURI( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise<[string]>; + + totalSupply(overrides?: CallOverrides): Promise<[BigNumber]>; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + }; + + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise; + + WETH9(overrides?: CallOverrides): Promise; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + burn( + tokenId: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + collect( + params: ICommonNonfungiblePositionManager.CollectParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + decreaseLiquidity( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + name(overrides?: CallOverrides): Promise; + + ownerOf(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + refundETH( + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenURI(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + callStatic: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise; + + WETH9(overrides?: CallOverrides): Promise; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + burn(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + collect( + params: ICommonNonfungiblePositionManager.CollectParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + decreaseLiquidity( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + factory(overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + name(overrides?: CallOverrides): Promise; + + ownerOf(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise; + + refundETH(overrides?: CallOverrides): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: CallOverrides + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: CallOverrides + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenURI(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "Approval(address,address,uint256)"( + owner?: string | null, + approved?: string | null, + tokenId?: BigNumberish | null + ): ApprovalEventFilter; + Approval( + owner?: string | null, + approved?: string | null, + tokenId?: BigNumberish | null + ): ApprovalEventFilter; + + "ApprovalForAll(address,address,bool)"( + owner?: string | null, + operator?: string | null, + approved?: null + ): ApprovalForAllEventFilter; + ApprovalForAll( + owner?: string | null, + operator?: string | null, + approved?: null + ): ApprovalForAllEventFilter; + + "Collect(uint256,address,uint256,uint256)"( + tokenId?: BigNumberish | null, + recipient?: null, + amount0?: null, + amount1?: null + ): CollectEventFilter; + Collect( + tokenId?: BigNumberish | null, + recipient?: null, + amount0?: null, + amount1?: null + ): CollectEventFilter; + + "DecreaseLiquidity(uint256,uint128,uint256,uint256)"( + tokenId?: BigNumberish | null, + liquidity?: null, + amount0?: null, + amount1?: null + ): DecreaseLiquidityEventFilter; + DecreaseLiquidity( + tokenId?: BigNumberish | null, + liquidity?: null, + amount0?: null, + amount1?: null + ): DecreaseLiquidityEventFilter; + + "IncreaseLiquidity(uint256,uint128,uint256,uint256)"( + tokenId?: BigNumberish | null, + liquidity?: null, + amount0?: null, + amount1?: null + ): IncreaseLiquidityEventFilter; + IncreaseLiquidity( + tokenId?: BigNumberish | null, + liquidity?: null, + amount0?: null, + amount1?: null + ): IncreaseLiquidityEventFilter; + + "Transfer(address,address,uint256)"( + from?: string | null, + to?: string | null, + tokenId?: BigNumberish | null + ): TransferEventFilter; + Transfer( + from?: string | null, + to?: string | null, + tokenId?: BigNumberish | null + ): TransferEventFilter; + }; + + estimateGas: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise; + + WETH9(overrides?: CallOverrides): Promise; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + burn( + tokenId: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + collect( + params: ICommonNonfungiblePositionManager.CollectParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + decreaseLiquidity( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + name(overrides?: CallOverrides): Promise; + + ownerOf( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + refundETH( + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenURI( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise; + + WETH9(overrides?: CallOverrides): Promise; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf( + owner: string, + overrides?: CallOverrides + ): Promise; + + burn( + tokenId: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + collect( + params: ICommonNonfungiblePositionManager.CollectParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + decreaseLiquidity( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + name(overrides?: CallOverrides): Promise; + + ownerOf( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + refundETH( + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenURI( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/@aperture_finance/uni-v3-lib/src/interfaces/IPCSV3NonfungiblePositionManager.ts b/src/typechain-typesV4/@aperture_finance/uni-v3-lib/src/interfaces/IPCSV3NonfungiblePositionManager.ts new file mode 100644 index 00000000..ae384103 --- /dev/null +++ b/src/typechain-typesV4/@aperture_finance/uni-v3-lib/src/interfaces/IPCSV3NonfungiblePositionManager.ts @@ -0,0 +1,1467 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../common"; + +export declare namespace ICommonNonfungiblePositionManager { + export type CollectParamsStruct = { + tokenId: BigNumberish; + recipient: string; + amount0Max: BigNumberish; + amount1Max: BigNumberish; + }; + + export type CollectParamsStructOutput = [ + BigNumber, + string, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + recipient: string; + amount0Max: BigNumber; + amount1Max: BigNumber; + }; + + export type DecreaseLiquidityParamsStruct = { + tokenId: BigNumberish; + liquidity: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + deadline: BigNumberish; + }; + + export type DecreaseLiquidityParamsStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + deadline: BigNumber; + }; + + export type IncreaseLiquidityParamsStruct = { + tokenId: BigNumberish; + amount0Desired: BigNumberish; + amount1Desired: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + deadline: BigNumberish; + }; + + export type IncreaseLiquidityParamsStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + amount0Desired: BigNumber; + amount1Desired: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + deadline: BigNumber; + }; +} + +export declare namespace IUniswapV3NonfungiblePositionManager { + export type MintParamsStruct = { + token0: string; + token1: string; + fee: BigNumberish; + tickLower: BigNumberish; + tickUpper: BigNumberish; + amount0Desired: BigNumberish; + amount1Desired: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + recipient: string; + deadline: BigNumberish; + }; + + export type MintParamsStructOutput = [ + string, + string, + number, + number, + number, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + string, + BigNumber + ] & { + token0: string; + token1: string; + fee: number; + tickLower: number; + tickUpper: number; + amount0Desired: BigNumber; + amount1Desired: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + recipient: string; + deadline: BigNumber; + }; +} + +export interface IPCSV3NonfungiblePositionManagerInterface + extends utils.Interface { + functions: { + "DOMAIN_SEPARATOR()": FunctionFragment; + "PERMIT_TYPEHASH()": FunctionFragment; + "WETH9()": FunctionFragment; + "approve(address,uint256)": FunctionFragment; + "balanceOf(address)": FunctionFragment; + "burn(uint256)": FunctionFragment; + "collect((uint256,address,uint128,uint128))": FunctionFragment; + "createAndInitializePoolIfNecessary(address,address,uint24,uint160)": FunctionFragment; + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256))": FunctionFragment; + "deployer()": FunctionFragment; + "factory()": FunctionFragment; + "getApproved(uint256)": FunctionFragment; + "increaseLiquidity((uint256,uint256,uint256,uint256,uint256,uint256))": FunctionFragment; + "isApprovedForAll(address,address)": FunctionFragment; + "mint((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256))": FunctionFragment; + "name()": FunctionFragment; + "ownerOf(uint256)": FunctionFragment; + "permit(address,uint256,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "positions(uint256)": FunctionFragment; + "refundETH()": FunctionFragment; + "safeTransferFrom(address,address,uint256)": FunctionFragment; + "safeTransferFrom(address,address,uint256,bytes)": FunctionFragment; + "setApprovalForAll(address,bool)": FunctionFragment; + "supportsInterface(bytes4)": FunctionFragment; + "sweepToken(address,uint256,address)": FunctionFragment; + "symbol()": FunctionFragment; + "tokenByIndex(uint256)": FunctionFragment; + "tokenOfOwnerByIndex(address,uint256)": FunctionFragment; + "tokenURI(uint256)": FunctionFragment; + "totalSupply()": FunctionFragment; + "transferFrom(address,address,uint256)": FunctionFragment; + "unwrapWETH9(uint256,address)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "DOMAIN_SEPARATOR" + | "PERMIT_TYPEHASH" + | "WETH9" + | "approve" + | "balanceOf" + | "burn" + | "collect" + | "createAndInitializePoolIfNecessary" + | "decreaseLiquidity" + | "deployer" + | "factory" + | "getApproved" + | "increaseLiquidity" + | "isApprovedForAll" + | "mint" + | "name" + | "ownerOf" + | "permit" + | "positions" + | "refundETH" + | "safeTransferFrom(address,address,uint256)" + | "safeTransferFrom(address,address,uint256,bytes)" + | "setApprovalForAll" + | "supportsInterface" + | "sweepToken" + | "symbol" + | "tokenByIndex" + | "tokenOfOwnerByIndex" + | "tokenURI" + | "totalSupply" + | "transferFrom" + | "unwrapWETH9" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "DOMAIN_SEPARATOR", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "PERMIT_TYPEHASH", + values?: undefined + ): string; + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData( + functionFragment: "approve", + values: [string, BigNumberish] + ): string; + encodeFunctionData(functionFragment: "balanceOf", values: [string]): string; + encodeFunctionData(functionFragment: "burn", values: [BigNumberish]): string; + encodeFunctionData( + functionFragment: "collect", + values: [ICommonNonfungiblePositionManager.CollectParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "createAndInitializePoolIfNecessary", + values: [string, string, BigNumberish, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidity", + values: [ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct] + ): string; + encodeFunctionData(functionFragment: "deployer", values?: undefined): string; + encodeFunctionData(functionFragment: "factory", values?: undefined): string; + encodeFunctionData( + functionFragment: "getApproved", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidity", + values: [ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "isApprovedForAll", + values: [string, string] + ): string; + encodeFunctionData( + functionFragment: "mint", + values: [IUniswapV3NonfungiblePositionManager.MintParamsStruct] + ): string; + encodeFunctionData(functionFragment: "name", values?: undefined): string; + encodeFunctionData( + functionFragment: "ownerOf", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "permit", + values: [ + string, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "positions", + values: [BigNumberish] + ): string; + encodeFunctionData(functionFragment: "refundETH", values?: undefined): string; + encodeFunctionData( + functionFragment: "safeTransferFrom(address,address,uint256)", + values: [string, string, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "safeTransferFrom(address,address,uint256,bytes)", + values: [string, string, BigNumberish, BytesLike] + ): string; + encodeFunctionData( + functionFragment: "setApprovalForAll", + values: [string, boolean] + ): string; + encodeFunctionData( + functionFragment: "supportsInterface", + values: [BytesLike] + ): string; + encodeFunctionData( + functionFragment: "sweepToken", + values: [string, BigNumberish, string] + ): string; + encodeFunctionData(functionFragment: "symbol", values?: undefined): string; + encodeFunctionData( + functionFragment: "tokenByIndex", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "tokenOfOwnerByIndex", + values: [string, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "tokenURI", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "totalSupply", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "transferFrom", + values: [string, string, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "unwrapWETH9", + values: [BigNumberish, string] + ): string; + + decodeFunctionResult( + functionFragment: "DOMAIN_SEPARATOR", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "PERMIT_TYPEHASH", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "approve", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "balanceOf", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "burn", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "collect", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "createAndInitializePoolIfNecessary", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidity", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "deployer", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "factory", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "getApproved", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidity", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "isApprovedForAll", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "mint", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "name", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "ownerOf", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "permit", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "positions", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "refundETH", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "safeTransferFrom(address,address,uint256)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "safeTransferFrom(address,address,uint256,bytes)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setApprovalForAll", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "supportsInterface", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "sweepToken", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "symbol", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "tokenByIndex", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "tokenOfOwnerByIndex", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "tokenURI", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "totalSupply", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "transferFrom", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "unwrapWETH9", + data: BytesLike + ): Result; + + events: { + "Approval(address,address,uint256)": EventFragment; + "ApprovalForAll(address,address,bool)": EventFragment; + "Collect(uint256,address,uint256,uint256)": EventFragment; + "DecreaseLiquidity(uint256,uint128,uint256,uint256)": EventFragment; + "IncreaseLiquidity(uint256,uint128,uint256,uint256)": EventFragment; + "Transfer(address,address,uint256)": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "Approval"): EventFragment; + getEvent(nameOrSignatureOrTopic: "ApprovalForAll"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Collect"): EventFragment; + getEvent(nameOrSignatureOrTopic: "DecreaseLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "IncreaseLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Transfer"): EventFragment; +} + +export interface ApprovalEventObject { + owner: string; + approved: string; + tokenId: BigNumber; +} +export type ApprovalEvent = TypedEvent< + [string, string, BigNumber], + ApprovalEventObject +>; + +export type ApprovalEventFilter = TypedEventFilter; + +export interface ApprovalForAllEventObject { + owner: string; + operator: string; + approved: boolean; +} +export type ApprovalForAllEvent = TypedEvent< + [string, string, boolean], + ApprovalForAllEventObject +>; + +export type ApprovalForAllEventFilter = TypedEventFilter; + +export interface CollectEventObject { + tokenId: BigNumber; + recipient: string; + amount0: BigNumber; + amount1: BigNumber; +} +export type CollectEvent = TypedEvent< + [BigNumber, string, BigNumber, BigNumber], + CollectEventObject +>; + +export type CollectEventFilter = TypedEventFilter; + +export interface DecreaseLiquidityEventObject { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; +} +export type DecreaseLiquidityEvent = TypedEvent< + [BigNumber, BigNumber, BigNumber, BigNumber], + DecreaseLiquidityEventObject +>; + +export type DecreaseLiquidityEventFilter = + TypedEventFilter; + +export interface IncreaseLiquidityEventObject { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; +} +export type IncreaseLiquidityEvent = TypedEvent< + [BigNumber, BigNumber, BigNumber, BigNumber], + IncreaseLiquidityEventObject +>; + +export type IncreaseLiquidityEventFilter = + TypedEventFilter; + +export interface TransferEventObject { + from: string; + to: string; + tokenId: BigNumber; +} +export type TransferEvent = TypedEvent< + [string, string, BigNumber], + TransferEventObject +>; + +export type TransferEventFilter = TypedEventFilter; + +export interface IPCSV3NonfungiblePositionManager extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IPCSV3NonfungiblePositionManagerInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise<[string]>; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise<[string]>; + + WETH9(overrides?: CallOverrides): Promise<[string]>; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf( + owner: string, + overrides?: CallOverrides + ): Promise<[BigNumber] & { balance: BigNumber }>; + + burn( + tokenId: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + collect( + params: ICommonNonfungiblePositionManager.CollectParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + createAndInitializePoolIfNecessary( + token0: string, + token1: string, + fee: BigNumberish, + sqrtPriceX96: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + decreaseLiquidity( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + deployer(overrides?: CallOverrides): Promise<[string]>; + + factory(overrides?: CallOverrides): Promise<[string]>; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise<[string] & { operator: string }>; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise<[boolean]>; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + name(overrides?: CallOverrides): Promise<[string]>; + + ownerOf( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise<[string] & { owner: string }>; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + positions( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise< + [ + BigNumber, + string, + string, + string, + number, + number, + number, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + nonce: BigNumber; + operator: string; + token0: string; + token1: string; + fee: number; + tickLower: number; + tickUpper: number; + liquidity: BigNumber; + feeGrowthInside0LastX128: BigNumber; + feeGrowthInside1LastX128: BigNumber; + tokensOwed0: BigNumber; + tokensOwed1: BigNumber; + } + >; + + refundETH( + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise<[boolean]>; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + symbol(overrides?: CallOverrides): Promise<[string]>; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise<[BigNumber]>; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise<[BigNumber]>; + + tokenURI( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise<[string]>; + + totalSupply(overrides?: CallOverrides): Promise<[BigNumber]>; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + }; + + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise; + + WETH9(overrides?: CallOverrides): Promise; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + burn( + tokenId: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + collect( + params: ICommonNonfungiblePositionManager.CollectParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + createAndInitializePoolIfNecessary( + token0: string, + token1: string, + fee: BigNumberish, + sqrtPriceX96: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + decreaseLiquidity( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + deployer(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + name(overrides?: CallOverrides): Promise; + + ownerOf(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + positions( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise< + [ + BigNumber, + string, + string, + string, + number, + number, + number, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + nonce: BigNumber; + operator: string; + token0: string; + token1: string; + fee: number; + tickLower: number; + tickUpper: number; + liquidity: BigNumber; + feeGrowthInside0LastX128: BigNumber; + feeGrowthInside1LastX128: BigNumber; + tokensOwed0: BigNumber; + tokensOwed1: BigNumber; + } + >; + + refundETH( + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenURI(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + callStatic: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise; + + WETH9(overrides?: CallOverrides): Promise; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + burn(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + collect( + params: ICommonNonfungiblePositionManager.CollectParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + createAndInitializePoolIfNecessary( + token0: string, + token1: string, + fee: BigNumberish, + sqrtPriceX96: BigNumberish, + overrides?: CallOverrides + ): Promise; + + decreaseLiquidity( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + deployer(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + name(overrides?: CallOverrides): Promise; + + ownerOf(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise; + + positions( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise< + [ + BigNumber, + string, + string, + string, + number, + number, + number, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + nonce: BigNumber; + operator: string; + token0: string; + token1: string; + fee: number; + tickLower: number; + tickUpper: number; + liquidity: BigNumber; + feeGrowthInside0LastX128: BigNumber; + feeGrowthInside1LastX128: BigNumber; + tokensOwed0: BigNumber; + tokensOwed1: BigNumber; + } + >; + + refundETH(overrides?: CallOverrides): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: CallOverrides + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: CallOverrides + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenURI(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "Approval(address,address,uint256)"( + owner?: string | null, + approved?: string | null, + tokenId?: BigNumberish | null + ): ApprovalEventFilter; + Approval( + owner?: string | null, + approved?: string | null, + tokenId?: BigNumberish | null + ): ApprovalEventFilter; + + "ApprovalForAll(address,address,bool)"( + owner?: string | null, + operator?: string | null, + approved?: null + ): ApprovalForAllEventFilter; + ApprovalForAll( + owner?: string | null, + operator?: string | null, + approved?: null + ): ApprovalForAllEventFilter; + + "Collect(uint256,address,uint256,uint256)"( + tokenId?: BigNumberish | null, + recipient?: null, + amount0?: null, + amount1?: null + ): CollectEventFilter; + Collect( + tokenId?: BigNumberish | null, + recipient?: null, + amount0?: null, + amount1?: null + ): CollectEventFilter; + + "DecreaseLiquidity(uint256,uint128,uint256,uint256)"( + tokenId?: BigNumberish | null, + liquidity?: null, + amount0?: null, + amount1?: null + ): DecreaseLiquidityEventFilter; + DecreaseLiquidity( + tokenId?: BigNumberish | null, + liquidity?: null, + amount0?: null, + amount1?: null + ): DecreaseLiquidityEventFilter; + + "IncreaseLiquidity(uint256,uint128,uint256,uint256)"( + tokenId?: BigNumberish | null, + liquidity?: null, + amount0?: null, + amount1?: null + ): IncreaseLiquidityEventFilter; + IncreaseLiquidity( + tokenId?: BigNumberish | null, + liquidity?: null, + amount0?: null, + amount1?: null + ): IncreaseLiquidityEventFilter; + + "Transfer(address,address,uint256)"( + from?: string | null, + to?: string | null, + tokenId?: BigNumberish | null + ): TransferEventFilter; + Transfer( + from?: string | null, + to?: string | null, + tokenId?: BigNumberish | null + ): TransferEventFilter; + }; + + estimateGas: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise; + + WETH9(overrides?: CallOverrides): Promise; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + burn( + tokenId: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + collect( + params: ICommonNonfungiblePositionManager.CollectParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + createAndInitializePoolIfNecessary( + token0: string, + token1: string, + fee: BigNumberish, + sqrtPriceX96: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + decreaseLiquidity( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + deployer(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + name(overrides?: CallOverrides): Promise; + + ownerOf( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + positions( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + refundETH( + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenURI( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise; + + WETH9(overrides?: CallOverrides): Promise; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf( + owner: string, + overrides?: CallOverrides + ): Promise; + + burn( + tokenId: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + collect( + params: ICommonNonfungiblePositionManager.CollectParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + createAndInitializePoolIfNecessary( + token0: string, + token1: string, + fee: BigNumberish, + sqrtPriceX96: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + decreaseLiquidity( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + deployer(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + name(overrides?: CallOverrides): Promise; + + ownerOf( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + positions( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + refundETH( + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenURI( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/@aperture_finance/uni-v3-lib/src/interfaces/ISlipStreamNonfungiblePositionManager.ts b/src/typechain-typesV4/@aperture_finance/uni-v3-lib/src/interfaces/ISlipStreamNonfungiblePositionManager.ts new file mode 100644 index 00000000..b63d492a --- /dev/null +++ b/src/typechain-typesV4/@aperture_finance/uni-v3-lib/src/interfaces/ISlipStreamNonfungiblePositionManager.ts @@ -0,0 +1,1539 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../common"; + +export declare namespace ICommonNonfungiblePositionManager { + export type CollectParamsStruct = { + tokenId: BigNumberish; + recipient: string; + amount0Max: BigNumberish; + amount1Max: BigNumberish; + }; + + export type CollectParamsStructOutput = [ + BigNumber, + string, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + recipient: string; + amount0Max: BigNumber; + amount1Max: BigNumber; + }; + + export type DecreaseLiquidityParamsStruct = { + tokenId: BigNumberish; + liquidity: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + deadline: BigNumberish; + }; + + export type DecreaseLiquidityParamsStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + deadline: BigNumber; + }; + + export type IncreaseLiquidityParamsStruct = { + tokenId: BigNumberish; + amount0Desired: BigNumberish; + amount1Desired: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + deadline: BigNumberish; + }; + + export type IncreaseLiquidityParamsStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + amount0Desired: BigNumber; + amount1Desired: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + deadline: BigNumber; + }; +} + +export declare namespace ISlipStreamNonfungiblePositionManager { + export type MintParamsStruct = { + token0: string; + token1: string; + tickSpacing: BigNumberish; + tickLower: BigNumberish; + tickUpper: BigNumberish; + amount0Desired: BigNumberish; + amount1Desired: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + recipient: string; + deadline: BigNumberish; + sqrtPriceX96: BigNumberish; + }; + + export type MintParamsStructOutput = [ + string, + string, + number, + number, + number, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + string, + BigNumber, + BigNumber + ] & { + token0: string; + token1: string; + tickSpacing: number; + tickLower: number; + tickUpper: number; + amount0Desired: BigNumber; + amount1Desired: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + recipient: string; + deadline: BigNumber; + sqrtPriceX96: BigNumber; + }; +} + +export interface ISlipStreamNonfungiblePositionManagerInterface + extends utils.Interface { + functions: { + "DOMAIN_SEPARATOR()": FunctionFragment; + "PERMIT_TYPEHASH()": FunctionFragment; + "WETH9()": FunctionFragment; + "approve(address,uint256)": FunctionFragment; + "balanceOf(address)": FunctionFragment; + "burn(uint256)": FunctionFragment; + "collect((uint256,address,uint128,uint128))": FunctionFragment; + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256))": FunctionFragment; + "factory()": FunctionFragment; + "getApproved(uint256)": FunctionFragment; + "increaseLiquidity((uint256,uint256,uint256,uint256,uint256,uint256))": FunctionFragment; + "isApprovedForAll(address,address)": FunctionFragment; + "mint((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160))": FunctionFragment; + "name()": FunctionFragment; + "owner()": FunctionFragment; + "ownerOf(uint256)": FunctionFragment; + "permit(address,uint256,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "positions(uint256)": FunctionFragment; + "refundETH()": FunctionFragment; + "safeTransferFrom(address,address,uint256)": FunctionFragment; + "safeTransferFrom(address,address,uint256,bytes)": FunctionFragment; + "setApprovalForAll(address,bool)": FunctionFragment; + "setOwner(address)": FunctionFragment; + "setTokenDescriptor(address)": FunctionFragment; + "supportsInterface(bytes4)": FunctionFragment; + "sweepToken(address,uint256,address)": FunctionFragment; + "symbol()": FunctionFragment; + "tokenByIndex(uint256)": FunctionFragment; + "tokenDescriptor()": FunctionFragment; + "tokenOfOwnerByIndex(address,uint256)": FunctionFragment; + "tokenURI(uint256)": FunctionFragment; + "totalSupply()": FunctionFragment; + "transferFrom(address,address,uint256)": FunctionFragment; + "unwrapWETH9(uint256,address)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "DOMAIN_SEPARATOR" + | "PERMIT_TYPEHASH" + | "WETH9" + | "approve" + | "balanceOf" + | "burn" + | "collect" + | "decreaseLiquidity" + | "factory" + | "getApproved" + | "increaseLiquidity" + | "isApprovedForAll" + | "mint" + | "name" + | "owner" + | "ownerOf" + | "permit" + | "positions" + | "refundETH" + | "safeTransferFrom(address,address,uint256)" + | "safeTransferFrom(address,address,uint256,bytes)" + | "setApprovalForAll" + | "setOwner" + | "setTokenDescriptor" + | "supportsInterface" + | "sweepToken" + | "symbol" + | "tokenByIndex" + | "tokenDescriptor" + | "tokenOfOwnerByIndex" + | "tokenURI" + | "totalSupply" + | "transferFrom" + | "unwrapWETH9" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "DOMAIN_SEPARATOR", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "PERMIT_TYPEHASH", + values?: undefined + ): string; + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData( + functionFragment: "approve", + values: [string, BigNumberish] + ): string; + encodeFunctionData(functionFragment: "balanceOf", values: [string]): string; + encodeFunctionData(functionFragment: "burn", values: [BigNumberish]): string; + encodeFunctionData( + functionFragment: "collect", + values: [ICommonNonfungiblePositionManager.CollectParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidity", + values: [ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct] + ): string; + encodeFunctionData(functionFragment: "factory", values?: undefined): string; + encodeFunctionData( + functionFragment: "getApproved", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidity", + values: [ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "isApprovedForAll", + values: [string, string] + ): string; + encodeFunctionData( + functionFragment: "mint", + values: [ISlipStreamNonfungiblePositionManager.MintParamsStruct] + ): string; + encodeFunctionData(functionFragment: "name", values?: undefined): string; + encodeFunctionData(functionFragment: "owner", values?: undefined): string; + encodeFunctionData( + functionFragment: "ownerOf", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "permit", + values: [ + string, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "positions", + values: [BigNumberish] + ): string; + encodeFunctionData(functionFragment: "refundETH", values?: undefined): string; + encodeFunctionData( + functionFragment: "safeTransferFrom(address,address,uint256)", + values: [string, string, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "safeTransferFrom(address,address,uint256,bytes)", + values: [string, string, BigNumberish, BytesLike] + ): string; + encodeFunctionData( + functionFragment: "setApprovalForAll", + values: [string, boolean] + ): string; + encodeFunctionData(functionFragment: "setOwner", values: [string]): string; + encodeFunctionData( + functionFragment: "setTokenDescriptor", + values: [string] + ): string; + encodeFunctionData( + functionFragment: "supportsInterface", + values: [BytesLike] + ): string; + encodeFunctionData( + functionFragment: "sweepToken", + values: [string, BigNumberish, string] + ): string; + encodeFunctionData(functionFragment: "symbol", values?: undefined): string; + encodeFunctionData( + functionFragment: "tokenByIndex", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "tokenDescriptor", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "tokenOfOwnerByIndex", + values: [string, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "tokenURI", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "totalSupply", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "transferFrom", + values: [string, string, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "unwrapWETH9", + values: [BigNumberish, string] + ): string; + + decodeFunctionResult( + functionFragment: "DOMAIN_SEPARATOR", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "PERMIT_TYPEHASH", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "approve", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "balanceOf", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "burn", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "collect", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidity", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "factory", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "getApproved", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidity", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "isApprovedForAll", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "mint", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "name", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "owner", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "ownerOf", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "permit", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "positions", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "refundETH", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "safeTransferFrom(address,address,uint256)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "safeTransferFrom(address,address,uint256,bytes)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setApprovalForAll", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "setOwner", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "setTokenDescriptor", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "supportsInterface", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "sweepToken", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "symbol", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "tokenByIndex", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "tokenDescriptor", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "tokenOfOwnerByIndex", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "tokenURI", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "totalSupply", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "transferFrom", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "unwrapWETH9", + data: BytesLike + ): Result; + + events: { + "Approval(address,address,uint256)": EventFragment; + "ApprovalForAll(address,address,bool)": EventFragment; + "Collect(uint256,address,uint256,uint256)": EventFragment; + "DecreaseLiquidity(uint256,uint128,uint256,uint256)": EventFragment; + "IncreaseLiquidity(uint256,uint128,uint256,uint256)": EventFragment; + "TokenDescriptorChanged(address)": EventFragment; + "Transfer(address,address,uint256)": EventFragment; + "TransferOwnership(address)": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "Approval"): EventFragment; + getEvent(nameOrSignatureOrTopic: "ApprovalForAll"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Collect"): EventFragment; + getEvent(nameOrSignatureOrTopic: "DecreaseLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "IncreaseLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "TokenDescriptorChanged"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Transfer"): EventFragment; + getEvent(nameOrSignatureOrTopic: "TransferOwnership"): EventFragment; +} + +export interface ApprovalEventObject { + owner: string; + approved: string; + tokenId: BigNumber; +} +export type ApprovalEvent = TypedEvent< + [string, string, BigNumber], + ApprovalEventObject +>; + +export type ApprovalEventFilter = TypedEventFilter; + +export interface ApprovalForAllEventObject { + owner: string; + operator: string; + approved: boolean; +} +export type ApprovalForAllEvent = TypedEvent< + [string, string, boolean], + ApprovalForAllEventObject +>; + +export type ApprovalForAllEventFilter = TypedEventFilter; + +export interface CollectEventObject { + tokenId: BigNumber; + recipient: string; + amount0: BigNumber; + amount1: BigNumber; +} +export type CollectEvent = TypedEvent< + [BigNumber, string, BigNumber, BigNumber], + CollectEventObject +>; + +export type CollectEventFilter = TypedEventFilter; + +export interface DecreaseLiquidityEventObject { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; +} +export type DecreaseLiquidityEvent = TypedEvent< + [BigNumber, BigNumber, BigNumber, BigNumber], + DecreaseLiquidityEventObject +>; + +export type DecreaseLiquidityEventFilter = + TypedEventFilter; + +export interface IncreaseLiquidityEventObject { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; +} +export type IncreaseLiquidityEvent = TypedEvent< + [BigNumber, BigNumber, BigNumber, BigNumber], + IncreaseLiquidityEventObject +>; + +export type IncreaseLiquidityEventFilter = + TypedEventFilter; + +export interface TokenDescriptorChangedEventObject { + tokenDescriptor: string; +} +export type TokenDescriptorChangedEvent = TypedEvent< + [string], + TokenDescriptorChangedEventObject +>; + +export type TokenDescriptorChangedEventFilter = + TypedEventFilter; + +export interface TransferEventObject { + from: string; + to: string; + tokenId: BigNumber; +} +export type TransferEvent = TypedEvent< + [string, string, BigNumber], + TransferEventObject +>; + +export type TransferEventFilter = TypedEventFilter; + +export interface TransferOwnershipEventObject { + owner: string; +} +export type TransferOwnershipEvent = TypedEvent< + [string], + TransferOwnershipEventObject +>; + +export type TransferOwnershipEventFilter = + TypedEventFilter; + +export interface ISlipStreamNonfungiblePositionManager extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: ISlipStreamNonfungiblePositionManagerInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise<[string]>; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise<[string]>; + + WETH9(overrides?: CallOverrides): Promise<[string]>; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf( + owner: string, + overrides?: CallOverrides + ): Promise<[BigNumber] & { balance: BigNumber }>; + + burn( + tokenId: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + collect( + params: ICommonNonfungiblePositionManager.CollectParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + decreaseLiquidity( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise<[string]>; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise<[string] & { operator: string }>; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise<[boolean]>; + + mint( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + name(overrides?: CallOverrides): Promise<[string]>; + + owner(overrides?: CallOverrides): Promise<[string]>; + + ownerOf( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise<[string] & { owner: string }>; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + positions( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise< + [ + BigNumber, + string, + string, + string, + number, + number, + number, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + nonce: BigNumber; + operator: string; + token0: string; + token1: string; + tickSpacing: number; + tickLower: number; + tickUpper: number; + liquidity: BigNumber; + feeGrowthInside0LastX128: BigNumber; + feeGrowthInside1LastX128: BigNumber; + tokensOwed0: BigNumber; + tokensOwed1: BigNumber; + } + >; + + refundETH( + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + setOwner( + _owner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + setTokenDescriptor( + _tokenDescriptor: string, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise<[boolean]>; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + symbol(overrides?: CallOverrides): Promise<[string]>; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise<[BigNumber]>; + + tokenDescriptor(overrides?: CallOverrides): Promise<[string]>; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise<[BigNumber]>; + + tokenURI( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise<[string]>; + + totalSupply(overrides?: CallOverrides): Promise<[BigNumber]>; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + }; + + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise; + + WETH9(overrides?: CallOverrides): Promise; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + burn( + tokenId: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + collect( + params: ICommonNonfungiblePositionManager.CollectParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + decreaseLiquidity( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + name(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + ownerOf(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + positions( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise< + [ + BigNumber, + string, + string, + string, + number, + number, + number, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + nonce: BigNumber; + operator: string; + token0: string; + token1: string; + tickSpacing: number; + tickLower: number; + tickUpper: number; + liquidity: BigNumber; + feeGrowthInside0LastX128: BigNumber; + feeGrowthInside1LastX128: BigNumber; + tokensOwed0: BigNumber; + tokensOwed1: BigNumber; + } + >; + + refundETH( + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + setOwner( + _owner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + setTokenDescriptor( + _tokenDescriptor: string, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenDescriptor(overrides?: CallOverrides): Promise; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenURI(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + callStatic: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise; + + WETH9(overrides?: CallOverrides): Promise; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + burn(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + collect( + params: ICommonNonfungiblePositionManager.CollectParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + decreaseLiquidity( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + factory(overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + name(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + ownerOf(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise; + + positions( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise< + [ + BigNumber, + string, + string, + string, + number, + number, + number, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + nonce: BigNumber; + operator: string; + token0: string; + token1: string; + tickSpacing: number; + tickLower: number; + tickUpper: number; + liquidity: BigNumber; + feeGrowthInside0LastX128: BigNumber; + feeGrowthInside1LastX128: BigNumber; + tokensOwed0: BigNumber; + tokensOwed1: BigNumber; + } + >; + + refundETH(overrides?: CallOverrides): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: CallOverrides + ): Promise; + + setOwner(_owner: string, overrides?: CallOverrides): Promise; + + setTokenDescriptor( + _tokenDescriptor: string, + overrides?: CallOverrides + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: CallOverrides + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenDescriptor(overrides?: CallOverrides): Promise; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenURI(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "Approval(address,address,uint256)"( + owner?: string | null, + approved?: string | null, + tokenId?: BigNumberish | null + ): ApprovalEventFilter; + Approval( + owner?: string | null, + approved?: string | null, + tokenId?: BigNumberish | null + ): ApprovalEventFilter; + + "ApprovalForAll(address,address,bool)"( + owner?: string | null, + operator?: string | null, + approved?: null + ): ApprovalForAllEventFilter; + ApprovalForAll( + owner?: string | null, + operator?: string | null, + approved?: null + ): ApprovalForAllEventFilter; + + "Collect(uint256,address,uint256,uint256)"( + tokenId?: BigNumberish | null, + recipient?: null, + amount0?: null, + amount1?: null + ): CollectEventFilter; + Collect( + tokenId?: BigNumberish | null, + recipient?: null, + amount0?: null, + amount1?: null + ): CollectEventFilter; + + "DecreaseLiquidity(uint256,uint128,uint256,uint256)"( + tokenId?: BigNumberish | null, + liquidity?: null, + amount0?: null, + amount1?: null + ): DecreaseLiquidityEventFilter; + DecreaseLiquidity( + tokenId?: BigNumberish | null, + liquidity?: null, + amount0?: null, + amount1?: null + ): DecreaseLiquidityEventFilter; + + "IncreaseLiquidity(uint256,uint128,uint256,uint256)"( + tokenId?: BigNumberish | null, + liquidity?: null, + amount0?: null, + amount1?: null + ): IncreaseLiquidityEventFilter; + IncreaseLiquidity( + tokenId?: BigNumberish | null, + liquidity?: null, + amount0?: null, + amount1?: null + ): IncreaseLiquidityEventFilter; + + "TokenDescriptorChanged(address)"( + tokenDescriptor?: string | null + ): TokenDescriptorChangedEventFilter; + TokenDescriptorChanged( + tokenDescriptor?: string | null + ): TokenDescriptorChangedEventFilter; + + "Transfer(address,address,uint256)"( + from?: string | null, + to?: string | null, + tokenId?: BigNumberish | null + ): TransferEventFilter; + Transfer( + from?: string | null, + to?: string | null, + tokenId?: BigNumberish | null + ): TransferEventFilter; + + "TransferOwnership(address)"( + owner?: string | null + ): TransferOwnershipEventFilter; + TransferOwnership(owner?: string | null): TransferOwnershipEventFilter; + }; + + estimateGas: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise; + + WETH9(overrides?: CallOverrides): Promise; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + burn( + tokenId: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + collect( + params: ICommonNonfungiblePositionManager.CollectParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + decreaseLiquidity( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + name(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + ownerOf( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + positions( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + refundETH( + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + setOwner( + _owner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + setTokenDescriptor( + _tokenDescriptor: string, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenDescriptor(overrides?: CallOverrides): Promise; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenURI( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise; + + WETH9(overrides?: CallOverrides): Promise; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf( + owner: string, + overrides?: CallOverrides + ): Promise; + + burn( + tokenId: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + collect( + params: ICommonNonfungiblePositionManager.CollectParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + decreaseLiquidity( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + name(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + ownerOf( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + positions( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + refundETH( + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + setOwner( + _owner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + setTokenDescriptor( + _tokenDescriptor: string, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenDescriptor(overrides?: CallOverrides): Promise; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenURI( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/@aperture_finance/uni-v3-lib/src/interfaces/IUniswapV3NonfungiblePositionManager.ts b/src/typechain-typesV4/@aperture_finance/uni-v3-lib/src/interfaces/IUniswapV3NonfungiblePositionManager.ts new file mode 100644 index 00000000..ffbe3bc1 --- /dev/null +++ b/src/typechain-typesV4/@aperture_finance/uni-v3-lib/src/interfaces/IUniswapV3NonfungiblePositionManager.ts @@ -0,0 +1,1453 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../common"; + +export declare namespace ICommonNonfungiblePositionManager { + export type CollectParamsStruct = { + tokenId: BigNumberish; + recipient: string; + amount0Max: BigNumberish; + amount1Max: BigNumberish; + }; + + export type CollectParamsStructOutput = [ + BigNumber, + string, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + recipient: string; + amount0Max: BigNumber; + amount1Max: BigNumber; + }; + + export type DecreaseLiquidityParamsStruct = { + tokenId: BigNumberish; + liquidity: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + deadline: BigNumberish; + }; + + export type DecreaseLiquidityParamsStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + deadline: BigNumber; + }; + + export type IncreaseLiquidityParamsStruct = { + tokenId: BigNumberish; + amount0Desired: BigNumberish; + amount1Desired: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + deadline: BigNumberish; + }; + + export type IncreaseLiquidityParamsStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + amount0Desired: BigNumber; + amount1Desired: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + deadline: BigNumber; + }; +} + +export declare namespace IUniswapV3NonfungiblePositionManager { + export type MintParamsStruct = { + token0: string; + token1: string; + fee: BigNumberish; + tickLower: BigNumberish; + tickUpper: BigNumberish; + amount0Desired: BigNumberish; + amount1Desired: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + recipient: string; + deadline: BigNumberish; + }; + + export type MintParamsStructOutput = [ + string, + string, + number, + number, + number, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + string, + BigNumber + ] & { + token0: string; + token1: string; + fee: number; + tickLower: number; + tickUpper: number; + amount0Desired: BigNumber; + amount1Desired: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + recipient: string; + deadline: BigNumber; + }; +} + +export interface IUniswapV3NonfungiblePositionManagerInterface + extends utils.Interface { + functions: { + "DOMAIN_SEPARATOR()": FunctionFragment; + "PERMIT_TYPEHASH()": FunctionFragment; + "WETH9()": FunctionFragment; + "approve(address,uint256)": FunctionFragment; + "balanceOf(address)": FunctionFragment; + "burn(uint256)": FunctionFragment; + "collect((uint256,address,uint128,uint128))": FunctionFragment; + "createAndInitializePoolIfNecessary(address,address,uint24,uint160)": FunctionFragment; + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256))": FunctionFragment; + "factory()": FunctionFragment; + "getApproved(uint256)": FunctionFragment; + "increaseLiquidity((uint256,uint256,uint256,uint256,uint256,uint256))": FunctionFragment; + "isApprovedForAll(address,address)": FunctionFragment; + "mint((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256))": FunctionFragment; + "name()": FunctionFragment; + "ownerOf(uint256)": FunctionFragment; + "permit(address,uint256,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "positions(uint256)": FunctionFragment; + "refundETH()": FunctionFragment; + "safeTransferFrom(address,address,uint256)": FunctionFragment; + "safeTransferFrom(address,address,uint256,bytes)": FunctionFragment; + "setApprovalForAll(address,bool)": FunctionFragment; + "supportsInterface(bytes4)": FunctionFragment; + "sweepToken(address,uint256,address)": FunctionFragment; + "symbol()": FunctionFragment; + "tokenByIndex(uint256)": FunctionFragment; + "tokenOfOwnerByIndex(address,uint256)": FunctionFragment; + "tokenURI(uint256)": FunctionFragment; + "totalSupply()": FunctionFragment; + "transferFrom(address,address,uint256)": FunctionFragment; + "unwrapWETH9(uint256,address)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "DOMAIN_SEPARATOR" + | "PERMIT_TYPEHASH" + | "WETH9" + | "approve" + | "balanceOf" + | "burn" + | "collect" + | "createAndInitializePoolIfNecessary" + | "decreaseLiquidity" + | "factory" + | "getApproved" + | "increaseLiquidity" + | "isApprovedForAll" + | "mint" + | "name" + | "ownerOf" + | "permit" + | "positions" + | "refundETH" + | "safeTransferFrom(address,address,uint256)" + | "safeTransferFrom(address,address,uint256,bytes)" + | "setApprovalForAll" + | "supportsInterface" + | "sweepToken" + | "symbol" + | "tokenByIndex" + | "tokenOfOwnerByIndex" + | "tokenURI" + | "totalSupply" + | "transferFrom" + | "unwrapWETH9" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "DOMAIN_SEPARATOR", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "PERMIT_TYPEHASH", + values?: undefined + ): string; + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData( + functionFragment: "approve", + values: [string, BigNumberish] + ): string; + encodeFunctionData(functionFragment: "balanceOf", values: [string]): string; + encodeFunctionData(functionFragment: "burn", values: [BigNumberish]): string; + encodeFunctionData( + functionFragment: "collect", + values: [ICommonNonfungiblePositionManager.CollectParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "createAndInitializePoolIfNecessary", + values: [string, string, BigNumberish, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidity", + values: [ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct] + ): string; + encodeFunctionData(functionFragment: "factory", values?: undefined): string; + encodeFunctionData( + functionFragment: "getApproved", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidity", + values: [ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "isApprovedForAll", + values: [string, string] + ): string; + encodeFunctionData( + functionFragment: "mint", + values: [IUniswapV3NonfungiblePositionManager.MintParamsStruct] + ): string; + encodeFunctionData(functionFragment: "name", values?: undefined): string; + encodeFunctionData( + functionFragment: "ownerOf", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "permit", + values: [ + string, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "positions", + values: [BigNumberish] + ): string; + encodeFunctionData(functionFragment: "refundETH", values?: undefined): string; + encodeFunctionData( + functionFragment: "safeTransferFrom(address,address,uint256)", + values: [string, string, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "safeTransferFrom(address,address,uint256,bytes)", + values: [string, string, BigNumberish, BytesLike] + ): string; + encodeFunctionData( + functionFragment: "setApprovalForAll", + values: [string, boolean] + ): string; + encodeFunctionData( + functionFragment: "supportsInterface", + values: [BytesLike] + ): string; + encodeFunctionData( + functionFragment: "sweepToken", + values: [string, BigNumberish, string] + ): string; + encodeFunctionData(functionFragment: "symbol", values?: undefined): string; + encodeFunctionData( + functionFragment: "tokenByIndex", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "tokenOfOwnerByIndex", + values: [string, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "tokenURI", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "totalSupply", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "transferFrom", + values: [string, string, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "unwrapWETH9", + values: [BigNumberish, string] + ): string; + + decodeFunctionResult( + functionFragment: "DOMAIN_SEPARATOR", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "PERMIT_TYPEHASH", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "approve", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "balanceOf", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "burn", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "collect", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "createAndInitializePoolIfNecessary", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidity", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "factory", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "getApproved", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidity", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "isApprovedForAll", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "mint", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "name", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "ownerOf", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "permit", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "positions", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "refundETH", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "safeTransferFrom(address,address,uint256)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "safeTransferFrom(address,address,uint256,bytes)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setApprovalForAll", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "supportsInterface", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "sweepToken", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "symbol", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "tokenByIndex", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "tokenOfOwnerByIndex", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "tokenURI", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "totalSupply", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "transferFrom", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "unwrapWETH9", + data: BytesLike + ): Result; + + events: { + "Approval(address,address,uint256)": EventFragment; + "ApprovalForAll(address,address,bool)": EventFragment; + "Collect(uint256,address,uint256,uint256)": EventFragment; + "DecreaseLiquidity(uint256,uint128,uint256,uint256)": EventFragment; + "IncreaseLiquidity(uint256,uint128,uint256,uint256)": EventFragment; + "Transfer(address,address,uint256)": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "Approval"): EventFragment; + getEvent(nameOrSignatureOrTopic: "ApprovalForAll"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Collect"): EventFragment; + getEvent(nameOrSignatureOrTopic: "DecreaseLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "IncreaseLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Transfer"): EventFragment; +} + +export interface ApprovalEventObject { + owner: string; + approved: string; + tokenId: BigNumber; +} +export type ApprovalEvent = TypedEvent< + [string, string, BigNumber], + ApprovalEventObject +>; + +export type ApprovalEventFilter = TypedEventFilter; + +export interface ApprovalForAllEventObject { + owner: string; + operator: string; + approved: boolean; +} +export type ApprovalForAllEvent = TypedEvent< + [string, string, boolean], + ApprovalForAllEventObject +>; + +export type ApprovalForAllEventFilter = TypedEventFilter; + +export interface CollectEventObject { + tokenId: BigNumber; + recipient: string; + amount0: BigNumber; + amount1: BigNumber; +} +export type CollectEvent = TypedEvent< + [BigNumber, string, BigNumber, BigNumber], + CollectEventObject +>; + +export type CollectEventFilter = TypedEventFilter; + +export interface DecreaseLiquidityEventObject { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; +} +export type DecreaseLiquidityEvent = TypedEvent< + [BigNumber, BigNumber, BigNumber, BigNumber], + DecreaseLiquidityEventObject +>; + +export type DecreaseLiquidityEventFilter = + TypedEventFilter; + +export interface IncreaseLiquidityEventObject { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; +} +export type IncreaseLiquidityEvent = TypedEvent< + [BigNumber, BigNumber, BigNumber, BigNumber], + IncreaseLiquidityEventObject +>; + +export type IncreaseLiquidityEventFilter = + TypedEventFilter; + +export interface TransferEventObject { + from: string; + to: string; + tokenId: BigNumber; +} +export type TransferEvent = TypedEvent< + [string, string, BigNumber], + TransferEventObject +>; + +export type TransferEventFilter = TypedEventFilter; + +export interface IUniswapV3NonfungiblePositionManager extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IUniswapV3NonfungiblePositionManagerInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise<[string]>; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise<[string]>; + + WETH9(overrides?: CallOverrides): Promise<[string]>; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf( + owner: string, + overrides?: CallOverrides + ): Promise<[BigNumber] & { balance: BigNumber }>; + + burn( + tokenId: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + collect( + params: ICommonNonfungiblePositionManager.CollectParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + createAndInitializePoolIfNecessary( + token0: string, + token1: string, + fee: BigNumberish, + sqrtPriceX96: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + decreaseLiquidity( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise<[string]>; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise<[string] & { operator: string }>; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise<[boolean]>; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + name(overrides?: CallOverrides): Promise<[string]>; + + ownerOf( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise<[string] & { owner: string }>; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + positions( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise< + [ + BigNumber, + string, + string, + string, + number, + number, + number, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + nonce: BigNumber; + operator: string; + token0: string; + token1: string; + fee: number; + tickLower: number; + tickUpper: number; + liquidity: BigNumber; + feeGrowthInside0LastX128: BigNumber; + feeGrowthInside1LastX128: BigNumber; + tokensOwed0: BigNumber; + tokensOwed1: BigNumber; + } + >; + + refundETH( + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise<[boolean]>; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + symbol(overrides?: CallOverrides): Promise<[string]>; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise<[BigNumber]>; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise<[BigNumber]>; + + tokenURI( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise<[string]>; + + totalSupply(overrides?: CallOverrides): Promise<[BigNumber]>; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + }; + + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise; + + WETH9(overrides?: CallOverrides): Promise; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + burn( + tokenId: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + collect( + params: ICommonNonfungiblePositionManager.CollectParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + createAndInitializePoolIfNecessary( + token0: string, + token1: string, + fee: BigNumberish, + sqrtPriceX96: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + decreaseLiquidity( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + name(overrides?: CallOverrides): Promise; + + ownerOf(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + positions( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise< + [ + BigNumber, + string, + string, + string, + number, + number, + number, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + nonce: BigNumber; + operator: string; + token0: string; + token1: string; + fee: number; + tickLower: number; + tickUpper: number; + liquidity: BigNumber; + feeGrowthInside0LastX128: BigNumber; + feeGrowthInside1LastX128: BigNumber; + tokensOwed0: BigNumber; + tokensOwed1: BigNumber; + } + >; + + refundETH( + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenURI(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + callStatic: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise; + + WETH9(overrides?: CallOverrides): Promise; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + burn(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + collect( + params: ICommonNonfungiblePositionManager.CollectParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + createAndInitializePoolIfNecessary( + token0: string, + token1: string, + fee: BigNumberish, + sqrtPriceX96: BigNumberish, + overrides?: CallOverrides + ): Promise; + + decreaseLiquidity( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + factory(overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + name(overrides?: CallOverrides): Promise; + + ownerOf(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise; + + positions( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise< + [ + BigNumber, + string, + string, + string, + number, + number, + number, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + nonce: BigNumber; + operator: string; + token0: string; + token1: string; + fee: number; + tickLower: number; + tickUpper: number; + liquidity: BigNumber; + feeGrowthInside0LastX128: BigNumber; + feeGrowthInside1LastX128: BigNumber; + tokensOwed0: BigNumber; + tokensOwed1: BigNumber; + } + >; + + refundETH(overrides?: CallOverrides): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: CallOverrides + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: CallOverrides + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenURI(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "Approval(address,address,uint256)"( + owner?: string | null, + approved?: string | null, + tokenId?: BigNumberish | null + ): ApprovalEventFilter; + Approval( + owner?: string | null, + approved?: string | null, + tokenId?: BigNumberish | null + ): ApprovalEventFilter; + + "ApprovalForAll(address,address,bool)"( + owner?: string | null, + operator?: string | null, + approved?: null + ): ApprovalForAllEventFilter; + ApprovalForAll( + owner?: string | null, + operator?: string | null, + approved?: null + ): ApprovalForAllEventFilter; + + "Collect(uint256,address,uint256,uint256)"( + tokenId?: BigNumberish | null, + recipient?: null, + amount0?: null, + amount1?: null + ): CollectEventFilter; + Collect( + tokenId?: BigNumberish | null, + recipient?: null, + amount0?: null, + amount1?: null + ): CollectEventFilter; + + "DecreaseLiquidity(uint256,uint128,uint256,uint256)"( + tokenId?: BigNumberish | null, + liquidity?: null, + amount0?: null, + amount1?: null + ): DecreaseLiquidityEventFilter; + DecreaseLiquidity( + tokenId?: BigNumberish | null, + liquidity?: null, + amount0?: null, + amount1?: null + ): DecreaseLiquidityEventFilter; + + "IncreaseLiquidity(uint256,uint128,uint256,uint256)"( + tokenId?: BigNumberish | null, + liquidity?: null, + amount0?: null, + amount1?: null + ): IncreaseLiquidityEventFilter; + IncreaseLiquidity( + tokenId?: BigNumberish | null, + liquidity?: null, + amount0?: null, + amount1?: null + ): IncreaseLiquidityEventFilter; + + "Transfer(address,address,uint256)"( + from?: string | null, + to?: string | null, + tokenId?: BigNumberish | null + ): TransferEventFilter; + Transfer( + from?: string | null, + to?: string | null, + tokenId?: BigNumberish | null + ): TransferEventFilter; + }; + + estimateGas: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise; + + WETH9(overrides?: CallOverrides): Promise; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + burn( + tokenId: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + collect( + params: ICommonNonfungiblePositionManager.CollectParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + createAndInitializePoolIfNecessary( + token0: string, + token1: string, + fee: BigNumberish, + sqrtPriceX96: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + decreaseLiquidity( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + name(overrides?: CallOverrides): Promise; + + ownerOf( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + positions( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + refundETH( + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenURI( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise; + + WETH9(overrides?: CallOverrides): Promise; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf( + owner: string, + overrides?: CallOverrides + ): Promise; + + burn( + tokenId: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + collect( + params: ICommonNonfungiblePositionManager.CollectParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + createAndInitializePoolIfNecessary( + token0: string, + token1: string, + fee: BigNumberish, + sqrtPriceX96: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + decreaseLiquidity( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + name(overrides?: CallOverrides): Promise; + + ownerOf( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + positions( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + refundETH( + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenURI( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/@aperture_finance/uni-v3-lib/src/interfaces/index.ts b/src/typechain-typesV4/@aperture_finance/uni-v3-lib/src/interfaces/index.ts new file mode 100644 index 00000000..58087252 --- /dev/null +++ b/src/typechain-typesV4/@aperture_finance/uni-v3-lib/src/interfaces/index.ts @@ -0,0 +1,7 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export type { ICommonNonfungiblePositionManager } from "./ICommonNonfungiblePositionManager"; +export type { IPCSV3NonfungiblePositionManager } from "./IPCSV3NonfungiblePositionManager"; +export type { ISlipStreamNonfungiblePositionManager } from "./ISlipStreamNonfungiblePositionManager"; +export type { IUniswapV3NonfungiblePositionManager } from "./IUniswapV3NonfungiblePositionManager"; diff --git a/src/typechain-typesV4/@openzeppelin/contracts/access/Ownable.ts b/src/typechain-typesV4/@openzeppelin/contracts/access/Ownable.ts new file mode 100644 index 00000000..aec24937 --- /dev/null +++ b/src/typechain-typesV4/@openzeppelin/contracts/access/Ownable.ts @@ -0,0 +1,175 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export interface OwnableInterface extends utils.Interface { + functions: { + "owner()": FunctionFragment; + "renounceOwnership()": FunctionFragment; + "transferOwnership(address)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: "owner" | "renounceOwnership" | "transferOwnership" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "owner", values?: undefined): string; + encodeFunctionData( + functionFragment: "renounceOwnership", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "transferOwnership", + values: [string] + ): string; + + decodeFunctionResult(functionFragment: "owner", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "renounceOwnership", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "transferOwnership", + data: BytesLike + ): Result; + + events: { + "OwnershipTransferred(address,address)": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "OwnershipTransferred"): EventFragment; +} + +export interface OwnershipTransferredEventObject { + previousOwner: string; + newOwner: string; +} +export type OwnershipTransferredEvent = TypedEvent< + [string, string], + OwnershipTransferredEventObject +>; + +export type OwnershipTransferredEventFilter = + TypedEventFilter; + +export interface Ownable extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: OwnableInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + owner(overrides?: CallOverrides): Promise<[string]>; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + owner(overrides?: CallOverrides): Promise; + + renounceOwnership(overrides?: CallOverrides): Promise; + + transferOwnership( + newOwner: string, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "OwnershipTransferred(address,address)"( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + OwnershipTransferred( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + }; + + estimateGas: { + owner(overrides?: CallOverrides): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + owner(overrides?: CallOverrides): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/@openzeppelin/contracts/access/index.ts b/src/typechain-typesV4/@openzeppelin/contracts/access/index.ts new file mode 100644 index 00000000..999bcc77 --- /dev/null +++ b/src/typechain-typesV4/@openzeppelin/contracts/access/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export type { Ownable } from "./Ownable"; diff --git a/src/typechain-typesV4/@openzeppelin/contracts/index.ts b/src/typechain-typesV4/@openzeppelin/contracts/index.ts new file mode 100644 index 00000000..c8c5c07b --- /dev/null +++ b/src/typechain-typesV4/@openzeppelin/contracts/index.ts @@ -0,0 +1,9 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as access from "./access"; +export type { access }; +import type * as token from "./token"; +export type { token }; +import type * as utils from "./utils"; +export type { utils }; diff --git a/src/typechain-typesV4/@openzeppelin/contracts/token/ERC20/IERC20.ts b/src/typechain-typesV4/@openzeppelin/contracts/token/ERC20/IERC20.ts new file mode 100644 index 00000000..40ca9438 --- /dev/null +++ b/src/typechain-typesV4/@openzeppelin/contracts/token/ERC20/IERC20.ts @@ -0,0 +1,322 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../common"; + +export interface IERC20Interface extends utils.Interface { + functions: { + "allowance(address,address)": FunctionFragment; + "approve(address,uint256)": FunctionFragment; + "balanceOf(address)": FunctionFragment; + "totalSupply()": FunctionFragment; + "transfer(address,uint256)": FunctionFragment; + "transferFrom(address,address,uint256)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "allowance" + | "approve" + | "balanceOf" + | "totalSupply" + | "transfer" + | "transferFrom" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "allowance", + values: [string, string] + ): string; + encodeFunctionData( + functionFragment: "approve", + values: [string, BigNumberish] + ): string; + encodeFunctionData(functionFragment: "balanceOf", values: [string]): string; + encodeFunctionData( + functionFragment: "totalSupply", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "transfer", + values: [string, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "transferFrom", + values: [string, string, BigNumberish] + ): string; + + decodeFunctionResult(functionFragment: "allowance", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "approve", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "balanceOf", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "totalSupply", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "transfer", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "transferFrom", + data: BytesLike + ): Result; + + events: { + "Approval(address,address,uint256)": EventFragment; + "Transfer(address,address,uint256)": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "Approval"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Transfer"): EventFragment; +} + +export interface ApprovalEventObject { + owner: string; + spender: string; + value: BigNumber; +} +export type ApprovalEvent = TypedEvent< + [string, string, BigNumber], + ApprovalEventObject +>; + +export type ApprovalEventFilter = TypedEventFilter; + +export interface TransferEventObject { + from: string; + to: string; + value: BigNumber; +} +export type TransferEvent = TypedEvent< + [string, string, BigNumber], + TransferEventObject +>; + +export type TransferEventFilter = TypedEventFilter; + +export interface IERC20 extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IERC20Interface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + allowance( + owner: string, + spender: string, + overrides?: CallOverrides + ): Promise<[BigNumber]>; + + approve( + spender: string, + value: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(account: string, overrides?: CallOverrides): Promise<[BigNumber]>; + + totalSupply(overrides?: CallOverrides): Promise<[BigNumber]>; + + transfer( + to: string, + value: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + transferFrom( + from: string, + to: string, + value: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + allowance( + owner: string, + spender: string, + overrides?: CallOverrides + ): Promise; + + approve( + spender: string, + value: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(account: string, overrides?: CallOverrides): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transfer( + to: string, + value: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + transferFrom( + from: string, + to: string, + value: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + allowance( + owner: string, + spender: string, + overrides?: CallOverrides + ): Promise; + + approve( + spender: string, + value: BigNumberish, + overrides?: CallOverrides + ): Promise; + + balanceOf(account: string, overrides?: CallOverrides): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transfer( + to: string, + value: BigNumberish, + overrides?: CallOverrides + ): Promise; + + transferFrom( + from: string, + to: string, + value: BigNumberish, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "Approval(address,address,uint256)"( + owner?: string | null, + spender?: string | null, + value?: null + ): ApprovalEventFilter; + Approval( + owner?: string | null, + spender?: string | null, + value?: null + ): ApprovalEventFilter; + + "Transfer(address,address,uint256)"( + from?: string | null, + to?: string | null, + value?: null + ): TransferEventFilter; + Transfer( + from?: string | null, + to?: string | null, + value?: null + ): TransferEventFilter; + }; + + estimateGas: { + allowance( + owner: string, + spender: string, + overrides?: CallOverrides + ): Promise; + + approve( + spender: string, + value: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(account: string, overrides?: CallOverrides): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transfer( + to: string, + value: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + transferFrom( + from: string, + to: string, + value: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + allowance( + owner: string, + spender: string, + overrides?: CallOverrides + ): Promise; + + approve( + spender: string, + value: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf( + account: string, + overrides?: CallOverrides + ): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transfer( + to: string, + value: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + transferFrom( + from: string, + to: string, + value: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata.ts b/src/typechain-typesV4/@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata.ts new file mode 100644 index 00000000..e517ebb2 --- /dev/null +++ b/src/typechain-typesV4/@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata.ts @@ -0,0 +1,364 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../../common"; + +export interface IERC20MetadataInterface extends utils.Interface { + functions: { + "allowance(address,address)": FunctionFragment; + "approve(address,uint256)": FunctionFragment; + "balanceOf(address)": FunctionFragment; + "decimals()": FunctionFragment; + "name()": FunctionFragment; + "symbol()": FunctionFragment; + "totalSupply()": FunctionFragment; + "transfer(address,uint256)": FunctionFragment; + "transferFrom(address,address,uint256)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "allowance" + | "approve" + | "balanceOf" + | "decimals" + | "name" + | "symbol" + | "totalSupply" + | "transfer" + | "transferFrom" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "allowance", + values: [string, string] + ): string; + encodeFunctionData( + functionFragment: "approve", + values: [string, BigNumberish] + ): string; + encodeFunctionData(functionFragment: "balanceOf", values: [string]): string; + encodeFunctionData(functionFragment: "decimals", values?: undefined): string; + encodeFunctionData(functionFragment: "name", values?: undefined): string; + encodeFunctionData(functionFragment: "symbol", values?: undefined): string; + encodeFunctionData( + functionFragment: "totalSupply", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "transfer", + values: [string, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "transferFrom", + values: [string, string, BigNumberish] + ): string; + + decodeFunctionResult(functionFragment: "allowance", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "approve", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "balanceOf", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "decimals", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "name", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "symbol", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "totalSupply", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "transfer", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "transferFrom", + data: BytesLike + ): Result; + + events: { + "Approval(address,address,uint256)": EventFragment; + "Transfer(address,address,uint256)": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "Approval"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Transfer"): EventFragment; +} + +export interface ApprovalEventObject { + owner: string; + spender: string; + value: BigNumber; +} +export type ApprovalEvent = TypedEvent< + [string, string, BigNumber], + ApprovalEventObject +>; + +export type ApprovalEventFilter = TypedEventFilter; + +export interface TransferEventObject { + from: string; + to: string; + value: BigNumber; +} +export type TransferEvent = TypedEvent< + [string, string, BigNumber], + TransferEventObject +>; + +export type TransferEventFilter = TypedEventFilter; + +export interface IERC20Metadata extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IERC20MetadataInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + allowance( + owner: string, + spender: string, + overrides?: CallOverrides + ): Promise<[BigNumber]>; + + approve( + spender: string, + value: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(account: string, overrides?: CallOverrides): Promise<[BigNumber]>; + + decimals(overrides?: CallOverrides): Promise<[number]>; + + name(overrides?: CallOverrides): Promise<[string]>; + + symbol(overrides?: CallOverrides): Promise<[string]>; + + totalSupply(overrides?: CallOverrides): Promise<[BigNumber]>; + + transfer( + to: string, + value: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + transferFrom( + from: string, + to: string, + value: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + allowance( + owner: string, + spender: string, + overrides?: CallOverrides + ): Promise; + + approve( + spender: string, + value: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(account: string, overrides?: CallOverrides): Promise; + + decimals(overrides?: CallOverrides): Promise; + + name(overrides?: CallOverrides): Promise; + + symbol(overrides?: CallOverrides): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transfer( + to: string, + value: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + transferFrom( + from: string, + to: string, + value: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + allowance( + owner: string, + spender: string, + overrides?: CallOverrides + ): Promise; + + approve( + spender: string, + value: BigNumberish, + overrides?: CallOverrides + ): Promise; + + balanceOf(account: string, overrides?: CallOverrides): Promise; + + decimals(overrides?: CallOverrides): Promise; + + name(overrides?: CallOverrides): Promise; + + symbol(overrides?: CallOverrides): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transfer( + to: string, + value: BigNumberish, + overrides?: CallOverrides + ): Promise; + + transferFrom( + from: string, + to: string, + value: BigNumberish, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "Approval(address,address,uint256)"( + owner?: string | null, + spender?: string | null, + value?: null + ): ApprovalEventFilter; + Approval( + owner?: string | null, + spender?: string | null, + value?: null + ): ApprovalEventFilter; + + "Transfer(address,address,uint256)"( + from?: string | null, + to?: string | null, + value?: null + ): TransferEventFilter; + Transfer( + from?: string | null, + to?: string | null, + value?: null + ): TransferEventFilter; + }; + + estimateGas: { + allowance( + owner: string, + spender: string, + overrides?: CallOverrides + ): Promise; + + approve( + spender: string, + value: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(account: string, overrides?: CallOverrides): Promise; + + decimals(overrides?: CallOverrides): Promise; + + name(overrides?: CallOverrides): Promise; + + symbol(overrides?: CallOverrides): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transfer( + to: string, + value: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + transferFrom( + from: string, + to: string, + value: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + allowance( + owner: string, + spender: string, + overrides?: CallOverrides + ): Promise; + + approve( + spender: string, + value: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf( + account: string, + overrides?: CallOverrides + ): Promise; + + decimals(overrides?: CallOverrides): Promise; + + name(overrides?: CallOverrides): Promise; + + symbol(overrides?: CallOverrides): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transfer( + to: string, + value: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + transferFrom( + from: string, + to: string, + value: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/@openzeppelin/contracts/token/ERC20/extensions/index.ts b/src/typechain-typesV4/@openzeppelin/contracts/token/ERC20/extensions/index.ts new file mode 100644 index 00000000..6044cdef --- /dev/null +++ b/src/typechain-typesV4/@openzeppelin/contracts/token/ERC20/extensions/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export type { IERC20Metadata } from "./IERC20Metadata"; diff --git a/src/typechain-typesV4/@openzeppelin/contracts/token/ERC20/index.ts b/src/typechain-typesV4/@openzeppelin/contracts/token/ERC20/index.ts new file mode 100644 index 00000000..a8eb12b2 --- /dev/null +++ b/src/typechain-typesV4/@openzeppelin/contracts/token/ERC20/index.ts @@ -0,0 +1,6 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as extensions from "./extensions"; +export type { extensions }; +export type { IERC20 } from "./IERC20"; diff --git a/src/typechain-typesV4/@openzeppelin/contracts/token/ERC721/IERC721.ts b/src/typechain-typesV4/@openzeppelin/contracts/token/ERC721/IERC721.ts new file mode 100644 index 00000000..5096a836 --- /dev/null +++ b/src/typechain-typesV4/@openzeppelin/contracts/token/ERC721/IERC721.ts @@ -0,0 +1,527 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../common"; + +export interface IERC721Interface extends utils.Interface { + functions: { + "approve(address,uint256)": FunctionFragment; + "balanceOf(address)": FunctionFragment; + "getApproved(uint256)": FunctionFragment; + "isApprovedForAll(address,address)": FunctionFragment; + "ownerOf(uint256)": FunctionFragment; + "safeTransferFrom(address,address,uint256)": FunctionFragment; + "safeTransferFrom(address,address,uint256,bytes)": FunctionFragment; + "setApprovalForAll(address,bool)": FunctionFragment; + "supportsInterface(bytes4)": FunctionFragment; + "transferFrom(address,address,uint256)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "approve" + | "balanceOf" + | "getApproved" + | "isApprovedForAll" + | "ownerOf" + | "safeTransferFrom(address,address,uint256)" + | "safeTransferFrom(address,address,uint256,bytes)" + | "setApprovalForAll" + | "supportsInterface" + | "transferFrom" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "approve", + values: [string, BigNumberish] + ): string; + encodeFunctionData(functionFragment: "balanceOf", values: [string]): string; + encodeFunctionData( + functionFragment: "getApproved", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "isApprovedForAll", + values: [string, string] + ): string; + encodeFunctionData( + functionFragment: "ownerOf", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "safeTransferFrom(address,address,uint256)", + values: [string, string, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "safeTransferFrom(address,address,uint256,bytes)", + values: [string, string, BigNumberish, BytesLike] + ): string; + encodeFunctionData( + functionFragment: "setApprovalForAll", + values: [string, boolean] + ): string; + encodeFunctionData( + functionFragment: "supportsInterface", + values: [BytesLike] + ): string; + encodeFunctionData( + functionFragment: "transferFrom", + values: [string, string, BigNumberish] + ): string; + + decodeFunctionResult(functionFragment: "approve", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "balanceOf", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "getApproved", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "isApprovedForAll", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "ownerOf", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "safeTransferFrom(address,address,uint256)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "safeTransferFrom(address,address,uint256,bytes)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setApprovalForAll", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "supportsInterface", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "transferFrom", + data: BytesLike + ): Result; + + events: { + "Approval(address,address,uint256)": EventFragment; + "ApprovalForAll(address,address,bool)": EventFragment; + "Transfer(address,address,uint256)": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "Approval"): EventFragment; + getEvent(nameOrSignatureOrTopic: "ApprovalForAll"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Transfer"): EventFragment; +} + +export interface ApprovalEventObject { + owner: string; + approved: string; + tokenId: BigNumber; +} +export type ApprovalEvent = TypedEvent< + [string, string, BigNumber], + ApprovalEventObject +>; + +export type ApprovalEventFilter = TypedEventFilter; + +export interface ApprovalForAllEventObject { + owner: string; + operator: string; + approved: boolean; +} +export type ApprovalForAllEvent = TypedEvent< + [string, string, boolean], + ApprovalForAllEventObject +>; + +export type ApprovalForAllEventFilter = TypedEventFilter; + +export interface TransferEventObject { + from: string; + to: string; + tokenId: BigNumber; +} +export type TransferEvent = TypedEvent< + [string, string, BigNumber], + TransferEventObject +>; + +export type TransferEventFilter = TypedEventFilter; + +export interface IERC721 extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IERC721Interface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf( + owner: string, + overrides?: CallOverrides + ): Promise<[BigNumber] & { balance: BigNumber }>; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise<[string] & { operator: string }>; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise<[boolean]>; + + ownerOf( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise<[string] & { owner: string }>; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise<[boolean]>; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + ownerOf(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + approve( + to: string, + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + ownerOf(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: CallOverrides + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "Approval(address,address,uint256)"( + owner?: string | null, + approved?: string | null, + tokenId?: BigNumberish | null + ): ApprovalEventFilter; + Approval( + owner?: string | null, + approved?: string | null, + tokenId?: BigNumberish | null + ): ApprovalEventFilter; + + "ApprovalForAll(address,address,bool)"( + owner?: string | null, + operator?: string | null, + approved?: null + ): ApprovalForAllEventFilter; + ApprovalForAll( + owner?: string | null, + operator?: string | null, + approved?: null + ): ApprovalForAllEventFilter; + + "Transfer(address,address,uint256)"( + from?: string | null, + to?: string | null, + tokenId?: BigNumberish | null + ): TransferEventFilter; + Transfer( + from?: string | null, + to?: string | null, + tokenId?: BigNumberish | null + ): TransferEventFilter; + }; + + estimateGas: { + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + ownerOf( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf( + owner: string, + overrides?: CallOverrides + ): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + ownerOf( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/@openzeppelin/contracts/token/ERC721/extensions/IERC721Enumerable.ts b/src/typechain-typesV4/@openzeppelin/contracts/token/ERC721/extensions/IERC721Enumerable.ts new file mode 100644 index 00000000..c243b650 --- /dev/null +++ b/src/typechain-typesV4/@openzeppelin/contracts/token/ERC721/extensions/IERC721Enumerable.ts @@ -0,0 +1,622 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../../common"; + +export interface IERC721EnumerableInterface extends utils.Interface { + functions: { + "approve(address,uint256)": FunctionFragment; + "balanceOf(address)": FunctionFragment; + "getApproved(uint256)": FunctionFragment; + "isApprovedForAll(address,address)": FunctionFragment; + "ownerOf(uint256)": FunctionFragment; + "safeTransferFrom(address,address,uint256)": FunctionFragment; + "safeTransferFrom(address,address,uint256,bytes)": FunctionFragment; + "setApprovalForAll(address,bool)": FunctionFragment; + "supportsInterface(bytes4)": FunctionFragment; + "tokenByIndex(uint256)": FunctionFragment; + "tokenOfOwnerByIndex(address,uint256)": FunctionFragment; + "totalSupply()": FunctionFragment; + "transferFrom(address,address,uint256)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "approve" + | "balanceOf" + | "getApproved" + | "isApprovedForAll" + | "ownerOf" + | "safeTransferFrom(address,address,uint256)" + | "safeTransferFrom(address,address,uint256,bytes)" + | "setApprovalForAll" + | "supportsInterface" + | "tokenByIndex" + | "tokenOfOwnerByIndex" + | "totalSupply" + | "transferFrom" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "approve", + values: [string, BigNumberish] + ): string; + encodeFunctionData(functionFragment: "balanceOf", values: [string]): string; + encodeFunctionData( + functionFragment: "getApproved", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "isApprovedForAll", + values: [string, string] + ): string; + encodeFunctionData( + functionFragment: "ownerOf", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "safeTransferFrom(address,address,uint256)", + values: [string, string, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "safeTransferFrom(address,address,uint256,bytes)", + values: [string, string, BigNumberish, BytesLike] + ): string; + encodeFunctionData( + functionFragment: "setApprovalForAll", + values: [string, boolean] + ): string; + encodeFunctionData( + functionFragment: "supportsInterface", + values: [BytesLike] + ): string; + encodeFunctionData( + functionFragment: "tokenByIndex", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "tokenOfOwnerByIndex", + values: [string, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "totalSupply", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "transferFrom", + values: [string, string, BigNumberish] + ): string; + + decodeFunctionResult(functionFragment: "approve", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "balanceOf", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "getApproved", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "isApprovedForAll", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "ownerOf", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "safeTransferFrom(address,address,uint256)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "safeTransferFrom(address,address,uint256,bytes)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setApprovalForAll", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "supportsInterface", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "tokenByIndex", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "tokenOfOwnerByIndex", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "totalSupply", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "transferFrom", + data: BytesLike + ): Result; + + events: { + "Approval(address,address,uint256)": EventFragment; + "ApprovalForAll(address,address,bool)": EventFragment; + "Transfer(address,address,uint256)": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "Approval"): EventFragment; + getEvent(nameOrSignatureOrTopic: "ApprovalForAll"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Transfer"): EventFragment; +} + +export interface ApprovalEventObject { + owner: string; + approved: string; + tokenId: BigNumber; +} +export type ApprovalEvent = TypedEvent< + [string, string, BigNumber], + ApprovalEventObject +>; + +export type ApprovalEventFilter = TypedEventFilter; + +export interface ApprovalForAllEventObject { + owner: string; + operator: string; + approved: boolean; +} +export type ApprovalForAllEvent = TypedEvent< + [string, string, boolean], + ApprovalForAllEventObject +>; + +export type ApprovalForAllEventFilter = TypedEventFilter; + +export interface TransferEventObject { + from: string; + to: string; + tokenId: BigNumber; +} +export type TransferEvent = TypedEvent< + [string, string, BigNumber], + TransferEventObject +>; + +export type TransferEventFilter = TypedEventFilter; + +export interface IERC721Enumerable extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IERC721EnumerableInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf( + owner: string, + overrides?: CallOverrides + ): Promise<[BigNumber] & { balance: BigNumber }>; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise<[string] & { operator: string }>; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise<[boolean]>; + + ownerOf( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise<[string] & { owner: string }>; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise<[boolean]>; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise<[BigNumber]>; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise<[BigNumber]>; + + totalSupply(overrides?: CallOverrides): Promise<[BigNumber]>; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + ownerOf(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + approve( + to: string, + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + ownerOf(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: CallOverrides + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "Approval(address,address,uint256)"( + owner?: string | null, + approved?: string | null, + tokenId?: BigNumberish | null + ): ApprovalEventFilter; + Approval( + owner?: string | null, + approved?: string | null, + tokenId?: BigNumberish | null + ): ApprovalEventFilter; + + "ApprovalForAll(address,address,bool)"( + owner?: string | null, + operator?: string | null, + approved?: null + ): ApprovalForAllEventFilter; + ApprovalForAll( + owner?: string | null, + operator?: string | null, + approved?: null + ): ApprovalForAllEventFilter; + + "Transfer(address,address,uint256)"( + from?: string | null, + to?: string | null, + tokenId?: BigNumberish | null + ): TransferEventFilter; + Transfer( + from?: string | null, + to?: string | null, + tokenId?: BigNumberish | null + ): TransferEventFilter; + }; + + estimateGas: { + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + ownerOf( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf( + owner: string, + overrides?: CallOverrides + ): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + ownerOf( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + tokenByIndex( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tokenOfOwnerByIndex( + owner: string, + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/@openzeppelin/contracts/token/ERC721/extensions/IERC721Metadata.ts b/src/typechain-typesV4/@openzeppelin/contracts/token/ERC721/extensions/IERC721Metadata.ts new file mode 100644 index 00000000..7aea27da --- /dev/null +++ b/src/typechain-typesV4/@openzeppelin/contracts/token/ERC721/extensions/IERC721Metadata.ts @@ -0,0 +1,581 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../../common"; + +export interface IERC721MetadataInterface extends utils.Interface { + functions: { + "approve(address,uint256)": FunctionFragment; + "balanceOf(address)": FunctionFragment; + "getApproved(uint256)": FunctionFragment; + "isApprovedForAll(address,address)": FunctionFragment; + "name()": FunctionFragment; + "ownerOf(uint256)": FunctionFragment; + "safeTransferFrom(address,address,uint256)": FunctionFragment; + "safeTransferFrom(address,address,uint256,bytes)": FunctionFragment; + "setApprovalForAll(address,bool)": FunctionFragment; + "supportsInterface(bytes4)": FunctionFragment; + "symbol()": FunctionFragment; + "tokenURI(uint256)": FunctionFragment; + "transferFrom(address,address,uint256)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "approve" + | "balanceOf" + | "getApproved" + | "isApprovedForAll" + | "name" + | "ownerOf" + | "safeTransferFrom(address,address,uint256)" + | "safeTransferFrom(address,address,uint256,bytes)" + | "setApprovalForAll" + | "supportsInterface" + | "symbol" + | "tokenURI" + | "transferFrom" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "approve", + values: [string, BigNumberish] + ): string; + encodeFunctionData(functionFragment: "balanceOf", values: [string]): string; + encodeFunctionData( + functionFragment: "getApproved", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "isApprovedForAll", + values: [string, string] + ): string; + encodeFunctionData(functionFragment: "name", values?: undefined): string; + encodeFunctionData( + functionFragment: "ownerOf", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "safeTransferFrom(address,address,uint256)", + values: [string, string, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "safeTransferFrom(address,address,uint256,bytes)", + values: [string, string, BigNumberish, BytesLike] + ): string; + encodeFunctionData( + functionFragment: "setApprovalForAll", + values: [string, boolean] + ): string; + encodeFunctionData( + functionFragment: "supportsInterface", + values: [BytesLike] + ): string; + encodeFunctionData(functionFragment: "symbol", values?: undefined): string; + encodeFunctionData( + functionFragment: "tokenURI", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "transferFrom", + values: [string, string, BigNumberish] + ): string; + + decodeFunctionResult(functionFragment: "approve", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "balanceOf", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "getApproved", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "isApprovedForAll", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "name", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "ownerOf", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "safeTransferFrom(address,address,uint256)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "safeTransferFrom(address,address,uint256,bytes)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setApprovalForAll", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "supportsInterface", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "symbol", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "tokenURI", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "transferFrom", + data: BytesLike + ): Result; + + events: { + "Approval(address,address,uint256)": EventFragment; + "ApprovalForAll(address,address,bool)": EventFragment; + "Transfer(address,address,uint256)": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "Approval"): EventFragment; + getEvent(nameOrSignatureOrTopic: "ApprovalForAll"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Transfer"): EventFragment; +} + +export interface ApprovalEventObject { + owner: string; + approved: string; + tokenId: BigNumber; +} +export type ApprovalEvent = TypedEvent< + [string, string, BigNumber], + ApprovalEventObject +>; + +export type ApprovalEventFilter = TypedEventFilter; + +export interface ApprovalForAllEventObject { + owner: string; + operator: string; + approved: boolean; +} +export type ApprovalForAllEvent = TypedEvent< + [string, string, boolean], + ApprovalForAllEventObject +>; + +export type ApprovalForAllEventFilter = TypedEventFilter; + +export interface TransferEventObject { + from: string; + to: string; + tokenId: BigNumber; +} +export type TransferEvent = TypedEvent< + [string, string, BigNumber], + TransferEventObject +>; + +export type TransferEventFilter = TypedEventFilter; + +export interface IERC721Metadata extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IERC721MetadataInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf( + owner: string, + overrides?: CallOverrides + ): Promise<[BigNumber] & { balance: BigNumber }>; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise<[string] & { operator: string }>; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise<[boolean]>; + + name(overrides?: CallOverrides): Promise<[string]>; + + ownerOf( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise<[string] & { owner: string }>; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise<[boolean]>; + + symbol(overrides?: CallOverrides): Promise<[string]>; + + tokenURI( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise<[string]>; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + name(overrides?: CallOverrides): Promise; + + ownerOf(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + tokenURI(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + approve( + to: string, + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + name(overrides?: CallOverrides): Promise; + + ownerOf(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: CallOverrides + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + tokenURI(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "Approval(address,address,uint256)"( + owner?: string | null, + approved?: string | null, + tokenId?: BigNumberish | null + ): ApprovalEventFilter; + Approval( + owner?: string | null, + approved?: string | null, + tokenId?: BigNumberish | null + ): ApprovalEventFilter; + + "ApprovalForAll(address,address,bool)"( + owner?: string | null, + operator?: string | null, + approved?: null + ): ApprovalForAllEventFilter; + ApprovalForAll( + owner?: string | null, + operator?: string | null, + approved?: null + ): ApprovalForAllEventFilter; + + "Transfer(address,address,uint256)"( + from?: string | null, + to?: string | null, + tokenId?: BigNumberish | null + ): TransferEventFilter; + Transfer( + from?: string | null, + to?: string | null, + tokenId?: BigNumberish | null + ): TransferEventFilter; + }; + + estimateGas: { + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + name(overrides?: CallOverrides): Promise; + + ownerOf( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + tokenURI( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf( + owner: string, + overrides?: CallOverrides + ): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + name(overrides?: CallOverrides): Promise; + + ownerOf( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + tokenURI( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/@openzeppelin/contracts/token/ERC721/extensions/index.ts b/src/typechain-typesV4/@openzeppelin/contracts/token/ERC721/extensions/index.ts new file mode 100644 index 00000000..10e64eae --- /dev/null +++ b/src/typechain-typesV4/@openzeppelin/contracts/token/ERC721/extensions/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export type { IERC721Enumerable } from "./IERC721Enumerable"; +export type { IERC721Metadata } from "./IERC721Metadata"; diff --git a/src/typechain-typesV4/@openzeppelin/contracts/token/ERC721/index.ts b/src/typechain-typesV4/@openzeppelin/contracts/token/ERC721/index.ts new file mode 100644 index 00000000..6e56dd13 --- /dev/null +++ b/src/typechain-typesV4/@openzeppelin/contracts/token/ERC721/index.ts @@ -0,0 +1,6 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as extensions from "./extensions"; +export type { extensions }; +export type { IERC721 } from "./IERC721"; diff --git a/src/typechain-typesV4/@openzeppelin/contracts/token/index.ts b/src/typechain-typesV4/@openzeppelin/contracts/token/index.ts new file mode 100644 index 00000000..bbfac68c --- /dev/null +++ b/src/typechain-typesV4/@openzeppelin/contracts/token/index.ts @@ -0,0 +1,7 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as erc20 from "./ERC20"; +export type { erc20 }; +import type * as erc721 from "./ERC721"; +export type { erc721 }; diff --git a/src/typechain-typesV4/@openzeppelin/contracts/utils/index.ts b/src/typechain-typesV4/@openzeppelin/contracts/utils/index.ts new file mode 100644 index 00000000..3aa96c1c --- /dev/null +++ b/src/typechain-typesV4/@openzeppelin/contracts/utils/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as introspection from "./introspection"; +export type { introspection }; diff --git a/src/typechain-typesV4/@openzeppelin/contracts/utils/introspection/IERC165.ts b/src/typechain-typesV4/@openzeppelin/contracts/utils/introspection/IERC165.ts new file mode 100644 index 00000000..bfd45609 --- /dev/null +++ b/src/typechain-typesV4/@openzeppelin/contracts/utils/introspection/IERC165.ts @@ -0,0 +1,102 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BytesLike, + CallOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../common"; + +export interface IERC165Interface extends utils.Interface { + functions: { + "supportsInterface(bytes4)": FunctionFragment; + }; + + getFunction(nameOrSignatureOrTopic: "supportsInterface"): FunctionFragment; + + encodeFunctionData( + functionFragment: "supportsInterface", + values: [BytesLike] + ): string; + + decodeFunctionResult( + functionFragment: "supportsInterface", + data: BytesLike + ): Result; + + events: {}; +} + +export interface IERC165 extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IERC165Interface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise<[boolean]>; + }; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + callStatic: { + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + }; + + filters: {}; + + estimateGas: { + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + }; + + populateTransaction: { + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + }; +} diff --git a/src/typechain-typesV4/@openzeppelin/contracts/utils/introspection/index.ts b/src/typechain-typesV4/@openzeppelin/contracts/utils/introspection/index.ts new file mode 100644 index 00000000..3fcca5c2 --- /dev/null +++ b/src/typechain-typesV4/@openzeppelin/contracts/utils/introspection/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export type { IERC165 } from "./IERC165"; diff --git a/src/typechain-typesV4/@openzeppelin/index.ts b/src/typechain-typesV4/@openzeppelin/index.ts new file mode 100644 index 00000000..a11e4ca2 --- /dev/null +++ b/src/typechain-typesV4/@openzeppelin/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as contracts from "./contracts"; +export type { contracts }; diff --git a/src/typechain-typesV4/@pancakeswap/index.ts b/src/typechain-typesV4/@pancakeswap/index.ts new file mode 100644 index 00000000..2aaf583e --- /dev/null +++ b/src/typechain-typesV4/@pancakeswap/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as v3Core from "./v3-core"; +export type { v3Core }; diff --git a/src/typechain-typesV4/@pancakeswap/v3-core/contracts/index.ts b/src/typechain-typesV4/@pancakeswap/v3-core/contracts/index.ts new file mode 100644 index 00000000..92159233 --- /dev/null +++ b/src/typechain-typesV4/@pancakeswap/v3-core/contracts/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as interfaces from "./interfaces"; +export type { interfaces }; diff --git a/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/IPancakeV3Pool.ts b/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/IPancakeV3Pool.ts new file mode 100644 index 00000000..cc71ae7a --- /dev/null +++ b/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/IPancakeV3Pool.ts @@ -0,0 +1,1372 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../common"; + +export interface IPancakeV3PoolInterface extends utils.Interface { + functions: { + "burn(int24,int24,uint128)": FunctionFragment; + "collect(address,int24,int24,uint128,uint128)": FunctionFragment; + "collectProtocol(address,uint128,uint128)": FunctionFragment; + "factory()": FunctionFragment; + "fee()": FunctionFragment; + "feeGrowthGlobal0X128()": FunctionFragment; + "feeGrowthGlobal1X128()": FunctionFragment; + "flash(address,uint256,uint256,bytes)": FunctionFragment; + "increaseObservationCardinalityNext(uint16)": FunctionFragment; + "initialize(uint160)": FunctionFragment; + "liquidity()": FunctionFragment; + "maxLiquidityPerTick()": FunctionFragment; + "mint(address,int24,int24,uint128,bytes)": FunctionFragment; + "observations(uint256)": FunctionFragment; + "observe(uint32[])": FunctionFragment; + "positions(bytes32)": FunctionFragment; + "protocolFees()": FunctionFragment; + "setFeeProtocol(uint32,uint32)": FunctionFragment; + "setLmPool(address)": FunctionFragment; + "slot0()": FunctionFragment; + "snapshotCumulativesInside(int24,int24)": FunctionFragment; + "swap(address,bool,int256,uint160,bytes)": FunctionFragment; + "tickBitmap(int16)": FunctionFragment; + "tickSpacing()": FunctionFragment; + "ticks(int24)": FunctionFragment; + "token0()": FunctionFragment; + "token1()": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "burn" + | "collect" + | "collectProtocol" + | "factory" + | "fee" + | "feeGrowthGlobal0X128" + | "feeGrowthGlobal1X128" + | "flash" + | "increaseObservationCardinalityNext" + | "initialize" + | "liquidity" + | "maxLiquidityPerTick" + | "mint" + | "observations" + | "observe" + | "positions" + | "protocolFees" + | "setFeeProtocol" + | "setLmPool" + | "slot0" + | "snapshotCumulativesInside" + | "swap" + | "tickBitmap" + | "tickSpacing" + | "ticks" + | "token0" + | "token1" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "burn", + values: [BigNumberish, BigNumberish, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "collect", + values: [string, BigNumberish, BigNumberish, BigNumberish, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "collectProtocol", + values: [string, BigNumberish, BigNumberish] + ): string; + encodeFunctionData(functionFragment: "factory", values?: undefined): string; + encodeFunctionData(functionFragment: "fee", values?: undefined): string; + encodeFunctionData( + functionFragment: "feeGrowthGlobal0X128", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "feeGrowthGlobal1X128", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "flash", + values: [string, BigNumberish, BigNumberish, BytesLike] + ): string; + encodeFunctionData( + functionFragment: "increaseObservationCardinalityNext", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "initialize", + values: [BigNumberish] + ): string; + encodeFunctionData(functionFragment: "liquidity", values?: undefined): string; + encodeFunctionData( + functionFragment: "maxLiquidityPerTick", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "mint", + values: [string, BigNumberish, BigNumberish, BigNumberish, BytesLike] + ): string; + encodeFunctionData( + functionFragment: "observations", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "observe", + values: [BigNumberish[]] + ): string; + encodeFunctionData( + functionFragment: "positions", + values: [BytesLike] + ): string; + encodeFunctionData( + functionFragment: "protocolFees", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "setFeeProtocol", + values: [BigNumberish, BigNumberish] + ): string; + encodeFunctionData(functionFragment: "setLmPool", values: [string]): string; + encodeFunctionData(functionFragment: "slot0", values?: undefined): string; + encodeFunctionData( + functionFragment: "snapshotCumulativesInside", + values: [BigNumberish, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "swap", + values: [string, boolean, BigNumberish, BigNumberish, BytesLike] + ): string; + encodeFunctionData( + functionFragment: "tickBitmap", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "tickSpacing", + values?: undefined + ): string; + encodeFunctionData(functionFragment: "ticks", values: [BigNumberish]): string; + encodeFunctionData(functionFragment: "token0", values?: undefined): string; + encodeFunctionData(functionFragment: "token1", values?: undefined): string; + + decodeFunctionResult(functionFragment: "burn", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "collect", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "collectProtocol", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "factory", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "fee", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "feeGrowthGlobal0X128", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "feeGrowthGlobal1X128", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "flash", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "increaseObservationCardinalityNext", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "initialize", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "liquidity", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "maxLiquidityPerTick", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "mint", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "observations", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "observe", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "positions", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "protocolFees", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setFeeProtocol", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "setLmPool", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "slot0", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "snapshotCumulativesInside", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "swap", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "tickBitmap", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "tickSpacing", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "ticks", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "token0", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "token1", data: BytesLike): Result; + + events: { + "Burn(address,int24,int24,uint128,uint256,uint256)": EventFragment; + "Collect(address,address,int24,int24,uint128,uint128)": EventFragment; + "CollectProtocol(address,address,uint128,uint128)": EventFragment; + "Flash(address,address,uint256,uint256,uint256,uint256)": EventFragment; + "IncreaseObservationCardinalityNext(uint16,uint16)": EventFragment; + "Initialize(uint160,int24)": EventFragment; + "Mint(address,address,int24,int24,uint128,uint256,uint256)": EventFragment; + "SetFeeProtocol(uint32,uint32,uint32,uint32)": EventFragment; + "Swap(address,address,int256,int256,uint160,uint128,int24,uint128,uint128)": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "Burn"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Collect"): EventFragment; + getEvent(nameOrSignatureOrTopic: "CollectProtocol"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Flash"): EventFragment; + getEvent( + nameOrSignatureOrTopic: "IncreaseObservationCardinalityNext" + ): EventFragment; + getEvent(nameOrSignatureOrTopic: "Initialize"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Mint"): EventFragment; + getEvent(nameOrSignatureOrTopic: "SetFeeProtocol"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Swap"): EventFragment; +} + +export interface BurnEventObject { + owner: string; + tickLower: number; + tickUpper: number; + amount: BigNumber; + amount0: BigNumber; + amount1: BigNumber; +} +export type BurnEvent = TypedEvent< + [string, number, number, BigNumber, BigNumber, BigNumber], + BurnEventObject +>; + +export type BurnEventFilter = TypedEventFilter; + +export interface CollectEventObject { + owner: string; + recipient: string; + tickLower: number; + tickUpper: number; + amount0: BigNumber; + amount1: BigNumber; +} +export type CollectEvent = TypedEvent< + [string, string, number, number, BigNumber, BigNumber], + CollectEventObject +>; + +export type CollectEventFilter = TypedEventFilter; + +export interface CollectProtocolEventObject { + sender: string; + recipient: string; + amount0: BigNumber; + amount1: BigNumber; +} +export type CollectProtocolEvent = TypedEvent< + [string, string, BigNumber, BigNumber], + CollectProtocolEventObject +>; + +export type CollectProtocolEventFilter = TypedEventFilter; + +export interface FlashEventObject { + sender: string; + recipient: string; + amount0: BigNumber; + amount1: BigNumber; + paid0: BigNumber; + paid1: BigNumber; +} +export type FlashEvent = TypedEvent< + [string, string, BigNumber, BigNumber, BigNumber, BigNumber], + FlashEventObject +>; + +export type FlashEventFilter = TypedEventFilter; + +export interface IncreaseObservationCardinalityNextEventObject { + observationCardinalityNextOld: number; + observationCardinalityNextNew: number; +} +export type IncreaseObservationCardinalityNextEvent = TypedEvent< + [number, number], + IncreaseObservationCardinalityNextEventObject +>; + +export type IncreaseObservationCardinalityNextEventFilter = + TypedEventFilter; + +export interface InitializeEventObject { + sqrtPriceX96: BigNumber; + tick: number; +} +export type InitializeEvent = TypedEvent< + [BigNumber, number], + InitializeEventObject +>; + +export type InitializeEventFilter = TypedEventFilter; + +export interface MintEventObject { + sender: string; + owner: string; + tickLower: number; + tickUpper: number; + amount: BigNumber; + amount0: BigNumber; + amount1: BigNumber; +} +export type MintEvent = TypedEvent< + [string, string, number, number, BigNumber, BigNumber, BigNumber], + MintEventObject +>; + +export type MintEventFilter = TypedEventFilter; + +export interface SetFeeProtocolEventObject { + feeProtocol0Old: number; + feeProtocol1Old: number; + feeProtocol0New: number; + feeProtocol1New: number; +} +export type SetFeeProtocolEvent = TypedEvent< + [number, number, number, number], + SetFeeProtocolEventObject +>; + +export type SetFeeProtocolEventFilter = TypedEventFilter; + +export interface SwapEventObject { + sender: string; + recipient: string; + amount0: BigNumber; + amount1: BigNumber; + sqrtPriceX96: BigNumber; + liquidity: BigNumber; + tick: number; + protocolFeesToken0: BigNumber; + protocolFeesToken1: BigNumber; +} +export type SwapEvent = TypedEvent< + [ + string, + string, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + number, + BigNumber, + BigNumber + ], + SwapEventObject +>; + +export type SwapEventFilter = TypedEventFilter; + +export interface IPancakeV3Pool extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IPancakeV3PoolInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + burn( + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + collect( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + collectProtocol( + recipient: string, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise<[string]>; + + fee(overrides?: CallOverrides): Promise<[number]>; + + feeGrowthGlobal0X128(overrides?: CallOverrides): Promise<[BigNumber]>; + + feeGrowthGlobal1X128(overrides?: CallOverrides): Promise<[BigNumber]>; + + flash( + recipient: string, + amount0: BigNumberish, + amount1: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + increaseObservationCardinalityNext( + observationCardinalityNext: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + initialize( + sqrtPriceX96: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + liquidity(overrides?: CallOverrides): Promise<[BigNumber]>; + + maxLiquidityPerTick(overrides?: CallOverrides): Promise<[BigNumber]>; + + mint( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + observations( + index: BigNumberish, + overrides?: CallOverrides + ): Promise< + [number, BigNumber, BigNumber, boolean] & { + blockTimestamp: number; + tickCumulative: BigNumber; + secondsPerLiquidityCumulativeX128: BigNumber; + initialized: boolean; + } + >; + + observe( + secondsAgos: BigNumberish[], + overrides?: CallOverrides + ): Promise< + [BigNumber[], BigNumber[]] & { + tickCumulatives: BigNumber[]; + secondsPerLiquidityCumulativeX128s: BigNumber[]; + } + >; + + positions( + key: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber, BigNumber] & { + _liquidity: BigNumber; + feeGrowthInside0LastX128: BigNumber; + feeGrowthInside1LastX128: BigNumber; + tokensOwed0: BigNumber; + tokensOwed1: BigNumber; + } + >; + + protocolFees( + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { token0: BigNumber; token1: BigNumber } + >; + + setFeeProtocol( + feeProtocol0: BigNumberish, + feeProtocol1: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + setLmPool( + lmPool: string, + overrides?: Overrides & { from?: string } + ): Promise; + + slot0( + overrides?: CallOverrides + ): Promise< + [BigNumber, number, number, number, number, number, boolean] & { + sqrtPriceX96: BigNumber; + tick: number; + observationIndex: number; + observationCardinality: number; + observationCardinalityNext: number; + feeProtocol: number; + unlocked: boolean; + } + >; + + snapshotCumulativesInside( + tickLower: BigNumberish, + tickUpper: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, number] & { + tickCumulativeInside: BigNumber; + secondsPerLiquidityInsideX128: BigNumber; + secondsInside: number; + } + >; + + swap( + recipient: string, + zeroForOne: boolean, + amountSpecified: BigNumberish, + sqrtPriceLimitX96: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + tickBitmap( + wordPosition: BigNumberish, + overrides?: CallOverrides + ): Promise<[BigNumber]>; + + tickSpacing(overrides?: CallOverrides): Promise<[number]>; + + ticks( + tick: BigNumberish, + overrides?: CallOverrides + ): Promise< + [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + number, + boolean + ] & { + liquidityGross: BigNumber; + liquidityNet: BigNumber; + feeGrowthOutside0X128: BigNumber; + feeGrowthOutside1X128: BigNumber; + tickCumulativeOutside: BigNumber; + secondsPerLiquidityOutsideX128: BigNumber; + secondsOutside: number; + initialized: boolean; + } + >; + + token0(overrides?: CallOverrides): Promise<[string]>; + + token1(overrides?: CallOverrides): Promise<[string]>; + }; + + burn( + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + collect( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + collectProtocol( + recipient: string, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + fee(overrides?: CallOverrides): Promise; + + feeGrowthGlobal0X128(overrides?: CallOverrides): Promise; + + feeGrowthGlobal1X128(overrides?: CallOverrides): Promise; + + flash( + recipient: string, + amount0: BigNumberish, + amount1: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + increaseObservationCardinalityNext( + observationCardinalityNext: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + initialize( + sqrtPriceX96: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + liquidity(overrides?: CallOverrides): Promise; + + maxLiquidityPerTick(overrides?: CallOverrides): Promise; + + mint( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + observations( + index: BigNumberish, + overrides?: CallOverrides + ): Promise< + [number, BigNumber, BigNumber, boolean] & { + blockTimestamp: number; + tickCumulative: BigNumber; + secondsPerLiquidityCumulativeX128: BigNumber; + initialized: boolean; + } + >; + + observe( + secondsAgos: BigNumberish[], + overrides?: CallOverrides + ): Promise< + [BigNumber[], BigNumber[]] & { + tickCumulatives: BigNumber[]; + secondsPerLiquidityCumulativeX128s: BigNumber[]; + } + >; + + positions( + key: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber, BigNumber] & { + _liquidity: BigNumber; + feeGrowthInside0LastX128: BigNumber; + feeGrowthInside1LastX128: BigNumber; + tokensOwed0: BigNumber; + tokensOwed1: BigNumber; + } + >; + + protocolFees( + overrides?: CallOverrides + ): Promise<[BigNumber, BigNumber] & { token0: BigNumber; token1: BigNumber }>; + + setFeeProtocol( + feeProtocol0: BigNumberish, + feeProtocol1: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + setLmPool( + lmPool: string, + overrides?: Overrides & { from?: string } + ): Promise; + + slot0( + overrides?: CallOverrides + ): Promise< + [BigNumber, number, number, number, number, number, boolean] & { + sqrtPriceX96: BigNumber; + tick: number; + observationIndex: number; + observationCardinality: number; + observationCardinalityNext: number; + feeProtocol: number; + unlocked: boolean; + } + >; + + snapshotCumulativesInside( + tickLower: BigNumberish, + tickUpper: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, number] & { + tickCumulativeInside: BigNumber; + secondsPerLiquidityInsideX128: BigNumber; + secondsInside: number; + } + >; + + swap( + recipient: string, + zeroForOne: boolean, + amountSpecified: BigNumberish, + sqrtPriceLimitX96: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + tickBitmap( + wordPosition: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tickSpacing(overrides?: CallOverrides): Promise; + + ticks( + tick: BigNumberish, + overrides?: CallOverrides + ): Promise< + [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + number, + boolean + ] & { + liquidityGross: BigNumber; + liquidityNet: BigNumber; + feeGrowthOutside0X128: BigNumber; + feeGrowthOutside1X128: BigNumber; + tickCumulativeOutside: BigNumber; + secondsPerLiquidityOutsideX128: BigNumber; + secondsOutside: number; + initialized: boolean; + } + >; + + token0(overrides?: CallOverrides): Promise; + + token1(overrides?: CallOverrides): Promise; + + callStatic: { + burn( + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + collect( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + collectProtocol( + recipient: string, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + factory(overrides?: CallOverrides): Promise; + + fee(overrides?: CallOverrides): Promise; + + feeGrowthGlobal0X128(overrides?: CallOverrides): Promise; + + feeGrowthGlobal1X128(overrides?: CallOverrides): Promise; + + flash( + recipient: string, + amount0: BigNumberish, + amount1: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + + increaseObservationCardinalityNext( + observationCardinalityNext: BigNumberish, + overrides?: CallOverrides + ): Promise; + + initialize( + sqrtPriceX96: BigNumberish, + overrides?: CallOverrides + ): Promise; + + liquidity(overrides?: CallOverrides): Promise; + + maxLiquidityPerTick(overrides?: CallOverrides): Promise; + + mint( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + observations( + index: BigNumberish, + overrides?: CallOverrides + ): Promise< + [number, BigNumber, BigNumber, boolean] & { + blockTimestamp: number; + tickCumulative: BigNumber; + secondsPerLiquidityCumulativeX128: BigNumber; + initialized: boolean; + } + >; + + observe( + secondsAgos: BigNumberish[], + overrides?: CallOverrides + ): Promise< + [BigNumber[], BigNumber[]] & { + tickCumulatives: BigNumber[]; + secondsPerLiquidityCumulativeX128s: BigNumber[]; + } + >; + + positions( + key: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber, BigNumber] & { + _liquidity: BigNumber; + feeGrowthInside0LastX128: BigNumber; + feeGrowthInside1LastX128: BigNumber; + tokensOwed0: BigNumber; + tokensOwed1: BigNumber; + } + >; + + protocolFees( + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { token0: BigNumber; token1: BigNumber } + >; + + setFeeProtocol( + feeProtocol0: BigNumberish, + feeProtocol1: BigNumberish, + overrides?: CallOverrides + ): Promise; + + setLmPool(lmPool: string, overrides?: CallOverrides): Promise; + + slot0( + overrides?: CallOverrides + ): Promise< + [BigNumber, number, number, number, number, number, boolean] & { + sqrtPriceX96: BigNumber; + tick: number; + observationIndex: number; + observationCardinality: number; + observationCardinalityNext: number; + feeProtocol: number; + unlocked: boolean; + } + >; + + snapshotCumulativesInside( + tickLower: BigNumberish, + tickUpper: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, number] & { + tickCumulativeInside: BigNumber; + secondsPerLiquidityInsideX128: BigNumber; + secondsInside: number; + } + >; + + swap( + recipient: string, + zeroForOne: boolean, + amountSpecified: BigNumberish, + sqrtPriceLimitX96: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + tickBitmap( + wordPosition: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tickSpacing(overrides?: CallOverrides): Promise; + + ticks( + tick: BigNumberish, + overrides?: CallOverrides + ): Promise< + [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + number, + boolean + ] & { + liquidityGross: BigNumber; + liquidityNet: BigNumber; + feeGrowthOutside0X128: BigNumber; + feeGrowthOutside1X128: BigNumber; + tickCumulativeOutside: BigNumber; + secondsPerLiquidityOutsideX128: BigNumber; + secondsOutside: number; + initialized: boolean; + } + >; + + token0(overrides?: CallOverrides): Promise; + + token1(overrides?: CallOverrides): Promise; + }; + + filters: { + "Burn(address,int24,int24,uint128,uint256,uint256)"( + owner?: string | null, + tickLower?: BigNumberish | null, + tickUpper?: BigNumberish | null, + amount?: null, + amount0?: null, + amount1?: null + ): BurnEventFilter; + Burn( + owner?: string | null, + tickLower?: BigNumberish | null, + tickUpper?: BigNumberish | null, + amount?: null, + amount0?: null, + amount1?: null + ): BurnEventFilter; + + "Collect(address,address,int24,int24,uint128,uint128)"( + owner?: string | null, + recipient?: null, + tickLower?: BigNumberish | null, + tickUpper?: BigNumberish | null, + amount0?: null, + amount1?: null + ): CollectEventFilter; + Collect( + owner?: string | null, + recipient?: null, + tickLower?: BigNumberish | null, + tickUpper?: BigNumberish | null, + amount0?: null, + amount1?: null + ): CollectEventFilter; + + "CollectProtocol(address,address,uint128,uint128)"( + sender?: string | null, + recipient?: string | null, + amount0?: null, + amount1?: null + ): CollectProtocolEventFilter; + CollectProtocol( + sender?: string | null, + recipient?: string | null, + amount0?: null, + amount1?: null + ): CollectProtocolEventFilter; + + "Flash(address,address,uint256,uint256,uint256,uint256)"( + sender?: string | null, + recipient?: string | null, + amount0?: null, + amount1?: null, + paid0?: null, + paid1?: null + ): FlashEventFilter; + Flash( + sender?: string | null, + recipient?: string | null, + amount0?: null, + amount1?: null, + paid0?: null, + paid1?: null + ): FlashEventFilter; + + "IncreaseObservationCardinalityNext(uint16,uint16)"( + observationCardinalityNextOld?: null, + observationCardinalityNextNew?: null + ): IncreaseObservationCardinalityNextEventFilter; + IncreaseObservationCardinalityNext( + observationCardinalityNextOld?: null, + observationCardinalityNextNew?: null + ): IncreaseObservationCardinalityNextEventFilter; + + "Initialize(uint160,int24)"( + sqrtPriceX96?: null, + tick?: null + ): InitializeEventFilter; + Initialize(sqrtPriceX96?: null, tick?: null): InitializeEventFilter; + + "Mint(address,address,int24,int24,uint128,uint256,uint256)"( + sender?: null, + owner?: string | null, + tickLower?: BigNumberish | null, + tickUpper?: BigNumberish | null, + amount?: null, + amount0?: null, + amount1?: null + ): MintEventFilter; + Mint( + sender?: null, + owner?: string | null, + tickLower?: BigNumberish | null, + tickUpper?: BigNumberish | null, + amount?: null, + amount0?: null, + amount1?: null + ): MintEventFilter; + + "SetFeeProtocol(uint32,uint32,uint32,uint32)"( + feeProtocol0Old?: null, + feeProtocol1Old?: null, + feeProtocol0New?: null, + feeProtocol1New?: null + ): SetFeeProtocolEventFilter; + SetFeeProtocol( + feeProtocol0Old?: null, + feeProtocol1Old?: null, + feeProtocol0New?: null, + feeProtocol1New?: null + ): SetFeeProtocolEventFilter; + + "Swap(address,address,int256,int256,uint160,uint128,int24,uint128,uint128)"( + sender?: string | null, + recipient?: string | null, + amount0?: null, + amount1?: null, + sqrtPriceX96?: null, + liquidity?: null, + tick?: null, + protocolFeesToken0?: null, + protocolFeesToken1?: null + ): SwapEventFilter; + Swap( + sender?: string | null, + recipient?: string | null, + amount0?: null, + amount1?: null, + sqrtPriceX96?: null, + liquidity?: null, + tick?: null, + protocolFeesToken0?: null, + protocolFeesToken1?: null + ): SwapEventFilter; + }; + + estimateGas: { + burn( + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + collect( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + collectProtocol( + recipient: string, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + fee(overrides?: CallOverrides): Promise; + + feeGrowthGlobal0X128(overrides?: CallOverrides): Promise; + + feeGrowthGlobal1X128(overrides?: CallOverrides): Promise; + + flash( + recipient: string, + amount0: BigNumberish, + amount1: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + increaseObservationCardinalityNext( + observationCardinalityNext: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + initialize( + sqrtPriceX96: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + liquidity(overrides?: CallOverrides): Promise; + + maxLiquidityPerTick(overrides?: CallOverrides): Promise; + + mint( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + observations( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + observe( + secondsAgos: BigNumberish[], + overrides?: CallOverrides + ): Promise; + + positions(key: BytesLike, overrides?: CallOverrides): Promise; + + protocolFees(overrides?: CallOverrides): Promise; + + setFeeProtocol( + feeProtocol0: BigNumberish, + feeProtocol1: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + setLmPool( + lmPool: string, + overrides?: Overrides & { from?: string } + ): Promise; + + slot0(overrides?: CallOverrides): Promise; + + snapshotCumulativesInside( + tickLower: BigNumberish, + tickUpper: BigNumberish, + overrides?: CallOverrides + ): Promise; + + swap( + recipient: string, + zeroForOne: boolean, + amountSpecified: BigNumberish, + sqrtPriceLimitX96: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + tickBitmap( + wordPosition: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tickSpacing(overrides?: CallOverrides): Promise; + + ticks(tick: BigNumberish, overrides?: CallOverrides): Promise; + + token0(overrides?: CallOverrides): Promise; + + token1(overrides?: CallOverrides): Promise; + }; + + populateTransaction: { + burn( + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + collect( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + collectProtocol( + recipient: string, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + fee(overrides?: CallOverrides): Promise; + + feeGrowthGlobal0X128( + overrides?: CallOverrides + ): Promise; + + feeGrowthGlobal1X128( + overrides?: CallOverrides + ): Promise; + + flash( + recipient: string, + amount0: BigNumberish, + amount1: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + increaseObservationCardinalityNext( + observationCardinalityNext: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + initialize( + sqrtPriceX96: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + liquidity(overrides?: CallOverrides): Promise; + + maxLiquidityPerTick( + overrides?: CallOverrides + ): Promise; + + mint( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + observations( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + observe( + secondsAgos: BigNumberish[], + overrides?: CallOverrides + ): Promise; + + positions( + key: BytesLike, + overrides?: CallOverrides + ): Promise; + + protocolFees(overrides?: CallOverrides): Promise; + + setFeeProtocol( + feeProtocol0: BigNumberish, + feeProtocol1: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + setLmPool( + lmPool: string, + overrides?: Overrides & { from?: string } + ): Promise; + + slot0(overrides?: CallOverrides): Promise; + + snapshotCumulativesInside( + tickLower: BigNumberish, + tickUpper: BigNumberish, + overrides?: CallOverrides + ): Promise; + + swap( + recipient: string, + zeroForOne: boolean, + amountSpecified: BigNumberish, + sqrtPriceLimitX96: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + tickBitmap( + wordPosition: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tickSpacing(overrides?: CallOverrides): Promise; + + ticks( + tick: BigNumberish, + overrides?: CallOverrides + ): Promise; + + token0(overrides?: CallOverrides): Promise; + + token1(overrides?: CallOverrides): Promise; + }; +} diff --git a/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/callback/IPancakeV3SwapCallback.ts b/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/callback/IPancakeV3SwapCallback.ts new file mode 100644 index 00000000..6ceebcca --- /dev/null +++ b/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/callback/IPancakeV3SwapCallback.ts @@ -0,0 +1,117 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../../common"; + +export interface IPancakeV3SwapCallbackInterface extends utils.Interface { + functions: { + "pancakeV3SwapCallback(int256,int256,bytes)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: "pancakeV3SwapCallback" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "pancakeV3SwapCallback", + values: [BigNumberish, BigNumberish, BytesLike] + ): string; + + decodeFunctionResult( + functionFragment: "pancakeV3SwapCallback", + data: BytesLike + ): Result; + + events: {}; +} + +export interface IPancakeV3SwapCallback extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IPancakeV3SwapCallbackInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + }; + + filters: {}; + + estimateGas: { + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/callback/index.ts b/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/callback/index.ts new file mode 100644 index 00000000..f5122cf8 --- /dev/null +++ b/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/callback/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export type { IPancakeV3SwapCallback } from "./IPancakeV3SwapCallback"; diff --git a/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/index.ts b/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/index.ts new file mode 100644 index 00000000..06989843 --- /dev/null +++ b/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/index.ts @@ -0,0 +1,8 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as callback from "./callback"; +export type { callback }; +import type * as pool from "./pool"; +export type { pool }; +export type { IPancakeV3Pool } from "./IPancakeV3Pool"; diff --git a/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolActions.ts b/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolActions.ts new file mode 100644 index 00000000..be277b4a --- /dev/null +++ b/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolActions.ts @@ -0,0 +1,393 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../../common"; + +export interface IPancakeV3PoolActionsInterface extends utils.Interface { + functions: { + "burn(int24,int24,uint128)": FunctionFragment; + "collect(address,int24,int24,uint128,uint128)": FunctionFragment; + "flash(address,uint256,uint256,bytes)": FunctionFragment; + "increaseObservationCardinalityNext(uint16)": FunctionFragment; + "initialize(uint160)": FunctionFragment; + "mint(address,int24,int24,uint128,bytes)": FunctionFragment; + "swap(address,bool,int256,uint160,bytes)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "burn" + | "collect" + | "flash" + | "increaseObservationCardinalityNext" + | "initialize" + | "mint" + | "swap" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "burn", + values: [BigNumberish, BigNumberish, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "collect", + values: [string, BigNumberish, BigNumberish, BigNumberish, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "flash", + values: [string, BigNumberish, BigNumberish, BytesLike] + ): string; + encodeFunctionData( + functionFragment: "increaseObservationCardinalityNext", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "initialize", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "mint", + values: [string, BigNumberish, BigNumberish, BigNumberish, BytesLike] + ): string; + encodeFunctionData( + functionFragment: "swap", + values: [string, boolean, BigNumberish, BigNumberish, BytesLike] + ): string; + + decodeFunctionResult(functionFragment: "burn", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "collect", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "flash", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "increaseObservationCardinalityNext", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "initialize", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "mint", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "swap", data: BytesLike): Result; + + events: {}; +} + +export interface IPancakeV3PoolActions extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IPancakeV3PoolActionsInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + burn( + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + collect( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + flash( + recipient: string, + amount0: BigNumberish, + amount1: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + increaseObservationCardinalityNext( + observationCardinalityNext: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + initialize( + sqrtPriceX96: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + mint( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + swap( + recipient: string, + zeroForOne: boolean, + amountSpecified: BigNumberish, + sqrtPriceLimitX96: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + burn( + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + collect( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + flash( + recipient: string, + amount0: BigNumberish, + amount1: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + increaseObservationCardinalityNext( + observationCardinalityNext: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + initialize( + sqrtPriceX96: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + mint( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + swap( + recipient: string, + zeroForOne: boolean, + amountSpecified: BigNumberish, + sqrtPriceLimitX96: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + burn( + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + collect( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + flash( + recipient: string, + amount0: BigNumberish, + amount1: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + + increaseObservationCardinalityNext( + observationCardinalityNext: BigNumberish, + overrides?: CallOverrides + ): Promise; + + initialize( + sqrtPriceX96: BigNumberish, + overrides?: CallOverrides + ): Promise; + + mint( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + swap( + recipient: string, + zeroForOne: boolean, + amountSpecified: BigNumberish, + sqrtPriceLimitX96: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + }; + + filters: {}; + + estimateGas: { + burn( + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + collect( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + flash( + recipient: string, + amount0: BigNumberish, + amount1: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + increaseObservationCardinalityNext( + observationCardinalityNext: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + initialize( + sqrtPriceX96: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + mint( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + swap( + recipient: string, + zeroForOne: boolean, + amountSpecified: BigNumberish, + sqrtPriceLimitX96: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + burn( + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + collect( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + flash( + recipient: string, + amount0: BigNumberish, + amount1: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + increaseObservationCardinalityNext( + observationCardinalityNext: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + initialize( + sqrtPriceX96: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + mint( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + swap( + recipient: string, + zeroForOne: boolean, + amountSpecified: BigNumberish, + sqrtPriceLimitX96: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolDerivedState.ts b/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolDerivedState.ts new file mode 100644 index 00000000..99b73a0a --- /dev/null +++ b/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolDerivedState.ts @@ -0,0 +1,174 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../../common"; + +export interface IPancakeV3PoolDerivedStateInterface extends utils.Interface { + functions: { + "observe(uint32[])": FunctionFragment; + "snapshotCumulativesInside(int24,int24)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: "observe" | "snapshotCumulativesInside" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "observe", + values: [BigNumberish[]] + ): string; + encodeFunctionData( + functionFragment: "snapshotCumulativesInside", + values: [BigNumberish, BigNumberish] + ): string; + + decodeFunctionResult(functionFragment: "observe", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "snapshotCumulativesInside", + data: BytesLike + ): Result; + + events: {}; +} + +export interface IPancakeV3PoolDerivedState extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IPancakeV3PoolDerivedStateInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + observe( + secondsAgos: BigNumberish[], + overrides?: CallOverrides + ): Promise< + [BigNumber[], BigNumber[]] & { + tickCumulatives: BigNumber[]; + secondsPerLiquidityCumulativeX128s: BigNumber[]; + } + >; + + snapshotCumulativesInside( + tickLower: BigNumberish, + tickUpper: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, number] & { + tickCumulativeInside: BigNumber; + secondsPerLiquidityInsideX128: BigNumber; + secondsInside: number; + } + >; + }; + + observe( + secondsAgos: BigNumberish[], + overrides?: CallOverrides + ): Promise< + [BigNumber[], BigNumber[]] & { + tickCumulatives: BigNumber[]; + secondsPerLiquidityCumulativeX128s: BigNumber[]; + } + >; + + snapshotCumulativesInside( + tickLower: BigNumberish, + tickUpper: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, number] & { + tickCumulativeInside: BigNumber; + secondsPerLiquidityInsideX128: BigNumber; + secondsInside: number; + } + >; + + callStatic: { + observe( + secondsAgos: BigNumberish[], + overrides?: CallOverrides + ): Promise< + [BigNumber[], BigNumber[]] & { + tickCumulatives: BigNumber[]; + secondsPerLiquidityCumulativeX128s: BigNumber[]; + } + >; + + snapshotCumulativesInside( + tickLower: BigNumberish, + tickUpper: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, number] & { + tickCumulativeInside: BigNumber; + secondsPerLiquidityInsideX128: BigNumber; + secondsInside: number; + } + >; + }; + + filters: {}; + + estimateGas: { + observe( + secondsAgos: BigNumberish[], + overrides?: CallOverrides + ): Promise; + + snapshotCumulativesInside( + tickLower: BigNumberish, + tickUpper: BigNumberish, + overrides?: CallOverrides + ): Promise; + }; + + populateTransaction: { + observe( + secondsAgos: BigNumberish[], + overrides?: CallOverrides + ): Promise; + + snapshotCumulativesInside( + tickLower: BigNumberish, + tickUpper: BigNumberish, + overrides?: CallOverrides + ): Promise; + }; +} diff --git a/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolEvents.ts b/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolEvents.ts new file mode 100644 index 00000000..c8999000 --- /dev/null +++ b/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolEvents.ts @@ -0,0 +1,355 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + Signer, + utils, +} from "ethers"; +import type { EventFragment } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../../common"; + +export interface IPancakeV3PoolEventsInterface extends utils.Interface { + functions: {}; + + events: { + "Burn(address,int24,int24,uint128,uint256,uint256)": EventFragment; + "Collect(address,address,int24,int24,uint128,uint128)": EventFragment; + "CollectProtocol(address,address,uint128,uint128)": EventFragment; + "Flash(address,address,uint256,uint256,uint256,uint256)": EventFragment; + "IncreaseObservationCardinalityNext(uint16,uint16)": EventFragment; + "Initialize(uint160,int24)": EventFragment; + "Mint(address,address,int24,int24,uint128,uint256,uint256)": EventFragment; + "SetFeeProtocol(uint32,uint32,uint32,uint32)": EventFragment; + "Swap(address,address,int256,int256,uint160,uint128,int24,uint128,uint128)": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "Burn"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Collect"): EventFragment; + getEvent(nameOrSignatureOrTopic: "CollectProtocol"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Flash"): EventFragment; + getEvent( + nameOrSignatureOrTopic: "IncreaseObservationCardinalityNext" + ): EventFragment; + getEvent(nameOrSignatureOrTopic: "Initialize"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Mint"): EventFragment; + getEvent(nameOrSignatureOrTopic: "SetFeeProtocol"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Swap"): EventFragment; +} + +export interface BurnEventObject { + owner: string; + tickLower: number; + tickUpper: number; + amount: BigNumber; + amount0: BigNumber; + amount1: BigNumber; +} +export type BurnEvent = TypedEvent< + [string, number, number, BigNumber, BigNumber, BigNumber], + BurnEventObject +>; + +export type BurnEventFilter = TypedEventFilter; + +export interface CollectEventObject { + owner: string; + recipient: string; + tickLower: number; + tickUpper: number; + amount0: BigNumber; + amount1: BigNumber; +} +export type CollectEvent = TypedEvent< + [string, string, number, number, BigNumber, BigNumber], + CollectEventObject +>; + +export type CollectEventFilter = TypedEventFilter; + +export interface CollectProtocolEventObject { + sender: string; + recipient: string; + amount0: BigNumber; + amount1: BigNumber; +} +export type CollectProtocolEvent = TypedEvent< + [string, string, BigNumber, BigNumber], + CollectProtocolEventObject +>; + +export type CollectProtocolEventFilter = TypedEventFilter; + +export interface FlashEventObject { + sender: string; + recipient: string; + amount0: BigNumber; + amount1: BigNumber; + paid0: BigNumber; + paid1: BigNumber; +} +export type FlashEvent = TypedEvent< + [string, string, BigNumber, BigNumber, BigNumber, BigNumber], + FlashEventObject +>; + +export type FlashEventFilter = TypedEventFilter; + +export interface IncreaseObservationCardinalityNextEventObject { + observationCardinalityNextOld: number; + observationCardinalityNextNew: number; +} +export type IncreaseObservationCardinalityNextEvent = TypedEvent< + [number, number], + IncreaseObservationCardinalityNextEventObject +>; + +export type IncreaseObservationCardinalityNextEventFilter = + TypedEventFilter; + +export interface InitializeEventObject { + sqrtPriceX96: BigNumber; + tick: number; +} +export type InitializeEvent = TypedEvent< + [BigNumber, number], + InitializeEventObject +>; + +export type InitializeEventFilter = TypedEventFilter; + +export interface MintEventObject { + sender: string; + owner: string; + tickLower: number; + tickUpper: number; + amount: BigNumber; + amount0: BigNumber; + amount1: BigNumber; +} +export type MintEvent = TypedEvent< + [string, string, number, number, BigNumber, BigNumber, BigNumber], + MintEventObject +>; + +export type MintEventFilter = TypedEventFilter; + +export interface SetFeeProtocolEventObject { + feeProtocol0Old: number; + feeProtocol1Old: number; + feeProtocol0New: number; + feeProtocol1New: number; +} +export type SetFeeProtocolEvent = TypedEvent< + [number, number, number, number], + SetFeeProtocolEventObject +>; + +export type SetFeeProtocolEventFilter = TypedEventFilter; + +export interface SwapEventObject { + sender: string; + recipient: string; + amount0: BigNumber; + amount1: BigNumber; + sqrtPriceX96: BigNumber; + liquidity: BigNumber; + tick: number; + protocolFeesToken0: BigNumber; + protocolFeesToken1: BigNumber; +} +export type SwapEvent = TypedEvent< + [ + string, + string, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + number, + BigNumber, + BigNumber + ], + SwapEventObject +>; + +export type SwapEventFilter = TypedEventFilter; + +export interface IPancakeV3PoolEvents extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IPancakeV3PoolEventsInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: {}; + + callStatic: {}; + + filters: { + "Burn(address,int24,int24,uint128,uint256,uint256)"( + owner?: string | null, + tickLower?: BigNumberish | null, + tickUpper?: BigNumberish | null, + amount?: null, + amount0?: null, + amount1?: null + ): BurnEventFilter; + Burn( + owner?: string | null, + tickLower?: BigNumberish | null, + tickUpper?: BigNumberish | null, + amount?: null, + amount0?: null, + amount1?: null + ): BurnEventFilter; + + "Collect(address,address,int24,int24,uint128,uint128)"( + owner?: string | null, + recipient?: null, + tickLower?: BigNumberish | null, + tickUpper?: BigNumberish | null, + amount0?: null, + amount1?: null + ): CollectEventFilter; + Collect( + owner?: string | null, + recipient?: null, + tickLower?: BigNumberish | null, + tickUpper?: BigNumberish | null, + amount0?: null, + amount1?: null + ): CollectEventFilter; + + "CollectProtocol(address,address,uint128,uint128)"( + sender?: string | null, + recipient?: string | null, + amount0?: null, + amount1?: null + ): CollectProtocolEventFilter; + CollectProtocol( + sender?: string | null, + recipient?: string | null, + amount0?: null, + amount1?: null + ): CollectProtocolEventFilter; + + "Flash(address,address,uint256,uint256,uint256,uint256)"( + sender?: string | null, + recipient?: string | null, + amount0?: null, + amount1?: null, + paid0?: null, + paid1?: null + ): FlashEventFilter; + Flash( + sender?: string | null, + recipient?: string | null, + amount0?: null, + amount1?: null, + paid0?: null, + paid1?: null + ): FlashEventFilter; + + "IncreaseObservationCardinalityNext(uint16,uint16)"( + observationCardinalityNextOld?: null, + observationCardinalityNextNew?: null + ): IncreaseObservationCardinalityNextEventFilter; + IncreaseObservationCardinalityNext( + observationCardinalityNextOld?: null, + observationCardinalityNextNew?: null + ): IncreaseObservationCardinalityNextEventFilter; + + "Initialize(uint160,int24)"( + sqrtPriceX96?: null, + tick?: null + ): InitializeEventFilter; + Initialize(sqrtPriceX96?: null, tick?: null): InitializeEventFilter; + + "Mint(address,address,int24,int24,uint128,uint256,uint256)"( + sender?: null, + owner?: string | null, + tickLower?: BigNumberish | null, + tickUpper?: BigNumberish | null, + amount?: null, + amount0?: null, + amount1?: null + ): MintEventFilter; + Mint( + sender?: null, + owner?: string | null, + tickLower?: BigNumberish | null, + tickUpper?: BigNumberish | null, + amount?: null, + amount0?: null, + amount1?: null + ): MintEventFilter; + + "SetFeeProtocol(uint32,uint32,uint32,uint32)"( + feeProtocol0Old?: null, + feeProtocol1Old?: null, + feeProtocol0New?: null, + feeProtocol1New?: null + ): SetFeeProtocolEventFilter; + SetFeeProtocol( + feeProtocol0Old?: null, + feeProtocol1Old?: null, + feeProtocol0New?: null, + feeProtocol1New?: null + ): SetFeeProtocolEventFilter; + + "Swap(address,address,int256,int256,uint160,uint128,int24,uint128,uint128)"( + sender?: string | null, + recipient?: string | null, + amount0?: null, + amount1?: null, + sqrtPriceX96?: null, + liquidity?: null, + tick?: null, + protocolFeesToken0?: null, + protocolFeesToken1?: null + ): SwapEventFilter; + Swap( + sender?: string | null, + recipient?: string | null, + amount0?: null, + amount1?: null, + sqrtPriceX96?: null, + liquidity?: null, + tick?: null, + protocolFeesToken0?: null, + protocolFeesToken1?: null + ): SwapEventFilter; + }; + + estimateGas: {}; + + populateTransaction: {}; +} diff --git a/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolImmutables.ts b/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolImmutables.ts new file mode 100644 index 00000000..4f742f43 --- /dev/null +++ b/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolImmutables.ts @@ -0,0 +1,168 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BytesLike, + CallOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../../common"; + +export interface IPancakeV3PoolImmutablesInterface extends utils.Interface { + functions: { + "factory()": FunctionFragment; + "fee()": FunctionFragment; + "maxLiquidityPerTick()": FunctionFragment; + "tickSpacing()": FunctionFragment; + "token0()": FunctionFragment; + "token1()": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "factory" + | "fee" + | "maxLiquidityPerTick" + | "tickSpacing" + | "token0" + | "token1" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "factory", values?: undefined): string; + encodeFunctionData(functionFragment: "fee", values?: undefined): string; + encodeFunctionData( + functionFragment: "maxLiquidityPerTick", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "tickSpacing", + values?: undefined + ): string; + encodeFunctionData(functionFragment: "token0", values?: undefined): string; + encodeFunctionData(functionFragment: "token1", values?: undefined): string; + + decodeFunctionResult(functionFragment: "factory", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "fee", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "maxLiquidityPerTick", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "tickSpacing", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "token0", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "token1", data: BytesLike): Result; + + events: {}; +} + +export interface IPancakeV3PoolImmutables extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IPancakeV3PoolImmutablesInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + factory(overrides?: CallOverrides): Promise<[string]>; + + fee(overrides?: CallOverrides): Promise<[number]>; + + maxLiquidityPerTick(overrides?: CallOverrides): Promise<[BigNumber]>; + + tickSpacing(overrides?: CallOverrides): Promise<[number]>; + + token0(overrides?: CallOverrides): Promise<[string]>; + + token1(overrides?: CallOverrides): Promise<[string]>; + }; + + factory(overrides?: CallOverrides): Promise; + + fee(overrides?: CallOverrides): Promise; + + maxLiquidityPerTick(overrides?: CallOverrides): Promise; + + tickSpacing(overrides?: CallOverrides): Promise; + + token0(overrides?: CallOverrides): Promise; + + token1(overrides?: CallOverrides): Promise; + + callStatic: { + factory(overrides?: CallOverrides): Promise; + + fee(overrides?: CallOverrides): Promise; + + maxLiquidityPerTick(overrides?: CallOverrides): Promise; + + tickSpacing(overrides?: CallOverrides): Promise; + + token0(overrides?: CallOverrides): Promise; + + token1(overrides?: CallOverrides): Promise; + }; + + filters: {}; + + estimateGas: { + factory(overrides?: CallOverrides): Promise; + + fee(overrides?: CallOverrides): Promise; + + maxLiquidityPerTick(overrides?: CallOverrides): Promise; + + tickSpacing(overrides?: CallOverrides): Promise; + + token0(overrides?: CallOverrides): Promise; + + token1(overrides?: CallOverrides): Promise; + }; + + populateTransaction: { + factory(overrides?: CallOverrides): Promise; + + fee(overrides?: CallOverrides): Promise; + + maxLiquidityPerTick( + overrides?: CallOverrides + ): Promise; + + tickSpacing(overrides?: CallOverrides): Promise; + + token0(overrides?: CallOverrides): Promise; + + token1(overrides?: CallOverrides): Promise; + }; +} diff --git a/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolOwnerActions.ts b/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolOwnerActions.ts new file mode 100644 index 00000000..d213d756 --- /dev/null +++ b/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolOwnerActions.ts @@ -0,0 +1,183 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../../common"; + +export interface IPancakeV3PoolOwnerActionsInterface extends utils.Interface { + functions: { + "collectProtocol(address,uint128,uint128)": FunctionFragment; + "setFeeProtocol(uint32,uint32)": FunctionFragment; + "setLmPool(address)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: "collectProtocol" | "setFeeProtocol" | "setLmPool" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "collectProtocol", + values: [string, BigNumberish, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "setFeeProtocol", + values: [BigNumberish, BigNumberish] + ): string; + encodeFunctionData(functionFragment: "setLmPool", values: [string]): string; + + decodeFunctionResult( + functionFragment: "collectProtocol", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setFeeProtocol", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "setLmPool", data: BytesLike): Result; + + events: {}; +} + +export interface IPancakeV3PoolOwnerActions extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IPancakeV3PoolOwnerActionsInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + collectProtocol( + recipient: string, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeProtocol( + feeProtocol0: BigNumberish, + feeProtocol1: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + setLmPool( + lmPool: string, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + collectProtocol( + recipient: string, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeProtocol( + feeProtocol0: BigNumberish, + feeProtocol1: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + setLmPool( + lmPool: string, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + collectProtocol( + recipient: string, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + setFeeProtocol( + feeProtocol0: BigNumberish, + feeProtocol1: BigNumberish, + overrides?: CallOverrides + ): Promise; + + setLmPool(lmPool: string, overrides?: CallOverrides): Promise; + }; + + filters: {}; + + estimateGas: { + collectProtocol( + recipient: string, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeProtocol( + feeProtocol0: BigNumberish, + feeProtocol1: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + setLmPool( + lmPool: string, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + collectProtocol( + recipient: string, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeProtocol( + feeProtocol0: BigNumberish, + feeProtocol1: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + setLmPool( + lmPool: string, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolState.ts b/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolState.ts new file mode 100644 index 00000000..cf1970a4 --- /dev/null +++ b/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolState.ts @@ -0,0 +1,436 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../../common"; + +export interface IPancakeV3PoolStateInterface extends utils.Interface { + functions: { + "feeGrowthGlobal0X128()": FunctionFragment; + "feeGrowthGlobal1X128()": FunctionFragment; + "liquidity()": FunctionFragment; + "observations(uint256)": FunctionFragment; + "positions(bytes32)": FunctionFragment; + "protocolFees()": FunctionFragment; + "slot0()": FunctionFragment; + "tickBitmap(int16)": FunctionFragment; + "ticks(int24)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "feeGrowthGlobal0X128" + | "feeGrowthGlobal1X128" + | "liquidity" + | "observations" + | "positions" + | "protocolFees" + | "slot0" + | "tickBitmap" + | "ticks" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "feeGrowthGlobal0X128", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "feeGrowthGlobal1X128", + values?: undefined + ): string; + encodeFunctionData(functionFragment: "liquidity", values?: undefined): string; + encodeFunctionData( + functionFragment: "observations", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "positions", + values: [BytesLike] + ): string; + encodeFunctionData( + functionFragment: "protocolFees", + values?: undefined + ): string; + encodeFunctionData(functionFragment: "slot0", values?: undefined): string; + encodeFunctionData( + functionFragment: "tickBitmap", + values: [BigNumberish] + ): string; + encodeFunctionData(functionFragment: "ticks", values: [BigNumberish]): string; + + decodeFunctionResult( + functionFragment: "feeGrowthGlobal0X128", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "feeGrowthGlobal1X128", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "liquidity", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "observations", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "positions", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "protocolFees", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "slot0", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "tickBitmap", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "ticks", data: BytesLike): Result; + + events: {}; +} + +export interface IPancakeV3PoolState extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IPancakeV3PoolStateInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + feeGrowthGlobal0X128(overrides?: CallOverrides): Promise<[BigNumber]>; + + feeGrowthGlobal1X128(overrides?: CallOverrides): Promise<[BigNumber]>; + + liquidity(overrides?: CallOverrides): Promise<[BigNumber]>; + + observations( + index: BigNumberish, + overrides?: CallOverrides + ): Promise< + [number, BigNumber, BigNumber, boolean] & { + blockTimestamp: number; + tickCumulative: BigNumber; + secondsPerLiquidityCumulativeX128: BigNumber; + initialized: boolean; + } + >; + + positions( + key: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber, BigNumber] & { + _liquidity: BigNumber; + feeGrowthInside0LastX128: BigNumber; + feeGrowthInside1LastX128: BigNumber; + tokensOwed0: BigNumber; + tokensOwed1: BigNumber; + } + >; + + protocolFees( + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { token0: BigNumber; token1: BigNumber } + >; + + slot0( + overrides?: CallOverrides + ): Promise< + [BigNumber, number, number, number, number, number, boolean] & { + sqrtPriceX96: BigNumber; + tick: number; + observationIndex: number; + observationCardinality: number; + observationCardinalityNext: number; + feeProtocol: number; + unlocked: boolean; + } + >; + + tickBitmap( + wordPosition: BigNumberish, + overrides?: CallOverrides + ): Promise<[BigNumber]>; + + ticks( + tick: BigNumberish, + overrides?: CallOverrides + ): Promise< + [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + number, + boolean + ] & { + liquidityGross: BigNumber; + liquidityNet: BigNumber; + feeGrowthOutside0X128: BigNumber; + feeGrowthOutside1X128: BigNumber; + tickCumulativeOutside: BigNumber; + secondsPerLiquidityOutsideX128: BigNumber; + secondsOutside: number; + initialized: boolean; + } + >; + }; + + feeGrowthGlobal0X128(overrides?: CallOverrides): Promise; + + feeGrowthGlobal1X128(overrides?: CallOverrides): Promise; + + liquidity(overrides?: CallOverrides): Promise; + + observations( + index: BigNumberish, + overrides?: CallOverrides + ): Promise< + [number, BigNumber, BigNumber, boolean] & { + blockTimestamp: number; + tickCumulative: BigNumber; + secondsPerLiquidityCumulativeX128: BigNumber; + initialized: boolean; + } + >; + + positions( + key: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber, BigNumber] & { + _liquidity: BigNumber; + feeGrowthInside0LastX128: BigNumber; + feeGrowthInside1LastX128: BigNumber; + tokensOwed0: BigNumber; + tokensOwed1: BigNumber; + } + >; + + protocolFees( + overrides?: CallOverrides + ): Promise<[BigNumber, BigNumber] & { token0: BigNumber; token1: BigNumber }>; + + slot0( + overrides?: CallOverrides + ): Promise< + [BigNumber, number, number, number, number, number, boolean] & { + sqrtPriceX96: BigNumber; + tick: number; + observationIndex: number; + observationCardinality: number; + observationCardinalityNext: number; + feeProtocol: number; + unlocked: boolean; + } + >; + + tickBitmap( + wordPosition: BigNumberish, + overrides?: CallOverrides + ): Promise; + + ticks( + tick: BigNumberish, + overrides?: CallOverrides + ): Promise< + [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + number, + boolean + ] & { + liquidityGross: BigNumber; + liquidityNet: BigNumber; + feeGrowthOutside0X128: BigNumber; + feeGrowthOutside1X128: BigNumber; + tickCumulativeOutside: BigNumber; + secondsPerLiquidityOutsideX128: BigNumber; + secondsOutside: number; + initialized: boolean; + } + >; + + callStatic: { + feeGrowthGlobal0X128(overrides?: CallOverrides): Promise; + + feeGrowthGlobal1X128(overrides?: CallOverrides): Promise; + + liquidity(overrides?: CallOverrides): Promise; + + observations( + index: BigNumberish, + overrides?: CallOverrides + ): Promise< + [number, BigNumber, BigNumber, boolean] & { + blockTimestamp: number; + tickCumulative: BigNumber; + secondsPerLiquidityCumulativeX128: BigNumber; + initialized: boolean; + } + >; + + positions( + key: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber, BigNumber] & { + _liquidity: BigNumber; + feeGrowthInside0LastX128: BigNumber; + feeGrowthInside1LastX128: BigNumber; + tokensOwed0: BigNumber; + tokensOwed1: BigNumber; + } + >; + + protocolFees( + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { token0: BigNumber; token1: BigNumber } + >; + + slot0( + overrides?: CallOverrides + ): Promise< + [BigNumber, number, number, number, number, number, boolean] & { + sqrtPriceX96: BigNumber; + tick: number; + observationIndex: number; + observationCardinality: number; + observationCardinalityNext: number; + feeProtocol: number; + unlocked: boolean; + } + >; + + tickBitmap( + wordPosition: BigNumberish, + overrides?: CallOverrides + ): Promise; + + ticks( + tick: BigNumberish, + overrides?: CallOverrides + ): Promise< + [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + number, + boolean + ] & { + liquidityGross: BigNumber; + liquidityNet: BigNumber; + feeGrowthOutside0X128: BigNumber; + feeGrowthOutside1X128: BigNumber; + tickCumulativeOutside: BigNumber; + secondsPerLiquidityOutsideX128: BigNumber; + secondsOutside: number; + initialized: boolean; + } + >; + }; + + filters: {}; + + estimateGas: { + feeGrowthGlobal0X128(overrides?: CallOverrides): Promise; + + feeGrowthGlobal1X128(overrides?: CallOverrides): Promise; + + liquidity(overrides?: CallOverrides): Promise; + + observations( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + positions(key: BytesLike, overrides?: CallOverrides): Promise; + + protocolFees(overrides?: CallOverrides): Promise; + + slot0(overrides?: CallOverrides): Promise; + + tickBitmap( + wordPosition: BigNumberish, + overrides?: CallOverrides + ): Promise; + + ticks(tick: BigNumberish, overrides?: CallOverrides): Promise; + }; + + populateTransaction: { + feeGrowthGlobal0X128( + overrides?: CallOverrides + ): Promise; + + feeGrowthGlobal1X128( + overrides?: CallOverrides + ): Promise; + + liquidity(overrides?: CallOverrides): Promise; + + observations( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + positions( + key: BytesLike, + overrides?: CallOverrides + ): Promise; + + protocolFees(overrides?: CallOverrides): Promise; + + slot0(overrides?: CallOverrides): Promise; + + tickBitmap( + wordPosition: BigNumberish, + overrides?: CallOverrides + ): Promise; + + ticks( + tick: BigNumberish, + overrides?: CallOverrides + ): Promise; + }; +} diff --git a/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/pool/index.ts b/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/pool/index.ts new file mode 100644 index 00000000..2012f9cf --- /dev/null +++ b/src/typechain-typesV4/@pancakeswap/v3-core/contracts/interfaces/pool/index.ts @@ -0,0 +1,9 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export type { IPancakeV3PoolActions } from "./IPancakeV3PoolActions"; +export type { IPancakeV3PoolDerivedState } from "./IPancakeV3PoolDerivedState"; +export type { IPancakeV3PoolEvents } from "./IPancakeV3PoolEvents"; +export type { IPancakeV3PoolImmutables } from "./IPancakeV3PoolImmutables"; +export type { IPancakeV3PoolOwnerActions } from "./IPancakeV3PoolOwnerActions"; +export type { IPancakeV3PoolState } from "./IPancakeV3PoolState"; diff --git a/src/typechain-typesV4/@pancakeswap/v3-core/index.ts b/src/typechain-typesV4/@pancakeswap/v3-core/index.ts new file mode 100644 index 00000000..a11e4ca2 --- /dev/null +++ b/src/typechain-typesV4/@pancakeswap/v3-core/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as contracts from "./contracts"; +export type { contracts }; diff --git a/src/typechain-typesV4/@uniswap/index.ts b/src/typechain-typesV4/@uniswap/index.ts new file mode 100644 index 00000000..620b30bb --- /dev/null +++ b/src/typechain-typesV4/@uniswap/index.ts @@ -0,0 +1,7 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as v3Core from "./v3-core"; +export type { v3Core }; +import type * as v3Periphery from "./v3-periphery"; +export type { v3Periphery }; diff --git a/src/typechain-typesV4/@uniswap/v3-core/contracts/index.ts b/src/typechain-typesV4/@uniswap/v3-core/contracts/index.ts new file mode 100644 index 00000000..92159233 --- /dev/null +++ b/src/typechain-typesV4/@uniswap/v3-core/contracts/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as interfaces from "./interfaces"; +export type { interfaces }; diff --git a/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/IUniswapV3Pool.ts b/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/IUniswapV3Pool.ts new file mode 100644 index 00000000..c09ec534 --- /dev/null +++ b/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/IUniswapV3Pool.ts @@ -0,0 +1,1330 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../common"; + +export interface IUniswapV3PoolInterface extends utils.Interface { + functions: { + "burn(int24,int24,uint128)": FunctionFragment; + "collect(address,int24,int24,uint128,uint128)": FunctionFragment; + "collectProtocol(address,uint128,uint128)": FunctionFragment; + "factory()": FunctionFragment; + "fee()": FunctionFragment; + "feeGrowthGlobal0X128()": FunctionFragment; + "feeGrowthGlobal1X128()": FunctionFragment; + "flash(address,uint256,uint256,bytes)": FunctionFragment; + "increaseObservationCardinalityNext(uint16)": FunctionFragment; + "initialize(uint160)": FunctionFragment; + "liquidity()": FunctionFragment; + "maxLiquidityPerTick()": FunctionFragment; + "mint(address,int24,int24,uint128,bytes)": FunctionFragment; + "observations(uint256)": FunctionFragment; + "observe(uint32[])": FunctionFragment; + "positions(bytes32)": FunctionFragment; + "protocolFees()": FunctionFragment; + "setFeeProtocol(uint8,uint8)": FunctionFragment; + "slot0()": FunctionFragment; + "snapshotCumulativesInside(int24,int24)": FunctionFragment; + "swap(address,bool,int256,uint160,bytes)": FunctionFragment; + "tickBitmap(int16)": FunctionFragment; + "tickSpacing()": FunctionFragment; + "ticks(int24)": FunctionFragment; + "token0()": FunctionFragment; + "token1()": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "burn" + | "collect" + | "collectProtocol" + | "factory" + | "fee" + | "feeGrowthGlobal0X128" + | "feeGrowthGlobal1X128" + | "flash" + | "increaseObservationCardinalityNext" + | "initialize" + | "liquidity" + | "maxLiquidityPerTick" + | "mint" + | "observations" + | "observe" + | "positions" + | "protocolFees" + | "setFeeProtocol" + | "slot0" + | "snapshotCumulativesInside" + | "swap" + | "tickBitmap" + | "tickSpacing" + | "ticks" + | "token0" + | "token1" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "burn", + values: [BigNumberish, BigNumberish, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "collect", + values: [string, BigNumberish, BigNumberish, BigNumberish, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "collectProtocol", + values: [string, BigNumberish, BigNumberish] + ): string; + encodeFunctionData(functionFragment: "factory", values?: undefined): string; + encodeFunctionData(functionFragment: "fee", values?: undefined): string; + encodeFunctionData( + functionFragment: "feeGrowthGlobal0X128", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "feeGrowthGlobal1X128", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "flash", + values: [string, BigNumberish, BigNumberish, BytesLike] + ): string; + encodeFunctionData( + functionFragment: "increaseObservationCardinalityNext", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "initialize", + values: [BigNumberish] + ): string; + encodeFunctionData(functionFragment: "liquidity", values?: undefined): string; + encodeFunctionData( + functionFragment: "maxLiquidityPerTick", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "mint", + values: [string, BigNumberish, BigNumberish, BigNumberish, BytesLike] + ): string; + encodeFunctionData( + functionFragment: "observations", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "observe", + values: [BigNumberish[]] + ): string; + encodeFunctionData( + functionFragment: "positions", + values: [BytesLike] + ): string; + encodeFunctionData( + functionFragment: "protocolFees", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "setFeeProtocol", + values: [BigNumberish, BigNumberish] + ): string; + encodeFunctionData(functionFragment: "slot0", values?: undefined): string; + encodeFunctionData( + functionFragment: "snapshotCumulativesInside", + values: [BigNumberish, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "swap", + values: [string, boolean, BigNumberish, BigNumberish, BytesLike] + ): string; + encodeFunctionData( + functionFragment: "tickBitmap", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "tickSpacing", + values?: undefined + ): string; + encodeFunctionData(functionFragment: "ticks", values: [BigNumberish]): string; + encodeFunctionData(functionFragment: "token0", values?: undefined): string; + encodeFunctionData(functionFragment: "token1", values?: undefined): string; + + decodeFunctionResult(functionFragment: "burn", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "collect", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "collectProtocol", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "factory", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "fee", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "feeGrowthGlobal0X128", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "feeGrowthGlobal1X128", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "flash", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "increaseObservationCardinalityNext", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "initialize", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "liquidity", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "maxLiquidityPerTick", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "mint", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "observations", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "observe", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "positions", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "protocolFees", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setFeeProtocol", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "slot0", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "snapshotCumulativesInside", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "swap", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "tickBitmap", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "tickSpacing", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "ticks", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "token0", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "token1", data: BytesLike): Result; + + events: { + "Burn(address,int24,int24,uint128,uint256,uint256)": EventFragment; + "Collect(address,address,int24,int24,uint128,uint128)": EventFragment; + "CollectProtocol(address,address,uint128,uint128)": EventFragment; + "Flash(address,address,uint256,uint256,uint256,uint256)": EventFragment; + "IncreaseObservationCardinalityNext(uint16,uint16)": EventFragment; + "Initialize(uint160,int24)": EventFragment; + "Mint(address,address,int24,int24,uint128,uint256,uint256)": EventFragment; + "SetFeeProtocol(uint8,uint8,uint8,uint8)": EventFragment; + "Swap(address,address,int256,int256,uint160,uint128,int24)": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "Burn"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Collect"): EventFragment; + getEvent(nameOrSignatureOrTopic: "CollectProtocol"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Flash"): EventFragment; + getEvent( + nameOrSignatureOrTopic: "IncreaseObservationCardinalityNext" + ): EventFragment; + getEvent(nameOrSignatureOrTopic: "Initialize"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Mint"): EventFragment; + getEvent(nameOrSignatureOrTopic: "SetFeeProtocol"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Swap"): EventFragment; +} + +export interface BurnEventObject { + owner: string; + tickLower: number; + tickUpper: number; + amount: BigNumber; + amount0: BigNumber; + amount1: BigNumber; +} +export type BurnEvent = TypedEvent< + [string, number, number, BigNumber, BigNumber, BigNumber], + BurnEventObject +>; + +export type BurnEventFilter = TypedEventFilter; + +export interface CollectEventObject { + owner: string; + recipient: string; + tickLower: number; + tickUpper: number; + amount0: BigNumber; + amount1: BigNumber; +} +export type CollectEvent = TypedEvent< + [string, string, number, number, BigNumber, BigNumber], + CollectEventObject +>; + +export type CollectEventFilter = TypedEventFilter; + +export interface CollectProtocolEventObject { + sender: string; + recipient: string; + amount0: BigNumber; + amount1: BigNumber; +} +export type CollectProtocolEvent = TypedEvent< + [string, string, BigNumber, BigNumber], + CollectProtocolEventObject +>; + +export type CollectProtocolEventFilter = TypedEventFilter; + +export interface FlashEventObject { + sender: string; + recipient: string; + amount0: BigNumber; + amount1: BigNumber; + paid0: BigNumber; + paid1: BigNumber; +} +export type FlashEvent = TypedEvent< + [string, string, BigNumber, BigNumber, BigNumber, BigNumber], + FlashEventObject +>; + +export type FlashEventFilter = TypedEventFilter; + +export interface IncreaseObservationCardinalityNextEventObject { + observationCardinalityNextOld: number; + observationCardinalityNextNew: number; +} +export type IncreaseObservationCardinalityNextEvent = TypedEvent< + [number, number], + IncreaseObservationCardinalityNextEventObject +>; + +export type IncreaseObservationCardinalityNextEventFilter = + TypedEventFilter; + +export interface InitializeEventObject { + sqrtPriceX96: BigNumber; + tick: number; +} +export type InitializeEvent = TypedEvent< + [BigNumber, number], + InitializeEventObject +>; + +export type InitializeEventFilter = TypedEventFilter; + +export interface MintEventObject { + sender: string; + owner: string; + tickLower: number; + tickUpper: number; + amount: BigNumber; + amount0: BigNumber; + amount1: BigNumber; +} +export type MintEvent = TypedEvent< + [string, string, number, number, BigNumber, BigNumber, BigNumber], + MintEventObject +>; + +export type MintEventFilter = TypedEventFilter; + +export interface SetFeeProtocolEventObject { + feeProtocol0Old: number; + feeProtocol1Old: number; + feeProtocol0New: number; + feeProtocol1New: number; +} +export type SetFeeProtocolEvent = TypedEvent< + [number, number, number, number], + SetFeeProtocolEventObject +>; + +export type SetFeeProtocolEventFilter = TypedEventFilter; + +export interface SwapEventObject { + sender: string; + recipient: string; + amount0: BigNumber; + amount1: BigNumber; + sqrtPriceX96: BigNumber; + liquidity: BigNumber; + tick: number; +} +export type SwapEvent = TypedEvent< + [string, string, BigNumber, BigNumber, BigNumber, BigNumber, number], + SwapEventObject +>; + +export type SwapEventFilter = TypedEventFilter; + +export interface IUniswapV3Pool extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IUniswapV3PoolInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + burn( + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + collect( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + collectProtocol( + recipient: string, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise<[string]>; + + fee(overrides?: CallOverrides): Promise<[number]>; + + feeGrowthGlobal0X128(overrides?: CallOverrides): Promise<[BigNumber]>; + + feeGrowthGlobal1X128(overrides?: CallOverrides): Promise<[BigNumber]>; + + flash( + recipient: string, + amount0: BigNumberish, + amount1: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + increaseObservationCardinalityNext( + observationCardinalityNext: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + initialize( + sqrtPriceX96: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + liquidity(overrides?: CallOverrides): Promise<[BigNumber]>; + + maxLiquidityPerTick(overrides?: CallOverrides): Promise<[BigNumber]>; + + mint( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + observations( + index: BigNumberish, + overrides?: CallOverrides + ): Promise< + [number, BigNumber, BigNumber, boolean] & { + blockTimestamp: number; + tickCumulative: BigNumber; + secondsPerLiquidityCumulativeX128: BigNumber; + initialized: boolean; + } + >; + + observe( + secondsAgos: BigNumberish[], + overrides?: CallOverrides + ): Promise< + [BigNumber[], BigNumber[]] & { + tickCumulatives: BigNumber[]; + secondsPerLiquidityCumulativeX128s: BigNumber[]; + } + >; + + positions( + key: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber, BigNumber] & { + _liquidity: BigNumber; + feeGrowthInside0LastX128: BigNumber; + feeGrowthInside1LastX128: BigNumber; + tokensOwed0: BigNumber; + tokensOwed1: BigNumber; + } + >; + + protocolFees( + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { token0: BigNumber; token1: BigNumber } + >; + + setFeeProtocol( + feeProtocol0: BigNumberish, + feeProtocol1: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + slot0( + overrides?: CallOverrides + ): Promise< + [BigNumber, number, number, number, number, number, boolean] & { + sqrtPriceX96: BigNumber; + tick: number; + observationIndex: number; + observationCardinality: number; + observationCardinalityNext: number; + feeProtocol: number; + unlocked: boolean; + } + >; + + snapshotCumulativesInside( + tickLower: BigNumberish, + tickUpper: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, number] & { + tickCumulativeInside: BigNumber; + secondsPerLiquidityInsideX128: BigNumber; + secondsInside: number; + } + >; + + swap( + recipient: string, + zeroForOne: boolean, + amountSpecified: BigNumberish, + sqrtPriceLimitX96: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + tickBitmap( + wordPosition: BigNumberish, + overrides?: CallOverrides + ): Promise<[BigNumber]>; + + tickSpacing(overrides?: CallOverrides): Promise<[number]>; + + ticks( + tick: BigNumberish, + overrides?: CallOverrides + ): Promise< + [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + number, + boolean + ] & { + liquidityGross: BigNumber; + liquidityNet: BigNumber; + feeGrowthOutside0X128: BigNumber; + feeGrowthOutside1X128: BigNumber; + tickCumulativeOutside: BigNumber; + secondsPerLiquidityOutsideX128: BigNumber; + secondsOutside: number; + initialized: boolean; + } + >; + + token0(overrides?: CallOverrides): Promise<[string]>; + + token1(overrides?: CallOverrides): Promise<[string]>; + }; + + burn( + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + collect( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + collectProtocol( + recipient: string, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + fee(overrides?: CallOverrides): Promise; + + feeGrowthGlobal0X128(overrides?: CallOverrides): Promise; + + feeGrowthGlobal1X128(overrides?: CallOverrides): Promise; + + flash( + recipient: string, + amount0: BigNumberish, + amount1: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + increaseObservationCardinalityNext( + observationCardinalityNext: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + initialize( + sqrtPriceX96: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + liquidity(overrides?: CallOverrides): Promise; + + maxLiquidityPerTick(overrides?: CallOverrides): Promise; + + mint( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + observations( + index: BigNumberish, + overrides?: CallOverrides + ): Promise< + [number, BigNumber, BigNumber, boolean] & { + blockTimestamp: number; + tickCumulative: BigNumber; + secondsPerLiquidityCumulativeX128: BigNumber; + initialized: boolean; + } + >; + + observe( + secondsAgos: BigNumberish[], + overrides?: CallOverrides + ): Promise< + [BigNumber[], BigNumber[]] & { + tickCumulatives: BigNumber[]; + secondsPerLiquidityCumulativeX128s: BigNumber[]; + } + >; + + positions( + key: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber, BigNumber] & { + _liquidity: BigNumber; + feeGrowthInside0LastX128: BigNumber; + feeGrowthInside1LastX128: BigNumber; + tokensOwed0: BigNumber; + tokensOwed1: BigNumber; + } + >; + + protocolFees( + overrides?: CallOverrides + ): Promise<[BigNumber, BigNumber] & { token0: BigNumber; token1: BigNumber }>; + + setFeeProtocol( + feeProtocol0: BigNumberish, + feeProtocol1: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + slot0( + overrides?: CallOverrides + ): Promise< + [BigNumber, number, number, number, number, number, boolean] & { + sqrtPriceX96: BigNumber; + tick: number; + observationIndex: number; + observationCardinality: number; + observationCardinalityNext: number; + feeProtocol: number; + unlocked: boolean; + } + >; + + snapshotCumulativesInside( + tickLower: BigNumberish, + tickUpper: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, number] & { + tickCumulativeInside: BigNumber; + secondsPerLiquidityInsideX128: BigNumber; + secondsInside: number; + } + >; + + swap( + recipient: string, + zeroForOne: boolean, + amountSpecified: BigNumberish, + sqrtPriceLimitX96: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + tickBitmap( + wordPosition: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tickSpacing(overrides?: CallOverrides): Promise; + + ticks( + tick: BigNumberish, + overrides?: CallOverrides + ): Promise< + [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + number, + boolean + ] & { + liquidityGross: BigNumber; + liquidityNet: BigNumber; + feeGrowthOutside0X128: BigNumber; + feeGrowthOutside1X128: BigNumber; + tickCumulativeOutside: BigNumber; + secondsPerLiquidityOutsideX128: BigNumber; + secondsOutside: number; + initialized: boolean; + } + >; + + token0(overrides?: CallOverrides): Promise; + + token1(overrides?: CallOverrides): Promise; + + callStatic: { + burn( + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + collect( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + collectProtocol( + recipient: string, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + factory(overrides?: CallOverrides): Promise; + + fee(overrides?: CallOverrides): Promise; + + feeGrowthGlobal0X128(overrides?: CallOverrides): Promise; + + feeGrowthGlobal1X128(overrides?: CallOverrides): Promise; + + flash( + recipient: string, + amount0: BigNumberish, + amount1: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + + increaseObservationCardinalityNext( + observationCardinalityNext: BigNumberish, + overrides?: CallOverrides + ): Promise; + + initialize( + sqrtPriceX96: BigNumberish, + overrides?: CallOverrides + ): Promise; + + liquidity(overrides?: CallOverrides): Promise; + + maxLiquidityPerTick(overrides?: CallOverrides): Promise; + + mint( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + observations( + index: BigNumberish, + overrides?: CallOverrides + ): Promise< + [number, BigNumber, BigNumber, boolean] & { + blockTimestamp: number; + tickCumulative: BigNumber; + secondsPerLiquidityCumulativeX128: BigNumber; + initialized: boolean; + } + >; + + observe( + secondsAgos: BigNumberish[], + overrides?: CallOverrides + ): Promise< + [BigNumber[], BigNumber[]] & { + tickCumulatives: BigNumber[]; + secondsPerLiquidityCumulativeX128s: BigNumber[]; + } + >; + + positions( + key: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber, BigNumber] & { + _liquidity: BigNumber; + feeGrowthInside0LastX128: BigNumber; + feeGrowthInside1LastX128: BigNumber; + tokensOwed0: BigNumber; + tokensOwed1: BigNumber; + } + >; + + protocolFees( + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { token0: BigNumber; token1: BigNumber } + >; + + setFeeProtocol( + feeProtocol0: BigNumberish, + feeProtocol1: BigNumberish, + overrides?: CallOverrides + ): Promise; + + slot0( + overrides?: CallOverrides + ): Promise< + [BigNumber, number, number, number, number, number, boolean] & { + sqrtPriceX96: BigNumber; + tick: number; + observationIndex: number; + observationCardinality: number; + observationCardinalityNext: number; + feeProtocol: number; + unlocked: boolean; + } + >; + + snapshotCumulativesInside( + tickLower: BigNumberish, + tickUpper: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, number] & { + tickCumulativeInside: BigNumber; + secondsPerLiquidityInsideX128: BigNumber; + secondsInside: number; + } + >; + + swap( + recipient: string, + zeroForOne: boolean, + amountSpecified: BigNumberish, + sqrtPriceLimitX96: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + tickBitmap( + wordPosition: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tickSpacing(overrides?: CallOverrides): Promise; + + ticks( + tick: BigNumberish, + overrides?: CallOverrides + ): Promise< + [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + number, + boolean + ] & { + liquidityGross: BigNumber; + liquidityNet: BigNumber; + feeGrowthOutside0X128: BigNumber; + feeGrowthOutside1X128: BigNumber; + tickCumulativeOutside: BigNumber; + secondsPerLiquidityOutsideX128: BigNumber; + secondsOutside: number; + initialized: boolean; + } + >; + + token0(overrides?: CallOverrides): Promise; + + token1(overrides?: CallOverrides): Promise; + }; + + filters: { + "Burn(address,int24,int24,uint128,uint256,uint256)"( + owner?: string | null, + tickLower?: BigNumberish | null, + tickUpper?: BigNumberish | null, + amount?: null, + amount0?: null, + amount1?: null + ): BurnEventFilter; + Burn( + owner?: string | null, + tickLower?: BigNumberish | null, + tickUpper?: BigNumberish | null, + amount?: null, + amount0?: null, + amount1?: null + ): BurnEventFilter; + + "Collect(address,address,int24,int24,uint128,uint128)"( + owner?: string | null, + recipient?: null, + tickLower?: BigNumberish | null, + tickUpper?: BigNumberish | null, + amount0?: null, + amount1?: null + ): CollectEventFilter; + Collect( + owner?: string | null, + recipient?: null, + tickLower?: BigNumberish | null, + tickUpper?: BigNumberish | null, + amount0?: null, + amount1?: null + ): CollectEventFilter; + + "CollectProtocol(address,address,uint128,uint128)"( + sender?: string | null, + recipient?: string | null, + amount0?: null, + amount1?: null + ): CollectProtocolEventFilter; + CollectProtocol( + sender?: string | null, + recipient?: string | null, + amount0?: null, + amount1?: null + ): CollectProtocolEventFilter; + + "Flash(address,address,uint256,uint256,uint256,uint256)"( + sender?: string | null, + recipient?: string | null, + amount0?: null, + amount1?: null, + paid0?: null, + paid1?: null + ): FlashEventFilter; + Flash( + sender?: string | null, + recipient?: string | null, + amount0?: null, + amount1?: null, + paid0?: null, + paid1?: null + ): FlashEventFilter; + + "IncreaseObservationCardinalityNext(uint16,uint16)"( + observationCardinalityNextOld?: null, + observationCardinalityNextNew?: null + ): IncreaseObservationCardinalityNextEventFilter; + IncreaseObservationCardinalityNext( + observationCardinalityNextOld?: null, + observationCardinalityNextNew?: null + ): IncreaseObservationCardinalityNextEventFilter; + + "Initialize(uint160,int24)"( + sqrtPriceX96?: null, + tick?: null + ): InitializeEventFilter; + Initialize(sqrtPriceX96?: null, tick?: null): InitializeEventFilter; + + "Mint(address,address,int24,int24,uint128,uint256,uint256)"( + sender?: null, + owner?: string | null, + tickLower?: BigNumberish | null, + tickUpper?: BigNumberish | null, + amount?: null, + amount0?: null, + amount1?: null + ): MintEventFilter; + Mint( + sender?: null, + owner?: string | null, + tickLower?: BigNumberish | null, + tickUpper?: BigNumberish | null, + amount?: null, + amount0?: null, + amount1?: null + ): MintEventFilter; + + "SetFeeProtocol(uint8,uint8,uint8,uint8)"( + feeProtocol0Old?: null, + feeProtocol1Old?: null, + feeProtocol0New?: null, + feeProtocol1New?: null + ): SetFeeProtocolEventFilter; + SetFeeProtocol( + feeProtocol0Old?: null, + feeProtocol1Old?: null, + feeProtocol0New?: null, + feeProtocol1New?: null + ): SetFeeProtocolEventFilter; + + "Swap(address,address,int256,int256,uint160,uint128,int24)"( + sender?: string | null, + recipient?: string | null, + amount0?: null, + amount1?: null, + sqrtPriceX96?: null, + liquidity?: null, + tick?: null + ): SwapEventFilter; + Swap( + sender?: string | null, + recipient?: string | null, + amount0?: null, + amount1?: null, + sqrtPriceX96?: null, + liquidity?: null, + tick?: null + ): SwapEventFilter; + }; + + estimateGas: { + burn( + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + collect( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + collectProtocol( + recipient: string, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + fee(overrides?: CallOverrides): Promise; + + feeGrowthGlobal0X128(overrides?: CallOverrides): Promise; + + feeGrowthGlobal1X128(overrides?: CallOverrides): Promise; + + flash( + recipient: string, + amount0: BigNumberish, + amount1: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + increaseObservationCardinalityNext( + observationCardinalityNext: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + initialize( + sqrtPriceX96: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + liquidity(overrides?: CallOverrides): Promise; + + maxLiquidityPerTick(overrides?: CallOverrides): Promise; + + mint( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + observations( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + observe( + secondsAgos: BigNumberish[], + overrides?: CallOverrides + ): Promise; + + positions(key: BytesLike, overrides?: CallOverrides): Promise; + + protocolFees(overrides?: CallOverrides): Promise; + + setFeeProtocol( + feeProtocol0: BigNumberish, + feeProtocol1: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + slot0(overrides?: CallOverrides): Promise; + + snapshotCumulativesInside( + tickLower: BigNumberish, + tickUpper: BigNumberish, + overrides?: CallOverrides + ): Promise; + + swap( + recipient: string, + zeroForOne: boolean, + amountSpecified: BigNumberish, + sqrtPriceLimitX96: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + tickBitmap( + wordPosition: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tickSpacing(overrides?: CallOverrides): Promise; + + ticks(tick: BigNumberish, overrides?: CallOverrides): Promise; + + token0(overrides?: CallOverrides): Promise; + + token1(overrides?: CallOverrides): Promise; + }; + + populateTransaction: { + burn( + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + collect( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + collectProtocol( + recipient: string, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + fee(overrides?: CallOverrides): Promise; + + feeGrowthGlobal0X128( + overrides?: CallOverrides + ): Promise; + + feeGrowthGlobal1X128( + overrides?: CallOverrides + ): Promise; + + flash( + recipient: string, + amount0: BigNumberish, + amount1: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + increaseObservationCardinalityNext( + observationCardinalityNext: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + initialize( + sqrtPriceX96: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + liquidity(overrides?: CallOverrides): Promise; + + maxLiquidityPerTick( + overrides?: CallOverrides + ): Promise; + + mint( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + observations( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + observe( + secondsAgos: BigNumberish[], + overrides?: CallOverrides + ): Promise; + + positions( + key: BytesLike, + overrides?: CallOverrides + ): Promise; + + protocolFees(overrides?: CallOverrides): Promise; + + setFeeProtocol( + feeProtocol0: BigNumberish, + feeProtocol1: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + slot0(overrides?: CallOverrides): Promise; + + snapshotCumulativesInside( + tickLower: BigNumberish, + tickUpper: BigNumberish, + overrides?: CallOverrides + ): Promise; + + swap( + recipient: string, + zeroForOne: boolean, + amountSpecified: BigNumberish, + sqrtPriceLimitX96: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + tickBitmap( + wordPosition: BigNumberish, + overrides?: CallOverrides + ): Promise; + + tickSpacing(overrides?: CallOverrides): Promise; + + ticks( + tick: BigNumberish, + overrides?: CallOverrides + ): Promise; + + token0(overrides?: CallOverrides): Promise; + + token1(overrides?: CallOverrides): Promise; + }; +} diff --git a/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/callback/IUniswapV3SwapCallback.ts b/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/callback/IUniswapV3SwapCallback.ts new file mode 100644 index 00000000..c972298a --- /dev/null +++ b/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/callback/IUniswapV3SwapCallback.ts @@ -0,0 +1,117 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../../common"; + +export interface IUniswapV3SwapCallbackInterface extends utils.Interface { + functions: { + "uniswapV3SwapCallback(int256,int256,bytes)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: "uniswapV3SwapCallback" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "uniswapV3SwapCallback", + values: [BigNumberish, BigNumberish, BytesLike] + ): string; + + decodeFunctionResult( + functionFragment: "uniswapV3SwapCallback", + data: BytesLike + ): Result; + + events: {}; +} + +export interface IUniswapV3SwapCallback extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IUniswapV3SwapCallbackInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + }; + + filters: {}; + + estimateGas: { + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/callback/index.ts b/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/callback/index.ts new file mode 100644 index 00000000..c552691c --- /dev/null +++ b/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/callback/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export type { IUniswapV3SwapCallback } from "./IUniswapV3SwapCallback"; diff --git a/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/index.ts b/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/index.ts new file mode 100644 index 00000000..c72a7fff --- /dev/null +++ b/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/index.ts @@ -0,0 +1,8 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as callback from "./callback"; +export type { callback }; +import type * as pool from "./pool"; +export type { pool }; +export type { IUniswapV3Pool } from "./IUniswapV3Pool"; diff --git a/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolActions.ts b/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolActions.ts new file mode 100644 index 00000000..dbadee5b --- /dev/null +++ b/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolActions.ts @@ -0,0 +1,393 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../../common"; + +export interface IUniswapV3PoolActionsInterface extends utils.Interface { + functions: { + "burn(int24,int24,uint128)": FunctionFragment; + "collect(address,int24,int24,uint128,uint128)": FunctionFragment; + "flash(address,uint256,uint256,bytes)": FunctionFragment; + "increaseObservationCardinalityNext(uint16)": FunctionFragment; + "initialize(uint160)": FunctionFragment; + "mint(address,int24,int24,uint128,bytes)": FunctionFragment; + "swap(address,bool,int256,uint160,bytes)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "burn" + | "collect" + | "flash" + | "increaseObservationCardinalityNext" + | "initialize" + | "mint" + | "swap" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "burn", + values: [BigNumberish, BigNumberish, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "collect", + values: [string, BigNumberish, BigNumberish, BigNumberish, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "flash", + values: [string, BigNumberish, BigNumberish, BytesLike] + ): string; + encodeFunctionData( + functionFragment: "increaseObservationCardinalityNext", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "initialize", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "mint", + values: [string, BigNumberish, BigNumberish, BigNumberish, BytesLike] + ): string; + encodeFunctionData( + functionFragment: "swap", + values: [string, boolean, BigNumberish, BigNumberish, BytesLike] + ): string; + + decodeFunctionResult(functionFragment: "burn", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "collect", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "flash", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "increaseObservationCardinalityNext", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "initialize", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "mint", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "swap", data: BytesLike): Result; + + events: {}; +} + +export interface IUniswapV3PoolActions extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IUniswapV3PoolActionsInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + burn( + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + collect( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + flash( + recipient: string, + amount0: BigNumberish, + amount1: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + increaseObservationCardinalityNext( + observationCardinalityNext: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + initialize( + sqrtPriceX96: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + mint( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + swap( + recipient: string, + zeroForOne: boolean, + amountSpecified: BigNumberish, + sqrtPriceLimitX96: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + burn( + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + collect( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + flash( + recipient: string, + amount0: BigNumberish, + amount1: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + increaseObservationCardinalityNext( + observationCardinalityNext: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + initialize( + sqrtPriceX96: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + mint( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + swap( + recipient: string, + zeroForOne: boolean, + amountSpecified: BigNumberish, + sqrtPriceLimitX96: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + burn( + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + collect( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + flash( + recipient: string, + amount0: BigNumberish, + amount1: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + + increaseObservationCardinalityNext( + observationCardinalityNext: BigNumberish, + overrides?: CallOverrides + ): Promise; + + initialize( + sqrtPriceX96: BigNumberish, + overrides?: CallOverrides + ): Promise; + + mint( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + swap( + recipient: string, + zeroForOne: boolean, + amountSpecified: BigNumberish, + sqrtPriceLimitX96: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + }; + + filters: {}; + + estimateGas: { + burn( + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + collect( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + flash( + recipient: string, + amount0: BigNumberish, + amount1: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + increaseObservationCardinalityNext( + observationCardinalityNext: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + initialize( + sqrtPriceX96: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + mint( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + swap( + recipient: string, + zeroForOne: boolean, + amountSpecified: BigNumberish, + sqrtPriceLimitX96: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + burn( + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + collect( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + flash( + recipient: string, + amount0: BigNumberish, + amount1: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + increaseObservationCardinalityNext( + observationCardinalityNext: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + initialize( + sqrtPriceX96: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + mint( + recipient: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + swap( + recipient: string, + zeroForOne: boolean, + amountSpecified: BigNumberish, + sqrtPriceLimitX96: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolDerivedState.ts b/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolDerivedState.ts new file mode 100644 index 00000000..16e49cf2 --- /dev/null +++ b/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolDerivedState.ts @@ -0,0 +1,174 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../../common"; + +export interface IUniswapV3PoolDerivedStateInterface extends utils.Interface { + functions: { + "observe(uint32[])": FunctionFragment; + "snapshotCumulativesInside(int24,int24)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: "observe" | "snapshotCumulativesInside" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "observe", + values: [BigNumberish[]] + ): string; + encodeFunctionData( + functionFragment: "snapshotCumulativesInside", + values: [BigNumberish, BigNumberish] + ): string; + + decodeFunctionResult(functionFragment: "observe", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "snapshotCumulativesInside", + data: BytesLike + ): Result; + + events: {}; +} + +export interface IUniswapV3PoolDerivedState extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IUniswapV3PoolDerivedStateInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + observe( + secondsAgos: BigNumberish[], + overrides?: CallOverrides + ): Promise< + [BigNumber[], BigNumber[]] & { + tickCumulatives: BigNumber[]; + secondsPerLiquidityCumulativeX128s: BigNumber[]; + } + >; + + snapshotCumulativesInside( + tickLower: BigNumberish, + tickUpper: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, number] & { + tickCumulativeInside: BigNumber; + secondsPerLiquidityInsideX128: BigNumber; + secondsInside: number; + } + >; + }; + + observe( + secondsAgos: BigNumberish[], + overrides?: CallOverrides + ): Promise< + [BigNumber[], BigNumber[]] & { + tickCumulatives: BigNumber[]; + secondsPerLiquidityCumulativeX128s: BigNumber[]; + } + >; + + snapshotCumulativesInside( + tickLower: BigNumberish, + tickUpper: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, number] & { + tickCumulativeInside: BigNumber; + secondsPerLiquidityInsideX128: BigNumber; + secondsInside: number; + } + >; + + callStatic: { + observe( + secondsAgos: BigNumberish[], + overrides?: CallOverrides + ): Promise< + [BigNumber[], BigNumber[]] & { + tickCumulatives: BigNumber[]; + secondsPerLiquidityCumulativeX128s: BigNumber[]; + } + >; + + snapshotCumulativesInside( + tickLower: BigNumberish, + tickUpper: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, number] & { + tickCumulativeInside: BigNumber; + secondsPerLiquidityInsideX128: BigNumber; + secondsInside: number; + } + >; + }; + + filters: {}; + + estimateGas: { + observe( + secondsAgos: BigNumberish[], + overrides?: CallOverrides + ): Promise; + + snapshotCumulativesInside( + tickLower: BigNumberish, + tickUpper: BigNumberish, + overrides?: CallOverrides + ): Promise; + }; + + populateTransaction: { + observe( + secondsAgos: BigNumberish[], + overrides?: CallOverrides + ): Promise; + + snapshotCumulativesInside( + tickLower: BigNumberish, + tickUpper: BigNumberish, + overrides?: CallOverrides + ): Promise; + }; +} diff --git a/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolEvents.ts b/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolEvents.ts new file mode 100644 index 00000000..eb4dced8 --- /dev/null +++ b/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolEvents.ts @@ -0,0 +1,339 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + Signer, + utils, +} from "ethers"; +import type { EventFragment } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../../common"; + +export interface IUniswapV3PoolEventsInterface extends utils.Interface { + functions: {}; + + events: { + "Burn(address,int24,int24,uint128,uint256,uint256)": EventFragment; + "Collect(address,address,int24,int24,uint128,uint128)": EventFragment; + "CollectProtocol(address,address,uint128,uint128)": EventFragment; + "Flash(address,address,uint256,uint256,uint256,uint256)": EventFragment; + "IncreaseObservationCardinalityNext(uint16,uint16)": EventFragment; + "Initialize(uint160,int24)": EventFragment; + "Mint(address,address,int24,int24,uint128,uint256,uint256)": EventFragment; + "SetFeeProtocol(uint8,uint8,uint8,uint8)": EventFragment; + "Swap(address,address,int256,int256,uint160,uint128,int24)": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "Burn"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Collect"): EventFragment; + getEvent(nameOrSignatureOrTopic: "CollectProtocol"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Flash"): EventFragment; + getEvent( + nameOrSignatureOrTopic: "IncreaseObservationCardinalityNext" + ): EventFragment; + getEvent(nameOrSignatureOrTopic: "Initialize"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Mint"): EventFragment; + getEvent(nameOrSignatureOrTopic: "SetFeeProtocol"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Swap"): EventFragment; +} + +export interface BurnEventObject { + owner: string; + tickLower: number; + tickUpper: number; + amount: BigNumber; + amount0: BigNumber; + amount1: BigNumber; +} +export type BurnEvent = TypedEvent< + [string, number, number, BigNumber, BigNumber, BigNumber], + BurnEventObject +>; + +export type BurnEventFilter = TypedEventFilter; + +export interface CollectEventObject { + owner: string; + recipient: string; + tickLower: number; + tickUpper: number; + amount0: BigNumber; + amount1: BigNumber; +} +export type CollectEvent = TypedEvent< + [string, string, number, number, BigNumber, BigNumber], + CollectEventObject +>; + +export type CollectEventFilter = TypedEventFilter; + +export interface CollectProtocolEventObject { + sender: string; + recipient: string; + amount0: BigNumber; + amount1: BigNumber; +} +export type CollectProtocolEvent = TypedEvent< + [string, string, BigNumber, BigNumber], + CollectProtocolEventObject +>; + +export type CollectProtocolEventFilter = TypedEventFilter; + +export interface FlashEventObject { + sender: string; + recipient: string; + amount0: BigNumber; + amount1: BigNumber; + paid0: BigNumber; + paid1: BigNumber; +} +export type FlashEvent = TypedEvent< + [string, string, BigNumber, BigNumber, BigNumber, BigNumber], + FlashEventObject +>; + +export type FlashEventFilter = TypedEventFilter; + +export interface IncreaseObservationCardinalityNextEventObject { + observationCardinalityNextOld: number; + observationCardinalityNextNew: number; +} +export type IncreaseObservationCardinalityNextEvent = TypedEvent< + [number, number], + IncreaseObservationCardinalityNextEventObject +>; + +export type IncreaseObservationCardinalityNextEventFilter = + TypedEventFilter; + +export interface InitializeEventObject { + sqrtPriceX96: BigNumber; + tick: number; +} +export type InitializeEvent = TypedEvent< + [BigNumber, number], + InitializeEventObject +>; + +export type InitializeEventFilter = TypedEventFilter; + +export interface MintEventObject { + sender: string; + owner: string; + tickLower: number; + tickUpper: number; + amount: BigNumber; + amount0: BigNumber; + amount1: BigNumber; +} +export type MintEvent = TypedEvent< + [string, string, number, number, BigNumber, BigNumber, BigNumber], + MintEventObject +>; + +export type MintEventFilter = TypedEventFilter; + +export interface SetFeeProtocolEventObject { + feeProtocol0Old: number; + feeProtocol1Old: number; + feeProtocol0New: number; + feeProtocol1New: number; +} +export type SetFeeProtocolEvent = TypedEvent< + [number, number, number, number], + SetFeeProtocolEventObject +>; + +export type SetFeeProtocolEventFilter = TypedEventFilter; + +export interface SwapEventObject { + sender: string; + recipient: string; + amount0: BigNumber; + amount1: BigNumber; + sqrtPriceX96: BigNumber; + liquidity: BigNumber; + tick: number; +} +export type SwapEvent = TypedEvent< + [string, string, BigNumber, BigNumber, BigNumber, BigNumber, number], + SwapEventObject +>; + +export type SwapEventFilter = TypedEventFilter; + +export interface IUniswapV3PoolEvents extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IUniswapV3PoolEventsInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: {}; + + callStatic: {}; + + filters: { + "Burn(address,int24,int24,uint128,uint256,uint256)"( + owner?: string | null, + tickLower?: BigNumberish | null, + tickUpper?: BigNumberish | null, + amount?: null, + amount0?: null, + amount1?: null + ): BurnEventFilter; + Burn( + owner?: string | null, + tickLower?: BigNumberish | null, + tickUpper?: BigNumberish | null, + amount?: null, + amount0?: null, + amount1?: null + ): BurnEventFilter; + + "Collect(address,address,int24,int24,uint128,uint128)"( + owner?: string | null, + recipient?: null, + tickLower?: BigNumberish | null, + tickUpper?: BigNumberish | null, + amount0?: null, + amount1?: null + ): CollectEventFilter; + Collect( + owner?: string | null, + recipient?: null, + tickLower?: BigNumberish | null, + tickUpper?: BigNumberish | null, + amount0?: null, + amount1?: null + ): CollectEventFilter; + + "CollectProtocol(address,address,uint128,uint128)"( + sender?: string | null, + recipient?: string | null, + amount0?: null, + amount1?: null + ): CollectProtocolEventFilter; + CollectProtocol( + sender?: string | null, + recipient?: string | null, + amount0?: null, + amount1?: null + ): CollectProtocolEventFilter; + + "Flash(address,address,uint256,uint256,uint256,uint256)"( + sender?: string | null, + recipient?: string | null, + amount0?: null, + amount1?: null, + paid0?: null, + paid1?: null + ): FlashEventFilter; + Flash( + sender?: string | null, + recipient?: string | null, + amount0?: null, + amount1?: null, + paid0?: null, + paid1?: null + ): FlashEventFilter; + + "IncreaseObservationCardinalityNext(uint16,uint16)"( + observationCardinalityNextOld?: null, + observationCardinalityNextNew?: null + ): IncreaseObservationCardinalityNextEventFilter; + IncreaseObservationCardinalityNext( + observationCardinalityNextOld?: null, + observationCardinalityNextNew?: null + ): IncreaseObservationCardinalityNextEventFilter; + + "Initialize(uint160,int24)"( + sqrtPriceX96?: null, + tick?: null + ): InitializeEventFilter; + Initialize(sqrtPriceX96?: null, tick?: null): InitializeEventFilter; + + "Mint(address,address,int24,int24,uint128,uint256,uint256)"( + sender?: null, + owner?: string | null, + tickLower?: BigNumberish | null, + tickUpper?: BigNumberish | null, + amount?: null, + amount0?: null, + amount1?: null + ): MintEventFilter; + Mint( + sender?: null, + owner?: string | null, + tickLower?: BigNumberish | null, + tickUpper?: BigNumberish | null, + amount?: null, + amount0?: null, + amount1?: null + ): MintEventFilter; + + "SetFeeProtocol(uint8,uint8,uint8,uint8)"( + feeProtocol0Old?: null, + feeProtocol1Old?: null, + feeProtocol0New?: null, + feeProtocol1New?: null + ): SetFeeProtocolEventFilter; + SetFeeProtocol( + feeProtocol0Old?: null, + feeProtocol1Old?: null, + feeProtocol0New?: null, + feeProtocol1New?: null + ): SetFeeProtocolEventFilter; + + "Swap(address,address,int256,int256,uint160,uint128,int24)"( + sender?: string | null, + recipient?: string | null, + amount0?: null, + amount1?: null, + sqrtPriceX96?: null, + liquidity?: null, + tick?: null + ): SwapEventFilter; + Swap( + sender?: string | null, + recipient?: string | null, + amount0?: null, + amount1?: null, + sqrtPriceX96?: null, + liquidity?: null, + tick?: null + ): SwapEventFilter; + }; + + estimateGas: {}; + + populateTransaction: {}; +} diff --git a/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolImmutables.ts b/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolImmutables.ts new file mode 100644 index 00000000..577225c4 --- /dev/null +++ b/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolImmutables.ts @@ -0,0 +1,168 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BytesLike, + CallOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../../common"; + +export interface IUniswapV3PoolImmutablesInterface extends utils.Interface { + functions: { + "factory()": FunctionFragment; + "fee()": FunctionFragment; + "maxLiquidityPerTick()": FunctionFragment; + "tickSpacing()": FunctionFragment; + "token0()": FunctionFragment; + "token1()": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "factory" + | "fee" + | "maxLiquidityPerTick" + | "tickSpacing" + | "token0" + | "token1" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "factory", values?: undefined): string; + encodeFunctionData(functionFragment: "fee", values?: undefined): string; + encodeFunctionData( + functionFragment: "maxLiquidityPerTick", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "tickSpacing", + values?: undefined + ): string; + encodeFunctionData(functionFragment: "token0", values?: undefined): string; + encodeFunctionData(functionFragment: "token1", values?: undefined): string; + + decodeFunctionResult(functionFragment: "factory", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "fee", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "maxLiquidityPerTick", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "tickSpacing", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "token0", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "token1", data: BytesLike): Result; + + events: {}; +} + +export interface IUniswapV3PoolImmutables extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IUniswapV3PoolImmutablesInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + factory(overrides?: CallOverrides): Promise<[string]>; + + fee(overrides?: CallOverrides): Promise<[number]>; + + maxLiquidityPerTick(overrides?: CallOverrides): Promise<[BigNumber]>; + + tickSpacing(overrides?: CallOverrides): Promise<[number]>; + + token0(overrides?: CallOverrides): Promise<[string]>; + + token1(overrides?: CallOverrides): Promise<[string]>; + }; + + factory(overrides?: CallOverrides): Promise; + + fee(overrides?: CallOverrides): Promise; + + maxLiquidityPerTick(overrides?: CallOverrides): Promise; + + tickSpacing(overrides?: CallOverrides): Promise; + + token0(overrides?: CallOverrides): Promise; + + token1(overrides?: CallOverrides): Promise; + + callStatic: { + factory(overrides?: CallOverrides): Promise; + + fee(overrides?: CallOverrides): Promise; + + maxLiquidityPerTick(overrides?: CallOverrides): Promise; + + tickSpacing(overrides?: CallOverrides): Promise; + + token0(overrides?: CallOverrides): Promise; + + token1(overrides?: CallOverrides): Promise; + }; + + filters: {}; + + estimateGas: { + factory(overrides?: CallOverrides): Promise; + + fee(overrides?: CallOverrides): Promise; + + maxLiquidityPerTick(overrides?: CallOverrides): Promise; + + tickSpacing(overrides?: CallOverrides): Promise; + + token0(overrides?: CallOverrides): Promise; + + token1(overrides?: CallOverrides): Promise; + }; + + populateTransaction: { + factory(overrides?: CallOverrides): Promise; + + fee(overrides?: CallOverrides): Promise; + + maxLiquidityPerTick( + overrides?: CallOverrides + ): Promise; + + tickSpacing(overrides?: CallOverrides): Promise; + + token0(overrides?: CallOverrides): Promise; + + token1(overrides?: CallOverrides): Promise; + }; +} diff --git a/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolOwnerActions.ts b/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolOwnerActions.ts new file mode 100644 index 00000000..2de4d34b --- /dev/null +++ b/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolOwnerActions.ts @@ -0,0 +1,158 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../../common"; + +export interface IUniswapV3PoolOwnerActionsInterface extends utils.Interface { + functions: { + "collectProtocol(address,uint128,uint128)": FunctionFragment; + "setFeeProtocol(uint8,uint8)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: "collectProtocol" | "setFeeProtocol" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "collectProtocol", + values: [string, BigNumberish, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "setFeeProtocol", + values: [BigNumberish, BigNumberish] + ): string; + + decodeFunctionResult( + functionFragment: "collectProtocol", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setFeeProtocol", + data: BytesLike + ): Result; + + events: {}; +} + +export interface IUniswapV3PoolOwnerActions extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IUniswapV3PoolOwnerActionsInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + collectProtocol( + recipient: string, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeProtocol( + feeProtocol0: BigNumberish, + feeProtocol1: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + collectProtocol( + recipient: string, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeProtocol( + feeProtocol0: BigNumberish, + feeProtocol1: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + collectProtocol( + recipient: string, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + setFeeProtocol( + feeProtocol0: BigNumberish, + feeProtocol1: BigNumberish, + overrides?: CallOverrides + ): Promise; + }; + + filters: {}; + + estimateGas: { + collectProtocol( + recipient: string, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeProtocol( + feeProtocol0: BigNumberish, + feeProtocol1: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + collectProtocol( + recipient: string, + amount0Requested: BigNumberish, + amount1Requested: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeProtocol( + feeProtocol0: BigNumberish, + feeProtocol1: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolState.ts b/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolState.ts new file mode 100644 index 00000000..ae57076a --- /dev/null +++ b/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolState.ts @@ -0,0 +1,436 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../../common"; + +export interface IUniswapV3PoolStateInterface extends utils.Interface { + functions: { + "feeGrowthGlobal0X128()": FunctionFragment; + "feeGrowthGlobal1X128()": FunctionFragment; + "liquidity()": FunctionFragment; + "observations(uint256)": FunctionFragment; + "positions(bytes32)": FunctionFragment; + "protocolFees()": FunctionFragment; + "slot0()": FunctionFragment; + "tickBitmap(int16)": FunctionFragment; + "ticks(int24)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "feeGrowthGlobal0X128" + | "feeGrowthGlobal1X128" + | "liquidity" + | "observations" + | "positions" + | "protocolFees" + | "slot0" + | "tickBitmap" + | "ticks" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "feeGrowthGlobal0X128", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "feeGrowthGlobal1X128", + values?: undefined + ): string; + encodeFunctionData(functionFragment: "liquidity", values?: undefined): string; + encodeFunctionData( + functionFragment: "observations", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "positions", + values: [BytesLike] + ): string; + encodeFunctionData( + functionFragment: "protocolFees", + values?: undefined + ): string; + encodeFunctionData(functionFragment: "slot0", values?: undefined): string; + encodeFunctionData( + functionFragment: "tickBitmap", + values: [BigNumberish] + ): string; + encodeFunctionData(functionFragment: "ticks", values: [BigNumberish]): string; + + decodeFunctionResult( + functionFragment: "feeGrowthGlobal0X128", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "feeGrowthGlobal1X128", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "liquidity", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "observations", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "positions", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "protocolFees", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "slot0", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "tickBitmap", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "ticks", data: BytesLike): Result; + + events: {}; +} + +export interface IUniswapV3PoolState extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IUniswapV3PoolStateInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + feeGrowthGlobal0X128(overrides?: CallOverrides): Promise<[BigNumber]>; + + feeGrowthGlobal1X128(overrides?: CallOverrides): Promise<[BigNumber]>; + + liquidity(overrides?: CallOverrides): Promise<[BigNumber]>; + + observations( + index: BigNumberish, + overrides?: CallOverrides + ): Promise< + [number, BigNumber, BigNumber, boolean] & { + blockTimestamp: number; + tickCumulative: BigNumber; + secondsPerLiquidityCumulativeX128: BigNumber; + initialized: boolean; + } + >; + + positions( + key: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber, BigNumber] & { + _liquidity: BigNumber; + feeGrowthInside0LastX128: BigNumber; + feeGrowthInside1LastX128: BigNumber; + tokensOwed0: BigNumber; + tokensOwed1: BigNumber; + } + >; + + protocolFees( + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { token0: BigNumber; token1: BigNumber } + >; + + slot0( + overrides?: CallOverrides + ): Promise< + [BigNumber, number, number, number, number, number, boolean] & { + sqrtPriceX96: BigNumber; + tick: number; + observationIndex: number; + observationCardinality: number; + observationCardinalityNext: number; + feeProtocol: number; + unlocked: boolean; + } + >; + + tickBitmap( + wordPosition: BigNumberish, + overrides?: CallOverrides + ): Promise<[BigNumber]>; + + ticks( + tick: BigNumberish, + overrides?: CallOverrides + ): Promise< + [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + number, + boolean + ] & { + liquidityGross: BigNumber; + liquidityNet: BigNumber; + feeGrowthOutside0X128: BigNumber; + feeGrowthOutside1X128: BigNumber; + tickCumulativeOutside: BigNumber; + secondsPerLiquidityOutsideX128: BigNumber; + secondsOutside: number; + initialized: boolean; + } + >; + }; + + feeGrowthGlobal0X128(overrides?: CallOverrides): Promise; + + feeGrowthGlobal1X128(overrides?: CallOverrides): Promise; + + liquidity(overrides?: CallOverrides): Promise; + + observations( + index: BigNumberish, + overrides?: CallOverrides + ): Promise< + [number, BigNumber, BigNumber, boolean] & { + blockTimestamp: number; + tickCumulative: BigNumber; + secondsPerLiquidityCumulativeX128: BigNumber; + initialized: boolean; + } + >; + + positions( + key: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber, BigNumber] & { + _liquidity: BigNumber; + feeGrowthInside0LastX128: BigNumber; + feeGrowthInside1LastX128: BigNumber; + tokensOwed0: BigNumber; + tokensOwed1: BigNumber; + } + >; + + protocolFees( + overrides?: CallOverrides + ): Promise<[BigNumber, BigNumber] & { token0: BigNumber; token1: BigNumber }>; + + slot0( + overrides?: CallOverrides + ): Promise< + [BigNumber, number, number, number, number, number, boolean] & { + sqrtPriceX96: BigNumber; + tick: number; + observationIndex: number; + observationCardinality: number; + observationCardinalityNext: number; + feeProtocol: number; + unlocked: boolean; + } + >; + + tickBitmap( + wordPosition: BigNumberish, + overrides?: CallOverrides + ): Promise; + + ticks( + tick: BigNumberish, + overrides?: CallOverrides + ): Promise< + [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + number, + boolean + ] & { + liquidityGross: BigNumber; + liquidityNet: BigNumber; + feeGrowthOutside0X128: BigNumber; + feeGrowthOutside1X128: BigNumber; + tickCumulativeOutside: BigNumber; + secondsPerLiquidityOutsideX128: BigNumber; + secondsOutside: number; + initialized: boolean; + } + >; + + callStatic: { + feeGrowthGlobal0X128(overrides?: CallOverrides): Promise; + + feeGrowthGlobal1X128(overrides?: CallOverrides): Promise; + + liquidity(overrides?: CallOverrides): Promise; + + observations( + index: BigNumberish, + overrides?: CallOverrides + ): Promise< + [number, BigNumber, BigNumber, boolean] & { + blockTimestamp: number; + tickCumulative: BigNumber; + secondsPerLiquidityCumulativeX128: BigNumber; + initialized: boolean; + } + >; + + positions( + key: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber, BigNumber] & { + _liquidity: BigNumber; + feeGrowthInside0LastX128: BigNumber; + feeGrowthInside1LastX128: BigNumber; + tokensOwed0: BigNumber; + tokensOwed1: BigNumber; + } + >; + + protocolFees( + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { token0: BigNumber; token1: BigNumber } + >; + + slot0( + overrides?: CallOverrides + ): Promise< + [BigNumber, number, number, number, number, number, boolean] & { + sqrtPriceX96: BigNumber; + tick: number; + observationIndex: number; + observationCardinality: number; + observationCardinalityNext: number; + feeProtocol: number; + unlocked: boolean; + } + >; + + tickBitmap( + wordPosition: BigNumberish, + overrides?: CallOverrides + ): Promise; + + ticks( + tick: BigNumberish, + overrides?: CallOverrides + ): Promise< + [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + number, + boolean + ] & { + liquidityGross: BigNumber; + liquidityNet: BigNumber; + feeGrowthOutside0X128: BigNumber; + feeGrowthOutside1X128: BigNumber; + tickCumulativeOutside: BigNumber; + secondsPerLiquidityOutsideX128: BigNumber; + secondsOutside: number; + initialized: boolean; + } + >; + }; + + filters: {}; + + estimateGas: { + feeGrowthGlobal0X128(overrides?: CallOverrides): Promise; + + feeGrowthGlobal1X128(overrides?: CallOverrides): Promise; + + liquidity(overrides?: CallOverrides): Promise; + + observations( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + positions(key: BytesLike, overrides?: CallOverrides): Promise; + + protocolFees(overrides?: CallOverrides): Promise; + + slot0(overrides?: CallOverrides): Promise; + + tickBitmap( + wordPosition: BigNumberish, + overrides?: CallOverrides + ): Promise; + + ticks(tick: BigNumberish, overrides?: CallOverrides): Promise; + }; + + populateTransaction: { + feeGrowthGlobal0X128( + overrides?: CallOverrides + ): Promise; + + feeGrowthGlobal1X128( + overrides?: CallOverrides + ): Promise; + + liquidity(overrides?: CallOverrides): Promise; + + observations( + index: BigNumberish, + overrides?: CallOverrides + ): Promise; + + positions( + key: BytesLike, + overrides?: CallOverrides + ): Promise; + + protocolFees(overrides?: CallOverrides): Promise; + + slot0(overrides?: CallOverrides): Promise; + + tickBitmap( + wordPosition: BigNumberish, + overrides?: CallOverrides + ): Promise; + + ticks( + tick: BigNumberish, + overrides?: CallOverrides + ): Promise; + }; +} diff --git a/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/pool/index.ts b/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/pool/index.ts new file mode 100644 index 00000000..459d8ece --- /dev/null +++ b/src/typechain-typesV4/@uniswap/v3-core/contracts/interfaces/pool/index.ts @@ -0,0 +1,9 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export type { IUniswapV3PoolActions } from "./IUniswapV3PoolActions"; +export type { IUniswapV3PoolDerivedState } from "./IUniswapV3PoolDerivedState"; +export type { IUniswapV3PoolEvents } from "./IUniswapV3PoolEvents"; +export type { IUniswapV3PoolImmutables } from "./IUniswapV3PoolImmutables"; +export type { IUniswapV3PoolOwnerActions } from "./IUniswapV3PoolOwnerActions"; +export type { IUniswapV3PoolState } from "./IUniswapV3PoolState"; diff --git a/src/typechain-typesV4/@uniswap/v3-core/index.ts b/src/typechain-typesV4/@uniswap/v3-core/index.ts new file mode 100644 index 00000000..a11e4ca2 --- /dev/null +++ b/src/typechain-typesV4/@uniswap/v3-core/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as contracts from "./contracts"; +export type { contracts }; diff --git a/src/typechain-typesV4/@uniswap/v3-periphery/contracts/index.ts b/src/typechain-typesV4/@uniswap/v3-periphery/contracts/index.ts new file mode 100644 index 00000000..92159233 --- /dev/null +++ b/src/typechain-typesV4/@uniswap/v3-periphery/contracts/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as interfaces from "./interfaces"; +export type { interfaces }; diff --git a/src/typechain-typesV4/@uniswap/v3-periphery/contracts/interfaces/IERC721Permit.ts b/src/typechain-typesV4/@uniswap/v3-periphery/contracts/interfaces/IERC721Permit.ts new file mode 100644 index 00000000..e7d4aa0c --- /dev/null +++ b/src/typechain-typesV4/@uniswap/v3-periphery/contracts/interfaces/IERC721Permit.ts @@ -0,0 +1,632 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../common"; + +export interface IERC721PermitInterface extends utils.Interface { + functions: { + "DOMAIN_SEPARATOR()": FunctionFragment; + "PERMIT_TYPEHASH()": FunctionFragment; + "approve(address,uint256)": FunctionFragment; + "balanceOf(address)": FunctionFragment; + "getApproved(uint256)": FunctionFragment; + "isApprovedForAll(address,address)": FunctionFragment; + "ownerOf(uint256)": FunctionFragment; + "permit(address,uint256,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "safeTransferFrom(address,address,uint256)": FunctionFragment; + "safeTransferFrom(address,address,uint256,bytes)": FunctionFragment; + "setApprovalForAll(address,bool)": FunctionFragment; + "supportsInterface(bytes4)": FunctionFragment; + "transferFrom(address,address,uint256)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "DOMAIN_SEPARATOR" + | "PERMIT_TYPEHASH" + | "approve" + | "balanceOf" + | "getApproved" + | "isApprovedForAll" + | "ownerOf" + | "permit" + | "safeTransferFrom(address,address,uint256)" + | "safeTransferFrom(address,address,uint256,bytes)" + | "setApprovalForAll" + | "supportsInterface" + | "transferFrom" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "DOMAIN_SEPARATOR", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "PERMIT_TYPEHASH", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "approve", + values: [string, BigNumberish] + ): string; + encodeFunctionData(functionFragment: "balanceOf", values: [string]): string; + encodeFunctionData( + functionFragment: "getApproved", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "isApprovedForAll", + values: [string, string] + ): string; + encodeFunctionData( + functionFragment: "ownerOf", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "permit", + values: [ + string, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "safeTransferFrom(address,address,uint256)", + values: [string, string, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "safeTransferFrom(address,address,uint256,bytes)", + values: [string, string, BigNumberish, BytesLike] + ): string; + encodeFunctionData( + functionFragment: "setApprovalForAll", + values: [string, boolean] + ): string; + encodeFunctionData( + functionFragment: "supportsInterface", + values: [BytesLike] + ): string; + encodeFunctionData( + functionFragment: "transferFrom", + values: [string, string, BigNumberish] + ): string; + + decodeFunctionResult( + functionFragment: "DOMAIN_SEPARATOR", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "PERMIT_TYPEHASH", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "approve", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "balanceOf", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "getApproved", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "isApprovedForAll", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "ownerOf", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "permit", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "safeTransferFrom(address,address,uint256)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "safeTransferFrom(address,address,uint256,bytes)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setApprovalForAll", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "supportsInterface", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "transferFrom", + data: BytesLike + ): Result; + + events: { + "Approval(address,address,uint256)": EventFragment; + "ApprovalForAll(address,address,bool)": EventFragment; + "Transfer(address,address,uint256)": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "Approval"): EventFragment; + getEvent(nameOrSignatureOrTopic: "ApprovalForAll"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Transfer"): EventFragment; +} + +export interface ApprovalEventObject { + owner: string; + approved: string; + tokenId: BigNumber; +} +export type ApprovalEvent = TypedEvent< + [string, string, BigNumber], + ApprovalEventObject +>; + +export type ApprovalEventFilter = TypedEventFilter; + +export interface ApprovalForAllEventObject { + owner: string; + operator: string; + approved: boolean; +} +export type ApprovalForAllEvent = TypedEvent< + [string, string, boolean], + ApprovalForAllEventObject +>; + +export type ApprovalForAllEventFilter = TypedEventFilter; + +export interface TransferEventObject { + from: string; + to: string; + tokenId: BigNumber; +} +export type TransferEvent = TypedEvent< + [string, string, BigNumber], + TransferEventObject +>; + +export type TransferEventFilter = TypedEventFilter; + +export interface IERC721Permit extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IERC721PermitInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise<[string]>; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise<[string]>; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf( + owner: string, + overrides?: CallOverrides + ): Promise<[BigNumber] & { balance: BigNumber }>; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise<[string] & { operator: string }>; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise<[boolean]>; + + ownerOf( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise<[string] & { owner: string }>; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise<[boolean]>; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + ownerOf(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + ownerOf(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: CallOverrides + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "Approval(address,address,uint256)"( + owner?: string | null, + approved?: string | null, + tokenId?: BigNumberish | null + ): ApprovalEventFilter; + Approval( + owner?: string | null, + approved?: string | null, + tokenId?: BigNumberish | null + ): ApprovalEventFilter; + + "ApprovalForAll(address,address,bool)"( + owner?: string | null, + operator?: string | null, + approved?: null + ): ApprovalForAllEventFilter; + ApprovalForAll( + owner?: string | null, + operator?: string | null, + approved?: null + ): ApprovalForAllEventFilter; + + "Transfer(address,address,uint256)"( + from?: string | null, + to?: string | null, + tokenId?: BigNumberish | null + ): TransferEventFilter; + Transfer( + from?: string | null, + to?: string | null, + tokenId?: BigNumberish | null + ): TransferEventFilter; + }; + + estimateGas: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + ownerOf( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + PERMIT_TYPEHASH(overrides?: CallOverrides): Promise; + + approve( + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf( + owner: string, + overrides?: CallOverrides + ): Promise; + + getApproved( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + isApprovedForAll( + owner: string, + operator: string, + overrides?: CallOverrides + ): Promise; + + ownerOf( + tokenId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + permit( + spender: string, + tokenId: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256)"( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + "safeTransferFrom(address,address,uint256,bytes)"( + from: string, + to: string, + tokenId: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setApprovalForAll( + operator: string, + approved: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + supportsInterface( + interfaceId: BytesLike, + overrides?: CallOverrides + ): Promise; + + transferFrom( + from: string, + to: string, + tokenId: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/@uniswap/v3-periphery/contracts/interfaces/IPeripheryImmutableState.ts b/src/typechain-typesV4/@uniswap/v3-periphery/contracts/interfaces/IPeripheryImmutableState.ts new file mode 100644 index 00000000..59bf865d --- /dev/null +++ b/src/typechain-typesV4/@uniswap/v3-periphery/contracts/interfaces/IPeripheryImmutableState.ts @@ -0,0 +1,94 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BytesLike, + CallOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../common"; + +export interface IPeripheryImmutableStateInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "factory()": FunctionFragment; + }; + + getFunction(nameOrSignatureOrTopic: "WETH9" | "factory"): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData(functionFragment: "factory", values?: undefined): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "factory", data: BytesLike): Result; + + events: {}; +} + +export interface IPeripheryImmutableState extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IPeripheryImmutableStateInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + factory(overrides?: CallOverrides): Promise<[string]>; + }; + + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + }; + + filters: {}; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + }; +} diff --git a/src/typechain-typesV4/@uniswap/v3-periphery/contracts/interfaces/IPeripheryPayments.ts b/src/typechain-typesV4/@uniswap/v3-periphery/contracts/interfaces/IPeripheryPayments.ts new file mode 100644 index 00000000..6606f96c --- /dev/null +++ b/src/typechain-typesV4/@uniswap/v3-periphery/contracts/interfaces/IPeripheryPayments.ts @@ -0,0 +1,174 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../common"; + +export interface IPeripheryPaymentsInterface extends utils.Interface { + functions: { + "refundETH()": FunctionFragment; + "sweepToken(address,uint256,address)": FunctionFragment; + "unwrapWETH9(uint256,address)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: "refundETH" | "sweepToken" | "unwrapWETH9" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "refundETH", values?: undefined): string; + encodeFunctionData( + functionFragment: "sweepToken", + values: [string, BigNumberish, string] + ): string; + encodeFunctionData( + functionFragment: "unwrapWETH9", + values: [BigNumberish, string] + ): string; + + decodeFunctionResult(functionFragment: "refundETH", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "sweepToken", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "unwrapWETH9", + data: BytesLike + ): Result; + + events: {}; +} + +export interface IPeripheryPayments extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IPeripheryPaymentsInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + refundETH( + overrides?: PayableOverrides & { from?: string } + ): Promise; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + }; + + refundETH( + overrides?: PayableOverrides & { from?: string } + ): Promise; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + callStatic: { + refundETH(overrides?: CallOverrides): Promise; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: CallOverrides + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: CallOverrides + ): Promise; + }; + + filters: {}; + + estimateGas: { + refundETH( + overrides?: PayableOverrides & { from?: string } + ): Promise; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + refundETH( + overrides?: PayableOverrides & { from?: string } + ): Promise; + + sweepToken( + token: string, + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + unwrapWETH9( + amountMinimum: BigNumberish, + recipient: string, + overrides?: PayableOverrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/@uniswap/v3-periphery/contracts/interfaces/IPoolInitializer.ts b/src/typechain-typesV4/@uniswap/v3-periphery/contracts/interfaces/IPoolInitializer.ts new file mode 100644 index 00000000..bb56cc4e --- /dev/null +++ b/src/typechain-typesV4/@uniswap/v3-periphery/contracts/interfaces/IPoolInitializer.ts @@ -0,0 +1,122 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../../common"; + +export interface IPoolInitializerInterface extends utils.Interface { + functions: { + "createAndInitializePoolIfNecessary(address,address,uint24,uint160)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: "createAndInitializePoolIfNecessary" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "createAndInitializePoolIfNecessary", + values: [string, string, BigNumberish, BigNumberish] + ): string; + + decodeFunctionResult( + functionFragment: "createAndInitializePoolIfNecessary", + data: BytesLike + ): Result; + + events: {}; +} + +export interface IPoolInitializer extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IPoolInitializerInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + createAndInitializePoolIfNecessary( + token0: string, + token1: string, + fee: BigNumberish, + sqrtPriceX96: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + }; + + createAndInitializePoolIfNecessary( + token0: string, + token1: string, + fee: BigNumberish, + sqrtPriceX96: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + callStatic: { + createAndInitializePoolIfNecessary( + token0: string, + token1: string, + fee: BigNumberish, + sqrtPriceX96: BigNumberish, + overrides?: CallOverrides + ): Promise; + }; + + filters: {}; + + estimateGas: { + createAndInitializePoolIfNecessary( + token0: string, + token1: string, + fee: BigNumberish, + sqrtPriceX96: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + createAndInitializePoolIfNecessary( + token0: string, + token1: string, + fee: BigNumberish, + sqrtPriceX96: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/@uniswap/v3-periphery/contracts/interfaces/index.ts b/src/typechain-typesV4/@uniswap/v3-periphery/contracts/interfaces/index.ts new file mode 100644 index 00000000..d4ae7813 --- /dev/null +++ b/src/typechain-typesV4/@uniswap/v3-periphery/contracts/interfaces/index.ts @@ -0,0 +1,7 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export type { IERC721Permit } from "./IERC721Permit"; +export type { IPeripheryImmutableState } from "./IPeripheryImmutableState"; +export type { IPeripheryPayments } from "./IPeripheryPayments"; +export type { IPoolInitializer } from "./IPoolInitializer"; diff --git a/src/typechain-typesV4/@uniswap/v3-periphery/index.ts b/src/typechain-typesV4/@uniswap/v3-periphery/index.ts new file mode 100644 index 00000000..a11e4ca2 --- /dev/null +++ b/src/typechain-typesV4/@uniswap/v3-periphery/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as contracts from "./contracts"; +export type { contracts }; diff --git a/src/typechain-typesV4/common.ts b/src/typechain-typesV4/common.ts new file mode 100644 index 00000000..2fc40c7f --- /dev/null +++ b/src/typechain-typesV4/common.ts @@ -0,0 +1,44 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { Listener } from "@ethersproject/providers"; +import type { Event, EventFilter } from "ethers"; + +export interface TypedEvent< + TArgsArray extends Array = any, + TArgsObject = any +> extends Event { + args: TArgsArray & TArgsObject; +} + +export interface TypedEventFilter<_TEvent extends TypedEvent> + extends EventFilter {} + +export interface TypedListener { + (...listenerArg: [...__TypechainArgsArray, TEvent]): void; +} + +type __TypechainArgsArray = T extends TypedEvent ? U : never; + +export interface OnEvent { + ( + eventFilter: TypedEventFilter, + listener: TypedListener + ): TRes; + (eventName: string, listener: Listener): TRes; +} + +export type MinEthersFactory = { + deploy(...a: ARGS[]): Promise; +}; + +export type GetContractTypeFromFactory = F extends MinEthersFactory< + infer C, + any +> + ? C + : never; + +export type GetARGsTypeFromFactory = F extends MinEthersFactory + ? Parameters + : never; diff --git a/src/typechain-typesV4/factories/@aperture_finance/index.ts b/src/typechain-typesV4/factories/@aperture_finance/index.ts new file mode 100644 index 00000000..56c8f863 --- /dev/null +++ b/src/typechain-typesV4/factories/@aperture_finance/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as uniV3Lib from "./uni-v3-lib"; diff --git a/src/typechain-typesV4/factories/@aperture_finance/uni-v3-lib/index.ts b/src/typechain-typesV4/factories/@aperture_finance/uni-v3-lib/index.ts new file mode 100644 index 00000000..ba4b1074 --- /dev/null +++ b/src/typechain-typesV4/factories/@aperture_finance/uni-v3-lib/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as src from "./src"; diff --git a/src/typechain-typesV4/factories/@aperture_finance/uni-v3-lib/src/FullMath__factory.ts b/src/typechain-typesV4/factories/@aperture_finance/uni-v3-lib/src/FullMath__factory.ts new file mode 100644 index 00000000..ad613f00 --- /dev/null +++ b/src/typechain-typesV4/factories/@aperture_finance/uni-v3-lib/src/FullMath__factory.ts @@ -0,0 +1,67 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import { Signer, utils, Contract, ContractFactory, Overrides } from "ethers"; +import type { Provider, TransactionRequest } from "@ethersproject/providers"; +import type { + FullMath, + FullMathInterface, +} from "../../../../@aperture_finance/uni-v3-lib/src/FullMath"; + +const _abi = [ + { + inputs: [], + name: "FullMulDivFailed", + type: "error", + }, +] as const; + +const _bytecode = + "0x6080806040523460175760119081601d823930815050f35b600080fdfe600080fdfea164736f6c634300081a000a"; + +type FullMathConstructorParams = + | [signer?: Signer] + | ConstructorParameters; + +const isSuperArgs = ( + xs: FullMathConstructorParams +): xs is ConstructorParameters => xs.length > 1; + +export class FullMath__factory extends ContractFactory { + constructor(...args: FullMathConstructorParams) { + if (isSuperArgs(args)) { + super(...args); + } else { + super(_abi, _bytecode, args[0]); + } + } + + override deploy( + overrides?: Overrides & { from?: string } + ): Promise { + return super.deploy(overrides || {}) as Promise; + } + override getDeployTransaction( + overrides?: Overrides & { from?: string } + ): TransactionRequest { + return super.getDeployTransaction(overrides || {}); + } + override attach(address: string): FullMath { + return super.attach(address) as FullMath; + } + override connect(signer: Signer): FullMath__factory { + return super.connect(signer) as FullMath__factory; + } + + static readonly bytecode = _bytecode; + static readonly abi = _abi; + static createInterface(): FullMathInterface { + return new utils.Interface(_abi) as FullMathInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): FullMath { + return new Contract(address, _abi, signerOrProvider) as FullMath; + } +} diff --git a/src/typechain-typesV4/factories/@aperture_finance/uni-v3-lib/src/index.ts b/src/typechain-typesV4/factories/@aperture_finance/uni-v3-lib/src/index.ts new file mode 100644 index 00000000..7dd438fd --- /dev/null +++ b/src/typechain-typesV4/factories/@aperture_finance/uni-v3-lib/src/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as interfaces from "./interfaces"; +export { FullMath__factory } from "./FullMath__factory"; diff --git a/src/typechain-typesV4/factories/@aperture_finance/uni-v3-lib/src/interfaces/ICommonNonfungiblePositionManager__factory.ts b/src/typechain-typesV4/factories/@aperture_finance/uni-v3-lib/src/interfaces/ICommonNonfungiblePositionManager__factory.ts new file mode 100644 index 00000000..8ea435b9 --- /dev/null +++ b/src/typechain-typesV4/factories/@aperture_finance/uni-v3-lib/src/interfaces/ICommonNonfungiblePositionManager__factory.ts @@ -0,0 +1,822 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + ICommonNonfungiblePositionManager, + ICommonNonfungiblePositionManagerInterface, +} from "../../../../../@aperture_finance/uni-v3-lib/src/interfaces/ICommonNonfungiblePositionManager"; + +const _abi = [ + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "approved", + type: "address", + }, + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Approval", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "operator", + type: "address", + }, + { + indexed: false, + internalType: "bool", + name: "approved", + type: "bool", + }, + ], + name: "ApprovalForAll", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + indexed: false, + internalType: "address", + name: "recipient", + type: "address", + }, + { + indexed: false, + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + name: "Collect", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + indexed: false, + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + indexed: false, + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + name: "DecreaseLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + indexed: false, + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + indexed: false, + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + name: "IncreaseLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "from", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "to", + type: "address", + }, + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Transfer", + type: "event", + }, + { + inputs: [], + name: "DOMAIN_SEPARATOR", + outputs: [ + { + internalType: "bytes32", + name: "", + type: "bytes32", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "PERMIT_TYPEHASH", + outputs: [ + { + internalType: "bytes32", + name: "", + type: "bytes32", + }, + ], + stateMutability: "pure", + type: "function", + }, + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "approve", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "balanceOf", + outputs: [ + { + internalType: "uint256", + name: "balance", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "burn", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint128", + name: "amount0Max", + type: "uint128", + }, + { + internalType: "uint128", + name: "amount1Max", + type: "uint128", + }, + ], + internalType: "struct ICommonNonfungiblePositionManager.CollectParams", + name: "params", + type: "tuple", + }, + ], + name: "collect", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + ], + name: "decreaseLiquidity", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [], + name: "factory", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "getApproved", + outputs: [ + { + internalType: "address", + name: "operator", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + ], + name: "increaseLiquidity", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + ], + name: "isApprovedForAll", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "name", + outputs: [ + { + internalType: "string", + name: "", + type: "string", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "ownerOf", + outputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "spender", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "permit", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [], + name: "refundETH", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "safeTransferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "safeTransferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "bool", + name: "approved", + type: "bool", + }, + ], + name: "setApprovalForAll", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "bytes4", + name: "interfaceId", + type: "bytes4", + }, + ], + name: "supportsInterface", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "token", + type: "address", + }, + { + internalType: "uint256", + name: "amountMinimum", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + ], + name: "sweepToken", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [], + name: "symbol", + outputs: [ + { + internalType: "string", + name: "", + type: "string", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "index", + type: "uint256", + }, + ], + name: "tokenByIndex", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + { + internalType: "uint256", + name: "index", + type: "uint256", + }, + ], + name: "tokenOfOwnerByIndex", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "tokenURI", + outputs: [ + { + internalType: "string", + name: "", + type: "string", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "totalSupply", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "transferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "amountMinimum", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + ], + name: "unwrapWETH9", + outputs: [], + stateMutability: "payable", + type: "function", + }, +] as const; + +export class ICommonNonfungiblePositionManager__factory { + static readonly abi = _abi; + static createInterface(): ICommonNonfungiblePositionManagerInterface { + return new utils.Interface( + _abi + ) as ICommonNonfungiblePositionManagerInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): ICommonNonfungiblePositionManager { + return new Contract( + address, + _abi, + signerOrProvider + ) as ICommonNonfungiblePositionManager; + } +} diff --git a/src/typechain-typesV4/factories/@aperture_finance/uni-v3-lib/src/interfaces/IPCSV3NonfungiblePositionManager__factory.ts b/src/typechain-typesV4/factories/@aperture_finance/uni-v3-lib/src/interfaces/IPCSV3NonfungiblePositionManager__factory.ts new file mode 100644 index 00000000..b1e6b679 --- /dev/null +++ b/src/typechain-typesV4/factories/@aperture_finance/uni-v3-lib/src/interfaces/IPCSV3NonfungiblePositionManager__factory.ts @@ -0,0 +1,1034 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IPCSV3NonfungiblePositionManager, + IPCSV3NonfungiblePositionManagerInterface, +} from "../../../../../@aperture_finance/uni-v3-lib/src/interfaces/IPCSV3NonfungiblePositionManager"; + +const _abi = [ + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "approved", + type: "address", + }, + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Approval", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "operator", + type: "address", + }, + { + indexed: false, + internalType: "bool", + name: "approved", + type: "bool", + }, + ], + name: "ApprovalForAll", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + indexed: false, + internalType: "address", + name: "recipient", + type: "address", + }, + { + indexed: false, + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + name: "Collect", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + indexed: false, + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + indexed: false, + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + name: "DecreaseLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + indexed: false, + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + indexed: false, + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + name: "IncreaseLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "from", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "to", + type: "address", + }, + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Transfer", + type: "event", + }, + { + inputs: [], + name: "DOMAIN_SEPARATOR", + outputs: [ + { + internalType: "bytes32", + name: "", + type: "bytes32", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "PERMIT_TYPEHASH", + outputs: [ + { + internalType: "bytes32", + name: "", + type: "bytes32", + }, + ], + stateMutability: "pure", + type: "function", + }, + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "approve", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "balanceOf", + outputs: [ + { + internalType: "uint256", + name: "balance", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "burn", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint128", + name: "amount0Max", + type: "uint128", + }, + { + internalType: "uint128", + name: "amount1Max", + type: "uint128", + }, + ], + internalType: "struct ICommonNonfungiblePositionManager.CollectParams", + name: "params", + type: "tuple", + }, + ], + name: "collect", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + name: "createAndInitializePoolIfNecessary", + outputs: [ + { + internalType: "address", + name: "pool", + type: "address", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + ], + name: "decreaseLiquidity", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [], + name: "deployer", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "factory", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "getApproved", + outputs: [ + { + internalType: "address", + name: "operator", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + ], + name: "increaseLiquidity", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + ], + name: "isApprovedForAll", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + ], + name: "mint", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [], + name: "name", + outputs: [ + { + internalType: "string", + name: "", + type: "string", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "ownerOf", + outputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "spender", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "permit", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "positions", + outputs: [ + { + internalType: "uint96", + name: "nonce", + type: "uint96", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "feeGrowthInside0LastX128", + type: "uint256", + }, + { + internalType: "uint256", + name: "feeGrowthInside1LastX128", + type: "uint256", + }, + { + internalType: "uint128", + name: "tokensOwed0", + type: "uint128", + }, + { + internalType: "uint128", + name: "tokensOwed1", + type: "uint128", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "refundETH", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "safeTransferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "safeTransferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "bool", + name: "approved", + type: "bool", + }, + ], + name: "setApprovalForAll", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "bytes4", + name: "interfaceId", + type: "bytes4", + }, + ], + name: "supportsInterface", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "token", + type: "address", + }, + { + internalType: "uint256", + name: "amountMinimum", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + ], + name: "sweepToken", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [], + name: "symbol", + outputs: [ + { + internalType: "string", + name: "", + type: "string", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "index", + type: "uint256", + }, + ], + name: "tokenByIndex", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + { + internalType: "uint256", + name: "index", + type: "uint256", + }, + ], + name: "tokenOfOwnerByIndex", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "tokenURI", + outputs: [ + { + internalType: "string", + name: "", + type: "string", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "totalSupply", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "transferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "amountMinimum", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + ], + name: "unwrapWETH9", + outputs: [], + stateMutability: "payable", + type: "function", + }, +] as const; + +export class IPCSV3NonfungiblePositionManager__factory { + static readonly abi = _abi; + static createInterface(): IPCSV3NonfungiblePositionManagerInterface { + return new utils.Interface( + _abi + ) as IPCSV3NonfungiblePositionManagerInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IPCSV3NonfungiblePositionManager { + return new Contract( + address, + _abi, + signerOrProvider + ) as IPCSV3NonfungiblePositionManager; + } +} diff --git a/src/typechain-typesV4/factories/@aperture_finance/uni-v3-lib/src/interfaces/ISlipStreamNonfungiblePositionManager__factory.ts b/src/typechain-typesV4/factories/@aperture_finance/uni-v3-lib/src/interfaces/ISlipStreamNonfungiblePositionManager__factory.ts new file mode 100644 index 00000000..3f4629d3 --- /dev/null +++ b/src/typechain-typesV4/factories/@aperture_finance/uni-v3-lib/src/interfaces/ISlipStreamNonfungiblePositionManager__factory.ts @@ -0,0 +1,1070 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + ISlipStreamNonfungiblePositionManager, + ISlipStreamNonfungiblePositionManagerInterface, +} from "../../../../../@aperture_finance/uni-v3-lib/src/interfaces/ISlipStreamNonfungiblePositionManager"; + +const _abi = [ + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "approved", + type: "address", + }, + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Approval", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "operator", + type: "address", + }, + { + indexed: false, + internalType: "bool", + name: "approved", + type: "bool", + }, + ], + name: "ApprovalForAll", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + indexed: false, + internalType: "address", + name: "recipient", + type: "address", + }, + { + indexed: false, + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + name: "Collect", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + indexed: false, + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + indexed: false, + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + name: "DecreaseLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + indexed: false, + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + indexed: false, + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + name: "IncreaseLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "tokenDescriptor", + type: "address", + }, + ], + name: "TokenDescriptorChanged", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "from", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "to", + type: "address", + }, + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Transfer", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "TransferOwnership", + type: "event", + }, + { + inputs: [], + name: "DOMAIN_SEPARATOR", + outputs: [ + { + internalType: "bytes32", + name: "", + type: "bytes32", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "PERMIT_TYPEHASH", + outputs: [ + { + internalType: "bytes32", + name: "", + type: "bytes32", + }, + ], + stateMutability: "pure", + type: "function", + }, + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "approve", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "balanceOf", + outputs: [ + { + internalType: "uint256", + name: "balance", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "burn", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint128", + name: "amount0Max", + type: "uint128", + }, + { + internalType: "uint128", + name: "amount1Max", + type: "uint128", + }, + ], + internalType: "struct ICommonNonfungiblePositionManager.CollectParams", + name: "params", + type: "tuple", + }, + ], + name: "collect", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + ], + name: "decreaseLiquidity", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [], + name: "factory", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "getApproved", + outputs: [ + { + internalType: "address", + name: "operator", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + ], + name: "increaseLiquidity", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + ], + name: "isApprovedForAll", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "int24", + name: "tickSpacing", + type: "int24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + internalType: "struct ISlipStreamNonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + ], + name: "mint", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [], + name: "name", + outputs: [ + { + internalType: "string", + name: "", + type: "string", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "owner", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "ownerOf", + outputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "spender", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "permit", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "positions", + outputs: [ + { + internalType: "uint96", + name: "nonce", + type: "uint96", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "int24", + name: "tickSpacing", + type: "int24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "feeGrowthInside0LastX128", + type: "uint256", + }, + { + internalType: "uint256", + name: "feeGrowthInside1LastX128", + type: "uint256", + }, + { + internalType: "uint128", + name: "tokensOwed0", + type: "uint128", + }, + { + internalType: "uint128", + name: "tokensOwed1", + type: "uint128", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "refundETH", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "safeTransferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "safeTransferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "bool", + name: "approved", + type: "bool", + }, + ], + name: "setApprovalForAll", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "_owner", + type: "address", + }, + ], + name: "setOwner", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "_tokenDescriptor", + type: "address", + }, + ], + name: "setTokenDescriptor", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "bytes4", + name: "interfaceId", + type: "bytes4", + }, + ], + name: "supportsInterface", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "token", + type: "address", + }, + { + internalType: "uint256", + name: "amountMinimum", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + ], + name: "sweepToken", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [], + name: "symbol", + outputs: [ + { + internalType: "string", + name: "", + type: "string", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "index", + type: "uint256", + }, + ], + name: "tokenByIndex", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "tokenDescriptor", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + { + internalType: "uint256", + name: "index", + type: "uint256", + }, + ], + name: "tokenOfOwnerByIndex", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "tokenURI", + outputs: [ + { + internalType: "string", + name: "", + type: "string", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "totalSupply", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "transferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "amountMinimum", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + ], + name: "unwrapWETH9", + outputs: [], + stateMutability: "payable", + type: "function", + }, +] as const; + +export class ISlipStreamNonfungiblePositionManager__factory { + static readonly abi = _abi; + static createInterface(): ISlipStreamNonfungiblePositionManagerInterface { + return new utils.Interface( + _abi + ) as ISlipStreamNonfungiblePositionManagerInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): ISlipStreamNonfungiblePositionManager { + return new Contract( + address, + _abi, + signerOrProvider + ) as ISlipStreamNonfungiblePositionManager; + } +} diff --git a/src/typechain-typesV4/factories/@aperture_finance/uni-v3-lib/src/interfaces/IUniswapV3NonfungiblePositionManager__factory.ts b/src/typechain-typesV4/factories/@aperture_finance/uni-v3-lib/src/interfaces/IUniswapV3NonfungiblePositionManager__factory.ts new file mode 100644 index 00000000..b9c23f99 --- /dev/null +++ b/src/typechain-typesV4/factories/@aperture_finance/uni-v3-lib/src/interfaces/IUniswapV3NonfungiblePositionManager__factory.ts @@ -0,0 +1,1021 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IUniswapV3NonfungiblePositionManager, + IUniswapV3NonfungiblePositionManagerInterface, +} from "../../../../../@aperture_finance/uni-v3-lib/src/interfaces/IUniswapV3NonfungiblePositionManager"; + +const _abi = [ + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "approved", + type: "address", + }, + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Approval", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "operator", + type: "address", + }, + { + indexed: false, + internalType: "bool", + name: "approved", + type: "bool", + }, + ], + name: "ApprovalForAll", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + indexed: false, + internalType: "address", + name: "recipient", + type: "address", + }, + { + indexed: false, + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + name: "Collect", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + indexed: false, + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + indexed: false, + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + name: "DecreaseLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + indexed: false, + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + indexed: false, + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + name: "IncreaseLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "from", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "to", + type: "address", + }, + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Transfer", + type: "event", + }, + { + inputs: [], + name: "DOMAIN_SEPARATOR", + outputs: [ + { + internalType: "bytes32", + name: "", + type: "bytes32", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "PERMIT_TYPEHASH", + outputs: [ + { + internalType: "bytes32", + name: "", + type: "bytes32", + }, + ], + stateMutability: "pure", + type: "function", + }, + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "approve", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "balanceOf", + outputs: [ + { + internalType: "uint256", + name: "balance", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "burn", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint128", + name: "amount0Max", + type: "uint128", + }, + { + internalType: "uint128", + name: "amount1Max", + type: "uint128", + }, + ], + internalType: "struct ICommonNonfungiblePositionManager.CollectParams", + name: "params", + type: "tuple", + }, + ], + name: "collect", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + name: "createAndInitializePoolIfNecessary", + outputs: [ + { + internalType: "address", + name: "pool", + type: "address", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + ], + name: "decreaseLiquidity", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [], + name: "factory", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "getApproved", + outputs: [ + { + internalType: "address", + name: "operator", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + ], + name: "increaseLiquidity", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + ], + name: "isApprovedForAll", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + ], + name: "mint", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [], + name: "name", + outputs: [ + { + internalType: "string", + name: "", + type: "string", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "ownerOf", + outputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "spender", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "permit", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "positions", + outputs: [ + { + internalType: "uint96", + name: "nonce", + type: "uint96", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "feeGrowthInside0LastX128", + type: "uint256", + }, + { + internalType: "uint256", + name: "feeGrowthInside1LastX128", + type: "uint256", + }, + { + internalType: "uint128", + name: "tokensOwed0", + type: "uint128", + }, + { + internalType: "uint128", + name: "tokensOwed1", + type: "uint128", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "refundETH", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "safeTransferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "safeTransferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "bool", + name: "approved", + type: "bool", + }, + ], + name: "setApprovalForAll", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "bytes4", + name: "interfaceId", + type: "bytes4", + }, + ], + name: "supportsInterface", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "token", + type: "address", + }, + { + internalType: "uint256", + name: "amountMinimum", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + ], + name: "sweepToken", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [], + name: "symbol", + outputs: [ + { + internalType: "string", + name: "", + type: "string", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "index", + type: "uint256", + }, + ], + name: "tokenByIndex", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + { + internalType: "uint256", + name: "index", + type: "uint256", + }, + ], + name: "tokenOfOwnerByIndex", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "tokenURI", + outputs: [ + { + internalType: "string", + name: "", + type: "string", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "totalSupply", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "transferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "amountMinimum", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + ], + name: "unwrapWETH9", + outputs: [], + stateMutability: "payable", + type: "function", + }, +] as const; + +export class IUniswapV3NonfungiblePositionManager__factory { + static readonly abi = _abi; + static createInterface(): IUniswapV3NonfungiblePositionManagerInterface { + return new utils.Interface( + _abi + ) as IUniswapV3NonfungiblePositionManagerInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IUniswapV3NonfungiblePositionManager { + return new Contract( + address, + _abi, + signerOrProvider + ) as IUniswapV3NonfungiblePositionManager; + } +} diff --git a/src/typechain-typesV4/factories/@aperture_finance/uni-v3-lib/src/interfaces/index.ts b/src/typechain-typesV4/factories/@aperture_finance/uni-v3-lib/src/interfaces/index.ts new file mode 100644 index 00000000..70ad673d --- /dev/null +++ b/src/typechain-typesV4/factories/@aperture_finance/uni-v3-lib/src/interfaces/index.ts @@ -0,0 +1,7 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export { ICommonNonfungiblePositionManager__factory } from "./ICommonNonfungiblePositionManager__factory"; +export { IPCSV3NonfungiblePositionManager__factory } from "./IPCSV3NonfungiblePositionManager__factory"; +export { ISlipStreamNonfungiblePositionManager__factory } from "./ISlipStreamNonfungiblePositionManager__factory"; +export { IUniswapV3NonfungiblePositionManager__factory } from "./IUniswapV3NonfungiblePositionManager__factory"; diff --git a/src/typechain-typesV4/factories/@openzeppelin/contracts/access/Ownable__factory.ts b/src/typechain-typesV4/factories/@openzeppelin/contracts/access/Ownable__factory.ts new file mode 100644 index 00000000..eba75cbd --- /dev/null +++ b/src/typechain-typesV4/factories/@openzeppelin/contracts/access/Ownable__factory.ts @@ -0,0 +1,100 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + Ownable, + OwnableInterface, +} from "../../../../@openzeppelin/contracts/access/Ownable"; + +const _abi = [ + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "OwnableInvalidOwner", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "account", + type: "address", + }, + ], + name: "OwnableUnauthorizedAccount", + type: "error", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "previousOwner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "OwnershipTransferred", + type: "event", + }, + { + inputs: [], + name: "owner", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "renounceOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "transferOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, +] as const; + +export class Ownable__factory { + static readonly abi = _abi; + static createInterface(): OwnableInterface { + return new utils.Interface(_abi) as OwnableInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): Ownable { + return new Contract(address, _abi, signerOrProvider) as Ownable; + } +} diff --git a/src/typechain-typesV4/factories/@openzeppelin/contracts/access/index.ts b/src/typechain-typesV4/factories/@openzeppelin/contracts/access/index.ts new file mode 100644 index 00000000..e332ae32 --- /dev/null +++ b/src/typechain-typesV4/factories/@openzeppelin/contracts/access/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export { Ownable__factory } from "./Ownable__factory"; diff --git a/src/typechain-typesV4/factories/@openzeppelin/contracts/index.ts b/src/typechain-typesV4/factories/@openzeppelin/contracts/index.ts new file mode 100644 index 00000000..ed5ad1bc --- /dev/null +++ b/src/typechain-typesV4/factories/@openzeppelin/contracts/index.ts @@ -0,0 +1,6 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as access from "./access"; +export * as token from "./token"; +export * as utils from "./utils"; diff --git a/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC20/IERC20__factory.ts b/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC20/IERC20__factory.ts new file mode 100644 index 00000000..2852323a --- /dev/null +++ b/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC20/IERC20__factory.ts @@ -0,0 +1,206 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IERC20, + IERC20Interface, +} from "../../../../../@openzeppelin/contracts/token/ERC20/IERC20"; + +const _abi = [ + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "spender", + type: "address", + }, + { + indexed: false, + internalType: "uint256", + name: "value", + type: "uint256", + }, + ], + name: "Approval", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "from", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "to", + type: "address", + }, + { + indexed: false, + internalType: "uint256", + name: "value", + type: "uint256", + }, + ], + name: "Transfer", + type: "event", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + { + internalType: "address", + name: "spender", + type: "address", + }, + ], + name: "allowance", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "spender", + type: "address", + }, + { + internalType: "uint256", + name: "value", + type: "uint256", + }, + ], + name: "approve", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "account", + type: "address", + }, + ], + name: "balanceOf", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "totalSupply", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "value", + type: "uint256", + }, + ], + name: "transfer", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "value", + type: "uint256", + }, + ], + name: "transferFrom", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, +] as const; + +export class IERC20__factory { + static readonly abi = _abi; + static createInterface(): IERC20Interface { + return new utils.Interface(_abi) as IERC20Interface; + } + static connect(address: string, signerOrProvider: Signer | Provider): IERC20 { + return new Contract(address, _abi, signerOrProvider) as IERC20; + } +} diff --git a/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata__factory.ts b/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata__factory.ts new file mode 100644 index 00000000..12eebd22 --- /dev/null +++ b/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata__factory.ts @@ -0,0 +1,248 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IERC20Metadata, + IERC20MetadataInterface, +} from "../../../../../../@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata"; + +const _abi = [ + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "spender", + type: "address", + }, + { + indexed: false, + internalType: "uint256", + name: "value", + type: "uint256", + }, + ], + name: "Approval", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "from", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "to", + type: "address", + }, + { + indexed: false, + internalType: "uint256", + name: "value", + type: "uint256", + }, + ], + name: "Transfer", + type: "event", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + { + internalType: "address", + name: "spender", + type: "address", + }, + ], + name: "allowance", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "spender", + type: "address", + }, + { + internalType: "uint256", + name: "value", + type: "uint256", + }, + ], + name: "approve", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "account", + type: "address", + }, + ], + name: "balanceOf", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "decimals", + outputs: [ + { + internalType: "uint8", + name: "", + type: "uint8", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "name", + outputs: [ + { + internalType: "string", + name: "", + type: "string", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "symbol", + outputs: [ + { + internalType: "string", + name: "", + type: "string", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "totalSupply", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "value", + type: "uint256", + }, + ], + name: "transfer", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "value", + type: "uint256", + }, + ], + name: "transferFrom", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, +] as const; + +export class IERC20Metadata__factory { + static readonly abi = _abi; + static createInterface(): IERC20MetadataInterface { + return new utils.Interface(_abi) as IERC20MetadataInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IERC20Metadata { + return new Contract(address, _abi, signerOrProvider) as IERC20Metadata; + } +} diff --git a/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC20/extensions/index.ts b/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC20/extensions/index.ts new file mode 100644 index 00000000..b9477f85 --- /dev/null +++ b/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC20/extensions/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export { IERC20Metadata__factory } from "./IERC20Metadata__factory"; diff --git a/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC20/index.ts b/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC20/index.ts new file mode 100644 index 00000000..6e86faa7 --- /dev/null +++ b/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC20/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as extensions from "./extensions"; +export { IERC20__factory } from "./IERC20__factory"; diff --git a/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC721/IERC721__factory.ts b/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC721/IERC721__factory.ts new file mode 100644 index 00000000..987eecaa --- /dev/null +++ b/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC721/IERC721__factory.ts @@ -0,0 +1,311 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IERC721, + IERC721Interface, +} from "../../../../../@openzeppelin/contracts/token/ERC721/IERC721"; + +const _abi = [ + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "approved", + type: "address", + }, + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Approval", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "operator", + type: "address", + }, + { + indexed: false, + internalType: "bool", + name: "approved", + type: "bool", + }, + ], + name: "ApprovalForAll", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "from", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "to", + type: "address", + }, + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Transfer", + type: "event", + }, + { + inputs: [ + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "approve", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "balanceOf", + outputs: [ + { + internalType: "uint256", + name: "balance", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "getApproved", + outputs: [ + { + internalType: "address", + name: "operator", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + ], + name: "isApprovedForAll", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "ownerOf", + outputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "safeTransferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "safeTransferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "bool", + name: "approved", + type: "bool", + }, + ], + name: "setApprovalForAll", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "bytes4", + name: "interfaceId", + type: "bytes4", + }, + ], + name: "supportsInterface", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "transferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, +] as const; + +export class IERC721__factory { + static readonly abi = _abi; + static createInterface(): IERC721Interface { + return new utils.Interface(_abi) as IERC721Interface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IERC721 { + return new Contract(address, _abi, signerOrProvider) as IERC721; + } +} diff --git a/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC721/extensions/IERC721Enumerable__factory.ts b/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC721/extensions/IERC721Enumerable__factory.ts new file mode 100644 index 00000000..93503198 --- /dev/null +++ b/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC721/extensions/IERC721Enumerable__factory.ts @@ -0,0 +1,367 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IERC721Enumerable, + IERC721EnumerableInterface, +} from "../../../../../../@openzeppelin/contracts/token/ERC721/extensions/IERC721Enumerable"; + +const _abi = [ + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "approved", + type: "address", + }, + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Approval", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "operator", + type: "address", + }, + { + indexed: false, + internalType: "bool", + name: "approved", + type: "bool", + }, + ], + name: "ApprovalForAll", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "from", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "to", + type: "address", + }, + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Transfer", + type: "event", + }, + { + inputs: [ + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "approve", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "balanceOf", + outputs: [ + { + internalType: "uint256", + name: "balance", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "getApproved", + outputs: [ + { + internalType: "address", + name: "operator", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + ], + name: "isApprovedForAll", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "ownerOf", + outputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "safeTransferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "safeTransferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "bool", + name: "approved", + type: "bool", + }, + ], + name: "setApprovalForAll", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "bytes4", + name: "interfaceId", + type: "bytes4", + }, + ], + name: "supportsInterface", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "index", + type: "uint256", + }, + ], + name: "tokenByIndex", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + { + internalType: "uint256", + name: "index", + type: "uint256", + }, + ], + name: "tokenOfOwnerByIndex", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "totalSupply", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "transferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, +] as const; + +export class IERC721Enumerable__factory { + static readonly abi = _abi; + static createInterface(): IERC721EnumerableInterface { + return new utils.Interface(_abi) as IERC721EnumerableInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IERC721Enumerable { + return new Contract(address, _abi, signerOrProvider) as IERC721Enumerable; + } +} diff --git a/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC721/extensions/IERC721Metadata__factory.ts b/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC721/extensions/IERC721Metadata__factory.ts new file mode 100644 index 00000000..9db53d58 --- /dev/null +++ b/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC721/extensions/IERC721Metadata__factory.ts @@ -0,0 +1,356 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IERC721Metadata, + IERC721MetadataInterface, +} from "../../../../../../@openzeppelin/contracts/token/ERC721/extensions/IERC721Metadata"; + +const _abi = [ + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "approved", + type: "address", + }, + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Approval", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "operator", + type: "address", + }, + { + indexed: false, + internalType: "bool", + name: "approved", + type: "bool", + }, + ], + name: "ApprovalForAll", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "from", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "to", + type: "address", + }, + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Transfer", + type: "event", + }, + { + inputs: [ + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "approve", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "balanceOf", + outputs: [ + { + internalType: "uint256", + name: "balance", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "getApproved", + outputs: [ + { + internalType: "address", + name: "operator", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + ], + name: "isApprovedForAll", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "name", + outputs: [ + { + internalType: "string", + name: "", + type: "string", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "ownerOf", + outputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "safeTransferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "safeTransferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "bool", + name: "approved", + type: "bool", + }, + ], + name: "setApprovalForAll", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "bytes4", + name: "interfaceId", + type: "bytes4", + }, + ], + name: "supportsInterface", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "symbol", + outputs: [ + { + internalType: "string", + name: "", + type: "string", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "tokenURI", + outputs: [ + { + internalType: "string", + name: "", + type: "string", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "transferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, +] as const; + +export class IERC721Metadata__factory { + static readonly abi = _abi; + static createInterface(): IERC721MetadataInterface { + return new utils.Interface(_abi) as IERC721MetadataInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IERC721Metadata { + return new Contract(address, _abi, signerOrProvider) as IERC721Metadata; + } +} diff --git a/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC721/extensions/index.ts b/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC721/extensions/index.ts new file mode 100644 index 00000000..3dbf3808 --- /dev/null +++ b/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC721/extensions/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export { IERC721Enumerable__factory } from "./IERC721Enumerable__factory"; +export { IERC721Metadata__factory } from "./IERC721Metadata__factory"; diff --git a/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC721/index.ts b/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC721/index.ts new file mode 100644 index 00000000..84c66bf9 --- /dev/null +++ b/src/typechain-typesV4/factories/@openzeppelin/contracts/token/ERC721/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as extensions from "./extensions"; +export { IERC721__factory } from "./IERC721__factory"; diff --git a/src/typechain-typesV4/factories/@openzeppelin/contracts/token/index.ts b/src/typechain-typesV4/factories/@openzeppelin/contracts/token/index.ts new file mode 100644 index 00000000..e1f8d490 --- /dev/null +++ b/src/typechain-typesV4/factories/@openzeppelin/contracts/token/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as erc20 from "./ERC20"; +export * as erc721 from "./ERC721"; diff --git a/src/typechain-typesV4/factories/@openzeppelin/contracts/utils/index.ts b/src/typechain-typesV4/factories/@openzeppelin/contracts/utils/index.ts new file mode 100644 index 00000000..03cab177 --- /dev/null +++ b/src/typechain-typesV4/factories/@openzeppelin/contracts/utils/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as introspection from "./introspection"; diff --git a/src/typechain-typesV4/factories/@openzeppelin/contracts/utils/introspection/IERC165__factory.ts b/src/typechain-typesV4/factories/@openzeppelin/contracts/utils/introspection/IERC165__factory.ts new file mode 100644 index 00000000..71bfb8a9 --- /dev/null +++ b/src/typechain-typesV4/factories/@openzeppelin/contracts/utils/introspection/IERC165__factory.ts @@ -0,0 +1,45 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IERC165, + IERC165Interface, +} from "../../../../../@openzeppelin/contracts/utils/introspection/IERC165"; + +const _abi = [ + { + inputs: [ + { + internalType: "bytes4", + name: "interfaceId", + type: "bytes4", + }, + ], + name: "supportsInterface", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, +] as const; + +export class IERC165__factory { + static readonly abi = _abi; + static createInterface(): IERC165Interface { + return new utils.Interface(_abi) as IERC165Interface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IERC165 { + return new Contract(address, _abi, signerOrProvider) as IERC165; + } +} diff --git a/src/typechain-typesV4/factories/@openzeppelin/contracts/utils/introspection/index.ts b/src/typechain-typesV4/factories/@openzeppelin/contracts/utils/introspection/index.ts new file mode 100644 index 00000000..85d37333 --- /dev/null +++ b/src/typechain-typesV4/factories/@openzeppelin/contracts/utils/introspection/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export { IERC165__factory } from "./IERC165__factory"; diff --git a/src/typechain-typesV4/factories/@openzeppelin/index.ts b/src/typechain-typesV4/factories/@openzeppelin/index.ts new file mode 100644 index 00000000..6397da09 --- /dev/null +++ b/src/typechain-typesV4/factories/@openzeppelin/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as contracts from "./contracts"; diff --git a/src/typechain-typesV4/factories/@pancakeswap/index.ts b/src/typechain-typesV4/factories/@pancakeswap/index.ts new file mode 100644 index 00000000..803fd16e --- /dev/null +++ b/src/typechain-typesV4/factories/@pancakeswap/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as v3Core from "./v3-core"; diff --git a/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/index.ts b/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/index.ts new file mode 100644 index 00000000..1d3444d5 --- /dev/null +++ b/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as interfaces from "./interfaces"; diff --git a/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/IPancakeV3Pool__factory.ts b/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/IPancakeV3Pool__factory.ts new file mode 100644 index 00000000..99691d58 --- /dev/null +++ b/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/IPancakeV3Pool__factory.ts @@ -0,0 +1,1032 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IPancakeV3Pool, + IPancakeV3PoolInterface, +} from "../../../../../@pancakeswap/v3-core/contracts/interfaces/IPancakeV3Pool"; + +const _abi = [ + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + indexed: true, + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + indexed: false, + internalType: "uint128", + name: "amount", + type: "uint128", + }, + { + indexed: false, + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + name: "Burn", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: false, + internalType: "address", + name: "recipient", + type: "address", + }, + { + indexed: true, + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + indexed: true, + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + indexed: false, + internalType: "uint128", + name: "amount0", + type: "uint128", + }, + { + indexed: false, + internalType: "uint128", + name: "amount1", + type: "uint128", + }, + ], + name: "Collect", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "sender", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "recipient", + type: "address", + }, + { + indexed: false, + internalType: "uint128", + name: "amount0", + type: "uint128", + }, + { + indexed: false, + internalType: "uint128", + name: "amount1", + type: "uint128", + }, + ], + name: "CollectProtocol", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "sender", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "recipient", + type: "address", + }, + { + indexed: false, + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "paid0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "paid1", + type: "uint256", + }, + ], + name: "Flash", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "uint16", + name: "observationCardinalityNextOld", + type: "uint16", + }, + { + indexed: false, + internalType: "uint16", + name: "observationCardinalityNextNew", + type: "uint16", + }, + ], + name: "IncreaseObservationCardinalityNext", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + { + indexed: false, + internalType: "int24", + name: "tick", + type: "int24", + }, + ], + name: "Initialize", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address", + name: "sender", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + indexed: true, + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + indexed: false, + internalType: "uint128", + name: "amount", + type: "uint128", + }, + { + indexed: false, + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + name: "Mint", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "uint32", + name: "feeProtocol0Old", + type: "uint32", + }, + { + indexed: false, + internalType: "uint32", + name: "feeProtocol1Old", + type: "uint32", + }, + { + indexed: false, + internalType: "uint32", + name: "feeProtocol0New", + type: "uint32", + }, + { + indexed: false, + internalType: "uint32", + name: "feeProtocol1New", + type: "uint32", + }, + ], + name: "SetFeeProtocol", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "sender", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "recipient", + type: "address", + }, + { + indexed: false, + internalType: "int256", + name: "amount0", + type: "int256", + }, + { + indexed: false, + internalType: "int256", + name: "amount1", + type: "int256", + }, + { + indexed: false, + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + { + indexed: false, + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + indexed: false, + internalType: "int24", + name: "tick", + type: "int24", + }, + { + indexed: false, + internalType: "uint128", + name: "protocolFeesToken0", + type: "uint128", + }, + { + indexed: false, + internalType: "uint128", + name: "protocolFeesToken1", + type: "uint128", + }, + ], + name: "Swap", + type: "event", + }, + { + inputs: [ + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint128", + name: "amount", + type: "uint128", + }, + ], + name: "burn", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint128", + name: "amount0Requested", + type: "uint128", + }, + { + internalType: "uint128", + name: "amount1Requested", + type: "uint128", + }, + ], + name: "collect", + outputs: [ + { + internalType: "uint128", + name: "amount0", + type: "uint128", + }, + { + internalType: "uint128", + name: "amount1", + type: "uint128", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint128", + name: "amount0Requested", + type: "uint128", + }, + { + internalType: "uint128", + name: "amount1Requested", + type: "uint128", + }, + ], + name: "collectProtocol", + outputs: [ + { + internalType: "uint128", + name: "amount0", + type: "uint128", + }, + { + internalType: "uint128", + name: "amount1", + type: "uint128", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [], + name: "factory", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "fee", + outputs: [ + { + internalType: "uint24", + name: "", + type: "uint24", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "feeGrowthGlobal0X128", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "feeGrowthGlobal1X128", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "flash", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint16", + name: "observationCardinalityNext", + type: "uint16", + }, + ], + name: "increaseObservationCardinalityNext", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + name: "initialize", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [], + name: "liquidity", + outputs: [ + { + internalType: "uint128", + name: "", + type: "uint128", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "maxLiquidityPerTick", + outputs: [ + { + internalType: "uint128", + name: "", + type: "uint128", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint128", + name: "amount", + type: "uint128", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "mint", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "index", + type: "uint256", + }, + ], + name: "observations", + outputs: [ + { + internalType: "uint32", + name: "blockTimestamp", + type: "uint32", + }, + { + internalType: "int56", + name: "tickCumulative", + type: "int56", + }, + { + internalType: "uint160", + name: "secondsPerLiquidityCumulativeX128", + type: "uint160", + }, + { + internalType: "bool", + name: "initialized", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint32[]", + name: "secondsAgos", + type: "uint32[]", + }, + ], + name: "observe", + outputs: [ + { + internalType: "int56[]", + name: "tickCumulatives", + type: "int56[]", + }, + { + internalType: "uint160[]", + name: "secondsPerLiquidityCumulativeX128s", + type: "uint160[]", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "bytes32", + name: "key", + type: "bytes32", + }, + ], + name: "positions", + outputs: [ + { + internalType: "uint128", + name: "_liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "feeGrowthInside0LastX128", + type: "uint256", + }, + { + internalType: "uint256", + name: "feeGrowthInside1LastX128", + type: "uint256", + }, + { + internalType: "uint128", + name: "tokensOwed0", + type: "uint128", + }, + { + internalType: "uint128", + name: "tokensOwed1", + type: "uint128", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "protocolFees", + outputs: [ + { + internalType: "uint128", + name: "token0", + type: "uint128", + }, + { + internalType: "uint128", + name: "token1", + type: "uint128", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint32", + name: "feeProtocol0", + type: "uint32", + }, + { + internalType: "uint32", + name: "feeProtocol1", + type: "uint32", + }, + ], + name: "setFeeProtocol", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "lmPool", + type: "address", + }, + ], + name: "setLmPool", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [], + name: "slot0", + outputs: [ + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + { + internalType: "int24", + name: "tick", + type: "int24", + }, + { + internalType: "uint16", + name: "observationIndex", + type: "uint16", + }, + { + internalType: "uint16", + name: "observationCardinality", + type: "uint16", + }, + { + internalType: "uint16", + name: "observationCardinalityNext", + type: "uint16", + }, + { + internalType: "uint32", + name: "feeProtocol", + type: "uint32", + }, + { + internalType: "bool", + name: "unlocked", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + ], + name: "snapshotCumulativesInside", + outputs: [ + { + internalType: "int56", + name: "tickCumulativeInside", + type: "int56", + }, + { + internalType: "uint160", + name: "secondsPerLiquidityInsideX128", + type: "uint160", + }, + { + internalType: "uint32", + name: "secondsInside", + type: "uint32", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "bool", + name: "zeroForOne", + type: "bool", + }, + { + internalType: "int256", + name: "amountSpecified", + type: "int256", + }, + { + internalType: "uint160", + name: "sqrtPriceLimitX96", + type: "uint160", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "swap", + outputs: [ + { + internalType: "int256", + name: "amount0", + type: "int256", + }, + { + internalType: "int256", + name: "amount1", + type: "int256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "int16", + name: "wordPosition", + type: "int16", + }, + ], + name: "tickBitmap", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "tickSpacing", + outputs: [ + { + internalType: "int24", + name: "", + type: "int24", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "int24", + name: "tick", + type: "int24", + }, + ], + name: "ticks", + outputs: [ + { + internalType: "uint128", + name: "liquidityGross", + type: "uint128", + }, + { + internalType: "int128", + name: "liquidityNet", + type: "int128", + }, + { + internalType: "uint256", + name: "feeGrowthOutside0X128", + type: "uint256", + }, + { + internalType: "uint256", + name: "feeGrowthOutside1X128", + type: "uint256", + }, + { + internalType: "int56", + name: "tickCumulativeOutside", + type: "int56", + }, + { + internalType: "uint160", + name: "secondsPerLiquidityOutsideX128", + type: "uint160", + }, + { + internalType: "uint32", + name: "secondsOutside", + type: "uint32", + }, + { + internalType: "bool", + name: "initialized", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "token0", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "token1", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, +] as const; + +export class IPancakeV3Pool__factory { + static readonly abi = _abi; + static createInterface(): IPancakeV3PoolInterface { + return new utils.Interface(_abi) as IPancakeV3PoolInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IPancakeV3Pool { + return new Contract(address, _abi, signerOrProvider) as IPancakeV3Pool; + } +} diff --git a/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/callback/IPancakeV3SwapCallback__factory.ts b/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/callback/IPancakeV3SwapCallback__factory.ts new file mode 100644 index 00000000..392f3e20 --- /dev/null +++ b/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/callback/IPancakeV3SwapCallback__factory.ts @@ -0,0 +1,53 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IPancakeV3SwapCallback, + IPancakeV3SwapCallbackInterface, +} from "../../../../../../@pancakeswap/v3-core/contracts/interfaces/callback/IPancakeV3SwapCallback"; + +const _abi = [ + { + inputs: [ + { + internalType: "int256", + name: "amount0Delta", + type: "int256", + }, + { + internalType: "int256", + name: "amount1Delta", + type: "int256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "pancakeV3SwapCallback", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, +] as const; + +export class IPancakeV3SwapCallback__factory { + static readonly abi = _abi; + static createInterface(): IPancakeV3SwapCallbackInterface { + return new utils.Interface(_abi) as IPancakeV3SwapCallbackInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IPancakeV3SwapCallback { + return new Contract( + address, + _abi, + signerOrProvider + ) as IPancakeV3SwapCallback; + } +} diff --git a/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/callback/index.ts b/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/callback/index.ts new file mode 100644 index 00000000..9bc1600f --- /dev/null +++ b/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/callback/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export { IPancakeV3SwapCallback__factory } from "./IPancakeV3SwapCallback__factory"; diff --git a/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/index.ts b/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/index.ts new file mode 100644 index 00000000..09881ce1 --- /dev/null +++ b/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/index.ts @@ -0,0 +1,6 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as callback from "./callback"; +export * as pool from "./pool"; +export { IPancakeV3Pool__factory } from "./IPancakeV3Pool__factory"; diff --git a/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolActions__factory.ts b/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolActions__factory.ts new file mode 100644 index 00000000..aab84cea --- /dev/null +++ b/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolActions__factory.ts @@ -0,0 +1,250 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IPancakeV3PoolActions, + IPancakeV3PoolActionsInterface, +} from "../../../../../../@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolActions"; + +const _abi = [ + { + inputs: [ + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint128", + name: "amount", + type: "uint128", + }, + ], + name: "burn", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint128", + name: "amount0Requested", + type: "uint128", + }, + { + internalType: "uint128", + name: "amount1Requested", + type: "uint128", + }, + ], + name: "collect", + outputs: [ + { + internalType: "uint128", + name: "amount0", + type: "uint128", + }, + { + internalType: "uint128", + name: "amount1", + type: "uint128", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "flash", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint16", + name: "observationCardinalityNext", + type: "uint16", + }, + ], + name: "increaseObservationCardinalityNext", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + name: "initialize", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint128", + name: "amount", + type: "uint128", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "mint", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "bool", + name: "zeroForOne", + type: "bool", + }, + { + internalType: "int256", + name: "amountSpecified", + type: "int256", + }, + { + internalType: "uint160", + name: "sqrtPriceLimitX96", + type: "uint160", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "swap", + outputs: [ + { + internalType: "int256", + name: "amount0", + type: "int256", + }, + { + internalType: "int256", + name: "amount1", + type: "int256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, +] as const; + +export class IPancakeV3PoolActions__factory { + static readonly abi = _abi; + static createInterface(): IPancakeV3PoolActionsInterface { + return new utils.Interface(_abi) as IPancakeV3PoolActionsInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IPancakeV3PoolActions { + return new Contract( + address, + _abi, + signerOrProvider + ) as IPancakeV3PoolActions; + } +} diff --git a/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolDerivedState__factory.ts b/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolDerivedState__factory.ts new file mode 100644 index 00000000..1c7e8f58 --- /dev/null +++ b/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolDerivedState__factory.ts @@ -0,0 +1,88 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IPancakeV3PoolDerivedState, + IPancakeV3PoolDerivedStateInterface, +} from "../../../../../../@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolDerivedState"; + +const _abi = [ + { + inputs: [ + { + internalType: "uint32[]", + name: "secondsAgos", + type: "uint32[]", + }, + ], + name: "observe", + outputs: [ + { + internalType: "int56[]", + name: "tickCumulatives", + type: "int56[]", + }, + { + internalType: "uint160[]", + name: "secondsPerLiquidityCumulativeX128s", + type: "uint160[]", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + ], + name: "snapshotCumulativesInside", + outputs: [ + { + internalType: "int56", + name: "tickCumulativeInside", + type: "int56", + }, + { + internalType: "uint160", + name: "secondsPerLiquidityInsideX128", + type: "uint160", + }, + { + internalType: "uint32", + name: "secondsInside", + type: "uint32", + }, + ], + stateMutability: "view", + type: "function", + }, +] as const; + +export class IPancakeV3PoolDerivedState__factory { + static readonly abi = _abi; + static createInterface(): IPancakeV3PoolDerivedStateInterface { + return new utils.Interface(_abi) as IPancakeV3PoolDerivedStateInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IPancakeV3PoolDerivedState { + return new Contract( + address, + _abi, + signerOrProvider + ) as IPancakeV3PoolDerivedState; + } +} diff --git a/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolEvents__factory.ts b/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolEvents__factory.ts new file mode 100644 index 00000000..a42d6e16 --- /dev/null +++ b/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolEvents__factory.ts @@ -0,0 +1,369 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IPancakeV3PoolEvents, + IPancakeV3PoolEventsInterface, +} from "../../../../../../@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolEvents"; + +const _abi = [ + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + indexed: true, + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + indexed: false, + internalType: "uint128", + name: "amount", + type: "uint128", + }, + { + indexed: false, + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + name: "Burn", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: false, + internalType: "address", + name: "recipient", + type: "address", + }, + { + indexed: true, + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + indexed: true, + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + indexed: false, + internalType: "uint128", + name: "amount0", + type: "uint128", + }, + { + indexed: false, + internalType: "uint128", + name: "amount1", + type: "uint128", + }, + ], + name: "Collect", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "sender", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "recipient", + type: "address", + }, + { + indexed: false, + internalType: "uint128", + name: "amount0", + type: "uint128", + }, + { + indexed: false, + internalType: "uint128", + name: "amount1", + type: "uint128", + }, + ], + name: "CollectProtocol", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "sender", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "recipient", + type: "address", + }, + { + indexed: false, + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "paid0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "paid1", + type: "uint256", + }, + ], + name: "Flash", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "uint16", + name: "observationCardinalityNextOld", + type: "uint16", + }, + { + indexed: false, + internalType: "uint16", + name: "observationCardinalityNextNew", + type: "uint16", + }, + ], + name: "IncreaseObservationCardinalityNext", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + { + indexed: false, + internalType: "int24", + name: "tick", + type: "int24", + }, + ], + name: "Initialize", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address", + name: "sender", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + indexed: true, + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + indexed: false, + internalType: "uint128", + name: "amount", + type: "uint128", + }, + { + indexed: false, + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + name: "Mint", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "uint32", + name: "feeProtocol0Old", + type: "uint32", + }, + { + indexed: false, + internalType: "uint32", + name: "feeProtocol1Old", + type: "uint32", + }, + { + indexed: false, + internalType: "uint32", + name: "feeProtocol0New", + type: "uint32", + }, + { + indexed: false, + internalType: "uint32", + name: "feeProtocol1New", + type: "uint32", + }, + ], + name: "SetFeeProtocol", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "sender", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "recipient", + type: "address", + }, + { + indexed: false, + internalType: "int256", + name: "amount0", + type: "int256", + }, + { + indexed: false, + internalType: "int256", + name: "amount1", + type: "int256", + }, + { + indexed: false, + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + { + indexed: false, + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + indexed: false, + internalType: "int24", + name: "tick", + type: "int24", + }, + { + indexed: false, + internalType: "uint128", + name: "protocolFeesToken0", + type: "uint128", + }, + { + indexed: false, + internalType: "uint128", + name: "protocolFeesToken1", + type: "uint128", + }, + ], + name: "Swap", + type: "event", + }, +] as const; + +export class IPancakeV3PoolEvents__factory { + static readonly abi = _abi; + static createInterface(): IPancakeV3PoolEventsInterface { + return new utils.Interface(_abi) as IPancakeV3PoolEventsInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IPancakeV3PoolEvents { + return new Contract( + address, + _abi, + signerOrProvider + ) as IPancakeV3PoolEvents; + } +} diff --git a/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolImmutables__factory.ts b/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolImmutables__factory.ts new file mode 100644 index 00000000..f1584a3e --- /dev/null +++ b/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolImmutables__factory.ts @@ -0,0 +1,108 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IPancakeV3PoolImmutables, + IPancakeV3PoolImmutablesInterface, +} from "../../../../../../@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolImmutables"; + +const _abi = [ + { + inputs: [], + name: "factory", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "fee", + outputs: [ + { + internalType: "uint24", + name: "", + type: "uint24", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "maxLiquidityPerTick", + outputs: [ + { + internalType: "uint128", + name: "", + type: "uint128", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "tickSpacing", + outputs: [ + { + internalType: "int24", + name: "", + type: "int24", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "token0", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "token1", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, +] as const; + +export class IPancakeV3PoolImmutables__factory { + static readonly abi = _abi; + static createInterface(): IPancakeV3PoolImmutablesInterface { + return new utils.Interface(_abi) as IPancakeV3PoolImmutablesInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IPancakeV3PoolImmutables { + return new Contract( + address, + _abi, + signerOrProvider + ) as IPancakeV3PoolImmutables; + } +} diff --git a/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolOwnerActions__factory.ts b/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolOwnerActions__factory.ts new file mode 100644 index 00000000..61dbdc02 --- /dev/null +++ b/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolOwnerActions__factory.ts @@ -0,0 +1,95 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IPancakeV3PoolOwnerActions, + IPancakeV3PoolOwnerActionsInterface, +} from "../../../../../../@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolOwnerActions"; + +const _abi = [ + { + inputs: [ + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint128", + name: "amount0Requested", + type: "uint128", + }, + { + internalType: "uint128", + name: "amount1Requested", + type: "uint128", + }, + ], + name: "collectProtocol", + outputs: [ + { + internalType: "uint128", + name: "amount0", + type: "uint128", + }, + { + internalType: "uint128", + name: "amount1", + type: "uint128", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint32", + name: "feeProtocol0", + type: "uint32", + }, + { + internalType: "uint32", + name: "feeProtocol1", + type: "uint32", + }, + ], + name: "setFeeProtocol", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "lmPool", + type: "address", + }, + ], + name: "setLmPool", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, +] as const; + +export class IPancakeV3PoolOwnerActions__factory { + static readonly abi = _abi; + static createInterface(): IPancakeV3PoolOwnerActionsInterface { + return new utils.Interface(_abi) as IPancakeV3PoolOwnerActionsInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IPancakeV3PoolOwnerActions { + return new Contract( + address, + _abi, + signerOrProvider + ) as IPancakeV3PoolOwnerActions; + } +} diff --git a/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolState__factory.ts b/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolState__factory.ts new file mode 100644 index 00000000..1e16eac2 --- /dev/null +++ b/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolState__factory.ts @@ -0,0 +1,272 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IPancakeV3PoolState, + IPancakeV3PoolStateInterface, +} from "../../../../../../@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolState"; + +const _abi = [ + { + inputs: [], + name: "feeGrowthGlobal0X128", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "feeGrowthGlobal1X128", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "liquidity", + outputs: [ + { + internalType: "uint128", + name: "", + type: "uint128", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "index", + type: "uint256", + }, + ], + name: "observations", + outputs: [ + { + internalType: "uint32", + name: "blockTimestamp", + type: "uint32", + }, + { + internalType: "int56", + name: "tickCumulative", + type: "int56", + }, + { + internalType: "uint160", + name: "secondsPerLiquidityCumulativeX128", + type: "uint160", + }, + { + internalType: "bool", + name: "initialized", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "bytes32", + name: "key", + type: "bytes32", + }, + ], + name: "positions", + outputs: [ + { + internalType: "uint128", + name: "_liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "feeGrowthInside0LastX128", + type: "uint256", + }, + { + internalType: "uint256", + name: "feeGrowthInside1LastX128", + type: "uint256", + }, + { + internalType: "uint128", + name: "tokensOwed0", + type: "uint128", + }, + { + internalType: "uint128", + name: "tokensOwed1", + type: "uint128", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "protocolFees", + outputs: [ + { + internalType: "uint128", + name: "token0", + type: "uint128", + }, + { + internalType: "uint128", + name: "token1", + type: "uint128", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "slot0", + outputs: [ + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + { + internalType: "int24", + name: "tick", + type: "int24", + }, + { + internalType: "uint16", + name: "observationIndex", + type: "uint16", + }, + { + internalType: "uint16", + name: "observationCardinality", + type: "uint16", + }, + { + internalType: "uint16", + name: "observationCardinalityNext", + type: "uint16", + }, + { + internalType: "uint32", + name: "feeProtocol", + type: "uint32", + }, + { + internalType: "bool", + name: "unlocked", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "int16", + name: "wordPosition", + type: "int16", + }, + ], + name: "tickBitmap", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "int24", + name: "tick", + type: "int24", + }, + ], + name: "ticks", + outputs: [ + { + internalType: "uint128", + name: "liquidityGross", + type: "uint128", + }, + { + internalType: "int128", + name: "liquidityNet", + type: "int128", + }, + { + internalType: "uint256", + name: "feeGrowthOutside0X128", + type: "uint256", + }, + { + internalType: "uint256", + name: "feeGrowthOutside1X128", + type: "uint256", + }, + { + internalType: "int56", + name: "tickCumulativeOutside", + type: "int56", + }, + { + internalType: "uint160", + name: "secondsPerLiquidityOutsideX128", + type: "uint160", + }, + { + internalType: "uint32", + name: "secondsOutside", + type: "uint32", + }, + { + internalType: "bool", + name: "initialized", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, +] as const; + +export class IPancakeV3PoolState__factory { + static readonly abi = _abi; + static createInterface(): IPancakeV3PoolStateInterface { + return new utils.Interface(_abi) as IPancakeV3PoolStateInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IPancakeV3PoolState { + return new Contract(address, _abi, signerOrProvider) as IPancakeV3PoolState; + } +} diff --git a/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/pool/index.ts b/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/pool/index.ts new file mode 100644 index 00000000..0bce3130 --- /dev/null +++ b/src/typechain-typesV4/factories/@pancakeswap/v3-core/contracts/interfaces/pool/index.ts @@ -0,0 +1,9 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export { IPancakeV3PoolActions__factory } from "./IPancakeV3PoolActions__factory"; +export { IPancakeV3PoolDerivedState__factory } from "./IPancakeV3PoolDerivedState__factory"; +export { IPancakeV3PoolEvents__factory } from "./IPancakeV3PoolEvents__factory"; +export { IPancakeV3PoolImmutables__factory } from "./IPancakeV3PoolImmutables__factory"; +export { IPancakeV3PoolOwnerActions__factory } from "./IPancakeV3PoolOwnerActions__factory"; +export { IPancakeV3PoolState__factory } from "./IPancakeV3PoolState__factory"; diff --git a/src/typechain-typesV4/factories/@pancakeswap/v3-core/index.ts b/src/typechain-typesV4/factories/@pancakeswap/v3-core/index.ts new file mode 100644 index 00000000..6397da09 --- /dev/null +++ b/src/typechain-typesV4/factories/@pancakeswap/v3-core/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as contracts from "./contracts"; diff --git a/src/typechain-typesV4/factories/@uniswap/index.ts b/src/typechain-typesV4/factories/@uniswap/index.ts new file mode 100644 index 00000000..546517dc --- /dev/null +++ b/src/typechain-typesV4/factories/@uniswap/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as v3Core from "./v3-core"; +export * as v3Periphery from "./v3-periphery"; diff --git a/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/index.ts b/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/index.ts new file mode 100644 index 00000000..1d3444d5 --- /dev/null +++ b/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as interfaces from "./interfaces"; diff --git a/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/IUniswapV3Pool__factory.ts b/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/IUniswapV3Pool__factory.ts new file mode 100644 index 00000000..71683bb2 --- /dev/null +++ b/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/IUniswapV3Pool__factory.ts @@ -0,0 +1,1007 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IUniswapV3Pool, + IUniswapV3PoolInterface, +} from "../../../../../@uniswap/v3-core/contracts/interfaces/IUniswapV3Pool"; + +const _abi = [ + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + indexed: true, + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + indexed: false, + internalType: "uint128", + name: "amount", + type: "uint128", + }, + { + indexed: false, + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + name: "Burn", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: false, + internalType: "address", + name: "recipient", + type: "address", + }, + { + indexed: true, + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + indexed: true, + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + indexed: false, + internalType: "uint128", + name: "amount0", + type: "uint128", + }, + { + indexed: false, + internalType: "uint128", + name: "amount1", + type: "uint128", + }, + ], + name: "Collect", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "sender", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "recipient", + type: "address", + }, + { + indexed: false, + internalType: "uint128", + name: "amount0", + type: "uint128", + }, + { + indexed: false, + internalType: "uint128", + name: "amount1", + type: "uint128", + }, + ], + name: "CollectProtocol", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "sender", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "recipient", + type: "address", + }, + { + indexed: false, + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "paid0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "paid1", + type: "uint256", + }, + ], + name: "Flash", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "uint16", + name: "observationCardinalityNextOld", + type: "uint16", + }, + { + indexed: false, + internalType: "uint16", + name: "observationCardinalityNextNew", + type: "uint16", + }, + ], + name: "IncreaseObservationCardinalityNext", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + { + indexed: false, + internalType: "int24", + name: "tick", + type: "int24", + }, + ], + name: "Initialize", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address", + name: "sender", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + indexed: true, + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + indexed: false, + internalType: "uint128", + name: "amount", + type: "uint128", + }, + { + indexed: false, + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + name: "Mint", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "uint8", + name: "feeProtocol0Old", + type: "uint8", + }, + { + indexed: false, + internalType: "uint8", + name: "feeProtocol1Old", + type: "uint8", + }, + { + indexed: false, + internalType: "uint8", + name: "feeProtocol0New", + type: "uint8", + }, + { + indexed: false, + internalType: "uint8", + name: "feeProtocol1New", + type: "uint8", + }, + ], + name: "SetFeeProtocol", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "sender", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "recipient", + type: "address", + }, + { + indexed: false, + internalType: "int256", + name: "amount0", + type: "int256", + }, + { + indexed: false, + internalType: "int256", + name: "amount1", + type: "int256", + }, + { + indexed: false, + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + { + indexed: false, + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + indexed: false, + internalType: "int24", + name: "tick", + type: "int24", + }, + ], + name: "Swap", + type: "event", + }, + { + inputs: [ + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint128", + name: "amount", + type: "uint128", + }, + ], + name: "burn", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint128", + name: "amount0Requested", + type: "uint128", + }, + { + internalType: "uint128", + name: "amount1Requested", + type: "uint128", + }, + ], + name: "collect", + outputs: [ + { + internalType: "uint128", + name: "amount0", + type: "uint128", + }, + { + internalType: "uint128", + name: "amount1", + type: "uint128", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint128", + name: "amount0Requested", + type: "uint128", + }, + { + internalType: "uint128", + name: "amount1Requested", + type: "uint128", + }, + ], + name: "collectProtocol", + outputs: [ + { + internalType: "uint128", + name: "amount0", + type: "uint128", + }, + { + internalType: "uint128", + name: "amount1", + type: "uint128", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [], + name: "factory", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "fee", + outputs: [ + { + internalType: "uint24", + name: "", + type: "uint24", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "feeGrowthGlobal0X128", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "feeGrowthGlobal1X128", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "flash", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint16", + name: "observationCardinalityNext", + type: "uint16", + }, + ], + name: "increaseObservationCardinalityNext", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + name: "initialize", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [], + name: "liquidity", + outputs: [ + { + internalType: "uint128", + name: "", + type: "uint128", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "maxLiquidityPerTick", + outputs: [ + { + internalType: "uint128", + name: "", + type: "uint128", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint128", + name: "amount", + type: "uint128", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "mint", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "index", + type: "uint256", + }, + ], + name: "observations", + outputs: [ + { + internalType: "uint32", + name: "blockTimestamp", + type: "uint32", + }, + { + internalType: "int56", + name: "tickCumulative", + type: "int56", + }, + { + internalType: "uint160", + name: "secondsPerLiquidityCumulativeX128", + type: "uint160", + }, + { + internalType: "bool", + name: "initialized", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint32[]", + name: "secondsAgos", + type: "uint32[]", + }, + ], + name: "observe", + outputs: [ + { + internalType: "int56[]", + name: "tickCumulatives", + type: "int56[]", + }, + { + internalType: "uint160[]", + name: "secondsPerLiquidityCumulativeX128s", + type: "uint160[]", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "bytes32", + name: "key", + type: "bytes32", + }, + ], + name: "positions", + outputs: [ + { + internalType: "uint128", + name: "_liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "feeGrowthInside0LastX128", + type: "uint256", + }, + { + internalType: "uint256", + name: "feeGrowthInside1LastX128", + type: "uint256", + }, + { + internalType: "uint128", + name: "tokensOwed0", + type: "uint128", + }, + { + internalType: "uint128", + name: "tokensOwed1", + type: "uint128", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "protocolFees", + outputs: [ + { + internalType: "uint128", + name: "token0", + type: "uint128", + }, + { + internalType: "uint128", + name: "token1", + type: "uint128", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint8", + name: "feeProtocol0", + type: "uint8", + }, + { + internalType: "uint8", + name: "feeProtocol1", + type: "uint8", + }, + ], + name: "setFeeProtocol", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [], + name: "slot0", + outputs: [ + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + { + internalType: "int24", + name: "tick", + type: "int24", + }, + { + internalType: "uint16", + name: "observationIndex", + type: "uint16", + }, + { + internalType: "uint16", + name: "observationCardinality", + type: "uint16", + }, + { + internalType: "uint16", + name: "observationCardinalityNext", + type: "uint16", + }, + { + internalType: "uint8", + name: "feeProtocol", + type: "uint8", + }, + { + internalType: "bool", + name: "unlocked", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + ], + name: "snapshotCumulativesInside", + outputs: [ + { + internalType: "int56", + name: "tickCumulativeInside", + type: "int56", + }, + { + internalType: "uint160", + name: "secondsPerLiquidityInsideX128", + type: "uint160", + }, + { + internalType: "uint32", + name: "secondsInside", + type: "uint32", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "bool", + name: "zeroForOne", + type: "bool", + }, + { + internalType: "int256", + name: "amountSpecified", + type: "int256", + }, + { + internalType: "uint160", + name: "sqrtPriceLimitX96", + type: "uint160", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "swap", + outputs: [ + { + internalType: "int256", + name: "amount0", + type: "int256", + }, + { + internalType: "int256", + name: "amount1", + type: "int256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "int16", + name: "wordPosition", + type: "int16", + }, + ], + name: "tickBitmap", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "tickSpacing", + outputs: [ + { + internalType: "int24", + name: "", + type: "int24", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "int24", + name: "tick", + type: "int24", + }, + ], + name: "ticks", + outputs: [ + { + internalType: "uint128", + name: "liquidityGross", + type: "uint128", + }, + { + internalType: "int128", + name: "liquidityNet", + type: "int128", + }, + { + internalType: "uint256", + name: "feeGrowthOutside0X128", + type: "uint256", + }, + { + internalType: "uint256", + name: "feeGrowthOutside1X128", + type: "uint256", + }, + { + internalType: "int56", + name: "tickCumulativeOutside", + type: "int56", + }, + { + internalType: "uint160", + name: "secondsPerLiquidityOutsideX128", + type: "uint160", + }, + { + internalType: "uint32", + name: "secondsOutside", + type: "uint32", + }, + { + internalType: "bool", + name: "initialized", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "token0", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "token1", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, +] as const; + +export class IUniswapV3Pool__factory { + static readonly abi = _abi; + static createInterface(): IUniswapV3PoolInterface { + return new utils.Interface(_abi) as IUniswapV3PoolInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IUniswapV3Pool { + return new Contract(address, _abi, signerOrProvider) as IUniswapV3Pool; + } +} diff --git a/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/callback/IUniswapV3SwapCallback__factory.ts b/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/callback/IUniswapV3SwapCallback__factory.ts new file mode 100644 index 00000000..a9788811 --- /dev/null +++ b/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/callback/IUniswapV3SwapCallback__factory.ts @@ -0,0 +1,53 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IUniswapV3SwapCallback, + IUniswapV3SwapCallbackInterface, +} from "../../../../../../@uniswap/v3-core/contracts/interfaces/callback/IUniswapV3SwapCallback"; + +const _abi = [ + { + inputs: [ + { + internalType: "int256", + name: "amount0Delta", + type: "int256", + }, + { + internalType: "int256", + name: "amount1Delta", + type: "int256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "uniswapV3SwapCallback", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, +] as const; + +export class IUniswapV3SwapCallback__factory { + static readonly abi = _abi; + static createInterface(): IUniswapV3SwapCallbackInterface { + return new utils.Interface(_abi) as IUniswapV3SwapCallbackInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IUniswapV3SwapCallback { + return new Contract( + address, + _abi, + signerOrProvider + ) as IUniswapV3SwapCallback; + } +} diff --git a/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/callback/index.ts b/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/callback/index.ts new file mode 100644 index 00000000..0c401bd0 --- /dev/null +++ b/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/callback/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export { IUniswapV3SwapCallback__factory } from "./IUniswapV3SwapCallback__factory"; diff --git a/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/index.ts b/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/index.ts new file mode 100644 index 00000000..c57eef33 --- /dev/null +++ b/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/index.ts @@ -0,0 +1,6 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as callback from "./callback"; +export * as pool from "./pool"; +export { IUniswapV3Pool__factory } from "./IUniswapV3Pool__factory"; diff --git a/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolActions__factory.ts b/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolActions__factory.ts new file mode 100644 index 00000000..678e131f --- /dev/null +++ b/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolActions__factory.ts @@ -0,0 +1,250 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IUniswapV3PoolActions, + IUniswapV3PoolActionsInterface, +} from "../../../../../../@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolActions"; + +const _abi = [ + { + inputs: [ + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint128", + name: "amount", + type: "uint128", + }, + ], + name: "burn", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint128", + name: "amount0Requested", + type: "uint128", + }, + { + internalType: "uint128", + name: "amount1Requested", + type: "uint128", + }, + ], + name: "collect", + outputs: [ + { + internalType: "uint128", + name: "amount0", + type: "uint128", + }, + { + internalType: "uint128", + name: "amount1", + type: "uint128", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "flash", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint16", + name: "observationCardinalityNext", + type: "uint16", + }, + ], + name: "increaseObservationCardinalityNext", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + name: "initialize", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint128", + name: "amount", + type: "uint128", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "mint", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "bool", + name: "zeroForOne", + type: "bool", + }, + { + internalType: "int256", + name: "amountSpecified", + type: "int256", + }, + { + internalType: "uint160", + name: "sqrtPriceLimitX96", + type: "uint160", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "swap", + outputs: [ + { + internalType: "int256", + name: "amount0", + type: "int256", + }, + { + internalType: "int256", + name: "amount1", + type: "int256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, +] as const; + +export class IUniswapV3PoolActions__factory { + static readonly abi = _abi; + static createInterface(): IUniswapV3PoolActionsInterface { + return new utils.Interface(_abi) as IUniswapV3PoolActionsInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IUniswapV3PoolActions { + return new Contract( + address, + _abi, + signerOrProvider + ) as IUniswapV3PoolActions; + } +} diff --git a/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolDerivedState__factory.ts b/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolDerivedState__factory.ts new file mode 100644 index 00000000..5676cd32 --- /dev/null +++ b/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolDerivedState__factory.ts @@ -0,0 +1,88 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IUniswapV3PoolDerivedState, + IUniswapV3PoolDerivedStateInterface, +} from "../../../../../../@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolDerivedState"; + +const _abi = [ + { + inputs: [ + { + internalType: "uint32[]", + name: "secondsAgos", + type: "uint32[]", + }, + ], + name: "observe", + outputs: [ + { + internalType: "int56[]", + name: "tickCumulatives", + type: "int56[]", + }, + { + internalType: "uint160[]", + name: "secondsPerLiquidityCumulativeX128s", + type: "uint160[]", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + ], + name: "snapshotCumulativesInside", + outputs: [ + { + internalType: "int56", + name: "tickCumulativeInside", + type: "int56", + }, + { + internalType: "uint160", + name: "secondsPerLiquidityInsideX128", + type: "uint160", + }, + { + internalType: "uint32", + name: "secondsInside", + type: "uint32", + }, + ], + stateMutability: "view", + type: "function", + }, +] as const; + +export class IUniswapV3PoolDerivedState__factory { + static readonly abi = _abi; + static createInterface(): IUniswapV3PoolDerivedStateInterface { + return new utils.Interface(_abi) as IUniswapV3PoolDerivedStateInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IUniswapV3PoolDerivedState { + return new Contract( + address, + _abi, + signerOrProvider + ) as IUniswapV3PoolDerivedState; + } +} diff --git a/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolEvents__factory.ts b/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolEvents__factory.ts new file mode 100644 index 00000000..47438de5 --- /dev/null +++ b/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolEvents__factory.ts @@ -0,0 +1,357 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IUniswapV3PoolEvents, + IUniswapV3PoolEventsInterface, +} from "../../../../../../@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolEvents"; + +const _abi = [ + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + indexed: true, + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + indexed: false, + internalType: "uint128", + name: "amount", + type: "uint128", + }, + { + indexed: false, + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + name: "Burn", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: false, + internalType: "address", + name: "recipient", + type: "address", + }, + { + indexed: true, + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + indexed: true, + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + indexed: false, + internalType: "uint128", + name: "amount0", + type: "uint128", + }, + { + indexed: false, + internalType: "uint128", + name: "amount1", + type: "uint128", + }, + ], + name: "Collect", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "sender", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "recipient", + type: "address", + }, + { + indexed: false, + internalType: "uint128", + name: "amount0", + type: "uint128", + }, + { + indexed: false, + internalType: "uint128", + name: "amount1", + type: "uint128", + }, + ], + name: "CollectProtocol", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "sender", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "recipient", + type: "address", + }, + { + indexed: false, + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "paid0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "paid1", + type: "uint256", + }, + ], + name: "Flash", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "uint16", + name: "observationCardinalityNextOld", + type: "uint16", + }, + { + indexed: false, + internalType: "uint16", + name: "observationCardinalityNextNew", + type: "uint16", + }, + ], + name: "IncreaseObservationCardinalityNext", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + { + indexed: false, + internalType: "int24", + name: "tick", + type: "int24", + }, + ], + name: "Initialize", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address", + name: "sender", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + indexed: true, + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + indexed: false, + internalType: "uint128", + name: "amount", + type: "uint128", + }, + { + indexed: false, + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + name: "Mint", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "uint8", + name: "feeProtocol0Old", + type: "uint8", + }, + { + indexed: false, + internalType: "uint8", + name: "feeProtocol1Old", + type: "uint8", + }, + { + indexed: false, + internalType: "uint8", + name: "feeProtocol0New", + type: "uint8", + }, + { + indexed: false, + internalType: "uint8", + name: "feeProtocol1New", + type: "uint8", + }, + ], + name: "SetFeeProtocol", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "sender", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "recipient", + type: "address", + }, + { + indexed: false, + internalType: "int256", + name: "amount0", + type: "int256", + }, + { + indexed: false, + internalType: "int256", + name: "amount1", + type: "int256", + }, + { + indexed: false, + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + { + indexed: false, + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + indexed: false, + internalType: "int24", + name: "tick", + type: "int24", + }, + ], + name: "Swap", + type: "event", + }, +] as const; + +export class IUniswapV3PoolEvents__factory { + static readonly abi = _abi; + static createInterface(): IUniswapV3PoolEventsInterface { + return new utils.Interface(_abi) as IUniswapV3PoolEventsInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IUniswapV3PoolEvents { + return new Contract( + address, + _abi, + signerOrProvider + ) as IUniswapV3PoolEvents; + } +} diff --git a/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolImmutables__factory.ts b/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolImmutables__factory.ts new file mode 100644 index 00000000..aa602597 --- /dev/null +++ b/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolImmutables__factory.ts @@ -0,0 +1,108 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IUniswapV3PoolImmutables, + IUniswapV3PoolImmutablesInterface, +} from "../../../../../../@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolImmutables"; + +const _abi = [ + { + inputs: [], + name: "factory", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "fee", + outputs: [ + { + internalType: "uint24", + name: "", + type: "uint24", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "maxLiquidityPerTick", + outputs: [ + { + internalType: "uint128", + name: "", + type: "uint128", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "tickSpacing", + outputs: [ + { + internalType: "int24", + name: "", + type: "int24", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "token0", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "token1", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, +] as const; + +export class IUniswapV3PoolImmutables__factory { + static readonly abi = _abi; + static createInterface(): IUniswapV3PoolImmutablesInterface { + return new utils.Interface(_abi) as IUniswapV3PoolImmutablesInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IUniswapV3PoolImmutables { + return new Contract( + address, + _abi, + signerOrProvider + ) as IUniswapV3PoolImmutables; + } +} diff --git a/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolOwnerActions__factory.ts b/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolOwnerActions__factory.ts new file mode 100644 index 00000000..3da8923a --- /dev/null +++ b/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolOwnerActions__factory.ts @@ -0,0 +1,82 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IUniswapV3PoolOwnerActions, + IUniswapV3PoolOwnerActionsInterface, +} from "../../../../../../@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolOwnerActions"; + +const _abi = [ + { + inputs: [ + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint128", + name: "amount0Requested", + type: "uint128", + }, + { + internalType: "uint128", + name: "amount1Requested", + type: "uint128", + }, + ], + name: "collectProtocol", + outputs: [ + { + internalType: "uint128", + name: "amount0", + type: "uint128", + }, + { + internalType: "uint128", + name: "amount1", + type: "uint128", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint8", + name: "feeProtocol0", + type: "uint8", + }, + { + internalType: "uint8", + name: "feeProtocol1", + type: "uint8", + }, + ], + name: "setFeeProtocol", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, +] as const; + +export class IUniswapV3PoolOwnerActions__factory { + static readonly abi = _abi; + static createInterface(): IUniswapV3PoolOwnerActionsInterface { + return new utils.Interface(_abi) as IUniswapV3PoolOwnerActionsInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IUniswapV3PoolOwnerActions { + return new Contract( + address, + _abi, + signerOrProvider + ) as IUniswapV3PoolOwnerActions; + } +} diff --git a/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolState__factory.ts b/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolState__factory.ts new file mode 100644 index 00000000..8d4cc25f --- /dev/null +++ b/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolState__factory.ts @@ -0,0 +1,272 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IUniswapV3PoolState, + IUniswapV3PoolStateInterface, +} from "../../../../../../@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolState"; + +const _abi = [ + { + inputs: [], + name: "feeGrowthGlobal0X128", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "feeGrowthGlobal1X128", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "liquidity", + outputs: [ + { + internalType: "uint128", + name: "", + type: "uint128", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "index", + type: "uint256", + }, + ], + name: "observations", + outputs: [ + { + internalType: "uint32", + name: "blockTimestamp", + type: "uint32", + }, + { + internalType: "int56", + name: "tickCumulative", + type: "int56", + }, + { + internalType: "uint160", + name: "secondsPerLiquidityCumulativeX128", + type: "uint160", + }, + { + internalType: "bool", + name: "initialized", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "bytes32", + name: "key", + type: "bytes32", + }, + ], + name: "positions", + outputs: [ + { + internalType: "uint128", + name: "_liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "feeGrowthInside0LastX128", + type: "uint256", + }, + { + internalType: "uint256", + name: "feeGrowthInside1LastX128", + type: "uint256", + }, + { + internalType: "uint128", + name: "tokensOwed0", + type: "uint128", + }, + { + internalType: "uint128", + name: "tokensOwed1", + type: "uint128", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "protocolFees", + outputs: [ + { + internalType: "uint128", + name: "token0", + type: "uint128", + }, + { + internalType: "uint128", + name: "token1", + type: "uint128", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "slot0", + outputs: [ + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + { + internalType: "int24", + name: "tick", + type: "int24", + }, + { + internalType: "uint16", + name: "observationIndex", + type: "uint16", + }, + { + internalType: "uint16", + name: "observationCardinality", + type: "uint16", + }, + { + internalType: "uint16", + name: "observationCardinalityNext", + type: "uint16", + }, + { + internalType: "uint8", + name: "feeProtocol", + type: "uint8", + }, + { + internalType: "bool", + name: "unlocked", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "int16", + name: "wordPosition", + type: "int16", + }, + ], + name: "tickBitmap", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "int24", + name: "tick", + type: "int24", + }, + ], + name: "ticks", + outputs: [ + { + internalType: "uint128", + name: "liquidityGross", + type: "uint128", + }, + { + internalType: "int128", + name: "liquidityNet", + type: "int128", + }, + { + internalType: "uint256", + name: "feeGrowthOutside0X128", + type: "uint256", + }, + { + internalType: "uint256", + name: "feeGrowthOutside1X128", + type: "uint256", + }, + { + internalType: "int56", + name: "tickCumulativeOutside", + type: "int56", + }, + { + internalType: "uint160", + name: "secondsPerLiquidityOutsideX128", + type: "uint160", + }, + { + internalType: "uint32", + name: "secondsOutside", + type: "uint32", + }, + { + internalType: "bool", + name: "initialized", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, +] as const; + +export class IUniswapV3PoolState__factory { + static readonly abi = _abi; + static createInterface(): IUniswapV3PoolStateInterface { + return new utils.Interface(_abi) as IUniswapV3PoolStateInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IUniswapV3PoolState { + return new Contract(address, _abi, signerOrProvider) as IUniswapV3PoolState; + } +} diff --git a/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/pool/index.ts b/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/pool/index.ts new file mode 100644 index 00000000..eaf51874 --- /dev/null +++ b/src/typechain-typesV4/factories/@uniswap/v3-core/contracts/interfaces/pool/index.ts @@ -0,0 +1,9 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export { IUniswapV3PoolActions__factory } from "./IUniswapV3PoolActions__factory"; +export { IUniswapV3PoolDerivedState__factory } from "./IUniswapV3PoolDerivedState__factory"; +export { IUniswapV3PoolEvents__factory } from "./IUniswapV3PoolEvents__factory"; +export { IUniswapV3PoolImmutables__factory } from "./IUniswapV3PoolImmutables__factory"; +export { IUniswapV3PoolOwnerActions__factory } from "./IUniswapV3PoolOwnerActions__factory"; +export { IUniswapV3PoolState__factory } from "./IUniswapV3PoolState__factory"; diff --git a/src/typechain-typesV4/factories/@uniswap/v3-core/index.ts b/src/typechain-typesV4/factories/@uniswap/v3-core/index.ts new file mode 100644 index 00000000..6397da09 --- /dev/null +++ b/src/typechain-typesV4/factories/@uniswap/v3-core/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as contracts from "./contracts"; diff --git a/src/typechain-typesV4/factories/@uniswap/v3-periphery/contracts/index.ts b/src/typechain-typesV4/factories/@uniswap/v3-periphery/contracts/index.ts new file mode 100644 index 00000000..1d3444d5 --- /dev/null +++ b/src/typechain-typesV4/factories/@uniswap/v3-periphery/contracts/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as interfaces from "./interfaces"; diff --git a/src/typechain-typesV4/factories/@uniswap/v3-periphery/contracts/interfaces/IERC721Permit__factory.ts b/src/typechain-typesV4/factories/@uniswap/v3-periphery/contracts/interfaces/IERC721Permit__factory.ts new file mode 100644 index 00000000..0b357e2f --- /dev/null +++ b/src/typechain-typesV4/factories/@uniswap/v3-periphery/contracts/interfaces/IERC721Permit__factory.ts @@ -0,0 +1,375 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IERC721Permit, + IERC721PermitInterface, +} from "../../../../../@uniswap/v3-periphery/contracts/interfaces/IERC721Permit"; + +const _abi = [ + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "approved", + type: "address", + }, + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Approval", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "operator", + type: "address", + }, + { + indexed: false, + internalType: "bool", + name: "approved", + type: "bool", + }, + ], + name: "ApprovalForAll", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "from", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "to", + type: "address", + }, + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Transfer", + type: "event", + }, + { + inputs: [], + name: "DOMAIN_SEPARATOR", + outputs: [ + { + internalType: "bytes32", + name: "", + type: "bytes32", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "PERMIT_TYPEHASH", + outputs: [ + { + internalType: "bytes32", + name: "", + type: "bytes32", + }, + ], + stateMutability: "pure", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "approve", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "balanceOf", + outputs: [ + { + internalType: "uint256", + name: "balance", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "getApproved", + outputs: [ + { + internalType: "address", + name: "operator", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + ], + name: "isApprovedForAll", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "ownerOf", + outputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "spender", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "permit", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "safeTransferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "safeTransferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "bool", + name: "approved", + type: "bool", + }, + ], + name: "setApprovalForAll", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "bytes4", + name: "interfaceId", + type: "bytes4", + }, + ], + name: "supportsInterface", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "transferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, +] as const; + +export class IERC721Permit__factory { + static readonly abi = _abi; + static createInterface(): IERC721PermitInterface { + return new utils.Interface(_abi) as IERC721PermitInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IERC721Permit { + return new Contract(address, _abi, signerOrProvider) as IERC721Permit; + } +} diff --git a/src/typechain-typesV4/factories/@uniswap/v3-periphery/contracts/interfaces/IPeripheryImmutableState__factory.ts b/src/typechain-typesV4/factories/@uniswap/v3-periphery/contracts/interfaces/IPeripheryImmutableState__factory.ts new file mode 100644 index 00000000..c5c54989 --- /dev/null +++ b/src/typechain-typesV4/factories/@uniswap/v3-periphery/contracts/interfaces/IPeripheryImmutableState__factory.ts @@ -0,0 +1,56 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IPeripheryImmutableState, + IPeripheryImmutableStateInterface, +} from "../../../../../@uniswap/v3-periphery/contracts/interfaces/IPeripheryImmutableState"; + +const _abi = [ + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "factory", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, +] as const; + +export class IPeripheryImmutableState__factory { + static readonly abi = _abi; + static createInterface(): IPeripheryImmutableStateInterface { + return new utils.Interface(_abi) as IPeripheryImmutableStateInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IPeripheryImmutableState { + return new Contract( + address, + _abi, + signerOrProvider + ) as IPeripheryImmutableState; + } +} diff --git a/src/typechain-typesV4/factories/@uniswap/v3-periphery/contracts/interfaces/IPeripheryPayments__factory.ts b/src/typechain-typesV4/factories/@uniswap/v3-periphery/contracts/interfaces/IPeripheryPayments__factory.ts new file mode 100644 index 00000000..659c0acd --- /dev/null +++ b/src/typechain-typesV4/factories/@uniswap/v3-periphery/contracts/interfaces/IPeripheryPayments__factory.ts @@ -0,0 +1,74 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IPeripheryPayments, + IPeripheryPaymentsInterface, +} from "../../../../../@uniswap/v3-periphery/contracts/interfaces/IPeripheryPayments"; + +const _abi = [ + { + inputs: [], + name: "refundETH", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "token", + type: "address", + }, + { + internalType: "uint256", + name: "amountMinimum", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + ], + name: "sweepToken", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "amountMinimum", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + ], + name: "unwrapWETH9", + outputs: [], + stateMutability: "payable", + type: "function", + }, +] as const; + +export class IPeripheryPayments__factory { + static readonly abi = _abi; + static createInterface(): IPeripheryPaymentsInterface { + return new utils.Interface(_abi) as IPeripheryPaymentsInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IPeripheryPayments { + return new Contract(address, _abi, signerOrProvider) as IPeripheryPayments; + } +} diff --git a/src/typechain-typesV4/factories/@uniswap/v3-periphery/contracts/interfaces/IPoolInitializer__factory.ts b/src/typechain-typesV4/factories/@uniswap/v3-periphery/contracts/interfaces/IPoolInitializer__factory.ts new file mode 100644 index 00000000..f05a8383 --- /dev/null +++ b/src/typechain-typesV4/factories/@uniswap/v3-periphery/contracts/interfaces/IPoolInitializer__factory.ts @@ -0,0 +1,60 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IPoolInitializer, + IPoolInitializerInterface, +} from "../../../../../@uniswap/v3-periphery/contracts/interfaces/IPoolInitializer"; + +const _abi = [ + { + inputs: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + name: "createAndInitializePoolIfNecessary", + outputs: [ + { + internalType: "address", + name: "pool", + type: "address", + }, + ], + stateMutability: "payable", + type: "function", + }, +] as const; + +export class IPoolInitializer__factory { + static readonly abi = _abi; + static createInterface(): IPoolInitializerInterface { + return new utils.Interface(_abi) as IPoolInitializerInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IPoolInitializer { + return new Contract(address, _abi, signerOrProvider) as IPoolInitializer; + } +} diff --git a/src/typechain-typesV4/factories/@uniswap/v3-periphery/contracts/interfaces/index.ts b/src/typechain-typesV4/factories/@uniswap/v3-periphery/contracts/interfaces/index.ts new file mode 100644 index 00000000..82df7e38 --- /dev/null +++ b/src/typechain-typesV4/factories/@uniswap/v3-periphery/contracts/interfaces/index.ts @@ -0,0 +1,7 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export { IERC721Permit__factory } from "./IERC721Permit__factory"; +export { IPeripheryImmutableState__factory } from "./IPeripheryImmutableState__factory"; +export { IPeripheryPayments__factory } from "./IPeripheryPayments__factory"; +export { IPoolInitializer__factory } from "./IPoolInitializer__factory"; diff --git a/src/typechain-typesV4/factories/@uniswap/v3-periphery/index.ts b/src/typechain-typesV4/factories/@uniswap/v3-periphery/index.ts new file mode 100644 index 00000000..6397da09 --- /dev/null +++ b/src/typechain-typesV4/factories/@uniswap/v3-periphery/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as contracts from "./contracts"; diff --git a/src/typechain-typesV4/factories/index.ts b/src/typechain-typesV4/factories/index.ts new file mode 100644 index 00000000..1fa01232 --- /dev/null +++ b/src/typechain-typesV4/factories/index.ts @@ -0,0 +1,9 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as apertureFinance from "./@aperture_finance"; +export * as openzeppelin from "./@openzeppelin"; +export * as pancakeswap from "./@pancakeswap"; +export * as uniswap from "./@uniswap"; +export * as solady from "./solady"; +export * as src from "./src"; diff --git a/src/typechain-typesV4/factories/solady/index.ts b/src/typechain-typesV4/factories/solady/index.ts new file mode 100644 index 00000000..ba4b1074 --- /dev/null +++ b/src/typechain-typesV4/factories/solady/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as src from "./src"; diff --git a/src/typechain-typesV4/factories/solady/src/index.ts b/src/typechain-typesV4/factories/solady/src/index.ts new file mode 100644 index 00000000..1d22927b --- /dev/null +++ b/src/typechain-typesV4/factories/solady/src/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as tokens from "./tokens"; +export * as utils from "./utils"; diff --git a/src/typechain-typesV4/factories/solady/src/tokens/ERC20__factory.ts b/src/typechain-typesV4/factories/solady/src/tokens/ERC20__factory.ts new file mode 100644 index 00000000..9f2459d9 --- /dev/null +++ b/src/typechain-typesV4/factories/solady/src/tokens/ERC20__factory.ts @@ -0,0 +1,355 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + ERC20, + ERC20Interface, +} from "../../../../solady/src/tokens/ERC20"; + +const _abi = [ + { + inputs: [], + name: "AllowanceOverflow", + type: "error", + }, + { + inputs: [], + name: "AllowanceUnderflow", + type: "error", + }, + { + inputs: [], + name: "InsufficientAllowance", + type: "error", + }, + { + inputs: [], + name: "InsufficientBalance", + type: "error", + }, + { + inputs: [], + name: "InvalidPermit", + type: "error", + }, + { + inputs: [], + name: "PermitExpired", + type: "error", + }, + { + inputs: [], + name: "TotalSupplyOverflow", + type: "error", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "spender", + type: "address", + }, + { + indexed: false, + internalType: "uint256", + name: "amount", + type: "uint256", + }, + ], + name: "Approval", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "from", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "to", + type: "address", + }, + { + indexed: false, + internalType: "uint256", + name: "amount", + type: "uint256", + }, + ], + name: "Transfer", + type: "event", + }, + { + inputs: [], + name: "DOMAIN_SEPARATOR", + outputs: [ + { + internalType: "bytes32", + name: "result", + type: "bytes32", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + { + internalType: "address", + name: "spender", + type: "address", + }, + ], + name: "allowance", + outputs: [ + { + internalType: "uint256", + name: "result", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "spender", + type: "address", + }, + { + internalType: "uint256", + name: "amount", + type: "uint256", + }, + ], + name: "approve", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "balanceOf", + outputs: [ + { + internalType: "uint256", + name: "result", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "decimals", + outputs: [ + { + internalType: "uint8", + name: "", + type: "uint8", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "name", + outputs: [ + { + internalType: "string", + name: "", + type: "string", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "nonces", + outputs: [ + { + internalType: "uint256", + name: "result", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + { + internalType: "address", + name: "spender", + type: "address", + }, + { + internalType: "uint256", + name: "value", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "permit", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [], + name: "symbol", + outputs: [ + { + internalType: "string", + name: "", + type: "string", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "totalSupply", + outputs: [ + { + internalType: "uint256", + name: "result", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "amount", + type: "uint256", + }, + ], + name: "transfer", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "amount", + type: "uint256", + }, + ], + name: "transferFrom", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, +] as const; + +export class ERC20__factory { + static readonly abi = _abi; + static createInterface(): ERC20Interface { + return new utils.Interface(_abi) as ERC20Interface; + } + static connect(address: string, signerOrProvider: Signer | Provider): ERC20 { + return new Contract(address, _abi, signerOrProvider) as ERC20; + } +} diff --git a/src/typechain-typesV4/factories/solady/src/tokens/WETH__factory.ts b/src/typechain-typesV4/factories/solady/src/tokens/WETH__factory.ts new file mode 100644 index 00000000..0c99ad3b --- /dev/null +++ b/src/typechain-typesV4/factories/solady/src/tokens/WETH__factory.ts @@ -0,0 +1,415 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import { Signer, utils, Contract, ContractFactory, Overrides } from "ethers"; +import type { Provider, TransactionRequest } from "@ethersproject/providers"; +import type { WETH, WETHInterface } from "../../../../solady/src/tokens/WETH"; + +const _abi = [ + { + inputs: [], + name: "AllowanceOverflow", + type: "error", + }, + { + inputs: [], + name: "AllowanceUnderflow", + type: "error", + }, + { + inputs: [], + name: "ETHTransferFailed", + type: "error", + }, + { + inputs: [], + name: "InsufficientAllowance", + type: "error", + }, + { + inputs: [], + name: "InsufficientBalance", + type: "error", + }, + { + inputs: [], + name: "InvalidPermit", + type: "error", + }, + { + inputs: [], + name: "PermitExpired", + type: "error", + }, + { + inputs: [], + name: "TotalSupplyOverflow", + type: "error", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "owner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "spender", + type: "address", + }, + { + indexed: false, + internalType: "uint256", + name: "amount", + type: "uint256", + }, + ], + name: "Approval", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "from", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "to", + type: "address", + }, + { + indexed: false, + internalType: "uint256", + name: "amount", + type: "uint256", + }, + ], + name: "Transfer", + type: "event", + }, + { + inputs: [], + name: "DOMAIN_SEPARATOR", + outputs: [ + { + internalType: "bytes32", + name: "result", + type: "bytes32", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + { + internalType: "address", + name: "spender", + type: "address", + }, + ], + name: "allowance", + outputs: [ + { + internalType: "uint256", + name: "result", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "spender", + type: "address", + }, + { + internalType: "uint256", + name: "amount", + type: "uint256", + }, + ], + name: "approve", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "balanceOf", + outputs: [ + { + internalType: "uint256", + name: "result", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "decimals", + outputs: [ + { + internalType: "uint8", + name: "", + type: "uint8", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "deposit", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [], + name: "name", + outputs: [ + { + internalType: "string", + name: "", + type: "string", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "nonces", + outputs: [ + { + internalType: "uint256", + name: "result", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + { + internalType: "address", + name: "spender", + type: "address", + }, + { + internalType: "uint256", + name: "value", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "permit", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [], + name: "symbol", + outputs: [ + { + internalType: "string", + name: "", + type: "string", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "totalSupply", + outputs: [ + { + internalType: "uint256", + name: "result", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "amount", + type: "uint256", + }, + ], + name: "transfer", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "from", + type: "address", + }, + { + internalType: "address", + name: "to", + type: "address", + }, + { + internalType: "uint256", + name: "amount", + type: "uint256", + }, + ], + name: "transferFrom", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "amount", + type: "uint256", + }, + ], + name: "withdraw", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + stateMutability: "payable", + type: "receive", + }, +] as const; + +const _bytecode = + "0x60808060405234601557610aae908161001b8239f35b600080fdfe60806040526004361015610023575b361561001957600080fd5b610021610a29565b005b60003560e01c806306fdde03146108ef578063095ea7b31461086357806318160ddd1461081f57806323b872dd146107165780632e1a7d4d14610663578063313ce567146106295780633644e5151461055e57806370a082311461050d5780637ecebe00146104bc57806395d89b4114610402578063a9059cbb14610352578063d0e30db014610320578063d505accf146101245763dd62ed3e0361000e573461011f5760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261011f576100f96109bf565b6101016109e2565b602052637f5e9f20600c5260005260206034600c2054604051908152f35b600080fd5b3461011f5760e07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261011f5761015b6109bf565b6101636109e2565b6084359160643560443560ff8516850361011f5761017f610a05565b60208101907f57726170706564204574686572000000000000000000000000000000000000008252519020908242116103125773ffffffffffffffffffffffffffffffffffffffff80604051951695169565383775081901600e528560005260c06020600c20958654957f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f8252602082019586528660408301967fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc688528b6060850198468a528c608087019330855260a08820602e527f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c9885252528688525260a082015220604e526042602c2060005260ff1660205260a43560405260c4356060526020806080600060015afa93853d5103610304577f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259460209401905585777f5e9f200000000000000000000000000000000000000000176040526034602c2055a3005b63ddafbaef6000526004601cfd5b631a15a3cc6000526004601cfd5b60007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261011f57610021610a29565b3461011f5760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261011f576103896109bf565b602435906387a211a2600c52336000526020600c2080548084116103f45783900390556000526020600c20818154019055602052600c5160601c337fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef602080a3602060405160018152f35b63f4d678b86000526004601cfd5b3461011f5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261011f57604051604081019080821067ffffffffffffffff83111761048d5761048991604052600481527f5745544800000000000000000000000000000000000000000000000000000000602082015260405191829182610957565b0390f35b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b3461011f5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261011f576104f36109bf565b6338377508600c52600052602080600c2054604051908152f35b3461011f5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261011f576105446109bf565b6387a211a2600c52600052602080600c2054604051908152f35b3461011f5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261011f57602060a0610599610a05565b828101907f57726170706564204574686572000000000000000000000000000000000000008252519020604051907f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f8252838201527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc6604082015246606082015230608082015220604051908152f35b3461011f5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261011f57602060405160128152f35b3461011f5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261011f576004356387a211a2600c52336000526020600c20908154918282116103f45781600093039055806805345cdf77eb68f44c54036805345cdf77eb68f44c5580825281337fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef602083a381803892335af11561070857005b63b12d13eb6000526004601cfd5b3461011f5760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261011f5761074d6109bf565b6107556109e2565b604435908260601b33602052637f5e9f208117600c526034600c2090815491600183016107fa575b506387a211a2915017600c526020600c2080548084116103f45783900390556000526020600c2081815401905560205273ffffffffffffffffffffffffffffffffffffffff600c5160601c91167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef602080a3602060405160018152f35b82851161081157846387a211a2930390558561077d565b6313be252b6000526004601cfd5b3461011f5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261011f5760206805345cdf77eb68f44c54604051908152f35b3461011f5760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261011f5761089a6109bf565b60243590602052637f5e9f20600c5233600052806034600c2055600052602c5160601c337f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560206000a3602060405160018152f35b3461011f5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261011f57610489610929610a05565b7f57726170706564204574686572000000000000000000000000000000000000006020820152604051918291825b9190916020815282519283602083015260005b8481106109a95750507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8460006040809697860101520116010190565b806020809284010151604082860101520161096a565b6004359073ffffffffffffffffffffffffffffffffffffffff8216820361011f57565b6024359073ffffffffffffffffffffffffffffffffffffffff8216820361011f57565b604051906040820182811067ffffffffffffffff82111761048d57604052600d8252565b6805345cdf77eb68f44c54348101908110610a93576805345cdf77eb68f44c556387a211a2600c52336000526020600c2034815401905534602052600c5160601c60007fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef602080a3565b63e5cfe9576000526004601cfdfea164736f6c634300081a000a"; + +type WETHConstructorParams = + | [signer?: Signer] + | ConstructorParameters; + +const isSuperArgs = ( + xs: WETHConstructorParams +): xs is ConstructorParameters => xs.length > 1; + +export class WETH__factory extends ContractFactory { + constructor(...args: WETHConstructorParams) { + if (isSuperArgs(args)) { + super(...args); + } else { + super(_abi, _bytecode, args[0]); + } + } + + override deploy(overrides?: Overrides & { from?: string }): Promise { + return super.deploy(overrides || {}) as Promise; + } + override getDeployTransaction( + overrides?: Overrides & { from?: string } + ): TransactionRequest { + return super.getDeployTransaction(overrides || {}); + } + override attach(address: string): WETH { + return super.attach(address) as WETH; + } + override connect(signer: Signer): WETH__factory { + return super.connect(signer) as WETH__factory; + } + + static readonly bytecode = _bytecode; + static readonly abi = _abi; + static createInterface(): WETHInterface { + return new utils.Interface(_abi) as WETHInterface; + } + static connect(address: string, signerOrProvider: Signer | Provider): WETH { + return new Contract(address, _abi, signerOrProvider) as WETH; + } +} diff --git a/src/typechain-typesV4/factories/solady/src/tokens/index.ts b/src/typechain-typesV4/factories/solady/src/tokens/index.ts new file mode 100644 index 00000000..52a662d5 --- /dev/null +++ b/src/typechain-typesV4/factories/solady/src/tokens/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export { ERC20__factory } from "./ERC20__factory"; +export { WETH__factory } from "./WETH__factory"; diff --git a/src/typechain-typesV4/factories/solady/src/utils/FixedPointMathLib__factory.ts b/src/typechain-typesV4/factories/solady/src/utils/FixedPointMathLib__factory.ts new file mode 100644 index 00000000..b4766d99 --- /dev/null +++ b/src/typechain-typesV4/factories/solady/src/utils/FixedPointMathLib__factory.ts @@ -0,0 +1,127 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import { Signer, utils, Contract, ContractFactory, Overrides } from "ethers"; +import type { Provider, TransactionRequest } from "@ethersproject/providers"; +import type { + FixedPointMathLib, + FixedPointMathLibInterface, +} from "../../../../solady/src/utils/FixedPointMathLib"; + +const _abi = [ + { + inputs: [], + name: "DivFailed", + type: "error", + }, + { + inputs: [], + name: "DivWadFailed", + type: "error", + }, + { + inputs: [], + name: "ExpOverflow", + type: "error", + }, + { + inputs: [], + name: "FactorialOverflow", + type: "error", + }, + { + inputs: [], + name: "FullMulDivFailed", + type: "error", + }, + { + inputs: [], + name: "LnWadUndefined", + type: "error", + }, + { + inputs: [], + name: "MantissaOverflow", + type: "error", + }, + { + inputs: [], + name: "MulDivFailed", + type: "error", + }, + { + inputs: [], + name: "MulWadFailed", + type: "error", + }, + { + inputs: [], + name: "OutOfDomain", + type: "error", + }, + { + inputs: [], + name: "RPowOverflow", + type: "error", + }, + { + inputs: [], + name: "SDivWadFailed", + type: "error", + }, + { + inputs: [], + name: "SMulWadFailed", + type: "error", + }, +] as const; + +const _bytecode = + "0x6080806040523460175760119081601d823930815050f35b600080fdfe600080fdfea164736f6c634300081a000a"; + +type FixedPointMathLibConstructorParams = + | [signer?: Signer] + | ConstructorParameters; + +const isSuperArgs = ( + xs: FixedPointMathLibConstructorParams +): xs is ConstructorParameters => xs.length > 1; + +export class FixedPointMathLib__factory extends ContractFactory { + constructor(...args: FixedPointMathLibConstructorParams) { + if (isSuperArgs(args)) { + super(...args); + } else { + super(_abi, _bytecode, args[0]); + } + } + + override deploy( + overrides?: Overrides & { from?: string } + ): Promise { + return super.deploy(overrides || {}) as Promise; + } + override getDeployTransaction( + overrides?: Overrides & { from?: string } + ): TransactionRequest { + return super.getDeployTransaction(overrides || {}); + } + override attach(address: string): FixedPointMathLib { + return super.attach(address) as FixedPointMathLib; + } + override connect(signer: Signer): FixedPointMathLib__factory { + return super.connect(signer) as FixedPointMathLib__factory; + } + + static readonly bytecode = _bytecode; + static readonly abi = _abi; + static createInterface(): FixedPointMathLibInterface { + return new utils.Interface(_abi) as FixedPointMathLibInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): FixedPointMathLib { + return new Contract(address, _abi, signerOrProvider) as FixedPointMathLib; + } +} diff --git a/src/typechain-typesV4/factories/solady/src/utils/SafeTransferLib__factory.ts b/src/typechain-typesV4/factories/solady/src/utils/SafeTransferLib__factory.ts new file mode 100644 index 00000000..c3e1e376 --- /dev/null +++ b/src/typechain-typesV4/factories/solady/src/utils/SafeTransferLib__factory.ts @@ -0,0 +1,92 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import { Signer, utils, Contract, ContractFactory, Overrides } from "ethers"; +import type { Provider, TransactionRequest } from "@ethersproject/providers"; +import type { + SafeTransferLib, + SafeTransferLibInterface, +} from "../../../../solady/src/utils/SafeTransferLib"; + +const _abi = [ + { + inputs: [], + name: "ApproveFailed", + type: "error", + }, + { + inputs: [], + name: "ETHTransferFailed", + type: "error", + }, + { + inputs: [], + name: "Permit2AmountOverflow", + type: "error", + }, + { + inputs: [], + name: "Permit2Failed", + type: "error", + }, + { + inputs: [], + name: "TransferFailed", + type: "error", + }, + { + inputs: [], + name: "TransferFromFailed", + type: "error", + }, +] as const; + +const _bytecode = + "0x6080806040523460175760119081601d823930815050f35b600080fdfe600080fdfea164736f6c634300081a000a"; + +type SafeTransferLibConstructorParams = + | [signer?: Signer] + | ConstructorParameters; + +const isSuperArgs = ( + xs: SafeTransferLibConstructorParams +): xs is ConstructorParameters => xs.length > 1; + +export class SafeTransferLib__factory extends ContractFactory { + constructor(...args: SafeTransferLibConstructorParams) { + if (isSuperArgs(args)) { + super(...args); + } else { + super(_abi, _bytecode, args[0]); + } + } + + override deploy( + overrides?: Overrides & { from?: string } + ): Promise { + return super.deploy(overrides || {}) as Promise; + } + override getDeployTransaction( + overrides?: Overrides & { from?: string } + ): TransactionRequest { + return super.getDeployTransaction(overrides || {}); + } + override attach(address: string): SafeTransferLib { + return super.attach(address) as SafeTransferLib; + } + override connect(signer: Signer): SafeTransferLib__factory { + return super.connect(signer) as SafeTransferLib__factory; + } + + static readonly bytecode = _bytecode; + static readonly abi = _abi; + static createInterface(): SafeTransferLibInterface { + return new utils.Interface(_abi) as SafeTransferLibInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): SafeTransferLib { + return new Contract(address, _abi, signerOrProvider) as SafeTransferLib; + } +} diff --git a/src/typechain-typesV4/factories/solady/src/utils/index.ts b/src/typechain-typesV4/factories/solady/src/utils/index.ts new file mode 100644 index 00000000..febb77c6 --- /dev/null +++ b/src/typechain-typesV4/factories/solady/src/utils/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export { FixedPointMathLib__factory } from "./FixedPointMathLib__factory"; +export { SafeTransferLib__factory } from "./SafeTransferLib__factory"; diff --git a/src/typechain-typesV4/factories/src/PCSV3Automan__factory.ts b/src/typechain-typesV4/factories/src/PCSV3Automan__factory.ts new file mode 100644 index 00000000..7dc8225b --- /dev/null +++ b/src/typechain-typesV4/factories/src/PCSV3Automan__factory.ts @@ -0,0 +1,1845 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import { + Signer, + utils, + Contract, + ContractFactory, + PayableOverrides, +} from "ethers"; +import type { Provider, TransactionRequest } from "@ethersproject/providers"; +import type { + PCSV3Automan, + PCSV3AutomanInterface, +} from "../../src/PCSV3Automan"; + +const _abi = [ + { + inputs: [ + { + internalType: "contract IPCSV3NonfungiblePositionManager", + name: "nonfungiblePositionManager", + type: "address", + }, + { + internalType: "address", + name: "owner_", + type: "address", + }, + ], + stateMutability: "payable", + type: "constructor", + }, + { + inputs: [], + name: "FeeLimitExceeded", + type: "error", + }, + { + inputs: [], + name: "InsufficientAmount", + type: "error", + }, + { + inputs: [], + name: "InvalidRouter", + type: "error", + }, + { + inputs: [], + name: "Invalid_Tick_Range", + type: "error", + }, + { + inputs: [], + name: "MismatchETH", + type: "error", + }, + { + inputs: [], + name: "NotAllowlistedRouter", + type: "error", + }, + { + inputs: [], + name: "NotApproved", + type: "error", + }, + { + inputs: [], + name: "NotWETH9", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "OwnableInvalidOwner", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "account", + type: "address", + }, + ], + name: "OwnableUnauthorizedAccount", + type: "error", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "controllers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "ControllersSet", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "DecreaseLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address", + name: "feeCollector", + type: "address", + }, + { + indexed: false, + internalType: "uint96", + name: "feeLimitPips", + type: "uint96", + }, + ], + name: "FeeConfigSet", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "IncreaseLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Mint", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "previousOwner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "OwnershipTransferred", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Rebalance", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Reinvest", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "RemoveLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "SetAllowlistedRouters", + type: "event", + }, + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + ], + name: "decreaseLiquidity", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "decreaseLiquidity", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenOut", + type: "address", + }, + { + internalType: "uint256", + name: "tokenOutMin", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + ], + name: "decreaseLiquidityToTokenOut", + outputs: [ + { + internalType: "uint256", + name: "tokenOutAmount", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenOut", + type: "address", + }, + { + internalType: "uint256", + name: "tokenOutMin", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "decreaseLiquidityToTokenOut", + outputs: [ + { + internalType: "uint256", + name: "tokenOutAmount", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [], + name: "deployer", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "feeConfig", + outputs: [ + { + internalType: "address", + name: "feeCollector", + type: "address", + }, + { + internalType: "uint96", + name: "feeLimitPips", + type: "uint96", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "V3PoolCallee", + name: "pool", + type: "address", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + ], + name: "getOptimalSwap", + outputs: [ + { + internalType: "uint256", + name: "amountIn", + type: "uint256", + }, + { + internalType: "uint256", + name: "amountOut", + type: "uint256", + }, + { + internalType: "bool", + name: "zeroForOne", + type: "bool", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + ], + name: "increaseLiquidity", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + ], + name: "increaseLiquidityOptimal", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenIn", + type: "address", + }, + { + internalType: "uint256", + name: "tokenInFeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + ], + name: "increaseLiquidityWithTokenIn", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + name: "isAllowListedRouter", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + name: "isController", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + ], + name: "mint", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + ], + name: "mintOptimal", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenIn", + type: "address", + }, + { + internalType: "uint256", + name: "tokenInFeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + ], + name: "mintWithTokenIn", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "owner", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "int256", + name: "amount0Delta", + type: "int256", + }, + { + internalType: "int256", + name: "amount1Delta", + type: "int256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "pancakeV3SwapCallback", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + ], + name: "rebalance", + outputs: [ + { + internalType: "uint256", + name: "newTokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "rebalance", + outputs: [ + { + internalType: "uint256", + name: "newTokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + ], + name: "reinvest", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "reinvest", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [], + name: "renounceOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setAllowlistedRouters", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "controllers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setControllers", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "feeCollector", + type: "address", + }, + { + internalType: "uint96", + name: "feeLimitPips", + type: "uint96", + }, + ], + internalType: "struct IAutomanCommon.FeeConfig", + name: "_feeConfig", + type: "tuple", + }, + ], + name: "setFeeConfig", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "transferOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + stateMutability: "payable", + type: "receive", + }, +] as const; + +const _bytecode = + "0x60e0806040526040816158ba803803809161001a8285610294565b8339810103126102245780516001600160a01b0381169190829003610224576001600160a01b039061004e906020016102cd565b16801561027e57600080546001600160a01b031981168317825560405192916001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09080a360808290526312a9293f60e21b8152602081600481855afa9081156102315760009161023d575b506001600160a01b031660a052604051631abe729160e31b815290602090829060049082905afa908115610231576000916101f2575b5060c0526040516155d890816102e28239608051818181610afb0152818161117e015281816111dd0152818161132401528181611680015281816116bb015281816116f2015281816126330152818161268c01528181612a2c01528181612bad01528181612caa01528181612d5201528181612df101528181612e6401528181612ea50152818161304d0152818161329c015281816133b1015281816146c201528181614938015261499f015260a0518181816030015281816118070152818161240401528181613595015261365e015260c05181818161040001528181611a52015281816126be0152818161371f01526138380152f35b90506020813d602011610229575b8161020d60209383610294565b810103126102245761021e906102cd565b386100fa565b600080fd5b3d9150610200565b6040513d6000823e3d90fd5b90506020813d602011610276575b8161025860209383610294565b810103126102245760049161026e6020926102cd565b9150916100c4565b3d915061024b565b631e4fbdf760e01b600052600060045260246000fd5b601f909101601f19168101906001600160401b038211908210176102b757604052565b634e487b7160e01b600052604160045260246000fd5b51906001600160a01b03821682036102245756fe60a06040526004361015610082575b361561001957600080fd5b73ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016330361005857005b7f2f1ca35a0000000000000000000000000000000000000000000000000000000060005260046000fd5b60003560e01c80631376f4c414611d125780631e5eb1d014611cb5578063218b625f14611c63578063219f5d1714611b9057806322adac0514611aed57806323a69e75146119d85780632c45e5a01461190657806332279096146118955780634095c6461461182b5780634aa4a4fc146117bc5780634bf193901461145257806370f3c180146113e4578063715018a6146113485780637f1e9ef6146112d957806386c64c8614610ea05780638831645614610dc05780638ba1e27314610d235780638da5cb5b14610cd157806391f6e9b214610a5b57806398bbfdc11461095d57806399642fb1146107c1578063a5fd1e3c14610707578063af3ed58614610610578063b429afeb146105a6578063c747e2b314610424578063d5f39488146103b5578063f2fde38b146102c35763fc0e92cc0361000e57346102be576102607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be576101f436611f26565b610164356101c43567ffffffffffffffff81116102be57610219903690600401612045565b90610204359260ff841684036102be576102ba946102516102609561023d84612b67565b610244359061022435906101e435866146bf565b6101a435916101843591613316565b90604094929451948486957f811d4760f1a92875eb76dbd3dc2359544b2f6a000ba5b78784c0b105b3469bd0600080a285526fffffffffffffffffffffffffffffffff166020850152604084015260608301526080820190565b0390f35b600080fd5b346102be5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be5773ffffffffffffffffffffffffffffffffffffffff61030f611f03565b6103176132c7565b1680156103865773ffffffffffffffffffffffffffffffffffffffff600054827fffffffffffffffffffffffff0000000000000000000000000000000000000000821617600055167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0600080a3005b7f1e4fbdf700000000000000000000000000000000000000000000000000000000600052600060045260246000fd5b346102be5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be57602060405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152f35b346102be5760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be57600061045d6132c7565b670de0b6b3a76400006bffffffffffffffffffffffff61047b6123cf565b1610156105a35773ffffffffffffffffffffffffffffffffffffffff61049f612299565b16156105a35773ffffffffffffffffffffffffffffffffffffffff6104c2612299565b167fffffffffffffffffffffffff000000000000000000000000000000000000000060025416176002556104f46123cf565b73ffffffffffffffffffffffffffffffffffffffff7fffffffffffffffffffffffff00000000000000000000000000000000000000006002549260a01b169116176002557f42200c2a55e71251cd849a86c7ece1a42ddabecbb489150a136f6c0d239c7a5c610561612299565b6105696123cf565b6040805173ffffffffffffffffffffffffffffffffffffffff9390931683526bffffffffffffffffffffffff91909116602083015290a180f35b80fd5b346102be5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be5773ffffffffffffffffffffffffffffffffffffffff6105f2611f03565b166000526003602052602060ff604060002054166040519015158152f35b346102be576101a07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be576106493661210a565b6101043567ffffffffffffffff81116102be5761066a903690600401612045565b9091610144359160ff831683036102be576102ba93826106a66106b394519561069287612b67565b6101843590610164359061012435896146bf565b60e4359060c435906139c9565b906040949294519485947fc13e24d2b0a3bacd5d1a7c514125a1e27323abf7c86f6d36597f8752bbd7eed7600080a26fffffffffffffffffffffffffffffffff168452602084015260408301526060820190565b346102be576101807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be5761074036612073565b6107486120eb565b90610124359060ff821682036102be576040928161078261078f93519461076e86612b67565b6101643590610144359061010435886146bf565b60c4359060a43590612c2b565b908351927f269a3942fe0284ff30ff93f97529fba299f93b8b85221afab5686fdab8bfa84b600080a282526020820152f35b6101207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be576107f53661210a565b60c43567ffffffffffffffff81116102be576108e36108aa6108d98460406108246102ba963690600401612045565b60e49491943594610104356108b361083c8751612dae565b9173ffffffffffffffffffffffffffffffffffffffff83511699896108a1838d9c73ffffffffffffffffffffffffffffffffffffffff6020890151169e8f9d602081019d8e9182518061094b575b50019e8f91825180610939575b5051915192612561565b50508851612211565b87528751612211565b86526108bd61239f565b50606081015160020b608082015160020b8651918851936125d5565b9092525284612ea1565b9092919351926040519485947fe93a38a2f007635b024bb3a896c7021e73edc7146c413a63e6b69c337304c698600080a26fffffffffffffffffffffffffffffffff168452602084015260408301526060820190565b610945903033856123ea565b38610897565b610957903033876123ea565b3861088a565b346102be576101c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be5761099636612073565b61099e611ee0565b60e43567ffffffffffffffff81116102be576109be903690600401612045565b6101049291923567ffffffffffffffff81116102be576109e2903690600401612045565b906109eb6120fa565b92610164359560ff871687036102be5787610a2e96610a2560209a5199610a118b612b67565b6101a435906101843590610144358d6146bf565b60c43591612fbe565b604051917f269a3942fe0284ff30ff93f97529fba299f93b8b85221afab5686fdab8bfa84b600080a28152f35b610a64366121a1565b610a6f9391936132c7565b8083036102be5760005b838110610ab85750610ab3907fe4d045717648b4a964b22e91953fd95d48e089e38c87021016e48ddd32387eee94604051948594856122dd565b0390a1005b610acb610ac682868661224d565b6122bc565b90610adf610ada82858961224d565b61228c565b15610c815773ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169173ffffffffffffffffffffffffffffffffffffffff811692808414610c235760009182918260405160208101927f095ea7b3000000000000000000000000000000000000000000000000000000008452602482015281604482015260448152610b86606482611e9f565b51925af13d15610c7c573d67ffffffffffffffff8111610c4d5760405190610bd660207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8401160183611e9f565b8152600060203d92013e5b610c2357600191600052816020526040600020827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008254161790555b01610a79565b7f466d7fef0000000000000000000000000000000000000000000000000000000060005260046000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b610be1565b73ffffffffffffffffffffffffffffffffffffffff600192166000528160205260406000207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008154169055610c1d565b346102be5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be57602073ffffffffffffffffffffffffffffffffffffffff60005416604051908152f35b346102be5760a07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be57610d5a611f03565b602435908160020b82036102be576044358060020b81036102be5760809273ffffffffffffffffffffffffffffffffffffffff92610d9f926084359260643592613a4c565b92919290845190604051948552602085015215156040840152166060820152f35b6101607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be576102ba610e46610dfa36611f26565b610e4173ffffffffffffffffffffffffffffffffffffffff82511673ffffffffffffffffffffffffffffffffffffffff60208401511660a08401519060c085015192612e29565b6129f9565b90604094929451948486957f07883703ed0e86588a40d76551c92f8a4b329e3bf19765e0e6749473c1a84665600080a285526fffffffffffffffffffffffffffffffff166020850152604084015260608301526080820190565b6101e07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be57610ed436611f26565b6101643573ffffffffffffffffffffffffffffffffffffffff8116918282036102be5761018435906101a43567ffffffffffffffff81116102be57610f1d903690600401612045565b6101c49591953567ffffffffffffffff81116102be576110bf966102ba95611091610f4d87943690600401612045565b6000969196906000928c60a0890196610f7781610f7260c08b519d019c8d5190612392565b612392565b610f8a82151591826112c8575b8361346b565b73ffffffffffffffffffffffffffffffffffffffff60025416906112b7575b505050610fb461239f565b9662ffffff60408d01511660408901528d73ffffffffffffffffffffffffffffffffffffffff8d5116908c808303611271575b505050505060208a019773ffffffffffffffffffffffffffffffffffffffff8951168d8b820361122c575b505050508773ffffffffffffffffffffffffffffffffffffffff8a51161461121c575b8773ffffffffffffffffffffffffffffffffffffffff8851161461120a575b73ffffffffffffffffffffffffffffffffffffffff808a511697511696602086019788528552606089015160020b60808a015160020b9086613824565b918192855252806111ab575b5050518061114c575b50506110b1826129f9565b9492969197909330906137e8565b908161111f575b505050604051948486957f07883703ed0e86588a40d76551c92f8a4b329e3bf19765e0e6749473c1a84665600080a285526fffffffffffffffffffffffffffffffff166020850152604084015260608301526080820190565b73ffffffffffffffffffffffffffffffffffffffff610120611144940151169061357e565b8580806110c6565b73ffffffffffffffffffffffffffffffffffffffff6111a492511673ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001690613950565b85806110a6565b73ffffffffffffffffffffffffffffffffffffffff61120392511673ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001690613950565b878061109d565b905061121630886137e8565b90611054565b5061122730886137e8565b611035565b61126794955073ffffffffffffffffffffffffffffffffffffffff90828d10928284838318028093181660208c0152181688528851886136f4565b908c80808d611012565b6112ac959650908273ffffffffffffffffffffffffffffffffffffffff9210928284838318028093181660208d0152181689528751896136f4565b908d80808e8c610fe7565b6112c09261357e565b8c8f80610fa9565b6112d4813033886123ea565b610f84565b346102be5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be57602060405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152f35b346102be5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be5761137f6132c7565b600073ffffffffffffffffffffffffffffffffffffffff81547fffffffffffffffffffffffff000000000000000000000000000000000000000081168355167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08280a3005b346102be576101207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be5761141d3661210a565b610104359067ffffffffffffffff82116102be576106b36114456102ba933690600401612045565b908351936106a685612b67565b6101407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be576114863661210a565b60c4359073ffffffffffffffffffffffffffffffffffffffff8216908183036102be5760e435926101043567ffffffffffffffff81116102be576114ce903690600401612045565b6101249391933567ffffffffffffffff81116102be5773ffffffffffffffffffffffffffffffffffffffff8061160f938861161b9a6102ba99886115178b983690600401612045565b6000959160009261156460208601958d87519961153e81610f72604086019d8e5190612392565b61155082151591826112c8578361346b565b8e60025416906117ab575b50505051612dae565b9861156d61239f565b9662ffffff60408c01511660408901528d8c8c51169084820361177a575b50505050602089019b8a8d51169180830361174a575b9350505050808888511614611731575b90816115ec92898c51161461171f575b508787511695888b511696602086019788528552606088015160020b608089015160020b9086613824565b918192855252806116e8575b505051806116b1575b505051169151169083612ea1565b939196909530906137e8565b80611675575b505051926040519485947fe93a38a2f007635b024bb3a896c7021e73edc7146c413a63e6b69c337304c698600080a26fffffffffffffffffffffffffffffffff168452602084015260408301526060820190565b6116aa916116a484517f000000000000000000000000000000000000000000000000000000000000000061398d565b9061357e565b8580611621565b836116e1925116847f00000000000000000000000000000000000000000000000000000000000000001690613950565b8a80611601565b85611718925116867f00000000000000000000000000000000000000000000000000000000000000001690613950565b8c806115f8565b61172b915030906137e8565b8e6115c1565b94506115ec9061174130876137e8565b959091506115b1565b611770955090828c9210928284838318028093181660208a0152181686528651866136f4565b8f808f8e816115a1565b849b508d90826117a19610928284838318028093181660208d0152181689528751896136f4565b963880808e61158b565b6117b49261357e565b8d388061155b565b346102be5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be57602060405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152f35b346102be5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be5773ffffffffffffffffffffffffffffffffffffffff611877611f03565b166000526001602052602060ff604060002054166040519015158152f35b346102be576101e07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be576118ce36611f26565b6101c4356101643567ffffffffffffffff82116102be576102ba926118fa610260933690600401612045565b92909161025182612b67565b346102be57611914366121a1565b929061191e6132c7565b8383036102be5760005b83811061196257507f2077016b05a05d3f12f6d9a8ca3667fbecaf29eba7083f7e2d1d70dc3709f63593610ab391604051948594856122dd565b80611973610ada600193888661224d565b73ffffffffffffffffffffffffffffffffffffffff611996610ac684898961224d565b16600052600360205260406000209060ff7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008354169115151617905501611928565b346102be5760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be5760043560443567ffffffffffffffff81116102be57611a2a903690600401612045565b5090604051606083600037606060002074ff00000000000000000000000000000000000000007f0000000000000000000000000000000000000000000000000000000000000000176000526020527f6ce8eb472fa82df5469c6ab6d485f17c3ad13c8cd7af59b3d4a8026c5ce0f7e260405273ffffffffffffffffffffffffffffffffffffffff6055600b2016906040528033036102be576000821315611ad957611ad7923090356123ea565b005b611ad79260243592503090602001356123ea565b346102be576101407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be57611b2636612073565b611b2e611ee0565b60e43567ffffffffffffffff81116102be57611b4e903690600401612045565b9092610104359167ffffffffffffffff83116102be57602094611b78610a2e943690600401612045565b929091611b836120fa565b94805197610a2589612b67565b60c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be576102ba611bc63661210a565b611c0f815191611bd583612dae565b73ffffffffffffffffffffffffffffffffffffffff6020818351169201511691611c0a60208201516040830151908585612e29565b612ea1565b906040949294519485947fe93a38a2f007635b024bb3a896c7021e73edc7146c413a63e6b69c337304c698600080a26fffffffffffffffffffffffffffffffff168452602084015260408301526060820190565b346102be576101007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be576040611c9e36612073565b61078f611ca96120eb565b82519261078284612b67565b346102be5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be576002546040805173ffffffffffffffffffffffffffffffffffffffff8316815260a09290921c602083015290f35b6101c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be57611d4636611f26565b6101643567ffffffffffffffff81116102be576102ba91611d6e610e46923690600401612045565b90611e0561018435926101a43592611d8461239f565b50611de960a0870194855180611e3c575b50611de060c0890197885180611e0e575b50611dd783828c8c73ffffffffffffffffffffffffffffffffffffffff602081845116930151168d51915192612561565b50508751612211565b86528651612211565b808652606087015160020b608088015160020b865191896125d5565b909252526129f9565b611e369073ffffffffffffffffffffffffffffffffffffffff60208d015116309033906123ea565b8c611da6565b611e619073ffffffffffffffffffffffffffffffffffffffff8a5116309033906123ea565b8a611d95565b60a0810190811067ffffffffffffffff821117610c4d57604052565b60c0810190811067ffffffffffffffff821117610c4d57604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff821117610c4d57604052565b60a4359073ffffffffffffffffffffffffffffffffffffffff821682036102be57565b6004359073ffffffffffffffffffffffffffffffffffffffff821682036102be57565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc6101609101126102be5760405190610160820182811067ffffffffffffffff821117610c4d576040528160043573ffffffffffffffffffffffffffffffffffffffff811681036102be57815260243573ffffffffffffffffffffffffffffffffffffffff811681036102be57602082015260443562ffffff811681036102be5760408201526064358060020b81036102be5760608201526084358060020b81036102be57608082015260a43560a082015260c43560c082015260e43560e0820152610104356101008201526101243573ffffffffffffffffffffffffffffffffffffffff811681036102be5761012082015261014061014435910152565b9181601f840112156102be5782359167ffffffffffffffff83116102be57602083818601950101116102be57565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc60a09101126102be57604051906120aa82611e67565b8160043581526024356fffffffffffffffffffffffffffffffff811681036102be576020820152604435604082015260643560608201526080608435910152565b60e4359081151582036102be57565b610124359081151582036102be57565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc60c09101126102be576040519061214182611e83565b6004358252602435602083015260443560408301526064356060830152608435608083015260a43560a0830152565b9181601f840112156102be5782359167ffffffffffffffff83116102be576020808501948460051b0101116102be57565b60407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc8201126102be5760043567ffffffffffffffff81116102be57816121ea91600401612170565b929092916024359067ffffffffffffffff82116102be5761220d91600401612170565b9091565b9190820391821161221e57565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b919081101561225d5760051b0190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b3580151581036102be5790565b60043573ffffffffffffffffffffffffffffffffffffffff811681036102be5790565b3573ffffffffffffffffffffffffffffffffffffffff811681036102be5790565b939293826040820160408352526060810191926000905b808210612342575050808203602091820152838252019291600091505b80821061231e5750505090565b9091928335908115158092036102be57602081600193829352019401920190612311565b90919284359073ffffffffffffffffffffffffffffffffffffffff821682036102be5773ffffffffffffffffffffffffffffffffffffffff919091168152602094850194019291600101906122f4565b9190820180921161221e57565b604051906060820182811067ffffffffffffffff821117610c4d5760405260006040838281528260208201520152565b6024356bffffffffffffffffffffffff811681036102be5790565b92919073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168073ffffffffffffffffffffffffffffffffffffffff86161480612558575b6124cc575b5073ffffffffffffffffffffffffffffffffffffffff81163003612472575061247092614818565b565b601c60006020949560649382956040519860605260405260601b602c526f23b872dd000000000000000000000000600c525af13d156001600051141716156124be576000606052604052565b637939f4246000526004601cfd5b34840361252e5760006004818681947fd0e30db00000000000000000000000000000000000000000000000000000000083525af1156102be573073ffffffffffffffffffffffffffffffffffffffff8316146125285738612448565b50505050565b7fa11a990f0000000000000000000000000000000000000000000000000000000060005260046000fd5b50341515612443565b95949193909295612572858361346b565b61257c878461346b565b73ffffffffffffffffffffffffffffffffffffffff6002541691806125c0575b5050816125ab575b5050509190565b816125b89396039561357e565b3880806125a4565b82816125ce9397039661357e565b388061259c565b969487876126b75790506125ea959650613824565b9190925b83612659575b82806125fe575050565b73ffffffffffffffffffffffffffffffffffffffff60206124709301511673ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001690613950565b6126b28473ffffffffffffffffffffffffffffffffffffffff83511673ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001690613950565b6125f4565b92909493917f00000000000000000000000000000000000000000000000000000000000000009461274f8587919060609074ff00000000000000000000000000000000000000006040519417600052206020527f6ce8eb472fa82df5469c6ab6d485f17c3ad13c8cd7af59b3d4a8026c5ce0f7e260405273ffffffffffffffffffffffffffffffffffffffff6055600b201691604052565b73ffffffffffffffffffffffffffffffffffffffff1661276e90614ad0565b509161277990614b0c565b9261278390614b0c565b73ffffffffffffffffffffffffffffffffffffffff169273ffffffffffffffffffffffffffffffffffffffff169173ffffffffffffffffffffffffffffffffffffffff16906127d194614e66565b92806020830196875173ffffffffffffffffffffffffffffffffffffffff1695845173ffffffffffffffffffffffffffffffffffffffff16908188180280911873ffffffffffffffffffffffffffffffffffffffff16963061283390896137e8565b50189161283f92615333565b30825173ffffffffffffffffffffffffffffffffffffffff1690612862916137e8565b30875173ffffffffffffffffffffffffffffffffffffffff1690612885916137e8565b6040805174ff00000000000000000000000000000000000000008717600052606086206020527f6ce8eb472fa82df5469c6ab6d485f17c3ad13c8cd7af59b3d4a8026c5ce0f7e282526055600b20915290929073ffffffffffffffffffffffffffffffffffffffff1694604282013560e81d91603f013560e81d9461296e9060609074ff00000000000000000000000000000000000000006040519417600052206020527f6ce8eb472fa82df5469c6ab6d485f17c3ad13c8cd7af59b3d4a8026c5ce0f7e260405273ffffffffffffffffffffffffffffffffffffffff6055600b201691604052565b73ffffffffffffffffffffffffffffffffffffffff169361298e94613a4c565b50506080516129a092909190876149c7565b50306129ab916137e8565b5030835173ffffffffffffffffffffffffffffffffffffffff16906129cf916137e8565b91516129f290309073ffffffffffffffffffffffffffffffffffffffff166137e8565b91926125ee565b6040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0820180516388316456825290937f000000000000000000000000000000000000000000000000000000000000000093608060006101647ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc840182895af115612b62576000519460205194604051946060519852604052600060605286938095969773ffffffffffffffffffffffffffffffffffffffff610120850151169160a08501519060c08601519184818310612b1d575b505050808210612ae2575b5050505050565b612b0c73ffffffffffffffffffffffffffffffffffffffff806020612b1398015116951685613905565b039161357e565b3880808080612adb565b612b5a9273ffffffffffffffffffffffffffffffffffffffff89511692612b0c73ffffffffffffffffffffffffffffffffffffffff8a1685613905565b388084612ad0565b3d6000fd5b33600052600360205260ff60406000205416612c28577f6352211e00000000000000000000000000000000000000000000000000000000600052600452602060006024817f00000000000000000000000000000000000000000000000000000000000000005afa15612c1e5773ffffffffffffffffffffffffffffffffffffffff600051163303612bf457565b7fc19f17a90000000000000000000000000000000000000000000000000000000060005260046000fd5b3d6000803e3d6000fd5b50565b909293916fffffffffffffffffffffffffffffffff60a081612c4d8551612dae565b93612c9e602087019183835116612d4c575b87519973ffffffffffffffffffffffffffffffffffffffff8851169a602089019b73ffffffffffffffffffffffffffffffffffffffff8d5116916148cd565b989099898b612cce8a517f000000000000000000000000000000000000000000000000000000000000000061398d565b908381612d23575b505081612cfa575b5050505051169201511614612cf05750565b612470905161496f565b73ffffffffffffffffffffffffffffffffffffffff612d1a945116613643565b38808080612cde565b612d45918373ffffffffffffffffffffffffffffffffffffffff8d5116613643565b3883612cd6565b612d76887f0000000000000000000000000000000000000000000000000000000000000000614863565b5050612c5f565b60405190612d8a82611e83565b600060a0838281528260208201528260408201528260608201528260808201520152565b612db6612d7d565b50612dbf612d7d565b907f99fbab880000000000000000000000000000000000000000000000000000000060005260045261010081602460007f00000000000000000000000000000000000000000000000000000000000000005afa15612e2557806101006040920182520190565b3d90fd5b90929180612e8a575b505080612e3d575050565b61247091612e4d823033846123ea565b73ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001690613950565b612e9a91612e4d823033846123ea565b3880612e32565b90927f0000000000000000000000000000000000000000000000000000000000000000604051937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0840180519063219f5d1781526060600060c47ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc890182885af115612c1e57526000519460205190604051906040528095829798602082015190612f52604084015193518861398d565b8583829710612f91575b50505050808210612f6e575050505050565b612b0c73ffffffffffffffffffffffffffffffffffffffff612b13961685613905565b612fb593612b0c73ffffffffffffffffffffffffffffffffffffffff8b1685613905565b38808481612f5c565b95936131139398979294612fd28851612dae565b9661302d60408a018051600060608d01928184519452526fffffffffffffffffffffffffffffffff60208d015116613296575b8b518b73ffffffffffffffffffffffffffffffffffffffff60208183511692015116916148cd565b9061303661239f565b9462ffffff60408c01511660408701526130718c517f000000000000000000000000000000000000000000000000000000000000000061398d565b9d73ffffffffffffffffffffffffffffffffffffffff8c511673ffffffffffffffffffffffffffffffffffffffff89168103613202575b5050505073ffffffffffffffffffffffffffffffffffffffff60208a0151169073ffffffffffffffffffffffffffffffffffffffff86168203613169575b505050505061310b3073ffffffffffffffffffffffffffffffffffffffff83166137e8565b978891613643565b841061313f576fffffffffffffffffffffffffffffffff60a0816020850151169201511614612cf05750565b7f5945ea560000000000000000000000000000000000000000000000000000000060005260046000fd5b6131a19473ffffffffffffffffffffffffffffffffffffffff8088168410938185828b180280921816602084015288181681526136f4565b506131c773ffffffffffffffffffffffffffffffffffffffff60208701511630906137e8565b82816131d6575b8180806130e6565b6131fb918a73ffffffffffffffffffffffffffffffffffffffff60208a015116613643565b38826131ce565b61323c9373ffffffffffffffffffffffffffffffffffffffff82818c818116831095869118028092181660208c01528b18168952886136f4565b508b8661326173ffffffffffffffffffffffffffffffffffffffff8c511630906137e8565b8061326d575b806130a8565b61328e9273ffffffffffffffffffffffffffffffffffffffff8d5116613643565b8b8638613267565b6132c08c7f0000000000000000000000000000000000000000000000000000000000000000614863565b5050613005565b73ffffffffffffffffffffffffffffffffffffffff6000541633036132e857565b7f118cdaa7000000000000000000000000000000000000000000000000000000006000523360045260246000fd5b93909260006024816133df6020949996996101408a01519a604051809c61333c82611e67565b8b8252608089830192878452876040820152876060820152015261335f8b612dae565b9073ffffffffffffffffffffffffffffffffffffffff825116906fffffffffffffffffffffffffffffffff60a073ffffffffffffffffffffffffffffffffffffffff8c860151169401511690526133d77f00000000000000000000000000000000000000000000000000000000000000009e8f614863565b50508b6148cd565b9990977f6352211e0000000000000000000000000000000000000000000000000000000083526004525afa15612c1e57613465946134569373ffffffffffffffffffffffffffffffffffffffff6000511661012087015261343e61239f565b50606086015160020b608087015160020b90876125d5565b60c083015260a08201526129f9565b90919293565b9081811061313f578061347c575050565b670de0b6b3a7640000820291818115670de0b6b3a7640000838604141702156134da575090045b60025460a01c106134b057565b7feab9763d0000000000000000000000000000000000000000000000000000000060005260046000fd5b81670de0b6b3a76400007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8184098581108601900392099082600003831692818111156135705783900480600302600218808202600203028082026002030280820260020302808202600203028082026002030280910260020302936001848483030494806000030401921190030217026134a3565b63ae47f7026000526004601cfd5b73ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016908173ffffffffffffffffffffffffffffffffffffffff8216148061363b575b1561362f575060006024818080947f2e1a7d4d000000000000000000000000000000000000000000000000000000008252876004525af1156102be57600080809338935af11561362157565b63b12d13eb6000526004601cfd5b61247093929150614818565b5060016135d5565b9290919273ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016918273ffffffffffffffffffffffffffffffffffffffff83161490816136ec575b501561362f575060006024818080947f2e1a7d4d000000000000000000000000000000000000000000000000000000008252876004525af1156102be57600080809338935af11561362157565b90503861369f565b9390919281156000146137975750506040805174ff00000000000000000000000000000000000000007f000000000000000000000000000000000000000000000000000000000000000017600052606085206020527f6ce8eb472fa82df5469c6ab6d485f17c3ad13c8cd7af59b3d4a8026c5ce0f7e282526055600b209152613794939073ffffffffffffffffffffffffffffffffffffffff16906149c7565b90565b6137e4939250906137dd9173ffffffffffffffffffffffffffffffffffffffff8080602089015116975116948588180280951816936137d630866137e8565b9618615333565b30906137e8565b0390565b6024600080926020947f70a082310000000000000000000000000000000000000000000000000000000083526004525afa156102be5760005190565b94939290916138e084836138f2936138c38a7f0000000000000000000000000000000000000000000000000000000000000000919060609074ff00000000000000000000000000000000000000006040519417600052206020527f6ce8eb472fa82df5469c6ab6d485f17c3ad13c8cd7af59b3d4a8026c5ce0f7e260405273ffffffffffffffffffffffffffffffffffffffff6055600b201691604052565b9673ffffffffffffffffffffffffffffffffffffffff8816613a4c565b505060805196909387918591906149c7565b9160000394858318028092180193180190565b6044601060008093602095601452816034526f095ea7b300000000000000000000000082525af13d15600160005114171615613942576000603452565b633e3f8f736000526004601cfd5b6010600060449260209582956014526034526f095ea7b300000000000000000000000082525af13d15600160005114171615613942576000603452565b6024600080926020947f6352211e0000000000000000000000000000000000000000000000000000000083526004525afa15612c1e5760005190565b9273ffffffffffffffffffffffffffffffffffffffff9192613a30613a45968493613a186139f78951612dae565b94613a0061239f565b508951988787511699602088019a898c5116916148cd565b90606086015160020b608087015160020b90876125d5565b60408701526020860152511691511691612ea1565b9192909190565b929094939460006080526000958215806146b7575b6146a0578360020b8260020b9080821291821592614676575b508115614669575b5061463f57843b1561463157604051610120810181811067ffffffffffffffff821117610c4d576040526000815260006020820152600060408201526000606082015260006080820152600060a0820152600060c0820152600060e08201526000610100820152613af286614ad0565b969093849760408401527f1a6865020000000000000000000000000000000000000000000000000000000060005260206000600481855afa156102be57600051907fddca3f430000000000000000000000000000000000000000000000000000000060005260206000600481865afa156102be5762ffffff60005116907fd0c93a7c0000000000000000000000000000000000000000000000000000000060005260206000600481875afa156102be57613bd892613bd29260005191875288602088015289606088015287608088015260e0870152610100860152614b0c565b96614b0c565b938660a08401528460c0840152613c3473ffffffffffffffffffffffffffffffffffffffff861673ffffffffffffffffffffffffffffffffffffffff891673ffffffffffffffffffffffffffffffffffffffff8416878a614e66565b608052507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8000906000905b600084604081015160020b9461010082015160020b946080516000146145555783868807128688050360081d9160010b8260010b14600014614545575b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600260ff8399898881830712910503161b01165b8015614507577f07060605060205040602030205040301060502050303040105050304000000006f8421084210842108cc6318c6db6d54be826fffffffffffffffffffffffffffffffff1060071b83811c67ffffffffffffffff1060061b1783811c63ffffffff1060051b1783811c61ffff1060041b1783811c60ff1060031b1792831c1c601f161a17955b948196613d6f82828560081b0102614b0c565b94608051156000146144ab57613dbf73ffffffffffffffffffffffffffffffffffffffff6020870151166fffffffffffffffffffffffffffffffff8751166080880151908960e08a015193615425565b92919690969260608201510196608082015103975b73ffffffffffffffffffffffffffffffffffffffff8085169116810361449a57613e0f9060a083015160c06080511515940151918b8b614e66565b15151461442557505050505050505050505b8051926020820151926060830151966080840151926080511560001461415b575073ffffffffffffffffffffffffffffffffffffffff811673ffffffffffffffffffffffffffffffffffffffff861610614061575b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff85161015613ebe575b50505090613eb89185614f99565b91030191565b9196509291975085519286602081015160c08201519560e08301519081620f424003908060601b84810460608701510190613efd60a08801518361553e565b9a613f16613f108689620f424002614fd8565b8561553e565b95613f2d60a060808b01519889019a01518661553e565b89039687111561405357613eb89c86613ffc96613f4d856140469d6151cb565b930204900303940290620f42400204900360011b9260011b8302828002018070ffffffffffffffffffffffffffffffffff1060071b81811c68ffffffffffffffffff1060061b1781811c64ffffffffff1060051b1781811c62ffffff1060041b1760b56201000083831c019160011c1b0260121c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8080920410900390565b0160601b058181119082180218978a89038060ff1d908101189060016c0100000000000000000000000060e0614032858a61553e565b930151620f4240039388091515160161511c565b9103019690913880613eaa565b63202368086000526004601cfd5b99975061408161407a60e0850151620f4240038461508a565b8686615011565b9773ffffffffffffffffffffffffffffffffffffffff8b1673ffffffffffffffffffffffffffffffffffffffff8a16106000146140d8575073ffffffffffffffffffffffffffffffffffffffff819a5b9050613e76565b999391858561412a9261412282879c969c038060ff1d908101186140fc818661553e565b60016c0100000000000000000000000060e08c0151620f4240039388091515160161511c565b900394614f99565b019573ffffffffffffffffffffffffffffffffffffffff8481811660208601528860608601528360808601526140d1565b905073ffffffffffffffffffffffffffffffffffffffff819893989792971673ffffffffffffffffffffffffffffffffffffffff861611614358575b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff851611156141e3575b50505090613eb89185038060ff1d908101189061553e565b9196509291975085519260208701519360c08801519460e08901519182620f4240039260608b0151908260601b908985870283620f42400204840192048203928311156140535784868e9561427e613eb89d61427661427061434b9c60a08c608061425f6142586143229e858501519061553e565b9b8a61553e565b910151019c0151620f424002614fd8565b8461553e565b8903986151cb565b93020401039160011b9260011b8302828002018070ffffffffffffffffffffffffffffffffff1060071b81811c68ffffffffffffffffff1060061b1781811c64ffffffffff1060051b1781811c62ffffff1060041b1760b56201000083831c019160011c1b0260121c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8080920410900390565b0160601b0481811090821802189760e061433d868d8c614f4b565b910151620f4240039061511c565b91030196909138806141cb565b99975061437861437160e0850151620f4240038461508a565b8686614eb2565b9773ffffffffffffffffffffffffffffffffffffffff8b8116908a16106143b9575073ffffffffffffffffffffffffffffffffffffffff819a5b9050614197565b9993916143f4906143e16143d18886899c969c614f4b565b60e0870151620f4240039061511c565b90039285038060ff1d908101188661553e565b019573ffffffffffffffffffffffffffffffffffffffff8481811660208601528360608601528860808601526143b2565b7ff30dba9300000000000000000000000000000000000000000000000000000000815283838660081b010260020b6004526040816024818b5afa156105a35760205190608051900318608051018a51018a5260208a01526080519260081b010203604087015260608601526080850152613c5e565b505050505050505050505050613e21565b936144f073ffffffffffffffffffffffffffffffffffffffff6020830151166fffffffffffffffffffffffffffffffff8351166060840151908960e086015193615425565b969192906060820151039660808201510197613dd4565b50919450507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0160010b61453b818361558c565b9390859085613cd0565b50614550818561558c565b613c9b565b60018487890712878905030160020b60081d9160010b8260010b14600014614621575b60018082988887818307129105030160ff161b8403165b801561460157808403167e1f0d1e100c1d070f090b19131c1706010e11080a1a141802121b1503160405601f826fffffffffffffffffffffffffffffffff1060071b83811c67ffffffffffffffff1060061b1783811c63ffffffff1060051b1792831c63d76453e004161a1795613d5c565b50905060019194500160010b614617818361558c565b939085908561458f565b5061462c818561558c565b614578565b6301ac05a56000526004601cfd5b7f30673a1b0000000000000000000000000000000000000000000000000000000060005260046000fd5b620d89e891501338613a82565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff2761813915038613a7a565b505050505090506000906000906000608052600090565b508015613a61565b907f00000000000000000000000000000000000000000000000000000000000000007f081812fc000000000000000000000000000000000000000000000000000000006000528260045260206000602481845afa15612c1e5760005173ffffffffffffffffffffffffffffffffffffffff163014614810577f6352211e000000000000000000000000000000000000000000000000000000006000528260045260206000602481845afa15612c1e576000517fe985e9c5000000000000000000000000000000000000000000000000000000006000526004523060245260206000604481845afa15612c1e57600051600060245261481057600095869560c4958794604051967f7ac2ff7b000000000000000000000000000000000000000000000000000000008852306004890152602488015260448701526064860152608485015260a48401525af115612c1e57565b505050505050565b6010600060449260209582956014526034526fa9059cbb00000000000000000000000082525af13d15600160005114171615614855576000603452565b6390b8ec186000526004601cfd5b6040600060a47fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0850193827ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc865197630c49ccbe885201915af115612c1e57526000519060205190565b60006084604092969594968351907ffc6f786500000000000000000000000000000000000000000000000000000000825260048201523060248201526fffffffffffffffffffffffffffffffff60448201526fffffffffffffffffffffffffffffffff6064820152827f00000000000000000000000000000000000000000000000000000000000000005af115612c1e5761220d936000519060205192612561565b7f42966c6800000000000000000000000000000000000000000000000000000000600052600452600080602481807f00000000000000000000000000000000000000000000000000000000000000005af115612c1e57565b9392919091600094826149da5750505050565b604091929395507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe06000910195865194606088528351907f128acb0800000000000000000000000000000000000000000000000000000000825230600483015285602483015260448201528473fffd8963efd1fc6a506488495d951d53639afb810273fffd8963efd1fc6a506488495d951d5263988d2518606482015260a060848201528273ffffffffffffffffffffffffffffffffffffffff60c48a51602081018c8160a488019160045afa500193165af160403d141615612c1e576000519081602051180218600003925238808080612528565b60006004816040937f3850c7bd0000000000000000000000000000000000000000000000000000000082525afa156102be576000519060205190565b8060ff1d81810118620d89e88111614e4e5763ffffffff91600182167001fffcb933bd6fad37aa2d162d1a59400102700100000000000000000000000000000000189160028116614e32575b60048116614e16575b60088116614dfa575b60108116614dde575b60208116614dc2575b60408116614da6575b60808116614d8a575b6101008116614d6e575b6102008116614d52575b6104008116614d36575b6108008116614d1a575b6110008116614cfe575b6120008116614ce2575b6140008116614cc6575b6180008116614caa575b620100008116614c8e575b620200008116614c73575b620400008116614c58575b6208000016614c3f575b600012614c18575b0160201c90565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04614c11565b6b048a170391f7dc42444e8fa290910260801c90614c09565b6d2216e584f5fa1ea926041bedfe9890920260801c91614bff565b916e5d6af8dedb81196699c329225ee6040260801c91614bf4565b916f09aa508b5b7a84e1c677de54f3e99bc90260801c91614be9565b916f31be135f97d08fd981231505542fcfa60260801c91614bde565b916f70d869a156d2a1b890bb3df62baf32f70260801c91614bd4565b916fa9f746462d870fdf8a65dc1f90e061e50260801c91614bca565b916fd097f3bdfd2022b8845ad8f792aa58250260801c91614bc0565b916fe7159475a2c29b7443b29c7fa6e889d90260801c91614bb6565b916ff3392b0822b70005940c7a398e4b70f30260801c91614bac565b916ff987a7253ac413176f2b074cf7815e540260801c91614ba2565b916ffcbe86c7900a88aedcffc83b479aa3a40260801c91614b98565b916ffe5dee046a99a2a811c461f1969c30530260801c91614b8e565b916fff2ea16466c96a3843ec78b326b528610260801c91614b85565b916fff973b41fa98c081472e6896dfb254c00260801c91614b7c565b916fffcb9843d60f6159c9db58835c9266440260801c91614b73565b916fffe5caca7e10e4e61c3624eaa0941cd00260801c91614b6a565b916ffff2e50f5f656932ef12357cf3c7fdcc0260801c91614b61565b916ffff97272373d413259a46990580e213a0260801c91614b58565b6308c379a0600052602080526101546041526045601cfd5b919391838511614e7a575050505050600090565b828510614e8b575050505050600190565b614eae93614e9c86614ea59361553e565b9086039061553e565b9382039061528c565b1090565b91908115614f465760601b918082028183820414614efa575b508291614eee9173ffffffffffffffffffffffffffffffffffffffff9404612392565b80820615159104011690565b8301838110614ecb579150614f1082828561528c565b9209614f30575b73ffffffffffffffffffffffffffffffffffffffff1690565b60010180614f175763ae47f7026000526004601cfd5b505090565b918282108284180280808518931893146102be5760019060601b92828103614f8a73ffffffffffffffffffffffffffffffffffffffff8316828761528c565b94098284061715151691040190565b818118818310028082189392811891146102be57614fd4918373ffffffffffffffffffffffffffffffffffffffff831692039060601b61528c565b0490565b8115614fe2570490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b9073ffffffffffffffffffffffffffffffffffffffff90615044938060a01c1560001461507a5760601b04915b16612392565b740100000000000000000000000000000000000000008110156102be5773ffffffffffffffffffffffffffffffffffffffff1690565b90615084916151cb565b9161503e565b81810291620f4240818385041483151702156150ab575050620f4240900490565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff620f42409284098481108501900392099080620f4240111561357057828211900360fa1b910360061c177fde8f6cefed634549b62c77574f722e1ac57e23f24d8fd5cb790fb65668c261390290565b90620f424082029181620f424082850414821517021561513c5750900490565b81620f42407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81840985811086019003920990826000038316928181111561357057839004806003026002188082026002030280820260020302808202600203028082026002030280820260020302809102600203029360018484830304948060000304019211900302170290565b908160601b91816c010000000000000000000000008285041482151702156151f35750900490565b816c010000000000000000000000007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81840985811086019003920990826000038316928181111561357057839004806003026002188082026002030280820260020302808202600203028082026002030280820260020302809102600203029360018484830304948060000304019211900302170290565b818102929181158285048214178302156152a7575050900490565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8492840985811086019003920990826000038316928181111561357057839004806003026002188082026002030280820260020302808202600203028082026002030280820260020302809102600203029360018484830304948060000304019211900302170290565b9190604681013560601c917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff92605a83013560601c910181600052600160205260ff60406000205416156153fb57836014527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff6034526f095ea7b3000000000000000000000000600052602060006044601082895af13d15600160005114171615613942576000928380938160345283606e604051940184375af115612c1e5761247091613905565b7f14e99d060000000000000000000000000000000000000000000000000000000060005260046000fd5b919094929473ffffffffffffffffffffffffffffffffffffffff811673ffffffffffffffffffffffffffffffffffffffff8416101594620f4240039061546b828861508a565b861561550c5761547c848684614f4b565b975b8882106154d5575050958691620f4240615498828461511c565b92096154c3575b945b156154ba579161379492038060ff1d908101189061553e565b61379492614f99565b6001915001801561357057859061549f565b96975091505082158215176102be5785156154fc576154f5908284614eb2565b80956154a1565b615507908284615011565b6154f5565b8185038060ff1d9081011860016c01000000000000000000000000615531838861553e565b928709151516019761547e565b818102917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff910981811082019003806c0100000000000000000000000011156135705760a01b9060601c1790565b6024600080926020947f5339c29600000000000000000000000000000000000000000000000000000000835260010b6004525afa156102be576000519056fea164736f6c634300081a000a"; + +type PCSV3AutomanConstructorParams = + | [signer?: Signer] + | ConstructorParameters; + +const isSuperArgs = ( + xs: PCSV3AutomanConstructorParams +): xs is ConstructorParameters => xs.length > 1; + +export class PCSV3Automan__factory extends ContractFactory { + constructor(...args: PCSV3AutomanConstructorParams) { + if (isSuperArgs(args)) { + super(...args); + } else { + super(_abi, _bytecode, args[0]); + } + } + + override deploy( + nonfungiblePositionManager: string, + owner_: string, + overrides?: PayableOverrides & { from?: string } + ): Promise { + return super.deploy( + nonfungiblePositionManager, + owner_, + overrides || {} + ) as Promise; + } + override getDeployTransaction( + nonfungiblePositionManager: string, + owner_: string, + overrides?: PayableOverrides & { from?: string } + ): TransactionRequest { + return super.getDeployTransaction( + nonfungiblePositionManager, + owner_, + overrides || {} + ); + } + override attach(address: string): PCSV3Automan { + return super.attach(address) as PCSV3Automan; + } + override connect(signer: Signer): PCSV3Automan__factory { + return super.connect(signer) as PCSV3Automan__factory; + } + + static readonly bytecode = _bytecode; + static readonly abi = _abi; + static createInterface(): PCSV3AutomanInterface { + return new utils.Interface(_abi) as PCSV3AutomanInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): PCSV3Automan { + return new Contract(address, _abi, signerOrProvider) as PCSV3Automan; + } +} diff --git a/src/typechain-typesV4/factories/src/PCSV3OptimalSwapRouter__factory.ts b/src/typechain-typesV4/factories/src/PCSV3OptimalSwapRouter__factory.ts new file mode 100644 index 00000000..4a971037 --- /dev/null +++ b/src/typechain-typesV4/factories/src/PCSV3OptimalSwapRouter__factory.ts @@ -0,0 +1,321 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import { + Signer, + utils, + Contract, + ContractFactory, + PayableOverrides, +} from "ethers"; +import type { Provider, TransactionRequest } from "@ethersproject/providers"; +import type { + PCSV3OptimalSwapRouter, + PCSV3OptimalSwapRouterInterface, +} from "../../src/PCSV3OptimalSwapRouter"; + +const _abi = [ + { + inputs: [ + { + internalType: "contract IPCSV3NonfungiblePositionManager", + name: "npm", + type: "address", + }, + { + internalType: "address", + name: "owner_", + type: "address", + }, + ], + stateMutability: "payable", + type: "constructor", + }, + { + inputs: [], + name: "InvalidRouter", + type: "error", + }, + { + inputs: [], + name: "Invalid_Tick_Range", + type: "error", + }, + { + inputs: [], + name: "MismatchETH", + type: "error", + }, + { + inputs: [], + name: "NotAllowlistedRouter", + type: "error", + }, + { + inputs: [], + name: "NotWETH9", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "OwnableInvalidOwner", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "account", + type: "address", + }, + ], + name: "OwnableUnauthorizedAccount", + type: "error", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "previousOwner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "OwnershipTransferred", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "SetAllowlistedRouters", + type: "event", + }, + { + stateMutability: "nonpayable", + type: "fallback", + }, + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "deployer", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + name: "isAllowListedRouter", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "owner", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "int256", + name: "amount0Delta", + type: "int256", + }, + { + internalType: "int256", + name: "amount1Delta", + type: "int256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "pancakeV3SwapCallback", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [], + name: "renounceOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setAllowlistedRouters", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "transferOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + stateMutability: "payable", + type: "receive", + }, +] as const; + +const _bytecode = + "0x60e0806040526040816128a9803803809161001a82856101ed565b83398101031261017d5780516001600160a01b038116919082900361017d576001600160a01b039061004e90602001610226565b1680156101d757600080546001600160a01b031981168317825560405192916001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09080a360808290526312a9293f60e21b8152602081600481855afa90811561018a57600091610196575b506001600160a01b031660a052604051631abe729160e31b815290602090829060049082905afa90811561018a5760009161014b575b5060c05260405161266e908161023b82396080518181816107a101526109ba015260a0518181816103d801528181610ac50152610d75015260c05181818161019e015281816105d70152610bec0152f35b90506020813d602011610182575b81610166602093836101ed565b8101031261017d5761017790610226565b386100fa565b600080fd5b3d9150610159565b6040513d6000823e3d90fd5b90506020813d6020116101cf575b816101b1602093836101ed565b8101031261017d576004916101c7602092610226565b9150916100c4565b3d91506101a4565b631e4fbdf760e01b600052600060045260246000fd5b601f909101601f19168101906001600160401b0382119082101761021057604052565b634e487b7160e01b600052604160045260246000fd5b51906001600160a01b038216820361017d5756fe60a080604052600436101561042a575b5036156103c157346103bc5760003560601c60143560601c9060313560f81c9060323560601c7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa63601838584180285189061008b6100833373ffffffffffffffffffffffffffffffffffffffff8516610ed0565b303385610f0c565b826014527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff6034526f095ea7b3000000000000000000000000600052602060006044601082865af13d156001600051141716156103ae57600080918160345260405181605a82378260463560601c5af11561035f576044601060008093602095601452816034526f095ea7b300000000000000000000000082525af13d156001600051141716156103ae5760006034526101453082610ed0565b61014f3085610ed0565b90604051906060820182811067ffffffffffffffff82111761037f5760405283825285602083015260283560e81c60408301526040519474ff00000000000000000000000000000000000000007f000000000000000000000000000000000000000000000000000000000000000017600052606083206020527f6ce8eb472fa82df5469c6ab6d485f17c3ad13c8cd7af59b3d4a8026c5ce0f7e260405273ffffffffffffffffffffffffffffffffffffffff6055600b20169560405260001461036957610236816102203389610ed0565b8501905b602e3560e81d602b3560e81d89610f65565b50506080519560009382610285575b50506000039485831802809218019318019180610273575b50508061026657005b610271913390611c09565b005b61027e913390611c09565b388061025d565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe09194500192604060008551926060875282517f128acb080000000000000000000000000000000000000000000000000000000081523060048201528a60248201528560448201528a73fffd8963efd1fc6a506488495d951d53639afb810273fffd8963efd1fc6a506488495d951d5263988d2518606482015260a060848201528260c489516020810160a48501818d60045afa5001925af160403d14161561035f57600051878160205118021860000393523880610245565b3d6000803e3d6000fd5b6102366103763386610ed0565b82018490610224565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b633e3f8f736000526004601cfd5b600080fd5b73ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016330361040057005b7f2f1ca35a0000000000000000000000000000000000000000000000000000000060005260046000fd5b60003560e01c90816323a69e7514610b53575080634095c64614610ae95780634aa4a4fc14610a7a578063715018a6146109de5780637f1e9ef61461096f5780638da5cb5b1461091d57806391f6e9b2146105fb578063d5f394881461058c5763f2fde38b1461049a573861000f565b346103bc5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103bc5773ffffffffffffffffffffffffffffffffffffffff6104e6610c87565b6104ee610e81565b16801561055d5773ffffffffffffffffffffffffffffffffffffffff600054827fffffffffffffffffffffffff0000000000000000000000000000000000000000821617600055167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0600080a3005b7f1e4fbdf700000000000000000000000000000000000000000000000000000000600052600060045260246000fd5b346103bc5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103bc57602060405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152f35b60407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103bc5760043567ffffffffffffffff81116103bc57610645903690600401610caa565b60243567ffffffffffffffff81116103bc57610665903690600401610caa565b909261066f610e81565b8183036103bc579160005b818110610742575060405192816040850160408652526060840190916000905b80821061070b57505060209150838103828501528281520192906000905b8082106106e7577fe4d045717648b4a964b22e91953fd95d48e089e38c87021016e48ddd32387eee84860385a1005b9091938435908115158092036103bc576020816001938293520195019201906106b8565b909183359073ffffffffffffffffffffffffffffffffffffffff82168092036103bc5790815260209384019301916001019061069a565b61074f8183869496610cdb565b359073ffffffffffffffffffffffffffffffffffffffff8216918281036103bc5761077b828689610cdb565b3580151581036103bc57156108e25773ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168084146108b35760009182918260405160208101927f095ea7b3000000000000000000000000000000000000000000000000000000008452602482015281604482015260448152610813606482610d1a565b51925af13d156108dd573d67ffffffffffffffff811161037f576040519061086360207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8401160183610d1a565b8152600060203d92013e5b6108b357600191600052816020526040600020827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008254161790555b0192909261067a565b7f466d7fef0000000000000000000000000000000000000000000000000000000060005260046000fd5b61086e565b506001916000528160205260406000207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0081541690556108aa565b346103bc5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103bc57602073ffffffffffffffffffffffffffffffffffffffff60005416604051908152f35b346103bc5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103bc57602060405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152f35b346103bc5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103bc57610a15610e81565b600073ffffffffffffffffffffffffffffffffffffffff81547fffffffffffffffffffffffff000000000000000000000000000000000000000081168355167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08280a3005b346103bc5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103bc57602060405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152f35b346103bc5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103bc5773ffffffffffffffffffffffffffffffffffffffff610b35610c87565b166000526001602052602060ff604060002054166040519015158152f35b346103bc5760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103bc576004356044359167ffffffffffffffff83116103bc57366023840112156103bc5782600401359267ffffffffffffffff84116103bc57602481019360243691830101116103bc57606084600037606060002074ff00000000000000000000000000000000000000007f0000000000000000000000000000000000000000000000000000000000000000176000526020527f6ce8eb472fa82df5469c6ab6d485f17c3ad13c8cd7af59b3d4a8026c5ce0f7e260405273ffffffffffffffffffffffffffffffffffffffff6055600b2016916040528133036103bc576000831315610c72575061027192309035610d5b565b61027193506024359250309060440135610d5b565b6004359073ffffffffffffffffffffffffffffffffffffffff821682036103bc57565b9181601f840112156103bc5782359167ffffffffffffffff83116103bc576020808501948460051b0101116103bc57565b9190811015610ceb5760051b0190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761037f57604052565b92919073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168073ffffffffffffffffffffffffffffffffffffffff86161480610e78575b610dec575b5073ffffffffffffffffffffffffffffffffffffffff81163003610de35750610de192611c09565b565b610de193610f0c565b348403610e4e5760006004818681947fd0e30db00000000000000000000000000000000000000000000000000000000083525af1156103bc573073ffffffffffffffffffffffffffffffffffffffff831614610e485738610db9565b50505050565b7fa11a990f0000000000000000000000000000000000000000000000000000000060005260046000fd5b50341515610db4565b73ffffffffffffffffffffffffffffffffffffffff600054163303610ea257565b7f118cdaa7000000000000000000000000000000000000000000000000000000006000523360045260246000fd5b6024600080926020947f70a082310000000000000000000000000000000000000000000000000000000083526004525afa156103bc5760005190565b601c600060649281946020966040519860605260405260601b602c526f23b872dd000000000000000000000000600c525af13d15600160005114171615610f57576000606052604052565b637939f4246000526004601cfd5b600060808190529594919391821580611c01575b611bea578360020b8560020b9080821291821592611bc0575b508115611bb3575b50611b8957813b15611b7b57604051610120810181811067ffffffffffffffff82111761037f576040526000815260006020820152600060408201526000606082015260006080820152600060a0820152600060c0820152600060e082015260006101008201527f3850c7bd0000000000000000000000000000000000000000000000000000000060005260406000600481865afa156103bc576000519260205196849760408401527f1a6865020000000000000000000000000000000000000000000000000000000060005260206000600481855afa156103bc57600051907fddca3f430000000000000000000000000000000000000000000000000000000060005260206000600481865afa156103bc5762ffffff60005116907fd0c93a7c0000000000000000000000000000000000000000000000000000000060005260206000600481875afa156103bc5761111f926111199260005191875288602088015289606088015287608088015260e0870152610100860152611c54565b96611c54565b938660a08401528460c084015261117b73ffffffffffffffffffffffffffffffffffffffff861673ffffffffffffffffffffffffffffffffffffffff891673ffffffffffffffffffffffffffffffffffffffff8416878a611fae565b608052507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8000906000905b600084604081015160020b9461010082015160020b94608051600014611a9f5783868807128688050360081d9160010b8260010b14600014611a8f575b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600260ff8399898881830712910503161b01165b8015611a51577f07060605060205040602030205040301060502050303040105050304000000006f8421084210842108cc6318c6db6d54be826fffffffffffffffffffffffffffffffff1060071b83811c67ffffffffffffffff1060061b1783811c63ffffffff1060051b1783811c61ffff1060041b1783811c60ff1060031b1792831c1c601f161a17955b9481966112b682828560081b0102611c54565b94608051156000146119f55761130673ffffffffffffffffffffffffffffffffffffffff6020870151166fffffffffffffffffffffffffffffffff8751166080880151908960e08a01519361220f565b92919690969260608201510196608082015103975b73ffffffffffffffffffffffffffffffffffffffff808516911681036119e4576113569060a083015160c06080511515940151918b8b611fae565b15151461196c57505050505050505050505b805192602082015192606083015196608084015192608051156000146116a2575073ffffffffffffffffffffffffffffffffffffffff811673ffffffffffffffffffffffffffffffffffffffff8616106115a8575b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff85161015611405575b505050906113ff918561211e565b91030191565b9196509291975085519286602081015160c08201519560e08301519081620f424003908060601b8481046060870151019061144460a0880151836125d4565b9a61145d6114578689620f42400261215d565b856125d4565b9561147460a060808b01519889019a0151866125d4565b89039687111561159a576113ff9c86611543966114948561158d9d61246c565b930204900303940290620f42400204900360011b9260011b8302828002018070ffffffffffffffffffffffffffffffffff1060071b81811c68ffffffffffffffffff1060061b1781811c64ffffffffff1060051b1781811c62ffffff1060041b1760b56201000083831c019160011c1b0260121c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8080920410900390565b0160601b058181119082180218978a89038060ff1d908101189060016c0100000000000000000000000060e0611579858a6125d4565b930151620f424003938809151516016123bd565b91030196909138806113f1565b63202368086000526004601cfd5b9997506115c86115c160e0850151620f4240038461232b565b8686612196565b9773ffffffffffffffffffffffffffffffffffffffff8b1673ffffffffffffffffffffffffffffffffffffffff8a161060001461161f575073ffffffffffffffffffffffffffffffffffffffff819a5b90506113bd565b99939185856116719261166982879c969c038060ff1d9081011861164381866125d4565b60016c0100000000000000000000000060e08c0151620f424003938809151516016123bd565b90039461211e565b019573ffffffffffffffffffffffffffffffffffffffff848181166020860152886060860152836080860152611618565b905073ffffffffffffffffffffffffffffffffffffffff819893989792971673ffffffffffffffffffffffffffffffffffffffff86161161189f575b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff8516111561172a575b505050906113ff9185038060ff1d90810118906125d4565b9196509291975085519260208701519360c08801519460e08901519182620f4240039260608b0151908260601b908985870283620f424002048401920482039283111561159a5784868e956117c56113ff9d6117bd6117b76118929c60a08c60806117a661179f6118699e85850151906125d4565b9b8a6125d4565b910151019c0151620f42400261215d565b846125d4565b89039861246c565b93020401039160011b9260011b8302828002018070ffffffffffffffffffffffffffffffffff1060071b81811c68ffffffffffffffffff1060061b1781811c64ffffffffff1060051b1781811c62ffffff1060041b1760b56201000083831c019160011c1b0260121c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8080920410900390565b0160601b0481811090821802189760e0611884868d8c6120d0565b910151620f424003906123bd565b9103019690913880611712565b9997506118bf6118b860e0850151620f4240038461232b565b8686612036565b9773ffffffffffffffffffffffffffffffffffffffff8b8116908a1610611900575073ffffffffffffffffffffffffffffffffffffffff819a5b90506116de565b99939161193b906119286119188886899c969c6120d0565b60e0870151620f424003906123bd565b90039285038060ff1d90810118866125d4565b019573ffffffffffffffffffffffffffffffffffffffff8481811660208601528360608601528860808601526118f9565b7ff30dba9300000000000000000000000000000000000000000000000000000000815283838660081b010260020b6004526040816024818b5afa156119e15760205190608051900318608051018a51018a5260208a01526080519260081b0102036040870152606086015260808501526111a5565b80fd5b505050505050505050505050611368565b93611a3a73ffffffffffffffffffffffffffffffffffffffff6020830151166fffffffffffffffffffffffffffffffff8351166060840151908960e08601519361220f565b96919290606082015103966080820151019761131b565b50919450507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0160010b611a858183612622565b9390859085611217565b50611a9a8185612622565b6111e2565b60018487890712878905030160020b60081d9160010b8260010b14600014611b6b575b60018082988887818307129105030160ff161b8403165b8015611b4b57808403167e1f0d1e100c1d070f090b19131c1706010e11080a1a141802121b1503160405601f826fffffffffffffffffffffffffffffffff1060071b83811c67ffffffffffffffff1060061b1783811c63ffffffff1060051b1792831c63d76453e004161a17956112a3565b50905060019194500160010b611b618183612622565b9390859085611ad9565b50611b768185612622565b611ac2565b6301ac05a56000526004601cfd5b7f30673a1b0000000000000000000000000000000000000000000000000000000060005260046000fd5b620d89e891501338610f9a565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff2761813915038610f92565b505050505090506000906000906000608052600090565b508015610f79565b6010600060449260209582956014526034526fa9059cbb00000000000000000000000082525af13d15600160005114171615611c46576000603452565b6390b8ec186000526004601cfd5b8060ff1d81810118620d89e88111611f965763ffffffff91600182167001fffcb933bd6fad37aa2d162d1a59400102700100000000000000000000000000000000189160028116611f7a575b60048116611f5e575b60088116611f42575b60108116611f26575b60208116611f0a575b60408116611eee575b60808116611ed2575b6101008116611eb6575b6102008116611e9a575b6104008116611e7e575b6108008116611e62575b6110008116611e46575b6120008116611e2a575b6140008116611e0e575b6180008116611df2575b620100008116611dd6575b620200008116611dbb575b620400008116611da0575b6208000016611d87575b600012611d60575b0160201c90565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04611d59565b6b048a170391f7dc42444e8fa290910260801c90611d51565b6d2216e584f5fa1ea926041bedfe9890920260801c91611d47565b916e5d6af8dedb81196699c329225ee6040260801c91611d3c565b916f09aa508b5b7a84e1c677de54f3e99bc90260801c91611d31565b916f31be135f97d08fd981231505542fcfa60260801c91611d26565b916f70d869a156d2a1b890bb3df62baf32f70260801c91611d1c565b916fa9f746462d870fdf8a65dc1f90e061e50260801c91611d12565b916fd097f3bdfd2022b8845ad8f792aa58250260801c91611d08565b916fe7159475a2c29b7443b29c7fa6e889d90260801c91611cfe565b916ff3392b0822b70005940c7a398e4b70f30260801c91611cf4565b916ff987a7253ac413176f2b074cf7815e540260801c91611cea565b916ffcbe86c7900a88aedcffc83b479aa3a40260801c91611ce0565b916ffe5dee046a99a2a811c461f1969c30530260801c91611cd6565b916fff2ea16466c96a3843ec78b326b528610260801c91611ccd565b916fff973b41fa98c081472e6896dfb254c00260801c91611cc4565b916fffcb9843d60f6159c9db58835c9266440260801c91611cbb565b916fffe5caca7e10e4e61c3624eaa0941cd00260801c91611cb2565b916ffff2e50f5f656932ef12357cf3c7fdcc0260801c91611ca9565b916ffff97272373d413259a46990580e213a0260801c91611ca0565b6308c379a0600052602080526101546041526045601cfd5b919391838511611fc2575050505050600090565b828510611fd3575050505050600190565b611ff693611fe486611fed936125d4565b908603906125d4565b9382039061252d565b1090565b9190820180921161200757565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b919081156120cb5760601b91808202818382041461207e575b5082916120729173ffffffffffffffffffffffffffffffffffffffff9404611ffa565b80820615159104011690565b830183811061204f57915061209482828561252d565b92096120b4575b73ffffffffffffffffffffffffffffffffffffffff1690565b6001018061209b575b63ae47f7026000526004601cfd5b505090565b918282108284180280808518931893146103bc5760019060601b9282810361210f73ffffffffffffffffffffffffffffffffffffffff8316828761252d565b94098284061715151691040190565b818118818310028082189392811891146103bc57612159918373ffffffffffffffffffffffffffffffffffffffff831692039060601b61252d565b0490565b8115612167570490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b9073ffffffffffffffffffffffffffffffffffffffff906121c9938060a01c156000146121ff5760601b04915b16611ffa565b740100000000000000000000000000000000000000008110156103bc5773ffffffffffffffffffffffffffffffffffffffff1690565b906122099161246c565b916121c3565b919094929473ffffffffffffffffffffffffffffffffffffffff811673ffffffffffffffffffffffffffffffffffffffff8416101594620f42400390612255828861232b565b86156122f9576122668486846120d0565b975b8882106122c2575050958691620f424061228282846123bd565b92096122b0575b945b156122a757916122a492038060ff1d90810118906125d4565b90565b6122a49261211e565b600191500180156120bd578590612289565b96975091505082158215176103bc5785156122e9576122e2908284612036565b809561228b565b6122f4908284612196565b6122e2565b8185038060ff1d9081011860016c0100000000000000000000000061231e83886125d4565b9287091515160197612268565b81810291620f42408183850414831517021561234c575050620f4240900490565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff620f42409284098481108501900392099080620f424011156120bd57828211900360fa1b910360061c177fde8f6cefed634549b62c77574f722e1ac57e23f24d8fd5cb790fb65668c261390290565b90620f424082029181620f42408285041482151702156123dd5750900490565b81620f42407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8184098581108601900392099082600003831692818111156120bd57839004806003026002188082026002030280820260020302808202600203028082026002030280820260020302809102600203029360018484830304948060000304019211900302170290565b908160601b91816c010000000000000000000000008285041482151702156124945750900490565b816c010000000000000000000000007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8184098581108601900392099082600003831692818111156120bd57839004806003026002188082026002030280820260020302808202600203028082026002030280820260020302809102600203029360018484830304948060000304019211900302170290565b81810292918115828504821417830215612548575050900490565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff849284098581108601900392099082600003831692818111156120bd57839004806003026002188082026002030280820260020302808202600203028082026002030280820260020302809102600203029360018484830304948060000304019211900302170290565b818102917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff910981811082019003806c0100000000000000000000000011156120bd5760a01b9060601c1790565b6024600080926020947f5339c29600000000000000000000000000000000000000000000000000000000835260010b6004525afa156103bc576000519056fea164736f6c634300081a000a"; + +type PCSV3OptimalSwapRouterConstructorParams = + | [signer?: Signer] + | ConstructorParameters; + +const isSuperArgs = ( + xs: PCSV3OptimalSwapRouterConstructorParams +): xs is ConstructorParameters => xs.length > 1; + +export class PCSV3OptimalSwapRouter__factory extends ContractFactory { + constructor(...args: PCSV3OptimalSwapRouterConstructorParams) { + if (isSuperArgs(args)) { + super(...args); + } else { + super(_abi, _bytecode, args[0]); + } + } + + override deploy( + npm: string, + owner_: string, + overrides?: PayableOverrides & { from?: string } + ): Promise { + return super.deploy( + npm, + owner_, + overrides || {} + ) as Promise; + } + override getDeployTransaction( + npm: string, + owner_: string, + overrides?: PayableOverrides & { from?: string } + ): TransactionRequest { + return super.getDeployTransaction(npm, owner_, overrides || {}); + } + override attach(address: string): PCSV3OptimalSwapRouter { + return super.attach(address) as PCSV3OptimalSwapRouter; + } + override connect(signer: Signer): PCSV3OptimalSwapRouter__factory { + return super.connect(signer) as PCSV3OptimalSwapRouter__factory; + } + + static readonly bytecode = _bytecode; + static readonly abi = _abi; + static createInterface(): PCSV3OptimalSwapRouterInterface { + return new utils.Interface(_abi) as PCSV3OptimalSwapRouterInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): PCSV3OptimalSwapRouter { + return new Contract( + address, + _abi, + signerOrProvider + ) as PCSV3OptimalSwapRouter; + } +} diff --git a/src/typechain-typesV4/factories/src/SlipStreamAutoman__factory.ts b/src/typechain-typesV4/factories/src/SlipStreamAutoman__factory.ts new file mode 100644 index 00000000..7c29b975 --- /dev/null +++ b/src/typechain-typesV4/factories/src/SlipStreamAutoman__factory.ts @@ -0,0 +1,1870 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import { + Signer, + utils, + Contract, + ContractFactory, + PayableOverrides, +} from "ethers"; +import type { Provider, TransactionRequest } from "@ethersproject/providers"; +import type { + SlipStreamAutoman, + SlipStreamAutomanInterface, +} from "../../src/SlipStreamAutoman"; + +const _abi = [ + { + inputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "nonfungiblePositionManager", + type: "address", + }, + { + internalType: "address", + name: "owner_", + type: "address", + }, + ], + stateMutability: "payable", + type: "constructor", + }, + { + inputs: [], + name: "FeeLimitExceeded", + type: "error", + }, + { + inputs: [], + name: "InsufficientAmount", + type: "error", + }, + { + inputs: [], + name: "InvalidRouter", + type: "error", + }, + { + inputs: [], + name: "Invalid_Tick_Range", + type: "error", + }, + { + inputs: [], + name: "MismatchETH", + type: "error", + }, + { + inputs: [], + name: "NotAllowlistedRouter", + type: "error", + }, + { + inputs: [], + name: "NotApproved", + type: "error", + }, + { + inputs: [], + name: "NotWETH9", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "OwnableInvalidOwner", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "account", + type: "address", + }, + ], + name: "OwnableUnauthorizedAccount", + type: "error", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "controllers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "ControllersSet", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "DecreaseLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address", + name: "feeCollector", + type: "address", + }, + { + indexed: false, + internalType: "uint96", + name: "feeLimitPips", + type: "uint96", + }, + ], + name: "FeeConfigSet", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "IncreaseLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Mint", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "previousOwner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "OwnershipTransferred", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Rebalance", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Reinvest", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "RemoveLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "SetAllowlistedRouters", + type: "event", + }, + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + ], + name: "decreaseLiquidity", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "decreaseLiquidity", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenOut", + type: "address", + }, + { + internalType: "uint256", + name: "tokenOutMin", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + ], + name: "decreaseLiquidityToTokenOut", + outputs: [ + { + internalType: "uint256", + name: "tokenOutAmount", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenOut", + type: "address", + }, + { + internalType: "uint256", + name: "tokenOutMin", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "decreaseLiquidityToTokenOut", + outputs: [ + { + internalType: "uint256", + name: "tokenOutAmount", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [], + name: "factory", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "feeConfig", + outputs: [ + { + internalType: "address", + name: "feeCollector", + type: "address", + }, + { + internalType: "uint96", + name: "feeLimitPips", + type: "uint96", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "V3PoolCallee", + name: "pool", + type: "address", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + ], + name: "getOptimalSwap", + outputs: [ + { + internalType: "uint256", + name: "amountIn", + type: "uint256", + }, + { + internalType: "uint256", + name: "amountOut", + type: "uint256", + }, + { + internalType: "bool", + name: "zeroForOne", + type: "bool", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + ], + name: "increaseLiquidity", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + ], + name: "increaseLiquidityOptimal", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenIn", + type: "address", + }, + { + internalType: "uint256", + name: "tokenInFeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + ], + name: "increaseLiquidityWithTokenIn", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + name: "isAllowListedRouter", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + name: "isController", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "int24", + name: "tickSpacing", + type: "int24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + internalType: "struct ISlipStreamNonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + ], + name: "mint", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "int24", + name: "tickSpacing", + type: "int24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + internalType: "struct ISlipStreamNonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + ], + name: "mintOptimal", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "int24", + name: "tickSpacing", + type: "int24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + internalType: "struct ISlipStreamNonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenIn", + type: "address", + }, + { + internalType: "uint256", + name: "tokenInFeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + ], + name: "mintWithTokenIn", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "owner", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "int24", + name: "tickSpacing", + type: "int24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + internalType: "struct ISlipStreamNonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "rebalance", + outputs: [ + { + internalType: "uint256", + name: "newTokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "int24", + name: "tickSpacing", + type: "int24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + internalType: "struct ISlipStreamNonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + ], + name: "rebalance", + outputs: [ + { + internalType: "uint256", + name: "newTokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + ], + name: "reinvest", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "reinvest", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [], + name: "renounceOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setAllowlistedRouters", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "controllers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setControllers", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "feeCollector", + type: "address", + }, + { + internalType: "uint96", + name: "feeLimitPips", + type: "uint96", + }, + ], + internalType: "struct IAutomanCommon.FeeConfig", + name: "_feeConfig", + type: "tuple", + }, + ], + name: "setFeeConfig", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "transferOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "int256", + name: "amount0Delta", + type: "int256", + }, + { + internalType: "int256", + name: "amount1Delta", + type: "int256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "uniswapV3SwapCallback", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + stateMutability: "payable", + type: "receive", + }, +] as const; + +const _bytecode = + "0x60e080604052604081615ea1803803809161001a8285610270565b8339810103126102005780516001600160a01b03811691828203610200576001600160a01b039061004d906020016102a9565b1690811561025a57600080546001600160a01b031981168417825560405193916001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09080a36080526312a9293f60e21b8152602081600481855afa90811561020d57600091610219575b506001600160a01b031660a05260405163c45a015560e01b815290602090829060049082905afa90811561020d576000916101ce575b5060c052604051615be390816102be8239608051818181610cdb01528181610d45015281816112b30152818161146001528181612aca01528181612bb301528181612cc301528181612d6201528181612dd901528181612fdc015281816132cf0152818161391d01528181613aba01528181613aea015281816143a7015281816145cb0152614632015260a0518181816108d301528181612a4701528181613363015281816135970152613660015260c051818181611c26015281816125450152818161370f015281816137d401526141670152f35b90506020813d602011610205575b816101e960209383610270565b81010312610200576101fa906102a9565b386100f8565b600080fd5b3d91506101dc565b6040513d6000823e3d90fd5b90506020813d602011610252575b8161023460209383610270565b810103126102005760049161024a6020926102a9565b9150916100c2565b3d9150610227565b631e4fbdf760e01b600052600060045260246000fd5b601f909101601f19168101906001600160401b0382119082101761029357604052565b634e487b7160e01b600052604160045260246000fd5b51906001600160a01b03821682036102005756fe60806040526004361015610023575b361561001957600080fd5b610021612a30565b005b60003560e01c80631e5eb1d0146101e3578063218b625f146101de578063219f5d17146101d957806322adac05146101d45780632c45e5a0146101cf5780634095c646146101ca5780634aa4a4fc146101c55780634bf19390146101c057806367963590146101bb57806370f3c180146101b6578063715018a6146101b15780637f1e9ef6146101ac5780638ba1e273146101a75780638da5cb5b146101a257806391f6e9b21461019d57806398bbfdc11461019857806399642fb114610193578063a5fd1e3c1461018e578063ac5f046c14610189578063af3ed58614610184578063b429afeb1461017f578063b5007d1f1461017a578063c45a015514610175578063c747e2b314610170578063dcad8f551461016b578063eeb6f92214610166578063f2fde38b146101615763fa461e330361000e576124eb565b6123f5565b611f49565b611ddc565b611c4a565b611bdb565b611afb565b611a8d565b6119cd565b6118f2565b611867565b6116b2565b6115f9565b6113c1565b61136f565b6112d7565b611268565b6111cc565b6110fc565b611036565b6108f7565b610888565b61081a565b610730565b6105d3565b61049c565b610398565b346102445760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610244576002546040805173ffffffffffffffffffffffffffffffffffffffff8316815260a09290921c602083015290f35b0390f35b600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60a0810190811067ffffffffffffffff82111761029457604052565b610249565b60c0810190811067ffffffffffffffff82111761029457604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761029457604052565b60405190610306610180836102b5565b565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc60a0910112610244576040519061033f82610278565b8160043581526024356fffffffffffffffffffffffffffffffff81168103610244576020820152604435604082015260643560608201526080608435910152565b8015150361024457565b610124359061030682610380565b34610244576101007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610244576102406103d436610308565b6103fa60e43560c43560a4356103e983610380565b8451946103f586612a99565b612b24565b6040939193519384937f269a3942fe0284ff30ff93f97529fba299f93b8b85221afab5686fdab8bfa84b600080a2835260208301526040820190565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc60c0910112610244576040519061046d82610299565b6004358252602435602083015260443560408301526064356060830152608435608083015260a43560a0830152565b60c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610244576102406104d236610436565b61051b8151916104e183612d1f565b73ffffffffffffffffffffffffffffffffffffffff602081835116920151169161051660208201516040830151908585612d9a565b612dd5565b906040949294519485947fe93a38a2f007635b024bb3a896c7021e73edc7146c413a63e6b69c337304c698600080a26fffffffffffffffffffffffffffffffff168452602084015260408301526060820190565b73ffffffffffffffffffffffffffffffffffffffff81160361024457565b60a435906103068261056f565b35906103068261056f565b9181601f840112156102445782359167ffffffffffffffff8311610244576020838186019501011161024457565b34610244576101407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102445761060c36610308565b60a435906106198261056f565b60c4359060e43567ffffffffffffffff81116102445761063d9036906004016105a5565b929093610104359367ffffffffffffffff8511610244576102409561066961067f9636906004016105a5565b949093610124359661067a88610380565b6126ca565b6040519081529081906020820190565b9181601f840112156102445782359167ffffffffffffffff8311610244576020808501948460051b01011161024457565b60407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc8201126102445760043567ffffffffffffffff811161024457816107099160040161068f565b929092916024359067ffffffffffffffff82116102445761072c9160040161068f565b9091565b346102445761073e366106c0565b92906107486132fa565b8383036102445760005b83811061079157507f2077016b05a05d3f12f6d9a8ca3667fbecaf29eba7083f7e2d1d70dc3709f6359361078c9160405194859485612778565b0390a1005b806108146107a26001938886612716565b356107ac81610380565b73ffffffffffffffffffffffffffffffffffffffff6107cc848989612716565b356107d68161056f565b16600052600360205260406000209060ff7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0083541691151516179055565b01610752565b346102445760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102445773ffffffffffffffffffffffffffffffffffffffff60043561086a8161056f565b166000526001602052602060ff604060002054166040519015158152f35b346102445760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261024457602060405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152f35b6101407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102445761092b36610436565b61093660c43561056f565b60e4356101043567ffffffffffffffff81116102445761095a9036906004016105a5565b9091610124359267ffffffffffffffff841161024457610c2f610c5193610c4a928761098d6102409836906004016105a5565b9290966000936000916109b4816109af60406020890151980197885190612845565b612845565b906109c88115159283610f28575b8261346d565b60025473ffffffffffffffffffffffffffffffffffffffff1691610f15575b50506109f38c51612d1f565b956109fc612857565b93610a18610a0e60408a015160020b90565b60020b6040870152565b8d610a37895173ffffffffffffffffffffffffffffffffffffffff1690565b9073ffffffffffffffffffffffffffffffffffffffff60c4351673ffffffffffffffffffffffffffffffffffffffff831603610e70575b505050506020860198610a958a5173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff811673ffffffffffffffffffffffffffffffffffffffff60c435168103610df1575b5050505073ffffffffffffffffffffffffffffffffffffffff60c43516610b23610b0a875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff1690565b14610dc7575b73ffffffffffffffffffffffffffffffffffffffff60c43516610b63610b0a8a5173ffffffffffffffffffffffffffffffffffffffff1690565b14610d9a575b610bfc90610b8b865173ffffffffffffffffffffffffffffffffffffffff1690565b94610be5610bad8b5173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff16602086019081529673ffffffffffffffffffffffffffffffffffffffff168552565b606087015160020b608088015160020b90856137bf565b83528060208c015280610d72575b50505180610d0d575b50505173ffffffffffffffffffffffffffffffffffffffff1690565b915173ffffffffffffffffffffffffffffffffffffffff1690565b9084612dd5565b90929193610c773073ffffffffffffffffffffffffffffffffffffffff60c43516613783565b80610cd0575b5051926040519485947fe93a38a2f007635b024bb3a896c7021e73edc7146c413a63e6b69c337304c698600080a26fffffffffffffffffffffffffffffffff168452602084015260408301526060820190565b610d0790610cff83517f0000000000000000000000000000000000000000000000000000000000000000614807565b60c435613580565b38610c7d565b610d2e610d6b925173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016906138dd565b3880610c13565b610d2e610d93925173ffffffffffffffffffffffffffffffffffffffff1690565b3880610c0a565b50610bfc610dc03073ffffffffffffffffffffffffffffffffffffffff60c43516613783565b9050610b69565b9250610deb3073ffffffffffffffffffffffffffffffffffffffff60c43516613783565b92610b29565b610e67945060c43573ffffffffffffffffffffffffffffffffffffffff81169190911091610e5f91610e45918082188502908118911873ffffffffffffffffffffffffffffffffffffffff16602089015290565b73ffffffffffffffffffffffffffffffffffffffff168652565b8551856136f6565b38808080610acc565b610f0b949850602090610f03610ee9610ecc610e9f8673ffffffffffffffffffffffffffffffffffffffff1690565b60c43573ffffffffffffffffffffffffffffffffffffffff81169190911096808218880290811892911890565b73ffffffffffffffffffffffffffffffffffffffff168b86015290565b73ffffffffffffffffffffffffffffffffffffffff168952565b0151866136f6565b933880808e610a6e565b610f219160c435613580565b38806109e7565b610f3681303360c435613349565b6109c2565b604435908160020b820361024457565b35908160020b820361024457565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc61018091011261024457610f8c6102f6565b90610f97600461059a565b8252610fa3602461059a565b6020830152610fb26044610f4b565b6040830152610fc16064610f4b565b6060830152610fd06084610f4b565b608083015260a43560a083015260c43560c083015260e43560e08301526101043561010083015261100261012461059a565b6101208301526101443561014083015261101d61016461059a565b610160830152565b610164359060ff8216820361024457565b34610244576102807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102445761106f36610f59565b6101c435906101a43590610184356101e43567ffffffffffffffff81116102445761109e9036906004016105a5565b6102043590610224359260ff8416840361024457610240976110c99761024435966102643598612887565b604080519485526fffffffffffffffffffffffffffffffff90931660208501529183015260608201529081906080820190565b34610244576101207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102445761113536610436565b60c435906101043560e43567ffffffffffffffff821161024457610240936111646111789336906004016105a5565b92909185519561117387612a99565b613b60565b906040949294519485947fc13e24d2b0a3bacd5d1a7c514125a1e27323abf7c86f6d36597f8752bbd7eed7600080a26fffffffffffffffffffffffffffffffff168452602084015260408301526060820190565b346102445760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610244576112036132fa565b600073ffffffffffffffffffffffffffffffffffffffff81547fffffffffffffffffffffffff000000000000000000000000000000000000000081168355167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08280a3005b346102445760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261024457602060405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152f35b346102445760a07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610244576004356113128161056f565b602435908160020b82036102445761135173ffffffffffffffffffffffffffffffffffffffff91608093611344610f3b565b6064359160843593613c39565b91604094939451948552602085015215156040840152166060820152f35b346102445760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261024457602073ffffffffffffffffffffffffffffffffffffffff60005416604051908152f35b6113ca366106c0565b6113d59391936132fa565b6113e081841461270f565b60005b83811061141d575061078c907fe4d045717648b4a964b22e91953fd95d48e089e38c87021016e48ddd32387eee9460405194859485612778565b61143061142b828686612716565b61276e565b9061144461143f828589612716565b612755565b1561159d5773ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168073ffffffffffffffffffffffffffffffffffffffff841614611573576040517f095ea7b3000000000000000000000000000000000000000000000000000000006020820190815273ffffffffffffffffffffffffffffffffffffffff9290921660248201526000604480830182905282529182916115006064826102b5565b519082865af161150e61290e565b506115735761156d61154260019373ffffffffffffffffffffffffffffffffffffffff166000526001602052604060002090565b60017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00825416179055565b016113e3565b7f466d7fef0000000000000000000000000000000000000000000000000000000060005260046000fd5b6115f46115cc60019373ffffffffffffffffffffffffffffffffffffffff166000526001602052604060002090565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008154169055565b61156d565b34610244576101c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102445761163236610308565b61163a61058d565b9060c4359060e43567ffffffffffffffff81116102445761165f9036906004016105a5565b939092610104359367ffffffffffffffff8511610244576102409561168b61067f9636906004016105a5565b9061169461038a565b9261014435946116a2611025565b9661018435986101a4359a61293e565b6101207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610244576116e636610436565b60c43567ffffffffffffffff8111610244576117ed6117a76117e38460406117156102409636906004016105a5565b90939060e43594610104356117b061172d8751612d1f565b9161174c835173ffffffffffffffffffffffffffffffffffffffff1690565b998961179e838d9c611775602089015173ffffffffffffffffffffffffffffffffffffffff1690565b9e8f9d602081019d8e91825180611855575b50019e8f91825180611843575b505191519261406c565b50508851612962565b87528751612962565b86526117bb816140e0565b906117d860806117cf606084015160020b90565b92015160020b90565b8651918851936140ec565b9092525284612dd5565b9092919351926040519485947fe93a38a2f007635b024bb3a896c7021e73edc7146c413a63e6b69c337304c698600080a26fffffffffffffffffffffffffffffffff168452602084015260408301526060820190565b61184f90303385613349565b38611794565b61186190303387613349565b38611787565b34610244576101807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610244576118a036610308565b60c43560a43560e4356118b281610380565b6101043592610124359260ff8416840361024457610240956103f56103fa95610144356118df6101643590565b918451996118ec8b612a99565b8a61391a565b34610244576102007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102445761192b36610f59565b6101a435906101e4359061018435906101c43567ffffffffffffffff841161024457610240946119626119739536906004016105a5565b94909361196e82612a99565b613a13565b90604094929451948486957f811d4760f1a92875eb76dbd3dc2359544b2f6a000ba5b78784c0b105b3469bd0600080a285526fffffffffffffffffffffffffffffffff166020850152604084015260608301526080820190565b34610244576101a07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261024457611a0636610436565b60c4359060e435906101043567ffffffffffffffff811161024457611a2f9036906004016105a5565b9093906101443590610124359060ff831683036102445761024096611a5d966101643595610184359761296f565b604080516fffffffffffffffffffffffffffffffff90941684526020840192909252908201529081906060820190565b346102445760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102445773ffffffffffffffffffffffffffffffffffffffff600435611add8161056f565b166000526003602052602060ff604060002054166040519015158152f35b6101807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261024457610240611b81611b3536610f59565b611b7c73ffffffffffffffffffffffffffffffffffffffff82511673ffffffffffffffffffffffffffffffffffffffff60208401511660a08401519060c085015192612d9a565b614374565b90604094929451948486957f07883703ed0e86588a40d76551c92f8a4b329e3bf19765e0e6749473c1a84665600080a285526fffffffffffffffffffffffffffffffff166020850152604084015260608301526080820190565b346102445760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261024457602060405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152f35b346102445760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610244576000611c836132fa565b670de0b6b3a76400006bffffffffffffffffffffffff611ca16129bd565b161015611dd957600435611cb48161056f565b73ffffffffffffffffffffffffffffffffffffffff811615611dd55780611cdd611d1e9261056f565b73ffffffffffffffffffffffffffffffffffffffff167fffffffffffffffffffffffff00000000000000000000000000000000000000006002541617600255565b611d266129bd565b73ffffffffffffffffffffffffffffffffffffffff7fffffffffffffffffffffffff00000000000000000000000000000000000000006002549260a01b169116176002557f42200c2a55e71251cd849a86c7ece1a42ddabecbb489150a136f6c0d239c7a5c611d93612762565b611d9b6129bd565b6040805173ffffffffffffffffffffffffffffffffffffffff9390931683526bffffffffffffffffffffffff91909116602083015290a180f35b5080fd5b80fd5b6101e07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261024457611e1036610f59565b6101843567ffffffffffffffff81116102445761024091611e38611b819236906004016105a5565b90611ee46101a435926101c43592611e4f866140e0565b611ec160a0880195865180611f21575b506117a760c08a0198895180611eed575b5061179e8382611e94885173ffffffffffffffffffffffffffffffffffffffff1690565b8d8d611eb760208c015173ffffffffffffffffffffffffffffffffffffffff1690565b905191519261406c565b90818752611ed3606089015160020b90565b608089015160020b908751926140ec565b90925252614374565b611f1b90611f12602088015173ffffffffffffffffffffffffffffffffffffffff1690565b30903390613349565b38611e70565b611f4390611f12855173ffffffffffffffffffffffffffffffffffffffff1690565b38611e5f565b6102007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261024457611f7d36610f59565b61018435611f8a8161056f565b6101a4356101c43567ffffffffffffffff811161024457611faf9036906004016105a5565b9390916101e4359467ffffffffffffffff861161024457828086936121c761024097611fe26121f59b36906004016105a5565b6000979197916000938a60a089019761201d61200a826109af60c08d519f019e8f5190612845565b8215159381856123e1575b50508261346d565b60025473ffffffffffffffffffffffffffffffffffffffff16916123d0575b5050612061612057604061204e612857565b9a015160020b90565b60020b60408a0152565b8b5173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff8c169b8c8073ffffffffffffffffffffffffffffffffffffffff841603612347575b505050505060208a01976120d8895173ffffffffffffffffffffffffffffffffffffffff1690565b8d73ffffffffffffffffffffffffffffffffffffffff82168c8082036122fa575b945050505050612120610b0a8b5173ffffffffffffffffffffffffffffffffffffffff1690565b146122ea575b87612148610b0a895173ffffffffffffffffffffffffffffffffffffffff1690565b146122d8575b6121b061218d6121728b5173ffffffffffffffffffffffffffffffffffffffff1690565b985173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff166020870190815297610e45565b606089015160020b60808a015160020b90866137bf565b918192855252806122b0575b50505180612288575b50506121e782614374565b949296919790933090613783565b9081612255575b505050604051948486957f07883703ed0e86588a40d76551c92f8a4b329e3bf19765e0e6749473c1a84665600080a285526fffffffffffffffffffffffffffffffff166020850152604084015260608301526080820190565b61227a61012061228094015173ffffffffffffffffffffffffffffffffffffffff1690565b90613580565b3880806121fc565b610d2e6122a9925173ffffffffffffffffffffffffffffffffffffffff1690565b38806121dc565b610d2e6122d1925173ffffffffffffffffffffffffffffffffffffffff1690565b38806121d3565b90506122e43088613783565b9061214e565b506122f53088613783565b612126565b95965061233b95109161233391610ee9918082188502908118911873ffffffffffffffffffffffffffffffffffffffff1660208c015290565b8851886136f6565b903880808d818c6120f9565b6123c59596506123856123bd926123a3926123758673ffffffffffffffffffffffffffffffffffffffff1690565b1194818118860290811892911890565b73ffffffffffffffffffffffffffffffffffffffff1660208d015290565b73ffffffffffffffffffffffffffffffffffffffff168a52565b8751896136f6565b903880808e8c6120b0565b6123da918d613580565b388061203c565b6123ee9130903390613349565b8e81612015565b346102445760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102445773ffffffffffffffffffffffffffffffffffffffff6004356124458161056f565b61244d6132fa565b1680156124bc5773ffffffffffffffffffffffffffffffffffffffff600054827fffffffffffffffffffffffff0000000000000000000000000000000000000000821617600055167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0600080a3005b7f1e4fbdf700000000000000000000000000000000000000000000000000000000600052600060045260246000fd5b346102445760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102445760243560043560443567ffffffffffffffff8111610244576125409036906004016105a5565b9290927f0000000000000000000000000000000000000000000000000000000000000000604051917fcefa779900000000000000000000000000000000000000000000000000000000835260208360048173ffffffffffffffffffffffffffffffffffffffff86165afa9081156126c55761264793600092612690575b506125ca903690886129f9565b6020815191012090603791605593604051927f3d602d80600a3d3981f3363d3d373d3d3d363d73000000000000000000000000845260601b60148401527f5af43d82803e903d91602b57fd5bf3ff00000000000000000000000000000000602884015260601b6038830152604c820152818120606c820152012090565b9061266973ffffffffffffffffffffffffffffffffffffffff8316331461270f565b600083131561267f575061002192309035613349565b915061002192602030910135613349565b6125ca9192506126b79060203d6020116126be575b6126af81836102b5565b8101906129d8565b91906125bd565b503d6126a5565b6129ed565b9796949290916126e79694928951996126e28b612a99565b612f0e565b917f269a3942fe0284ff30ff93f97529fba299f93b8b85221afab5686fdab8bfa84b600080a2565b1561024457565b91908110156127265760051b0190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b3561275f81610380565b90565b60043561275f8161056f565b3561275f8161056f565b9392938260408201604083525260608101919260005b8181106127db575050602080935081830391015282815201919060005b8181106127b85750505090565b90919260208060019286356127cc81610380565b151581520194019291016127ab565b90919260208060019273ffffffffffffffffffffffffffffffffffffffff88356128048161056f565b1681520195019101939291909361278e565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b9190820180921161285257565b612816565b604051906060820182811067ffffffffffffffff8211176102945760405260006040838281528260208201520152565b9295976128a69991949761196e9396996128a087612a99565b8661391a565b939293909192847f811d4760f1a92875eb76dbd3dc2359544b2f6a000ba5b78784c0b105b3469bd0600080a2565b67ffffffffffffffff811161029457601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b3d15612939573d9061291f826128d4565b9161292d60405193846102b5565b82523d6000602084013e565b606090565b919395979b9a6126e79a6126e2929496989a84519e8f61295d81612a99565b61391a565b9190820391821161285257565b91939597612991976111739294969a9984519b61298b8d612a99565b8c61391a565b91939092907fc13e24d2b0a3bacd5d1a7c514125a1e27323abf7c86f6d36597f8752bbd7eed7600080a2565b6024356bffffffffffffffffffffffff811681036102445790565b90816020910312610244575161275f8161056f565b6040513d6000823e3d90fd5b929192612a05826128d4565b91612a1360405193846102b5565b829481845281830111610244578281602093846000960137010152565b73ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000163303612a6f57565b7f2f1ca35a0000000000000000000000000000000000000000000000000000000060005260046000fd5b33600052600360205260ff60406000205416612b2157612aee73ffffffffffffffffffffffffffffffffffffffff917f0000000000000000000000000000000000000000000000000000000000000000614807565b163303612af757565b7fc19f17a90000000000000000000000000000000000000000000000000000000060005260046000fd5b50565b909391612ba690612b358351612d1f565b956fffffffffffffffffffffffffffffffff612b6460208601516fffffffffffffffffffffffffffffffff1690565b16612cbd575b8351875173ffffffffffffffffffffffffffffffffffffffff16602089015173ffffffffffffffffffffffffffffffffffffffff165b91614560565b949085948196612bd785517f0000000000000000000000000000000000000000000000000000000000000000614807565b928281612c93575b505080612c61575b5050506fffffffffffffffffffffffffffffffff612c4d612c3860a0612c2060208701516fffffffffffffffffffffffffffffffff1690565b9401516fffffffffffffffffffffffffffffffff1690565b6fffffffffffffffffffffffffffffffff1690565b911614612c575750565b6103069051614602565b612c8b92612c86602086015173ffffffffffffffffffffffffffffffffffffffff1690565b613645565b388080612be7565b612cb69185612c86885173ffffffffffffffffffffffffffffffffffffffff1690565b3882612bdf565b612ce7847f00000000000000000000000000000000000000000000000000000000000000006144f6565b5050612b6a565b60405190612cfb82610299565b600060a0838281528260208201528260408201528260608201528260808201520152565b612d27612cee565b50612d30612cee565b907f99fbab880000000000000000000000000000000000000000000000000000000060005260045261010081602460007f00000000000000000000000000000000000000000000000000000000000000005afa15612d9657806101006040920182520190565b3d90fd5b90929180612dbe575b505080612dae575050565b61030691610d2e82303384613349565b612dce91610d2e82303384613349565b3880612da3565b90927f0000000000000000000000000000000000000000000000000000000000000000604051937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0840180519063219f5d1781526060600060c47ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc890182885af115612f0457526000519460205190604051906040528095829798602082015190612e866040840151935188614807565b8583829710612ed7575b50505050808210612ea3575b5050505050565b612ec673ffffffffffffffffffffffffffffffffffffffff612ecd961685613835565b0391613580565b3880808080612e9c565b612efb93612ec673ffffffffffffffffffffffffffffffffffffffff8b1685613835565b38808481612e90565b3d6000803e3d6000fd5b95936130d79398979294612f228851612d1f565b96612fb060408a018a6fffffffffffffffffffffffffffffffff612f6860208451936000606082019681885198525201516fffffffffffffffffffffffffffffffff1690565b166132c9575b8b518b612ba06020612f94835173ffffffffffffffffffffffffffffffffffffffff1690565b92015173ffffffffffffffffffffffffffffffffffffffff1690565b90612fb9612857565b94612fd5612fcb60408d015160020b90565b60020b6040880152565b6130008c517f0000000000000000000000000000000000000000000000000000000000000000614807565b9d61301f8c5173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff891673ffffffffffffffffffffffffffffffffffffffff821603613215575b50505050602089015173ffffffffffffffffffffffffffffffffffffffff169073ffffffffffffffffffffffffffffffffffffffff82169473ffffffffffffffffffffffffffffffffffffffff8716860361313d575b5050505050506130cf3073ffffffffffffffffffffffffffffffffffffffff8316613783565b978891613645565b8410613113576fffffffffffffffffffffffffffffffff612c4d612c3860a0612c2060208701516fffffffffffffffffffffffffffffffff1690565b7f5945ea560000000000000000000000000000000000000000000000000000000060005260046000fd5b6131a99573ffffffffffffffffffffffffffffffffffffffff881611926131a49061318a90808a188602808b18911873ffffffffffffffffffffffffffffffffffffffff16602085015290565b73ffffffffffffffffffffffffffffffffffffffff168252565b6136f6565b506131d86131d1610b0a602088015173ffffffffffffffffffffffffffffffffffffffff1690565b3090613783565b82816131e8575b818080806130a9565b61320e918a612c8660208a015173ffffffffffffffffffffffffffffffffffffffff1690565b38826131df565b61326c936132666123a361238573ffffffffffffffffffffffffffffffffffffffff8d166132568673ffffffffffffffffffffffffffffffffffffffff1690565b10948d81188602808f1892911890565b886136f6565b508b866132936131d1610b0a8d5173ffffffffffffffffffffffffffffffffffffffff1690565b8061329f575b80613053565b6132c192612c868d5173ffffffffffffffffffffffffffffffffffffffff1690565b8b8638613299565b6132f38c7f00000000000000000000000000000000000000000000000000000000000000006144f6565b5050612f6e565b73ffffffffffffffffffffffffffffffffffffffff60005416330361331b57565b7f118cdaa7000000000000000000000000000000000000000000000000000000006000523360045260246000fd5b92919073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168073ffffffffffffffffffffffffffffffffffffffff86161480613464575b6133d8575b5073ffffffffffffffffffffffffffffffffffffffff811630036133cf5750610306926146b3565b6103069361465a565b34840361343a5760006004818681947fd0e30db00000000000000000000000000000000000000000000000000000000083525af115610244573073ffffffffffffffffffffffffffffffffffffffff83161461343457386133a7565b50505050565b7fa11a990f0000000000000000000000000000000000000000000000000000000060005260046000fd5b503415156133a2565b90818110613113578061347e575050565b670de0b6b3a7640000820291818115670de0b6b3a7640000838604141702156134dc575090045b60025460a01c106134b257565b7feab9763d0000000000000000000000000000000000000000000000000000000060005260046000fd5b81670de0b6b3a76400007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8184098581108601900392099082600003831692818111156135725783900480600302600218808202600203028082026002030280820260020302808202600203028082026002030280910260020302936001848483030494806000030401921190030217026134a5565b63ae47f7026000526004601cfd5b73ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016908173ffffffffffffffffffffffffffffffffffffffff8216148061363d575b15613631575060006024818080947f2e1a7d4d000000000000000000000000000000000000000000000000000000008252876004525af11561024457600080809338935af11561362357565b63b12d13eb6000526004601cfd5b610306939291506146b3565b5060016135d7565b9290919273ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016918273ffffffffffffffffffffffffffffffffffffffff83161490816136ee575b5015613631575060006024818080947f2e1a7d4d000000000000000000000000000000000000000000000000000000008252876004525af11561024457600080809338935af11561362357565b9050386136a1565b9390919281156000146137395750508261373361275f947f0000000000000000000000000000000000000000000000000000000000000000615608565b906146fe565b61377f939250906131d19173ffffffffffffffffffffffffffffffffffffffff8080602089015116975116948588180280951816936137783086613783565b961861555f565b0390565b6024600080926020947f70a082310000000000000000000000000000000000000000000000000000000083526004525afa156102445760005190565b9161381585856138229398979694986137f8877f0000000000000000000000000000000000000000000000000000000000000000615608565b9973ffffffffffffffffffffffffffffffffffffffff8b16613c39565b50978295899392506146fe565b9160000394858318028092180193180190565b6044601060008093602095601452816034526f095ea7b300000000000000000000000082525af13d15600160005114171615613872576000603452565b633e3f8f736000526004601cfd5b60446010600080936020956014527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff6034526f095ea7b300000000000000000000000082525af13d15600160005114171615613872576000603452565b6010600060449260209582956014526034526f095ea7b300000000000000000000000082525af13d15600160005114171615613872576000603452565b907f00000000000000000000000000000000000000000000000000000000000000006139468382614843565b73ffffffffffffffffffffffffffffffffffffffff163014613a0b5761396c8382614807565b7fe985e9c5000000000000000000000000000000000000000000000000000000006000526004523060245260206000604481845afa15612f04576000516000602452613a0b57600095869560c4958794604051967f7ac2ff7b000000000000000000000000000000000000000000000000000000008852306004890152602488015260448701526064860152608485015260a48401525af115612f0457565b505050505050565b9390613b0e90613b2c613ae5613b4b96613b5a99966101408a015160405190613a3b82610278565b8682526000602083015260006040830152600060608301526080820152805190613a6482612d1f565b91613ade73ffffffffffffffffffffffffffffffffffffffff845116926fffffffffffffffffffffffffffffffff60a073ffffffffffffffffffffffffffffffffffffffff6020880151169601511660208201527f00000000000000000000000000000000000000000000000000000000000000006144f6565b5050614560565b9390927f0000000000000000000000000000000000000000000000000000000000000000614807565b73ffffffffffffffffffffffffffffffffffffffff16610120880152565b613b35866140e0565b606087015160020b608088015160020b916140ec565b60c083015260a0820152614374565b90919293565b9273ffffffffffffffffffffffffffffffffffffffff9192613bc7613bdc968493613baf613b8e8951612d1f565b94613b97612857565b508951988787511699602088019a898c511691614560565b90606086015160020b608087015160020b90876140ec565b60408701526020860152511691511691612dd5565b9192909190565b60405190610120820182811067ffffffffffffffff821117610294576040526000610100838281528260208201528260408201528260608201528260808201528260a08201528260c08201528260e08201520152565b929493919094600095811580614064575b61404f578260020b8160020b9080821291821592614025575b508115614018575b50613fee57843b15613fe057613c7f613be3565b93613c898661487f565b6040870152948591613c9a88615758565b92613ca489615790565b62ffffff1692613cb38a6157c8565b94815260208101978289526060820196888852608083019685885260e08401968752610100840152613ce4906148bb565b90613cee906148bb565b988160a08401528960c084015273ffffffffffffffffffffffffffffffffffffffff82169173ffffffffffffffffffffffffffffffffffffffff8b1697848b8a868a73ffffffffffffffffffffffffffffffffffffffff8b1690613d5194614c16565b9e8f97613d5f928992614c62565b84519983519981519d83519815600014613eab5750508473ffffffffffffffffffffffffffffffffffffffff8b1610613e09575b5050505073ffffffffffffffffffffffffffffffffffffffff86161015613dca575b5050505090613dc49185614ef6565b91030192565b613dc495949b50613dfb9192939850613de290615179565b97613dee858d8b614f4a565b9051620f42400390615348565b910301979091388080613db5565b849f9e9d508897969594613e46613e3f73ffffffffffffffffffffffffffffffffffffffff9f9e9d9c9b51620f424003896152b6565b8c8c6150fe565b9d8e161015613e6c5750505050909180939495969798999a9b9c509b5b38808080613d93565b8f9c9d9e9f94959b613e9e8b809d9e613e948c8e999f899d9e9f908a613dee929b9a9b614f4a565b9003998a97614ef6565b019c8d929a525252613e63565b935080955073ffffffffffffffffffffffffffffffffffffffff8b9e989e9d999d1611613f36575b5050505073ffffffffffffffffffffffffffffffffffffffff86161115613f04575b5050505090613dc49185614f35565b613dc495949b50613f289192939850613f1c90614fb1565b97613dee858d8b614ea8565b910301979091388080613ef5565b849f9e9d508897969594613f73613f6c73ffffffffffffffffffffffffffffffffffffffff9f9e9d9c9b51620f424003896152b6565b8c8c614e0f565b9d8e1610613f985750505050909180939495969798999a9b9c509b5b38808080613ed3565b8f9c9d9e9f94959b613fd38b9c9d613fc8613fbb8e88999f9c9d9e809899614ea8565b8d51620f42400390615348565b900398899487614f35565b019c8d949a525252613f8f565b6301ac05a56000526004601cfd5b7f30673a1b0000000000000000000000000000000000000000000000000000000060005260046000fd5b620d89e891501338613c6b565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff2761813915038613c63565b50505050509050600090600090600090600090565b508315613c4a565b9594919390929561407d858361346d565b614087878461346d565b73ffffffffffffffffffffffffffffffffffffffff6002541691806140cb575b5050816140b6575b5050509190565b816140c393960395613580565b3880806140af565b82816140d993970396613580565b38806140a7565b6140e8612857565b5090565b969487876141605790506141019596506137bf565b9190925b83614139575b8280614115575050565b610d2e602061030693015173ffffffffffffffffffffffffffffffffffffffff1690565b61415b84610d2e835173ffffffffffffffffffffffffffffffffffffffff1690565b61410b565b92909493917f0000000000000000000000000000000000000000000000000000000000000000946141918587615608565b73ffffffffffffffffffffffffffffffffffffffff166141b09061487f565b50916141bb906148bb565b926141c5906148bb565b73ffffffffffffffffffffffffffffffffffffffff169273ffffffffffffffffffffffffffffffffffffffff169173ffffffffffffffffffffffffffffffffffffffff169061421394614c16565b92806020830196875173ffffffffffffffffffffffffffffffffffffffff1695845173ffffffffffffffffffffffffffffffffffffffff16908188180280911873ffffffffffffffffffffffffffffffffffffffff1696306142759089613783565b5018916142819261555f565b30825173ffffffffffffffffffffffffffffffffffffffff16906142a491613783565b30875173ffffffffffffffffffffffffffffffffffffffff16906142c791613783565b916142d28486615608565b94604282013560e81d91603f013560e81d946142ed91615608565b73ffffffffffffffffffffffffffffffffffffffff169361430d94613c39565b5091905061431b92876146fe565b503061432691613783565b50825161434a90309073ffffffffffffffffffffffffffffffffffffffff16613783565b915161436d90309073ffffffffffffffffffffffffffffffffffffffff16613783565b9192614105565b6040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08201805163b5007d1f825290937f000000000000000000000000000000000000000000000000000000000000000093608060006101847ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc840182895af1156144f1576000519460205194604051946060519852604052600060605286938095969761443b61012085015173ffffffffffffffffffffffffffffffffffffffff1690565b9160a08501519060c086015191848183106144a6575b505050808210614462575050505050565b612ec673ffffffffffffffffffffffffffffffffffffffff61449e6020612ecd98015173ffffffffffffffffffffffffffffffffffffffff1690565b951685613835565b6144e9926144c8895173ffffffffffffffffffffffffffffffffffffffff1690565b92612ec673ffffffffffffffffffffffffffffffffffffffff8a1685613835565b388084614451565b3d6000fd5b6040600060a47fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0850193827ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc865197630c49ccbe885201915af115612f0457526000519060205190565b60006084604092969594968351907ffc6f786500000000000000000000000000000000000000000000000000000000825260048201523060248201526fffffffffffffffffffffffffffffffff60448201526fffffffffffffffffffffffffffffffff6064820152827f00000000000000000000000000000000000000000000000000000000000000005af115612f045761072c93600051906020519261406c565b7f42966c6800000000000000000000000000000000000000000000000000000000600052600452600080602481807f00000000000000000000000000000000000000000000000000000000000000005af115612f0457565b601c600060649281946020966040519860605260405260601b602c526f23b872dd000000000000000000000000600c525af13d156001600051141716156146a5576000606052604052565b637939f4246000526004601cfd5b6010600060449260209582956014526034526fa9059cbb00000000000000000000000082525af13d156001600051141716156146f0576000603452565b6390b8ec186000526004601cfd5b9392919091600094826147115750505050565b604091929395507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe06000910195865194606088528351907f128acb0800000000000000000000000000000000000000000000000000000000825230600483015285602483015260448201528473fffd8963efd1fc6a506488495d951d53639afb810273fffd8963efd1fc6a506488495d951d5263988d2518606482015260a060848201528273ffffffffffffffffffffffffffffffffffffffff60c48a51602081018c8160a488019160045afa500193165af160403d141615612f04576000519081602051180218600003925238808080613434565b6024600080926020947f6352211e0000000000000000000000000000000000000000000000000000000083526004525afa15612f045760005190565b6024600080926020947f081812fc0000000000000000000000000000000000000000000000000000000083526004525afa15612f045760005190565b60006004816040937f3850c7bd0000000000000000000000000000000000000000000000000000000082525afa15610244576000519060205190565b60ff81901d80820118620d89e88111614bfe5763ffffffff91600182167001fffcb933bd6fad37aa2d162d1a59400102700100000000000000000000000000000000189160028116614be2575b60048116614bc6575b60088116614baa575b60108116614b8e575b60208116614b72575b60408116614b56575b60808116614b3a575b6101008116614b1e575b6102008116614b02575b6104008116614ae6575b6108008116614aca575b6110008116614aae575b6120008116614a92575b6140008116614a76575b6180008116614a5a575b620100008116614a3e575b620200008116614a23575b620400008116614a08575b62080000166149ef575b6000126149c8575b0160201c90565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff046149c1565b6b048a170391f7dc42444e8fa290910260801c906149b9565b6d2216e584f5fa1ea926041bedfe9890920260801c916149af565b916e5d6af8dedb81196699c329225ee6040260801c916149a4565b916f09aa508b5b7a84e1c677de54f3e99bc90260801c91614999565b916f31be135f97d08fd981231505542fcfa60260801c9161498e565b916f70d869a156d2a1b890bb3df62baf32f70260801c91614984565b916fa9f746462d870fdf8a65dc1f90e061e50260801c9161497a565b916fd097f3bdfd2022b8845ad8f792aa58250260801c91614970565b916fe7159475a2c29b7443b29c7fa6e889d90260801c91614966565b916ff3392b0822b70005940c7a398e4b70f30260801c9161495c565b916ff987a7253ac413176f2b074cf7815e540260801c91614952565b916ffcbe86c7900a88aedcffc83b479aa3a40260801c91614948565b916ffe5dee046a99a2a811c461f1969c30530260801c9161493e565b916fff2ea16466c96a3843ec78b326b528610260801c91614935565b916fff973b41fa98c081472e6896dfb254c00260801c9161492c565b916fffcb9843d60f6159c9db58835c9266440260801c91614923565b916fffe5caca7e10e4e61c3624eaa0941cd00260801c9161491a565b916ffff2e50f5f656932ef12357cf3c7fdcc0260801c91614911565b916ffff97272373d413259a46990580e213a0260801c91614908565b6308c379a0600052602080526101546041526045601cfd5b919391838511614c2a575050505050600090565b828510614c3b575050505050600190565b614c5e93614c4c86614c5593615b49565b90860390615b49565b938203906154b8565b1090565b9091507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff80006000935b614cb1600095604086019383614ca1865160020b90565b61010089015160020b9088615800565b969093614cbd836148bb565b9184159384600014614db057602089015173ffffffffffffffffffffffffffffffffffffffff1693614d17614d028b516fffffffffffffffffffffffffffffffff1690565b958b60808101978460e08a5193015193615a1b565b92919260608d015101965103965b73ffffffffffffffffffffffffffffffffffffffff80841692168203614da1578b91614d5f9160c060a08501519115940151918a8a614c16565b151514614d73575050505050505050505050565b869283614d80848c615b0a565b91031883018a51018a5260208a015203905260608601526080850152614c8a565b50505050505050505050505050565b602089015173ffffffffffffffffffffffffffffffffffffffff16614dfd614de88b516fffffffffffffffffffffffffffffffff1690565b918b60608101938860e0865193015193615a1b565b96919251039560808c01510196614d25565b908215614ea25760601b908083028184820414614e56575b5081049182018092116128525773ffffffffffffffffffffffffffffffffffffffff9180820615159104011690565b8201828110614e2757919250614e6d8282856154b8565b9209614e8c5773ffffffffffffffffffffffffffffffffffffffff1690565b60010180610b0a5763ae47f7026000526004601cfd5b50905090565b918282108284180280808518931893146102445760019060601b92828103614ee773ffffffffffffffffffffffffffffffffffffffff831682876154b8565b94098284061715151691040190565b8181188183100280821893928118911461024457614f31918373ffffffffffffffffffffffffffffffffffffffff831692039060601b6154b8565b0490565b9061275f9291038060ff1d9081011890615b49565b6001916c0100000000000000000000000091038060ff1d90810118614f6f8185615b49565b93091515160190565b8115614f82570490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b80519060208101519160c08201519160e08101519081620f4240036060820151938060601b8688840282620f42400204870191048103958611156150f0578260a0850191825161500091615b49565b9461500b8a85615b49565b9060800151019151620f4240029061502291614f78565b61502c9083615b49565b810396615038916153f7565b93020401039060011b9160011b8202818002016150e0908070ffffffffffffffffffffffffffffffffff1060071b81811c68ffffffffffffffffff1060061b1781811c64ffffffffff1060051b1781811c62ffffff1060041b1760b56201000083831c019160011c1b0260121c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8080920410900390565b0160601b04818110908218021890565b63202368086000526004601cfd5b919073ffffffffffffffffffffffffffffffffffffffff918060a01c156000146151695760601b04915b1690810180911161285257740100000000000000000000000000000000000000008110156102445773ffffffffffffffffffffffffffffffffffffffff1690565b90615173916153f7565b91615128565b80519060208101519160c08201519060e083015180620f424003928260601b90868204606087015101928760a088016151de60806151d06151ca8b6151bf86518c615b49565b96620f424002614f78565b8a615b49565b9a0151998a01915188615b49565b8103988911156150f0576152a6966151f7858a936153f7565b930204900303940290620f42400204900360011b9260011b8302828002018070ffffffffffffffffffffffffffffffffff1060071b81811c68ffffffffffffffffff1060061b1781811c64ffffffffff1060051b1781811c62ffffff1060041b1760b56201000083831c019160011c1b0260121c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8080920410900390565b0160601b05818111908218021890565b81810291620f4240818385041483151702156152d7575050620f4240900490565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff620f42409284098481108501900392099080620f4240111561357257828211900360fa1b910360061c177fde8f6cefed634549b62c77574f722e1ac57e23f24d8fd5cb790fb65668c261390290565b90620f424082029181620f42408285041482151702156153685750900490565b81620f42407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81840985811086019003920990826000038316928181111561357257839004806003026002188082026002030280820260020302808202600203028082026002030280820260020302809102600203029360018484830304948060000304019211900302170290565b908160601b91816c0100000000000000000000000082850414821517021561541f5750900490565b816c010000000000000000000000007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81840985811086019003920990826000038316928181111561357257839004806003026002188082026002030280820260020302808202600203028082026002030280820260020302809102600203029360018484830304948060000304019211900302170290565b818102929181158285048214178302156154d3575050900490565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8492840985811086019003920990826000038316928181111561357257839004806003026002188082026002030280820260020302808202600203028082026002030280820260020302809102600203029360018484830304948060000304019211900302170290565b9190604681013560601c917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff92605a83013560601c91018160005260016020526155b060ff6040600020541615151590565b6155de576000928380936155c48789613880565b83606e604051940184375af115612f045761030691613835565b7f14e99d060000000000000000000000000000000000000000000000000000000060005260046000fd5b604051917fcefa779900000000000000000000000000000000000000000000000000000000835260208360048173ffffffffffffffffffffffffffffffffffffffff86165afa9081156126c55761275f93600092615737575b506040516040602082019273ffffffffffffffffffffffffffffffffffffffff815116845273ffffffffffffffffffffffffffffffffffffffff60208201511682840152015160020b6060820152606081526156be6080826102b5565b51902090603791605593604051927f3d602d80600a3d3981f3363d3d373d3d3d363d73000000000000000000000000845260601b60148401527f5af43d82803e903d91602b57fd5bf3ff00000000000000000000000000000000602884015260601b6038830152604c820152818120606c820152012090565b61575191925060203d6020116126be576126af81836102b5565b9038615661565b60006004816020937f1a6865020000000000000000000000000000000000000000000000000000000082525afa156102445760005190565b60006004816020937fddca3f430000000000000000000000000000000000000000000000000000000082525afa156102445760005190565b60006004816020937fd0c93a7c0000000000000000000000000000000000000000000000000000000082525afa156102445760005190565b9192909493948360008183071291050360009160001461594457600881901d915060ff169390809560010b8160010b1460001461593457505b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600282951b0116905b81156158f857507f0706060506020504060203020504030106050205030304010505030400000000601f6f8421084210842108cc6318c6db6d54be6fffffffffffffffffffffffffffffffff841160071b84811c67ffffffffffffffff1060061b1784811c63ffffffff1060051b1784811c61ffff1060041b1784811c60ff1060031b1793841c1c161a175b8360081b010292565b925050917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0160010b9161592c8383615b97565b918290615863565b61593f915082615b97565b615839565b600101600281900b60081d9060ff169490809660010b8160010b14600014615a0a5750905b600182951b900316905b81156159ed57506159e89080600003167e1f0d1e100c1d070f090b19131c1706010e11080a1a141802121b1503160405601f826fffffffffffffffffffffffffffffffff1060071b83811c67ffffffffffffffff1060061b1783811c63ffffffff1060051b1792831c63d76453e004161a1790565b6158ef565b9250509160010160010b91615a028383615b97565b918290615973565b615a15915083615b97565b90615969565b919094929473ffffffffffffffffffffffffffffffffffffffff811673ffffffffffffffffffffffffffffffffffffffff8416101594620f42400390615a6182886152b6565b8615615af957615a72848684614ea8565b975b888210615ac2575050958691620f4240615a8f8282856154b8565b9209615ab0575b945b15615aa7579161275f92614f35565b61275f92614ef6565b60019150018015613572578590615a96565b9697509150508215821517610244578515615ae957615ae2908284614e0f565b8095615a98565b615af49082846150fe565b615ae2565b615b04848387614f4a565b97615a74565b6024600080926040947ff30dba9300000000000000000000000000000000000000000000000000000000835260020b6004525afa156102445760205190565b818102917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff910981811082019003806c0100000000000000000000000011156135725760a01b9060601c1790565b6024600080926020947f5339c29600000000000000000000000000000000000000000000000000000000835260010b6004525afa15610244576000519056fea164736f6c634300081a000a"; + +type SlipStreamAutomanConstructorParams = + | [signer?: Signer] + | ConstructorParameters; + +const isSuperArgs = ( + xs: SlipStreamAutomanConstructorParams +): xs is ConstructorParameters => xs.length > 1; + +export class SlipStreamAutoman__factory extends ContractFactory { + constructor(...args: SlipStreamAutomanConstructorParams) { + if (isSuperArgs(args)) { + super(...args); + } else { + super(_abi, _bytecode, args[0]); + } + } + + override deploy( + nonfungiblePositionManager: string, + owner_: string, + overrides?: PayableOverrides & { from?: string } + ): Promise { + return super.deploy( + nonfungiblePositionManager, + owner_, + overrides || {} + ) as Promise; + } + override getDeployTransaction( + nonfungiblePositionManager: string, + owner_: string, + overrides?: PayableOverrides & { from?: string } + ): TransactionRequest { + return super.getDeployTransaction( + nonfungiblePositionManager, + owner_, + overrides || {} + ); + } + override attach(address: string): SlipStreamAutoman { + return super.attach(address) as SlipStreamAutoman; + } + override connect(signer: Signer): SlipStreamAutoman__factory { + return super.connect(signer) as SlipStreamAutoman__factory; + } + + static readonly bytecode = _bytecode; + static readonly abi = _abi; + static createInterface(): SlipStreamAutomanInterface { + return new utils.Interface(_abi) as SlipStreamAutomanInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): SlipStreamAutoman { + return new Contract(address, _abi, signerOrProvider) as SlipStreamAutoman; + } +} diff --git a/src/typechain-typesV4/factories/src/SlipStreamOptimalSwapRouter__factory.ts b/src/typechain-typesV4/factories/src/SlipStreamOptimalSwapRouter__factory.ts new file mode 100644 index 00000000..3008f0aa --- /dev/null +++ b/src/typechain-typesV4/factories/src/SlipStreamOptimalSwapRouter__factory.ts @@ -0,0 +1,321 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import { + Signer, + utils, + Contract, + ContractFactory, + PayableOverrides, +} from "ethers"; +import type { Provider, TransactionRequest } from "@ethersproject/providers"; +import type { + SlipStreamOptimalSwapRouter, + SlipStreamOptimalSwapRouterInterface, +} from "../../src/SlipStreamOptimalSwapRouter"; + +const _abi = [ + { + inputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "npm", + type: "address", + }, + { + internalType: "address", + name: "owner_", + type: "address", + }, + ], + stateMutability: "payable", + type: "constructor", + }, + { + inputs: [], + name: "InvalidRouter", + type: "error", + }, + { + inputs: [], + name: "Invalid_Tick_Range", + type: "error", + }, + { + inputs: [], + name: "MismatchETH", + type: "error", + }, + { + inputs: [], + name: "NotAllowlistedRouter", + type: "error", + }, + { + inputs: [], + name: "NotWETH9", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "OwnableInvalidOwner", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "account", + type: "address", + }, + ], + name: "OwnableUnauthorizedAccount", + type: "error", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "previousOwner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "OwnershipTransferred", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "SetAllowlistedRouters", + type: "event", + }, + { + stateMutability: "nonpayable", + type: "fallback", + }, + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "factory", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + name: "isAllowListedRouter", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "owner", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "renounceOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setAllowlistedRouters", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "transferOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "int256", + name: "amount0Delta", + type: "int256", + }, + { + internalType: "int256", + name: "amount1Delta", + type: "int256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "uniswapV3SwapCallback", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + stateMutability: "payable", + type: "receive", + }, +] as const; + +const _bytecode = + "0x60e080604052604081612ba6803803809161001a82856101eb565b83398101031261017b5780516001600160a01b0381169182820361017b576001600160a01b039061004d90602001610224565b169081156101d557600080546001600160a01b031981168417825560405193916001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09080a36080526312a9293f60e21b8152602081600481855afa90811561018857600091610194575b506001600160a01b031660a05260405163c45a015560e01b815290602090829060049082905afa90811561018857600091610149575b5060c05260405161296d908161023982396080518181816102a70152610453015260a05181818161019c01528181610bbe0152610e53015260c05181818161063701528181610a220152610d140152f35b90506020813d602011610180575b81610164602093836101eb565b8101031261017b5761017590610224565b386100f8565b600080fd5b3d9150610157565b6040513d6000823e3d90fd5b90506020813d6020116101cd575b816101af602093836101eb565b8101031261017b576004916101c5602092610224565b9150916100c2565b3d91506101a2565b631e4fbdf760e01b600052600060045260246000fd5b601f909101601f19168101906001600160401b0382119082101761020e57604052565b634e487b7160e01b600052604160045260246000fd5b51906001600160a01b038216820361017b5756fe60806040526004361015610030575b3615610028573461002357610021610c10565b005b600080fd5b610021610ba7565b60003560e01c80634095c646146100c05780634aa4a4fc146100bb578063715018a6146100b65780637f1e9ef6146100b15780638da5cb5b146100ac57806391f6e9b2146100a7578063c45a0155146100a2578063f2fde38b1461009d5763fa461e330361000e57610751565b61065b565b6105ec565b61034e565b6102cb565b61025c565b6101c0565b610151565b6100e3565b73ffffffffffffffffffffffffffffffffffffffff81160361002357565b346100235760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126100235773ffffffffffffffffffffffffffffffffffffffff600435610133816100c5565b166000526001602052602060ff604060002054166040519015158152f35b346100235760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261002357602060405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152f35b346100235760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610023576101f7610dea565b600073ffffffffffffffffffffffffffffffffffffffff81547fffffffffffffffffffffffff000000000000000000000000000000000000000081168355167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08280a3005b346100235760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261002357602060405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152f35b346100235760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261002357602073ffffffffffffffffffffffffffffffffffffffff60005416604051908152f35b9181601f840112156100235782359167ffffffffffffffff8311610023576020808501948460051b01011161002357565b60407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126100235760043567ffffffffffffffff81116100235761039890369060040161031d565b60243567ffffffffffffffff8111610023576103b890369060040161031d565b6103c3939193610dea565b6103ce8184146107d1565b60005b838110610410575061040b907fe4d045717648b4a964b22e91953fd95d48e089e38c87021016e48ddd32387eee9460405194859485610928565b0390a1005b61042361041e8286866107d8565b610817565b906104376104328285896107d8565b61082e565b156105905773ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168073ffffffffffffffffffffffffffffffffffffffff841614610566576040517f095ea7b3000000000000000000000000000000000000000000000000000000006020820190815273ffffffffffffffffffffffffffffffffffffffff9290921660248201526000604480830182905282529182916104f3606482610867565b519082865af16105016108f8565b506105665761056061053560019373ffffffffffffffffffffffffffffffffffffffff166000526001602052604060002090565b60017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00825416179055565b016103d1565b7f466d7fef0000000000000000000000000000000000000000000000000000000060005260046000fd5b6105e76105bf60019373ffffffffffffffffffffffffffffffffffffffff166000526001602052604060002090565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008154169055565b610560565b346100235760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261002357602060405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152f35b346100235760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126100235773ffffffffffffffffffffffffffffffffffffffff6004356106ab816100c5565b6106b3610dea565b1680156107225773ffffffffffffffffffffffffffffffffffffffff600054827fffffffffffffffffffffffff0000000000000000000000000000000000000000821617600055167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0600080a3005b7f1e4fbdf700000000000000000000000000000000000000000000000000000000600052600060045260246000fd5b346100235760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126100235760443560243560043567ffffffffffffffff831161002357366023840112156100235782600401359167ffffffffffffffff8311610023573660248486010111610023576024610021940191610a1e565b1561002357565b91908110156107e85760051b0190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b35610821816100c5565b90565b8015150361002357565b3561082181610824565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff8211176108a857604052565b610838565b604051906108bc606083610867565b565b67ffffffffffffffff81116108a857601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b3d15610923573d90610909826108be565b916109176040519384610867565b82523d6000602084013e565b606090565b9392938260408201604083525260608101919260005b81811061098b575050602080935081830391015282815201919060005b8181106109685750505090565b909192602080600192863561097c81610824565b1515815201940192910161095b565b90919260208060019273ffffffffffffffffffffffffffffffffffffffff88356109b4816100c5565b1681520195019101939291909361093e565b908160209103126100235751610821816100c5565b6040513d6000823e3d90fd5b9291926109f3826108be565b91610a016040519384610867565b829481845281830111610023578281602093846000960137010152565b91927f0000000000000000000000000000000000000000000000000000000000000000604051917fcefa779900000000000000000000000000000000000000000000000000000000835260208360048173ffffffffffffffffffffffffffffffffffffffff86165afa908115610ba257610b2493600092610b6d575b50610aa7903690886109e7565b6020815191012090603791605593604051927f3d602d80600a3d3981f3363d3d373d3d3d363d73000000000000000000000000845260601b60148401527f5af43d82803e903d91602b57fd5bf3ff00000000000000000000000000000000602884015260601b6038830152604c820152818120606c820152012090565b90610b4673ffffffffffffffffffffffffffffffffffffffff831633146107d1565b6000831315610b5c57506108bc92309035610e39565b91506108bc92602030910135610e39565b610aa7919250610b949060203d602011610b9b575b610b8c8183610867565b8101906109c6565b9190610a9a565b503d610b82565b6109db565b73ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000163303610be657565b7f2f1ca35a0000000000000000000000000000000000000000000000000000000060005260046000fd5b60003560601c60143560601c9060313560f81c9060323560601c7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa63601906000808587861802871893610c84610c7c3373ffffffffffffffffffffffffffffffffffffffff8816610f5d565b303388610f99565b610c8e8486610ff2565b60405181605a82378260463560601c5af115610de057610cad9161105d565b610cb73082610f5d565b610cc13085610f5d565b90610cca6108ad565b73ffffffffffffffffffffffffffffffffffffffff841681529073ffffffffffffffffffffffffffffffffffffffff8616602083015260283560e81d60020b6040830152610d38827f0000000000000000000000000000000000000000000000000000000000000000611677565b9415610dc757610d88610d7b82610d4f338a610f5d565b8601905b602e3560e81d602b3560e81d73ffffffffffffffffffffffffffffffffffffffff8b166110f0565b5097829589939250611523565b916000039485831802809218019318019180610db5575b505080610daa575050565b6108bc91339061162c565b610dc091339061162c565b3880610d9f565b610d88610d7b610dd73387610f5d565b83018590610d53565b3d6000803e3d6000fd5b73ffffffffffffffffffffffffffffffffffffffff600054163303610e0b57565b7f118cdaa7000000000000000000000000000000000000000000000000000000006000523360045260246000fd5b92919073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168073ffffffffffffffffffffffffffffffffffffffff86161480610f54575b610ec8575b5073ffffffffffffffffffffffffffffffffffffffff81163003610ebf57506108bc9261162c565b6108bc93610f99565b348403610f2a5760006004818681947fd0e30db00000000000000000000000000000000000000000000000000000000083525af115610023573073ffffffffffffffffffffffffffffffffffffffff831614610f245738610e97565b50505050565b7fa11a990f0000000000000000000000000000000000000000000000000000000060005260046000fd5b50341515610e92565b6024600080926020947f70a082310000000000000000000000000000000000000000000000000000000083526004525afa156100235760005190565b601c600060649281946020966040519860605260405260601b602c526f23b872dd000000000000000000000000600c525af13d15600160005114171615610fe4576000606052604052565b637939f4246000526004601cfd5b60446010600080936020956014527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff6034526f095ea7b300000000000000000000000082525af13d1560016000511417161561104f576000603452565b633e3f8f736000526004601cfd5b6044601060008093602095601452816034526f095ea7b300000000000000000000000082525af13d1560016000511417161561104f576000603452565b60405190610120820182811067ffffffffffffffff8211176108a8576040526000610100838281528260208201528260408201528260608201528260808201528260a08201528260c08201528260e08201520152565b92949391909460009581158061151b575b611506578260020b8160020b90808212918215926114dc575b5081156114cf575b506114a557843b156114975761113661109a565b93611140866117c7565b604087015294859161115188612239565b9261115b89612271565b62ffffff169261116a8a6122a9565b94815260208101978289526060820196888852608083019685885260e0840196875261010084015261119b90611803565b906111a590611803565b988160a08401528960c084015273ffffffffffffffffffffffffffffffffffffffff82169173ffffffffffffffffffffffffffffffffffffffff8b1697848b8a868a73ffffffffffffffffffffffffffffffffffffffff8b169061120894611b5e565b9e8f97611216928992611baa565b84519983519981519d835198156000146113625750508473ffffffffffffffffffffffffffffffffffffffff8b16106112c0575b5050505073ffffffffffffffffffffffffffffffffffffffff86161015611281575b505050509061127b9185611e7b565b91030192565b61127b95949b506112b29192939850611299906120fc565b976112a5858d8b611ecf565b9051620f424003906126bc565b91030197909138808061126c565b849f9e9d5088979695946112fd6112f673ffffffffffffffffffffffffffffffffffffffff9f9e9d9c9b51620f4240038961262a565b8c8c612083565b9d8e1610156113235750505050909180939495969798999a9b9c509b5b3880808061124a565b8f9c9d9e9f94959b6113558b809d9e61134b8c8e999f899d9e9f908a6112a5929b9a9b611ecf565b9003998a97611e7b565b019c8d929a52525261131a565b935080955073ffffffffffffffffffffffffffffffffffffffff8b9e989e9d999d16116113ed575b5050505073ffffffffffffffffffffffffffffffffffffffff861611156113bb575b505050509061127b9185611eba565b61127b95949b506113df91929398506113d390611f36565b976112a5858d8b611e2d565b9103019790913880806113ac565b849f9e9d50889796959461142a61142373ffffffffffffffffffffffffffffffffffffffff9f9e9d9c9b51620f4240038961262a565b8c8c611d93565b9d8e161061144f5750505050909180939495969798999a9b9c509b5b3880808061138a565b8f9c9d9e9f94959b61148a8b9c9d61147f6114728e88999f9c9d9e809899611e2d565b8d51620f424003906126bc565b900398899487611eba565b019c8d949a525252611446565b6301ac05a56000526004601cfd5b7f30673a1b0000000000000000000000000000000000000000000000000000000060005260046000fd5b620d89e891501338611122565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff276181391503861111a565b50505050509050600090600090600090600090565b508315611101565b9392919091600094826115365750505050565b604091929395507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe06000910195865194606088528351907f128acb0800000000000000000000000000000000000000000000000000000000825230600483015285602483015260448201528473fffd8963efd1fc6a506488495d951d53639afb810273fffd8963efd1fc6a506488495d951d5263988d2518606482015260a060848201528273ffffffffffffffffffffffffffffffffffffffff60c48a51602081018c8160a488019160045afa500193165af160403d141615610de0576000519081602051180218600003925238808080610f24565b6010600060449260209582956014526034526fa9059cbb00000000000000000000000082525af13d15600160005114171615611669576000603452565b6390b8ec186000526004601cfd5b604051917fcefa779900000000000000000000000000000000000000000000000000000000835260208360048173ffffffffffffffffffffffffffffffffffffffff86165afa908115610ba257610821936000926117a6575b506040516040602082019273ffffffffffffffffffffffffffffffffffffffff815116845273ffffffffffffffffffffffffffffffffffffffff60208201511682840152015160020b60608201526060815261172d608082610867565b51902090603791605593604051927f3d602d80600a3d3981f3363d3d373d3d3d363d73000000000000000000000000845260601b60148401527f5af43d82803e903d91602b57fd5bf3ff00000000000000000000000000000000602884015260601b6038830152604c820152818120606c820152012090565b6117c091925060203d602011610b9b57610b8c8183610867565b90386116d0565b60006004816040937f3850c7bd0000000000000000000000000000000000000000000000000000000082525afa15610023576000519060205190565b60ff81901d80820118620d89e88111611b465763ffffffff91600182167001fffcb933bd6fad37aa2d162d1a59400102700100000000000000000000000000000000189160028116611b2a575b60048116611b0e575b60088116611af2575b60108116611ad6575b60208116611aba575b60408116611a9e575b60808116611a82575b6101008116611a66575b6102008116611a4a575b6104008116611a2e575b6108008116611a12575b61100081166119f6575b61200081166119da575b61400081166119be575b61800081166119a2575b620100008116611986575b62020000811661196b575b620400008116611950575b6208000016611937575b600012611910575b0160201c90565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04611909565b6b048a170391f7dc42444e8fa290910260801c90611901565b6d2216e584f5fa1ea926041bedfe9890920260801c916118f7565b916e5d6af8dedb81196699c329225ee6040260801c916118ec565b916f09aa508b5b7a84e1c677de54f3e99bc90260801c916118e1565b916f31be135f97d08fd981231505542fcfa60260801c916118d6565b916f70d869a156d2a1b890bb3df62baf32f70260801c916118cc565b916fa9f746462d870fdf8a65dc1f90e061e50260801c916118c2565b916fd097f3bdfd2022b8845ad8f792aa58250260801c916118b8565b916fe7159475a2c29b7443b29c7fa6e889d90260801c916118ae565b916ff3392b0822b70005940c7a398e4b70f30260801c916118a4565b916ff987a7253ac413176f2b074cf7815e540260801c9161189a565b916ffcbe86c7900a88aedcffc83b479aa3a40260801c91611890565b916ffe5dee046a99a2a811c461f1969c30530260801c91611886565b916fff2ea16466c96a3843ec78b326b528610260801c9161187d565b916fff973b41fa98c081472e6896dfb254c00260801c91611874565b916fffcb9843d60f6159c9db58835c9266440260801c9161186b565b916fffe5caca7e10e4e61c3624eaa0941cd00260801c91611862565b916ffff2e50f5f656932ef12357cf3c7fdcc0260801c91611859565b916ffff97272373d413259a46990580e213a0260801c91611850565b6308c379a0600052602080526101546041526045601cfd5b919391838511611b72575050505050600090565b828510611b83575050505050600190565b611ba693611b9486611b9d936128d3565b908603906128d3565b9382039061282c565b1090565b9091507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff80006000935b611bf9600095604086019383611be9865160020b90565b61010089015160020b90886122e1565b969093611c0583611803565b9184159384600014611cf857602089015173ffffffffffffffffffffffffffffffffffffffff1693611c5f611c4a8b516fffffffffffffffffffffffffffffffff1690565b958b60808101978460e08a51930151936124fc565b92919260608d015101965103965b73ffffffffffffffffffffffffffffffffffffffff80841692168203611ce9578b91611ca79160c060a08501519115940151918a8a611b5e565b151514611cbb575050505050505050505050565b869283611cc8848c6125eb565b91031883018a51018a5260208a015203905260608601526080850152611bd2565b50505050505050505050505050565b602089015173ffffffffffffffffffffffffffffffffffffffff16611d45611d308b516fffffffffffffffffffffffffffffffff1690565b918b60608101938860e08651930151936124fc565b96919251039560808c01510196611c6d565b91908201809211611d6457565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b91908115611e285760601b918082028183820414611ddb575b508291611dcf9173ffffffffffffffffffffffffffffffffffffffff9404611d57565b80820615159104011690565b8301838110611dac579150611df182828561282c565b9209611e11575b73ffffffffffffffffffffffffffffffffffffffff1690565b60010180611df8575b63ae47f7026000526004601cfd5b505090565b918282108284180280808518931893146100235760019060601b92828103611e6c73ffffffffffffffffffffffffffffffffffffffff8316828761282c565b94098284061715151691040190565b8181188183100280821893928118911461002357611eb6918373ffffffffffffffffffffffffffffffffffffffff831692039060601b61282c565b0490565b906108219291038060ff1d90810118906128d3565b6001916c0100000000000000000000000091038060ff1d90810118611ef481856128d3565b93091515160190565b8115611f07570490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b80519060208101519160c08201519160e08101519081620f4240036060820151938060601b8688840282620f4240020487019104810395861115612075578260a08501918251611f85916128d3565b94611f908a856128d3565b9060800151019151620f42400290611fa791611efd565b611fb190836128d3565b810396611fbd9161276b565b93020401039060011b9160011b820281800201612065908070ffffffffffffffffffffffffffffffffff1060071b81811c68ffffffffffffffffff1060061b1781811c64ffffffffff1060051b1781811c62ffffff1060041b1760b56201000083831c019160011c1b0260121c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8080920410900390565b0160601b04818110908218021890565b63202368086000526004601cfd5b9073ffffffffffffffffffffffffffffffffffffffff906120b6938060a01c156000146120ec5760601b04915b16611d57565b740100000000000000000000000000000000000000008110156100235773ffffffffffffffffffffffffffffffffffffffff1690565b906120f69161276b565b916120b0565b80519060208101519160c08201519060e083015180620f424003928260601b90868204606087015101928760a08801612161608061215361214d8b61214286518c6128d3565b96620f424002611efd565b8a6128d3565b9a0151998a019151886128d3565b810398891115612075576122299661217a858a9361276b565b930204900303940290620f42400204900360011b9260011b8302828002018070ffffffffffffffffffffffffffffffffff1060071b81811c68ffffffffffffffffff1060061b1781811c64ffffffffff1060051b1781811c62ffffff1060041b1760b56201000083831c019160011c1b0260121c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8080920410900390565b0160601b05818111908218021890565b60006004816020937f1a6865020000000000000000000000000000000000000000000000000000000082525afa156100235760005190565b60006004816020937fddca3f430000000000000000000000000000000000000000000000000000000082525afa156100235760005190565b60006004816020937fd0c93a7c0000000000000000000000000000000000000000000000000000000082525afa156100235760005190565b9192909493948360008183071291050360009160001461242557600881901d915060ff169390809560010b8160010b1460001461241557505b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600282951b0116905b81156123d957507f0706060506020504060203020504030106050205030304010505030400000000601f6f8421084210842108cc6318c6db6d54be6fffffffffffffffffffffffffffffffff841160071b84811c67ffffffffffffffff1060061b1784811c63ffffffff1060051b1784811c61ffff1060041b1784811c60ff1060031b1793841c1c161a175b8360081b010292565b925050917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0160010b9161240d8383612921565b918290612344565b612420915082612921565b61231a565b600101600281900b60081d9060ff169490809660010b8160010b146000146124eb5750905b600182951b900316905b81156124ce57506124c99080600003167e1f0d1e100c1d070f090b19131c1706010e11080a1a141802121b1503160405601f826fffffffffffffffffffffffffffffffff1060071b83811c67ffffffffffffffff1060061b1783811c63ffffffff1060051b1792831c63d76453e004161a1790565b6123d0565b9250509160010160010b916124e38383612921565b918290612454565b6124f6915083612921565b9061244a565b919094929473ffffffffffffffffffffffffffffffffffffffff811673ffffffffffffffffffffffffffffffffffffffff8416101594620f42400390612542828861262a565b86156125da57612553848684611e2d565b975b8882106125a3575050958691620f424061257082828561282c565b9209612591575b945b15612588579161082192611eba565b61082192611e7b565b60019150018015611e1a578590612577565b96975091505082158215176100235785156125ca576125c3908284611d93565b8095612579565b6125d5908284612083565b6125c3565b6125e5848387611ecf565b97612555565b6024600080926040947ff30dba9300000000000000000000000000000000000000000000000000000000835260020b6004525afa156100235760205190565b81810291620f42408183850414831517021561264b575050620f4240900490565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff620f42409284098481108501900392099080620f42401115611e1a57828211900360fa1b910360061c177fde8f6cefed634549b62c77574f722e1ac57e23f24d8fd5cb790fb65668c261390290565b90620f424082029181620f42408285041482151702156126dc5750900490565b81620f42407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff818409858110860190039209908260000383169281811115611e1a57839004806003026002188082026002030280820260020302808202600203028082026002030280820260020302809102600203029360018484830304948060000304019211900302170290565b908160601b91816c010000000000000000000000008285041482151702156127935750900490565b816c010000000000000000000000007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff818409858110860190039209908260000383169281811115611e1a57839004806003026002188082026002030280820260020302808202600203028082026002030280820260020302809102600203029360018484830304948060000304019211900302170290565b81810292918115828504821417830215612847575050900490565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff84928409858110860190039209908260000383169281811115611e1a57839004806003026002188082026002030280820260020302808202600203028082026002030280820260020302809102600203029360018484830304948060000304019211900302170290565b818102917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff910981811082019003806c010000000000000000000000001115611e1a5760a01b9060601c1790565b6024600080926020947f5339c29600000000000000000000000000000000000000000000000000000000835260010b6004525afa15610023576000519056fea164736f6c634300081a000a"; + +type SlipStreamOptimalSwapRouterConstructorParams = + | [signer?: Signer] + | ConstructorParameters; + +const isSuperArgs = ( + xs: SlipStreamOptimalSwapRouterConstructorParams +): xs is ConstructorParameters => xs.length > 1; + +export class SlipStreamOptimalSwapRouter__factory extends ContractFactory { + constructor(...args: SlipStreamOptimalSwapRouterConstructorParams) { + if (isSuperArgs(args)) { + super(...args); + } else { + super(_abi, _bytecode, args[0]); + } + } + + override deploy( + npm: string, + owner_: string, + overrides?: PayableOverrides & { from?: string } + ): Promise { + return super.deploy( + npm, + owner_, + overrides || {} + ) as Promise; + } + override getDeployTransaction( + npm: string, + owner_: string, + overrides?: PayableOverrides & { from?: string } + ): TransactionRequest { + return super.getDeployTransaction(npm, owner_, overrides || {}); + } + override attach(address: string): SlipStreamOptimalSwapRouter { + return super.attach(address) as SlipStreamOptimalSwapRouter; + } + override connect(signer: Signer): SlipStreamOptimalSwapRouter__factory { + return super.connect(signer) as SlipStreamOptimalSwapRouter__factory; + } + + static readonly bytecode = _bytecode; + static readonly abi = _abi; + static createInterface(): SlipStreamOptimalSwapRouterInterface { + return new utils.Interface(_abi) as SlipStreamOptimalSwapRouterInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): SlipStreamOptimalSwapRouter { + return new Contract( + address, + _abi, + signerOrProvider + ) as SlipStreamOptimalSwapRouter; + } +} diff --git a/src/typechain-typesV4/factories/src/UniV3Automan__factory.ts b/src/typechain-typesV4/factories/src/UniV3Automan__factory.ts new file mode 100644 index 00000000..89f1b205 --- /dev/null +++ b/src/typechain-typesV4/factories/src/UniV3Automan__factory.ts @@ -0,0 +1,1845 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import { + Signer, + utils, + Contract, + ContractFactory, + PayableOverrides, +} from "ethers"; +import type { Provider, TransactionRequest } from "@ethersproject/providers"; +import type { + UniV3Automan, + UniV3AutomanInterface, +} from "../../src/UniV3Automan"; + +const _abi = [ + { + inputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "nonfungiblePositionManager", + type: "address", + }, + { + internalType: "address", + name: "owner_", + type: "address", + }, + ], + stateMutability: "payable", + type: "constructor", + }, + { + inputs: [], + name: "FeeLimitExceeded", + type: "error", + }, + { + inputs: [], + name: "InsufficientAmount", + type: "error", + }, + { + inputs: [], + name: "InvalidRouter", + type: "error", + }, + { + inputs: [], + name: "Invalid_Tick_Range", + type: "error", + }, + { + inputs: [], + name: "MismatchETH", + type: "error", + }, + { + inputs: [], + name: "NotAllowlistedRouter", + type: "error", + }, + { + inputs: [], + name: "NotApproved", + type: "error", + }, + { + inputs: [], + name: "NotWETH9", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "OwnableInvalidOwner", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "account", + type: "address", + }, + ], + name: "OwnableUnauthorizedAccount", + type: "error", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "controllers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "ControllersSet", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "DecreaseLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address", + name: "feeCollector", + type: "address", + }, + { + indexed: false, + internalType: "uint96", + name: "feeLimitPips", + type: "uint96", + }, + ], + name: "FeeConfigSet", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "IncreaseLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Mint", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "previousOwner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "OwnershipTransferred", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Rebalance", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Reinvest", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "RemoveLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "SetAllowlistedRouters", + type: "event", + }, + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + ], + name: "decreaseLiquidity", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "decreaseLiquidity", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenOut", + type: "address", + }, + { + internalType: "uint256", + name: "tokenOutMin", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + ], + name: "decreaseLiquidityToTokenOut", + outputs: [ + { + internalType: "uint256", + name: "tokenOutAmount", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenOut", + type: "address", + }, + { + internalType: "uint256", + name: "tokenOutMin", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "decreaseLiquidityToTokenOut", + outputs: [ + { + internalType: "uint256", + name: "tokenOutAmount", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [], + name: "factory", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "feeConfig", + outputs: [ + { + internalType: "address", + name: "feeCollector", + type: "address", + }, + { + internalType: "uint96", + name: "feeLimitPips", + type: "uint96", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "V3PoolCallee", + name: "pool", + type: "address", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + ], + name: "getOptimalSwap", + outputs: [ + { + internalType: "uint256", + name: "amountIn", + type: "uint256", + }, + { + internalType: "uint256", + name: "amountOut", + type: "uint256", + }, + { + internalType: "bool", + name: "zeroForOne", + type: "bool", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + ], + name: "increaseLiquidity", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + ], + name: "increaseLiquidityOptimal", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenIn", + type: "address", + }, + { + internalType: "uint256", + name: "tokenInFeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + ], + name: "increaseLiquidityWithTokenIn", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + name: "isAllowListedRouter", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + name: "isController", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + ], + name: "mint", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + ], + name: "mintOptimal", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenIn", + type: "address", + }, + { + internalType: "uint256", + name: "tokenInFeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + ], + name: "mintWithTokenIn", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "owner", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + ], + name: "rebalance", + outputs: [ + { + internalType: "uint256", + name: "newTokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "rebalance", + outputs: [ + { + internalType: "uint256", + name: "newTokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + ], + name: "reinvest", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "reinvest", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [], + name: "renounceOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setAllowlistedRouters", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "controllers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setControllers", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "feeCollector", + type: "address", + }, + { + internalType: "uint96", + name: "feeLimitPips", + type: "uint96", + }, + ], + internalType: "struct IAutomanCommon.FeeConfig", + name: "_feeConfig", + type: "tuple", + }, + ], + name: "setFeeConfig", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "transferOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "int256", + name: "amount0Delta", + type: "int256", + }, + { + internalType: "int256", + name: "amount1Delta", + type: "int256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "uniswapV3SwapCallback", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + stateMutability: "payable", + type: "receive", + }, +] as const; + +const _bytecode = + "0x60e0806040526040816158b8803803809161001a8285610292565b8339810103126102225780516001600160a01b03811691828203610222576001600160a01b039061004d906020016102cb565b1690811561027c57600080546001600160a01b031981168417825560405193916001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09080a36080526312a9293f60e21b8152602081600481855afa90811561022f5760009161023b575b506001600160a01b031660a05260405163c45a015560e01b815290602090829060049082905afa90811561022f576000916101f0575b5060c0526040516155d890816102e08239608051818181610c1001528181611293015281816112f20152818161143901528181611795015281816117d001528181611807015281816126330152818161268c01528181612a2c01528181612bad01528181612caa01528181612d5201528181612df101528181612e6401528181612ea50152818161304d0152818161329c015281816133b1015281816146c201528181614938015261499f015260a05181818160300152818161191c0152818161240401528181613595015261365e015260c05181818161033d01528181610697015281816126be0152818161371f01526138380152f35b90506020813d602011610227575b8161020b60209383610292565b810103126102225761021c906102cb565b386100f8565b600080fd5b3d91506101fe565b6040513d6000823e3d90fd5b90506020813d602011610274575b8161025660209383610292565b810103126102225760049161026c6020926102cb565b9150916100c2565b3d9150610249565b631e4fbdf760e01b600052600060045260246000fd5b601f909101601f19168101906001600160401b038211908210176102b557604052565b634e487b7160e01b600052604160045260246000fd5b51906001600160a01b03821682036102225756fe60a06040526004361015610082575b361561001957600080fd5b73ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016330361005857005b7f2f1ca35a0000000000000000000000000000000000000000000000000000000060005260046000fd5b60003560e01c80631376f4c414611d125780631e5eb1d014611cb5578063218b625f14611c63578063219f5d1714611b9057806322adac0514611aed5780632c45e5a014611a1b57806332279096146119aa5780634095c646146119405780634aa4a4fc146118d15780634bf193901461156757806370f3c180146114f9578063715018a61461145d5780637f1e9ef6146113ee57806386c64c8614610fb55780638831645614610ed55780638ba1e27314610e385780638da5cb5b14610de657806391f6e9b214610b7057806398bbfdc114610a7257806399642fb1146108d6578063a5fd1e3c1461081c578063af3ed58614610725578063b429afeb146106bb578063c45a01551461064c578063c747e2b3146104ca578063f2fde38b146103d8578063fa461e33146102c35763fc0e92cc0361000e57346102be576102607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be576101f436611f26565b610164356101c43567ffffffffffffffff81116102be57610219903690600401612045565b90610204359260ff841684036102be576102ba946102516102609561023d84612b67565b610244359061022435906101e435866146bf565b6101a435916101843591613316565b90604094929451948486957f811d4760f1a92875eb76dbd3dc2359544b2f6a000ba5b78784c0b105b3469bd0600080a285526fffffffffffffffffffffffffffffffff166020850152604084015260608301526080820190565b0390f35b600080fd5b346102be5760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be5760043560443567ffffffffffffffff81116102be57610315903690600401612045565b5090604051606083600037606060002074ff00000000000000000000000000000000000000007f0000000000000000000000000000000000000000000000000000000000000000176000526020527fe34f199b19b2b4f47f68442619d555527d244f78a3297ea89325f843f87b8b5460405273ffffffffffffffffffffffffffffffffffffffff6055600b2016906040528033036102be5760008213156103c4576103c2923090356123ea565b005b6103c29260243592503090602001356123ea565b346102be5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be5773ffffffffffffffffffffffffffffffffffffffff610424611f03565b61042c6132c7565b16801561049b5773ffffffffffffffffffffffffffffffffffffffff600054827fffffffffffffffffffffffff0000000000000000000000000000000000000000821617600055167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0600080a3005b7f1e4fbdf700000000000000000000000000000000000000000000000000000000600052600060045260246000fd5b346102be5760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be5760006105036132c7565b670de0b6b3a76400006bffffffffffffffffffffffff6105216123cf565b1610156106495773ffffffffffffffffffffffffffffffffffffffff610545612299565b16156106495773ffffffffffffffffffffffffffffffffffffffff610568612299565b167fffffffffffffffffffffffff0000000000000000000000000000000000000000600254161760025561059a6123cf565b73ffffffffffffffffffffffffffffffffffffffff7fffffffffffffffffffffffff00000000000000000000000000000000000000006002549260a01b169116176002557f42200c2a55e71251cd849a86c7ece1a42ddabecbb489150a136f6c0d239c7a5c610607612299565b61060f6123cf565b6040805173ffffffffffffffffffffffffffffffffffffffff9390931683526bffffffffffffffffffffffff91909116602083015290a180f35b80fd5b346102be5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be57602060405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152f35b346102be5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be5773ffffffffffffffffffffffffffffffffffffffff610707611f03565b166000526003602052602060ff604060002054166040519015158152f35b346102be576101a07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be5761075e3661210a565b6101043567ffffffffffffffff81116102be5761077f903690600401612045565b9091610144359160ff831683036102be576102ba93826107bb6107c89451956107a787612b67565b6101843590610164359061012435896146bf565b60e4359060c435906139c9565b906040949294519485947fc13e24d2b0a3bacd5d1a7c514125a1e27323abf7c86f6d36597f8752bbd7eed7600080a26fffffffffffffffffffffffffffffffff168452602084015260408301526060820190565b346102be576101807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be5761085536612073565b61085d6120eb565b90610124359060ff821682036102be57604092816108976108a493519461088386612b67565b6101643590610144359061010435886146bf565b60c4359060a43590612c2b565b908351927f269a3942fe0284ff30ff93f97529fba299f93b8b85221afab5686fdab8bfa84b600080a282526020820152f35b6101207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be5761090a3661210a565b60c43567ffffffffffffffff81116102be576109f86109bf6109ee8460406109396102ba963690600401612045565b60e49491943594610104356109c86109518751612dae565b9173ffffffffffffffffffffffffffffffffffffffff83511699896109b6838d9c73ffffffffffffffffffffffffffffffffffffffff6020890151169e8f9d602081019d8e91825180610a60575b50019e8f91825180610a4e575b5051915192612561565b50508851612211565b87528751612211565b86526109d261239f565b50606081015160020b608082015160020b8651918851936125d5565b9092525284612ea1565b9092919351926040519485947fe93a38a2f007635b024bb3a896c7021e73edc7146c413a63e6b69c337304c698600080a26fffffffffffffffffffffffffffffffff168452602084015260408301526060820190565b610a5a903033856123ea565b386109ac565b610a6c903033876123ea565b3861099f565b346102be576101c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be57610aab36612073565b610ab3611ee0565b60e43567ffffffffffffffff81116102be57610ad3903690600401612045565b6101049291923567ffffffffffffffff81116102be57610af7903690600401612045565b90610b006120fa565b92610164359560ff871687036102be5787610b4396610b3a60209a5199610b268b612b67565b6101a435906101843590610144358d6146bf565b60c43591612fbe565b604051917f269a3942fe0284ff30ff93f97529fba299f93b8b85221afab5686fdab8bfa84b600080a28152f35b610b79366121a1565b610b849391936132c7565b8083036102be5760005b838110610bcd5750610bc8907fe4d045717648b4a964b22e91953fd95d48e089e38c87021016e48ddd32387eee94604051948594856122dd565b0390a1005b610be0610bdb82868661224d565b6122bc565b90610bf4610bef82858961224d565b61228c565b15610d965773ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169173ffffffffffffffffffffffffffffffffffffffff811692808414610d385760009182918260405160208101927f095ea7b3000000000000000000000000000000000000000000000000000000008452602482015281604482015260448152610c9b606482611e9f565b51925af13d15610d91573d67ffffffffffffffff8111610d625760405190610ceb60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8401160183611e9f565b8152600060203d92013e5b610d3857600191600052816020526040600020827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008254161790555b01610b8e565b7f466d7fef0000000000000000000000000000000000000000000000000000000060005260046000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b610cf6565b73ffffffffffffffffffffffffffffffffffffffff600192166000528160205260406000207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008154169055610d32565b346102be5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be57602073ffffffffffffffffffffffffffffffffffffffff60005416604051908152f35b346102be5760a07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be57610e6f611f03565b602435908160020b82036102be576044358060020b81036102be5760809273ffffffffffffffffffffffffffffffffffffffff92610eb4926084359260643592613a4c565b92919290845190604051948552602085015215156040840152166060820152f35b6101607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be576102ba610f5b610f0f36611f26565b610f5673ffffffffffffffffffffffffffffffffffffffff82511673ffffffffffffffffffffffffffffffffffffffff60208401511660a08401519060c085015192612e29565b6129f9565b90604094929451948486957f07883703ed0e86588a40d76551c92f8a4b329e3bf19765e0e6749473c1a84665600080a285526fffffffffffffffffffffffffffffffff166020850152604084015260608301526080820190565b6101e07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be57610fe936611f26565b6101643573ffffffffffffffffffffffffffffffffffffffff8116918282036102be5761018435906101a43567ffffffffffffffff81116102be57611032903690600401612045565b6101c49591953567ffffffffffffffff81116102be576111d4966102ba956111a661106287943690600401612045565b6000969196906000928c60a089019661108c8161108760c08b519d019c8d5190612392565b612392565b61109f82151591826113dd575b8361346b565b73ffffffffffffffffffffffffffffffffffffffff60025416906113cc575b5050506110c961239f565b9662ffffff60408d01511660408901528d73ffffffffffffffffffffffffffffffffffffffff8d5116908c808303611386575b505050505060208a019773ffffffffffffffffffffffffffffffffffffffff8951168d8b8203611341575b505050508773ffffffffffffffffffffffffffffffffffffffff8a511614611331575b8773ffffffffffffffffffffffffffffffffffffffff8851161461131f575b73ffffffffffffffffffffffffffffffffffffffff808a511697511696602086019788528552606089015160020b60808a015160020b9086613824565b918192855252806112c0575b50505180611261575b50506111c6826129f9565b9492969197909330906137e8565b9081611234575b505050604051948486957f07883703ed0e86588a40d76551c92f8a4b329e3bf19765e0e6749473c1a84665600080a285526fffffffffffffffffffffffffffffffff166020850152604084015260608301526080820190565b73ffffffffffffffffffffffffffffffffffffffff610120611259940151169061357e565b8580806111db565b73ffffffffffffffffffffffffffffffffffffffff6112b992511673ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001690613950565b85806111bb565b73ffffffffffffffffffffffffffffffffffffffff61131892511673ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001690613950565b87806111b2565b905061132b30886137e8565b90611169565b5061133c30886137e8565b61114a565b61137c94955073ffffffffffffffffffffffffffffffffffffffff90828d10928284838318028093181660208c0152181688528851886136f4565b908c80808d611127565b6113c1959650908273ffffffffffffffffffffffffffffffffffffffff9210928284838318028093181660208d0152181689528751896136f4565b908d80808e8c6110fc565b6113d59261357e565b8c8f806110be565b6113e9813033886123ea565b611099565b346102be5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be57602060405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152f35b346102be5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be576114946132c7565b600073ffffffffffffffffffffffffffffffffffffffff81547fffffffffffffffffffffffff000000000000000000000000000000000000000081168355167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08280a3005b346102be576101207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be576115323661210a565b610104359067ffffffffffffffff82116102be576107c861155a6102ba933690600401612045565b908351936107bb85612b67565b6101407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be5761159b3661210a565b60c4359073ffffffffffffffffffffffffffffffffffffffff8216908183036102be5760e435926101043567ffffffffffffffff81116102be576115e3903690600401612045565b6101249391933567ffffffffffffffff81116102be5773ffffffffffffffffffffffffffffffffffffffff8061172493886117309a6102ba998861162c8b983690600401612045565b6000959160009261167960208601958d87519961165381611087604086019d8e5190612392565b61166582151591826113dd578361346b565b8e60025416906118c0575b50505051612dae565b9861168261239f565b9662ffffff60408c01511660408901528d8c8c51169084820361188f575b50505050602089019b8a8d51169180830361185f575b9350505050808888511614611846575b908161170192898c511614611834575b508787511695888b511696602086019788528552606088015160020b608089015160020b9086613824565b918192855252806117fd575b505051806117c6575b505051169151169083612ea1565b939196909530906137e8565b8061178a575b505051926040519485947fe93a38a2f007635b024bb3a896c7021e73edc7146c413a63e6b69c337304c698600080a26fffffffffffffffffffffffffffffffff168452602084015260408301526060820190565b6117bf916117b984517f000000000000000000000000000000000000000000000000000000000000000061398d565b9061357e565b8580611736565b836117f6925116847f00000000000000000000000000000000000000000000000000000000000000001690613950565b8a80611716565b8561182d925116867f00000000000000000000000000000000000000000000000000000000000000001690613950565b8c8061170d565b611840915030906137e8565b8e6116d6565b94506117019061185630876137e8565b959091506116c6565b611885955090828c9210928284838318028093181660208a0152181686528651866136f4565b8f808f8e816116b6565b849b508d90826118b69610928284838318028093181660208d0152181689528751896136f4565b963880808e6116a0565b6118c99261357e565b8d3880611670565b346102be5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be57602060405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152f35b346102be5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be5773ffffffffffffffffffffffffffffffffffffffff61198c611f03565b166000526001602052602060ff604060002054166040519015158152f35b346102be576101e07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be576119e336611f26565b6101c4356101643567ffffffffffffffff82116102be576102ba92611a0f610260933690600401612045565b92909161025182612b67565b346102be57611a29366121a1565b9290611a336132c7565b8383036102be5760005b838110611a7757507f2077016b05a05d3f12f6d9a8ca3667fbecaf29eba7083f7e2d1d70dc3709f63593610bc891604051948594856122dd565b80611a88610bef600193888661224d565b73ffffffffffffffffffffffffffffffffffffffff611aab610bdb84898961224d565b16600052600360205260406000209060ff7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008354169115151617905501611a3d565b346102be576101407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be57611b2636612073565b611b2e611ee0565b60e43567ffffffffffffffff81116102be57611b4e903690600401612045565b9092610104359167ffffffffffffffff83116102be57602094611b78610b43943690600401612045565b929091611b836120fa565b94805197610b3a89612b67565b60c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be576102ba611bc63661210a565b611c0f815191611bd583612dae565b73ffffffffffffffffffffffffffffffffffffffff6020818351169201511691611c0a60208201516040830151908585612e29565b612ea1565b906040949294519485947fe93a38a2f007635b024bb3a896c7021e73edc7146c413a63e6b69c337304c698600080a26fffffffffffffffffffffffffffffffff168452602084015260408301526060820190565b346102be576101007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be576040611c9e36612073565b6108a4611ca96120eb565b82519261089784612b67565b346102be5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be576002546040805173ffffffffffffffffffffffffffffffffffffffff8316815260a09290921c602083015290f35b6101c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126102be57611d4636611f26565b6101643567ffffffffffffffff81116102be576102ba91611d6e610f5b923690600401612045565b90611e0561018435926101a43592611d8461239f565b50611de960a0870194855180611e3c575b50611de060c0890197885180611e0e575b50611dd783828c8c73ffffffffffffffffffffffffffffffffffffffff602081845116930151168d51915192612561565b50508751612211565b86528651612211565b808652606087015160020b608088015160020b865191896125d5565b909252526129f9565b611e369073ffffffffffffffffffffffffffffffffffffffff60208d015116309033906123ea565b8c611da6565b611e619073ffffffffffffffffffffffffffffffffffffffff8a5116309033906123ea565b8a611d95565b60a0810190811067ffffffffffffffff821117610d6257604052565b60c0810190811067ffffffffffffffff821117610d6257604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff821117610d6257604052565b60a4359073ffffffffffffffffffffffffffffffffffffffff821682036102be57565b6004359073ffffffffffffffffffffffffffffffffffffffff821682036102be57565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc6101609101126102be5760405190610160820182811067ffffffffffffffff821117610d62576040528160043573ffffffffffffffffffffffffffffffffffffffff811681036102be57815260243573ffffffffffffffffffffffffffffffffffffffff811681036102be57602082015260443562ffffff811681036102be5760408201526064358060020b81036102be5760608201526084358060020b81036102be57608082015260a43560a082015260c43560c082015260e43560e0820152610104356101008201526101243573ffffffffffffffffffffffffffffffffffffffff811681036102be5761012082015261014061014435910152565b9181601f840112156102be5782359167ffffffffffffffff83116102be57602083818601950101116102be57565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc60a09101126102be57604051906120aa82611e67565b8160043581526024356fffffffffffffffffffffffffffffffff811681036102be576020820152604435604082015260643560608201526080608435910152565b60e4359081151582036102be57565b610124359081151582036102be57565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc60c09101126102be576040519061214182611e83565b6004358252602435602083015260443560408301526064356060830152608435608083015260a43560a0830152565b9181601f840112156102be5782359167ffffffffffffffff83116102be576020808501948460051b0101116102be57565b60407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc8201126102be5760043567ffffffffffffffff81116102be57816121ea91600401612170565b929092916024359067ffffffffffffffff82116102be5761220d91600401612170565b9091565b9190820391821161221e57565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b919081101561225d5760051b0190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b3580151581036102be5790565b60043573ffffffffffffffffffffffffffffffffffffffff811681036102be5790565b3573ffffffffffffffffffffffffffffffffffffffff811681036102be5790565b939293826040820160408352526060810191926000905b808210612342575050808203602091820152838252019291600091505b80821061231e5750505090565b9091928335908115158092036102be57602081600193829352019401920190612311565b90919284359073ffffffffffffffffffffffffffffffffffffffff821682036102be5773ffffffffffffffffffffffffffffffffffffffff919091168152602094850194019291600101906122f4565b9190820180921161221e57565b604051906060820182811067ffffffffffffffff821117610d625760405260006040838281528260208201520152565b6024356bffffffffffffffffffffffff811681036102be5790565b92919073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168073ffffffffffffffffffffffffffffffffffffffff86161480612558575b6124cc575b5073ffffffffffffffffffffffffffffffffffffffff81163003612472575061247092614818565b565b601c60006020949560649382956040519860605260405260601b602c526f23b872dd000000000000000000000000600c525af13d156001600051141716156124be576000606052604052565b637939f4246000526004601cfd5b34840361252e5760006004818681947fd0e30db00000000000000000000000000000000000000000000000000000000083525af1156102be573073ffffffffffffffffffffffffffffffffffffffff8316146125285738612448565b50505050565b7fa11a990f0000000000000000000000000000000000000000000000000000000060005260046000fd5b50341515612443565b95949193909295612572858361346b565b61257c878461346b565b73ffffffffffffffffffffffffffffffffffffffff6002541691806125c0575b5050816125ab575b5050509190565b816125b89396039561357e565b3880806125a4565b82816125ce9397039661357e565b388061259c565b969487876126b75790506125ea959650613824565b9190925b83612659575b82806125fe575050565b73ffffffffffffffffffffffffffffffffffffffff60206124709301511673ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001690613950565b6126b28473ffffffffffffffffffffffffffffffffffffffff83511673ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001690613950565b6125f4565b92909493917f00000000000000000000000000000000000000000000000000000000000000009461274f8587919060609074ff00000000000000000000000000000000000000006040519417600052206020527fe34f199b19b2b4f47f68442619d555527d244f78a3297ea89325f843f87b8b5460405273ffffffffffffffffffffffffffffffffffffffff6055600b201691604052565b73ffffffffffffffffffffffffffffffffffffffff1661276e90614ad0565b509161277990614b0c565b9261278390614b0c565b73ffffffffffffffffffffffffffffffffffffffff169273ffffffffffffffffffffffffffffffffffffffff169173ffffffffffffffffffffffffffffffffffffffff16906127d194614e66565b92806020830196875173ffffffffffffffffffffffffffffffffffffffff1695845173ffffffffffffffffffffffffffffffffffffffff16908188180280911873ffffffffffffffffffffffffffffffffffffffff16963061283390896137e8565b50189161283f92615333565b30825173ffffffffffffffffffffffffffffffffffffffff1690612862916137e8565b30875173ffffffffffffffffffffffffffffffffffffffff1690612885916137e8565b6040805174ff00000000000000000000000000000000000000008717600052606086206020527fe34f199b19b2b4f47f68442619d555527d244f78a3297ea89325f843f87b8b5482526055600b20915290929073ffffffffffffffffffffffffffffffffffffffff1694604282013560e81d91603f013560e81d9461296e9060609074ff00000000000000000000000000000000000000006040519417600052206020527fe34f199b19b2b4f47f68442619d555527d244f78a3297ea89325f843f87b8b5460405273ffffffffffffffffffffffffffffffffffffffff6055600b201691604052565b73ffffffffffffffffffffffffffffffffffffffff169361298e94613a4c565b50506080516129a092909190876149c7565b50306129ab916137e8565b5030835173ffffffffffffffffffffffffffffffffffffffff16906129cf916137e8565b91516129f290309073ffffffffffffffffffffffffffffffffffffffff166137e8565b91926125ee565b6040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0820180516388316456825290937f000000000000000000000000000000000000000000000000000000000000000093608060006101647ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc840182895af115612b62576000519460205194604051946060519852604052600060605286938095969773ffffffffffffffffffffffffffffffffffffffff610120850151169160a08501519060c08601519184818310612b1d575b505050808210612ae2575b5050505050565b612b0c73ffffffffffffffffffffffffffffffffffffffff806020612b1398015116951685613905565b039161357e565b3880808080612adb565b612b5a9273ffffffffffffffffffffffffffffffffffffffff89511692612b0c73ffffffffffffffffffffffffffffffffffffffff8a1685613905565b388084612ad0565b3d6000fd5b33600052600360205260ff60406000205416612c28577f6352211e00000000000000000000000000000000000000000000000000000000600052600452602060006024817f00000000000000000000000000000000000000000000000000000000000000005afa15612c1e5773ffffffffffffffffffffffffffffffffffffffff600051163303612bf457565b7fc19f17a90000000000000000000000000000000000000000000000000000000060005260046000fd5b3d6000803e3d6000fd5b50565b909293916fffffffffffffffffffffffffffffffff60a081612c4d8551612dae565b93612c9e602087019183835116612d4c575b87519973ffffffffffffffffffffffffffffffffffffffff8851169a602089019b73ffffffffffffffffffffffffffffffffffffffff8d5116916148cd565b989099898b612cce8a517f000000000000000000000000000000000000000000000000000000000000000061398d565b908381612d23575b505081612cfa575b5050505051169201511614612cf05750565b612470905161496f565b73ffffffffffffffffffffffffffffffffffffffff612d1a945116613643565b38808080612cde565b612d45918373ffffffffffffffffffffffffffffffffffffffff8d5116613643565b3883612cd6565b612d76887f0000000000000000000000000000000000000000000000000000000000000000614863565b5050612c5f565b60405190612d8a82611e83565b600060a0838281528260208201528260408201528260608201528260808201520152565b612db6612d7d565b50612dbf612d7d565b907f99fbab880000000000000000000000000000000000000000000000000000000060005260045261010081602460007f00000000000000000000000000000000000000000000000000000000000000005afa15612e2557806101006040920182520190565b3d90fd5b90929180612e8a575b505080612e3d575050565b61247091612e4d823033846123ea565b73ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001690613950565b612e9a91612e4d823033846123ea565b3880612e32565b90927f0000000000000000000000000000000000000000000000000000000000000000604051937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0840180519063219f5d1781526060600060c47ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc890182885af115612c1e57526000519460205190604051906040528095829798602082015190612f52604084015193518861398d565b8583829710612f91575b50505050808210612f6e575050505050565b612b0c73ffffffffffffffffffffffffffffffffffffffff612b13961685613905565b612fb593612b0c73ffffffffffffffffffffffffffffffffffffffff8b1685613905565b38808481612f5c565b95936131139398979294612fd28851612dae565b9661302d60408a018051600060608d01928184519452526fffffffffffffffffffffffffffffffff60208d015116613296575b8b518b73ffffffffffffffffffffffffffffffffffffffff60208183511692015116916148cd565b9061303661239f565b9462ffffff60408c01511660408701526130718c517f000000000000000000000000000000000000000000000000000000000000000061398d565b9d73ffffffffffffffffffffffffffffffffffffffff8c511673ffffffffffffffffffffffffffffffffffffffff89168103613202575b5050505073ffffffffffffffffffffffffffffffffffffffff60208a0151169073ffffffffffffffffffffffffffffffffffffffff86168203613169575b505050505061310b3073ffffffffffffffffffffffffffffffffffffffff83166137e8565b978891613643565b841061313f576fffffffffffffffffffffffffffffffff60a0816020850151169201511614612cf05750565b7f5945ea560000000000000000000000000000000000000000000000000000000060005260046000fd5b6131a19473ffffffffffffffffffffffffffffffffffffffff8088168410938185828b180280921816602084015288181681526136f4565b506131c773ffffffffffffffffffffffffffffffffffffffff60208701511630906137e8565b82816131d6575b8180806130e6565b6131fb918a73ffffffffffffffffffffffffffffffffffffffff60208a015116613643565b38826131ce565b61323c9373ffffffffffffffffffffffffffffffffffffffff82818c818116831095869118028092181660208c01528b18168952886136f4565b508b8661326173ffffffffffffffffffffffffffffffffffffffff8c511630906137e8565b8061326d575b806130a8565b61328e9273ffffffffffffffffffffffffffffffffffffffff8d5116613643565b8b8638613267565b6132c08c7f0000000000000000000000000000000000000000000000000000000000000000614863565b5050613005565b73ffffffffffffffffffffffffffffffffffffffff6000541633036132e857565b7f118cdaa7000000000000000000000000000000000000000000000000000000006000523360045260246000fd5b93909260006024816133df6020949996996101408a01519a604051809c61333c82611e67565b8b8252608089830192878452876040820152876060820152015261335f8b612dae565b9073ffffffffffffffffffffffffffffffffffffffff825116906fffffffffffffffffffffffffffffffff60a073ffffffffffffffffffffffffffffffffffffffff8c860151169401511690526133d77f00000000000000000000000000000000000000000000000000000000000000009e8f614863565b50508b6148cd565b9990977f6352211e0000000000000000000000000000000000000000000000000000000083526004525afa15612c1e57613465946134569373ffffffffffffffffffffffffffffffffffffffff6000511661012087015261343e61239f565b50606086015160020b608087015160020b90876125d5565b60c083015260a08201526129f9565b90919293565b9081811061313f578061347c575050565b670de0b6b3a7640000820291818115670de0b6b3a7640000838604141702156134da575090045b60025460a01c106134b057565b7feab9763d0000000000000000000000000000000000000000000000000000000060005260046000fd5b81670de0b6b3a76400007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8184098581108601900392099082600003831692818111156135705783900480600302600218808202600203028082026002030280820260020302808202600203028082026002030280910260020302936001848483030494806000030401921190030217026134a3565b63ae47f7026000526004601cfd5b73ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016908173ffffffffffffffffffffffffffffffffffffffff8216148061363b575b1561362f575060006024818080947f2e1a7d4d000000000000000000000000000000000000000000000000000000008252876004525af1156102be57600080809338935af11561362157565b63b12d13eb6000526004601cfd5b61247093929150614818565b5060016135d5565b9290919273ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016918273ffffffffffffffffffffffffffffffffffffffff83161490816136ec575b501561362f575060006024818080947f2e1a7d4d000000000000000000000000000000000000000000000000000000008252876004525af1156102be57600080809338935af11561362157565b90503861369f565b9390919281156000146137975750506040805174ff00000000000000000000000000000000000000007f000000000000000000000000000000000000000000000000000000000000000017600052606085206020527fe34f199b19b2b4f47f68442619d555527d244f78a3297ea89325f843f87b8b5482526055600b209152613794939073ffffffffffffffffffffffffffffffffffffffff16906149c7565b90565b6137e4939250906137dd9173ffffffffffffffffffffffffffffffffffffffff8080602089015116975116948588180280951816936137d630866137e8565b9618615333565b30906137e8565b0390565b6024600080926020947f70a082310000000000000000000000000000000000000000000000000000000083526004525afa156102be5760005190565b94939290916138e084836138f2936138c38a7f0000000000000000000000000000000000000000000000000000000000000000919060609074ff00000000000000000000000000000000000000006040519417600052206020527fe34f199b19b2b4f47f68442619d555527d244f78a3297ea89325f843f87b8b5460405273ffffffffffffffffffffffffffffffffffffffff6055600b201691604052565b9673ffffffffffffffffffffffffffffffffffffffff8816613a4c565b505060805196909387918591906149c7565b9160000394858318028092180193180190565b6044601060008093602095601452816034526f095ea7b300000000000000000000000082525af13d15600160005114171615613942576000603452565b633e3f8f736000526004601cfd5b6010600060449260209582956014526034526f095ea7b300000000000000000000000082525af13d15600160005114171615613942576000603452565b6024600080926020947f6352211e0000000000000000000000000000000000000000000000000000000083526004525afa15612c1e5760005190565b9273ffffffffffffffffffffffffffffffffffffffff9192613a30613a45968493613a186139f78951612dae565b94613a0061239f565b508951988787511699602088019a898c5116916148cd565b90606086015160020b608087015160020b90876125d5565b60408701526020860152511691511691612ea1565b9192909190565b929094939460006080526000958215806146b7575b6146a0578360020b8260020b9080821291821592614676575b508115614669575b5061463f57843b1561463157604051610120810181811067ffffffffffffffff821117610d62576040526000815260006020820152600060408201526000606082015260006080820152600060a0820152600060c0820152600060e08201526000610100820152613af286614ad0565b969093849760408401527f1a6865020000000000000000000000000000000000000000000000000000000060005260206000600481855afa156102be57600051907fddca3f430000000000000000000000000000000000000000000000000000000060005260206000600481865afa156102be5762ffffff60005116907fd0c93a7c0000000000000000000000000000000000000000000000000000000060005260206000600481875afa156102be57613bd892613bd29260005191875288602088015289606088015287608088015260e0870152610100860152614b0c565b96614b0c565b938660a08401528460c0840152613c3473ffffffffffffffffffffffffffffffffffffffff861673ffffffffffffffffffffffffffffffffffffffff891673ffffffffffffffffffffffffffffffffffffffff8416878a614e66565b608052507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8000906000905b600084604081015160020b9461010082015160020b946080516000146145555783868807128688050360081d9160010b8260010b14600014614545575b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600260ff8399898881830712910503161b01165b8015614507577f07060605060205040602030205040301060502050303040105050304000000006f8421084210842108cc6318c6db6d54be826fffffffffffffffffffffffffffffffff1060071b83811c67ffffffffffffffff1060061b1783811c63ffffffff1060051b1783811c61ffff1060041b1783811c60ff1060031b1792831c1c601f161a17955b948196613d6f82828560081b0102614b0c565b94608051156000146144ab57613dbf73ffffffffffffffffffffffffffffffffffffffff6020870151166fffffffffffffffffffffffffffffffff8751166080880151908960e08a015193615425565b92919690969260608201510196608082015103975b73ffffffffffffffffffffffffffffffffffffffff8085169116810361449a57613e0f9060a083015160c06080511515940151918b8b614e66565b15151461442557505050505050505050505b8051926020820151926060830151966080840151926080511560001461415b575073ffffffffffffffffffffffffffffffffffffffff811673ffffffffffffffffffffffffffffffffffffffff861610614061575b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff85161015613ebe575b50505090613eb89185614f99565b91030191565b9196509291975085519286602081015160c08201519560e08301519081620f424003908060601b84810460608701510190613efd60a08801518361553e565b9a613f16613f108689620f424002614fd8565b8561553e565b95613f2d60a060808b01519889019a01518661553e565b89039687111561405357613eb89c86613ffc96613f4d856140469d6151cb565b930204900303940290620f42400204900360011b9260011b8302828002018070ffffffffffffffffffffffffffffffffff1060071b81811c68ffffffffffffffffff1060061b1781811c64ffffffffff1060051b1781811c62ffffff1060041b1760b56201000083831c019160011c1b0260121c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8080920410900390565b0160601b058181119082180218978a89038060ff1d908101189060016c0100000000000000000000000060e0614032858a61553e565b930151620f4240039388091515160161511c565b9103019690913880613eaa565b63202368086000526004601cfd5b99975061408161407a60e0850151620f4240038461508a565b8686615011565b9773ffffffffffffffffffffffffffffffffffffffff8b1673ffffffffffffffffffffffffffffffffffffffff8a16106000146140d8575073ffffffffffffffffffffffffffffffffffffffff819a5b9050613e76565b999391858561412a9261412282879c969c038060ff1d908101186140fc818661553e565b60016c0100000000000000000000000060e08c0151620f4240039388091515160161511c565b900394614f99565b019573ffffffffffffffffffffffffffffffffffffffff8481811660208601528860608601528360808601526140d1565b905073ffffffffffffffffffffffffffffffffffffffff819893989792971673ffffffffffffffffffffffffffffffffffffffff861611614358575b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff851611156141e3575b50505090613eb89185038060ff1d908101189061553e565b9196509291975085519260208701519360c08801519460e08901519182620f4240039260608b0151908260601b908985870283620f42400204840192048203928311156140535784868e9561427e613eb89d61427661427061434b9c60a08c608061425f6142586143229e858501519061553e565b9b8a61553e565b910151019c0151620f424002614fd8565b8461553e565b8903986151cb565b93020401039160011b9260011b8302828002018070ffffffffffffffffffffffffffffffffff1060071b81811c68ffffffffffffffffff1060061b1781811c64ffffffffff1060051b1781811c62ffffff1060041b1760b56201000083831c019160011c1b0260121c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8080920410900390565b0160601b0481811090821802189760e061433d868d8c614f4b565b910151620f4240039061511c565b91030196909138806141cb565b99975061437861437160e0850151620f4240038461508a565b8686614eb2565b9773ffffffffffffffffffffffffffffffffffffffff8b8116908a16106143b9575073ffffffffffffffffffffffffffffffffffffffff819a5b9050614197565b9993916143f4906143e16143d18886899c969c614f4b565b60e0870151620f4240039061511c565b90039285038060ff1d908101188661553e565b019573ffffffffffffffffffffffffffffffffffffffff8481811660208601528360608601528860808601526143b2565b7ff30dba9300000000000000000000000000000000000000000000000000000000815283838660081b010260020b6004526040816024818b5afa156106495760205190608051900318608051018a51018a5260208a01526080519260081b010203604087015260608601526080850152613c5e565b505050505050505050505050613e21565b936144f073ffffffffffffffffffffffffffffffffffffffff6020830151166fffffffffffffffffffffffffffffffff8351166060840151908960e086015193615425565b969192906060820151039660808201510197613dd4565b50919450507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0160010b61453b818361558c565b9390859085613cd0565b50614550818561558c565b613c9b565b60018487890712878905030160020b60081d9160010b8260010b14600014614621575b60018082988887818307129105030160ff161b8403165b801561460157808403167e1f0d1e100c1d070f090b19131c1706010e11080a1a141802121b1503160405601f826fffffffffffffffffffffffffffffffff1060071b83811c67ffffffffffffffff1060061b1783811c63ffffffff1060051b1792831c63d76453e004161a1795613d5c565b50905060019194500160010b614617818361558c565b939085908561458f565b5061462c818561558c565b614578565b6301ac05a56000526004601cfd5b7f30673a1b0000000000000000000000000000000000000000000000000000000060005260046000fd5b620d89e891501338613a82565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff2761813915038613a7a565b505050505090506000906000906000608052600090565b508015613a61565b907f00000000000000000000000000000000000000000000000000000000000000007f081812fc000000000000000000000000000000000000000000000000000000006000528260045260206000602481845afa15612c1e5760005173ffffffffffffffffffffffffffffffffffffffff163014614810577f6352211e000000000000000000000000000000000000000000000000000000006000528260045260206000602481845afa15612c1e576000517fe985e9c5000000000000000000000000000000000000000000000000000000006000526004523060245260206000604481845afa15612c1e57600051600060245261481057600095869560c4958794604051967f7ac2ff7b000000000000000000000000000000000000000000000000000000008852306004890152602488015260448701526064860152608485015260a48401525af115612c1e57565b505050505050565b6010600060449260209582956014526034526fa9059cbb00000000000000000000000082525af13d15600160005114171615614855576000603452565b6390b8ec186000526004601cfd5b6040600060a47fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0850193827ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc865197630c49ccbe885201915af115612c1e57526000519060205190565b60006084604092969594968351907ffc6f786500000000000000000000000000000000000000000000000000000000825260048201523060248201526fffffffffffffffffffffffffffffffff60448201526fffffffffffffffffffffffffffffffff6064820152827f00000000000000000000000000000000000000000000000000000000000000005af115612c1e5761220d936000519060205192612561565b7f42966c6800000000000000000000000000000000000000000000000000000000600052600452600080602481807f00000000000000000000000000000000000000000000000000000000000000005af115612c1e57565b9392919091600094826149da5750505050565b604091929395507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe06000910195865194606088528351907f128acb0800000000000000000000000000000000000000000000000000000000825230600483015285602483015260448201528473fffd8963efd1fc6a506488495d951d53639afb810273fffd8963efd1fc6a506488495d951d5263988d2518606482015260a060848201528273ffffffffffffffffffffffffffffffffffffffff60c48a51602081018c8160a488019160045afa500193165af160403d141615612c1e576000519081602051180218600003925238808080612528565b60006004816040937f3850c7bd0000000000000000000000000000000000000000000000000000000082525afa156102be576000519060205190565b8060ff1d81810118620d89e88111614e4e5763ffffffff91600182167001fffcb933bd6fad37aa2d162d1a59400102700100000000000000000000000000000000189160028116614e32575b60048116614e16575b60088116614dfa575b60108116614dde575b60208116614dc2575b60408116614da6575b60808116614d8a575b6101008116614d6e575b6102008116614d52575b6104008116614d36575b6108008116614d1a575b6110008116614cfe575b6120008116614ce2575b6140008116614cc6575b6180008116614caa575b620100008116614c8e575b620200008116614c73575b620400008116614c58575b6208000016614c3f575b600012614c18575b0160201c90565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04614c11565b6b048a170391f7dc42444e8fa290910260801c90614c09565b6d2216e584f5fa1ea926041bedfe9890920260801c91614bff565b916e5d6af8dedb81196699c329225ee6040260801c91614bf4565b916f09aa508b5b7a84e1c677de54f3e99bc90260801c91614be9565b916f31be135f97d08fd981231505542fcfa60260801c91614bde565b916f70d869a156d2a1b890bb3df62baf32f70260801c91614bd4565b916fa9f746462d870fdf8a65dc1f90e061e50260801c91614bca565b916fd097f3bdfd2022b8845ad8f792aa58250260801c91614bc0565b916fe7159475a2c29b7443b29c7fa6e889d90260801c91614bb6565b916ff3392b0822b70005940c7a398e4b70f30260801c91614bac565b916ff987a7253ac413176f2b074cf7815e540260801c91614ba2565b916ffcbe86c7900a88aedcffc83b479aa3a40260801c91614b98565b916ffe5dee046a99a2a811c461f1969c30530260801c91614b8e565b916fff2ea16466c96a3843ec78b326b528610260801c91614b85565b916fff973b41fa98c081472e6896dfb254c00260801c91614b7c565b916fffcb9843d60f6159c9db58835c9266440260801c91614b73565b916fffe5caca7e10e4e61c3624eaa0941cd00260801c91614b6a565b916ffff2e50f5f656932ef12357cf3c7fdcc0260801c91614b61565b916ffff97272373d413259a46990580e213a0260801c91614b58565b6308c379a0600052602080526101546041526045601cfd5b919391838511614e7a575050505050600090565b828510614e8b575050505050600190565b614eae93614e9c86614ea59361553e565b9086039061553e565b9382039061528c565b1090565b91908115614f465760601b918082028183820414614efa575b508291614eee9173ffffffffffffffffffffffffffffffffffffffff9404612392565b80820615159104011690565b8301838110614ecb579150614f1082828561528c565b9209614f30575b73ffffffffffffffffffffffffffffffffffffffff1690565b60010180614f175763ae47f7026000526004601cfd5b505090565b918282108284180280808518931893146102be5760019060601b92828103614f8a73ffffffffffffffffffffffffffffffffffffffff8316828761528c565b94098284061715151691040190565b818118818310028082189392811891146102be57614fd4918373ffffffffffffffffffffffffffffffffffffffff831692039060601b61528c565b0490565b8115614fe2570490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b9073ffffffffffffffffffffffffffffffffffffffff90615044938060a01c1560001461507a5760601b04915b16612392565b740100000000000000000000000000000000000000008110156102be5773ffffffffffffffffffffffffffffffffffffffff1690565b90615084916151cb565b9161503e565b81810291620f4240818385041483151702156150ab575050620f4240900490565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff620f42409284098481108501900392099080620f4240111561357057828211900360fa1b910360061c177fde8f6cefed634549b62c77574f722e1ac57e23f24d8fd5cb790fb65668c261390290565b90620f424082029181620f424082850414821517021561513c5750900490565b81620f42407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81840985811086019003920990826000038316928181111561357057839004806003026002188082026002030280820260020302808202600203028082026002030280820260020302809102600203029360018484830304948060000304019211900302170290565b908160601b91816c010000000000000000000000008285041482151702156151f35750900490565b816c010000000000000000000000007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81840985811086019003920990826000038316928181111561357057839004806003026002188082026002030280820260020302808202600203028082026002030280820260020302809102600203029360018484830304948060000304019211900302170290565b818102929181158285048214178302156152a7575050900490565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8492840985811086019003920990826000038316928181111561357057839004806003026002188082026002030280820260020302808202600203028082026002030280820260020302809102600203029360018484830304948060000304019211900302170290565b9190604681013560601c917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff92605a83013560601c910181600052600160205260ff60406000205416156153fb57836014527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff6034526f095ea7b3000000000000000000000000600052602060006044601082895af13d15600160005114171615613942576000928380938160345283606e604051940184375af115612c1e5761247091613905565b7f14e99d060000000000000000000000000000000000000000000000000000000060005260046000fd5b919094929473ffffffffffffffffffffffffffffffffffffffff811673ffffffffffffffffffffffffffffffffffffffff8416101594620f4240039061546b828861508a565b861561550c5761547c848684614f4b565b975b8882106154d5575050958691620f4240615498828461511c565b92096154c3575b945b156154ba579161379492038060ff1d908101189061553e565b61379492614f99565b6001915001801561357057859061549f565b96975091505082158215176102be5785156154fc576154f5908284614eb2565b80956154a1565b615507908284615011565b6154f5565b8185038060ff1d9081011860016c01000000000000000000000000615531838861553e565b928709151516019761547e565b818102917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff910981811082019003806c0100000000000000000000000011156135705760a01b9060601c1790565b6024600080926020947f5339c29600000000000000000000000000000000000000000000000000000000835260010b6004525afa156102be576000519056fea164736f6c634300081a000a"; + +type UniV3AutomanConstructorParams = + | [signer?: Signer] + | ConstructorParameters; + +const isSuperArgs = ( + xs: UniV3AutomanConstructorParams +): xs is ConstructorParameters => xs.length > 1; + +export class UniV3Automan__factory extends ContractFactory { + constructor(...args: UniV3AutomanConstructorParams) { + if (isSuperArgs(args)) { + super(...args); + } else { + super(_abi, _bytecode, args[0]); + } + } + + override deploy( + nonfungiblePositionManager: string, + owner_: string, + overrides?: PayableOverrides & { from?: string } + ): Promise { + return super.deploy( + nonfungiblePositionManager, + owner_, + overrides || {} + ) as Promise; + } + override getDeployTransaction( + nonfungiblePositionManager: string, + owner_: string, + overrides?: PayableOverrides & { from?: string } + ): TransactionRequest { + return super.getDeployTransaction( + nonfungiblePositionManager, + owner_, + overrides || {} + ); + } + override attach(address: string): UniV3Automan { + return super.attach(address) as UniV3Automan; + } + override connect(signer: Signer): UniV3Automan__factory { + return super.connect(signer) as UniV3Automan__factory; + } + + static readonly bytecode = _bytecode; + static readonly abi = _abi; + static createInterface(): UniV3AutomanInterface { + return new utils.Interface(_abi) as UniV3AutomanInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): UniV3Automan { + return new Contract(address, _abi, signerOrProvider) as UniV3Automan; + } +} diff --git a/src/typechain-typesV4/factories/src/UniV3OptimalSwapRouter__factory.ts b/src/typechain-typesV4/factories/src/UniV3OptimalSwapRouter__factory.ts new file mode 100644 index 00000000..aa9303e8 --- /dev/null +++ b/src/typechain-typesV4/factories/src/UniV3OptimalSwapRouter__factory.ts @@ -0,0 +1,321 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import { + Signer, + utils, + Contract, + ContractFactory, + PayableOverrides, +} from "ethers"; +import type { Provider, TransactionRequest } from "@ethersproject/providers"; +import type { + UniV3OptimalSwapRouter, + UniV3OptimalSwapRouterInterface, +} from "../../src/UniV3OptimalSwapRouter"; + +const _abi = [ + { + inputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "npm", + type: "address", + }, + { + internalType: "address", + name: "owner_", + type: "address", + }, + ], + stateMutability: "payable", + type: "constructor", + }, + { + inputs: [], + name: "InvalidRouter", + type: "error", + }, + { + inputs: [], + name: "Invalid_Tick_Range", + type: "error", + }, + { + inputs: [], + name: "MismatchETH", + type: "error", + }, + { + inputs: [], + name: "NotAllowlistedRouter", + type: "error", + }, + { + inputs: [], + name: "NotWETH9", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "OwnableInvalidOwner", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "account", + type: "address", + }, + ], + name: "OwnableUnauthorizedAccount", + type: "error", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "previousOwner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "OwnershipTransferred", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "SetAllowlistedRouters", + type: "event", + }, + { + stateMutability: "nonpayable", + type: "fallback", + }, + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "factory", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + name: "isAllowListedRouter", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "owner", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "renounceOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setAllowlistedRouters", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "transferOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "int256", + name: "amount0Delta", + type: "int256", + }, + { + internalType: "int256", + name: "amount1Delta", + type: "int256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "uniswapV3SwapCallback", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + stateMutability: "payable", + type: "receive", + }, +] as const; + +const _bytecode = + "0x60e0806040526040816128a6803803809161001a82856101eb565b83398101031261017b5780516001600160a01b0381169182820361017b576001600160a01b039061004d90602001610224565b169081156101d557600080546001600160a01b031981168417825560405193916001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09080a36080526312a9293f60e21b8152602081600481855afa90811561018857600091610194575b506001600160a01b031660a05260405163c45a015560e01b815290602090829060049082905afa90811561018857600091610149575b5060c05260405161266d908161023982396080518181816108d80152610af1015260a0518181816103d801528181610bfc0152610dc3015260c05181818161019e01528181610536015261070e0152f35b90506020813d602011610180575b81610164602093836101eb565b8101031261017b5761017590610224565b386100f8565b600080fd5b3d9150610157565b6040513d6000823e3d90fd5b90506020813d6020116101cd575b816101af602093836101eb565b8101031261017b576004916101c5602092610224565b9150916100c2565b3d91506101a2565b631e4fbdf760e01b600052600060045260246000fd5b601f909101601f19168101906001600160401b0382119082101761020e57604052565b634e487b7160e01b600052604160045260246000fd5b51906001600160a01b038216820361017b5756fe60a080604052600436101561042a575b5036156103c157346103bc5760003560601c60143560601c9060313560f81c9060323560601c7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa63601838584180285189061008b6100833373ffffffffffffffffffffffffffffffffffffffff8516610ecf565b303385610f0b565b826014527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff6034526f095ea7b3000000000000000000000000600052602060006044601082865af13d156001600051141716156103ae57600080918160345260405181605a82378260463560601c5af11561035f576044601060008093602095601452816034526f095ea7b300000000000000000000000082525af13d156001600051141716156103ae5760006034526101453082610ecf565b61014f3085610ecf565b90604051906060820182811067ffffffffffffffff82111761037f5760405283825285602083015260283560e81c60408301526040519474ff00000000000000000000000000000000000000007f000000000000000000000000000000000000000000000000000000000000000017600052606083206020527fe34f199b19b2b4f47f68442619d555527d244f78a3297ea89325f843f87b8b5460405273ffffffffffffffffffffffffffffffffffffffff6055600b20169560405260001461036957610236816102203389610ecf565b8501905b602e3560e81d602b3560e81d89610f64565b50506080519560009382610285575b50506000039485831802809218019318019180610273575b50508061026657005b610271913390611c08565b005b61027e913390611c08565b388061025d565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe09194500192604060008551926060875282517f128acb080000000000000000000000000000000000000000000000000000000081523060048201528a60248201528560448201528a73fffd8963efd1fc6a506488495d951d53639afb810273fffd8963efd1fc6a506488495d951d5263988d2518606482015260a060848201528260c489516020810160a48501818d60045afa5001925af160403d14161561035f57600051878160205118021860000393523880610245565b3d6000803e3d6000fd5b6102366103763386610ecf565b82018490610224565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b633e3f8f736000526004601cfd5b600080fd5b73ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016330361040057005b7f2f1ca35a0000000000000000000000000000000000000000000000000000000060005260046000fd5b60003560e01c9081634095c64614610c20575080634aa4a4fc14610bb1578063715018a614610b155780637f1e9ef614610aa65780638da5cb5b14610a5457806391f6e9b214610732578063c45a0155146106c3578063f2fde38b146105d15763fa461e331461049a573861000f565b346103bc5760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103bc5760443560043567ffffffffffffffff82116103bc57366023830112156103bc5781600401359167ffffffffffffffff83116103bc57602481019260243691830101116103bc5760405190606084600037606060002074ff00000000000000000000000000000000000000007f0000000000000000000000000000000000000000000000000000000000000000176000526020527fe34f199b19b2b4f47f68442619d555527d244f78a3297ea89325f843f87b8b5460405273ffffffffffffffffffffffffffffffffffffffff6055600b2016916040528133036103bc5760008313156105bc575061027192309035610da9565b61027193506024359250309060440135610da9565b346103bc5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103bc5773ffffffffffffffffffffffffffffffffffffffff61061d610c86565b610625610d5a565b1680156106945773ffffffffffffffffffffffffffffffffffffffff600054827fffffffffffffffffffffffff0000000000000000000000000000000000000000821617600055167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0600080a3005b7f1e4fbdf700000000000000000000000000000000000000000000000000000000600052600060045260246000fd5b346103bc5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103bc57602060405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152f35b60407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103bc5760043567ffffffffffffffff81116103bc5761077c903690600401610ca9565b60243567ffffffffffffffff81116103bc5761079c903690600401610ca9565b90926107a6610d5a565b8183036103bc579160005b818110610879575060405192816040850160408652526060840190916000905b80821061084257505060209150838103828501528281520192906000905b80821061081e577fe4d045717648b4a964b22e91953fd95d48e089e38c87021016e48ddd32387eee84860385a1005b9091938435908115158092036103bc576020816001938293520195019201906107ef565b909183359073ffffffffffffffffffffffffffffffffffffffff82168092036103bc579081526020938401930191600101906107d1565b6108868183869496610cda565b359073ffffffffffffffffffffffffffffffffffffffff8216918281036103bc576108b2828689610cda565b3580151581036103bc5715610a195773ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168084146109ea5760009182918260405160208101927f095ea7b300000000000000000000000000000000000000000000000000000000845260248201528160448201526044815261094a606482610d19565b51925af13d15610a14573d67ffffffffffffffff811161037f576040519061099a60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8401160183610d19565b8152600060203d92013e5b6109ea57600191600052816020526040600020827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008254161790555b019290926107b1565b7f466d7fef0000000000000000000000000000000000000000000000000000000060005260046000fd5b6109a5565b506001916000528160205260406000207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0081541690556109e1565b346103bc5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103bc57602073ffffffffffffffffffffffffffffffffffffffff60005416604051908152f35b346103bc5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103bc57602060405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152f35b346103bc5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103bc57610b4c610d5a565b600073ffffffffffffffffffffffffffffffffffffffff81547fffffffffffffffffffffffff000000000000000000000000000000000000000081168355167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08280a3005b346103bc5760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103bc57602060405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152f35b346103bc5760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103bc5760209073ffffffffffffffffffffffffffffffffffffffff610c6f610c86565b166000526001825260ff6040600020541615158152f35b6004359073ffffffffffffffffffffffffffffffffffffffff821682036103bc57565b9181601f840112156103bc5782359167ffffffffffffffff83116103bc576020808501948460051b0101116103bc57565b9190811015610cea5760051b0190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761037f57604052565b73ffffffffffffffffffffffffffffffffffffffff600054163303610d7b57565b7f118cdaa7000000000000000000000000000000000000000000000000000000006000523360045260246000fd5b92919073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168073ffffffffffffffffffffffffffffffffffffffff86161480610ec6575b610e3a575b5073ffffffffffffffffffffffffffffffffffffffff81163003610e315750610e2f92611c08565b565b610e2f93610f0b565b348403610e9c5760006004818681947fd0e30db00000000000000000000000000000000000000000000000000000000083525af1156103bc573073ffffffffffffffffffffffffffffffffffffffff831614610e965738610e07565b50505050565b7fa11a990f0000000000000000000000000000000000000000000000000000000060005260046000fd5b50341515610e02565b6024600080926020947f70a082310000000000000000000000000000000000000000000000000000000083526004525afa156103bc5760005190565b601c600060649281946020966040519860605260405260601b602c526f23b872dd000000000000000000000000600c525af13d15600160005114171615610f56576000606052604052565b637939f4246000526004601cfd5b600060808190529594919391821580611c00575b611be9578360020b8560020b9080821291821592611bbf575b508115611bb2575b50611b8857813b15611b7a57604051610120810181811067ffffffffffffffff82111761037f576040526000815260006020820152600060408201526000606082015260006080820152600060a0820152600060c0820152600060e082015260006101008201527f3850c7bd0000000000000000000000000000000000000000000000000000000060005260406000600481865afa156103bc576000519260205196849760408401527f1a6865020000000000000000000000000000000000000000000000000000000060005260206000600481855afa156103bc57600051907fddca3f430000000000000000000000000000000000000000000000000000000060005260206000600481865afa156103bc5762ffffff60005116907fd0c93a7c0000000000000000000000000000000000000000000000000000000060005260206000600481875afa156103bc5761111e926111189260005191875288602088015289606088015287608088015260e0870152610100860152611c53565b96611c53565b938660a08401528460c084015261117a73ffffffffffffffffffffffffffffffffffffffff861673ffffffffffffffffffffffffffffffffffffffff891673ffffffffffffffffffffffffffffffffffffffff8416878a611fad565b608052507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8000906000905b600084604081015160020b9461010082015160020b94608051600014611a9e5783868807128688050360081d9160010b8260010b14600014611a8e575b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600260ff8399898881830712910503161b01165b8015611a50577f07060605060205040602030205040301060502050303040105050304000000006f8421084210842108cc6318c6db6d54be826fffffffffffffffffffffffffffffffff1060071b83811c67ffffffffffffffff1060061b1783811c63ffffffff1060051b1783811c61ffff1060041b1783811c60ff1060031b1792831c1c601f161a17955b9481966112b582828560081b0102611c53565b94608051156000146119f45761130573ffffffffffffffffffffffffffffffffffffffff6020870151166fffffffffffffffffffffffffffffffff8751166080880151908960e08a01519361220e565b92919690969260608201510196608082015103975b73ffffffffffffffffffffffffffffffffffffffff808516911681036119e3576113559060a083015160c06080511515940151918b8b611fad565b15151461196b57505050505050505050505b805192602082015192606083015196608084015192608051156000146116a1575073ffffffffffffffffffffffffffffffffffffffff811673ffffffffffffffffffffffffffffffffffffffff8616106115a7575b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff85161015611404575b505050906113fe918561211d565b91030191565b9196509291975085519286602081015160c08201519560e08301519081620f424003908060601b8481046060870151019061144360a0880151836125d3565b9a61145c6114568689620f42400261215c565b856125d3565b9561147360a060808b01519889019a0151866125d3565b890396871115611599576113fe9c86611542966114938561158c9d61246b565b930204900303940290620f42400204900360011b9260011b8302828002018070ffffffffffffffffffffffffffffffffff1060071b81811c68ffffffffffffffffff1060061b1781811c64ffffffffff1060051b1781811c62ffffff1060041b1760b56201000083831c019160011c1b0260121c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8080920410900390565b0160601b058181119082180218978a89038060ff1d908101189060016c0100000000000000000000000060e0611578858a6125d3565b930151620f424003938809151516016123bc565b91030196909138806113f0565b63202368086000526004601cfd5b9997506115c76115c060e0850151620f4240038461232a565b8686612195565b9773ffffffffffffffffffffffffffffffffffffffff8b1673ffffffffffffffffffffffffffffffffffffffff8a161060001461161e575073ffffffffffffffffffffffffffffffffffffffff819a5b90506113bc565b99939185856116709261166882879c969c038060ff1d9081011861164281866125d3565b60016c0100000000000000000000000060e08c0151620f424003938809151516016123bc565b90039461211d565b019573ffffffffffffffffffffffffffffffffffffffff848181166020860152886060860152836080860152611617565b905073ffffffffffffffffffffffffffffffffffffffff819893989792971673ffffffffffffffffffffffffffffffffffffffff86161161189e575b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff85161115611729575b505050906113fe9185038060ff1d90810118906125d3565b9196509291975085519260208701519360c08801519460e08901519182620f4240039260608b0151908260601b908985870283620f42400204840192048203928311156115995784868e956117c46113fe9d6117bc6117b66118919c60a08c60806117a561179e6118689e85850151906125d3565b9b8a6125d3565b910151019c0151620f42400261215c565b846125d3565b89039861246b565b93020401039160011b9260011b8302828002018070ffffffffffffffffffffffffffffffffff1060071b81811c68ffffffffffffffffff1060061b1781811c64ffffffffff1060051b1781811c62ffffff1060041b1760b56201000083831c019160011c1b0260121c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8082040160011c8080920410900390565b0160601b0481811090821802189760e0611883868d8c6120cf565b910151620f424003906123bc565b9103019690913880611711565b9997506118be6118b760e0850151620f4240038461232a565b8686612035565b9773ffffffffffffffffffffffffffffffffffffffff8b8116908a16106118ff575073ffffffffffffffffffffffffffffffffffffffff819a5b90506116dd565b99939161193a906119276119178886899c969c6120cf565b60e0870151620f424003906123bc565b90039285038060ff1d90810118866125d3565b019573ffffffffffffffffffffffffffffffffffffffff8481811660208601528360608601528860808601526118f8565b7ff30dba9300000000000000000000000000000000000000000000000000000000815283838660081b010260020b6004526040816024818b5afa156119e05760205190608051900318608051018a51018a5260208a01526080519260081b0102036040870152606086015260808501526111a4565b80fd5b505050505050505050505050611367565b93611a3973ffffffffffffffffffffffffffffffffffffffff6020830151166fffffffffffffffffffffffffffffffff8351166060840151908960e08601519361220e565b96919290606082015103966080820151019761131a565b50919450507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0160010b611a848183612621565b9390859085611216565b50611a998185612621565b6111e1565b60018487890712878905030160020b60081d9160010b8260010b14600014611b6a575b60018082988887818307129105030160ff161b8403165b8015611b4a57808403167e1f0d1e100c1d070f090b19131c1706010e11080a1a141802121b1503160405601f826fffffffffffffffffffffffffffffffff1060071b83811c67ffffffffffffffff1060061b1783811c63ffffffff1060051b1792831c63d76453e004161a17956112a2565b50905060019194500160010b611b608183612621565b9390859085611ad8565b50611b758185612621565b611ac1565b6301ac05a56000526004601cfd5b7f30673a1b0000000000000000000000000000000000000000000000000000000060005260046000fd5b620d89e891501338610f99565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff2761813915038610f91565b505050505090506000906000906000608052600090565b508015610f78565b6010600060449260209582956014526034526fa9059cbb00000000000000000000000082525af13d15600160005114171615611c45576000603452565b6390b8ec186000526004601cfd5b8060ff1d81810118620d89e88111611f955763ffffffff91600182167001fffcb933bd6fad37aa2d162d1a59400102700100000000000000000000000000000000189160028116611f79575b60048116611f5d575b60088116611f41575b60108116611f25575b60208116611f09575b60408116611eed575b60808116611ed1575b6101008116611eb5575b6102008116611e99575b6104008116611e7d575b6108008116611e61575b6110008116611e45575b6120008116611e29575b6140008116611e0d575b6180008116611df1575b620100008116611dd5575b620200008116611dba575b620400008116611d9f575b6208000016611d86575b600012611d5f575b0160201c90565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04611d58565b6b048a170391f7dc42444e8fa290910260801c90611d50565b6d2216e584f5fa1ea926041bedfe9890920260801c91611d46565b916e5d6af8dedb81196699c329225ee6040260801c91611d3b565b916f09aa508b5b7a84e1c677de54f3e99bc90260801c91611d30565b916f31be135f97d08fd981231505542fcfa60260801c91611d25565b916f70d869a156d2a1b890bb3df62baf32f70260801c91611d1b565b916fa9f746462d870fdf8a65dc1f90e061e50260801c91611d11565b916fd097f3bdfd2022b8845ad8f792aa58250260801c91611d07565b916fe7159475a2c29b7443b29c7fa6e889d90260801c91611cfd565b916ff3392b0822b70005940c7a398e4b70f30260801c91611cf3565b916ff987a7253ac413176f2b074cf7815e540260801c91611ce9565b916ffcbe86c7900a88aedcffc83b479aa3a40260801c91611cdf565b916ffe5dee046a99a2a811c461f1969c30530260801c91611cd5565b916fff2ea16466c96a3843ec78b326b528610260801c91611ccc565b916fff973b41fa98c081472e6896dfb254c00260801c91611cc3565b916fffcb9843d60f6159c9db58835c9266440260801c91611cba565b916fffe5caca7e10e4e61c3624eaa0941cd00260801c91611cb1565b916ffff2e50f5f656932ef12357cf3c7fdcc0260801c91611ca8565b916ffff97272373d413259a46990580e213a0260801c91611c9f565b6308c379a0600052602080526101546041526045601cfd5b919391838511611fc1575050505050600090565b828510611fd2575050505050600190565b611ff593611fe386611fec936125d3565b908603906125d3565b9382039061252c565b1090565b9190820180921161200657565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b919081156120ca5760601b91808202818382041461207d575b5082916120719173ffffffffffffffffffffffffffffffffffffffff9404611ff9565b80820615159104011690565b830183811061204e57915061209382828561252c565b92096120b3575b73ffffffffffffffffffffffffffffffffffffffff1690565b6001018061209a575b63ae47f7026000526004601cfd5b505090565b918282108284180280808518931893146103bc5760019060601b9282810361210e73ffffffffffffffffffffffffffffffffffffffff8316828761252c565b94098284061715151691040190565b818118818310028082189392811891146103bc57612158918373ffffffffffffffffffffffffffffffffffffffff831692039060601b61252c565b0490565b8115612166570490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b9073ffffffffffffffffffffffffffffffffffffffff906121c8938060a01c156000146121fe5760601b04915b16611ff9565b740100000000000000000000000000000000000000008110156103bc5773ffffffffffffffffffffffffffffffffffffffff1690565b906122089161246b565b916121c2565b919094929473ffffffffffffffffffffffffffffffffffffffff811673ffffffffffffffffffffffffffffffffffffffff8416101594620f42400390612254828861232a565b86156122f8576122658486846120cf565b975b8882106122c1575050958691620f424061228182846123bc565b92096122af575b945b156122a657916122a392038060ff1d90810118906125d3565b90565b6122a39261211d565b600191500180156120bc578590612288565b96975091505082158215176103bc5785156122e8576122e1908284612035565b809561228a565b6122f3908284612195565b6122e1565b8185038060ff1d9081011860016c0100000000000000000000000061231d83886125d3565b9287091515160197612267565b81810291620f42408183850414831517021561234b575050620f4240900490565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff620f42409284098481108501900392099080620f424011156120bc57828211900360fa1b910360061c177fde8f6cefed634549b62c77574f722e1ac57e23f24d8fd5cb790fb65668c261390290565b90620f424082029181620f42408285041482151702156123dc5750900490565b81620f42407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8184098581108601900392099082600003831692818111156120bc57839004806003026002188082026002030280820260020302808202600203028082026002030280820260020302809102600203029360018484830304948060000304019211900302170290565b908160601b91816c010000000000000000000000008285041482151702156124935750900490565b816c010000000000000000000000007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8184098581108601900392099082600003831692818111156120bc57839004806003026002188082026002030280820260020302808202600203028082026002030280820260020302809102600203029360018484830304948060000304019211900302170290565b81810292918115828504821417830215612547575050900490565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff849284098581108601900392099082600003831692818111156120bc57839004806003026002188082026002030280820260020302808202600203028082026002030280820260020302809102600203029360018484830304948060000304019211900302170290565b818102917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff910981811082019003806c0100000000000000000000000011156120bc5760a01b9060601c1790565b6024600080926020947f5339c29600000000000000000000000000000000000000000000000000000000835260010b6004525afa156103bc576000519056fea164736f6c634300081a000a"; + +type UniV3OptimalSwapRouterConstructorParams = + | [signer?: Signer] + | ConstructorParameters; + +const isSuperArgs = ( + xs: UniV3OptimalSwapRouterConstructorParams +): xs is ConstructorParameters => xs.length > 1; + +export class UniV3OptimalSwapRouter__factory extends ContractFactory { + constructor(...args: UniV3OptimalSwapRouterConstructorParams) { + if (isSuperArgs(args)) { + super(...args); + } else { + super(_abi, _bytecode, args[0]); + } + } + + override deploy( + npm: string, + owner_: string, + overrides?: PayableOverrides & { from?: string } + ): Promise { + return super.deploy( + npm, + owner_, + overrides || {} + ) as Promise; + } + override getDeployTransaction( + npm: string, + owner_: string, + overrides?: PayableOverrides & { from?: string } + ): TransactionRequest { + return super.getDeployTransaction(npm, owner_, overrides || {}); + } + override attach(address: string): UniV3OptimalSwapRouter { + return super.attach(address) as UniV3OptimalSwapRouter; + } + override connect(signer: Signer): UniV3OptimalSwapRouter__factory { + return super.connect(signer) as UniV3OptimalSwapRouter__factory; + } + + static readonly bytecode = _bytecode; + static readonly abi = _abi; + static createInterface(): UniV3OptimalSwapRouterInterface { + return new utils.Interface(_abi) as UniV3OptimalSwapRouterInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): UniV3OptimalSwapRouter { + return new Contract( + address, + _abi, + signerOrProvider + ) as UniV3OptimalSwapRouter; + } +} diff --git a/src/typechain-typesV4/factories/src/base/Automan__factory.ts b/src/typechain-typesV4/factories/src/base/Automan__factory.ts new file mode 100644 index 00000000..1120f613 --- /dev/null +++ b/src/typechain-typesV4/factories/src/base/Automan__factory.ts @@ -0,0 +1,1736 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { Automan, AutomanInterface } from "../../../src/base/Automan"; + +const _abi = [ + { + inputs: [], + name: "FeeLimitExceeded", + type: "error", + }, + { + inputs: [], + name: "InsufficientAmount", + type: "error", + }, + { + inputs: [], + name: "InvalidRouter", + type: "error", + }, + { + inputs: [], + name: "Invalid_Tick_Range", + type: "error", + }, + { + inputs: [], + name: "MismatchETH", + type: "error", + }, + { + inputs: [], + name: "NotAllowlistedRouter", + type: "error", + }, + { + inputs: [], + name: "NotApproved", + type: "error", + }, + { + inputs: [], + name: "NotWETH9", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "OwnableInvalidOwner", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "account", + type: "address", + }, + ], + name: "OwnableUnauthorizedAccount", + type: "error", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "controllers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "ControllersSet", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "DecreaseLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address", + name: "feeCollector", + type: "address", + }, + { + indexed: false, + internalType: "uint96", + name: "feeLimitPips", + type: "uint96", + }, + ], + name: "FeeConfigSet", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "IncreaseLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Mint", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "previousOwner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "OwnershipTransferred", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Rebalance", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Reinvest", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "RemoveLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "SetAllowlistedRouters", + type: "event", + }, + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + ], + name: "decreaseLiquidity", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "decreaseLiquidity", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenOut", + type: "address", + }, + { + internalType: "uint256", + name: "tokenOutMin", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + ], + name: "decreaseLiquidityToTokenOut", + outputs: [ + { + internalType: "uint256", + name: "tokenOutAmount", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenOut", + type: "address", + }, + { + internalType: "uint256", + name: "tokenOutMin", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "decreaseLiquidityToTokenOut", + outputs: [ + { + internalType: "uint256", + name: "tokenOutAmount", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [], + name: "feeConfig", + outputs: [ + { + internalType: "address", + name: "feeCollector", + type: "address", + }, + { + internalType: "uint96", + name: "feeLimitPips", + type: "uint96", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "V3PoolCallee", + name: "pool", + type: "address", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + ], + name: "getOptimalSwap", + outputs: [ + { + internalType: "uint256", + name: "amountIn", + type: "uint256", + }, + { + internalType: "uint256", + name: "amountOut", + type: "uint256", + }, + { + internalType: "bool", + name: "zeroForOne", + type: "bool", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + ], + name: "increaseLiquidity", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + ], + name: "increaseLiquidityOptimal", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenIn", + type: "address", + }, + { + internalType: "uint256", + name: "tokenInFeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + ], + name: "increaseLiquidityWithTokenIn", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + name: "isAllowListedRouter", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + name: "isController", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + ], + name: "mint", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + ], + name: "mintOptimal", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenIn", + type: "address", + }, + { + internalType: "uint256", + name: "tokenInFeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + ], + name: "mintWithTokenIn", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "owner", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + ], + name: "rebalance", + outputs: [ + { + internalType: "uint256", + name: "newTokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "rebalance", + outputs: [ + { + internalType: "uint256", + name: "newTokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + ], + name: "reinvest", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "reinvest", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [], + name: "renounceOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setAllowlistedRouters", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "controllers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setControllers", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "feeCollector", + type: "address", + }, + { + internalType: "uint96", + name: "feeLimitPips", + type: "uint96", + }, + ], + internalType: "struct IAutomanCommon.FeeConfig", + name: "_feeConfig", + type: "tuple", + }, + ], + name: "setFeeConfig", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "transferOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + stateMutability: "payable", + type: "receive", + }, +] as const; + +export class Automan__factory { + static readonly abi = _abi; + static createInterface(): AutomanInterface { + return new utils.Interface(_abi) as AutomanInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): Automan { + return new Contract(address, _abi, signerOrProvider) as Automan; + } +} diff --git a/src/typechain-typesV4/factories/src/base/Callback.sol/PancakeV3Callback__factory.ts b/src/typechain-typesV4/factories/src/base/Callback.sol/PancakeV3Callback__factory.ts new file mode 100644 index 00000000..95d6d38b --- /dev/null +++ b/src/typechain-typesV4/factories/src/base/Callback.sol/PancakeV3Callback__factory.ts @@ -0,0 +1,102 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + PancakeV3Callback, + PancakeV3CallbackInterface, +} from "../../../../src/base/Callback.sol/PancakeV3Callback"; + +const _abi = [ + { + inputs: [], + name: "MismatchETH", + type: "error", + }, + { + inputs: [], + name: "NotWETH9", + type: "error", + }, + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "deployer", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "int256", + name: "amount0Delta", + type: "int256", + }, + { + internalType: "int256", + name: "amount1Delta", + type: "int256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "pancakeV3SwapCallback", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + stateMutability: "payable", + type: "receive", + }, +] as const; + +export class PancakeV3Callback__factory { + static readonly abi = _abi; + static createInterface(): PancakeV3CallbackInterface { + return new utils.Interface(_abi) as PancakeV3CallbackInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): PancakeV3Callback { + return new Contract(address, _abi, signerOrProvider) as PancakeV3Callback; + } +} diff --git a/src/typechain-typesV4/factories/src/base/Callback.sol/SlipStreamCallback__factory.ts b/src/typechain-typesV4/factories/src/base/Callback.sol/SlipStreamCallback__factory.ts new file mode 100644 index 00000000..f31ebe31 --- /dev/null +++ b/src/typechain-typesV4/factories/src/base/Callback.sol/SlipStreamCallback__factory.ts @@ -0,0 +1,102 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + SlipStreamCallback, + SlipStreamCallbackInterface, +} from "../../../../src/base/Callback.sol/SlipStreamCallback"; + +const _abi = [ + { + inputs: [], + name: "MismatchETH", + type: "error", + }, + { + inputs: [], + name: "NotWETH9", + type: "error", + }, + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "factory", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "int256", + name: "amount0Delta", + type: "int256", + }, + { + internalType: "int256", + name: "amount1Delta", + type: "int256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "uniswapV3SwapCallback", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + stateMutability: "payable", + type: "receive", + }, +] as const; + +export class SlipStreamCallback__factory { + static readonly abi = _abi; + static createInterface(): SlipStreamCallbackInterface { + return new utils.Interface(_abi) as SlipStreamCallbackInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): SlipStreamCallback { + return new Contract(address, _abi, signerOrProvider) as SlipStreamCallback; + } +} diff --git a/src/typechain-typesV4/factories/src/base/Callback.sol/UniswapV3Callback__factory.ts b/src/typechain-typesV4/factories/src/base/Callback.sol/UniswapV3Callback__factory.ts new file mode 100644 index 00000000..51fe209c --- /dev/null +++ b/src/typechain-typesV4/factories/src/base/Callback.sol/UniswapV3Callback__factory.ts @@ -0,0 +1,102 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + UniswapV3Callback, + UniswapV3CallbackInterface, +} from "../../../../src/base/Callback.sol/UniswapV3Callback"; + +const _abi = [ + { + inputs: [], + name: "MismatchETH", + type: "error", + }, + { + inputs: [], + name: "NotWETH9", + type: "error", + }, + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "factory", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "int256", + name: "amount0Delta", + type: "int256", + }, + { + internalType: "int256", + name: "amount1Delta", + type: "int256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "uniswapV3SwapCallback", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + stateMutability: "payable", + type: "receive", + }, +] as const; + +export class UniswapV3Callback__factory { + static readonly abi = _abi; + static createInterface(): UniswapV3CallbackInterface { + return new utils.Interface(_abi) as UniswapV3CallbackInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): UniswapV3Callback { + return new Contract(address, _abi, signerOrProvider) as UniswapV3Callback; + } +} diff --git a/src/typechain-typesV4/factories/src/base/Callback.sol/index.ts b/src/typechain-typesV4/factories/src/base/Callback.sol/index.ts new file mode 100644 index 00000000..01bd2554 --- /dev/null +++ b/src/typechain-typesV4/factories/src/base/Callback.sol/index.ts @@ -0,0 +1,6 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export { PancakeV3Callback__factory } from "./PancakeV3Callback__factory"; +export { SlipStreamCallback__factory } from "./SlipStreamCallback__factory"; +export { UniswapV3Callback__factory } from "./UniswapV3Callback__factory"; diff --git a/src/typechain-typesV4/factories/src/base/Immutables.sol/Immutables__factory.ts b/src/typechain-typesV4/factories/src/base/Immutables.sol/Immutables__factory.ts new file mode 100644 index 00000000..c985d5be --- /dev/null +++ b/src/typechain-typesV4/factories/src/base/Immutables.sol/Immutables__factory.ts @@ -0,0 +1,52 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + Immutables, + ImmutablesInterface, +} from "../../../../src/base/Immutables.sol/Immutables"; + +const _abi = [ + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, +] as const; + +export class Immutables__factory { + static readonly abi = _abi; + static createInterface(): ImmutablesInterface { + return new utils.Interface(_abi) as ImmutablesInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): Immutables { + return new Contract(address, _abi, signerOrProvider) as Immutables; + } +} diff --git a/src/typechain-typesV4/factories/src/base/Immutables.sol/PCSV3Immutables__factory.ts b/src/typechain-typesV4/factories/src/base/Immutables.sol/PCSV3Immutables__factory.ts new file mode 100644 index 00000000..3c786b02 --- /dev/null +++ b/src/typechain-typesV4/factories/src/base/Immutables.sol/PCSV3Immutables__factory.ts @@ -0,0 +1,65 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + PCSV3Immutables, + PCSV3ImmutablesInterface, +} from "../../../../src/base/Immutables.sol/PCSV3Immutables"; + +const _abi = [ + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "deployer", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, +] as const; + +export class PCSV3Immutables__factory { + static readonly abi = _abi; + static createInterface(): PCSV3ImmutablesInterface { + return new utils.Interface(_abi) as PCSV3ImmutablesInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): PCSV3Immutables { + return new Contract(address, _abi, signerOrProvider) as PCSV3Immutables; + } +} diff --git a/src/typechain-typesV4/factories/src/base/Immutables.sol/UniV3Immutables__factory.ts b/src/typechain-typesV4/factories/src/base/Immutables.sol/UniV3Immutables__factory.ts new file mode 100644 index 00000000..4afdfc8d --- /dev/null +++ b/src/typechain-typesV4/factories/src/base/Immutables.sol/UniV3Immutables__factory.ts @@ -0,0 +1,65 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + UniV3Immutables, + UniV3ImmutablesInterface, +} from "../../../../src/base/Immutables.sol/UniV3Immutables"; + +const _abi = [ + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "factory", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, +] as const; + +export class UniV3Immutables__factory { + static readonly abi = _abi; + static createInterface(): UniV3ImmutablesInterface { + return new utils.Interface(_abi) as UniV3ImmutablesInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): UniV3Immutables { + return new Contract(address, _abi, signerOrProvider) as UniV3Immutables; + } +} diff --git a/src/typechain-typesV4/factories/src/base/Immutables.sol/index.ts b/src/typechain-typesV4/factories/src/base/Immutables.sol/index.ts new file mode 100644 index 00000000..04570ee5 --- /dev/null +++ b/src/typechain-typesV4/factories/src/base/Immutables.sol/index.ts @@ -0,0 +1,6 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export { Immutables__factory } from "./Immutables__factory"; +export { PCSV3Immutables__factory } from "./PCSV3Immutables__factory"; +export { UniV3Immutables__factory } from "./UniV3Immutables__factory"; diff --git a/src/typechain-typesV4/factories/src/base/OptimalSwapRouter__factory.ts b/src/typechain-typesV4/factories/src/base/OptimalSwapRouter__factory.ts new file mode 100644 index 00000000..408c66af --- /dev/null +++ b/src/typechain-typesV4/factories/src/base/OptimalSwapRouter__factory.ts @@ -0,0 +1,215 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + OptimalSwapRouter, + OptimalSwapRouterInterface, +} from "../../../src/base/OptimalSwapRouter"; + +const _abi = [ + { + inputs: [], + name: "InvalidRouter", + type: "error", + }, + { + inputs: [], + name: "Invalid_Tick_Range", + type: "error", + }, + { + inputs: [], + name: "MismatchETH", + type: "error", + }, + { + inputs: [], + name: "NotAllowlistedRouter", + type: "error", + }, + { + inputs: [], + name: "NotWETH9", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "OwnableInvalidOwner", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "account", + type: "address", + }, + ], + name: "OwnableUnauthorizedAccount", + type: "error", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "previousOwner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "OwnershipTransferred", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "SetAllowlistedRouters", + type: "event", + }, + { + stateMutability: "nonpayable", + type: "fallback", + }, + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + name: "isAllowListedRouter", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "owner", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "renounceOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setAllowlistedRouters", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "transferOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + stateMutability: "payable", + type: "receive", + }, +] as const; + +export class OptimalSwapRouter__factory { + static readonly abi = _abi; + static createInterface(): OptimalSwapRouterInterface { + return new utils.Interface(_abi) as OptimalSwapRouterInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): OptimalSwapRouter { + return new Contract(address, _abi, signerOrProvider) as OptimalSwapRouter; + } +} diff --git a/src/typechain-typesV4/factories/src/base/Payments__factory.ts b/src/typechain-typesV4/factories/src/base/Payments__factory.ts new file mode 100644 index 00000000..1aacd3f7 --- /dev/null +++ b/src/typechain-typesV4/factories/src/base/Payments__factory.ts @@ -0,0 +1,63 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { Payments, PaymentsInterface } from "../../../src/base/Payments"; + +const _abi = [ + { + inputs: [], + name: "MismatchETH", + type: "error", + }, + { + inputs: [], + name: "NotWETH9", + type: "error", + }, + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + stateMutability: "payable", + type: "receive", + }, +] as const; + +export class Payments__factory { + static readonly abi = _abi; + static createInterface(): PaymentsInterface { + return new utils.Interface(_abi) as PaymentsInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): Payments { + return new Contract(address, _abi, signerOrProvider) as Payments; + } +} diff --git a/src/typechain-typesV4/factories/src/base/SlipStreamSwapRouter__factory.ts b/src/typechain-typesV4/factories/src/base/SlipStreamSwapRouter__factory.ts new file mode 100644 index 00000000..d3439738 --- /dev/null +++ b/src/typechain-typesV4/factories/src/base/SlipStreamSwapRouter__factory.ts @@ -0,0 +1,246 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + SlipStreamSwapRouter, + SlipStreamSwapRouterInterface, +} from "../../../src/base/SlipStreamSwapRouter"; + +const _abi = [ + { + inputs: [], + name: "InvalidRouter", + type: "error", + }, + { + inputs: [], + name: "MismatchETH", + type: "error", + }, + { + inputs: [], + name: "NotAllowlistedRouter", + type: "error", + }, + { + inputs: [], + name: "NotWETH9", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "OwnableInvalidOwner", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "account", + type: "address", + }, + ], + name: "OwnableUnauthorizedAccount", + type: "error", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "previousOwner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "OwnershipTransferred", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "SetAllowlistedRouters", + type: "event", + }, + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "factory", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + name: "isAllowListedRouter", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "owner", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "renounceOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setAllowlistedRouters", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "transferOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "int256", + name: "amount0Delta", + type: "int256", + }, + { + internalType: "int256", + name: "amount1Delta", + type: "int256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "uniswapV3SwapCallback", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + stateMutability: "payable", + type: "receive", + }, +] as const; + +export class SlipStreamSwapRouter__factory { + static readonly abi = _abi; + static createInterface(): SlipStreamSwapRouterInterface { + return new utils.Interface(_abi) as SlipStreamSwapRouterInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): SlipStreamSwapRouter { + return new Contract( + address, + _abi, + signerOrProvider + ) as SlipStreamSwapRouter; + } +} diff --git a/src/typechain-typesV4/factories/src/base/SwapRouter.sol/PCSV3SwapRouter__factory.ts b/src/typechain-typesV4/factories/src/base/SwapRouter.sol/PCSV3SwapRouter__factory.ts new file mode 100644 index 00000000..8b5822d3 --- /dev/null +++ b/src/typechain-typesV4/factories/src/base/SwapRouter.sol/PCSV3SwapRouter__factory.ts @@ -0,0 +1,242 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + PCSV3SwapRouter, + PCSV3SwapRouterInterface, +} from "../../../../src/base/SwapRouter.sol/PCSV3SwapRouter"; + +const _abi = [ + { + inputs: [], + name: "InvalidRouter", + type: "error", + }, + { + inputs: [], + name: "MismatchETH", + type: "error", + }, + { + inputs: [], + name: "NotAllowlistedRouter", + type: "error", + }, + { + inputs: [], + name: "NotWETH9", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "OwnableInvalidOwner", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "account", + type: "address", + }, + ], + name: "OwnableUnauthorizedAccount", + type: "error", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "previousOwner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "OwnershipTransferred", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "SetAllowlistedRouters", + type: "event", + }, + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "deployer", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + name: "isAllowListedRouter", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "owner", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "int256", + name: "amount0Delta", + type: "int256", + }, + { + internalType: "int256", + name: "amount1Delta", + type: "int256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "pancakeV3SwapCallback", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [], + name: "renounceOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setAllowlistedRouters", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "transferOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + stateMutability: "payable", + type: "receive", + }, +] as const; + +export class PCSV3SwapRouter__factory { + static readonly abi = _abi; + static createInterface(): PCSV3SwapRouterInterface { + return new utils.Interface(_abi) as PCSV3SwapRouterInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): PCSV3SwapRouter { + return new Contract(address, _abi, signerOrProvider) as PCSV3SwapRouter; + } +} diff --git a/src/typechain-typesV4/factories/src/base/SwapRouter.sol/SwapRouter__factory.ts b/src/typechain-typesV4/factories/src/base/SwapRouter.sol/SwapRouter__factory.ts new file mode 100644 index 00000000..537c1151 --- /dev/null +++ b/src/typechain-typesV4/factories/src/base/SwapRouter.sol/SwapRouter__factory.ts @@ -0,0 +1,206 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + SwapRouter, + SwapRouterInterface, +} from "../../../../src/base/SwapRouter.sol/SwapRouter"; + +const _abi = [ + { + inputs: [], + name: "InvalidRouter", + type: "error", + }, + { + inputs: [], + name: "MismatchETH", + type: "error", + }, + { + inputs: [], + name: "NotAllowlistedRouter", + type: "error", + }, + { + inputs: [], + name: "NotWETH9", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "OwnableInvalidOwner", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "account", + type: "address", + }, + ], + name: "OwnableUnauthorizedAccount", + type: "error", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "previousOwner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "OwnershipTransferred", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "SetAllowlistedRouters", + type: "event", + }, + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + name: "isAllowListedRouter", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "owner", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "renounceOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setAllowlistedRouters", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "transferOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + stateMutability: "payable", + type: "receive", + }, +] as const; + +export class SwapRouter__factory { + static readonly abi = _abi; + static createInterface(): SwapRouterInterface { + return new utils.Interface(_abi) as SwapRouterInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): SwapRouter { + return new Contract(address, _abi, signerOrProvider) as SwapRouter; + } +} diff --git a/src/typechain-typesV4/factories/src/base/SwapRouter.sol/UniV3SwapRouter__factory.ts b/src/typechain-typesV4/factories/src/base/SwapRouter.sol/UniV3SwapRouter__factory.ts new file mode 100644 index 00000000..8cc260d1 --- /dev/null +++ b/src/typechain-typesV4/factories/src/base/SwapRouter.sol/UniV3SwapRouter__factory.ts @@ -0,0 +1,242 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + UniV3SwapRouter, + UniV3SwapRouterInterface, +} from "../../../../src/base/SwapRouter.sol/UniV3SwapRouter"; + +const _abi = [ + { + inputs: [], + name: "InvalidRouter", + type: "error", + }, + { + inputs: [], + name: "MismatchETH", + type: "error", + }, + { + inputs: [], + name: "NotAllowlistedRouter", + type: "error", + }, + { + inputs: [], + name: "NotWETH9", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "owner", + type: "address", + }, + ], + name: "OwnableInvalidOwner", + type: "error", + }, + { + inputs: [ + { + internalType: "address", + name: "account", + type: "address", + }, + ], + name: "OwnableUnauthorizedAccount", + type: "error", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "previousOwner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "OwnershipTransferred", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "SetAllowlistedRouters", + type: "event", + }, + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "factory", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + name: "isAllowListedRouter", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "owner", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "renounceOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setAllowlistedRouters", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "newOwner", + type: "address", + }, + ], + name: "transferOwnership", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "int256", + name: "amount0Delta", + type: "int256", + }, + { + internalType: "int256", + name: "amount1Delta", + type: "int256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "uniswapV3SwapCallback", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + stateMutability: "payable", + type: "receive", + }, +] as const; + +export class UniV3SwapRouter__factory { + static readonly abi = _abi; + static createInterface(): UniV3SwapRouterInterface { + return new utils.Interface(_abi) as UniV3SwapRouterInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): UniV3SwapRouter { + return new Contract(address, _abi, signerOrProvider) as UniV3SwapRouter; + } +} diff --git a/src/typechain-typesV4/factories/src/base/SwapRouter.sol/index.ts b/src/typechain-typesV4/factories/src/base/SwapRouter.sol/index.ts new file mode 100644 index 00000000..8d24821b --- /dev/null +++ b/src/typechain-typesV4/factories/src/base/SwapRouter.sol/index.ts @@ -0,0 +1,6 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export { PCSV3SwapRouter__factory } from "./PCSV3SwapRouter__factory"; +export { SwapRouter__factory } from "./SwapRouter__factory"; +export { UniV3SwapRouter__factory } from "./UniV3SwapRouter__factory"; diff --git a/src/typechain-typesV4/factories/src/base/index.ts b/src/typechain-typesV4/factories/src/base/index.ts new file mode 100644 index 00000000..40ca314e --- /dev/null +++ b/src/typechain-typesV4/factories/src/base/index.ts @@ -0,0 +1,10 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as callbackSol from "./Callback.sol"; +export * as immutablesSol from "./Immutables.sol"; +export * as swapRouterSol from "./SwapRouter.sol"; +export { Automan__factory } from "./Automan__factory"; +export { OptimalSwapRouter__factory } from "./OptimalSwapRouter__factory"; +export { Payments__factory } from "./Payments__factory"; +export { SlipStreamSwapRouter__factory } from "./SlipStreamSwapRouter__factory"; diff --git a/src/typechain-typesV4/factories/src/index.ts b/src/typechain-typesV4/factories/src/index.ts new file mode 100644 index 00000000..8f9d023d --- /dev/null +++ b/src/typechain-typesV4/factories/src/index.ts @@ -0,0 +1,12 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as base from "./base"; +export * as interfaces from "./interfaces"; +export * as libraries from "./libraries"; +export { PCSV3Automan__factory } from "./PCSV3Automan__factory"; +export { PCSV3OptimalSwapRouter__factory } from "./PCSV3OptimalSwapRouter__factory"; +export { SlipStreamAutoman__factory } from "./SlipStreamAutoman__factory"; +export { SlipStreamOptimalSwapRouter__factory } from "./SlipStreamOptimalSwapRouter__factory"; +export { UniV3Automan__factory } from "./UniV3Automan__factory"; +export { UniV3OptimalSwapRouter__factory } from "./UniV3OptimalSwapRouter__factory"; diff --git a/src/typechain-typesV4/factories/src/interfaces/IAutoman.sol/IAutomanCommon__factory.ts b/src/typechain-typesV4/factories/src/interfaces/IAutoman.sol/IAutomanCommon__factory.ts new file mode 100644 index 00000000..630c3b0b --- /dev/null +++ b/src/typechain-typesV4/factories/src/interfaces/IAutoman.sol/IAutomanCommon__factory.ts @@ -0,0 +1,1033 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IAutomanCommon, + IAutomanCommonInterface, +} from "../../../../src/interfaces/IAutoman.sol/IAutomanCommon"; + +const _abi = [ + { + inputs: [], + name: "FeeLimitExceeded", + type: "error", + }, + { + inputs: [], + name: "InsufficientAmount", + type: "error", + }, + { + inputs: [], + name: "InvalidRouter", + type: "error", + }, + { + inputs: [], + name: "NotAllowlistedRouter", + type: "error", + }, + { + inputs: [], + name: "NotApproved", + type: "error", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "controllers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "ControllersSet", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "DecreaseLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address", + name: "feeCollector", + type: "address", + }, + { + indexed: false, + internalType: "uint96", + name: "feeLimitPips", + type: "uint96", + }, + ], + name: "FeeConfigSet", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "IncreaseLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Mint", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Rebalance", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Reinvest", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "RemoveLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "SetAllowlistedRouters", + type: "event", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + ], + name: "decreaseLiquidity", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "decreaseLiquidity", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenOut", + type: "address", + }, + { + internalType: "uint256", + name: "tokenOutMin", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + ], + name: "decreaseLiquidityToTokenOut", + outputs: [ + { + internalType: "uint256", + name: "tokenOutAmount", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenOut", + type: "address", + }, + { + internalType: "uint256", + name: "tokenOutMin", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "decreaseLiquidityToTokenOut", + outputs: [ + { + internalType: "uint256", + name: "tokenOutAmount", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "V3PoolCallee", + name: "pool", + type: "address", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + ], + name: "getOptimalSwap", + outputs: [ + { + internalType: "uint256", + name: "amountIn", + type: "uint256", + }, + { + internalType: "uint256", + name: "amountOut", + type: "uint256", + }, + { + internalType: "bool", + name: "zeroForOne", + type: "bool", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + ], + name: "increaseLiquidity", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + ], + name: "increaseLiquidityOptimal", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenIn", + type: "address", + }, + { + internalType: "uint256", + name: "tokenInFeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + ], + name: "increaseLiquidityWithTokenIn", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "addressToCheck", + type: "address", + }, + ], + name: "isController", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + ], + name: "reinvest", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "reinvest", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setAllowlistedRouters", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "controllers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setControllers", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "feeCollector", + type: "address", + }, + { + internalType: "uint96", + name: "feeLimitPips", + type: "uint96", + }, + ], + internalType: "struct IAutomanCommon.FeeConfig", + name: "_feeConfig", + type: "tuple", + }, + ], + name: "setFeeConfig", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, +] as const; + +export class IAutomanCommon__factory { + static readonly abi = _abi; + static createInterface(): IAutomanCommonInterface { + return new utils.Interface(_abi) as IAutomanCommonInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IAutomanCommon { + return new Contract(address, _abi, signerOrProvider) as IAutomanCommon; + } +} diff --git a/src/typechain-typesV4/factories/src/interfaces/IAutoman.sol/IAutomanSlipStreamMintRebalance__factory.ts b/src/typechain-typesV4/factories/src/interfaces/IAutoman.sol/IAutomanSlipStreamMintRebalance__factory.ts new file mode 100644 index 00000000..943be0b8 --- /dev/null +++ b/src/typechain-typesV4/factories/src/interfaces/IAutoman.sol/IAutomanSlipStreamMintRebalance__factory.ts @@ -0,0 +1,607 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IAutomanSlipStreamMintRebalance, + IAutomanSlipStreamMintRebalanceInterface, +} from "../../../../src/interfaces/IAutoman.sol/IAutomanSlipStreamMintRebalance"; + +const _abi = [ + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "int24", + name: "tickSpacing", + type: "int24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + internalType: "struct ISlipStreamNonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + ], + name: "mint", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "int24", + name: "tickSpacing", + type: "int24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + internalType: "struct ISlipStreamNonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + ], + name: "mintOptimal", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "int24", + name: "tickSpacing", + type: "int24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + internalType: "struct ISlipStreamNonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenIn", + type: "address", + }, + { + internalType: "uint256", + name: "tokenInFeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + ], + name: "mintWithTokenIn", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "int24", + name: "tickSpacing", + type: "int24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + internalType: "struct ISlipStreamNonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "rebalance", + outputs: [ + { + internalType: "uint256", + name: "newTokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "int24", + name: "tickSpacing", + type: "int24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + internalType: "struct ISlipStreamNonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + ], + name: "rebalance", + outputs: [ + { + internalType: "uint256", + name: "newTokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, +] as const; + +export class IAutomanSlipStreamMintRebalance__factory { + static readonly abi = _abi; + static createInterface(): IAutomanSlipStreamMintRebalanceInterface { + return new utils.Interface( + _abi + ) as IAutomanSlipStreamMintRebalanceInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IAutomanSlipStreamMintRebalance { + return new Contract( + address, + _abi, + signerOrProvider + ) as IAutomanSlipStreamMintRebalance; + } +} diff --git a/src/typechain-typesV4/factories/src/interfaces/IAutoman.sol/IAutomanUniV3MintRebalance__factory.ts b/src/typechain-typesV4/factories/src/interfaces/IAutoman.sol/IAutomanUniV3MintRebalance__factory.ts new file mode 100644 index 00000000..882cc60d --- /dev/null +++ b/src/typechain-typesV4/factories/src/interfaces/IAutoman.sol/IAutomanUniV3MintRebalance__factory.ts @@ -0,0 +1,580 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IAutomanUniV3MintRebalance, + IAutomanUniV3MintRebalanceInterface, +} from "../../../../src/interfaces/IAutoman.sol/IAutomanUniV3MintRebalance"; + +const _abi = [ + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + ], + name: "mint", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + ], + name: "mintOptimal", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenIn", + type: "address", + }, + { + internalType: "uint256", + name: "tokenInFeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + ], + name: "mintWithTokenIn", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + ], + name: "rebalance", + outputs: [ + { + internalType: "uint256", + name: "newTokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "rebalance", + outputs: [ + { + internalType: "uint256", + name: "newTokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, +] as const; + +export class IAutomanUniV3MintRebalance__factory { + static readonly abi = _abi; + static createInterface(): IAutomanUniV3MintRebalanceInterface { + return new utils.Interface(_abi) as IAutomanUniV3MintRebalanceInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IAutomanUniV3MintRebalance { + return new Contract( + address, + _abi, + signerOrProvider + ) as IAutomanUniV3MintRebalance; + } +} diff --git a/src/typechain-typesV4/factories/src/interfaces/IAutoman.sol/IPCSV3Automan__factory.ts b/src/typechain-typesV4/factories/src/interfaces/IAutoman.sol/IPCSV3Automan__factory.ts new file mode 100644 index 00000000..32089c33 --- /dev/null +++ b/src/typechain-typesV4/factories/src/interfaces/IAutoman.sol/IPCSV3Automan__factory.ts @@ -0,0 +1,1645 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IPCSV3Automan, + IPCSV3AutomanInterface, +} from "../../../../src/interfaces/IAutoman.sol/IPCSV3Automan"; + +const _abi = [ + { + inputs: [], + name: "FeeLimitExceeded", + type: "error", + }, + { + inputs: [], + name: "InsufficientAmount", + type: "error", + }, + { + inputs: [], + name: "InvalidRouter", + type: "error", + }, + { + inputs: [], + name: "NotAllowlistedRouter", + type: "error", + }, + { + inputs: [], + name: "NotApproved", + type: "error", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "controllers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "ControllersSet", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "DecreaseLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address", + name: "feeCollector", + type: "address", + }, + { + indexed: false, + internalType: "uint96", + name: "feeLimitPips", + type: "uint96", + }, + ], + name: "FeeConfigSet", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "IncreaseLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Mint", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Rebalance", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Reinvest", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "RemoveLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "SetAllowlistedRouters", + type: "event", + }, + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + ], + name: "decreaseLiquidity", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "decreaseLiquidity", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenOut", + type: "address", + }, + { + internalType: "uint256", + name: "tokenOutMin", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + ], + name: "decreaseLiquidityToTokenOut", + outputs: [ + { + internalType: "uint256", + name: "tokenOutAmount", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenOut", + type: "address", + }, + { + internalType: "uint256", + name: "tokenOutMin", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "decreaseLiquidityToTokenOut", + outputs: [ + { + internalType: "uint256", + name: "tokenOutAmount", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [], + name: "deployer", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "V3PoolCallee", + name: "pool", + type: "address", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + ], + name: "getOptimalSwap", + outputs: [ + { + internalType: "uint256", + name: "amountIn", + type: "uint256", + }, + { + internalType: "uint256", + name: "amountOut", + type: "uint256", + }, + { + internalType: "bool", + name: "zeroForOne", + type: "bool", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + ], + name: "increaseLiquidity", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + ], + name: "increaseLiquidityOptimal", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenIn", + type: "address", + }, + { + internalType: "uint256", + name: "tokenInFeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + ], + name: "increaseLiquidityWithTokenIn", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "addressToCheck", + type: "address", + }, + ], + name: "isController", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + ], + name: "mint", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + ], + name: "mintOptimal", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenIn", + type: "address", + }, + { + internalType: "uint256", + name: "tokenInFeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + ], + name: "mintWithTokenIn", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "int256", + name: "amount0Delta", + type: "int256", + }, + { + internalType: "int256", + name: "amount1Delta", + type: "int256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "pancakeV3SwapCallback", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + ], + name: "rebalance", + outputs: [ + { + internalType: "uint256", + name: "newTokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "rebalance", + outputs: [ + { + internalType: "uint256", + name: "newTokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + ], + name: "reinvest", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "reinvest", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setAllowlistedRouters", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "controllers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setControllers", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "feeCollector", + type: "address", + }, + { + internalType: "uint96", + name: "feeLimitPips", + type: "uint96", + }, + ], + internalType: "struct IAutomanCommon.FeeConfig", + name: "_feeConfig", + type: "tuple", + }, + ], + name: "setFeeConfig", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, +] as const; + +export class IPCSV3Automan__factory { + static readonly abi = _abi; + static createInterface(): IPCSV3AutomanInterface { + return new utils.Interface(_abi) as IPCSV3AutomanInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IPCSV3Automan { + return new Contract(address, _abi, signerOrProvider) as IPCSV3Automan; + } +} diff --git a/src/typechain-typesV4/factories/src/interfaces/IAutoman.sol/ISlipStreamAutoman__factory.ts b/src/typechain-typesV4/factories/src/interfaces/IAutoman.sol/ISlipStreamAutoman__factory.ts new file mode 100644 index 00000000..aaed250a --- /dev/null +++ b/src/typechain-typesV4/factories/src/interfaces/IAutoman.sol/ISlipStreamAutoman__factory.ts @@ -0,0 +1,1670 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + ISlipStreamAutoman, + ISlipStreamAutomanInterface, +} from "../../../../src/interfaces/IAutoman.sol/ISlipStreamAutoman"; + +const _abi = [ + { + inputs: [], + name: "FeeLimitExceeded", + type: "error", + }, + { + inputs: [], + name: "InsufficientAmount", + type: "error", + }, + { + inputs: [], + name: "InvalidRouter", + type: "error", + }, + { + inputs: [], + name: "NotAllowlistedRouter", + type: "error", + }, + { + inputs: [], + name: "NotApproved", + type: "error", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "controllers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "ControllersSet", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "DecreaseLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address", + name: "feeCollector", + type: "address", + }, + { + indexed: false, + internalType: "uint96", + name: "feeLimitPips", + type: "uint96", + }, + ], + name: "FeeConfigSet", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "IncreaseLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Mint", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Rebalance", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Reinvest", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "RemoveLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "SetAllowlistedRouters", + type: "event", + }, + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + ], + name: "decreaseLiquidity", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "decreaseLiquidity", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenOut", + type: "address", + }, + { + internalType: "uint256", + name: "tokenOutMin", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + ], + name: "decreaseLiquidityToTokenOut", + outputs: [ + { + internalType: "uint256", + name: "tokenOutAmount", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenOut", + type: "address", + }, + { + internalType: "uint256", + name: "tokenOutMin", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "decreaseLiquidityToTokenOut", + outputs: [ + { + internalType: "uint256", + name: "tokenOutAmount", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [], + name: "factory", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "V3PoolCallee", + name: "pool", + type: "address", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + ], + name: "getOptimalSwap", + outputs: [ + { + internalType: "uint256", + name: "amountIn", + type: "uint256", + }, + { + internalType: "uint256", + name: "amountOut", + type: "uint256", + }, + { + internalType: "bool", + name: "zeroForOne", + type: "bool", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + ], + name: "increaseLiquidity", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + ], + name: "increaseLiquidityOptimal", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenIn", + type: "address", + }, + { + internalType: "uint256", + name: "tokenInFeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + ], + name: "increaseLiquidityWithTokenIn", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "addressToCheck", + type: "address", + }, + ], + name: "isController", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "int24", + name: "tickSpacing", + type: "int24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + internalType: "struct ISlipStreamNonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + ], + name: "mint", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "int24", + name: "tickSpacing", + type: "int24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + internalType: "struct ISlipStreamNonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + ], + name: "mintOptimal", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "int24", + name: "tickSpacing", + type: "int24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + internalType: "struct ISlipStreamNonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenIn", + type: "address", + }, + { + internalType: "uint256", + name: "tokenInFeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + ], + name: "mintWithTokenIn", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "int24", + name: "tickSpacing", + type: "int24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + internalType: "struct ISlipStreamNonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "rebalance", + outputs: [ + { + internalType: "uint256", + name: "newTokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "int24", + name: "tickSpacing", + type: "int24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + internalType: "struct ISlipStreamNonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + ], + name: "rebalance", + outputs: [ + { + internalType: "uint256", + name: "newTokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + ], + name: "reinvest", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "reinvest", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setAllowlistedRouters", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "controllers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setControllers", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "feeCollector", + type: "address", + }, + { + internalType: "uint96", + name: "feeLimitPips", + type: "uint96", + }, + ], + internalType: "struct IAutomanCommon.FeeConfig", + name: "_feeConfig", + type: "tuple", + }, + ], + name: "setFeeConfig", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "int256", + name: "amount0Delta", + type: "int256", + }, + { + internalType: "int256", + name: "amount1Delta", + type: "int256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "uniswapV3SwapCallback", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, +] as const; + +export class ISlipStreamAutoman__factory { + static readonly abi = _abi; + static createInterface(): ISlipStreamAutomanInterface { + return new utils.Interface(_abi) as ISlipStreamAutomanInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): ISlipStreamAutoman { + return new Contract(address, _abi, signerOrProvider) as ISlipStreamAutoman; + } +} diff --git a/src/typechain-typesV4/factories/src/interfaces/IAutoman.sol/IUniV3Automan__factory.ts b/src/typechain-typesV4/factories/src/interfaces/IAutoman.sol/IUniV3Automan__factory.ts new file mode 100644 index 00000000..e5a2b444 --- /dev/null +++ b/src/typechain-typesV4/factories/src/interfaces/IAutoman.sol/IUniV3Automan__factory.ts @@ -0,0 +1,1645 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IUniV3Automan, + IUniV3AutomanInterface, +} from "../../../../src/interfaces/IAutoman.sol/IUniV3Automan"; + +const _abi = [ + { + inputs: [], + name: "FeeLimitExceeded", + type: "error", + }, + { + inputs: [], + name: "InsufficientAmount", + type: "error", + }, + { + inputs: [], + name: "InvalidRouter", + type: "error", + }, + { + inputs: [], + name: "NotAllowlistedRouter", + type: "error", + }, + { + inputs: [], + name: "NotApproved", + type: "error", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "controllers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "ControllersSet", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "DecreaseLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address", + name: "feeCollector", + type: "address", + }, + { + indexed: false, + internalType: "uint96", + name: "feeLimitPips", + type: "uint96", + }, + ], + name: "FeeConfigSet", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "IncreaseLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Mint", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Rebalance", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "Reinvest", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "RemoveLiquidity", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "SetAllowlistedRouters", + type: "event", + }, + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + ], + name: "decreaseLiquidity", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "decreaseLiquidity", + outputs: [ + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenOut", + type: "address", + }, + { + internalType: "uint256", + name: "tokenOutMin", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + ], + name: "decreaseLiquidityToTokenOut", + outputs: [ + { + internalType: "uint256", + name: "tokenOutAmount", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.DecreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenOut", + type: "address", + }, + { + internalType: "uint256", + name: "tokenOutMin", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + { + internalType: "bool", + name: "isUnwrapNative", + type: "bool", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "decreaseLiquidityToTokenOut", + outputs: [ + { + internalType: "uint256", + name: "tokenOutAmount", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [], + name: "factory", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "V3PoolCallee", + name: "pool", + type: "address", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + ], + name: "getOptimalSwap", + outputs: [ + { + internalType: "uint256", + name: "amountIn", + type: "uint256", + }, + { + internalType: "uint256", + name: "amountOut", + type: "uint256", + }, + { + internalType: "bool", + name: "zeroForOne", + type: "bool", + }, + { + internalType: "uint160", + name: "sqrtPriceX96", + type: "uint160", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + ], + name: "increaseLiquidity", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + ], + name: "increaseLiquidityOptimal", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenIn", + type: "address", + }, + { + internalType: "uint256", + name: "tokenInFeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + ], + name: "increaseLiquidityWithTokenIn", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "addressToCheck", + type: "address", + }, + ], + name: "isController", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + ], + name: "mint", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + ], + name: "mintOptimal", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "address", + name: "tokenIn", + type: "address", + }, + { + internalType: "uint256", + name: "tokenInFeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData0", + type: "bytes", + }, + { + internalType: "bytes", + name: "swapData1", + type: "bytes", + }, + ], + name: "mintWithTokenIn", + outputs: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + ], + name: "rebalance", + outputs: [ + { + internalType: "uint256", + name: "newTokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "token0", + type: "address", + }, + { + internalType: "address", + name: "token1", + type: "address", + }, + { + internalType: "uint24", + name: "fee", + type: "uint24", + }, + { + internalType: "int24", + name: "tickLower", + type: "int24", + }, + { + internalType: "int24", + name: "tickUpper", + type: "int24", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "address", + name: "recipient", + type: "address", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: "struct IUniswapV3NonfungiblePositionManager.MintParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "rebalance", + outputs: [ + { + internalType: "uint256", + name: "newTokenId", + type: "uint256", + }, + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + ], + name: "reinvest", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Desired", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount0Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1Min", + type: "uint256", + }, + { + internalType: "uint256", + name: "deadline", + type: "uint256", + }, + ], + internalType: + "struct ICommonNonfungiblePositionManager.IncreaseLiquidityParams", + name: "params", + type: "tuple", + }, + { + internalType: "uint256", + name: "token0FeeAmount", + type: "uint256", + }, + { + internalType: "uint256", + name: "token1FeeAmount", + type: "uint256", + }, + { + internalType: "bytes", + name: "swapData", + type: "bytes", + }, + { + internalType: "uint256", + name: "permitDeadline", + type: "uint256", + }, + { + internalType: "uint8", + name: "v", + type: "uint8", + }, + { + internalType: "bytes32", + name: "r", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "s", + type: "bytes32", + }, + ], + name: "reinvest", + outputs: [ + { + internalType: "uint128", + name: "liquidity", + type: "uint128", + }, + { + internalType: "uint256", + name: "amount0", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount1", + type: "uint256", + }, + ], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setAllowlistedRouters", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "controllers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setControllers", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "address", + name: "feeCollector", + type: "address", + }, + { + internalType: "uint96", + name: "feeLimitPips", + type: "uint96", + }, + ], + internalType: "struct IAutomanCommon.FeeConfig", + name: "_feeConfig", + type: "tuple", + }, + ], + name: "setFeeConfig", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "int256", + name: "amount0Delta", + type: "int256", + }, + { + internalType: "int256", + name: "amount1Delta", + type: "int256", + }, + { + internalType: "bytes", + name: "data", + type: "bytes", + }, + ], + name: "uniswapV3SwapCallback", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, +] as const; + +export class IUniV3Automan__factory { + static readonly abi = _abi; + static createInterface(): IUniV3AutomanInterface { + return new utils.Interface(_abi) as IUniV3AutomanInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IUniV3Automan { + return new Contract(address, _abi, signerOrProvider) as IUniV3Automan; + } +} diff --git a/src/typechain-typesV4/factories/src/interfaces/IAutoman.sol/index.ts b/src/typechain-typesV4/factories/src/interfaces/IAutoman.sol/index.ts new file mode 100644 index 00000000..15bd84cf --- /dev/null +++ b/src/typechain-typesV4/factories/src/interfaces/IAutoman.sol/index.ts @@ -0,0 +1,9 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export { IAutomanCommon__factory } from "./IAutomanCommon__factory"; +export { IAutomanSlipStreamMintRebalance__factory } from "./IAutomanSlipStreamMintRebalance__factory"; +export { IAutomanUniV3MintRebalance__factory } from "./IAutomanUniV3MintRebalance__factory"; +export { IPCSV3Automan__factory } from "./IPCSV3Automan__factory"; +export { ISlipStreamAutoman__factory } from "./ISlipStreamAutoman__factory"; +export { IUniV3Automan__factory } from "./IUniV3Automan__factory"; diff --git a/src/typechain-typesV4/factories/src/interfaces/IImmutables.sol/IImmutables__factory.ts b/src/typechain-typesV4/factories/src/interfaces/IImmutables.sol/IImmutables__factory.ts new file mode 100644 index 00000000..8622a8ae --- /dev/null +++ b/src/typechain-typesV4/factories/src/interfaces/IImmutables.sol/IImmutables__factory.ts @@ -0,0 +1,52 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IImmutables, + IImmutablesInterface, +} from "../../../../src/interfaces/IImmutables.sol/IImmutables"; + +const _abi = [ + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, +] as const; + +export class IImmutables__factory { + static readonly abi = _abi; + static createInterface(): IImmutablesInterface { + return new utils.Interface(_abi) as IImmutablesInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IImmutables { + return new Contract(address, _abi, signerOrProvider) as IImmutables; + } +} diff --git a/src/typechain-typesV4/factories/src/interfaces/IImmutables.sol/IPCSV3Immutables__factory.ts b/src/typechain-typesV4/factories/src/interfaces/IImmutables.sol/IPCSV3Immutables__factory.ts new file mode 100644 index 00000000..58bc0f6a --- /dev/null +++ b/src/typechain-typesV4/factories/src/interfaces/IImmutables.sol/IPCSV3Immutables__factory.ts @@ -0,0 +1,65 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IPCSV3Immutables, + IPCSV3ImmutablesInterface, +} from "../../../../src/interfaces/IImmutables.sol/IPCSV3Immutables"; + +const _abi = [ + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "deployer", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, +] as const; + +export class IPCSV3Immutables__factory { + static readonly abi = _abi; + static createInterface(): IPCSV3ImmutablesInterface { + return new utils.Interface(_abi) as IPCSV3ImmutablesInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IPCSV3Immutables { + return new Contract(address, _abi, signerOrProvider) as IPCSV3Immutables; + } +} diff --git a/src/typechain-typesV4/factories/src/interfaces/IImmutables.sol/IUniV3Immutables__factory.ts b/src/typechain-typesV4/factories/src/interfaces/IImmutables.sol/IUniV3Immutables__factory.ts new file mode 100644 index 00000000..2731717f --- /dev/null +++ b/src/typechain-typesV4/factories/src/interfaces/IImmutables.sol/IUniV3Immutables__factory.ts @@ -0,0 +1,65 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + IUniV3Immutables, + IUniV3ImmutablesInterface, +} from "../../../../src/interfaces/IImmutables.sol/IUniV3Immutables"; + +const _abi = [ + { + inputs: [], + name: "WETH9", + outputs: [ + { + internalType: "address payable", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "factory", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "npm", + outputs: [ + { + internalType: "contract ICommonNonfungiblePositionManager", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, +] as const; + +export class IUniV3Immutables__factory { + static readonly abi = _abi; + static createInterface(): IUniV3ImmutablesInterface { + return new utils.Interface(_abi) as IUniV3ImmutablesInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IUniV3Immutables { + return new Contract(address, _abi, signerOrProvider) as IUniV3Immutables; + } +} diff --git a/src/typechain-typesV4/factories/src/interfaces/IImmutables.sol/index.ts b/src/typechain-typesV4/factories/src/interfaces/IImmutables.sol/index.ts new file mode 100644 index 00000000..ec386e12 --- /dev/null +++ b/src/typechain-typesV4/factories/src/interfaces/IImmutables.sol/index.ts @@ -0,0 +1,6 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export { IImmutables__factory } from "./IImmutables__factory"; +export { IPCSV3Immutables__factory } from "./IPCSV3Immutables__factory"; +export { IUniV3Immutables__factory } from "./IUniV3Immutables__factory"; diff --git a/src/typechain-typesV4/factories/src/interfaces/ISwapRouter.sol/ISwapRouterCommon__factory.ts b/src/typechain-typesV4/factories/src/interfaces/ISwapRouter.sol/ISwapRouterCommon__factory.ts new file mode 100644 index 00000000..959eab25 --- /dev/null +++ b/src/typechain-typesV4/factories/src/interfaces/ISwapRouter.sol/ISwapRouterCommon__factory.ts @@ -0,0 +1,73 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + ISwapRouterCommon, + ISwapRouterCommonInterface, +} from "../../../../src/interfaces/ISwapRouter.sol/ISwapRouterCommon"; + +const _abi = [ + { + inputs: [], + name: "InvalidRouter", + type: "error", + }, + { + inputs: [], + name: "NotAllowlistedRouter", + type: "error", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + indexed: false, + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "SetAllowlistedRouters", + type: "event", + }, + { + inputs: [ + { + internalType: "address[]", + name: "routers", + type: "address[]", + }, + { + internalType: "bool[]", + name: "statuses", + type: "bool[]", + }, + ], + name: "setAllowlistedRouters", + outputs: [], + stateMutability: "payable", + type: "function", + }, +] as const; + +export class ISwapRouterCommon__factory { + static readonly abi = _abi; + static createInterface(): ISwapRouterCommonInterface { + return new utils.Interface(_abi) as ISwapRouterCommonInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): ISwapRouterCommon { + return new Contract(address, _abi, signerOrProvider) as ISwapRouterCommon; + } +} diff --git a/src/typechain-typesV4/factories/src/interfaces/ISwapRouter.sol/index.ts b/src/typechain-typesV4/factories/src/interfaces/ISwapRouter.sol/index.ts new file mode 100644 index 00000000..0da4b54e --- /dev/null +++ b/src/typechain-typesV4/factories/src/interfaces/ISwapRouter.sol/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export { ISwapRouterCommon__factory } from "./ISwapRouterCommon__factory"; diff --git a/src/typechain-typesV4/factories/src/interfaces/index.ts b/src/typechain-typesV4/factories/src/interfaces/index.ts new file mode 100644 index 00000000..1aaece72 --- /dev/null +++ b/src/typechain-typesV4/factories/src/interfaces/index.ts @@ -0,0 +1,6 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as iAutomanSol from "./IAutoman.sol"; +export * as iImmutablesSol from "./IImmutables.sol"; +export * as iSwapRouterSol from "./ISwapRouter.sol"; diff --git a/src/typechain-typesV4/factories/src/libraries/OptimalSwap__factory.ts b/src/typechain-typesV4/factories/src/libraries/OptimalSwap__factory.ts new file mode 100644 index 00000000..a4ac2f92 --- /dev/null +++ b/src/typechain-typesV4/factories/src/libraries/OptimalSwap__factory.ts @@ -0,0 +1,77 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import { Signer, utils, Contract, ContractFactory, Overrides } from "ethers"; +import type { Provider, TransactionRequest } from "@ethersproject/providers"; +import type { + OptimalSwap, + OptimalSwapInterface, +} from "../../../src/libraries/OptimalSwap"; + +const _abi = [ + { + inputs: [], + name: "Invalid_Pool", + type: "error", + }, + { + inputs: [], + name: "Invalid_Tick_Range", + type: "error", + }, + { + inputs: [], + name: "Math_Overflow", + type: "error", + }, +] as const; + +const _bytecode = + "0x6080806040523460175760119081601d823930815050f35b600080fdfe600080fdfea164736f6c634300081a000a"; + +type OptimalSwapConstructorParams = + | [signer?: Signer] + | ConstructorParameters; + +const isSuperArgs = ( + xs: OptimalSwapConstructorParams +): xs is ConstructorParameters => xs.length > 1; + +export class OptimalSwap__factory extends ContractFactory { + constructor(...args: OptimalSwapConstructorParams) { + if (isSuperArgs(args)) { + super(...args); + } else { + super(_abi, _bytecode, args[0]); + } + } + + override deploy( + overrides?: Overrides & { from?: string } + ): Promise { + return super.deploy(overrides || {}) as Promise; + } + override getDeployTransaction( + overrides?: Overrides & { from?: string } + ): TransactionRequest { + return super.getDeployTransaction(overrides || {}); + } + override attach(address: string): OptimalSwap { + return super.attach(address) as OptimalSwap; + } + override connect(signer: Signer): OptimalSwap__factory { + return super.connect(signer) as OptimalSwap__factory; + } + + static readonly bytecode = _bytecode; + static readonly abi = _abi; + static createInterface(): OptimalSwapInterface { + return new utils.Interface(_abi) as OptimalSwapInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): OptimalSwap { + return new Contract(address, _abi, signerOrProvider) as OptimalSwap; + } +} diff --git a/src/typechain-typesV4/factories/src/libraries/SlipStreamPoolAddress.sol/ISlipStreamCLFactory__factory.ts b/src/typechain-typesV4/factories/src/libraries/SlipStreamPoolAddress.sol/ISlipStreamCLFactory__factory.ts new file mode 100644 index 00000000..62d6b460 --- /dev/null +++ b/src/typechain-typesV4/factories/src/libraries/SlipStreamPoolAddress.sol/ISlipStreamCLFactory__factory.ts @@ -0,0 +1,43 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import type { Provider } from "@ethersproject/providers"; +import type { + ISlipStreamCLFactory, + ISlipStreamCLFactoryInterface, +} from "../../../../src/libraries/SlipStreamPoolAddress.sol/ISlipStreamCLFactory"; + +const _abi = [ + { + inputs: [], + name: "poolImplementation", + outputs: [ + { + internalType: "address", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, +] as const; + +export class ISlipStreamCLFactory__factory { + static readonly abi = _abi; + static createInterface(): ISlipStreamCLFactoryInterface { + return new utils.Interface(_abi) as ISlipStreamCLFactoryInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): ISlipStreamCLFactory { + return new Contract( + address, + _abi, + signerOrProvider + ) as ISlipStreamCLFactory; + } +} diff --git a/src/typechain-typesV4/factories/src/libraries/SlipStreamPoolAddress.sol/index.ts b/src/typechain-typesV4/factories/src/libraries/SlipStreamPoolAddress.sol/index.ts new file mode 100644 index 00000000..48ecdaec --- /dev/null +++ b/src/typechain-typesV4/factories/src/libraries/SlipStreamPoolAddress.sol/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export { ISlipStreamCLFactory__factory } from "./ISlipStreamCLFactory__factory"; diff --git a/src/typechain-typesV4/factories/src/libraries/index.ts b/src/typechain-typesV4/factories/src/libraries/index.ts new file mode 100644 index 00000000..ef22e100 --- /dev/null +++ b/src/typechain-typesV4/factories/src/libraries/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export * as slipStreamPoolAddressSol from "./SlipStreamPoolAddress.sol"; +export { OptimalSwap__factory } from "./OptimalSwap__factory"; diff --git a/src/typechain-typesV4/hardhat.d.ts b/src/typechain-typesV4/hardhat.d.ts new file mode 100644 index 00000000..24c7603d --- /dev/null +++ b/src/typechain-typesV4/hardhat.d.ts @@ -0,0 +1,636 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { ethers } from "ethers"; +import { + FactoryOptions, + HardhatEthersHelpers as HardhatEthersHelpersBase, +} from "@nomiclabs/hardhat-ethers/types"; + +import * as Contracts from "."; + +declare module "hardhat/types/runtime" { + interface HardhatEthersHelpers extends HardhatEthersHelpersBase { + getContractFactory( + name: "FullMath", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "ICommonNonfungiblePositionManager", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IPCSV3NonfungiblePositionManager", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "ISlipStreamNonfungiblePositionManager", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IUniswapV3NonfungiblePositionManager", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "Ownable", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IERC20Metadata", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IERC20", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IERC721Enumerable", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IERC721Metadata", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IERC721", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IERC165", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IPancakeV3SwapCallback", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IPancakeV3Pool", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IPancakeV3PoolActions", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IPancakeV3PoolDerivedState", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IPancakeV3PoolEvents", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IPancakeV3PoolImmutables", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IPancakeV3PoolOwnerActions", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IPancakeV3PoolState", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IUniswapV3SwapCallback", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IUniswapV3Pool", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IUniswapV3PoolActions", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IUniswapV3PoolDerivedState", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IUniswapV3PoolEvents", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IUniswapV3PoolImmutables", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IUniswapV3PoolOwnerActions", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IUniswapV3PoolState", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IERC721Permit", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IPeripheryImmutableState", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IPeripheryPayments", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IPoolInitializer", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "ERC20", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "WETH", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "FixedPointMathLib", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "SafeTransferLib", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "Automan", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "PancakeV3Callback", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "SlipStreamCallback", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "UniswapV3Callback", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "Immutables", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "PCSV3Immutables", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "UniV3Immutables", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "OptimalSwapRouter", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "Payments", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "SlipStreamSwapRouter", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "PCSV3SwapRouter", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "SwapRouter", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "UniV3SwapRouter", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IAutomanCommon", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IAutomanSlipStreamMintRebalance", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IAutomanUniV3MintRebalance", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IPCSV3Automan", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "ISlipStreamAutoman", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IUniV3Automan", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IImmutables", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IPCSV3Immutables", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "IUniV3Immutables", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "ISwapRouterCommon", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "OptimalSwap", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "ISlipStreamCLFactory", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "PCSV3Automan", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "PCSV3OptimalSwapRouter", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "SlipStreamAutoman", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "SlipStreamOptimalSwapRouter", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "UniV3Automan", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "UniV3OptimalSwapRouter", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + + getContractAt( + name: "FullMath", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "ICommonNonfungiblePositionManager", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IPCSV3NonfungiblePositionManager", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "ISlipStreamNonfungiblePositionManager", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IUniswapV3NonfungiblePositionManager", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "Ownable", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IERC20Metadata", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IERC20", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IERC721Enumerable", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IERC721Metadata", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IERC721", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IERC165", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IPancakeV3SwapCallback", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IPancakeV3Pool", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IPancakeV3PoolActions", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IPancakeV3PoolDerivedState", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IPancakeV3PoolEvents", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IPancakeV3PoolImmutables", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IPancakeV3PoolOwnerActions", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IPancakeV3PoolState", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IUniswapV3SwapCallback", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IUniswapV3Pool", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IUniswapV3PoolActions", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IUniswapV3PoolDerivedState", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IUniswapV3PoolEvents", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IUniswapV3PoolImmutables", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IUniswapV3PoolOwnerActions", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IUniswapV3PoolState", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IERC721Permit", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IPeripheryImmutableState", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IPeripheryPayments", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IPoolInitializer", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "ERC20", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "WETH", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "FixedPointMathLib", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "SafeTransferLib", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "Automan", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "PancakeV3Callback", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "SlipStreamCallback", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "UniswapV3Callback", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "Immutables", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "PCSV3Immutables", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "UniV3Immutables", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "OptimalSwapRouter", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "Payments", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "SlipStreamSwapRouter", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "PCSV3SwapRouter", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "SwapRouter", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "UniV3SwapRouter", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IAutomanCommon", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IAutomanSlipStreamMintRebalance", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IAutomanUniV3MintRebalance", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IPCSV3Automan", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "ISlipStreamAutoman", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IUniV3Automan", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IImmutables", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IPCSV3Immutables", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "IUniV3Immutables", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "ISwapRouterCommon", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "OptimalSwap", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "ISlipStreamCLFactory", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "PCSV3Automan", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "PCSV3OptimalSwapRouter", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "SlipStreamAutoman", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "SlipStreamOptimalSwapRouter", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "UniV3Automan", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "UniV3OptimalSwapRouter", + address: string, + signer?: ethers.Signer + ): Promise; + + // default types + getContractFactory( + name: string, + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + abi: any[], + bytecode: ethers.utils.BytesLike, + signer?: ethers.Signer + ): Promise; + getContractAt( + nameOrAbi: string | any[], + address: string, + signer?: ethers.Signer + ): Promise; + } +} diff --git a/src/typechain-typesV4/index.ts b/src/typechain-typesV4/index.ts new file mode 100644 index 00000000..a1c306db --- /dev/null +++ b/src/typechain-typesV4/index.ts @@ -0,0 +1,150 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as apertureFinance from "./@aperture_finance"; +export type { apertureFinance }; +import type * as openzeppelin from "./@openzeppelin"; +export type { openzeppelin }; +import type * as pancakeswap from "./@pancakeswap"; +export type { pancakeswap }; +import type * as uniswap from "./@uniswap"; +export type { uniswap }; +import type * as solady from "./solady"; +export type { solady }; +import type * as src from "./src"; +export type { src }; +export * as factories from "./factories"; +export type { FullMath } from "./@aperture_finance/uni-v3-lib/src/FullMath"; +export { FullMath__factory } from "./factories/@aperture_finance/uni-v3-lib/src/FullMath__factory"; +export type { ICommonNonfungiblePositionManager } from "./@aperture_finance/uni-v3-lib/src/interfaces/ICommonNonfungiblePositionManager"; +export { ICommonNonfungiblePositionManager__factory } from "./factories/@aperture_finance/uni-v3-lib/src/interfaces/ICommonNonfungiblePositionManager__factory"; +export type { IPCSV3NonfungiblePositionManager } from "./@aperture_finance/uni-v3-lib/src/interfaces/IPCSV3NonfungiblePositionManager"; +export { IPCSV3NonfungiblePositionManager__factory } from "./factories/@aperture_finance/uni-v3-lib/src/interfaces/IPCSV3NonfungiblePositionManager__factory"; +export type { ISlipStreamNonfungiblePositionManager } from "./@aperture_finance/uni-v3-lib/src/interfaces/ISlipStreamNonfungiblePositionManager"; +export { ISlipStreamNonfungiblePositionManager__factory } from "./factories/@aperture_finance/uni-v3-lib/src/interfaces/ISlipStreamNonfungiblePositionManager__factory"; +export type { IUniswapV3NonfungiblePositionManager } from "./@aperture_finance/uni-v3-lib/src/interfaces/IUniswapV3NonfungiblePositionManager"; +export { IUniswapV3NonfungiblePositionManager__factory } from "./factories/@aperture_finance/uni-v3-lib/src/interfaces/IUniswapV3NonfungiblePositionManager__factory"; +export type { Ownable } from "./@openzeppelin/contracts/access/Ownable"; +export { Ownable__factory } from "./factories/@openzeppelin/contracts/access/Ownable__factory"; +export type { IERC20Metadata } from "./@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata"; +export { IERC20Metadata__factory } from "./factories/@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata__factory"; +export type { IERC20 } from "./@openzeppelin/contracts/token/ERC20/IERC20"; +export { IERC20__factory } from "./factories/@openzeppelin/contracts/token/ERC20/IERC20__factory"; +export type { IERC721Enumerable } from "./@openzeppelin/contracts/token/ERC721/extensions/IERC721Enumerable"; +export { IERC721Enumerable__factory } from "./factories/@openzeppelin/contracts/token/ERC721/extensions/IERC721Enumerable__factory"; +export type { IERC721Metadata } from "./@openzeppelin/contracts/token/ERC721/extensions/IERC721Metadata"; +export { IERC721Metadata__factory } from "./factories/@openzeppelin/contracts/token/ERC721/extensions/IERC721Metadata__factory"; +export type { IERC721 } from "./@openzeppelin/contracts/token/ERC721/IERC721"; +export { IERC721__factory } from "./factories/@openzeppelin/contracts/token/ERC721/IERC721__factory"; +export type { IERC165 } from "./@openzeppelin/contracts/utils/introspection/IERC165"; +export { IERC165__factory } from "./factories/@openzeppelin/contracts/utils/introspection/IERC165__factory"; +export type { IPancakeV3SwapCallback } from "./@pancakeswap/v3-core/contracts/interfaces/callback/IPancakeV3SwapCallback"; +export { IPancakeV3SwapCallback__factory } from "./factories/@pancakeswap/v3-core/contracts/interfaces/callback/IPancakeV3SwapCallback__factory"; +export type { IPancakeV3Pool } from "./@pancakeswap/v3-core/contracts/interfaces/IPancakeV3Pool"; +export { IPancakeV3Pool__factory } from "./factories/@pancakeswap/v3-core/contracts/interfaces/IPancakeV3Pool__factory"; +export type { IPancakeV3PoolActions } from "./@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolActions"; +export { IPancakeV3PoolActions__factory } from "./factories/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolActions__factory"; +export type { IPancakeV3PoolDerivedState } from "./@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolDerivedState"; +export { IPancakeV3PoolDerivedState__factory } from "./factories/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolDerivedState__factory"; +export type { IPancakeV3PoolEvents } from "./@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolEvents"; +export { IPancakeV3PoolEvents__factory } from "./factories/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolEvents__factory"; +export type { IPancakeV3PoolImmutables } from "./@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolImmutables"; +export { IPancakeV3PoolImmutables__factory } from "./factories/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolImmutables__factory"; +export type { IPancakeV3PoolOwnerActions } from "./@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolOwnerActions"; +export { IPancakeV3PoolOwnerActions__factory } from "./factories/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolOwnerActions__factory"; +export type { IPancakeV3PoolState } from "./@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolState"; +export { IPancakeV3PoolState__factory } from "./factories/@pancakeswap/v3-core/contracts/interfaces/pool/IPancakeV3PoolState__factory"; +export type { IUniswapV3SwapCallback } from "./@uniswap/v3-core/contracts/interfaces/callback/IUniswapV3SwapCallback"; +export { IUniswapV3SwapCallback__factory } from "./factories/@uniswap/v3-core/contracts/interfaces/callback/IUniswapV3SwapCallback__factory"; +export type { IUniswapV3Pool } from "./@uniswap/v3-core/contracts/interfaces/IUniswapV3Pool"; +export { IUniswapV3Pool__factory } from "./factories/@uniswap/v3-core/contracts/interfaces/IUniswapV3Pool__factory"; +export type { IUniswapV3PoolActions } from "./@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolActions"; +export { IUniswapV3PoolActions__factory } from "./factories/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolActions__factory"; +export type { IUniswapV3PoolDerivedState } from "./@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolDerivedState"; +export { IUniswapV3PoolDerivedState__factory } from "./factories/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolDerivedState__factory"; +export type { IUniswapV3PoolEvents } from "./@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolEvents"; +export { IUniswapV3PoolEvents__factory } from "./factories/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolEvents__factory"; +export type { IUniswapV3PoolImmutables } from "./@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolImmutables"; +export { IUniswapV3PoolImmutables__factory } from "./factories/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolImmutables__factory"; +export type { IUniswapV3PoolOwnerActions } from "./@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolOwnerActions"; +export { IUniswapV3PoolOwnerActions__factory } from "./factories/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolOwnerActions__factory"; +export type { IUniswapV3PoolState } from "./@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolState"; +export { IUniswapV3PoolState__factory } from "./factories/@uniswap/v3-core/contracts/interfaces/pool/IUniswapV3PoolState__factory"; +export type { IERC721Permit } from "./@uniswap/v3-periphery/contracts/interfaces/IERC721Permit"; +export { IERC721Permit__factory } from "./factories/@uniswap/v3-periphery/contracts/interfaces/IERC721Permit__factory"; +export type { IPeripheryImmutableState } from "./@uniswap/v3-periphery/contracts/interfaces/IPeripheryImmutableState"; +export { IPeripheryImmutableState__factory } from "./factories/@uniswap/v3-periphery/contracts/interfaces/IPeripheryImmutableState__factory"; +export type { IPeripheryPayments } from "./@uniswap/v3-periphery/contracts/interfaces/IPeripheryPayments"; +export { IPeripheryPayments__factory } from "./factories/@uniswap/v3-periphery/contracts/interfaces/IPeripheryPayments__factory"; +export type { IPoolInitializer } from "./@uniswap/v3-periphery/contracts/interfaces/IPoolInitializer"; +export { IPoolInitializer__factory } from "./factories/@uniswap/v3-periphery/contracts/interfaces/IPoolInitializer__factory"; +export type { ERC20 } from "./solady/src/tokens/ERC20"; +export { ERC20__factory } from "./factories/solady/src/tokens/ERC20__factory"; +export type { WETH } from "./solady/src/tokens/WETH"; +export { WETH__factory } from "./factories/solady/src/tokens/WETH__factory"; +export type { FixedPointMathLib } from "./solady/src/utils/FixedPointMathLib"; +export { FixedPointMathLib__factory } from "./factories/solady/src/utils/FixedPointMathLib__factory"; +export type { SafeTransferLib } from "./solady/src/utils/SafeTransferLib"; +export { SafeTransferLib__factory } from "./factories/solady/src/utils/SafeTransferLib__factory"; +export type { Automan } from "./src/base/Automan"; +export { Automan__factory } from "./factories/src/base/Automan__factory"; +export type { PancakeV3Callback } from "./src/base/Callback.sol/PancakeV3Callback"; +export { PancakeV3Callback__factory } from "./factories/src/base/Callback.sol/PancakeV3Callback__factory"; +export type { SlipStreamCallback } from "./src/base/Callback.sol/SlipStreamCallback"; +export { SlipStreamCallback__factory } from "./factories/src/base/Callback.sol/SlipStreamCallback__factory"; +export type { UniswapV3Callback } from "./src/base/Callback.sol/UniswapV3Callback"; +export { UniswapV3Callback__factory } from "./factories/src/base/Callback.sol/UniswapV3Callback__factory"; +export type { Immutables } from "./src/base/Immutables.sol/Immutables"; +export { Immutables__factory } from "./factories/src/base/Immutables.sol/Immutables__factory"; +export type { PCSV3Immutables } from "./src/base/Immutables.sol/PCSV3Immutables"; +export { PCSV3Immutables__factory } from "./factories/src/base/Immutables.sol/PCSV3Immutables__factory"; +export type { UniV3Immutables } from "./src/base/Immutables.sol/UniV3Immutables"; +export { UniV3Immutables__factory } from "./factories/src/base/Immutables.sol/UniV3Immutables__factory"; +export type { OptimalSwapRouter } from "./src/base/OptimalSwapRouter"; +export { OptimalSwapRouter__factory } from "./factories/src/base/OptimalSwapRouter__factory"; +export type { Payments } from "./src/base/Payments"; +export { Payments__factory } from "./factories/src/base/Payments__factory"; +export type { SlipStreamSwapRouter } from "./src/base/SlipStreamSwapRouter"; +export { SlipStreamSwapRouter__factory } from "./factories/src/base/SlipStreamSwapRouter__factory"; +export type { PCSV3SwapRouter } from "./src/base/SwapRouter.sol/PCSV3SwapRouter"; +export { PCSV3SwapRouter__factory } from "./factories/src/base/SwapRouter.sol/PCSV3SwapRouter__factory"; +export type { SwapRouter } from "./src/base/SwapRouter.sol/SwapRouter"; +export { SwapRouter__factory } from "./factories/src/base/SwapRouter.sol/SwapRouter__factory"; +export type { UniV3SwapRouter } from "./src/base/SwapRouter.sol/UniV3SwapRouter"; +export { UniV3SwapRouter__factory } from "./factories/src/base/SwapRouter.sol/UniV3SwapRouter__factory"; +export type { IAutomanCommon } from "./src/interfaces/IAutoman.sol/IAutomanCommon"; +export { IAutomanCommon__factory } from "./factories/src/interfaces/IAutoman.sol/IAutomanCommon__factory"; +export type { IAutomanSlipStreamMintRebalance } from "./src/interfaces/IAutoman.sol/IAutomanSlipStreamMintRebalance"; +export { IAutomanSlipStreamMintRebalance__factory } from "./factories/src/interfaces/IAutoman.sol/IAutomanSlipStreamMintRebalance__factory"; +export type { IAutomanUniV3MintRebalance } from "./src/interfaces/IAutoman.sol/IAutomanUniV3MintRebalance"; +export { IAutomanUniV3MintRebalance__factory } from "./factories/src/interfaces/IAutoman.sol/IAutomanUniV3MintRebalance__factory"; +export type { IPCSV3Automan } from "./src/interfaces/IAutoman.sol/IPCSV3Automan"; +export { IPCSV3Automan__factory } from "./factories/src/interfaces/IAutoman.sol/IPCSV3Automan__factory"; +export type { ISlipStreamAutoman } from "./src/interfaces/IAutoman.sol/ISlipStreamAutoman"; +export { ISlipStreamAutoman__factory } from "./factories/src/interfaces/IAutoman.sol/ISlipStreamAutoman__factory"; +export type { IUniV3Automan } from "./src/interfaces/IAutoman.sol/IUniV3Automan"; +export { IUniV3Automan__factory } from "./factories/src/interfaces/IAutoman.sol/IUniV3Automan__factory"; +export type { IImmutables } from "./src/interfaces/IImmutables.sol/IImmutables"; +export { IImmutables__factory } from "./factories/src/interfaces/IImmutables.sol/IImmutables__factory"; +export type { IPCSV3Immutables } from "./src/interfaces/IImmutables.sol/IPCSV3Immutables"; +export { IPCSV3Immutables__factory } from "./factories/src/interfaces/IImmutables.sol/IPCSV3Immutables__factory"; +export type { IUniV3Immutables } from "./src/interfaces/IImmutables.sol/IUniV3Immutables"; +export { IUniV3Immutables__factory } from "./factories/src/interfaces/IImmutables.sol/IUniV3Immutables__factory"; +export type { ISwapRouterCommon } from "./src/interfaces/ISwapRouter.sol/ISwapRouterCommon"; +export { ISwapRouterCommon__factory } from "./factories/src/interfaces/ISwapRouter.sol/ISwapRouterCommon__factory"; +export type { OptimalSwap } from "./src/libraries/OptimalSwap"; +export { OptimalSwap__factory } from "./factories/src/libraries/OptimalSwap__factory"; +export type { ISlipStreamCLFactory } from "./src/libraries/SlipStreamPoolAddress.sol/ISlipStreamCLFactory"; +export { ISlipStreamCLFactory__factory } from "./factories/src/libraries/SlipStreamPoolAddress.sol/ISlipStreamCLFactory__factory"; +export type { PCSV3Automan } from "./src/PCSV3Automan"; +export { PCSV3Automan__factory } from "./factories/src/PCSV3Automan__factory"; +export type { PCSV3OptimalSwapRouter } from "./src/PCSV3OptimalSwapRouter"; +export { PCSV3OptimalSwapRouter__factory } from "./factories/src/PCSV3OptimalSwapRouter__factory"; +export type { SlipStreamAutoman } from "./src/SlipStreamAutoman"; +export { SlipStreamAutoman__factory } from "./factories/src/SlipStreamAutoman__factory"; +export type { SlipStreamOptimalSwapRouter } from "./src/SlipStreamOptimalSwapRouter"; +export { SlipStreamOptimalSwapRouter__factory } from "./factories/src/SlipStreamOptimalSwapRouter__factory"; +export type { UniV3Automan } from "./src/UniV3Automan"; +export { UniV3Automan__factory } from "./factories/src/UniV3Automan__factory"; +export type { UniV3OptimalSwapRouter } from "./src/UniV3OptimalSwapRouter"; +export { UniV3OptimalSwapRouter__factory } from "./factories/src/UniV3OptimalSwapRouter__factory"; diff --git a/src/typechain-typesV4/solady/index.ts b/src/typechain-typesV4/solady/index.ts new file mode 100644 index 00000000..f68cafed --- /dev/null +++ b/src/typechain-typesV4/solady/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as src from "./src"; +export type { src }; diff --git a/src/typechain-typesV4/solady/src/index.ts b/src/typechain-typesV4/solady/src/index.ts new file mode 100644 index 00000000..5f3bc658 --- /dev/null +++ b/src/typechain-typesV4/solady/src/index.ts @@ -0,0 +1,7 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as tokens from "./tokens"; +export type { tokens }; +import type * as utils from "./utils"; +export type { utils }; diff --git a/src/typechain-typesV4/solady/src/tokens/ERC20.ts b/src/typechain-typesV4/solady/src/tokens/ERC20.ts new file mode 100644 index 00000000..b0198526 --- /dev/null +++ b/src/typechain-typesV4/solady/src/tokens/ERC20.ts @@ -0,0 +1,481 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export interface ERC20Interface extends utils.Interface { + functions: { + "DOMAIN_SEPARATOR()": FunctionFragment; + "allowance(address,address)": FunctionFragment; + "approve(address,uint256)": FunctionFragment; + "balanceOf(address)": FunctionFragment; + "decimals()": FunctionFragment; + "name()": FunctionFragment; + "nonces(address)": FunctionFragment; + "permit(address,address,uint256,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "symbol()": FunctionFragment; + "totalSupply()": FunctionFragment; + "transfer(address,uint256)": FunctionFragment; + "transferFrom(address,address,uint256)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "DOMAIN_SEPARATOR" + | "allowance" + | "approve" + | "balanceOf" + | "decimals" + | "name" + | "nonces" + | "permit" + | "symbol" + | "totalSupply" + | "transfer" + | "transferFrom" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "DOMAIN_SEPARATOR", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "allowance", + values: [string, string] + ): string; + encodeFunctionData( + functionFragment: "approve", + values: [string, BigNumberish] + ): string; + encodeFunctionData(functionFragment: "balanceOf", values: [string]): string; + encodeFunctionData(functionFragment: "decimals", values?: undefined): string; + encodeFunctionData(functionFragment: "name", values?: undefined): string; + encodeFunctionData(functionFragment: "nonces", values: [string]): string; + encodeFunctionData( + functionFragment: "permit", + values: [ + string, + string, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData(functionFragment: "symbol", values?: undefined): string; + encodeFunctionData( + functionFragment: "totalSupply", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "transfer", + values: [string, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "transferFrom", + values: [string, string, BigNumberish] + ): string; + + decodeFunctionResult( + functionFragment: "DOMAIN_SEPARATOR", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "allowance", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "approve", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "balanceOf", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "decimals", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "name", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "nonces", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "permit", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "symbol", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "totalSupply", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "transfer", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "transferFrom", + data: BytesLike + ): Result; + + events: { + "Approval(address,address,uint256)": EventFragment; + "Transfer(address,address,uint256)": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "Approval"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Transfer"): EventFragment; +} + +export interface ApprovalEventObject { + owner: string; + spender: string; + amount: BigNumber; +} +export type ApprovalEvent = TypedEvent< + [string, string, BigNumber], + ApprovalEventObject +>; + +export type ApprovalEventFilter = TypedEventFilter; + +export interface TransferEventObject { + from: string; + to: string; + amount: BigNumber; +} +export type TransferEvent = TypedEvent< + [string, string, BigNumber], + TransferEventObject +>; + +export type TransferEventFilter = TypedEventFilter; + +export interface ERC20 extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: ERC20Interface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + DOMAIN_SEPARATOR( + overrides?: CallOverrides + ): Promise<[string] & { result: string }>; + + allowance( + owner: string, + spender: string, + overrides?: CallOverrides + ): Promise<[BigNumber] & { result: BigNumber }>; + + approve( + spender: string, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf( + owner: string, + overrides?: CallOverrides + ): Promise<[BigNumber] & { result: BigNumber }>; + + decimals(overrides?: CallOverrides): Promise<[number]>; + + name(overrides?: CallOverrides): Promise<[string]>; + + nonces( + owner: string, + overrides?: CallOverrides + ): Promise<[BigNumber] & { result: BigNumber }>; + + permit( + owner: string, + spender: string, + value: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + symbol(overrides?: CallOverrides): Promise<[string]>; + + totalSupply( + overrides?: CallOverrides + ): Promise<[BigNumber] & { result: BigNumber }>; + + transfer( + to: string, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + transferFrom( + from: string, + to: string, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + allowance( + owner: string, + spender: string, + overrides?: CallOverrides + ): Promise; + + approve( + spender: string, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + decimals(overrides?: CallOverrides): Promise; + + name(overrides?: CallOverrides): Promise; + + nonces(owner: string, overrides?: CallOverrides): Promise; + + permit( + owner: string, + spender: string, + value: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transfer( + to: string, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + transferFrom( + from: string, + to: string, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + allowance( + owner: string, + spender: string, + overrides?: CallOverrides + ): Promise; + + approve( + spender: string, + amount: BigNumberish, + overrides?: CallOverrides + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + decimals(overrides?: CallOverrides): Promise; + + name(overrides?: CallOverrides): Promise; + + nonces(owner: string, overrides?: CallOverrides): Promise; + + permit( + owner: string, + spender: string, + value: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transfer( + to: string, + amount: BigNumberish, + overrides?: CallOverrides + ): Promise; + + transferFrom( + from: string, + to: string, + amount: BigNumberish, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "Approval(address,address,uint256)"( + owner?: string | null, + spender?: string | null, + amount?: null + ): ApprovalEventFilter; + Approval( + owner?: string | null, + spender?: string | null, + amount?: null + ): ApprovalEventFilter; + + "Transfer(address,address,uint256)"( + from?: string | null, + to?: string | null, + amount?: null + ): TransferEventFilter; + Transfer( + from?: string | null, + to?: string | null, + amount?: null + ): TransferEventFilter; + }; + + estimateGas: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + allowance( + owner: string, + spender: string, + overrides?: CallOverrides + ): Promise; + + approve( + spender: string, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + decimals(overrides?: CallOverrides): Promise; + + name(overrides?: CallOverrides): Promise; + + nonces(owner: string, overrides?: CallOverrides): Promise; + + permit( + owner: string, + spender: string, + value: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transfer( + to: string, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + transferFrom( + from: string, + to: string, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + allowance( + owner: string, + spender: string, + overrides?: CallOverrides + ): Promise; + + approve( + spender: string, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf( + owner: string, + overrides?: CallOverrides + ): Promise; + + decimals(overrides?: CallOverrides): Promise; + + name(overrides?: CallOverrides): Promise; + + nonces( + owner: string, + overrides?: CallOverrides + ): Promise; + + permit( + owner: string, + spender: string, + value: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transfer( + to: string, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + transferFrom( + from: string, + to: string, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/solady/src/tokens/WETH.ts b/src/typechain-typesV4/solady/src/tokens/WETH.ts new file mode 100644 index 00000000..80548ed9 --- /dev/null +++ b/src/typechain-typesV4/solady/src/tokens/WETH.ts @@ -0,0 +1,533 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export interface WETHInterface extends utils.Interface { + functions: { + "DOMAIN_SEPARATOR()": FunctionFragment; + "allowance(address,address)": FunctionFragment; + "approve(address,uint256)": FunctionFragment; + "balanceOf(address)": FunctionFragment; + "decimals()": FunctionFragment; + "deposit()": FunctionFragment; + "name()": FunctionFragment; + "nonces(address)": FunctionFragment; + "permit(address,address,uint256,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "symbol()": FunctionFragment; + "totalSupply()": FunctionFragment; + "transfer(address,uint256)": FunctionFragment; + "transferFrom(address,address,uint256)": FunctionFragment; + "withdraw(uint256)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "DOMAIN_SEPARATOR" + | "allowance" + | "approve" + | "balanceOf" + | "decimals" + | "deposit" + | "name" + | "nonces" + | "permit" + | "symbol" + | "totalSupply" + | "transfer" + | "transferFrom" + | "withdraw" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "DOMAIN_SEPARATOR", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "allowance", + values: [string, string] + ): string; + encodeFunctionData( + functionFragment: "approve", + values: [string, BigNumberish] + ): string; + encodeFunctionData(functionFragment: "balanceOf", values: [string]): string; + encodeFunctionData(functionFragment: "decimals", values?: undefined): string; + encodeFunctionData(functionFragment: "deposit", values?: undefined): string; + encodeFunctionData(functionFragment: "name", values?: undefined): string; + encodeFunctionData(functionFragment: "nonces", values: [string]): string; + encodeFunctionData( + functionFragment: "permit", + values: [ + string, + string, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData(functionFragment: "symbol", values?: undefined): string; + encodeFunctionData( + functionFragment: "totalSupply", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "transfer", + values: [string, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "transferFrom", + values: [string, string, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "withdraw", + values: [BigNumberish] + ): string; + + decodeFunctionResult( + functionFragment: "DOMAIN_SEPARATOR", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "allowance", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "approve", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "balanceOf", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "decimals", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "deposit", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "name", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "nonces", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "permit", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "symbol", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "totalSupply", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "transfer", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "transferFrom", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "withdraw", data: BytesLike): Result; + + events: { + "Approval(address,address,uint256)": EventFragment; + "Transfer(address,address,uint256)": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "Approval"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Transfer"): EventFragment; +} + +export interface ApprovalEventObject { + owner: string; + spender: string; + amount: BigNumber; +} +export type ApprovalEvent = TypedEvent< + [string, string, BigNumber], + ApprovalEventObject +>; + +export type ApprovalEventFilter = TypedEventFilter; + +export interface TransferEventObject { + from: string; + to: string; + amount: BigNumber; +} +export type TransferEvent = TypedEvent< + [string, string, BigNumber], + TransferEventObject +>; + +export type TransferEventFilter = TypedEventFilter; + +export interface WETH extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: WETHInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + DOMAIN_SEPARATOR( + overrides?: CallOverrides + ): Promise<[string] & { result: string }>; + + allowance( + owner: string, + spender: string, + overrides?: CallOverrides + ): Promise<[BigNumber] & { result: BigNumber }>; + + approve( + spender: string, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf( + owner: string, + overrides?: CallOverrides + ): Promise<[BigNumber] & { result: BigNumber }>; + + decimals(overrides?: CallOverrides): Promise<[number]>; + + deposit( + overrides?: PayableOverrides & { from?: string } + ): Promise; + + name(overrides?: CallOverrides): Promise<[string]>; + + nonces( + owner: string, + overrides?: CallOverrides + ): Promise<[BigNumber] & { result: BigNumber }>; + + permit( + owner: string, + spender: string, + value: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + symbol(overrides?: CallOverrides): Promise<[string]>; + + totalSupply( + overrides?: CallOverrides + ): Promise<[BigNumber] & { result: BigNumber }>; + + transfer( + to: string, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + transferFrom( + from: string, + to: string, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + withdraw( + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + allowance( + owner: string, + spender: string, + overrides?: CallOverrides + ): Promise; + + approve( + spender: string, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + decimals(overrides?: CallOverrides): Promise; + + deposit( + overrides?: PayableOverrides & { from?: string } + ): Promise; + + name(overrides?: CallOverrides): Promise; + + nonces(owner: string, overrides?: CallOverrides): Promise; + + permit( + owner: string, + spender: string, + value: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transfer( + to: string, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + transferFrom( + from: string, + to: string, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + withdraw( + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + allowance( + owner: string, + spender: string, + overrides?: CallOverrides + ): Promise; + + approve( + spender: string, + amount: BigNumberish, + overrides?: CallOverrides + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + decimals(overrides?: CallOverrides): Promise; + + deposit(overrides?: CallOverrides): Promise; + + name(overrides?: CallOverrides): Promise; + + nonces(owner: string, overrides?: CallOverrides): Promise; + + permit( + owner: string, + spender: string, + value: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transfer( + to: string, + amount: BigNumberish, + overrides?: CallOverrides + ): Promise; + + transferFrom( + from: string, + to: string, + amount: BigNumberish, + overrides?: CallOverrides + ): Promise; + + withdraw(amount: BigNumberish, overrides?: CallOverrides): Promise; + }; + + filters: { + "Approval(address,address,uint256)"( + owner?: string | null, + spender?: string | null, + amount?: null + ): ApprovalEventFilter; + Approval( + owner?: string | null, + spender?: string | null, + amount?: null + ): ApprovalEventFilter; + + "Transfer(address,address,uint256)"( + from?: string | null, + to?: string | null, + amount?: null + ): TransferEventFilter; + Transfer( + from?: string | null, + to?: string | null, + amount?: null + ): TransferEventFilter; + }; + + estimateGas: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + allowance( + owner: string, + spender: string, + overrides?: CallOverrides + ): Promise; + + approve( + spender: string, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf(owner: string, overrides?: CallOverrides): Promise; + + decimals(overrides?: CallOverrides): Promise; + + deposit( + overrides?: PayableOverrides & { from?: string } + ): Promise; + + name(overrides?: CallOverrides): Promise; + + nonces(owner: string, overrides?: CallOverrides): Promise; + + permit( + owner: string, + spender: string, + value: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transfer( + to: string, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + transferFrom( + from: string, + to: string, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + withdraw( + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise; + + allowance( + owner: string, + spender: string, + overrides?: CallOverrides + ): Promise; + + approve( + spender: string, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + balanceOf( + owner: string, + overrides?: CallOverrides + ): Promise; + + decimals(overrides?: CallOverrides): Promise; + + deposit( + overrides?: PayableOverrides & { from?: string } + ): Promise; + + name(overrides?: CallOverrides): Promise; + + nonces( + owner: string, + overrides?: CallOverrides + ): Promise; + + permit( + owner: string, + spender: string, + value: BigNumberish, + deadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + symbol(overrides?: CallOverrides): Promise; + + totalSupply(overrides?: CallOverrides): Promise; + + transfer( + to: string, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + transferFrom( + from: string, + to: string, + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + + withdraw( + amount: BigNumberish, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/solady/src/tokens/index.ts b/src/typechain-typesV4/solady/src/tokens/index.ts new file mode 100644 index 00000000..dc704d70 --- /dev/null +++ b/src/typechain-typesV4/solady/src/tokens/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export type { ERC20 } from "./ERC20"; +export type { WETH } from "./WETH"; diff --git a/src/typechain-typesV4/solady/src/utils/FixedPointMathLib.ts b/src/typechain-typesV4/solady/src/utils/FixedPointMathLib.ts new file mode 100644 index 00000000..48cc97c2 --- /dev/null +++ b/src/typechain-typesV4/solady/src/utils/FixedPointMathLib.ts @@ -0,0 +1,55 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { BaseContract, Signer, utils } from "ethers"; + +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export interface FixedPointMathLibInterface extends utils.Interface { + functions: {}; + + events: {}; +} + +export interface FixedPointMathLib extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: FixedPointMathLibInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: {}; + + callStatic: {}; + + filters: {}; + + estimateGas: {}; + + populateTransaction: {}; +} diff --git a/src/typechain-typesV4/solady/src/utils/SafeTransferLib.ts b/src/typechain-typesV4/solady/src/utils/SafeTransferLib.ts new file mode 100644 index 00000000..5882a2fd --- /dev/null +++ b/src/typechain-typesV4/solady/src/utils/SafeTransferLib.ts @@ -0,0 +1,55 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { BaseContract, Signer, utils } from "ethers"; + +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export interface SafeTransferLibInterface extends utils.Interface { + functions: {}; + + events: {}; +} + +export interface SafeTransferLib extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: SafeTransferLibInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: {}; + + callStatic: {}; + + filters: {}; + + estimateGas: {}; + + populateTransaction: {}; +} diff --git a/src/typechain-typesV4/solady/src/utils/index.ts b/src/typechain-typesV4/solady/src/utils/index.ts new file mode 100644 index 00000000..68297f42 --- /dev/null +++ b/src/typechain-typesV4/solady/src/utils/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export type { FixedPointMathLib } from "./FixedPointMathLib"; +export type { SafeTransferLib } from "./SafeTransferLib"; diff --git a/src/typechain-typesV4/src/PCSV3Automan.ts b/src/typechain-typesV4/src/PCSV3Automan.ts new file mode 100644 index 00000000..07fe0189 --- /dev/null +++ b/src/typechain-typesV4/src/PCSV3Automan.ts @@ -0,0 +1,1745 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../common"; + +export declare namespace ICommonNonfungiblePositionManager { + export type DecreaseLiquidityParamsStruct = { + tokenId: BigNumberish; + liquidity: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + deadline: BigNumberish; + }; + + export type DecreaseLiquidityParamsStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + deadline: BigNumber; + }; + + export type IncreaseLiquidityParamsStruct = { + tokenId: BigNumberish; + amount0Desired: BigNumberish; + amount1Desired: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + deadline: BigNumberish; + }; + + export type IncreaseLiquidityParamsStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + amount0Desired: BigNumber; + amount1Desired: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + deadline: BigNumber; + }; +} + +export declare namespace IUniswapV3NonfungiblePositionManager { + export type MintParamsStruct = { + token0: string; + token1: string; + fee: BigNumberish; + tickLower: BigNumberish; + tickUpper: BigNumberish; + amount0Desired: BigNumberish; + amount1Desired: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + recipient: string; + deadline: BigNumberish; + }; + + export type MintParamsStructOutput = [ + string, + string, + number, + number, + number, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + string, + BigNumber + ] & { + token0: string; + token1: string; + fee: number; + tickLower: number; + tickUpper: number; + amount0Desired: BigNumber; + amount1Desired: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + recipient: string; + deadline: BigNumber; + }; +} + +export declare namespace IAutomanCommon { + export type FeeConfigStruct = { + feeCollector: string; + feeLimitPips: BigNumberish; + }; + + export type FeeConfigStructOutput = [string, BigNumber] & { + feeCollector: string; + feeLimitPips: BigNumber; + }; +} + +export interface PCSV3AutomanInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)": FunctionFragment; + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)": FunctionFragment; + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "deployer()": FunctionFragment; + "feeConfig()": FunctionFragment; + "getOptimalSwap(address,int24,int24,uint256,uint256)": FunctionFragment; + "increaseLiquidity((uint256,uint256,uint256,uint256,uint256,uint256))": FunctionFragment; + "increaseLiquidityOptimal((uint256,uint256,uint256,uint256,uint256,uint256),bytes,uint256,uint256)": FunctionFragment; + "increaseLiquidityWithTokenIn((uint256,uint256,uint256,uint256,uint256,uint256),address,uint256,bytes,bytes)": FunctionFragment; + "isAllowListedRouter(address)": FunctionFragment; + "isController(address)": FunctionFragment; + "mint((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256))": FunctionFragment; + "mintOptimal((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),bytes,uint256,uint256)": FunctionFragment; + "mintWithTokenIn((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),address,uint256,bytes,bytes)": FunctionFragment; + "npm()": FunctionFragment; + "owner()": FunctionFragment; + "pancakeV3SwapCallback(int256,int256,bytes)": FunctionFragment; + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)": FunctionFragment; + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)": FunctionFragment; + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "renounceOwnership()": FunctionFragment; + "setAllowlistedRouters(address[],bool[])": FunctionFragment; + "setControllers(address[],bool[])": FunctionFragment; + "setFeeConfig((address,uint96))": FunctionFragment; + "transferOwnership(address)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "WETH9" + | "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)" + | "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)" + | "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)" + | "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)" + | "deployer" + | "feeConfig" + | "getOptimalSwap" + | "increaseLiquidity" + | "increaseLiquidityOptimal" + | "increaseLiquidityWithTokenIn" + | "isAllowListedRouter" + | "isController" + | "mint" + | "mintOptimal" + | "mintWithTokenIn" + | "npm" + | "owner" + | "pancakeV3SwapCallback" + | "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)" + | "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)" + | "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)" + | "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)" + | "renounceOwnership" + | "setAllowlistedRouters" + | "setControllers" + | "setFeeConfig" + | "transferOwnership" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + boolean + ] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + boolean, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike, + boolean + ] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike, + boolean, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData(functionFragment: "deployer", values?: undefined): string; + encodeFunctionData(functionFragment: "feeConfig", values?: undefined): string; + encodeFunctionData( + functionFragment: "getOptimalSwap", + values: [string, BigNumberish, BigNumberish, BigNumberish, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidity", + values: [ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidityOptimal", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + BytesLike, + BigNumberish, + BigNumberish + ] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidityWithTokenIn", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "isAllowListedRouter", + values: [string] + ): string; + encodeFunctionData( + functionFragment: "isController", + values: [string] + ): string; + encodeFunctionData( + functionFragment: "mint", + values: [IUniswapV3NonfungiblePositionManager.MintParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "mintOptimal", + values: [ + IUniswapV3NonfungiblePositionManager.MintParamsStruct, + BytesLike, + BigNumberish, + BigNumberish + ] + ): string; + encodeFunctionData( + functionFragment: "mintWithTokenIn", + values: [ + IUniswapV3NonfungiblePositionManager.MintParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + encodeFunctionData(functionFragment: "owner", values?: undefined): string; + encodeFunctionData( + functionFragment: "pancakeV3SwapCallback", + values: [BigNumberish, BigNumberish, BytesLike] + ): string; + encodeFunctionData( + functionFragment: "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)", + values: [ + IUniswapV3NonfungiblePositionManager.MintParamsStruct, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + values: [ + IUniswapV3NonfungiblePositionManager.MintParamsStruct, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + BytesLike, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "renounceOwnership", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "setAllowlistedRouters", + values: [string[], boolean[]] + ): string; + encodeFunctionData( + functionFragment: "setControllers", + values: [string[], boolean[]] + ): string; + encodeFunctionData( + functionFragment: "setFeeConfig", + values: [IAutomanCommon.FeeConfigStruct] + ): string; + encodeFunctionData( + functionFragment: "transferOwnership", + values: [string] + ): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "deployer", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "feeConfig", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "getOptimalSwap", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidity", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidityOptimal", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidityWithTokenIn", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "isAllowListedRouter", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "isController", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "mint", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "mintOptimal", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "mintWithTokenIn", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "owner", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "pancakeV3SwapCallback", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "renounceOwnership", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setAllowlistedRouters", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setControllers", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setFeeConfig", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "transferOwnership", + data: BytesLike + ): Result; + + events: { + "ControllersSet(address[],bool[])": EventFragment; + "DecreaseLiquidity(uint256)": EventFragment; + "FeeConfigSet(address,uint96)": EventFragment; + "IncreaseLiquidity(uint256)": EventFragment; + "Mint(uint256)": EventFragment; + "OwnershipTransferred(address,address)": EventFragment; + "Rebalance(uint256)": EventFragment; + "Reinvest(uint256)": EventFragment; + "RemoveLiquidity(uint256)": EventFragment; + "SetAllowlistedRouters(address[],bool[])": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "ControllersSet"): EventFragment; + getEvent(nameOrSignatureOrTopic: "DecreaseLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "FeeConfigSet"): EventFragment; + getEvent(nameOrSignatureOrTopic: "IncreaseLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Mint"): EventFragment; + getEvent(nameOrSignatureOrTopic: "OwnershipTransferred"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Rebalance"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Reinvest"): EventFragment; + getEvent(nameOrSignatureOrTopic: "RemoveLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "SetAllowlistedRouters"): EventFragment; +} + +export interface ControllersSetEventObject { + controllers: string[]; + statuses: boolean[]; +} +export type ControllersSetEvent = TypedEvent< + [string[], boolean[]], + ControllersSetEventObject +>; + +export type ControllersSetEventFilter = TypedEventFilter; + +export interface DecreaseLiquidityEventObject { + tokenId: BigNumber; +} +export type DecreaseLiquidityEvent = TypedEvent< + [BigNumber], + DecreaseLiquidityEventObject +>; + +export type DecreaseLiquidityEventFilter = + TypedEventFilter; + +export interface FeeConfigSetEventObject { + feeCollector: string; + feeLimitPips: BigNumber; +} +export type FeeConfigSetEvent = TypedEvent< + [string, BigNumber], + FeeConfigSetEventObject +>; + +export type FeeConfigSetEventFilter = TypedEventFilter; + +export interface IncreaseLiquidityEventObject { + tokenId: BigNumber; +} +export type IncreaseLiquidityEvent = TypedEvent< + [BigNumber], + IncreaseLiquidityEventObject +>; + +export type IncreaseLiquidityEventFilter = + TypedEventFilter; + +export interface MintEventObject { + tokenId: BigNumber; +} +export type MintEvent = TypedEvent<[BigNumber], MintEventObject>; + +export type MintEventFilter = TypedEventFilter; + +export interface OwnershipTransferredEventObject { + previousOwner: string; + newOwner: string; +} +export type OwnershipTransferredEvent = TypedEvent< + [string, string], + OwnershipTransferredEventObject +>; + +export type OwnershipTransferredEventFilter = + TypedEventFilter; + +export interface RebalanceEventObject { + tokenId: BigNumber; +} +export type RebalanceEvent = TypedEvent<[BigNumber], RebalanceEventObject>; + +export type RebalanceEventFilter = TypedEventFilter; + +export interface ReinvestEventObject { + tokenId: BigNumber; +} +export type ReinvestEvent = TypedEvent<[BigNumber], ReinvestEventObject>; + +export type ReinvestEventFilter = TypedEventFilter; + +export interface RemoveLiquidityEventObject { + tokenId: BigNumber; +} +export type RemoveLiquidityEvent = TypedEvent< + [BigNumber], + RemoveLiquidityEventObject +>; + +export type RemoveLiquidityEventFilter = TypedEventFilter; + +export interface SetAllowlistedRoutersEventObject { + routers: string[]; + statuses: boolean[]; +} +export type SetAllowlistedRoutersEvent = TypedEvent< + [string[], boolean[]], + SetAllowlistedRoutersEventObject +>; + +export type SetAllowlistedRoutersEventFilter = + TypedEventFilter; + +export interface PCSV3Automan extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: PCSV3AutomanInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + deployer(overrides?: CallOverrides): Promise<[string]>; + + feeConfig( + overrides?: CallOverrides + ): Promise< + [string, BigNumber] & { feeCollector: string; feeLimitPips: BigNumber } + >; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, boolean, BigNumber] & { + amountIn: BigNumber; + amountOut: BigNumber; + zeroForOne: boolean; + sqrtPriceX96: BigNumber; + } + >; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise<[boolean]>; + + isController(arg0: string, overrides?: CallOverrides): Promise<[boolean]>; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise<[string]>; + + owner(overrides?: CallOverrides): Promise<[string]>; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + deployer(overrides?: CallOverrides): Promise; + + feeConfig( + overrides?: CallOverrides + ): Promise< + [string, BigNumber] & { feeCollector: string; feeLimitPips: BigNumber } + >; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, boolean, BigNumber] & { + amountIn: BigNumber; + amountOut: BigNumber; + zeroForOne: boolean; + sqrtPriceX96: BigNumber; + } + >; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + isController(arg0: string, overrides?: CallOverrides): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: CallOverrides + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise; + + deployer(overrides?: CallOverrides): Promise; + + feeConfig( + overrides?: CallOverrides + ): Promise< + [string, BigNumber] & { feeCollector: string; feeLimitPips: BigNumber } + >; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, boolean, BigNumber] & { + amountIn: BigNumber; + amountOut: BigNumber; + zeroForOne: boolean; + sqrtPriceX96: BigNumber; + } + >; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + isController(arg0: string, overrides?: CallOverrides): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + newTokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + newTokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + renounceOwnership(overrides?: CallOverrides): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: CallOverrides + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "ControllersSet(address[],bool[])"( + controllers?: null, + statuses?: null + ): ControllersSetEventFilter; + ControllersSet( + controllers?: null, + statuses?: null + ): ControllersSetEventFilter; + + "DecreaseLiquidity(uint256)"( + tokenId?: BigNumberish | null + ): DecreaseLiquidityEventFilter; + DecreaseLiquidity( + tokenId?: BigNumberish | null + ): DecreaseLiquidityEventFilter; + + "FeeConfigSet(address,uint96)"( + feeCollector?: null, + feeLimitPips?: null + ): FeeConfigSetEventFilter; + FeeConfigSet( + feeCollector?: null, + feeLimitPips?: null + ): FeeConfigSetEventFilter; + + "IncreaseLiquidity(uint256)"( + tokenId?: BigNumberish | null + ): IncreaseLiquidityEventFilter; + IncreaseLiquidity( + tokenId?: BigNumberish | null + ): IncreaseLiquidityEventFilter; + + "Mint(uint256)"(tokenId?: BigNumberish | null): MintEventFilter; + Mint(tokenId?: BigNumberish | null): MintEventFilter; + + "OwnershipTransferred(address,address)"( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + OwnershipTransferred( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + + "Rebalance(uint256)"(tokenId?: BigNumberish | null): RebalanceEventFilter; + Rebalance(tokenId?: BigNumberish | null): RebalanceEventFilter; + + "Reinvest(uint256)"(tokenId?: BigNumberish | null): ReinvestEventFilter; + Reinvest(tokenId?: BigNumberish | null): ReinvestEventFilter; + + "RemoveLiquidity(uint256)"( + tokenId?: BigNumberish | null + ): RemoveLiquidityEventFilter; + RemoveLiquidity(tokenId?: BigNumberish | null): RemoveLiquidityEventFilter; + + "SetAllowlistedRouters(address[],bool[])"( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + SetAllowlistedRouters( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + }; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + deployer(overrides?: CallOverrides): Promise; + + feeConfig(overrides?: CallOverrides): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + isController(arg0: string, overrides?: CallOverrides): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + deployer(overrides?: CallOverrides): Promise; + + feeConfig(overrides?: CallOverrides): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + isController( + arg0: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/src/PCSV3OptimalSwapRouter.ts b/src/typechain-typesV4/src/PCSV3OptimalSwapRouter.ts new file mode 100644 index 00000000..2857fad6 --- /dev/null +++ b/src/typechain-typesV4/src/PCSV3OptimalSwapRouter.ts @@ -0,0 +1,365 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../common"; + +export interface PCSV3OptimalSwapRouterInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "deployer()": FunctionFragment; + "isAllowListedRouter(address)": FunctionFragment; + "npm()": FunctionFragment; + "owner()": FunctionFragment; + "pancakeV3SwapCallback(int256,int256,bytes)": FunctionFragment; + "renounceOwnership()": FunctionFragment; + "setAllowlistedRouters(address[],bool[])": FunctionFragment; + "transferOwnership(address)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "WETH9" + | "deployer" + | "isAllowListedRouter" + | "npm" + | "owner" + | "pancakeV3SwapCallback" + | "renounceOwnership" + | "setAllowlistedRouters" + | "transferOwnership" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData(functionFragment: "deployer", values?: undefined): string; + encodeFunctionData( + functionFragment: "isAllowListedRouter", + values: [string] + ): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + encodeFunctionData(functionFragment: "owner", values?: undefined): string; + encodeFunctionData( + functionFragment: "pancakeV3SwapCallback", + values: [BigNumberish, BigNumberish, BytesLike] + ): string; + encodeFunctionData( + functionFragment: "renounceOwnership", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "setAllowlistedRouters", + values: [string[], boolean[]] + ): string; + encodeFunctionData( + functionFragment: "transferOwnership", + values: [string] + ): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "deployer", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "isAllowListedRouter", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "owner", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "pancakeV3SwapCallback", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "renounceOwnership", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setAllowlistedRouters", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "transferOwnership", + data: BytesLike + ): Result; + + events: { + "OwnershipTransferred(address,address)": EventFragment; + "SetAllowlistedRouters(address[],bool[])": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "OwnershipTransferred"): EventFragment; + getEvent(nameOrSignatureOrTopic: "SetAllowlistedRouters"): EventFragment; +} + +export interface OwnershipTransferredEventObject { + previousOwner: string; + newOwner: string; +} +export type OwnershipTransferredEvent = TypedEvent< + [string, string], + OwnershipTransferredEventObject +>; + +export type OwnershipTransferredEventFilter = + TypedEventFilter; + +export interface SetAllowlistedRoutersEventObject { + routers: string[]; + statuses: boolean[]; +} +export type SetAllowlistedRoutersEvent = TypedEvent< + [string[], boolean[]], + SetAllowlistedRoutersEventObject +>; + +export type SetAllowlistedRoutersEventFilter = + TypedEventFilter; + +export interface PCSV3OptimalSwapRouter extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: PCSV3OptimalSwapRouterInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + deployer(overrides?: CallOverrides): Promise<[string]>; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise<[boolean]>; + + npm(overrides?: CallOverrides): Promise<[string]>; + + owner(overrides?: CallOverrides): Promise<[string]>; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + WETH9(overrides?: CallOverrides): Promise; + + deployer(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + deployer(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + + renounceOwnership(overrides?: CallOverrides): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "OwnershipTransferred(address,address)"( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + OwnershipTransferred( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + + "SetAllowlistedRouters(address[],bool[])"( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + SetAllowlistedRouters( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + }; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + deployer(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + deployer(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/src/SlipStreamAutoman.ts b/src/typechain-typesV4/src/SlipStreamAutoman.ts new file mode 100644 index 00000000..212ce4aa --- /dev/null +++ b/src/typechain-typesV4/src/SlipStreamAutoman.ts @@ -0,0 +1,1748 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../common"; + +export declare namespace ICommonNonfungiblePositionManager { + export type DecreaseLiquidityParamsStruct = { + tokenId: BigNumberish; + liquidity: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + deadline: BigNumberish; + }; + + export type DecreaseLiquidityParamsStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + deadline: BigNumber; + }; + + export type IncreaseLiquidityParamsStruct = { + tokenId: BigNumberish; + amount0Desired: BigNumberish; + amount1Desired: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + deadline: BigNumberish; + }; + + export type IncreaseLiquidityParamsStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + amount0Desired: BigNumber; + amount1Desired: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + deadline: BigNumber; + }; +} + +export declare namespace ISlipStreamNonfungiblePositionManager { + export type MintParamsStruct = { + token0: string; + token1: string; + tickSpacing: BigNumberish; + tickLower: BigNumberish; + tickUpper: BigNumberish; + amount0Desired: BigNumberish; + amount1Desired: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + recipient: string; + deadline: BigNumberish; + sqrtPriceX96: BigNumberish; + }; + + export type MintParamsStructOutput = [ + string, + string, + number, + number, + number, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + string, + BigNumber, + BigNumber + ] & { + token0: string; + token1: string; + tickSpacing: number; + tickLower: number; + tickUpper: number; + amount0Desired: BigNumber; + amount1Desired: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + recipient: string; + deadline: BigNumber; + sqrtPriceX96: BigNumber; + }; +} + +export declare namespace IAutomanCommon { + export type FeeConfigStruct = { + feeCollector: string; + feeLimitPips: BigNumberish; + }; + + export type FeeConfigStructOutput = [string, BigNumber] & { + feeCollector: string; + feeLimitPips: BigNumber; + }; +} + +export interface SlipStreamAutomanInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)": FunctionFragment; + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)": FunctionFragment; + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "factory()": FunctionFragment; + "feeConfig()": FunctionFragment; + "getOptimalSwap(address,int24,int24,uint256,uint256)": FunctionFragment; + "increaseLiquidity((uint256,uint256,uint256,uint256,uint256,uint256))": FunctionFragment; + "increaseLiquidityOptimal((uint256,uint256,uint256,uint256,uint256,uint256),bytes,uint256,uint256)": FunctionFragment; + "increaseLiquidityWithTokenIn((uint256,uint256,uint256,uint256,uint256,uint256),address,uint256,bytes,bytes)": FunctionFragment; + "isAllowListedRouter(address)": FunctionFragment; + "isController(address)": FunctionFragment; + "mint((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160))": FunctionFragment; + "mintOptimal((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),bytes,uint256,uint256)": FunctionFragment; + "mintWithTokenIn((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),address,uint256,bytes,bytes)": FunctionFragment; + "npm()": FunctionFragment; + "owner()": FunctionFragment; + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)": FunctionFragment; + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)": FunctionFragment; + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "renounceOwnership()": FunctionFragment; + "setAllowlistedRouters(address[],bool[])": FunctionFragment; + "setControllers(address[],bool[])": FunctionFragment; + "setFeeConfig((address,uint96))": FunctionFragment; + "transferOwnership(address)": FunctionFragment; + "uniswapV3SwapCallback(int256,int256,bytes)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "WETH9" + | "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)" + | "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)" + | "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)" + | "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)" + | "factory" + | "feeConfig" + | "getOptimalSwap" + | "increaseLiquidity" + | "increaseLiquidityOptimal" + | "increaseLiquidityWithTokenIn" + | "isAllowListedRouter" + | "isController" + | "mint" + | "mintOptimal" + | "mintWithTokenIn" + | "npm" + | "owner" + | "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)" + | "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)" + | "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)" + | "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)" + | "renounceOwnership" + | "setAllowlistedRouters" + | "setControllers" + | "setFeeConfig" + | "transferOwnership" + | "uniswapV3SwapCallback" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + boolean + ] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + boolean, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike, + boolean + ] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike, + boolean, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData(functionFragment: "factory", values?: undefined): string; + encodeFunctionData(functionFragment: "feeConfig", values?: undefined): string; + encodeFunctionData( + functionFragment: "getOptimalSwap", + values: [string, BigNumberish, BigNumberish, BigNumberish, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidity", + values: [ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidityOptimal", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + BytesLike, + BigNumberish, + BigNumberish + ] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidityWithTokenIn", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "isAllowListedRouter", + values: [string] + ): string; + encodeFunctionData( + functionFragment: "isController", + values: [string] + ): string; + encodeFunctionData( + functionFragment: "mint", + values: [ISlipStreamNonfungiblePositionManager.MintParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "mintOptimal", + values: [ + ISlipStreamNonfungiblePositionManager.MintParamsStruct, + BytesLike, + BigNumberish, + BigNumberish + ] + ): string; + encodeFunctionData( + functionFragment: "mintWithTokenIn", + values: [ + ISlipStreamNonfungiblePositionManager.MintParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + encodeFunctionData(functionFragment: "owner", values?: undefined): string; + encodeFunctionData( + functionFragment: "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + values: [ + ISlipStreamNonfungiblePositionManager.MintParamsStruct, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)", + values: [ + ISlipStreamNonfungiblePositionManager.MintParamsStruct, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + BytesLike, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "renounceOwnership", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "setAllowlistedRouters", + values: [string[], boolean[]] + ): string; + encodeFunctionData( + functionFragment: "setControllers", + values: [string[], boolean[]] + ): string; + encodeFunctionData( + functionFragment: "setFeeConfig", + values: [IAutomanCommon.FeeConfigStruct] + ): string; + encodeFunctionData( + functionFragment: "transferOwnership", + values: [string] + ): string; + encodeFunctionData( + functionFragment: "uniswapV3SwapCallback", + values: [BigNumberish, BigNumberish, BytesLike] + ): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "factory", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "feeConfig", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "getOptimalSwap", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidity", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidityOptimal", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidityWithTokenIn", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "isAllowListedRouter", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "isController", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "mint", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "mintOptimal", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "mintWithTokenIn", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "owner", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "renounceOwnership", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setAllowlistedRouters", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setControllers", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setFeeConfig", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "transferOwnership", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "uniswapV3SwapCallback", + data: BytesLike + ): Result; + + events: { + "ControllersSet(address[],bool[])": EventFragment; + "DecreaseLiquidity(uint256)": EventFragment; + "FeeConfigSet(address,uint96)": EventFragment; + "IncreaseLiquidity(uint256)": EventFragment; + "Mint(uint256)": EventFragment; + "OwnershipTransferred(address,address)": EventFragment; + "Rebalance(uint256)": EventFragment; + "Reinvest(uint256)": EventFragment; + "RemoveLiquidity(uint256)": EventFragment; + "SetAllowlistedRouters(address[],bool[])": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "ControllersSet"): EventFragment; + getEvent(nameOrSignatureOrTopic: "DecreaseLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "FeeConfigSet"): EventFragment; + getEvent(nameOrSignatureOrTopic: "IncreaseLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Mint"): EventFragment; + getEvent(nameOrSignatureOrTopic: "OwnershipTransferred"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Rebalance"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Reinvest"): EventFragment; + getEvent(nameOrSignatureOrTopic: "RemoveLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "SetAllowlistedRouters"): EventFragment; +} + +export interface ControllersSetEventObject { + controllers: string[]; + statuses: boolean[]; +} +export type ControllersSetEvent = TypedEvent< + [string[], boolean[]], + ControllersSetEventObject +>; + +export type ControllersSetEventFilter = TypedEventFilter; + +export interface DecreaseLiquidityEventObject { + tokenId: BigNumber; +} +export type DecreaseLiquidityEvent = TypedEvent< + [BigNumber], + DecreaseLiquidityEventObject +>; + +export type DecreaseLiquidityEventFilter = + TypedEventFilter; + +export interface FeeConfigSetEventObject { + feeCollector: string; + feeLimitPips: BigNumber; +} +export type FeeConfigSetEvent = TypedEvent< + [string, BigNumber], + FeeConfigSetEventObject +>; + +export type FeeConfigSetEventFilter = TypedEventFilter; + +export interface IncreaseLiquidityEventObject { + tokenId: BigNumber; +} +export type IncreaseLiquidityEvent = TypedEvent< + [BigNumber], + IncreaseLiquidityEventObject +>; + +export type IncreaseLiquidityEventFilter = + TypedEventFilter; + +export interface MintEventObject { + tokenId: BigNumber; +} +export type MintEvent = TypedEvent<[BigNumber], MintEventObject>; + +export type MintEventFilter = TypedEventFilter; + +export interface OwnershipTransferredEventObject { + previousOwner: string; + newOwner: string; +} +export type OwnershipTransferredEvent = TypedEvent< + [string, string], + OwnershipTransferredEventObject +>; + +export type OwnershipTransferredEventFilter = + TypedEventFilter; + +export interface RebalanceEventObject { + tokenId: BigNumber; +} +export type RebalanceEvent = TypedEvent<[BigNumber], RebalanceEventObject>; + +export type RebalanceEventFilter = TypedEventFilter; + +export interface ReinvestEventObject { + tokenId: BigNumber; +} +export type ReinvestEvent = TypedEvent<[BigNumber], ReinvestEventObject>; + +export type ReinvestEventFilter = TypedEventFilter; + +export interface RemoveLiquidityEventObject { + tokenId: BigNumber; +} +export type RemoveLiquidityEvent = TypedEvent< + [BigNumber], + RemoveLiquidityEventObject +>; + +export type RemoveLiquidityEventFilter = TypedEventFilter; + +export interface SetAllowlistedRoutersEventObject { + routers: string[]; + statuses: boolean[]; +} +export type SetAllowlistedRoutersEvent = TypedEvent< + [string[], boolean[]], + SetAllowlistedRoutersEventObject +>; + +export type SetAllowlistedRoutersEventFilter = + TypedEventFilter; + +export interface SlipStreamAutoman extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: SlipStreamAutomanInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise<[string]>; + + feeConfig( + overrides?: CallOverrides + ): Promise< + [string, BigNumber] & { feeCollector: string; feeLimitPips: BigNumber } + >; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, boolean, BigNumber] & { + amountIn: BigNumber; + amountOut: BigNumber; + zeroForOne: boolean; + sqrtPriceX96: BigNumber; + } + >; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise<[boolean]>; + + isController(arg0: string, overrides?: CallOverrides): Promise<[boolean]>; + + mint( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise<[string]>; + + owner(overrides?: CallOverrides): Promise<[string]>; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + feeConfig( + overrides?: CallOverrides + ): Promise< + [string, BigNumber] & { feeCollector: string; feeLimitPips: BigNumber } + >; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, boolean, BigNumber] & { + amountIn: BigNumber; + amountOut: BigNumber; + zeroForOne: boolean; + sqrtPriceX96: BigNumber; + } + >; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + isController(arg0: string, overrides?: CallOverrides): Promise; + + mint( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: CallOverrides + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + feeConfig( + overrides?: CallOverrides + ): Promise< + [string, BigNumber] & { feeCollector: string; feeLimitPips: BigNumber } + >; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, boolean, BigNumber] & { + amountIn: BigNumber; + amountOut: BigNumber; + zeroForOne: boolean; + sqrtPriceX96: BigNumber; + } + >; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + isController(arg0: string, overrides?: CallOverrides): Promise; + + mint( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + mintOptimal( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + mintWithTokenIn( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + newTokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + newTokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + renounceOwnership(overrides?: CallOverrides): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: CallOverrides + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: CallOverrides + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "ControllersSet(address[],bool[])"( + controllers?: null, + statuses?: null + ): ControllersSetEventFilter; + ControllersSet( + controllers?: null, + statuses?: null + ): ControllersSetEventFilter; + + "DecreaseLiquidity(uint256)"( + tokenId?: BigNumberish | null + ): DecreaseLiquidityEventFilter; + DecreaseLiquidity( + tokenId?: BigNumberish | null + ): DecreaseLiquidityEventFilter; + + "FeeConfigSet(address,uint96)"( + feeCollector?: null, + feeLimitPips?: null + ): FeeConfigSetEventFilter; + FeeConfigSet( + feeCollector?: null, + feeLimitPips?: null + ): FeeConfigSetEventFilter; + + "IncreaseLiquidity(uint256)"( + tokenId?: BigNumberish | null + ): IncreaseLiquidityEventFilter; + IncreaseLiquidity( + tokenId?: BigNumberish | null + ): IncreaseLiquidityEventFilter; + + "Mint(uint256)"(tokenId?: BigNumberish | null): MintEventFilter; + Mint(tokenId?: BigNumberish | null): MintEventFilter; + + "OwnershipTransferred(address,address)"( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + OwnershipTransferred( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + + "Rebalance(uint256)"(tokenId?: BigNumberish | null): RebalanceEventFilter; + Rebalance(tokenId?: BigNumberish | null): RebalanceEventFilter; + + "Reinvest(uint256)"(tokenId?: BigNumberish | null): ReinvestEventFilter; + Reinvest(tokenId?: BigNumberish | null): ReinvestEventFilter; + + "RemoveLiquidity(uint256)"( + tokenId?: BigNumberish | null + ): RemoveLiquidityEventFilter; + RemoveLiquidity(tokenId?: BigNumberish | null): RemoveLiquidityEventFilter; + + "SetAllowlistedRouters(address[],bool[])"( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + SetAllowlistedRouters( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + }; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + feeConfig(overrides?: CallOverrides): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + isController(arg0: string, overrides?: CallOverrides): Promise; + + mint( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + feeConfig(overrides?: CallOverrides): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + isController( + arg0: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/src/SlipStreamOptimalSwapRouter.ts b/src/typechain-typesV4/src/SlipStreamOptimalSwapRouter.ts new file mode 100644 index 00000000..9bd34e8a --- /dev/null +++ b/src/typechain-typesV4/src/SlipStreamOptimalSwapRouter.ts @@ -0,0 +1,365 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../common"; + +export interface SlipStreamOptimalSwapRouterInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "factory()": FunctionFragment; + "isAllowListedRouter(address)": FunctionFragment; + "npm()": FunctionFragment; + "owner()": FunctionFragment; + "renounceOwnership()": FunctionFragment; + "setAllowlistedRouters(address[],bool[])": FunctionFragment; + "transferOwnership(address)": FunctionFragment; + "uniswapV3SwapCallback(int256,int256,bytes)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "WETH9" + | "factory" + | "isAllowListedRouter" + | "npm" + | "owner" + | "renounceOwnership" + | "setAllowlistedRouters" + | "transferOwnership" + | "uniswapV3SwapCallback" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData(functionFragment: "factory", values?: undefined): string; + encodeFunctionData( + functionFragment: "isAllowListedRouter", + values: [string] + ): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + encodeFunctionData(functionFragment: "owner", values?: undefined): string; + encodeFunctionData( + functionFragment: "renounceOwnership", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "setAllowlistedRouters", + values: [string[], boolean[]] + ): string; + encodeFunctionData( + functionFragment: "transferOwnership", + values: [string] + ): string; + encodeFunctionData( + functionFragment: "uniswapV3SwapCallback", + values: [BigNumberish, BigNumberish, BytesLike] + ): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "factory", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "isAllowListedRouter", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "owner", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "renounceOwnership", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setAllowlistedRouters", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "transferOwnership", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "uniswapV3SwapCallback", + data: BytesLike + ): Result; + + events: { + "OwnershipTransferred(address,address)": EventFragment; + "SetAllowlistedRouters(address[],bool[])": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "OwnershipTransferred"): EventFragment; + getEvent(nameOrSignatureOrTopic: "SetAllowlistedRouters"): EventFragment; +} + +export interface OwnershipTransferredEventObject { + previousOwner: string; + newOwner: string; +} +export type OwnershipTransferredEvent = TypedEvent< + [string, string], + OwnershipTransferredEventObject +>; + +export type OwnershipTransferredEventFilter = + TypedEventFilter; + +export interface SetAllowlistedRoutersEventObject { + routers: string[]; + statuses: boolean[]; +} +export type SetAllowlistedRoutersEvent = TypedEvent< + [string[], boolean[]], + SetAllowlistedRoutersEventObject +>; + +export type SetAllowlistedRoutersEventFilter = + TypedEventFilter; + +export interface SlipStreamOptimalSwapRouter extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: SlipStreamOptimalSwapRouterInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + factory(overrides?: CallOverrides): Promise<[string]>; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise<[boolean]>; + + npm(overrides?: CallOverrides): Promise<[string]>; + + owner(overrides?: CallOverrides): Promise<[string]>; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership(overrides?: CallOverrides): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: CallOverrides + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "OwnershipTransferred(address,address)"( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + OwnershipTransferred( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + + "SetAllowlistedRouters(address[],bool[])"( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + SetAllowlistedRouters( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + }; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/src/UniV3Automan.ts b/src/typechain-typesV4/src/UniV3Automan.ts new file mode 100644 index 00000000..bfb22b7e --- /dev/null +++ b/src/typechain-typesV4/src/UniV3Automan.ts @@ -0,0 +1,1745 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../common"; + +export declare namespace ICommonNonfungiblePositionManager { + export type DecreaseLiquidityParamsStruct = { + tokenId: BigNumberish; + liquidity: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + deadline: BigNumberish; + }; + + export type DecreaseLiquidityParamsStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + deadline: BigNumber; + }; + + export type IncreaseLiquidityParamsStruct = { + tokenId: BigNumberish; + amount0Desired: BigNumberish; + amount1Desired: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + deadline: BigNumberish; + }; + + export type IncreaseLiquidityParamsStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + amount0Desired: BigNumber; + amount1Desired: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + deadline: BigNumber; + }; +} + +export declare namespace IUniswapV3NonfungiblePositionManager { + export type MintParamsStruct = { + token0: string; + token1: string; + fee: BigNumberish; + tickLower: BigNumberish; + tickUpper: BigNumberish; + amount0Desired: BigNumberish; + amount1Desired: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + recipient: string; + deadline: BigNumberish; + }; + + export type MintParamsStructOutput = [ + string, + string, + number, + number, + number, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + string, + BigNumber + ] & { + token0: string; + token1: string; + fee: number; + tickLower: number; + tickUpper: number; + amount0Desired: BigNumber; + amount1Desired: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + recipient: string; + deadline: BigNumber; + }; +} + +export declare namespace IAutomanCommon { + export type FeeConfigStruct = { + feeCollector: string; + feeLimitPips: BigNumberish; + }; + + export type FeeConfigStructOutput = [string, BigNumber] & { + feeCollector: string; + feeLimitPips: BigNumber; + }; +} + +export interface UniV3AutomanInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)": FunctionFragment; + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)": FunctionFragment; + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "factory()": FunctionFragment; + "feeConfig()": FunctionFragment; + "getOptimalSwap(address,int24,int24,uint256,uint256)": FunctionFragment; + "increaseLiquidity((uint256,uint256,uint256,uint256,uint256,uint256))": FunctionFragment; + "increaseLiquidityOptimal((uint256,uint256,uint256,uint256,uint256,uint256),bytes,uint256,uint256)": FunctionFragment; + "increaseLiquidityWithTokenIn((uint256,uint256,uint256,uint256,uint256,uint256),address,uint256,bytes,bytes)": FunctionFragment; + "isAllowListedRouter(address)": FunctionFragment; + "isController(address)": FunctionFragment; + "mint((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256))": FunctionFragment; + "mintOptimal((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),bytes,uint256,uint256)": FunctionFragment; + "mintWithTokenIn((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),address,uint256,bytes,bytes)": FunctionFragment; + "npm()": FunctionFragment; + "owner()": FunctionFragment; + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)": FunctionFragment; + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)": FunctionFragment; + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "renounceOwnership()": FunctionFragment; + "setAllowlistedRouters(address[],bool[])": FunctionFragment; + "setControllers(address[],bool[])": FunctionFragment; + "setFeeConfig((address,uint96))": FunctionFragment; + "transferOwnership(address)": FunctionFragment; + "uniswapV3SwapCallback(int256,int256,bytes)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "WETH9" + | "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)" + | "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)" + | "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)" + | "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)" + | "factory" + | "feeConfig" + | "getOptimalSwap" + | "increaseLiquidity" + | "increaseLiquidityOptimal" + | "increaseLiquidityWithTokenIn" + | "isAllowListedRouter" + | "isController" + | "mint" + | "mintOptimal" + | "mintWithTokenIn" + | "npm" + | "owner" + | "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)" + | "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)" + | "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)" + | "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)" + | "renounceOwnership" + | "setAllowlistedRouters" + | "setControllers" + | "setFeeConfig" + | "transferOwnership" + | "uniswapV3SwapCallback" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + boolean + ] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + boolean, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike, + boolean + ] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike, + boolean, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData(functionFragment: "factory", values?: undefined): string; + encodeFunctionData(functionFragment: "feeConfig", values?: undefined): string; + encodeFunctionData( + functionFragment: "getOptimalSwap", + values: [string, BigNumberish, BigNumberish, BigNumberish, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidity", + values: [ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidityOptimal", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + BytesLike, + BigNumberish, + BigNumberish + ] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidityWithTokenIn", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "isAllowListedRouter", + values: [string] + ): string; + encodeFunctionData( + functionFragment: "isController", + values: [string] + ): string; + encodeFunctionData( + functionFragment: "mint", + values: [IUniswapV3NonfungiblePositionManager.MintParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "mintOptimal", + values: [ + IUniswapV3NonfungiblePositionManager.MintParamsStruct, + BytesLike, + BigNumberish, + BigNumberish + ] + ): string; + encodeFunctionData( + functionFragment: "mintWithTokenIn", + values: [ + IUniswapV3NonfungiblePositionManager.MintParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + encodeFunctionData(functionFragment: "owner", values?: undefined): string; + encodeFunctionData( + functionFragment: "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)", + values: [ + IUniswapV3NonfungiblePositionManager.MintParamsStruct, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + values: [ + IUniswapV3NonfungiblePositionManager.MintParamsStruct, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + BytesLike, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "renounceOwnership", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "setAllowlistedRouters", + values: [string[], boolean[]] + ): string; + encodeFunctionData( + functionFragment: "setControllers", + values: [string[], boolean[]] + ): string; + encodeFunctionData( + functionFragment: "setFeeConfig", + values: [IAutomanCommon.FeeConfigStruct] + ): string; + encodeFunctionData( + functionFragment: "transferOwnership", + values: [string] + ): string; + encodeFunctionData( + functionFragment: "uniswapV3SwapCallback", + values: [BigNumberish, BigNumberish, BytesLike] + ): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "factory", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "feeConfig", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "getOptimalSwap", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidity", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidityOptimal", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidityWithTokenIn", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "isAllowListedRouter", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "isController", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "mint", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "mintOptimal", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "mintWithTokenIn", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "owner", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "renounceOwnership", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setAllowlistedRouters", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setControllers", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setFeeConfig", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "transferOwnership", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "uniswapV3SwapCallback", + data: BytesLike + ): Result; + + events: { + "ControllersSet(address[],bool[])": EventFragment; + "DecreaseLiquidity(uint256)": EventFragment; + "FeeConfigSet(address,uint96)": EventFragment; + "IncreaseLiquidity(uint256)": EventFragment; + "Mint(uint256)": EventFragment; + "OwnershipTransferred(address,address)": EventFragment; + "Rebalance(uint256)": EventFragment; + "Reinvest(uint256)": EventFragment; + "RemoveLiquidity(uint256)": EventFragment; + "SetAllowlistedRouters(address[],bool[])": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "ControllersSet"): EventFragment; + getEvent(nameOrSignatureOrTopic: "DecreaseLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "FeeConfigSet"): EventFragment; + getEvent(nameOrSignatureOrTopic: "IncreaseLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Mint"): EventFragment; + getEvent(nameOrSignatureOrTopic: "OwnershipTransferred"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Rebalance"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Reinvest"): EventFragment; + getEvent(nameOrSignatureOrTopic: "RemoveLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "SetAllowlistedRouters"): EventFragment; +} + +export interface ControllersSetEventObject { + controllers: string[]; + statuses: boolean[]; +} +export type ControllersSetEvent = TypedEvent< + [string[], boolean[]], + ControllersSetEventObject +>; + +export type ControllersSetEventFilter = TypedEventFilter; + +export interface DecreaseLiquidityEventObject { + tokenId: BigNumber; +} +export type DecreaseLiquidityEvent = TypedEvent< + [BigNumber], + DecreaseLiquidityEventObject +>; + +export type DecreaseLiquidityEventFilter = + TypedEventFilter; + +export interface FeeConfigSetEventObject { + feeCollector: string; + feeLimitPips: BigNumber; +} +export type FeeConfigSetEvent = TypedEvent< + [string, BigNumber], + FeeConfigSetEventObject +>; + +export type FeeConfigSetEventFilter = TypedEventFilter; + +export interface IncreaseLiquidityEventObject { + tokenId: BigNumber; +} +export type IncreaseLiquidityEvent = TypedEvent< + [BigNumber], + IncreaseLiquidityEventObject +>; + +export type IncreaseLiquidityEventFilter = + TypedEventFilter; + +export interface MintEventObject { + tokenId: BigNumber; +} +export type MintEvent = TypedEvent<[BigNumber], MintEventObject>; + +export type MintEventFilter = TypedEventFilter; + +export interface OwnershipTransferredEventObject { + previousOwner: string; + newOwner: string; +} +export type OwnershipTransferredEvent = TypedEvent< + [string, string], + OwnershipTransferredEventObject +>; + +export type OwnershipTransferredEventFilter = + TypedEventFilter; + +export interface RebalanceEventObject { + tokenId: BigNumber; +} +export type RebalanceEvent = TypedEvent<[BigNumber], RebalanceEventObject>; + +export type RebalanceEventFilter = TypedEventFilter; + +export interface ReinvestEventObject { + tokenId: BigNumber; +} +export type ReinvestEvent = TypedEvent<[BigNumber], ReinvestEventObject>; + +export type ReinvestEventFilter = TypedEventFilter; + +export interface RemoveLiquidityEventObject { + tokenId: BigNumber; +} +export type RemoveLiquidityEvent = TypedEvent< + [BigNumber], + RemoveLiquidityEventObject +>; + +export type RemoveLiquidityEventFilter = TypedEventFilter; + +export interface SetAllowlistedRoutersEventObject { + routers: string[]; + statuses: boolean[]; +} +export type SetAllowlistedRoutersEvent = TypedEvent< + [string[], boolean[]], + SetAllowlistedRoutersEventObject +>; + +export type SetAllowlistedRoutersEventFilter = + TypedEventFilter; + +export interface UniV3Automan extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: UniV3AutomanInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise<[string]>; + + feeConfig( + overrides?: CallOverrides + ): Promise< + [string, BigNumber] & { feeCollector: string; feeLimitPips: BigNumber } + >; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, boolean, BigNumber] & { + amountIn: BigNumber; + amountOut: BigNumber; + zeroForOne: boolean; + sqrtPriceX96: BigNumber; + } + >; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise<[boolean]>; + + isController(arg0: string, overrides?: CallOverrides): Promise<[boolean]>; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise<[string]>; + + owner(overrides?: CallOverrides): Promise<[string]>; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + feeConfig( + overrides?: CallOverrides + ): Promise< + [string, BigNumber] & { feeCollector: string; feeLimitPips: BigNumber } + >; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, boolean, BigNumber] & { + amountIn: BigNumber; + amountOut: BigNumber; + zeroForOne: boolean; + sqrtPriceX96: BigNumber; + } + >; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + isController(arg0: string, overrides?: CallOverrides): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: CallOverrides + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + feeConfig( + overrides?: CallOverrides + ): Promise< + [string, BigNumber] & { feeCollector: string; feeLimitPips: BigNumber } + >; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, boolean, BigNumber] & { + amountIn: BigNumber; + amountOut: BigNumber; + zeroForOne: boolean; + sqrtPriceX96: BigNumber; + } + >; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + isController(arg0: string, overrides?: CallOverrides): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + newTokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + newTokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + renounceOwnership(overrides?: CallOverrides): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: CallOverrides + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: CallOverrides + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "ControllersSet(address[],bool[])"( + controllers?: null, + statuses?: null + ): ControllersSetEventFilter; + ControllersSet( + controllers?: null, + statuses?: null + ): ControllersSetEventFilter; + + "DecreaseLiquidity(uint256)"( + tokenId?: BigNumberish | null + ): DecreaseLiquidityEventFilter; + DecreaseLiquidity( + tokenId?: BigNumberish | null + ): DecreaseLiquidityEventFilter; + + "FeeConfigSet(address,uint96)"( + feeCollector?: null, + feeLimitPips?: null + ): FeeConfigSetEventFilter; + FeeConfigSet( + feeCollector?: null, + feeLimitPips?: null + ): FeeConfigSetEventFilter; + + "IncreaseLiquidity(uint256)"( + tokenId?: BigNumberish | null + ): IncreaseLiquidityEventFilter; + IncreaseLiquidity( + tokenId?: BigNumberish | null + ): IncreaseLiquidityEventFilter; + + "Mint(uint256)"(tokenId?: BigNumberish | null): MintEventFilter; + Mint(tokenId?: BigNumberish | null): MintEventFilter; + + "OwnershipTransferred(address,address)"( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + OwnershipTransferred( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + + "Rebalance(uint256)"(tokenId?: BigNumberish | null): RebalanceEventFilter; + Rebalance(tokenId?: BigNumberish | null): RebalanceEventFilter; + + "Reinvest(uint256)"(tokenId?: BigNumberish | null): ReinvestEventFilter; + Reinvest(tokenId?: BigNumberish | null): ReinvestEventFilter; + + "RemoveLiquidity(uint256)"( + tokenId?: BigNumberish | null + ): RemoveLiquidityEventFilter; + RemoveLiquidity(tokenId?: BigNumberish | null): RemoveLiquidityEventFilter; + + "SetAllowlistedRouters(address[],bool[])"( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + SetAllowlistedRouters( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + }; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + feeConfig(overrides?: CallOverrides): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + isController(arg0: string, overrides?: CallOverrides): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + feeConfig(overrides?: CallOverrides): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + isController( + arg0: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/src/UniV3OptimalSwapRouter.ts b/src/typechain-typesV4/src/UniV3OptimalSwapRouter.ts new file mode 100644 index 00000000..f4ce3567 --- /dev/null +++ b/src/typechain-typesV4/src/UniV3OptimalSwapRouter.ts @@ -0,0 +1,365 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../common"; + +export interface UniV3OptimalSwapRouterInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "factory()": FunctionFragment; + "isAllowListedRouter(address)": FunctionFragment; + "npm()": FunctionFragment; + "owner()": FunctionFragment; + "renounceOwnership()": FunctionFragment; + "setAllowlistedRouters(address[],bool[])": FunctionFragment; + "transferOwnership(address)": FunctionFragment; + "uniswapV3SwapCallback(int256,int256,bytes)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "WETH9" + | "factory" + | "isAllowListedRouter" + | "npm" + | "owner" + | "renounceOwnership" + | "setAllowlistedRouters" + | "transferOwnership" + | "uniswapV3SwapCallback" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData(functionFragment: "factory", values?: undefined): string; + encodeFunctionData( + functionFragment: "isAllowListedRouter", + values: [string] + ): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + encodeFunctionData(functionFragment: "owner", values?: undefined): string; + encodeFunctionData( + functionFragment: "renounceOwnership", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "setAllowlistedRouters", + values: [string[], boolean[]] + ): string; + encodeFunctionData( + functionFragment: "transferOwnership", + values: [string] + ): string; + encodeFunctionData( + functionFragment: "uniswapV3SwapCallback", + values: [BigNumberish, BigNumberish, BytesLike] + ): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "factory", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "isAllowListedRouter", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "owner", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "renounceOwnership", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setAllowlistedRouters", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "transferOwnership", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "uniswapV3SwapCallback", + data: BytesLike + ): Result; + + events: { + "OwnershipTransferred(address,address)": EventFragment; + "SetAllowlistedRouters(address[],bool[])": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "OwnershipTransferred"): EventFragment; + getEvent(nameOrSignatureOrTopic: "SetAllowlistedRouters"): EventFragment; +} + +export interface OwnershipTransferredEventObject { + previousOwner: string; + newOwner: string; +} +export type OwnershipTransferredEvent = TypedEvent< + [string, string], + OwnershipTransferredEventObject +>; + +export type OwnershipTransferredEventFilter = + TypedEventFilter; + +export interface SetAllowlistedRoutersEventObject { + routers: string[]; + statuses: boolean[]; +} +export type SetAllowlistedRoutersEvent = TypedEvent< + [string[], boolean[]], + SetAllowlistedRoutersEventObject +>; + +export type SetAllowlistedRoutersEventFilter = + TypedEventFilter; + +export interface UniV3OptimalSwapRouter extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: UniV3OptimalSwapRouterInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + factory(overrides?: CallOverrides): Promise<[string]>; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise<[boolean]>; + + npm(overrides?: CallOverrides): Promise<[string]>; + + owner(overrides?: CallOverrides): Promise<[string]>; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership(overrides?: CallOverrides): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: CallOverrides + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "OwnershipTransferred(address,address)"( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + OwnershipTransferred( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + + "SetAllowlistedRouters(address[],bool[])"( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + SetAllowlistedRouters( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + }; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/src/base/Automan.ts b/src/typechain-typesV4/src/base/Automan.ts new file mode 100644 index 00000000..564a2abb --- /dev/null +++ b/src/typechain-typesV4/src/base/Automan.ts @@ -0,0 +1,1686 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../common"; + +export declare namespace ICommonNonfungiblePositionManager { + export type DecreaseLiquidityParamsStruct = { + tokenId: BigNumberish; + liquidity: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + deadline: BigNumberish; + }; + + export type DecreaseLiquidityParamsStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + deadline: BigNumber; + }; + + export type IncreaseLiquidityParamsStruct = { + tokenId: BigNumberish; + amount0Desired: BigNumberish; + amount1Desired: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + deadline: BigNumberish; + }; + + export type IncreaseLiquidityParamsStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + amount0Desired: BigNumber; + amount1Desired: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + deadline: BigNumber; + }; +} + +export declare namespace IUniswapV3NonfungiblePositionManager { + export type MintParamsStruct = { + token0: string; + token1: string; + fee: BigNumberish; + tickLower: BigNumberish; + tickUpper: BigNumberish; + amount0Desired: BigNumberish; + amount1Desired: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + recipient: string; + deadline: BigNumberish; + }; + + export type MintParamsStructOutput = [ + string, + string, + number, + number, + number, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + string, + BigNumber + ] & { + token0: string; + token1: string; + fee: number; + tickLower: number; + tickUpper: number; + amount0Desired: BigNumber; + amount1Desired: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + recipient: string; + deadline: BigNumber; + }; +} + +export declare namespace IAutomanCommon { + export type FeeConfigStruct = { + feeCollector: string; + feeLimitPips: BigNumberish; + }; + + export type FeeConfigStructOutput = [string, BigNumber] & { + feeCollector: string; + feeLimitPips: BigNumber; + }; +} + +export interface AutomanInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)": FunctionFragment; + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)": FunctionFragment; + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "feeConfig()": FunctionFragment; + "getOptimalSwap(address,int24,int24,uint256,uint256)": FunctionFragment; + "increaseLiquidity((uint256,uint256,uint256,uint256,uint256,uint256))": FunctionFragment; + "increaseLiquidityOptimal((uint256,uint256,uint256,uint256,uint256,uint256),bytes,uint256,uint256)": FunctionFragment; + "increaseLiquidityWithTokenIn((uint256,uint256,uint256,uint256,uint256,uint256),address,uint256,bytes,bytes)": FunctionFragment; + "isAllowListedRouter(address)": FunctionFragment; + "isController(address)": FunctionFragment; + "mint((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256))": FunctionFragment; + "mintOptimal((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),bytes,uint256,uint256)": FunctionFragment; + "mintWithTokenIn((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),address,uint256,bytes,bytes)": FunctionFragment; + "npm()": FunctionFragment; + "owner()": FunctionFragment; + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)": FunctionFragment; + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)": FunctionFragment; + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "renounceOwnership()": FunctionFragment; + "setAllowlistedRouters(address[],bool[])": FunctionFragment; + "setControllers(address[],bool[])": FunctionFragment; + "setFeeConfig((address,uint96))": FunctionFragment; + "transferOwnership(address)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "WETH9" + | "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)" + | "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)" + | "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)" + | "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)" + | "feeConfig" + | "getOptimalSwap" + | "increaseLiquidity" + | "increaseLiquidityOptimal" + | "increaseLiquidityWithTokenIn" + | "isAllowListedRouter" + | "isController" + | "mint" + | "mintOptimal" + | "mintWithTokenIn" + | "npm" + | "owner" + | "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)" + | "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)" + | "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)" + | "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)" + | "renounceOwnership" + | "setAllowlistedRouters" + | "setControllers" + | "setFeeConfig" + | "transferOwnership" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + boolean + ] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + boolean, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike, + boolean + ] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike, + boolean, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData(functionFragment: "feeConfig", values?: undefined): string; + encodeFunctionData( + functionFragment: "getOptimalSwap", + values: [string, BigNumberish, BigNumberish, BigNumberish, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidity", + values: [ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidityOptimal", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + BytesLike, + BigNumberish, + BigNumberish + ] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidityWithTokenIn", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "isAllowListedRouter", + values: [string] + ): string; + encodeFunctionData( + functionFragment: "isController", + values: [string] + ): string; + encodeFunctionData( + functionFragment: "mint", + values: [IUniswapV3NonfungiblePositionManager.MintParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "mintOptimal", + values: [ + IUniswapV3NonfungiblePositionManager.MintParamsStruct, + BytesLike, + BigNumberish, + BigNumberish + ] + ): string; + encodeFunctionData( + functionFragment: "mintWithTokenIn", + values: [ + IUniswapV3NonfungiblePositionManager.MintParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + encodeFunctionData(functionFragment: "owner", values?: undefined): string; + encodeFunctionData( + functionFragment: "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)", + values: [ + IUniswapV3NonfungiblePositionManager.MintParamsStruct, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + values: [ + IUniswapV3NonfungiblePositionManager.MintParamsStruct, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + BytesLike, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "renounceOwnership", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "setAllowlistedRouters", + values: [string[], boolean[]] + ): string; + encodeFunctionData( + functionFragment: "setControllers", + values: [string[], boolean[]] + ): string; + encodeFunctionData( + functionFragment: "setFeeConfig", + values: [IAutomanCommon.FeeConfigStruct] + ): string; + encodeFunctionData( + functionFragment: "transferOwnership", + values: [string] + ): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "feeConfig", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "getOptimalSwap", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidity", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidityOptimal", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidityWithTokenIn", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "isAllowListedRouter", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "isController", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "mint", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "mintOptimal", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "mintWithTokenIn", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "owner", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "renounceOwnership", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setAllowlistedRouters", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setControllers", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setFeeConfig", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "transferOwnership", + data: BytesLike + ): Result; + + events: { + "ControllersSet(address[],bool[])": EventFragment; + "DecreaseLiquidity(uint256)": EventFragment; + "FeeConfigSet(address,uint96)": EventFragment; + "IncreaseLiquidity(uint256)": EventFragment; + "Mint(uint256)": EventFragment; + "OwnershipTransferred(address,address)": EventFragment; + "Rebalance(uint256)": EventFragment; + "Reinvest(uint256)": EventFragment; + "RemoveLiquidity(uint256)": EventFragment; + "SetAllowlistedRouters(address[],bool[])": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "ControllersSet"): EventFragment; + getEvent(nameOrSignatureOrTopic: "DecreaseLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "FeeConfigSet"): EventFragment; + getEvent(nameOrSignatureOrTopic: "IncreaseLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Mint"): EventFragment; + getEvent(nameOrSignatureOrTopic: "OwnershipTransferred"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Rebalance"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Reinvest"): EventFragment; + getEvent(nameOrSignatureOrTopic: "RemoveLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "SetAllowlistedRouters"): EventFragment; +} + +export interface ControllersSetEventObject { + controllers: string[]; + statuses: boolean[]; +} +export type ControllersSetEvent = TypedEvent< + [string[], boolean[]], + ControllersSetEventObject +>; + +export type ControllersSetEventFilter = TypedEventFilter; + +export interface DecreaseLiquidityEventObject { + tokenId: BigNumber; +} +export type DecreaseLiquidityEvent = TypedEvent< + [BigNumber], + DecreaseLiquidityEventObject +>; + +export type DecreaseLiquidityEventFilter = + TypedEventFilter; + +export interface FeeConfigSetEventObject { + feeCollector: string; + feeLimitPips: BigNumber; +} +export type FeeConfigSetEvent = TypedEvent< + [string, BigNumber], + FeeConfigSetEventObject +>; + +export type FeeConfigSetEventFilter = TypedEventFilter; + +export interface IncreaseLiquidityEventObject { + tokenId: BigNumber; +} +export type IncreaseLiquidityEvent = TypedEvent< + [BigNumber], + IncreaseLiquidityEventObject +>; + +export type IncreaseLiquidityEventFilter = + TypedEventFilter; + +export interface MintEventObject { + tokenId: BigNumber; +} +export type MintEvent = TypedEvent<[BigNumber], MintEventObject>; + +export type MintEventFilter = TypedEventFilter; + +export interface OwnershipTransferredEventObject { + previousOwner: string; + newOwner: string; +} +export type OwnershipTransferredEvent = TypedEvent< + [string, string], + OwnershipTransferredEventObject +>; + +export type OwnershipTransferredEventFilter = + TypedEventFilter; + +export interface RebalanceEventObject { + tokenId: BigNumber; +} +export type RebalanceEvent = TypedEvent<[BigNumber], RebalanceEventObject>; + +export type RebalanceEventFilter = TypedEventFilter; + +export interface ReinvestEventObject { + tokenId: BigNumber; +} +export type ReinvestEvent = TypedEvent<[BigNumber], ReinvestEventObject>; + +export type ReinvestEventFilter = TypedEventFilter; + +export interface RemoveLiquidityEventObject { + tokenId: BigNumber; +} +export type RemoveLiquidityEvent = TypedEvent< + [BigNumber], + RemoveLiquidityEventObject +>; + +export type RemoveLiquidityEventFilter = TypedEventFilter; + +export interface SetAllowlistedRoutersEventObject { + routers: string[]; + statuses: boolean[]; +} +export type SetAllowlistedRoutersEvent = TypedEvent< + [string[], boolean[]], + SetAllowlistedRoutersEventObject +>; + +export type SetAllowlistedRoutersEventFilter = + TypedEventFilter; + +export interface Automan extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: AutomanInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + feeConfig( + overrides?: CallOverrides + ): Promise< + [string, BigNumber] & { feeCollector: string; feeLimitPips: BigNumber } + >; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, boolean, BigNumber] & { + amountIn: BigNumber; + amountOut: BigNumber; + zeroForOne: boolean; + sqrtPriceX96: BigNumber; + } + >; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise<[boolean]>; + + isController(arg0: string, overrides?: CallOverrides): Promise<[boolean]>; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise<[string]>; + + owner(overrides?: CallOverrides): Promise<[string]>; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + feeConfig( + overrides?: CallOverrides + ): Promise< + [string, BigNumber] & { feeCollector: string; feeLimitPips: BigNumber } + >; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, boolean, BigNumber] & { + amountIn: BigNumber; + amountOut: BigNumber; + zeroForOne: boolean; + sqrtPriceX96: BigNumber; + } + >; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + isController(arg0: string, overrides?: CallOverrides): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: CallOverrides + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise; + + feeConfig( + overrides?: CallOverrides + ): Promise< + [string, BigNumber] & { feeCollector: string; feeLimitPips: BigNumber } + >; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, boolean, BigNumber] & { + amountIn: BigNumber; + amountOut: BigNumber; + zeroForOne: boolean; + sqrtPriceX96: BigNumber; + } + >; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + isController(arg0: string, overrides?: CallOverrides): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + newTokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + newTokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + renounceOwnership(overrides?: CallOverrides): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: CallOverrides + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "ControllersSet(address[],bool[])"( + controllers?: null, + statuses?: null + ): ControllersSetEventFilter; + ControllersSet( + controllers?: null, + statuses?: null + ): ControllersSetEventFilter; + + "DecreaseLiquidity(uint256)"( + tokenId?: BigNumberish | null + ): DecreaseLiquidityEventFilter; + DecreaseLiquidity( + tokenId?: BigNumberish | null + ): DecreaseLiquidityEventFilter; + + "FeeConfigSet(address,uint96)"( + feeCollector?: null, + feeLimitPips?: null + ): FeeConfigSetEventFilter; + FeeConfigSet( + feeCollector?: null, + feeLimitPips?: null + ): FeeConfigSetEventFilter; + + "IncreaseLiquidity(uint256)"( + tokenId?: BigNumberish | null + ): IncreaseLiquidityEventFilter; + IncreaseLiquidity( + tokenId?: BigNumberish | null + ): IncreaseLiquidityEventFilter; + + "Mint(uint256)"(tokenId?: BigNumberish | null): MintEventFilter; + Mint(tokenId?: BigNumberish | null): MintEventFilter; + + "OwnershipTransferred(address,address)"( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + OwnershipTransferred( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + + "Rebalance(uint256)"(tokenId?: BigNumberish | null): RebalanceEventFilter; + Rebalance(tokenId?: BigNumberish | null): RebalanceEventFilter; + + "Reinvest(uint256)"(tokenId?: BigNumberish | null): ReinvestEventFilter; + Reinvest(tokenId?: BigNumberish | null): ReinvestEventFilter; + + "RemoveLiquidity(uint256)"( + tokenId?: BigNumberish | null + ): RemoveLiquidityEventFilter; + RemoveLiquidity(tokenId?: BigNumberish | null): RemoveLiquidityEventFilter; + + "SetAllowlistedRouters(address[],bool[])"( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + SetAllowlistedRouters( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + }; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + feeConfig(overrides?: CallOverrides): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + isController(arg0: string, overrides?: CallOverrides): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + feeConfig(overrides?: CallOverrides): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + isController( + arg0: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/src/base/Callback.sol/PancakeV3Callback.ts b/src/typechain-typesV4/src/base/Callback.sol/PancakeV3Callback.ts new file mode 100644 index 00000000..2b6a07f7 --- /dev/null +++ b/src/typechain-typesV4/src/base/Callback.sol/PancakeV3Callback.ts @@ -0,0 +1,160 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export interface PancakeV3CallbackInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "deployer()": FunctionFragment; + "npm()": FunctionFragment; + "pancakeV3SwapCallback(int256,int256,bytes)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "WETH9" + | "deployer" + | "npm" + | "pancakeV3SwapCallback" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData(functionFragment: "deployer", values?: undefined): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + encodeFunctionData( + functionFragment: "pancakeV3SwapCallback", + values: [BigNumberish, BigNumberish, BytesLike] + ): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "deployer", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "pancakeV3SwapCallback", + data: BytesLike + ): Result; + + events: {}; +} + +export interface PancakeV3Callback extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: PancakeV3CallbackInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + deployer(overrides?: CallOverrides): Promise<[string]>; + + npm(overrides?: CallOverrides): Promise<[string]>; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + WETH9(overrides?: CallOverrides): Promise; + + deployer(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + deployer(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + }; + + filters: {}; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + deployer(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + deployer(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/src/base/Callback.sol/SlipStreamCallback.ts b/src/typechain-typesV4/src/base/Callback.sol/SlipStreamCallback.ts new file mode 100644 index 00000000..67ee49f9 --- /dev/null +++ b/src/typechain-typesV4/src/base/Callback.sol/SlipStreamCallback.ts @@ -0,0 +1,160 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export interface SlipStreamCallbackInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "factory()": FunctionFragment; + "npm()": FunctionFragment; + "uniswapV3SwapCallback(int256,int256,bytes)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "WETH9" + | "factory" + | "npm" + | "uniswapV3SwapCallback" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData(functionFragment: "factory", values?: undefined): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + encodeFunctionData( + functionFragment: "uniswapV3SwapCallback", + values: [BigNumberish, BigNumberish, BytesLike] + ): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "factory", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "uniswapV3SwapCallback", + data: BytesLike + ): Result; + + events: {}; +} + +export interface SlipStreamCallback extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: SlipStreamCallbackInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + factory(overrides?: CallOverrides): Promise<[string]>; + + npm(overrides?: CallOverrides): Promise<[string]>; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + }; + + filters: {}; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/src/base/Callback.sol/UniswapV3Callback.ts b/src/typechain-typesV4/src/base/Callback.sol/UniswapV3Callback.ts new file mode 100644 index 00000000..799522d3 --- /dev/null +++ b/src/typechain-typesV4/src/base/Callback.sol/UniswapV3Callback.ts @@ -0,0 +1,160 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export interface UniswapV3CallbackInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "factory()": FunctionFragment; + "npm()": FunctionFragment; + "uniswapV3SwapCallback(int256,int256,bytes)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "WETH9" + | "factory" + | "npm" + | "uniswapV3SwapCallback" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData(functionFragment: "factory", values?: undefined): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + encodeFunctionData( + functionFragment: "uniswapV3SwapCallback", + values: [BigNumberish, BigNumberish, BytesLike] + ): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "factory", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "uniswapV3SwapCallback", + data: BytesLike + ): Result; + + events: {}; +} + +export interface UniswapV3Callback extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: UniswapV3CallbackInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + factory(overrides?: CallOverrides): Promise<[string]>; + + npm(overrides?: CallOverrides): Promise<[string]>; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + }; + + filters: {}; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/src/base/Callback.sol/index.ts b/src/typechain-typesV4/src/base/Callback.sol/index.ts new file mode 100644 index 00000000..4394fb44 --- /dev/null +++ b/src/typechain-typesV4/src/base/Callback.sol/index.ts @@ -0,0 +1,6 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export type { PancakeV3Callback } from "./PancakeV3Callback"; +export type { SlipStreamCallback } from "./SlipStreamCallback"; +export type { UniswapV3Callback } from "./UniswapV3Callback"; diff --git a/src/typechain-typesV4/src/base/Immutables.sol/Immutables.ts b/src/typechain-typesV4/src/base/Immutables.sol/Immutables.ts new file mode 100644 index 00000000..3b7e9c3e --- /dev/null +++ b/src/typechain-typesV4/src/base/Immutables.sol/Immutables.ts @@ -0,0 +1,94 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BytesLike, + CallOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export interface ImmutablesInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "npm()": FunctionFragment; + }; + + getFunction(nameOrSignatureOrTopic: "WETH9" | "npm"): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + + events: {}; +} + +export interface Immutables extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: ImmutablesInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + npm(overrides?: CallOverrides): Promise<[string]>; + }; + + WETH9(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + }; + + filters: {}; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + }; +} diff --git a/src/typechain-typesV4/src/base/Immutables.sol/PCSV3Immutables.ts b/src/typechain-typesV4/src/base/Immutables.sol/PCSV3Immutables.ts new file mode 100644 index 00000000..e6f711a0 --- /dev/null +++ b/src/typechain-typesV4/src/base/Immutables.sol/PCSV3Immutables.ts @@ -0,0 +1,109 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BytesLike, + CallOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export interface PCSV3ImmutablesInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "deployer()": FunctionFragment; + "npm()": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: "WETH9" | "deployer" | "npm" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData(functionFragment: "deployer", values?: undefined): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "deployer", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + + events: {}; +} + +export interface PCSV3Immutables extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: PCSV3ImmutablesInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + deployer(overrides?: CallOverrides): Promise<[string]>; + + npm(overrides?: CallOverrides): Promise<[string]>; + }; + + WETH9(overrides?: CallOverrides): Promise; + + deployer(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + deployer(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + }; + + filters: {}; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + deployer(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + deployer(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + }; +} diff --git a/src/typechain-typesV4/src/base/Immutables.sol/UniV3Immutables.ts b/src/typechain-typesV4/src/base/Immutables.sol/UniV3Immutables.ts new file mode 100644 index 00000000..30c7e65a --- /dev/null +++ b/src/typechain-typesV4/src/base/Immutables.sol/UniV3Immutables.ts @@ -0,0 +1,109 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BytesLike, + CallOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export interface UniV3ImmutablesInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "factory()": FunctionFragment; + "npm()": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: "WETH9" | "factory" | "npm" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData(functionFragment: "factory", values?: undefined): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "factory", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + + events: {}; +} + +export interface UniV3Immutables extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: UniV3ImmutablesInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + factory(overrides?: CallOverrides): Promise<[string]>; + + npm(overrides?: CallOverrides): Promise<[string]>; + }; + + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + }; + + filters: {}; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + }; +} diff --git a/src/typechain-typesV4/src/base/Immutables.sol/index.ts b/src/typechain-typesV4/src/base/Immutables.sol/index.ts new file mode 100644 index 00000000..4d2c1b4e --- /dev/null +++ b/src/typechain-typesV4/src/base/Immutables.sol/index.ts @@ -0,0 +1,6 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export type { Immutables } from "./Immutables"; +export type { PCSV3Immutables } from "./PCSV3Immutables"; +export type { UniV3Immutables } from "./UniV3Immutables"; diff --git a/src/typechain-typesV4/src/base/OptimalSwapRouter.ts b/src/typechain-typesV4/src/base/OptimalSwapRouter.ts new file mode 100644 index 00000000..116dfe8b --- /dev/null +++ b/src/typechain-typesV4/src/base/OptimalSwapRouter.ts @@ -0,0 +1,305 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../common"; + +export interface OptimalSwapRouterInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "isAllowListedRouter(address)": FunctionFragment; + "npm()": FunctionFragment; + "owner()": FunctionFragment; + "renounceOwnership()": FunctionFragment; + "setAllowlistedRouters(address[],bool[])": FunctionFragment; + "transferOwnership(address)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "WETH9" + | "isAllowListedRouter" + | "npm" + | "owner" + | "renounceOwnership" + | "setAllowlistedRouters" + | "transferOwnership" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData( + functionFragment: "isAllowListedRouter", + values: [string] + ): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + encodeFunctionData(functionFragment: "owner", values?: undefined): string; + encodeFunctionData( + functionFragment: "renounceOwnership", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "setAllowlistedRouters", + values: [string[], boolean[]] + ): string; + encodeFunctionData( + functionFragment: "transferOwnership", + values: [string] + ): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "isAllowListedRouter", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "owner", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "renounceOwnership", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setAllowlistedRouters", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "transferOwnership", + data: BytesLike + ): Result; + + events: { + "OwnershipTransferred(address,address)": EventFragment; + "SetAllowlistedRouters(address[],bool[])": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "OwnershipTransferred"): EventFragment; + getEvent(nameOrSignatureOrTopic: "SetAllowlistedRouters"): EventFragment; +} + +export interface OwnershipTransferredEventObject { + previousOwner: string; + newOwner: string; +} +export type OwnershipTransferredEvent = TypedEvent< + [string, string], + OwnershipTransferredEventObject +>; + +export type OwnershipTransferredEventFilter = + TypedEventFilter; + +export interface SetAllowlistedRoutersEventObject { + routers: string[]; + statuses: boolean[]; +} +export type SetAllowlistedRoutersEvent = TypedEvent< + [string[], boolean[]], + SetAllowlistedRoutersEventObject +>; + +export type SetAllowlistedRoutersEventFilter = + TypedEventFilter; + +export interface OptimalSwapRouter extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: OptimalSwapRouterInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise<[boolean]>; + + npm(overrides?: CallOverrides): Promise<[string]>; + + owner(overrides?: CallOverrides): Promise<[string]>; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + WETH9(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership(overrides?: CallOverrides): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "OwnershipTransferred(address,address)"( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + OwnershipTransferred( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + + "SetAllowlistedRouters(address[],bool[])"( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + SetAllowlistedRouters( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + }; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/src/base/Payments.ts b/src/typechain-typesV4/src/base/Payments.ts new file mode 100644 index 00000000..4a8689f1 --- /dev/null +++ b/src/typechain-typesV4/src/base/Payments.ts @@ -0,0 +1,94 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BytesLike, + CallOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../common"; + +export interface PaymentsInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "npm()": FunctionFragment; + }; + + getFunction(nameOrSignatureOrTopic: "WETH9" | "npm"): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + + events: {}; +} + +export interface Payments extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: PaymentsInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + npm(overrides?: CallOverrides): Promise<[string]>; + }; + + WETH9(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + }; + + filters: {}; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + }; +} diff --git a/src/typechain-typesV4/src/base/SlipStreamSwapRouter.ts b/src/typechain-typesV4/src/base/SlipStreamSwapRouter.ts new file mode 100644 index 00000000..0ce3a735 --- /dev/null +++ b/src/typechain-typesV4/src/base/SlipStreamSwapRouter.ts @@ -0,0 +1,365 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../common"; + +export interface SlipStreamSwapRouterInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "factory()": FunctionFragment; + "isAllowListedRouter(address)": FunctionFragment; + "npm()": FunctionFragment; + "owner()": FunctionFragment; + "renounceOwnership()": FunctionFragment; + "setAllowlistedRouters(address[],bool[])": FunctionFragment; + "transferOwnership(address)": FunctionFragment; + "uniswapV3SwapCallback(int256,int256,bytes)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "WETH9" + | "factory" + | "isAllowListedRouter" + | "npm" + | "owner" + | "renounceOwnership" + | "setAllowlistedRouters" + | "transferOwnership" + | "uniswapV3SwapCallback" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData(functionFragment: "factory", values?: undefined): string; + encodeFunctionData( + functionFragment: "isAllowListedRouter", + values: [string] + ): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + encodeFunctionData(functionFragment: "owner", values?: undefined): string; + encodeFunctionData( + functionFragment: "renounceOwnership", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "setAllowlistedRouters", + values: [string[], boolean[]] + ): string; + encodeFunctionData( + functionFragment: "transferOwnership", + values: [string] + ): string; + encodeFunctionData( + functionFragment: "uniswapV3SwapCallback", + values: [BigNumberish, BigNumberish, BytesLike] + ): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "factory", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "isAllowListedRouter", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "owner", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "renounceOwnership", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setAllowlistedRouters", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "transferOwnership", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "uniswapV3SwapCallback", + data: BytesLike + ): Result; + + events: { + "OwnershipTransferred(address,address)": EventFragment; + "SetAllowlistedRouters(address[],bool[])": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "OwnershipTransferred"): EventFragment; + getEvent(nameOrSignatureOrTopic: "SetAllowlistedRouters"): EventFragment; +} + +export interface OwnershipTransferredEventObject { + previousOwner: string; + newOwner: string; +} +export type OwnershipTransferredEvent = TypedEvent< + [string, string], + OwnershipTransferredEventObject +>; + +export type OwnershipTransferredEventFilter = + TypedEventFilter; + +export interface SetAllowlistedRoutersEventObject { + routers: string[]; + statuses: boolean[]; +} +export type SetAllowlistedRoutersEvent = TypedEvent< + [string[], boolean[]], + SetAllowlistedRoutersEventObject +>; + +export type SetAllowlistedRoutersEventFilter = + TypedEventFilter; + +export interface SlipStreamSwapRouter extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: SlipStreamSwapRouterInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + factory(overrides?: CallOverrides): Promise<[string]>; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise<[boolean]>; + + npm(overrides?: CallOverrides): Promise<[string]>; + + owner(overrides?: CallOverrides): Promise<[string]>; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership(overrides?: CallOverrides): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: CallOverrides + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "OwnershipTransferred(address,address)"( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + OwnershipTransferred( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + + "SetAllowlistedRouters(address[],bool[])"( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + SetAllowlistedRouters( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + }; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/src/base/SwapRouter.sol/PCSV3SwapRouter.ts b/src/typechain-typesV4/src/base/SwapRouter.sol/PCSV3SwapRouter.ts new file mode 100644 index 00000000..0f9b66cd --- /dev/null +++ b/src/typechain-typesV4/src/base/SwapRouter.sol/PCSV3SwapRouter.ts @@ -0,0 +1,365 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export interface PCSV3SwapRouterInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "deployer()": FunctionFragment; + "isAllowListedRouter(address)": FunctionFragment; + "npm()": FunctionFragment; + "owner()": FunctionFragment; + "pancakeV3SwapCallback(int256,int256,bytes)": FunctionFragment; + "renounceOwnership()": FunctionFragment; + "setAllowlistedRouters(address[],bool[])": FunctionFragment; + "transferOwnership(address)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "WETH9" + | "deployer" + | "isAllowListedRouter" + | "npm" + | "owner" + | "pancakeV3SwapCallback" + | "renounceOwnership" + | "setAllowlistedRouters" + | "transferOwnership" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData(functionFragment: "deployer", values?: undefined): string; + encodeFunctionData( + functionFragment: "isAllowListedRouter", + values: [string] + ): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + encodeFunctionData(functionFragment: "owner", values?: undefined): string; + encodeFunctionData( + functionFragment: "pancakeV3SwapCallback", + values: [BigNumberish, BigNumberish, BytesLike] + ): string; + encodeFunctionData( + functionFragment: "renounceOwnership", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "setAllowlistedRouters", + values: [string[], boolean[]] + ): string; + encodeFunctionData( + functionFragment: "transferOwnership", + values: [string] + ): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "deployer", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "isAllowListedRouter", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "owner", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "pancakeV3SwapCallback", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "renounceOwnership", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setAllowlistedRouters", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "transferOwnership", + data: BytesLike + ): Result; + + events: { + "OwnershipTransferred(address,address)": EventFragment; + "SetAllowlistedRouters(address[],bool[])": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "OwnershipTransferred"): EventFragment; + getEvent(nameOrSignatureOrTopic: "SetAllowlistedRouters"): EventFragment; +} + +export interface OwnershipTransferredEventObject { + previousOwner: string; + newOwner: string; +} +export type OwnershipTransferredEvent = TypedEvent< + [string, string], + OwnershipTransferredEventObject +>; + +export type OwnershipTransferredEventFilter = + TypedEventFilter; + +export interface SetAllowlistedRoutersEventObject { + routers: string[]; + statuses: boolean[]; +} +export type SetAllowlistedRoutersEvent = TypedEvent< + [string[], boolean[]], + SetAllowlistedRoutersEventObject +>; + +export type SetAllowlistedRoutersEventFilter = + TypedEventFilter; + +export interface PCSV3SwapRouter extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: PCSV3SwapRouterInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + deployer(overrides?: CallOverrides): Promise<[string]>; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise<[boolean]>; + + npm(overrides?: CallOverrides): Promise<[string]>; + + owner(overrides?: CallOverrides): Promise<[string]>; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + WETH9(overrides?: CallOverrides): Promise; + + deployer(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + deployer(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + + renounceOwnership(overrides?: CallOverrides): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "OwnershipTransferred(address,address)"( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + OwnershipTransferred( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + + "SetAllowlistedRouters(address[],bool[])"( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + SetAllowlistedRouters( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + }; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + deployer(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + deployer(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/src/base/SwapRouter.sol/SwapRouter.ts b/src/typechain-typesV4/src/base/SwapRouter.sol/SwapRouter.ts new file mode 100644 index 00000000..007240fc --- /dev/null +++ b/src/typechain-typesV4/src/base/SwapRouter.sol/SwapRouter.ts @@ -0,0 +1,305 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export interface SwapRouterInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "isAllowListedRouter(address)": FunctionFragment; + "npm()": FunctionFragment; + "owner()": FunctionFragment; + "renounceOwnership()": FunctionFragment; + "setAllowlistedRouters(address[],bool[])": FunctionFragment; + "transferOwnership(address)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "WETH9" + | "isAllowListedRouter" + | "npm" + | "owner" + | "renounceOwnership" + | "setAllowlistedRouters" + | "transferOwnership" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData( + functionFragment: "isAllowListedRouter", + values: [string] + ): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + encodeFunctionData(functionFragment: "owner", values?: undefined): string; + encodeFunctionData( + functionFragment: "renounceOwnership", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "setAllowlistedRouters", + values: [string[], boolean[]] + ): string; + encodeFunctionData( + functionFragment: "transferOwnership", + values: [string] + ): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "isAllowListedRouter", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "owner", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "renounceOwnership", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setAllowlistedRouters", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "transferOwnership", + data: BytesLike + ): Result; + + events: { + "OwnershipTransferred(address,address)": EventFragment; + "SetAllowlistedRouters(address[],bool[])": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "OwnershipTransferred"): EventFragment; + getEvent(nameOrSignatureOrTopic: "SetAllowlistedRouters"): EventFragment; +} + +export interface OwnershipTransferredEventObject { + previousOwner: string; + newOwner: string; +} +export type OwnershipTransferredEvent = TypedEvent< + [string, string], + OwnershipTransferredEventObject +>; + +export type OwnershipTransferredEventFilter = + TypedEventFilter; + +export interface SetAllowlistedRoutersEventObject { + routers: string[]; + statuses: boolean[]; +} +export type SetAllowlistedRoutersEvent = TypedEvent< + [string[], boolean[]], + SetAllowlistedRoutersEventObject +>; + +export type SetAllowlistedRoutersEventFilter = + TypedEventFilter; + +export interface SwapRouter extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: SwapRouterInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise<[boolean]>; + + npm(overrides?: CallOverrides): Promise<[string]>; + + owner(overrides?: CallOverrides): Promise<[string]>; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + WETH9(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership(overrides?: CallOverrides): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "OwnershipTransferred(address,address)"( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + OwnershipTransferred( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + + "SetAllowlistedRouters(address[],bool[])"( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + SetAllowlistedRouters( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + }; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/src/base/SwapRouter.sol/UniV3SwapRouter.ts b/src/typechain-typesV4/src/base/SwapRouter.sol/UniV3SwapRouter.ts new file mode 100644 index 00000000..ea5e6b6a --- /dev/null +++ b/src/typechain-typesV4/src/base/SwapRouter.sol/UniV3SwapRouter.ts @@ -0,0 +1,365 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export interface UniV3SwapRouterInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "factory()": FunctionFragment; + "isAllowListedRouter(address)": FunctionFragment; + "npm()": FunctionFragment; + "owner()": FunctionFragment; + "renounceOwnership()": FunctionFragment; + "setAllowlistedRouters(address[],bool[])": FunctionFragment; + "transferOwnership(address)": FunctionFragment; + "uniswapV3SwapCallback(int256,int256,bytes)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "WETH9" + | "factory" + | "isAllowListedRouter" + | "npm" + | "owner" + | "renounceOwnership" + | "setAllowlistedRouters" + | "transferOwnership" + | "uniswapV3SwapCallback" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData(functionFragment: "factory", values?: undefined): string; + encodeFunctionData( + functionFragment: "isAllowListedRouter", + values: [string] + ): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + encodeFunctionData(functionFragment: "owner", values?: undefined): string; + encodeFunctionData( + functionFragment: "renounceOwnership", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "setAllowlistedRouters", + values: [string[], boolean[]] + ): string; + encodeFunctionData( + functionFragment: "transferOwnership", + values: [string] + ): string; + encodeFunctionData( + functionFragment: "uniswapV3SwapCallback", + values: [BigNumberish, BigNumberish, BytesLike] + ): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "factory", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "isAllowListedRouter", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "owner", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "renounceOwnership", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setAllowlistedRouters", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "transferOwnership", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "uniswapV3SwapCallback", + data: BytesLike + ): Result; + + events: { + "OwnershipTransferred(address,address)": EventFragment; + "SetAllowlistedRouters(address[],bool[])": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "OwnershipTransferred"): EventFragment; + getEvent(nameOrSignatureOrTopic: "SetAllowlistedRouters"): EventFragment; +} + +export interface OwnershipTransferredEventObject { + previousOwner: string; + newOwner: string; +} +export type OwnershipTransferredEvent = TypedEvent< + [string, string], + OwnershipTransferredEventObject +>; + +export type OwnershipTransferredEventFilter = + TypedEventFilter; + +export interface SetAllowlistedRoutersEventObject { + routers: string[]; + statuses: boolean[]; +} +export type SetAllowlistedRoutersEvent = TypedEvent< + [string[], boolean[]], + SetAllowlistedRoutersEventObject +>; + +export type SetAllowlistedRoutersEventFilter = + TypedEventFilter; + +export interface UniV3SwapRouter extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: UniV3SwapRouterInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + factory(overrides?: CallOverrides): Promise<[string]>; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise<[boolean]>; + + npm(overrides?: CallOverrides): Promise<[string]>; + + owner(overrides?: CallOverrides): Promise<[string]>; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership(overrides?: CallOverrides): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: CallOverrides + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "OwnershipTransferred(address,address)"( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + OwnershipTransferred( + previousOwner?: string | null, + newOwner?: string | null + ): OwnershipTransferredEventFilter; + + "SetAllowlistedRouters(address[],bool[])"( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + SetAllowlistedRouters( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + }; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + isAllowListedRouter( + arg0: string, + overrides?: CallOverrides + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + owner(overrides?: CallOverrides): Promise; + + renounceOwnership( + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + transferOwnership( + newOwner: string, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/src/base/SwapRouter.sol/index.ts b/src/typechain-typesV4/src/base/SwapRouter.sol/index.ts new file mode 100644 index 00000000..ad86ba85 --- /dev/null +++ b/src/typechain-typesV4/src/base/SwapRouter.sol/index.ts @@ -0,0 +1,6 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export type { PCSV3SwapRouter } from "./PCSV3SwapRouter"; +export type { SwapRouter } from "./SwapRouter"; +export type { UniV3SwapRouter } from "./UniV3SwapRouter"; diff --git a/src/typechain-typesV4/src/base/index.ts b/src/typechain-typesV4/src/base/index.ts new file mode 100644 index 00000000..4870090e --- /dev/null +++ b/src/typechain-typesV4/src/base/index.ts @@ -0,0 +1,13 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as callbackSol from "./Callback.sol"; +export type { callbackSol }; +import type * as immutablesSol from "./Immutables.sol"; +export type { immutablesSol }; +import type * as swapRouterSol from "./SwapRouter.sol"; +export type { swapRouterSol }; +export type { Automan } from "./Automan"; +export type { OptimalSwapRouter } from "./OptimalSwapRouter"; +export type { Payments } from "./Payments"; +export type { SlipStreamSwapRouter } from "./SlipStreamSwapRouter"; diff --git a/src/typechain-typesV4/src/index.ts b/src/typechain-typesV4/src/index.ts new file mode 100644 index 00000000..0e082323 --- /dev/null +++ b/src/typechain-typesV4/src/index.ts @@ -0,0 +1,15 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as base from "./base"; +export type { base }; +import type * as interfaces from "./interfaces"; +export type { interfaces }; +import type * as libraries from "./libraries"; +export type { libraries }; +export type { PCSV3Automan } from "./PCSV3Automan"; +export type { PCSV3OptimalSwapRouter } from "./PCSV3OptimalSwapRouter"; +export type { SlipStreamAutoman } from "./SlipStreamAutoman"; +export type { SlipStreamOptimalSwapRouter } from "./SlipStreamOptimalSwapRouter"; +export type { UniV3Automan } from "./UniV3Automan"; +export type { UniV3OptimalSwapRouter } from "./UniV3OptimalSwapRouter"; diff --git a/src/typechain-typesV4/src/interfaces/IAutoman.sol/IAutomanCommon.ts b/src/typechain-typesV4/src/interfaces/IAutoman.sol/IAutomanCommon.ts new file mode 100644 index 00000000..c04f2b0b --- /dev/null +++ b/src/typechain-typesV4/src/interfaces/IAutoman.sol/IAutomanCommon.ts @@ -0,0 +1,1138 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export declare namespace ICommonNonfungiblePositionManager { + export type DecreaseLiquidityParamsStruct = { + tokenId: BigNumberish; + liquidity: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + deadline: BigNumberish; + }; + + export type DecreaseLiquidityParamsStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + deadline: BigNumber; + }; + + export type IncreaseLiquidityParamsStruct = { + tokenId: BigNumberish; + amount0Desired: BigNumberish; + amount1Desired: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + deadline: BigNumberish; + }; + + export type IncreaseLiquidityParamsStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + amount0Desired: BigNumber; + amount1Desired: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + deadline: BigNumber; + }; +} + +export declare namespace IAutomanCommon { + export type FeeConfigStruct = { + feeCollector: string; + feeLimitPips: BigNumberish; + }; + + export type FeeConfigStructOutput = [string, BigNumber] & { + feeCollector: string; + feeLimitPips: BigNumber; + }; +} + +export interface IAutomanCommonInterface extends utils.Interface { + functions: { + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)": FunctionFragment; + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)": FunctionFragment; + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "getOptimalSwap(address,int24,int24,uint256,uint256)": FunctionFragment; + "increaseLiquidity((uint256,uint256,uint256,uint256,uint256,uint256))": FunctionFragment; + "increaseLiquidityOptimal((uint256,uint256,uint256,uint256,uint256,uint256),bytes,uint256,uint256)": FunctionFragment; + "increaseLiquidityWithTokenIn((uint256,uint256,uint256,uint256,uint256,uint256),address,uint256,bytes,bytes)": FunctionFragment; + "isController(address)": FunctionFragment; + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)": FunctionFragment; + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "setAllowlistedRouters(address[],bool[])": FunctionFragment; + "setControllers(address[],bool[])": FunctionFragment; + "setFeeConfig((address,uint96))": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)" + | "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)" + | "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)" + | "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)" + | "getOptimalSwap" + | "increaseLiquidity" + | "increaseLiquidityOptimal" + | "increaseLiquidityWithTokenIn" + | "isController" + | "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)" + | "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)" + | "setAllowlistedRouters" + | "setControllers" + | "setFeeConfig" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + boolean + ] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + boolean, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike, + boolean + ] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike, + boolean, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "getOptimalSwap", + values: [string, BigNumberish, BigNumberish, BigNumberish, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidity", + values: [ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidityOptimal", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + BytesLike, + BigNumberish, + BigNumberish + ] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidityWithTokenIn", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "isController", + values: [string] + ): string; + encodeFunctionData( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + BytesLike, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "setAllowlistedRouters", + values: [string[], boolean[]] + ): string; + encodeFunctionData( + functionFragment: "setControllers", + values: [string[], boolean[]] + ): string; + encodeFunctionData( + functionFragment: "setFeeConfig", + values: [IAutomanCommon.FeeConfigStruct] + ): string; + + decodeFunctionResult( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "getOptimalSwap", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidity", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidityOptimal", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidityWithTokenIn", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "isController", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setAllowlistedRouters", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setControllers", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setFeeConfig", + data: BytesLike + ): Result; + + events: { + "ControllersSet(address[],bool[])": EventFragment; + "DecreaseLiquidity(uint256)": EventFragment; + "FeeConfigSet(address,uint96)": EventFragment; + "IncreaseLiquidity(uint256)": EventFragment; + "Mint(uint256)": EventFragment; + "Rebalance(uint256)": EventFragment; + "Reinvest(uint256)": EventFragment; + "RemoveLiquidity(uint256)": EventFragment; + "SetAllowlistedRouters(address[],bool[])": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "ControllersSet"): EventFragment; + getEvent(nameOrSignatureOrTopic: "DecreaseLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "FeeConfigSet"): EventFragment; + getEvent(nameOrSignatureOrTopic: "IncreaseLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Mint"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Rebalance"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Reinvest"): EventFragment; + getEvent(nameOrSignatureOrTopic: "RemoveLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "SetAllowlistedRouters"): EventFragment; +} + +export interface ControllersSetEventObject { + controllers: string[]; + statuses: boolean[]; +} +export type ControllersSetEvent = TypedEvent< + [string[], boolean[]], + ControllersSetEventObject +>; + +export type ControllersSetEventFilter = TypedEventFilter; + +export interface DecreaseLiquidityEventObject { + tokenId: BigNumber; +} +export type DecreaseLiquidityEvent = TypedEvent< + [BigNumber], + DecreaseLiquidityEventObject +>; + +export type DecreaseLiquidityEventFilter = + TypedEventFilter; + +export interface FeeConfigSetEventObject { + feeCollector: string; + feeLimitPips: BigNumber; +} +export type FeeConfigSetEvent = TypedEvent< + [string, BigNumber], + FeeConfigSetEventObject +>; + +export type FeeConfigSetEventFilter = TypedEventFilter; + +export interface IncreaseLiquidityEventObject { + tokenId: BigNumber; +} +export type IncreaseLiquidityEvent = TypedEvent< + [BigNumber], + IncreaseLiquidityEventObject +>; + +export type IncreaseLiquidityEventFilter = + TypedEventFilter; + +export interface MintEventObject { + tokenId: BigNumber; +} +export type MintEvent = TypedEvent<[BigNumber], MintEventObject>; + +export type MintEventFilter = TypedEventFilter; + +export interface RebalanceEventObject { + tokenId: BigNumber; +} +export type RebalanceEvent = TypedEvent<[BigNumber], RebalanceEventObject>; + +export type RebalanceEventFilter = TypedEventFilter; + +export interface ReinvestEventObject { + tokenId: BigNumber; +} +export type ReinvestEvent = TypedEvent<[BigNumber], ReinvestEventObject>; + +export type ReinvestEventFilter = TypedEventFilter; + +export interface RemoveLiquidityEventObject { + tokenId: BigNumber; +} +export type RemoveLiquidityEvent = TypedEvent< + [BigNumber], + RemoveLiquidityEventObject +>; + +export type RemoveLiquidityEventFilter = TypedEventFilter; + +export interface SetAllowlistedRoutersEventObject { + routers: string[]; + statuses: boolean[]; +} +export type SetAllowlistedRoutersEvent = TypedEvent< + [string[], boolean[]], + SetAllowlistedRoutersEventObject +>; + +export type SetAllowlistedRoutersEventFilter = + TypedEventFilter; + +export interface IAutomanCommon extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IAutomanCommonInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, boolean, BigNumber] & { + amountIn: BigNumber; + amountOut: BigNumber; + zeroForOne: boolean; + sqrtPriceX96: BigNumber; + } + >; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isController( + addressToCheck: string, + overrides?: CallOverrides + ): Promise<[boolean]>; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, boolean, BigNumber] & { + amountIn: BigNumber; + amountOut: BigNumber; + zeroForOne: boolean; + sqrtPriceX96: BigNumber; + } + >; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isController( + addressToCheck: string, + overrides?: CallOverrides + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: CallOverrides + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, boolean, BigNumber] & { + amountIn: BigNumber; + amountOut: BigNumber; + zeroForOne: boolean; + sqrtPriceX96: BigNumber; + } + >; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + isController( + addressToCheck: string, + overrides?: CallOverrides + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "ControllersSet(address[],bool[])"( + controllers?: null, + statuses?: null + ): ControllersSetEventFilter; + ControllersSet( + controllers?: null, + statuses?: null + ): ControllersSetEventFilter; + + "DecreaseLiquidity(uint256)"( + tokenId?: BigNumberish | null + ): DecreaseLiquidityEventFilter; + DecreaseLiquidity( + tokenId?: BigNumberish | null + ): DecreaseLiquidityEventFilter; + + "FeeConfigSet(address,uint96)"( + feeCollector?: null, + feeLimitPips?: null + ): FeeConfigSetEventFilter; + FeeConfigSet( + feeCollector?: null, + feeLimitPips?: null + ): FeeConfigSetEventFilter; + + "IncreaseLiquidity(uint256)"( + tokenId?: BigNumberish | null + ): IncreaseLiquidityEventFilter; + IncreaseLiquidity( + tokenId?: BigNumberish | null + ): IncreaseLiquidityEventFilter; + + "Mint(uint256)"(tokenId?: BigNumberish | null): MintEventFilter; + Mint(tokenId?: BigNumberish | null): MintEventFilter; + + "Rebalance(uint256)"(tokenId?: BigNumberish | null): RebalanceEventFilter; + Rebalance(tokenId?: BigNumberish | null): RebalanceEventFilter; + + "Reinvest(uint256)"(tokenId?: BigNumberish | null): ReinvestEventFilter; + Reinvest(tokenId?: BigNumberish | null): ReinvestEventFilter; + + "RemoveLiquidity(uint256)"( + tokenId?: BigNumberish | null + ): RemoveLiquidityEventFilter; + RemoveLiquidity(tokenId?: BigNumberish | null): RemoveLiquidityEventFilter; + + "SetAllowlistedRouters(address[],bool[])"( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + SetAllowlistedRouters( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + }; + + estimateGas: { + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isController( + addressToCheck: string, + overrides?: CallOverrides + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isController( + addressToCheck: string, + overrides?: CallOverrides + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/src/interfaces/IAutoman.sol/IAutomanSlipStreamMintRebalance.ts b/src/typechain-typesV4/src/interfaces/IAutoman.sol/IAutomanSlipStreamMintRebalance.ts new file mode 100644 index 00000000..59e7f757 --- /dev/null +++ b/src/typechain-typesV4/src/interfaces/IAutoman.sol/IAutomanSlipStreamMintRebalance.ts @@ -0,0 +1,449 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export declare namespace ISlipStreamNonfungiblePositionManager { + export type MintParamsStruct = { + token0: string; + token1: string; + tickSpacing: BigNumberish; + tickLower: BigNumberish; + tickUpper: BigNumberish; + amount0Desired: BigNumberish; + amount1Desired: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + recipient: string; + deadline: BigNumberish; + sqrtPriceX96: BigNumberish; + }; + + export type MintParamsStructOutput = [ + string, + string, + number, + number, + number, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + string, + BigNumber, + BigNumber + ] & { + token0: string; + token1: string; + tickSpacing: number; + tickLower: number; + tickUpper: number; + amount0Desired: BigNumber; + amount1Desired: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + recipient: string; + deadline: BigNumber; + sqrtPriceX96: BigNumber; + }; +} + +export interface IAutomanSlipStreamMintRebalanceInterface + extends utils.Interface { + functions: { + "mint((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160))": FunctionFragment; + "mintOptimal((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),bytes,uint256,uint256)": FunctionFragment; + "mintWithTokenIn((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),address,uint256,bytes,bytes)": FunctionFragment; + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "mint" + | "mintOptimal" + | "mintWithTokenIn" + | "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)" + | "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "mint", + values: [ISlipStreamNonfungiblePositionManager.MintParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "mintOptimal", + values: [ + ISlipStreamNonfungiblePositionManager.MintParamsStruct, + BytesLike, + BigNumberish, + BigNumberish + ] + ): string; + encodeFunctionData( + functionFragment: "mintWithTokenIn", + values: [ + ISlipStreamNonfungiblePositionManager.MintParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + values: [ + ISlipStreamNonfungiblePositionManager.MintParamsStruct, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)", + values: [ + ISlipStreamNonfungiblePositionManager.MintParamsStruct, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike + ] + ): string; + + decodeFunctionResult(functionFragment: "mint", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "mintOptimal", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "mintWithTokenIn", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)", + data: BytesLike + ): Result; + + events: {}; +} + +export interface IAutomanSlipStreamMintRebalance extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IAutomanSlipStreamMintRebalanceInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + mint( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + mint( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + mint( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + mintOptimal( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + mintWithTokenIn( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + newTokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + newTokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + }; + + filters: {}; + + estimateGas: { + mint( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + mint( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/src/interfaces/IAutoman.sol/IAutomanUniV3MintRebalance.ts b/src/typechain-typesV4/src/interfaces/IAutoman.sol/IAutomanUniV3MintRebalance.ts new file mode 100644 index 00000000..da171a8d --- /dev/null +++ b/src/typechain-typesV4/src/interfaces/IAutoman.sol/IAutomanUniV3MintRebalance.ts @@ -0,0 +1,445 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export declare namespace IUniswapV3NonfungiblePositionManager { + export type MintParamsStruct = { + token0: string; + token1: string; + fee: BigNumberish; + tickLower: BigNumberish; + tickUpper: BigNumberish; + amount0Desired: BigNumberish; + amount1Desired: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + recipient: string; + deadline: BigNumberish; + }; + + export type MintParamsStructOutput = [ + string, + string, + number, + number, + number, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + string, + BigNumber + ] & { + token0: string; + token1: string; + fee: number; + tickLower: number; + tickUpper: number; + amount0Desired: BigNumber; + amount1Desired: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + recipient: string; + deadline: BigNumber; + }; +} + +export interface IAutomanUniV3MintRebalanceInterface extends utils.Interface { + functions: { + "mint((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256))": FunctionFragment; + "mintOptimal((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),bytes,uint256,uint256)": FunctionFragment; + "mintWithTokenIn((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),address,uint256,bytes,bytes)": FunctionFragment; + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)": FunctionFragment; + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "mint" + | "mintOptimal" + | "mintWithTokenIn" + | "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)" + | "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "mint", + values: [IUniswapV3NonfungiblePositionManager.MintParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "mintOptimal", + values: [ + IUniswapV3NonfungiblePositionManager.MintParamsStruct, + BytesLike, + BigNumberish, + BigNumberish + ] + ): string; + encodeFunctionData( + functionFragment: "mintWithTokenIn", + values: [ + IUniswapV3NonfungiblePositionManager.MintParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)", + values: [ + IUniswapV3NonfungiblePositionManager.MintParamsStruct, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + values: [ + IUniswapV3NonfungiblePositionManager.MintParamsStruct, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + + decodeFunctionResult(functionFragment: "mint", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "mintOptimal", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "mintWithTokenIn", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + + events: {}; +} + +export interface IAutomanUniV3MintRebalance extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IAutomanUniV3MintRebalanceInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + newTokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + newTokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + }; + + filters: {}; + + estimateGas: { + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/src/interfaces/IAutoman.sol/IPCSV3Automan.ts b/src/typechain-typesV4/src/interfaces/IAutoman.sol/IPCSV3Automan.ts new file mode 100644 index 00000000..1d270f14 --- /dev/null +++ b/src/typechain-typesV4/src/interfaces/IAutoman.sol/IPCSV3Automan.ts @@ -0,0 +1,1596 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export declare namespace ICommonNonfungiblePositionManager { + export type DecreaseLiquidityParamsStruct = { + tokenId: BigNumberish; + liquidity: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + deadline: BigNumberish; + }; + + export type DecreaseLiquidityParamsStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + deadline: BigNumber; + }; + + export type IncreaseLiquidityParamsStruct = { + tokenId: BigNumberish; + amount0Desired: BigNumberish; + amount1Desired: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + deadline: BigNumberish; + }; + + export type IncreaseLiquidityParamsStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + amount0Desired: BigNumber; + amount1Desired: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + deadline: BigNumber; + }; +} + +export declare namespace IUniswapV3NonfungiblePositionManager { + export type MintParamsStruct = { + token0: string; + token1: string; + fee: BigNumberish; + tickLower: BigNumberish; + tickUpper: BigNumberish; + amount0Desired: BigNumberish; + amount1Desired: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + recipient: string; + deadline: BigNumberish; + }; + + export type MintParamsStructOutput = [ + string, + string, + number, + number, + number, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + string, + BigNumber + ] & { + token0: string; + token1: string; + fee: number; + tickLower: number; + tickUpper: number; + amount0Desired: BigNumber; + amount1Desired: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + recipient: string; + deadline: BigNumber; + }; +} + +export declare namespace IAutomanCommon { + export type FeeConfigStruct = { + feeCollector: string; + feeLimitPips: BigNumberish; + }; + + export type FeeConfigStructOutput = [string, BigNumber] & { + feeCollector: string; + feeLimitPips: BigNumber; + }; +} + +export interface IPCSV3AutomanInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)": FunctionFragment; + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)": FunctionFragment; + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "deployer()": FunctionFragment; + "getOptimalSwap(address,int24,int24,uint256,uint256)": FunctionFragment; + "increaseLiquidity((uint256,uint256,uint256,uint256,uint256,uint256))": FunctionFragment; + "increaseLiquidityOptimal((uint256,uint256,uint256,uint256,uint256,uint256),bytes,uint256,uint256)": FunctionFragment; + "increaseLiquidityWithTokenIn((uint256,uint256,uint256,uint256,uint256,uint256),address,uint256,bytes,bytes)": FunctionFragment; + "isController(address)": FunctionFragment; + "mint((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256))": FunctionFragment; + "mintOptimal((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),bytes,uint256,uint256)": FunctionFragment; + "mintWithTokenIn((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),address,uint256,bytes,bytes)": FunctionFragment; + "npm()": FunctionFragment; + "pancakeV3SwapCallback(int256,int256,bytes)": FunctionFragment; + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)": FunctionFragment; + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)": FunctionFragment; + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "setAllowlistedRouters(address[],bool[])": FunctionFragment; + "setControllers(address[],bool[])": FunctionFragment; + "setFeeConfig((address,uint96))": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "WETH9" + | "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)" + | "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)" + | "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)" + | "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)" + | "deployer" + | "getOptimalSwap" + | "increaseLiquidity" + | "increaseLiquidityOptimal" + | "increaseLiquidityWithTokenIn" + | "isController" + | "mint" + | "mintOptimal" + | "mintWithTokenIn" + | "npm" + | "pancakeV3SwapCallback" + | "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)" + | "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)" + | "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)" + | "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)" + | "setAllowlistedRouters" + | "setControllers" + | "setFeeConfig" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + boolean + ] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + boolean, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike, + boolean + ] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike, + boolean, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData(functionFragment: "deployer", values?: undefined): string; + encodeFunctionData( + functionFragment: "getOptimalSwap", + values: [string, BigNumberish, BigNumberish, BigNumberish, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidity", + values: [ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidityOptimal", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + BytesLike, + BigNumberish, + BigNumberish + ] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidityWithTokenIn", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "isController", + values: [string] + ): string; + encodeFunctionData( + functionFragment: "mint", + values: [IUniswapV3NonfungiblePositionManager.MintParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "mintOptimal", + values: [ + IUniswapV3NonfungiblePositionManager.MintParamsStruct, + BytesLike, + BigNumberish, + BigNumberish + ] + ): string; + encodeFunctionData( + functionFragment: "mintWithTokenIn", + values: [ + IUniswapV3NonfungiblePositionManager.MintParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + encodeFunctionData( + functionFragment: "pancakeV3SwapCallback", + values: [BigNumberish, BigNumberish, BytesLike] + ): string; + encodeFunctionData( + functionFragment: "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)", + values: [ + IUniswapV3NonfungiblePositionManager.MintParamsStruct, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + values: [ + IUniswapV3NonfungiblePositionManager.MintParamsStruct, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + BytesLike, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "setAllowlistedRouters", + values: [string[], boolean[]] + ): string; + encodeFunctionData( + functionFragment: "setControllers", + values: [string[], boolean[]] + ): string; + encodeFunctionData( + functionFragment: "setFeeConfig", + values: [IAutomanCommon.FeeConfigStruct] + ): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "deployer", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "getOptimalSwap", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidity", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidityOptimal", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidityWithTokenIn", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "isController", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "mint", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "mintOptimal", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "mintWithTokenIn", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "pancakeV3SwapCallback", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setAllowlistedRouters", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setControllers", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setFeeConfig", + data: BytesLike + ): Result; + + events: { + "ControllersSet(address[],bool[])": EventFragment; + "DecreaseLiquidity(uint256)": EventFragment; + "FeeConfigSet(address,uint96)": EventFragment; + "IncreaseLiquidity(uint256)": EventFragment; + "Mint(uint256)": EventFragment; + "Rebalance(uint256)": EventFragment; + "Reinvest(uint256)": EventFragment; + "RemoveLiquidity(uint256)": EventFragment; + "SetAllowlistedRouters(address[],bool[])": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "ControllersSet"): EventFragment; + getEvent(nameOrSignatureOrTopic: "DecreaseLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "FeeConfigSet"): EventFragment; + getEvent(nameOrSignatureOrTopic: "IncreaseLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Mint"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Rebalance"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Reinvest"): EventFragment; + getEvent(nameOrSignatureOrTopic: "RemoveLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "SetAllowlistedRouters"): EventFragment; +} + +export interface ControllersSetEventObject { + controllers: string[]; + statuses: boolean[]; +} +export type ControllersSetEvent = TypedEvent< + [string[], boolean[]], + ControllersSetEventObject +>; + +export type ControllersSetEventFilter = TypedEventFilter; + +export interface DecreaseLiquidityEventObject { + tokenId: BigNumber; +} +export type DecreaseLiquidityEvent = TypedEvent< + [BigNumber], + DecreaseLiquidityEventObject +>; + +export type DecreaseLiquidityEventFilter = + TypedEventFilter; + +export interface FeeConfigSetEventObject { + feeCollector: string; + feeLimitPips: BigNumber; +} +export type FeeConfigSetEvent = TypedEvent< + [string, BigNumber], + FeeConfigSetEventObject +>; + +export type FeeConfigSetEventFilter = TypedEventFilter; + +export interface IncreaseLiquidityEventObject { + tokenId: BigNumber; +} +export type IncreaseLiquidityEvent = TypedEvent< + [BigNumber], + IncreaseLiquidityEventObject +>; + +export type IncreaseLiquidityEventFilter = + TypedEventFilter; + +export interface MintEventObject { + tokenId: BigNumber; +} +export type MintEvent = TypedEvent<[BigNumber], MintEventObject>; + +export type MintEventFilter = TypedEventFilter; + +export interface RebalanceEventObject { + tokenId: BigNumber; +} +export type RebalanceEvent = TypedEvent<[BigNumber], RebalanceEventObject>; + +export type RebalanceEventFilter = TypedEventFilter; + +export interface ReinvestEventObject { + tokenId: BigNumber; +} +export type ReinvestEvent = TypedEvent<[BigNumber], ReinvestEventObject>; + +export type ReinvestEventFilter = TypedEventFilter; + +export interface RemoveLiquidityEventObject { + tokenId: BigNumber; +} +export type RemoveLiquidityEvent = TypedEvent< + [BigNumber], + RemoveLiquidityEventObject +>; + +export type RemoveLiquidityEventFilter = TypedEventFilter; + +export interface SetAllowlistedRoutersEventObject { + routers: string[]; + statuses: boolean[]; +} +export type SetAllowlistedRoutersEvent = TypedEvent< + [string[], boolean[]], + SetAllowlistedRoutersEventObject +>; + +export type SetAllowlistedRoutersEventFilter = + TypedEventFilter; + +export interface IPCSV3Automan extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IPCSV3AutomanInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + deployer(overrides?: CallOverrides): Promise<[string]>; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, boolean, BigNumber] & { + amountIn: BigNumber; + amountOut: BigNumber; + zeroForOne: boolean; + sqrtPriceX96: BigNumber; + } + >; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isController( + addressToCheck: string, + overrides?: CallOverrides + ): Promise<[boolean]>; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise<[string]>; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + deployer(overrides?: CallOverrides): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, boolean, BigNumber] & { + amountIn: BigNumber; + amountOut: BigNumber; + zeroForOne: boolean; + sqrtPriceX96: BigNumber; + } + >; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isController( + addressToCheck: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: CallOverrides + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise; + + deployer(overrides?: CallOverrides): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, boolean, BigNumber] & { + amountIn: BigNumber; + amountOut: BigNumber; + zeroForOne: boolean; + sqrtPriceX96: BigNumber; + } + >; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + isController( + addressToCheck: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + npm(overrides?: CallOverrides): Promise; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + newTokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + newTokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "ControllersSet(address[],bool[])"( + controllers?: null, + statuses?: null + ): ControllersSetEventFilter; + ControllersSet( + controllers?: null, + statuses?: null + ): ControllersSetEventFilter; + + "DecreaseLiquidity(uint256)"( + tokenId?: BigNumberish | null + ): DecreaseLiquidityEventFilter; + DecreaseLiquidity( + tokenId?: BigNumberish | null + ): DecreaseLiquidityEventFilter; + + "FeeConfigSet(address,uint96)"( + feeCollector?: null, + feeLimitPips?: null + ): FeeConfigSetEventFilter; + FeeConfigSet( + feeCollector?: null, + feeLimitPips?: null + ): FeeConfigSetEventFilter; + + "IncreaseLiquidity(uint256)"( + tokenId?: BigNumberish | null + ): IncreaseLiquidityEventFilter; + IncreaseLiquidity( + tokenId?: BigNumberish | null + ): IncreaseLiquidityEventFilter; + + "Mint(uint256)"(tokenId?: BigNumberish | null): MintEventFilter; + Mint(tokenId?: BigNumberish | null): MintEventFilter; + + "Rebalance(uint256)"(tokenId?: BigNumberish | null): RebalanceEventFilter; + Rebalance(tokenId?: BigNumberish | null): RebalanceEventFilter; + + "Reinvest(uint256)"(tokenId?: BigNumberish | null): ReinvestEventFilter; + Reinvest(tokenId?: BigNumberish | null): ReinvestEventFilter; + + "RemoveLiquidity(uint256)"( + tokenId?: BigNumberish | null + ): RemoveLiquidityEventFilter; + RemoveLiquidity(tokenId?: BigNumberish | null): RemoveLiquidityEventFilter; + + "SetAllowlistedRouters(address[],bool[])"( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + SetAllowlistedRouters( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + }; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + deployer(overrides?: CallOverrides): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isController( + addressToCheck: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + deployer(overrides?: CallOverrides): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isController( + addressToCheck: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + pancakeV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/src/interfaces/IAutoman.sol/ISlipStreamAutoman.ts b/src/typechain-typesV4/src/interfaces/IAutoman.sol/ISlipStreamAutoman.ts new file mode 100644 index 00000000..d11f1e20 --- /dev/null +++ b/src/typechain-typesV4/src/interfaces/IAutoman.sol/ISlipStreamAutoman.ts @@ -0,0 +1,1599 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export declare namespace ICommonNonfungiblePositionManager { + export type DecreaseLiquidityParamsStruct = { + tokenId: BigNumberish; + liquidity: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + deadline: BigNumberish; + }; + + export type DecreaseLiquidityParamsStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + deadline: BigNumber; + }; + + export type IncreaseLiquidityParamsStruct = { + tokenId: BigNumberish; + amount0Desired: BigNumberish; + amount1Desired: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + deadline: BigNumberish; + }; + + export type IncreaseLiquidityParamsStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + amount0Desired: BigNumber; + amount1Desired: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + deadline: BigNumber; + }; +} + +export declare namespace ISlipStreamNonfungiblePositionManager { + export type MintParamsStruct = { + token0: string; + token1: string; + tickSpacing: BigNumberish; + tickLower: BigNumberish; + tickUpper: BigNumberish; + amount0Desired: BigNumberish; + amount1Desired: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + recipient: string; + deadline: BigNumberish; + sqrtPriceX96: BigNumberish; + }; + + export type MintParamsStructOutput = [ + string, + string, + number, + number, + number, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + string, + BigNumber, + BigNumber + ] & { + token0: string; + token1: string; + tickSpacing: number; + tickLower: number; + tickUpper: number; + amount0Desired: BigNumber; + amount1Desired: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + recipient: string; + deadline: BigNumber; + sqrtPriceX96: BigNumber; + }; +} + +export declare namespace IAutomanCommon { + export type FeeConfigStruct = { + feeCollector: string; + feeLimitPips: BigNumberish; + }; + + export type FeeConfigStructOutput = [string, BigNumber] & { + feeCollector: string; + feeLimitPips: BigNumber; + }; +} + +export interface ISlipStreamAutomanInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)": FunctionFragment; + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)": FunctionFragment; + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "factory()": FunctionFragment; + "getOptimalSwap(address,int24,int24,uint256,uint256)": FunctionFragment; + "increaseLiquidity((uint256,uint256,uint256,uint256,uint256,uint256))": FunctionFragment; + "increaseLiquidityOptimal((uint256,uint256,uint256,uint256,uint256,uint256),bytes,uint256,uint256)": FunctionFragment; + "increaseLiquidityWithTokenIn((uint256,uint256,uint256,uint256,uint256,uint256),address,uint256,bytes,bytes)": FunctionFragment; + "isController(address)": FunctionFragment; + "mint((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160))": FunctionFragment; + "mintOptimal((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),bytes,uint256,uint256)": FunctionFragment; + "mintWithTokenIn((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),address,uint256,bytes,bytes)": FunctionFragment; + "npm()": FunctionFragment; + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)": FunctionFragment; + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)": FunctionFragment; + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "setAllowlistedRouters(address[],bool[])": FunctionFragment; + "setControllers(address[],bool[])": FunctionFragment; + "setFeeConfig((address,uint96))": FunctionFragment; + "uniswapV3SwapCallback(int256,int256,bytes)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "WETH9" + | "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)" + | "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)" + | "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)" + | "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)" + | "factory" + | "getOptimalSwap" + | "increaseLiquidity" + | "increaseLiquidityOptimal" + | "increaseLiquidityWithTokenIn" + | "isController" + | "mint" + | "mintOptimal" + | "mintWithTokenIn" + | "npm" + | "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)" + | "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)" + | "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)" + | "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)" + | "setAllowlistedRouters" + | "setControllers" + | "setFeeConfig" + | "uniswapV3SwapCallback" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + boolean + ] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + boolean, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike, + boolean + ] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike, + boolean, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData(functionFragment: "factory", values?: undefined): string; + encodeFunctionData( + functionFragment: "getOptimalSwap", + values: [string, BigNumberish, BigNumberish, BigNumberish, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidity", + values: [ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidityOptimal", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + BytesLike, + BigNumberish, + BigNumberish + ] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidityWithTokenIn", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "isController", + values: [string] + ): string; + encodeFunctionData( + functionFragment: "mint", + values: [ISlipStreamNonfungiblePositionManager.MintParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "mintOptimal", + values: [ + ISlipStreamNonfungiblePositionManager.MintParamsStruct, + BytesLike, + BigNumberish, + BigNumberish + ] + ): string; + encodeFunctionData( + functionFragment: "mintWithTokenIn", + values: [ + ISlipStreamNonfungiblePositionManager.MintParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + encodeFunctionData( + functionFragment: "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + values: [ + ISlipStreamNonfungiblePositionManager.MintParamsStruct, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)", + values: [ + ISlipStreamNonfungiblePositionManager.MintParamsStruct, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + BytesLike, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "setAllowlistedRouters", + values: [string[], boolean[]] + ): string; + encodeFunctionData( + functionFragment: "setControllers", + values: [string[], boolean[]] + ): string; + encodeFunctionData( + functionFragment: "setFeeConfig", + values: [IAutomanCommon.FeeConfigStruct] + ): string; + encodeFunctionData( + functionFragment: "uniswapV3SwapCallback", + values: [BigNumberish, BigNumberish, BytesLike] + ): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "factory", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "getOptimalSwap", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidity", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidityOptimal", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidityWithTokenIn", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "isController", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "mint", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "mintOptimal", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "mintWithTokenIn", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setAllowlistedRouters", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setControllers", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setFeeConfig", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "uniswapV3SwapCallback", + data: BytesLike + ): Result; + + events: { + "ControllersSet(address[],bool[])": EventFragment; + "DecreaseLiquidity(uint256)": EventFragment; + "FeeConfigSet(address,uint96)": EventFragment; + "IncreaseLiquidity(uint256)": EventFragment; + "Mint(uint256)": EventFragment; + "Rebalance(uint256)": EventFragment; + "Reinvest(uint256)": EventFragment; + "RemoveLiquidity(uint256)": EventFragment; + "SetAllowlistedRouters(address[],bool[])": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "ControllersSet"): EventFragment; + getEvent(nameOrSignatureOrTopic: "DecreaseLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "FeeConfigSet"): EventFragment; + getEvent(nameOrSignatureOrTopic: "IncreaseLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Mint"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Rebalance"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Reinvest"): EventFragment; + getEvent(nameOrSignatureOrTopic: "RemoveLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "SetAllowlistedRouters"): EventFragment; +} + +export interface ControllersSetEventObject { + controllers: string[]; + statuses: boolean[]; +} +export type ControllersSetEvent = TypedEvent< + [string[], boolean[]], + ControllersSetEventObject +>; + +export type ControllersSetEventFilter = TypedEventFilter; + +export interface DecreaseLiquidityEventObject { + tokenId: BigNumber; +} +export type DecreaseLiquidityEvent = TypedEvent< + [BigNumber], + DecreaseLiquidityEventObject +>; + +export type DecreaseLiquidityEventFilter = + TypedEventFilter; + +export interface FeeConfigSetEventObject { + feeCollector: string; + feeLimitPips: BigNumber; +} +export type FeeConfigSetEvent = TypedEvent< + [string, BigNumber], + FeeConfigSetEventObject +>; + +export type FeeConfigSetEventFilter = TypedEventFilter; + +export interface IncreaseLiquidityEventObject { + tokenId: BigNumber; +} +export type IncreaseLiquidityEvent = TypedEvent< + [BigNumber], + IncreaseLiquidityEventObject +>; + +export type IncreaseLiquidityEventFilter = + TypedEventFilter; + +export interface MintEventObject { + tokenId: BigNumber; +} +export type MintEvent = TypedEvent<[BigNumber], MintEventObject>; + +export type MintEventFilter = TypedEventFilter; + +export interface RebalanceEventObject { + tokenId: BigNumber; +} +export type RebalanceEvent = TypedEvent<[BigNumber], RebalanceEventObject>; + +export type RebalanceEventFilter = TypedEventFilter; + +export interface ReinvestEventObject { + tokenId: BigNumber; +} +export type ReinvestEvent = TypedEvent<[BigNumber], ReinvestEventObject>; + +export type ReinvestEventFilter = TypedEventFilter; + +export interface RemoveLiquidityEventObject { + tokenId: BigNumber; +} +export type RemoveLiquidityEvent = TypedEvent< + [BigNumber], + RemoveLiquidityEventObject +>; + +export type RemoveLiquidityEventFilter = TypedEventFilter; + +export interface SetAllowlistedRoutersEventObject { + routers: string[]; + statuses: boolean[]; +} +export type SetAllowlistedRoutersEvent = TypedEvent< + [string[], boolean[]], + SetAllowlistedRoutersEventObject +>; + +export type SetAllowlistedRoutersEventFilter = + TypedEventFilter; + +export interface ISlipStreamAutoman extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: ISlipStreamAutomanInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise<[string]>; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, boolean, BigNumber] & { + amountIn: BigNumber; + amountOut: BigNumber; + zeroForOne: boolean; + sqrtPriceX96: BigNumber; + } + >; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isController( + addressToCheck: string, + overrides?: CallOverrides + ): Promise<[boolean]>; + + mint( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise<[string]>; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, boolean, BigNumber] & { + amountIn: BigNumber; + amountOut: BigNumber; + zeroForOne: boolean; + sqrtPriceX96: BigNumber; + } + >; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isController( + addressToCheck: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: CallOverrides + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, boolean, BigNumber] & { + amountIn: BigNumber; + amountOut: BigNumber; + zeroForOne: boolean; + sqrtPriceX96: BigNumber; + } + >; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + isController( + addressToCheck: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + mintOptimal( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + mintWithTokenIn( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + npm(overrides?: CallOverrides): Promise; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + newTokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + newTokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: CallOverrides + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "ControllersSet(address[],bool[])"( + controllers?: null, + statuses?: null + ): ControllersSetEventFilter; + ControllersSet( + controllers?: null, + statuses?: null + ): ControllersSetEventFilter; + + "DecreaseLiquidity(uint256)"( + tokenId?: BigNumberish | null + ): DecreaseLiquidityEventFilter; + DecreaseLiquidity( + tokenId?: BigNumberish | null + ): DecreaseLiquidityEventFilter; + + "FeeConfigSet(address,uint96)"( + feeCollector?: null, + feeLimitPips?: null + ): FeeConfigSetEventFilter; + FeeConfigSet( + feeCollector?: null, + feeLimitPips?: null + ): FeeConfigSetEventFilter; + + "IncreaseLiquidity(uint256)"( + tokenId?: BigNumberish | null + ): IncreaseLiquidityEventFilter; + IncreaseLiquidity( + tokenId?: BigNumberish | null + ): IncreaseLiquidityEventFilter; + + "Mint(uint256)"(tokenId?: BigNumberish | null): MintEventFilter; + Mint(tokenId?: BigNumberish | null): MintEventFilter; + + "Rebalance(uint256)"(tokenId?: BigNumberish | null): RebalanceEventFilter; + Rebalance(tokenId?: BigNumberish | null): RebalanceEventFilter; + + "Reinvest(uint256)"(tokenId?: BigNumberish | null): ReinvestEventFilter; + Reinvest(tokenId?: BigNumberish | null): ReinvestEventFilter; + + "RemoveLiquidity(uint256)"( + tokenId?: BigNumberish | null + ): RemoveLiquidityEventFilter; + RemoveLiquidity(tokenId?: BigNumberish | null): RemoveLiquidityEventFilter; + + "SetAllowlistedRouters(address[],bool[])"( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + SetAllowlistedRouters( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + }; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isController( + addressToCheck: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isController( + addressToCheck: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,int24,int24,int24,uint256,uint256,uint256,uint256,address,uint256,uint160),uint256,uint256,uint256,bytes)"( + params: ISlipStreamNonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/src/interfaces/IAutoman.sol/IUniV3Automan.ts b/src/typechain-typesV4/src/interfaces/IAutoman.sol/IUniV3Automan.ts new file mode 100644 index 00000000..cb91b694 --- /dev/null +++ b/src/typechain-typesV4/src/interfaces/IAutoman.sol/IUniV3Automan.ts @@ -0,0 +1,1596 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export declare namespace ICommonNonfungiblePositionManager { + export type DecreaseLiquidityParamsStruct = { + tokenId: BigNumberish; + liquidity: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + deadline: BigNumberish; + }; + + export type DecreaseLiquidityParamsStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + deadline: BigNumber; + }; + + export type IncreaseLiquidityParamsStruct = { + tokenId: BigNumberish; + amount0Desired: BigNumberish; + amount1Desired: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + deadline: BigNumberish; + }; + + export type IncreaseLiquidityParamsStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + tokenId: BigNumber; + amount0Desired: BigNumber; + amount1Desired: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + deadline: BigNumber; + }; +} + +export declare namespace IUniswapV3NonfungiblePositionManager { + export type MintParamsStruct = { + token0: string; + token1: string; + fee: BigNumberish; + tickLower: BigNumberish; + tickUpper: BigNumberish; + amount0Desired: BigNumberish; + amount1Desired: BigNumberish; + amount0Min: BigNumberish; + amount1Min: BigNumberish; + recipient: string; + deadline: BigNumberish; + }; + + export type MintParamsStructOutput = [ + string, + string, + number, + number, + number, + BigNumber, + BigNumber, + BigNumber, + BigNumber, + string, + BigNumber + ] & { + token0: string; + token1: string; + fee: number; + tickLower: number; + tickUpper: number; + amount0Desired: BigNumber; + amount1Desired: BigNumber; + amount0Min: BigNumber; + amount1Min: BigNumber; + recipient: string; + deadline: BigNumber; + }; +} + +export declare namespace IAutomanCommon { + export type FeeConfigStruct = { + feeCollector: string; + feeLimitPips: BigNumberish; + }; + + export type FeeConfigStructOutput = [string, BigNumber] & { + feeCollector: string; + feeLimitPips: BigNumber; + }; +} + +export interface IUniV3AutomanInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)": FunctionFragment; + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)": FunctionFragment; + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "factory()": FunctionFragment; + "getOptimalSwap(address,int24,int24,uint256,uint256)": FunctionFragment; + "increaseLiquidity((uint256,uint256,uint256,uint256,uint256,uint256))": FunctionFragment; + "increaseLiquidityOptimal((uint256,uint256,uint256,uint256,uint256,uint256),bytes,uint256,uint256)": FunctionFragment; + "increaseLiquidityWithTokenIn((uint256,uint256,uint256,uint256,uint256,uint256),address,uint256,bytes,bytes)": FunctionFragment; + "isController(address)": FunctionFragment; + "mint((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256))": FunctionFragment; + "mintOptimal((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),bytes,uint256,uint256)": FunctionFragment; + "mintWithTokenIn((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),address,uint256,bytes,bytes)": FunctionFragment; + "npm()": FunctionFragment; + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)": FunctionFragment; + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)": FunctionFragment; + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)": FunctionFragment; + "setAllowlistedRouters(address[],bool[])": FunctionFragment; + "setControllers(address[],bool[])": FunctionFragment; + "setFeeConfig((address,uint96))": FunctionFragment; + "uniswapV3SwapCallback(int256,int256,bytes)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "WETH9" + | "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)" + | "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)" + | "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)" + | "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)" + | "factory" + | "getOptimalSwap" + | "increaseLiquidity" + | "increaseLiquidityOptimal" + | "increaseLiquidityWithTokenIn" + | "isController" + | "mint" + | "mintOptimal" + | "mintWithTokenIn" + | "npm" + | "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)" + | "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)" + | "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)" + | "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)" + | "setAllowlistedRouters" + | "setControllers" + | "setFeeConfig" + | "uniswapV3SwapCallback" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + boolean + ] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + boolean, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike, + boolean + ] + ): string; + encodeFunctionData( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)", + values: [ + ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike, + boolean, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData(functionFragment: "factory", values?: undefined): string; + encodeFunctionData( + functionFragment: "getOptimalSwap", + values: [string, BigNumberish, BigNumberish, BigNumberish, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidity", + values: [ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidityOptimal", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + BytesLike, + BigNumberish, + BigNumberish + ] + ): string; + encodeFunctionData( + functionFragment: "increaseLiquidityWithTokenIn", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "isController", + values: [string] + ): string; + encodeFunctionData( + functionFragment: "mint", + values: [IUniswapV3NonfungiblePositionManager.MintParamsStruct] + ): string; + encodeFunctionData( + functionFragment: "mintOptimal", + values: [ + IUniswapV3NonfungiblePositionManager.MintParamsStruct, + BytesLike, + BigNumberish, + BigNumberish + ] + ): string; + encodeFunctionData( + functionFragment: "mintWithTokenIn", + values: [ + IUniswapV3NonfungiblePositionManager.MintParamsStruct, + string, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + encodeFunctionData( + functionFragment: "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)", + values: [ + IUniswapV3NonfungiblePositionManager.MintParamsStruct, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + values: [ + IUniswapV3NonfungiblePositionManager.MintParamsStruct, + BigNumberish, + BigNumberish, + BigNumberish, + BytesLike, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + values: [ + ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + BigNumberish, + BigNumberish, + BytesLike, + BigNumberish, + BigNumberish, + BytesLike, + BytesLike + ] + ): string; + encodeFunctionData( + functionFragment: "setAllowlistedRouters", + values: [string[], boolean[]] + ): string; + encodeFunctionData( + functionFragment: "setControllers", + values: [string[], boolean[]] + ): string; + encodeFunctionData( + functionFragment: "setFeeConfig", + values: [IAutomanCommon.FeeConfigStruct] + ): string; + encodeFunctionData( + functionFragment: "uniswapV3SwapCallback", + values: [BigNumberish, BigNumberish, BytesLike] + ): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "factory", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "getOptimalSwap", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidity", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidityOptimal", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "increaseLiquidityWithTokenIn", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "isController", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "mint", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "mintOptimal", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "mintWithTokenIn", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setAllowlistedRouters", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setControllers", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setFeeConfig", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "uniswapV3SwapCallback", + data: BytesLike + ): Result; + + events: { + "ControllersSet(address[],bool[])": EventFragment; + "DecreaseLiquidity(uint256)": EventFragment; + "FeeConfigSet(address,uint96)": EventFragment; + "IncreaseLiquidity(uint256)": EventFragment; + "Mint(uint256)": EventFragment; + "Rebalance(uint256)": EventFragment; + "Reinvest(uint256)": EventFragment; + "RemoveLiquidity(uint256)": EventFragment; + "SetAllowlistedRouters(address[],bool[])": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "ControllersSet"): EventFragment; + getEvent(nameOrSignatureOrTopic: "DecreaseLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "FeeConfigSet"): EventFragment; + getEvent(nameOrSignatureOrTopic: "IncreaseLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Mint"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Rebalance"): EventFragment; + getEvent(nameOrSignatureOrTopic: "Reinvest"): EventFragment; + getEvent(nameOrSignatureOrTopic: "RemoveLiquidity"): EventFragment; + getEvent(nameOrSignatureOrTopic: "SetAllowlistedRouters"): EventFragment; +} + +export interface ControllersSetEventObject { + controllers: string[]; + statuses: boolean[]; +} +export type ControllersSetEvent = TypedEvent< + [string[], boolean[]], + ControllersSetEventObject +>; + +export type ControllersSetEventFilter = TypedEventFilter; + +export interface DecreaseLiquidityEventObject { + tokenId: BigNumber; +} +export type DecreaseLiquidityEvent = TypedEvent< + [BigNumber], + DecreaseLiquidityEventObject +>; + +export type DecreaseLiquidityEventFilter = + TypedEventFilter; + +export interface FeeConfigSetEventObject { + feeCollector: string; + feeLimitPips: BigNumber; +} +export type FeeConfigSetEvent = TypedEvent< + [string, BigNumber], + FeeConfigSetEventObject +>; + +export type FeeConfigSetEventFilter = TypedEventFilter; + +export interface IncreaseLiquidityEventObject { + tokenId: BigNumber; +} +export type IncreaseLiquidityEvent = TypedEvent< + [BigNumber], + IncreaseLiquidityEventObject +>; + +export type IncreaseLiquidityEventFilter = + TypedEventFilter; + +export interface MintEventObject { + tokenId: BigNumber; +} +export type MintEvent = TypedEvent<[BigNumber], MintEventObject>; + +export type MintEventFilter = TypedEventFilter; + +export interface RebalanceEventObject { + tokenId: BigNumber; +} +export type RebalanceEvent = TypedEvent<[BigNumber], RebalanceEventObject>; + +export type RebalanceEventFilter = TypedEventFilter; + +export interface ReinvestEventObject { + tokenId: BigNumber; +} +export type ReinvestEvent = TypedEvent<[BigNumber], ReinvestEventObject>; + +export type ReinvestEventFilter = TypedEventFilter; + +export interface RemoveLiquidityEventObject { + tokenId: BigNumber; +} +export type RemoveLiquidityEvent = TypedEvent< + [BigNumber], + RemoveLiquidityEventObject +>; + +export type RemoveLiquidityEventFilter = TypedEventFilter; + +export interface SetAllowlistedRoutersEventObject { + routers: string[]; + statuses: boolean[]; +} +export type SetAllowlistedRoutersEvent = TypedEvent< + [string[], boolean[]], + SetAllowlistedRoutersEventObject +>; + +export type SetAllowlistedRoutersEventFilter = + TypedEventFilter; + +export interface IUniV3Automan extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IUniV3AutomanInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise<[string]>; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, boolean, BigNumber] & { + amountIn: BigNumber; + amountOut: BigNumber; + zeroForOne: boolean; + sqrtPriceX96: BigNumber; + } + >; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isController( + addressToCheck: string, + overrides?: CallOverrides + ): Promise<[boolean]>; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise<[string]>; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, boolean, BigNumber] & { + amountIn: BigNumber; + amountOut: BigNumber; + zeroForOne: boolean; + sqrtPriceX96: BigNumber; + } + >; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isController( + addressToCheck: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber] & { amount0: BigNumber; amount1: BigNumber } + >; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: CallOverrides + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, boolean, BigNumber] & { + amountIn: BigNumber; + amountOut: BigNumber; + zeroForOne: boolean; + sqrtPriceX96: BigNumber; + } + >; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + isController( + addressToCheck: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + tokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + npm(overrides?: CallOverrides): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + newTokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber, BigNumber] & { + newTokenId: BigNumber; + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: CallOverrides + ): Promise< + [BigNumber, BigNumber, BigNumber] & { + liquidity: BigNumber; + amount0: BigNumber; + amount1: BigNumber; + } + >; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: CallOverrides + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "ControllersSet(address[],bool[])"( + controllers?: null, + statuses?: null + ): ControllersSetEventFilter; + ControllersSet( + controllers?: null, + statuses?: null + ): ControllersSetEventFilter; + + "DecreaseLiquidity(uint256)"( + tokenId?: BigNumberish | null + ): DecreaseLiquidityEventFilter; + DecreaseLiquidity( + tokenId?: BigNumberish | null + ): DecreaseLiquidityEventFilter; + + "FeeConfigSet(address,uint96)"( + feeCollector?: null, + feeLimitPips?: null + ): FeeConfigSetEventFilter; + FeeConfigSet( + feeCollector?: null, + feeLimitPips?: null + ): FeeConfigSetEventFilter; + + "IncreaseLiquidity(uint256)"( + tokenId?: BigNumberish | null + ): IncreaseLiquidityEventFilter; + IncreaseLiquidity( + tokenId?: BigNumberish | null + ): IncreaseLiquidityEventFilter; + + "Mint(uint256)"(tokenId?: BigNumberish | null): MintEventFilter; + Mint(tokenId?: BigNumberish | null): MintEventFilter; + + "Rebalance(uint256)"(tokenId?: BigNumberish | null): RebalanceEventFilter; + Rebalance(tokenId?: BigNumberish | null): RebalanceEventFilter; + + "Reinvest(uint256)"(tokenId?: BigNumberish | null): ReinvestEventFilter; + Reinvest(tokenId?: BigNumberish | null): ReinvestEventFilter; + + "RemoveLiquidity(uint256)"( + tokenId?: BigNumberish | null + ): RemoveLiquidityEventFilter; + RemoveLiquidity(tokenId?: BigNumberish | null): RemoveLiquidityEventFilter; + + "SetAllowlistedRouters(address[],bool[])"( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + SetAllowlistedRouters( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + }; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isController( + addressToCheck: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidity((uint256,uint128,uint256,uint256,uint256),uint256,uint256,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + overrides?: Overrides & { from?: string } + ): Promise; + + "decreaseLiquidityToTokenOut((uint256,uint128,uint256,uint256,uint256),address,uint256,bytes,bytes,bool,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.DecreaseLiquidityParamsStruct, + tokenOut: string, + tokenOutMin: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + isUnwrapNative: boolean, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + factory(overrides?: CallOverrides): Promise; + + getOptimalSwap( + pool: string, + tickLower: BigNumberish, + tickUpper: BigNumberish, + amount0Desired: BigNumberish, + amount1Desired: BigNumberish, + overrides?: CallOverrides + ): Promise; + + increaseLiquidity( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityOptimal( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + increaseLiquidityWithTokenIn( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + isController( + addressToCheck: string, + overrides?: CallOverrides + ): Promise; + + mint( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintOptimal( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + swapData: BytesLike, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + mintWithTokenIn( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenIn: string, + tokenInFeeAmount: BigNumberish, + swapData0: BytesLike, + swapData1: BytesLike, + overrides?: PayableOverrides & { from?: string } + ): Promise; + + npm(overrides?: CallOverrides): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "rebalance((address,address,uint24,int24,int24,uint256,uint256,uint256,uint256,address,uint256),uint256,uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: IUniswapV3NonfungiblePositionManager.MintParamsStruct, + tokenId: BigNumberish, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + "reinvest((uint256,uint256,uint256,uint256,uint256,uint256),uint256,uint256,bytes,uint256,uint8,bytes32,bytes32)"( + params: ICommonNonfungiblePositionManager.IncreaseLiquidityParamsStruct, + token0FeeAmount: BigNumberish, + token1FeeAmount: BigNumberish, + swapData: BytesLike, + permitDeadline: BigNumberish, + v: BigNumberish, + r: BytesLike, + s: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + setControllers( + controllers: string[], + statuses: boolean[], + overrides?: Overrides & { from?: string } + ): Promise; + + setFeeConfig( + _feeConfig: IAutomanCommon.FeeConfigStruct, + overrides?: Overrides & { from?: string } + ): Promise; + + uniswapV3SwapCallback( + amount0Delta: BigNumberish, + amount1Delta: BigNumberish, + data: BytesLike, + overrides?: Overrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/src/interfaces/IAutoman.sol/index.ts b/src/typechain-typesV4/src/interfaces/IAutoman.sol/index.ts new file mode 100644 index 00000000..5331e927 --- /dev/null +++ b/src/typechain-typesV4/src/interfaces/IAutoman.sol/index.ts @@ -0,0 +1,9 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export type { IAutomanCommon } from "./IAutomanCommon"; +export type { IAutomanSlipStreamMintRebalance } from "./IAutomanSlipStreamMintRebalance"; +export type { IAutomanUniV3MintRebalance } from "./IAutomanUniV3MintRebalance"; +export type { IPCSV3Automan } from "./IPCSV3Automan"; +export type { ISlipStreamAutoman } from "./ISlipStreamAutoman"; +export type { IUniV3Automan } from "./IUniV3Automan"; diff --git a/src/typechain-typesV4/src/interfaces/IImmutables.sol/IImmutables.ts b/src/typechain-typesV4/src/interfaces/IImmutables.sol/IImmutables.ts new file mode 100644 index 00000000..74e23595 --- /dev/null +++ b/src/typechain-typesV4/src/interfaces/IImmutables.sol/IImmutables.ts @@ -0,0 +1,94 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BytesLike, + CallOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export interface IImmutablesInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "npm()": FunctionFragment; + }; + + getFunction(nameOrSignatureOrTopic: "WETH9" | "npm"): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + + events: {}; +} + +export interface IImmutables extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IImmutablesInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + npm(overrides?: CallOverrides): Promise<[string]>; + }; + + WETH9(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + }; + + filters: {}; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + }; +} diff --git a/src/typechain-typesV4/src/interfaces/IImmutables.sol/IPCSV3Immutables.ts b/src/typechain-typesV4/src/interfaces/IImmutables.sol/IPCSV3Immutables.ts new file mode 100644 index 00000000..da901023 --- /dev/null +++ b/src/typechain-typesV4/src/interfaces/IImmutables.sol/IPCSV3Immutables.ts @@ -0,0 +1,109 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BytesLike, + CallOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export interface IPCSV3ImmutablesInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "deployer()": FunctionFragment; + "npm()": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: "WETH9" | "deployer" | "npm" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData(functionFragment: "deployer", values?: undefined): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "deployer", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + + events: {}; +} + +export interface IPCSV3Immutables extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IPCSV3ImmutablesInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + deployer(overrides?: CallOverrides): Promise<[string]>; + + npm(overrides?: CallOverrides): Promise<[string]>; + }; + + WETH9(overrides?: CallOverrides): Promise; + + deployer(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + deployer(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + }; + + filters: {}; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + deployer(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + deployer(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + }; +} diff --git a/src/typechain-typesV4/src/interfaces/IImmutables.sol/IUniV3Immutables.ts b/src/typechain-typesV4/src/interfaces/IImmutables.sol/IUniV3Immutables.ts new file mode 100644 index 00000000..c211eb82 --- /dev/null +++ b/src/typechain-typesV4/src/interfaces/IImmutables.sol/IUniV3Immutables.ts @@ -0,0 +1,109 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BytesLike, + CallOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export interface IUniV3ImmutablesInterface extends utils.Interface { + functions: { + "WETH9()": FunctionFragment; + "factory()": FunctionFragment; + "npm()": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: "WETH9" | "factory" | "npm" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "WETH9", values?: undefined): string; + encodeFunctionData(functionFragment: "factory", values?: undefined): string; + encodeFunctionData(functionFragment: "npm", values?: undefined): string; + + decodeFunctionResult(functionFragment: "WETH9", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "factory", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "npm", data: BytesLike): Result; + + events: {}; +} + +export interface IUniV3Immutables extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IUniV3ImmutablesInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + WETH9(overrides?: CallOverrides): Promise<[string]>; + + factory(overrides?: CallOverrides): Promise<[string]>; + + npm(overrides?: CallOverrides): Promise<[string]>; + }; + + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + + callStatic: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + }; + + filters: {}; + + estimateGas: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + }; + + populateTransaction: { + WETH9(overrides?: CallOverrides): Promise; + + factory(overrides?: CallOverrides): Promise; + + npm(overrides?: CallOverrides): Promise; + }; +} diff --git a/src/typechain-typesV4/src/interfaces/IImmutables.sol/index.ts b/src/typechain-typesV4/src/interfaces/IImmutables.sol/index.ts new file mode 100644 index 00000000..c6c3882f --- /dev/null +++ b/src/typechain-typesV4/src/interfaces/IImmutables.sol/index.ts @@ -0,0 +1,6 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export type { IImmutables } from "./IImmutables"; +export type { IPCSV3Immutables } from "./IPCSV3Immutables"; +export type { IUniV3Immutables } from "./IUniV3Immutables"; diff --git a/src/typechain-typesV4/src/interfaces/ISwapRouter.sol/ISwapRouterCommon.ts b/src/typechain-typesV4/src/interfaces/ISwapRouter.sol/ISwapRouterCommon.ts new file mode 100644 index 00000000..fe51763d --- /dev/null +++ b/src/typechain-typesV4/src/interfaces/ISwapRouter.sol/ISwapRouterCommon.ts @@ -0,0 +1,140 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BytesLike, + CallOverrides, + ContractTransaction, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { + FunctionFragment, + Result, + EventFragment, +} from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export interface ISwapRouterCommonInterface extends utils.Interface { + functions: { + "setAllowlistedRouters(address[],bool[])": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: "setAllowlistedRouters" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "setAllowlistedRouters", + values: [string[], boolean[]] + ): string; + + decodeFunctionResult( + functionFragment: "setAllowlistedRouters", + data: BytesLike + ): Result; + + events: { + "SetAllowlistedRouters(address[],bool[])": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "SetAllowlistedRouters"): EventFragment; +} + +export interface SetAllowlistedRoutersEventObject { + routers: string[]; + statuses: boolean[]; +} +export type SetAllowlistedRoutersEvent = TypedEvent< + [string[], boolean[]], + SetAllowlistedRoutersEventObject +>; + +export type SetAllowlistedRoutersEventFilter = + TypedEventFilter; + +export interface ISwapRouterCommon extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: ISwapRouterCommonInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + }; + + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + + callStatic: { + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "SetAllowlistedRouters(address[],bool[])"( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + SetAllowlistedRouters( + routers?: null, + statuses?: null + ): SetAllowlistedRoutersEventFilter; + }; + + estimateGas: { + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + }; + + populateTransaction: { + setAllowlistedRouters( + routers: string[], + statuses: boolean[], + overrides?: PayableOverrides & { from?: string } + ): Promise; + }; +} diff --git a/src/typechain-typesV4/src/interfaces/ISwapRouter.sol/index.ts b/src/typechain-typesV4/src/interfaces/ISwapRouter.sol/index.ts new file mode 100644 index 00000000..48efd08b --- /dev/null +++ b/src/typechain-typesV4/src/interfaces/ISwapRouter.sol/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export type { ISwapRouterCommon } from "./ISwapRouterCommon"; diff --git a/src/typechain-typesV4/src/interfaces/index.ts b/src/typechain-typesV4/src/interfaces/index.ts new file mode 100644 index 00000000..85212cd9 --- /dev/null +++ b/src/typechain-typesV4/src/interfaces/index.ts @@ -0,0 +1,9 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as iAutomanSol from "./IAutoman.sol"; +export type { iAutomanSol }; +import type * as iImmutablesSol from "./IImmutables.sol"; +export type { iImmutablesSol }; +import type * as iSwapRouterSol from "./ISwapRouter.sol"; +export type { iSwapRouterSol }; diff --git a/src/typechain-typesV4/src/libraries/OptimalSwap.ts b/src/typechain-typesV4/src/libraries/OptimalSwap.ts new file mode 100644 index 00000000..58f454d9 --- /dev/null +++ b/src/typechain-typesV4/src/libraries/OptimalSwap.ts @@ -0,0 +1,55 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { BaseContract, Signer, utils } from "ethers"; + +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../common"; + +export interface OptimalSwapInterface extends utils.Interface { + functions: {}; + + events: {}; +} + +export interface OptimalSwap extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: OptimalSwapInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: {}; + + callStatic: {}; + + filters: {}; + + estimateGas: {}; + + populateTransaction: {}; +} diff --git a/src/typechain-typesV4/src/libraries/SlipStreamPoolAddress.sol/ISlipStreamCLFactory.ts b/src/typechain-typesV4/src/libraries/SlipStreamPoolAddress.sol/ISlipStreamCLFactory.ts new file mode 100644 index 00000000..3db4c7eb --- /dev/null +++ b/src/typechain-typesV4/src/libraries/SlipStreamPoolAddress.sol/ISlipStreamCLFactory.ts @@ -0,0 +1,89 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BytesLike, + CallOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, +} from "../../../common"; + +export interface ISlipStreamCLFactoryInterface extends utils.Interface { + functions: { + "poolImplementation()": FunctionFragment; + }; + + getFunction(nameOrSignatureOrTopic: "poolImplementation"): FunctionFragment; + + encodeFunctionData( + functionFragment: "poolImplementation", + values?: undefined + ): string; + + decodeFunctionResult( + functionFragment: "poolImplementation", + data: BytesLike + ): Result; + + events: {}; +} + +export interface ISlipStreamCLFactory extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: ISlipStreamCLFactoryInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + poolImplementation(overrides?: CallOverrides): Promise<[string]>; + }; + + poolImplementation(overrides?: CallOverrides): Promise; + + callStatic: { + poolImplementation(overrides?: CallOverrides): Promise; + }; + + filters: {}; + + estimateGas: { + poolImplementation(overrides?: CallOverrides): Promise; + }; + + populateTransaction: { + poolImplementation( + overrides?: CallOverrides + ): Promise; + }; +} diff --git a/src/typechain-typesV4/src/libraries/SlipStreamPoolAddress.sol/index.ts b/src/typechain-typesV4/src/libraries/SlipStreamPoolAddress.sol/index.ts new file mode 100644 index 00000000..35484b4b --- /dev/null +++ b/src/typechain-typesV4/src/libraries/SlipStreamPoolAddress.sol/index.ts @@ -0,0 +1,4 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export type { ISlipStreamCLFactory } from "./ISlipStreamCLFactory"; diff --git a/src/typechain-typesV4/src/libraries/index.ts b/src/typechain-typesV4/src/libraries/index.ts new file mode 100644 index 00000000..05db33eb --- /dev/null +++ b/src/typechain-typesV4/src/libraries/index.ts @@ -0,0 +1,6 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type * as slipStreamPoolAddressSol from "./SlipStreamPoolAddress.sol"; +export type { slipStreamPoolAddressSol }; +export type { OptimalSwap } from "./OptimalSwap"; diff --git a/src/viem/automan/automan.ts b/src/viem/automan/automan.ts index 9d95d027..db0d7c2b 100644 --- a/src/viem/automan/automan.ts +++ b/src/viem/automan/automan.ts @@ -1,6 +1,6 @@ import { ApertureSupportedChainId, - AutomanV3__factory, + AutomanV4__factory, Automan__factory, getAMMInfo, } from '@/index'; @@ -31,24 +31,25 @@ import { tryRequestWithOverrides, } from '../overrides'; import { - getAutomanIncreaseLiquidityOptimalCallData, - getAutomanMintOptimalCalldata, + getAutomanDecreaseLiquiditySingleCalldata, getAutomanRebalanceCalldata, getAutomanReinvestCalldata, getAutomanRemoveLiquidityCalldata, - getAutomanV3IncreaseLiquidityOptimalCallData, - getAutomanV3MintOptimalCalldata, - getAutomanV3RebalanceCalldata, - getAutomanV3ReinvestCalldata, - getAutomanV3RemoveLiquidityCalldata, + getAutomanV4DecreaseLiquidityCalldata, + getAutomanV4IncreaseLiquidityOptimalCallData, + getAutomanV4MintOptimalCalldata, + getAutomanV4RebalanceCalldata, + getAutomanV4ReinvestCalldata, } from './getAutomanCallData'; import { getFromAddress } from './internal'; import { + DecreaseLiquidityParams, + DecreaseLiquiditySingleReturnType, IncreaseLiquidityParams, IncreaseLiquidityReturnType, MintReturnType, RebalanceReturnType, - ReinvestV3ReturnType, + ReinvestV4ReturnType, RemoveLiquidityReturnType, SlipStreamMintParams, UniV3MintParams, @@ -70,25 +71,24 @@ export function getAutomanContract( }); } -export function getAutomanV3Contract( +export function getAutomanV4Contract( chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, publicClient?: PublicClient, walletClient?: WalletClient, ): GetContractReturnType< - typeof AutomanV3__factory.abi, + typeof AutomanV4__factory.abi, PublicClient | WalletClient > { return getContract({ - address: getAMMInfo(chainId, amm)!.apertureAutomanV3, - abi: AutomanV3__factory.abi, + address: getAMMInfo(chainId, amm)!.apertureAutomanV4, + abi: AutomanV4__factory.abi, client: walletClient ?? publicClient!, }); } export function encodeOptimalSwapData( - chainId: ApertureSupportedChainId, - amm: AutomatedMarketMakerEnum, + from: Address, token0: Address, token1: Address, feeOrTickSpacing: number, @@ -102,7 +102,7 @@ export function encodeOptimalSwapData( return encodePacked( ['address', 'bytes'], [ - getAMMInfo(chainId, amm)!.optimalSwapRouter!, + from, encodePacked( // prettier-ignore ["address", "address", "uint24", "int24", "int24", "bool", "address", "address", "bytes"], @@ -138,37 +138,12 @@ function checkTicks( * @param from The address to simulate the call from. * @param mintParams The mint parameters. * @param swapData The swap data if using a router. + * @param token0FeeAmount The amount of token0 to send to feeCollector. + * @param token1FeeAmount The amount of token1 to send to feeCollector. * @param blockNumber Optional block number to query. * @returns {tokenId, liquidity, amount0, amount1} */ -export async function simulateMintOptimal( - chainId: ApertureSupportedChainId, - amm: AutomatedMarketMakerEnum, - publicClient: PublicClient, - from: Address, - mintParams: UniV3MintParams | SlipStreamMintParams, - swapData: Hex = '0x', - blockNumber?: bigint, -): Promise { - checkTicks(amm, mintParams); - const returnData = await requestMintOptimal( - 'eth_call', - chainId, - amm, - publicClient, - from, - mintParams, - swapData, - blockNumber, - ); - return decodeFunctionResult({ - abi: Automan__factory.abi, - data: returnData, - functionName: 'mintOptimal', - }); -} - -export async function simulateMintOptimalV3( +export async function simulateMintOptimalV4( chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, publicClient: PublicClient, @@ -179,8 +154,7 @@ export async function simulateMintOptimalV3( token1FeeAmount = BigInt(0), blockNumber?: bigint, ): Promise { - checkTicks(amm, mintParams); - const returnData = await requestMintOptimalV3( + const returnData = await requestMintOptimalV4( 'eth_call', chainId, amm, @@ -193,36 +167,13 @@ export async function simulateMintOptimalV3( blockNumber, ); return decodeFunctionResult({ - abi: AutomanV3__factory.abi, + abi: AutomanV4__factory.abi, data: returnData, functionName: 'mintOptimal', }); } -export async function estimateMintOptimalGas( - chainId: ApertureSupportedChainId, - amm: AutomatedMarketMakerEnum, - publicClient: PublicClient, - from: Address, - mintParams: UniV3MintParams | SlipStreamMintParams, - swapData: Hex = '0x', - blockNumber?: bigint, -): Promise { - return hexToBigInt( - await requestMintOptimal( - 'eth_estimateGas', - chainId, - amm, - publicClient, - from, - mintParams, - swapData, - blockNumber, - ), - ); -} - -export async function estimateMintOptimalV3Gas( +export async function estimateMintOptimalV4Gas( chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, publicClient: PublicClient, @@ -234,7 +185,7 @@ export async function estimateMintOptimalV3Gas( blockNumber?: bigint, ): Promise { return hexToBigInt( - await requestMintOptimalV3( + await requestMintOptimalV4( 'eth_estimateGas', chainId, amm, @@ -249,52 +200,7 @@ export async function estimateMintOptimalV3Gas( ); } -export async function requestMintOptimal( - method: M, - chainId: ApertureSupportedChainId, - amm: AutomatedMarketMakerEnum, - publicClient: PublicClient, - from: Address, - mintParams: UniV3MintParams | SlipStreamMintParams, - swapData: Hex = '0x', - blockNumber?: bigint, -): Promise { - checkTicks(amm, mintParams); - const data = getAutomanMintOptimalCalldata(amm, mintParams, swapData); - const { apertureAutoman } = getAMMInfo(chainId, amm)!; - const [token0Overrides, token1Overrides] = await Promise.all([ - getERC20Overrides( - mintParams.token0, - from, - apertureAutoman, - mintParams.amount0Desired, - publicClient, - ), - getERC20Overrides( - mintParams.token1, - from, - apertureAutoman, - mintParams.amount1Desired, - publicClient, - ), - ]); - return tryRequestWithOverrides( - method, - { - from, - to: apertureAutoman, - data, - }, - publicClient, - { - ...token0Overrides, - ...token1Overrides, - }, - blockNumber, - ); -} - -export async function requestMintOptimalV3( +export async function requestMintOptimalV4( method: M, chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, @@ -307,26 +213,26 @@ export async function requestMintOptimalV3( blockNumber?: bigint, ): Promise { checkTicks(amm, mintParams); - const data = getAutomanV3MintOptimalCalldata( + const data = getAutomanV4MintOptimalCalldata( amm, mintParams, swapData, token0FeeAmount, token1FeeAmount, ); - const { apertureAutomanV3 } = getAMMInfo(chainId, amm)!; + const { apertureAutomanV4 } = getAMMInfo(chainId, amm)!; const [token0Overrides, token1Overrides] = await Promise.all([ getERC20Overrides( mintParams.token0, from, - apertureAutomanV3, + apertureAutomanV4, mintParams.amount0Desired, publicClient, ), getERC20Overrides( mintParams.token1, from, - apertureAutomanV3, + apertureAutomanV4, mintParams.amount1Desired, publicClient, ), @@ -335,7 +241,7 @@ export async function requestMintOptimalV3( method, { from, - to: apertureAutomanV3, + to: apertureAutomanV4, data, }, publicClient, @@ -359,35 +265,7 @@ export async function requestMintOptimalV3( * @param blockNumber Optional block number to query. * @returns {tokenId, liquidity, amount0, amount1} */ -export async function simulateIncreaseLiquidityOptimal( - chainId: ApertureSupportedChainId, - amm: AutomatedMarketMakerEnum, - publicClient: PublicClient, - from: Address, - position: Position, - increaseParams: IncreaseLiquidityParams, - swapData: Hex = '0x', - blockNumber?: bigint, -): Promise { - const returnData = await requestIncreaseLiquidityOptimal( - 'eth_call', - chainId, - amm, - publicClient, - from, - position, - increaseParams, - swapData, - blockNumber, - ); - return decodeFunctionResult({ - abi: Automan__factory.abi, - data: returnData, - functionName: 'increaseLiquidityOptimal', - }); -} - -export async function simulateIncreaseLiquidityOptimalV3( +export async function simulateIncreaseLiquidityOptimalV4( chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, publicClient: PublicClient, @@ -399,7 +277,7 @@ export async function simulateIncreaseLiquidityOptimalV3( token1FeeAmount = BigInt(0), blockNumber?: bigint, ): Promise { - const returnData = await requestIncreaseLiquidityOptimalV3( + const returnData = await requestIncreaseLiquidityOptimalV4( 'eth_call', chainId, amm, @@ -413,38 +291,13 @@ export async function simulateIncreaseLiquidityOptimalV3( blockNumber, ); return decodeFunctionResult({ - abi: AutomanV3__factory.abi, + abi: AutomanV4__factory.abi, data: returnData, functionName: 'increaseLiquidityOptimal', }); } -export async function estimateIncreaseLiquidityOptimalGas( - chainId: ApertureSupportedChainId, - amm: AutomatedMarketMakerEnum, - publicClient: PublicClient, - from: Address, - position: Position, - increaseParams: IncreaseLiquidityParams, - swapData: Hex = '0x', - blockNumber?: bigint, -): Promise { - return hexToBigInt( - await requestIncreaseLiquidityOptimal( - 'eth_estimateGas', - chainId, - amm, - publicClient, - from, - position, - increaseParams, - swapData, - blockNumber, - ), - ); -} - -export async function estimateIncreaseLiquidityOptimalV3Gas( +export async function estimateIncreaseLiquidityOptimalV4Gas( chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, publicClient: PublicClient, @@ -457,7 +310,7 @@ export async function estimateIncreaseLiquidityOptimalV3Gas( blockNumber?: bigint, ): Promise { return hexToBigInt( - await requestIncreaseLiquidityOptimalV3( + await requestIncreaseLiquidityOptimalV4( 'eth_estimateGas', chainId, amm, @@ -473,7 +326,7 @@ export async function estimateIncreaseLiquidityOptimalV3Gas( ); } -export async function requestIncreaseLiquidityOptimal< +export async function requestIncreaseLiquidityOptimalV4< M extends keyof RpcReturnType, >( method: M, @@ -484,26 +337,30 @@ export async function requestIncreaseLiquidityOptimal< position: Position, increaseParams: IncreaseLiquidityParams, swapData: Hex = '0x', + token0FeeAmount = BigInt(0), + token1FeeAmount = BigInt(0), blockNumber?: bigint, ): Promise { - const data = getAutomanIncreaseLiquidityOptimalCallData( + const data = getAutomanV4IncreaseLiquidityOptimalCallData( increaseParams, swapData, + token0FeeAmount, + token1FeeAmount, ); - const { apertureAutoman } = getAMMInfo(chainId, amm)!; + const { apertureAutomanV4 } = getAMMInfo(chainId, amm)!; const [token0Overrides, token1Overrides] = await Promise.all([ getERC20Overrides( position.pool.token0.address as Address, from, - apertureAutoman, + apertureAutomanV4, increaseParams.amount0Desired, publicClient, ), getERC20Overrides( position.pool.token1.address as Address, from, - apertureAutoman, + apertureAutomanV4, increaseParams.amount1Desired, publicClient, ), @@ -513,7 +370,7 @@ export async function requestIncreaseLiquidityOptimal< method, { from, - to: apertureAutoman, + to: apertureAutomanV4, data, }, publicClient, @@ -525,64 +382,150 @@ export async function requestIncreaseLiquidityOptimal< ); } -export async function requestIncreaseLiquidityOptimalV3< - M extends keyof RpcReturnType, ->( +export async function requestDecreaseLiquidity( method: M, + chainId: ApertureSupportedChainId, + amm: AutomatedMarketMakerEnum, + publicClient: PublicClient, + from: Address | undefined, + owner: Address, + decreaseLiquidityParams: DecreaseLiquidityParams, + blockNumber?: bigint, +): Promise { + from = getFromAddress(from); + const data = getAutomanV4DecreaseLiquidityCalldata(decreaseLiquidityParams); + const { apertureAutomanV4 } = getAMMInfo(chainId, amm)!; + + return tryRequestWithOverrides( + method, + { + from, + to: apertureAutomanV4, + data, + }, + publicClient, + { + ...getNPMApprovalOverrides(chainId, amm, owner), + }, + blockNumber, + ); +} + +export async function simulateDecreaseLiquiditySingle( chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, publicClient: PublicClient, from: Address, - position: Position, - increaseParams: IncreaseLiquidityParams, + owner: Address, + decreaseLiquidityParams: DecreaseLiquidityParams, + zeroForOne: boolean, + token0FeeAmount: bigint, + token1FeeAmount: bigint, swapData: Hex = '0x', - token0FeeAmount = BigInt(0), - token1FeeAmount = BigInt(0), + isUnwrapNative = true, blockNumber?: bigint, -): Promise { - const data = getAutomanV3IncreaseLiquidityOptimalCallData( - increaseParams, - swapData, +): Promise { + const returnData = await requestDecreaseLiquiditySingle( + 'eth_call', + chainId, + amm, + publicClient, + from, + owner, + decreaseLiquidityParams, + zeroForOne, token0FeeAmount, token1FeeAmount, + swapData, + isUnwrapNative, + blockNumber, ); - const { apertureAutomanV3 } = getAMMInfo(chainId, amm)!; + return decodeFunctionResult({ + abi: AutomanV4__factory.abi, + data: returnData, + functionName: 'decreaseLiquiditySingle', + }); +} - const [token0Overrides, token1Overrides] = await Promise.all([ - getERC20Overrides( - position.pool.token0.address as Address, - from, - apertureAutomanV3, - increaseParams.amount0Desired, +export async function estimateDecreaseLiquiditySingleGas( + chainId: ApertureSupportedChainId, + amm: AutomatedMarketMakerEnum, + publicClient: PublicClient, + from: Address, + owner: Address, + decreaseLiquidityParams: DecreaseLiquidityParams, + zeroForOne: boolean, + token0FeeAmount: bigint, + token1FeeAmount: bigint, + swapData: Hex = '0x', + isUnwrapNative = true, + blockNumber?: bigint, +): Promise { + return hexToBigInt( + await requestDecreaseLiquiditySingle( + 'eth_estimateGas', + chainId, + amm, publicClient, - ), - getERC20Overrides( - position.pool.token1.address as Address, from, - apertureAutomanV3, - increaseParams.amount1Desired, - publicClient, + owner, + decreaseLiquidityParams, + zeroForOne, + token0FeeAmount, + token1FeeAmount, + swapData, + isUnwrapNative, + blockNumber, ), - ]); + ); +} + +export async function requestDecreaseLiquiditySingle< + M extends keyof RpcReturnType, +>( + method: M, + chainId: ApertureSupportedChainId, + amm: AutomatedMarketMakerEnum, + publicClient: PublicClient, + from: Address | undefined, + owner: Address, + decreaseLiquidityParams: DecreaseLiquidityParams, + zeroForOne: boolean, + token0FeeAmount: bigint, + token1FeeAmount: bigint, + swapData: Hex = '0x', + isUnwrapNative = true, + blockNumber?: bigint, +): Promise { + from = getFromAddress(from); + const data = getAutomanDecreaseLiquiditySingleCalldata( + decreaseLiquidityParams, + zeroForOne, + token0FeeAmount, + token1FeeAmount, + swapData, + isUnwrapNative, + ); + const { apertureAutomanV4 } = getAMMInfo(chainId, amm)!; return tryRequestWithOverrides( method, { from, - to: apertureAutomanV3, + to: apertureAutomanV4, data, }, publicClient, { - ...token0Overrides, - ...token1Overrides, + ...getNPMApprovalOverrides(chainId, amm, owner), + ...getControllerOverrides(chainId, amm, from), }, blockNumber, ); } /** - * Simulate a `removeLiquidity` call. + * Simulate a `removeLiquidity` call. Uses AutomanV1 for backend. * @param chainId The chain ID. * @param amm The Automated Market Maker. * @param publicClient Viem public client. @@ -634,7 +577,7 @@ export async function simulateRemoveLiquidity( } /** - * Simulate a `removeLiquidity` call. + * Simulate a `decreaseLiquidity` call. * @param chainId The chain ID. * @param amm The Automated Market Maker. * @param publicClient Viem public client. @@ -647,32 +590,29 @@ export async function simulateRemoveLiquidity( * @param token1FeeAmount The amount of token1 to send to feeCollector. * @param blockNumber Optional block number to query. */ -export async function simulateRemoveLiquidityV3( - chainId: ApertureSupportedChainId, +export async function simulateDecreaseLiquidity( amm: AutomatedMarketMakerEnum, + chainId: ApertureSupportedChainId, publicClient: PublicClient, from: Address, owner: Address, - tokenId: bigint, - amount0Min = BigInt(0), - amount1Min = BigInt(0), + decreaseLiquidityParams: DecreaseLiquidityParams, token0FeeAmount = BigInt(0), token1FeeAmount = BigInt(0), + isUnwrapNative = true, blockNumber?: bigint, customDestContract?: Address, ): Promise { - const data = getAutomanV3RemoveLiquidityCalldata( - tokenId, - BigInt(Math.floor(Date.now() / 1000 + 60 * 30)), - amount0Min, - amount1Min, + const data = getAutomanV4DecreaseLiquidityCalldata( + decreaseLiquidityParams, token0FeeAmount, token1FeeAmount, + isUnwrapNative, ); const destContract = - customDestContract ?? getAMMInfo(chainId, amm)!.apertureAutomanV3; + customDestContract ?? getAMMInfo(chainId, amm)!.apertureAutomanV4; return decodeFunctionResult({ - abi: AutomanV3__factory.abi, + abi: AutomanV4__factory.abi, data: await tryRequestWithOverrides( 'eth_call', { @@ -684,7 +624,7 @@ export async function simulateRemoveLiquidityV3( getNPMApprovalOverrides(chainId, amm, owner), blockNumber, ), - functionName: 'removeLiquidity', + functionName: 'decreaseLiquidity', }); } @@ -728,7 +668,7 @@ export async function requestRebalance( ); } -export async function requestRebalanceV3( +export async function requestRebalanceV4( method: M, chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, @@ -743,14 +683,14 @@ export async function requestRebalanceV3( blockNumber?: bigint, ): Promise { checkTicks(amm, mintParams); - const data = getAutomanV3RebalanceCalldata( + const data = getAutomanV4RebalanceCalldata( amm, mintParams, tokenId, token0FeeAmount, token1FeeAmount, - /* permitInfo= */ undefined, swapData, + /* permitInfo= */ undefined, ); from = getFromAddress(from); const overrides = { @@ -761,7 +701,7 @@ export async function requestRebalanceV3( method, { from, - to: getAMMInfo(chainId, amm)!.apertureAutomanV3, + to: getAMMInfo(chainId, amm)!.apertureAutomanV4, data, }, publicClient, @@ -829,7 +769,7 @@ export async function simulateRebalance( * @param swapData The swap data if using a router. * @param blockNumber Optional block number to query. */ -export async function simulateRebalanceV3( +export async function simulateRebalanceV4( chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, publicClient: PublicClient, @@ -842,7 +782,7 @@ export async function simulateRebalanceV3( swapData: Hex = '0x', blockNumber?: bigint, ): Promise { - const data = await requestRebalanceV3( + const data = await requestRebalanceV4( 'eth_call', chainId, amm, @@ -857,7 +797,7 @@ export async function simulateRebalanceV3( blockNumber, ); return decodeFunctionResult({ - abi: AutomanV3__factory.abi, + abi: AutomanV4__factory.abi, data, functionName: 'rebalance', }); @@ -892,7 +832,7 @@ export async function estimateRebalanceGas( ); } -export async function estimateRebalanceV3Gas( +export async function estimateRebalanceV4Gas( chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, publicClient: PublicClient, @@ -906,7 +846,7 @@ export async function estimateRebalanceV3Gas( blockNumber?: bigint, ): Promise { return hexToBigInt( - await requestRebalanceV3( + await requestRebalanceV4( 'eth_estimateGas', chainId, amm, @@ -959,7 +899,7 @@ export async function requestReinvest( ); } -export async function requestReinvestV3( +export async function requestReinvestV4( method: M, chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, @@ -972,7 +912,7 @@ export async function requestReinvestV3( swapData: Hex = '0x', blockNumber?: bigint, ): Promise { - const data = getAutomanV3ReinvestCalldata( + const data = getAutomanV4ReinvestCalldata( increaseLiquidityParams, token0FeeAmount, token1FeeAmount, @@ -988,7 +928,7 @@ export async function requestReinvestV3( method, { from, - to: getAMMInfo(chainId, amm)!.apertureAutomanV3, + to: getAMMInfo(chainId, amm)!.apertureAutomanV4, data, }, publicClient, @@ -1027,7 +967,7 @@ export async function simulateReinvest( }); } -export async function simulateReinvestV3( +export async function simulateReinvestV4( chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, publicClient: PublicClient, @@ -1038,8 +978,8 @@ export async function simulateReinvestV3( token1FeeAmount = BigInt(0), swapData: Hex = '0x', blockNumber?: bigint, -): Promise { - const data = await requestReinvestV3( +): Promise { + const data = await requestReinvestV4( 'eth_call', chainId, amm, @@ -1053,7 +993,7 @@ export async function simulateReinvestV3( blockNumber, ); return decodeFunctionResult({ - abi: AutomanV3__factory.abi, + abi: AutomanV4__factory.abi, data, functionName: 'reinvest', }); @@ -1086,7 +1026,7 @@ export async function estimateReinvestGas( ); } -export async function estimateReinvestV3Gas( +export async function estimateReinvestV4Gas( chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, publicClient: PublicClient, @@ -1099,7 +1039,7 @@ export async function estimateReinvestV3Gas( blockNumber?: bigint, ): Promise { return hexToBigInt( - await requestReinvestV3( + await requestReinvestV4( 'eth_estimateGas', chainId, amm, diff --git a/src/viem/automan/getAutomanCallData.ts b/src/viem/automan/getAutomanCallData.ts index ce9d7bd1..b59ba129 100644 --- a/src/viem/automan/getAutomanCallData.ts +++ b/src/viem/automan/getAutomanCallData.ts @@ -1,7 +1,7 @@ import { - AutomanV3__factory, + AutomanV4__factory, Automan__factory, - ISlipStreamAutomanV3__factory, + ISlipStreamAutomanV4__factory, ISlipStreamAutoman__factory, PermitInfo, } from '@/index'; @@ -15,26 +15,7 @@ import { UniV3MintParams, } from './types'; -export function getAutomanMintOptimalCalldata( - amm: AutomatedMarketMakerEnum, - mintParams: UniV3MintParams | SlipStreamMintParams, - swapData: Hex = '0x', -): Hex { - if (amm === AutomatedMarketMakerEnum.enum.SLIPSTREAM) { - return encodeFunctionData({ - abi: ISlipStreamAutoman__factory.abi, - args: [mintParams as SlipStreamMintParams, swapData] as const, - functionName: 'mintOptimal', - }); - } - return encodeFunctionData({ - abi: Automan__factory.abi, - args: [mintParams as UniV3MintParams, swapData] as const, - functionName: 'mintOptimal', - }); -} - -export function getAutomanV3MintOptimalCalldata( +export function getAutomanV4MintOptimalCalldata( amm: AutomatedMarketMakerEnum, mintParams: UniV3MintParams | SlipStreamMintParams, swapData: Hex = '0x', @@ -43,7 +24,7 @@ export function getAutomanV3MintOptimalCalldata( ): Hex { if (amm === AutomatedMarketMakerEnum.enum.SLIPSTREAM) { return encodeFunctionData({ - abi: ISlipStreamAutomanV3__factory.abi, + abi: ISlipStreamAutomanV4__factory.abi, args: [ mintParams as SlipStreamMintParams, swapData, @@ -54,7 +35,7 @@ export function getAutomanV3MintOptimalCalldata( }); } return encodeFunctionData({ - abi: AutomanV3__factory.abi, + abi: AutomanV4__factory.abi, args: [ mintParams as UniV3MintParams, swapData, @@ -65,50 +46,29 @@ export function getAutomanV3MintOptimalCalldata( }); } -export function getAutomanIncreaseLiquidityOptimalCallData( - increaseParams: IncreaseLiquidityParams, - swapData: Hex = '0x', -): Hex { - return encodeFunctionData({ - abi: Automan__factory.abi, - args: [increaseParams, swapData] as const, - functionName: 'increaseLiquidityOptimal', - }); -} - -export function getAutomanV3IncreaseLiquidityOptimalCallData( +export function getAutomanV4IncreaseLiquidityOptimalCallData( increaseParams: IncreaseLiquidityParams, swapData: Hex = '0x', token0FeeAmount = BigInt(0), token1FeeAmount = BigInt(0), ): Hex { return encodeFunctionData({ - abi: AutomanV3__factory.abi, + abi: AutomanV4__factory.abi, args: [increaseParams, swapData, token0FeeAmount, token1FeeAmount] as const, functionName: 'increaseLiquidityOptimal', }); } +// Still used by backend for Prescheduled Position Close export function getAutomanDecreaseLiquidityCalldata( - tokenId: bigint, - liquidity: bigint, - deadline: bigint, - amount0Min = BigInt(0), - amount1Min = BigInt(0), + decreaseLiquidityParams: DecreaseLiquidityParams, feeBips = BigInt(0), permitInfo?: PermitInfo, ): Hex { - const params: DecreaseLiquidityParams = { - tokenId, - liquidity, - amount0Min, - amount1Min, - deadline, - }; if (permitInfo === undefined) { return encodeFunctionData({ abi: Automan__factory.abi, - args: [params, feeBips] as const, + args: [decreaseLiquidityParams, feeBips] as const, functionName: 'decreaseLiquidity', }); } @@ -116,7 +76,7 @@ export function getAutomanDecreaseLiquidityCalldata( return encodeFunctionData({ abi: Automan__factory.abi, args: [ - params, + decreaseLiquidityParams, feeBips, BigInt(permitInfo.deadline), Number(v), @@ -127,37 +87,33 @@ export function getAutomanDecreaseLiquidityCalldata( }); } -export function getAutomanV3DecreaseLiquidityCalldata( - tokenId: bigint, - liquidity: bigint, - deadline: bigint, - amount0Min = BigInt(0), - amount1Min = BigInt(0), +export function getAutomanV4DecreaseLiquidityCalldata( + decreaseLiquidityParams: DecreaseLiquidityParams, token0FeeAmount = BigInt(0), token1FeeAmount = BigInt(0), + isUnwrapNative = true, permitInfo?: PermitInfo, ): Hex { - const params: DecreaseLiquidityParams = { - tokenId, - liquidity, - amount0Min, - amount1Min, - deadline, - }; if (permitInfo === undefined) { return encodeFunctionData({ - abi: AutomanV3__factory.abi, - args: [params, token0FeeAmount, token1FeeAmount] as const, + abi: AutomanV4__factory.abi, + args: [ + decreaseLiquidityParams, + token0FeeAmount, + token1FeeAmount, + isUnwrapNative, + ] as const, functionName: 'decreaseLiquidity', }); } const { v, r, s } = hexToSignature(permitInfo.signature as Hex); return encodeFunctionData({ - abi: AutomanV3__factory.abi, + abi: AutomanV4__factory.abi, args: [ - params, + decreaseLiquidityParams, token0FeeAmount, token1FeeAmount, + isUnwrapNative, BigInt(permitInfo.deadline), Number(v), r, @@ -167,6 +123,48 @@ export function getAutomanV3DecreaseLiquidityCalldata( }); } +export function getAutomanDecreaseLiquiditySingleCalldata( + decreaseLiquidityParams: DecreaseLiquidityParams, + zeroForOne: boolean, + token0FeeAmount: bigint, + token1FeeAmount: bigint, + swapData: Hex = '0x', + isUnwrapNative = true, + permitInfo?: PermitInfo, +): Hex { + if (permitInfo === undefined) { + return encodeFunctionData({ + abi: AutomanV4__factory.abi, + args: [ + decreaseLiquidityParams, + zeroForOne, + token0FeeAmount, + token1FeeAmount, + swapData, + isUnwrapNative, + ] as const, + functionName: 'decreaseLiquiditySingle', + }); + } + const { v, r, s } = hexToSignature(permitInfo.signature as Hex); + return encodeFunctionData({ + abi: AutomanV4__factory.abi, + args: [ + decreaseLiquidityParams, + zeroForOne, + token0FeeAmount, + token1FeeAmount, + swapData, + isUnwrapNative, + BigInt(permitInfo.deadline), + Number(v), + r, + s, + ] as const, + functionName: 'decreaseLiquiditySingle', + }); +} + export function getAutomanRebalanceCalldata( amm: AutomatedMarketMakerEnum, mintParams: UniV3MintParams | SlipStreamMintParams, @@ -232,19 +230,19 @@ export function getAutomanRebalanceCalldata( }); } -export function getAutomanV3RebalanceCalldata( +export function getAutomanV4RebalanceCalldata( amm: AutomatedMarketMakerEnum, mintParams: UniV3MintParams | SlipStreamMintParams, tokenId: bigint, token0FeeAmount = BigInt(0), token1FeeAmount = BigInt(0), - permitInfo?: PermitInfo, swapData: Hex = '0x', + permitInfo?: PermitInfo, ): Hex { if (permitInfo === undefined) { if (amm === AutomatedMarketMakerEnum.enum.SLIPSTREAM) { return encodeFunctionData({ - abi: ISlipStreamAutomanV3__factory.abi, + abi: ISlipStreamAutomanV4__factory.abi, args: [ mintParams as SlipStreamMintParams, tokenId, @@ -256,7 +254,7 @@ export function getAutomanV3RebalanceCalldata( }); } return encodeFunctionData({ - abi: AutomanV3__factory.abi, + abi: AutomanV4__factory.abi, args: [ mintParams as UniV3MintParams, tokenId, @@ -270,7 +268,7 @@ export function getAutomanV3RebalanceCalldata( const { v, r, s } = hexToSignature(permitInfo.signature as Hex); if (amm === AutomatedMarketMakerEnum.enum.SLIPSTREAM) { return encodeFunctionData({ - abi: ISlipStreamAutomanV3__factory.abi, + abi: ISlipStreamAutomanV4__factory.abi, args: [ mintParams as SlipStreamMintParams, tokenId, @@ -286,7 +284,7 @@ export function getAutomanV3RebalanceCalldata( }); } return encodeFunctionData({ - abi: AutomanV3__factory.abi, + abi: AutomanV4__factory.abi, args: [ mintParams as UniV3MintParams, tokenId, @@ -331,7 +329,7 @@ export function getAutomanReinvestCalldata( }); } -export function getAutomanV3ReinvestCalldata( +export function getAutomanV4ReinvestCalldata( increaseLiquidityParams: IncreaseLiquidityParams, token0FeeAmount = BigInt(0), token1FeeAmount = BigInt(0), @@ -340,7 +338,7 @@ export function getAutomanV3ReinvestCalldata( ): Hex { if (permitInfo === undefined) { return encodeFunctionData({ - abi: AutomanV3__factory.abi, + abi: AutomanV4__factory.abi, args: [ increaseLiquidityParams, token0FeeAmount, @@ -352,7 +350,7 @@ export function getAutomanV3ReinvestCalldata( } const { v, r, s } = hexToSignature(permitInfo.signature as Hex); return encodeFunctionData({ - abi: AutomanV3__factory.abi, + abi: AutomanV4__factory.abi, args: [ increaseLiquidityParams, token0FeeAmount, @@ -367,6 +365,7 @@ export function getAutomanV3ReinvestCalldata( }); } +// Uses AutomanV1 for backend. export function getAutomanRemoveLiquidityCalldata( tokenId: bigint, deadline: bigint, @@ -403,42 +402,3 @@ export function getAutomanRemoveLiquidityCalldata( functionName: 'removeLiquidity', }); } - -export function getAutomanV3RemoveLiquidityCalldata( - tokenId: bigint, - deadline: bigint, - amount0Min = BigInt(0), - amount1Min = BigInt(0), - token0FeeAmount = BigInt(0), - token1FeeAmount = BigInt(0), - permitInfo?: PermitInfo, -): Hex { - const params: DecreaseLiquidityParams = { - tokenId, - liquidity: BigInt(0), // Param value ignored by Automan. - amount0Min, - amount1Min, - deadline, - }; - if (permitInfo === undefined) { - return encodeFunctionData({ - abi: AutomanV3__factory.abi, - args: [params, token0FeeAmount, token1FeeAmount] as const, - functionName: 'removeLiquidity', - }); - } - const { v, r, s } = hexToSignature(permitInfo.signature as Hex); - return encodeFunctionData({ - abi: AutomanV3__factory.abi, - args: [ - params, - token0FeeAmount, - token1FeeAmount, - BigInt(permitInfo.deadline), - Number(v), - r, - s, - ] as const, - functionName: 'removeLiquidity', - }); -} diff --git a/src/viem/automan/getDecreaseLiquiditySingleSwapInfo.ts b/src/viem/automan/getDecreaseLiquiditySingleSwapInfo.ts new file mode 100644 index 00000000..4feebd18 --- /dev/null +++ b/src/viem/automan/getDecreaseLiquiditySingleSwapInfo.ts @@ -0,0 +1,59 @@ +import { ApertureSupportedChainId } from '@/index'; +import { RemoveLiquidityOptions } from '@aperture_finance/uniswap-v3-sdk'; +import { AutomatedMarketMakerEnum } from 'aperture-lens/dist/src/viem'; +import { Address, PublicClient } from 'viem'; + +import { PositionDetails } from '../position'; +import { SolverResult, decreaseLiquiditySingle } from '../solver'; +import { E_Solver } from '../solver'; + +/** + * calculates the optimal swap information including swap path info, swap route and price impact for adding liquidity in a decentralized exchange + * @param removeLiquidityOptions Decrease liquidity options. + * @param chainId The chain ID. + * @param amm The Automated Market Maker. + * @param zeroForOne If true, collect in token1. If false, collect in token0. + * @param recipient The recipient address. + * @param tokenPricesUsd The prices of the two tokens in the pool in usd. + * @param publicClient Viem public client. + * @param includeSolvers Optional. The solvers to include in the quote. If not provided, all solvers will be included. + * @param positionDetails Uniswap SDK PositionDetails for the specified position (optional); if undefined, one will be created. + * @param blockNumber Optional. The block number to simulate the call from. + */ +export async function getDecreaseLiquiditySingleSwapInfo( + removeLiquidityOptions: RemoveLiquidityOptions, + chainId: ApertureSupportedChainId, + amm: AutomatedMarketMakerEnum, + zeroForOne: boolean, + recipient: Address, + tokenPricesUsd: [string, string], + publicClient: PublicClient, + isUnwrapNative = true, + includeSolvers?: E_Solver[], + positionDetails?: PositionDetails, + blockNumber?: bigint, +): Promise { + if (positionDetails === undefined) { + positionDetails = await PositionDetails.fromPositionId( + chainId, + amm, + BigInt(removeLiquidityOptions.tokenId.toString()), + publicClient, + blockNumber, + ); + } + + return await decreaseLiquiditySingle( + chainId, + amm, + publicClient, + positionDetails, + removeLiquidityOptions, + zeroForOne, + recipient, + tokenPricesUsd, + isUnwrapNative, + blockNumber, + includeSolvers, + ); +} diff --git a/src/viem/automan/getIncreaseLiquidityOptimalSwapInfo.ts b/src/viem/automan/getIncreaseLiquidityOptimalSwapInfo.ts index 13681235..396b01f6 100644 --- a/src/viem/automan/getIncreaseLiquidityOptimalSwapInfo.ts +++ b/src/viem/automan/getIncreaseLiquidityOptimalSwapInfo.ts @@ -5,10 +5,7 @@ import { AutomatedMarketMakerEnum } from 'aperture-lens/dist/src/viem'; import { Address, PublicClient } from 'viem'; import { PositionDetails } from '../position'; -import { - increaseLiquidityOptimalV2, - increaseLiquidityOptimalV3, -} from '../solver'; +import { increaseLiquidityOptimalV4 } from '../solver'; import { E_Solver } from '../solver'; /** @@ -19,46 +16,13 @@ import { E_Solver } from '../solver'; * @param token0Amount The token0 amount. * @param token1Amount The token1 amount. * @param fromAddress The address to increase liquidity from. + * @param tokenPricesUsd The token prices in USD. * @param publicClient Viem public client. + * @param includeSolvers Optional. The solvers to include. * @param position The current position to simulate the call from. * @param blockNumber Optional. The block number to simulate the call from. */ -export async function getIncreaseLiquidityOptimalSwapInfo( - increaseOptions: IncreaseOptions, - chainId: ApertureSupportedChainId, - amm: AutomatedMarketMakerEnum, - token0Amount: CurrencyAmount, - token1Amount: CurrencyAmount, - fromAddress: Address, - publicClient: PublicClient, - includeSolvers?: E_Solver[], - position?: Position, - blockNumber?: bigint, -) { - if (position === undefined) { - ({ position } = await PositionDetails.fromPositionId( - chainId, - amm, - BigInt(increaseOptions.tokenId.toString()), - publicClient, - )); - } - - return await increaseLiquidityOptimalV2( - chainId, - amm, - publicClient, - position, - increaseOptions, - token0Amount as CurrencyAmount, - token1Amount as CurrencyAmount, - fromAddress, - blockNumber, - includeSolvers, - ); -} - -export async function getIncreaseLiquidityOptimalSwapInfoV3( +export async function getIncreaseLiquidityOptimalSwapInfoV4( increaseOptions: IncreaseOptions, chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, @@ -80,7 +44,7 @@ export async function getIncreaseLiquidityOptimalSwapInfoV3( )); } - return await increaseLiquidityOptimalV3( + return await increaseLiquidityOptimalV4( chainId, amm, publicClient, @@ -90,7 +54,7 @@ export async function getIncreaseLiquidityOptimalSwapInfoV3( token1Amount as CurrencyAmount, fromAddress, tokenPricesUsd, - blockNumber, includeSolvers, + blockNumber, ); } diff --git a/src/viem/automan/getMintOptimalSwapInfo.ts b/src/viem/automan/getMintOptimalSwapInfo.ts index 0a1fd84a..27cb3048 100644 --- a/src/viem/automan/getMintOptimalSwapInfo.ts +++ b/src/viem/automan/getMintOptimalSwapInfo.ts @@ -1,5 +1,5 @@ import { ApertureSupportedChainId } from '@/index'; -import { E_Solver, mintOptimalV2, mintOptimalV3 } from '@/viem'; +import { E_Solver, mintOptimalV4 } from '@/viem'; import { Currency, CurrencyAmount, Token } from '@uniswap/sdk-core'; import { AutomatedMarketMakerEnum } from 'aperture-lens/dist/src/viem'; import { Address, PublicClient } from 'viem'; @@ -15,40 +15,12 @@ import { Address, PublicClient } from 'viem'; * @param tickUpper The upper tick of the range. * @param recipient The recipient address. * @param slippage The slippage tolerance. + * @param tokenPricesUsd The token prices in USD. * @param publicClient Viem public client. + * @param includeSolvers Optional. The solvers to include. * @param blockNumber Optional. The block number to simulate the call from. */ -export async function getMintOptimalSwapInfo( - chainId: ApertureSupportedChainId, - amm: AutomatedMarketMakerEnum, - token0Amount: CurrencyAmount, - token1Amount: CurrencyAmount, - feeOrTickSpacing: number, - tickLower: number, - tickUpper: number, - fromAddress: Address, - slippage: number, - publicClient: PublicClient, - includeSolvers?: E_Solver[], - blockNumber?: bigint, -) { - return mintOptimalV2( - chainId, - amm, - token0Amount as CurrencyAmount, - token1Amount as CurrencyAmount, - feeOrTickSpacing, - tickLower, - tickUpper, - fromAddress, - slippage, - publicClient, - blockNumber, - includeSolvers, - ); -} - -export async function getMintOptimalSwapInfoV3( +export async function getMintOptimalSwapInfoV4( chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, token0Amount: CurrencyAmount, @@ -63,7 +35,7 @@ export async function getMintOptimalSwapInfoV3( includeSolvers?: E_Solver[], blockNumber?: bigint, ) { - return mintOptimalV3( + return mintOptimalV4( chainId, amm, token0Amount as CurrencyAmount, diff --git a/src/viem/automan/getRebalanceSwapInfo.ts b/src/viem/automan/getRebalanceSwapInfo.ts index 0481b7f3..23b25be6 100644 --- a/src/viem/automan/getRebalanceSwapInfo.ts +++ b/src/viem/automan/getRebalanceSwapInfo.ts @@ -5,13 +5,14 @@ import { SolverResult, rebalanceBackend, rebalanceOptimalV2, - rebalanceV3, + rebalanceV4, } from '@/viem'; import { AutomatedMarketMakerEnum } from 'aperture-lens/dist/src/viem'; import { Address, PublicClient } from 'viem'; /** - * calculates the optimal swap information including swap path info, swap route and price impact for rebalances an existing position into a new one with the specified price range using Aperture's Automan contract. + * Calculates the optimal swap information including swap path info, swap route and price impact for rebalances an existing position into a new one with the specified price range using Aperture's Automan contract. + * Currently used for frontend, and can optionally be migrated to getRebalanceSwapInfoV4. * @param chainId Chain id. * @param amm Automated Market Maker. * @param fromAddress The address to rebalance from. @@ -68,6 +69,7 @@ export async function getRebalanceSwapInfo( /** * Calculates the SolverResults for rebalances from an existing position into a new one with the specified price range using Aperture's Automan contract. + * Used for backend with 2x solver calls for gas reimbursements. * @param chainId Chain id. * @param amm Automated Market Maker. * @param fromAddress The address to rebalance from. @@ -112,8 +114,8 @@ export async function getRebalanceSwapInfoBackend( } // Same as getRebalanceSwapInfo, except return the fees as token0FeeAmount and token1FeeAmount instead of feeBips -// Do not use, but implemented to make it easier to migrate to future versions. -export async function getRebalanceSwapInfoV3( +// Frontend don't have to use, but implemented to make it easier to migrate to future versions. +export async function getRebalanceSwapInfoV4( chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, publicClient: PublicClient, @@ -126,7 +128,7 @@ export async function getRebalanceSwapInfoV3( includeSolvers?: E_Solver[], blockNumber?: bigint, ): Promise { - return rebalanceV3( + return rebalanceV4( chainId, amm, publicClient, diff --git a/src/viem/automan/getReinvestSwapInfo.ts b/src/viem/automan/getReinvestSwapInfo.ts index 749bc440..aa465e08 100644 --- a/src/viem/automan/getReinvestSwapInfo.ts +++ b/src/viem/automan/getReinvestSwapInfo.ts @@ -4,7 +4,7 @@ import { PositionDetails, SolverResult, reinvestBackend, - reinvestV3, + reinvestV4, } from '@/viem'; import { IncreaseOptions } from '@aperture_finance/uniswap-v3-sdk'; import { AutomatedMarketMakerEnum } from 'aperture-lens/dist/src/viem'; @@ -63,7 +63,7 @@ export async function getReinvestSwapInfoBackend( * @param includeSolvers Optional. The solvers to include in the quote. If not provided, all solvers will be included. * @param blockNumber Optional. The block number to simulate the call from. */ -export async function getReinvestSwapInfoV3( +export async function getReinvestSwapInfoV4( chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, publicClient: PublicClient, @@ -84,7 +84,7 @@ export async function getReinvestSwapInfoV3( ); } - return reinvestV3( + return reinvestV4( chainId, amm, publicClient, diff --git a/src/viem/automan/index.ts b/src/viem/automan/index.ts index dec6cff0..0790bc0c 100644 --- a/src/viem/automan/index.ts +++ b/src/viem/automan/index.ts @@ -1,4 +1,5 @@ export * from './automan'; +export * from './getDecreaseLiquiditySingleSwapInfo'; export * from './getIncreaseLiquidityOptimalSwapInfo'; export * from './getFees'; export * from './getMintOptimalSwapInfo'; diff --git a/src/viem/automan/types.ts b/src/viem/automan/types.ts index e7c3d2b2..f5ac9f0f 100644 --- a/src/viem/automan/types.ts +++ b/src/viem/automan/types.ts @@ -1,5 +1,5 @@ import { - AutomanV3__factory, + AutomanV4__factory, Automan__factory, ICommonNonfungiblePositionManager__factory, ISlipStreamNonfungiblePositionManager__factory, @@ -18,14 +18,24 @@ export type AutomanActionName = | 'mintOptimal' | 'increaseLiquidityOptimal' | 'decreaseLiquidity' + | 'decreaseLiquiditySingle' | 'reinvest' | 'rebalance' | 'removeLiquidity'; +export type AutomanV4ActionName = + | 'mintOptimal' + | 'increaseLiquidityOptimal' + | 'decreaseLiquidity' + | 'decreaseLiquiditySingle' + | 'reinvest' + | 'rebalance'; +// removeLiquidity is deprecated in AutomanV4 + export type GetAutomanParams = GetAbiFunctionParamsTypes; -export type GetAutomanV3Params = - GetAbiFunctionParamsTypes; +export type GetAutomanV4Params = + GetAbiFunctionParamsTypes; export type GetAutomanReturnTypes< functionName extends AutomanActionName, @@ -45,19 +55,19 @@ export type GetAutomanReturnTypes< args // to dedup function name >; -export type GetAutomanV3ReturnTypes< - functionName extends AutomanActionName, +export type GetAutomanV4ReturnTypes< + functionName extends AutomanV4ActionName, args extends ContractFunctionArgs< - typeof AutomanV3__factory.abi, + typeof AutomanV4__factory.abi, AbiStateMutability, functionName > = ContractFunctionArgs< - typeof AutomanV3__factory.abi, + typeof AutomanV4__factory.abi, AbiStateMutability, functionName >, > = ContractFunctionReturnType< - typeof AutomanV3__factory.abi, + typeof AutomanV4__factory.abi, AbiStateMutability, functionName, args // to dedup function name @@ -87,7 +97,7 @@ export type ReinvestReturnType = GetAutomanReturnTypes< 'reinvest', [IncreaseLiquidityParams, bigint, Hex] >; -export type ReinvestV3ReturnType = GetAutomanV3ReturnTypes< +export type ReinvestV4ReturnType = GetAutomanV4ReturnTypes< 'reinvest', [IncreaseLiquidityParams, bigint, bigint, Hex] >; @@ -106,3 +116,13 @@ export type DecreaseLiquidityParams = GetAbiFunctionParamsTypes< typeof ICommonNonfungiblePositionManager__factory.abi, 'decreaseLiquidity' >[0]; + +export type DecreaseLiquidityReturnType = GetAutomanV4ReturnTypes< + 'decreaseLiquidity', + [DecreaseLiquidityParams, bigint, bigint, boolean] +>; + +export type DecreaseLiquiditySingleReturnType = GetAutomanV4ReturnTypes< + 'decreaseLiquiditySingle', + [DecreaseLiquidityParams, boolean, bigint, bigint, Hex, boolean] +>; diff --git a/src/viem/overrides.ts b/src/viem/overrides.ts index b8fb866c..c01bd278 100644 --- a/src/viem/overrides.ts +++ b/src/viem/overrides.ts @@ -71,15 +71,15 @@ export function getNPMApprovalOverrides( amm: AutomatedMarketMakerEnum, owner: Address, ): StateOverrides { - const { apertureAutoman, nonfungiblePositionManager } = getAMMInfo( - chainId, - amm, - )!; + const { apertureAutoman, apertureAutomanV4, nonfungiblePositionManager } = + getAMMInfo(chainId, amm)!; return { [nonfungiblePositionManager]: { stateDiff: { [computeOperatorApprovalSlot(owner, apertureAutoman)]: encodeAbiParameters(parseAbiParameters('bool'), [true]), + [computeOperatorApprovalSlot(owner, apertureAutomanV4)]: + encodeAbiParameters(parseAbiParameters('bool'), [true]), }, }, }; @@ -90,8 +90,17 @@ export function getControllerOverrides( amm: AutomatedMarketMakerEnum, from: Address, ) { + const { apertureAutoman, apertureAutomanV4 } = getAMMInfo(chainId, amm)!; return { - [getAMMInfo(chainId, amm)!.apertureAutoman]: { + [apertureAutoman]: { + stateDiff: { + [computeIsControllerSlot(from)]: encodeAbiParameters( + parseAbiParameters('bool'), + [true], + ), + }, + }, + [apertureAutomanV4]: { stateDiff: { [computeIsControllerSlot(from)]: encodeAbiParameters( parseAbiParameters('bool'), @@ -107,8 +116,19 @@ export function getAutomanWhitelistOverrides( amm: AutomatedMarketMakerEnum, routerToWhitelist: Address, ): StateOverrides { + const { apertureAutoman, apertureAutomanV4 } = getAMMInfo(chainId, amm)!; return { - [getAMMInfo(chainId, amm)!.apertureAutoman]: { + [apertureAutoman]: { + stateDiff: { + [keccak256( + encodeAbiParameters(parseAbiParameters('address, bytes32'), [ + routerToWhitelist, + encodeAbiParameters(parseAbiParameters('uint256'), [3n]), + ]), + )]: encodeAbiParameters(parseAbiParameters('bool'), [true]), + }, + }, + [apertureAutomanV4]: { stateDiff: { [keccak256( encodeAbiParameters(parseAbiParameters('address, bytes32'), [ diff --git a/src/viem/permission.ts b/src/viem/permission.ts index 9e27c9d9..561eccc9 100644 --- a/src/viem/permission.ts +++ b/src/viem/permission.ts @@ -177,11 +177,10 @@ export async function generateTypedDataForPermit( positionId: bigint, deadlineEpochSeconds: bigint, publicClient?: PublicClient, + isLatestAutoman = false, ): Promise> { - const { apertureAutoman, nonfungiblePositionManager } = getAMMInfo( - chainId, - amm, - )!; + const { apertureAutoman, apertureAutomanV4, nonfungiblePositionManager } = + getAMMInfo(chainId, amm)!; const nonce = ( await getNPM(chainId, amm, publicClient).read.positions([positionId]) )[0]; @@ -204,7 +203,7 @@ export async function generateTypedDataForPermit( types: PermitTypes, primaryType: 'Permit', message: { - spender: apertureAutoman, + spender: isLatestAutoman ? apertureAutomanV4 : apertureAutoman, tokenId: positionId, nonce, deadline: deadlineEpochSeconds, diff --git a/src/viem/solver/decreaseLiquiditySingle.ts b/src/viem/solver/decreaseLiquiditySingle.ts new file mode 100644 index 00000000..ec2deaac --- /dev/null +++ b/src/viem/solver/decreaseLiquiditySingle.ts @@ -0,0 +1,253 @@ +import { ApertureSupportedChainId, getLogger } from '@/index'; +import { RemoveLiquidityOptions } from '@aperture_finance/uniswap-v3-sdk'; +import { AutomatedMarketMakerEnum } from 'aperture-lens/dist/src/viem'; +import Big from 'big.js'; +import { Address, Hex, PublicClient } from 'viem'; + +import { DEFAULT_SOLVERS, E_Solver, SwapRoute, getSolver } from '.'; +import { + DecreaseLiquidityParams, + FEE_ZAP_RATIO, + estimateDecreaseLiquiditySingleGas, + simulateDecreaseLiquidity, + simulateDecreaseLiquiditySingle, +} from '../automan'; +import { PositionDetails } from '../position'; +import { + buildOptimalSolutions, + calcPriceImpact, + getSwapPath, + getSwapRoute, +} from './internal'; +import { SolverResult } from './types'; + +/** + * Get the optimal amount of liquidity to decrease for a given pool and token amounts. + * @param chainId The chain ID. + * @param amm The Automated Market Maker. + * @param publicClient Viem public client. + * @param positionDetails Uniswap SDK PositionDetails for the specified position. + * @param decreaseLiquidityOptions Decrease liquidity options. + * @param zeroForOne If true, collect in token1. If false, collect in token0. + * @param from The address to decrease liquidity for. + * @param tokenPricesUsd The prices of the two tokens in the pool in usd. + * @param blockNumber Optional. The block number to simulate the call from. + * @param includeSolvers Optional. The solvers to include. + */ +export async function decreaseLiquiditySingle( + chainId: ApertureSupportedChainId, + amm: AutomatedMarketMakerEnum, + publicClient: PublicClient, + positionDetails: PositionDetails, + decreaseLiquidityOptions: RemoveLiquidityOptions, // RemoveLiquidityOptions can be used for decreasing liquidity (<100%). + zeroForOne: boolean, + from: Address, + tokenPricesUsd: [string, string], + isUnwrapNative = true, + blockNumber?: bigint, + includeSolvers: E_Solver[] = DEFAULT_SOLVERS, +): Promise { + // Use BigInt math for precision, not the liquidity in SolverResult + const liquidityToDecrease = + (BigInt(positionDetails.liquidity.toString()) * + BigInt( + decreaseLiquidityOptions.liquidityPercentage.numerator.toString(), + )) / + BigInt(decreaseLiquidityOptions.liquidityPercentage.denominator.toString()); + const decreaseLiquidityParams: DecreaseLiquidityParams = { + tokenId: BigInt(decreaseLiquidityOptions.tokenId.toString()), + liquidity: liquidityToDecrease, + amount0Min: 0n, + amount1Min: 0n, + deadline: BigInt(Math.floor(Date.now() / 1000 + 86400)), + }; + const token0 = positionDetails.token0; + const token1 = positionDetails.token1; + const [positionInitialAmount0, positionInitialAmount1] = + await simulateDecreaseLiquidity( + amm, + chainId, + publicClient, + from, + positionDetails.owner, + decreaseLiquidityParams, + /* token0FeeAmount= */ 0n, + /* token1FeeAmount= */ 0n, + isUnwrapNative, + blockNumber, + ); + let swapAmountIn = zeroForOne + ? positionInitialAmount0 + : positionInitialAmount1; + const swapFeeAmount = BigInt( + new Big(swapAmountIn.toString()).mul(FEE_ZAP_RATIO).toFixed(0), + ); + swapAmountIn -= swapFeeAmount; + const token0FeeAmount = zeroForOne ? swapFeeAmount : 0n; + const token1FeeAmount = zeroForOne ? 0n : swapFeeAmount; + + const estimateGas = async (swapData: Hex) => { + try { + const [gasPrice, gasAmount] = await Promise.all([ + publicClient.getGasPrice(), + estimateDecreaseLiquiditySingleGas( + chainId, + amm, + publicClient, + from, + positionDetails.owner, + decreaseLiquidityParams, + zeroForOne, + token0FeeAmount, + token1FeeAmount, + swapData, + isUnwrapNative, + blockNumber, + ), + ]); + return gasPrice * gasAmount; + } catch (e) { + getLogger().error('SDK.decreaseLiquiditySingleV4.EstimateGas.Error', { + error: JSON.stringify((e as Error).message), + swapData, + decreaseLiquidityParams, + }); + return 0n; + } + }; + + const solve = async (solver: E_Solver) => { + let swapData: Hex = '0x'; + let swapRoute: SwapRoute | undefined = undefined; + let amountOut: bigint = 0n; + let gasFeeEstimation: bigint = 0n; + + try { + const slippage = + Number(decreaseLiquidityOptions.slippageTolerance.toSignificant()) / + 100; + if (swapAmountIn > 0n) { + // Although it's mintOptimal, it's the same swapData and swapRoute. + ({ swapData, swapRoute } = await getSolver(solver).mintOptimal({ + chainId, + amm, + fromAddress: from, + token0: token0.address as Address, + token1: token1.address as Address, + feeOrTickSpacing: + amm === AutomatedMarketMakerEnum.enum.SLIPSTREAM + ? positionDetails.tickSpacing + : positionDetails.fee, + tickLower: positionDetails.tickLower, + tickUpper: positionDetails.tickUpper, + slippage, + poolAmountIn: swapAmountIn, + zeroForOne, + isUseOptimalSwapRouter: false, // False because frontend uses the latest automan, which has the optimalSwapRouter merged into it. + })); + } + amountOut = await simulateDecreaseLiquiditySingle( + chainId, + amm, + publicClient, + from, + positionDetails.owner, + decreaseLiquidityParams, + zeroForOne, + token0FeeAmount, + token1FeeAmount, + swapData, + isUnwrapNative, + blockNumber, + ); + gasFeeEstimation = await estimateGas(swapData); + + const tokenInPrice = zeroForOne ? tokenPricesUsd[0] : tokenPricesUsd[1]; + const decimals = zeroForOne ? token0.decimals : token1.decimals; + const feeUSD = new Big(swapAmountIn.toString()) + .div(10 ** decimals) + .mul(tokenInPrice) + .mul(FEE_ZAP_RATIO); + const tokenOutSlippage = + (amountOut * + BigInt( + decreaseLiquidityOptions.slippageTolerance.numerator.toString(), + )) / + BigInt( + decreaseLiquidityOptions.slippageTolerance.denominator.toString(), + ); + // Based on current automan contracts, fees are in swapInputToken whereas slippage are in swapOutputToken. + const token0Out = zeroForOne ? 0n : amountOut; + const token1Out = zeroForOne ? amountOut : 0n; + const token0OutAfterSlippage = zeroForOne + ? 0n + : amountOut - tokenOutSlippage; + const token1OutAfterSlippage = zeroForOne + ? amountOut - tokenOutSlippage + : 0n; + getLogger().info('SDK.decreaseLiquiditySingleV4.fees ', { + solver: solver, + amm: amm, + chainId: chainId, + position: decreaseLiquidityOptions.tokenId, + totalDecreaseLiquiditySingleFeeUsd: feeUSD.toString(), + token0PricesUsd: tokenPricesUsd[0], + token1PricesUsd: tokenPricesUsd[1], + token0FeeAmount: token0FeeAmount.toString(), + token1FeeAmount: token1FeeAmount.toString(), + token0OutAfterSlippage: token0OutAfterSlippage.toString(), + token1OutAfterSlippage: token1OutAfterSlippage.toString(), + liquidityToDecrease: liquidityToDecrease.toString(), + zeroForOne, + swapAmountIn: swapAmountIn.toString(), + amountOut: amountOut.toString(), + }); + + return { + solver, + amount0: token0OutAfterSlippage, // Used for amount0Min + amount1: token1OutAfterSlippage, // Used for amount1Min + liquidity: amountOut, // Required for SolverResult, can be used to compare solvers. + swapData, + gasFeeEstimation, + swapRoute: getSwapRoute( + token0.address as Address, + token1.address as Address, + /* deltaAmount0= */ token0Out - positionInitialAmount0, // Actual amount doesn't matter, just whether it's positive or negative. + swapRoute, + ), + swapPath: getSwapPath( + token0.address as Address, + token1.address as Address, + positionInitialAmount0, + positionInitialAmount1, + token0Out, + token1Out, + slippage, + ), + feeUSD: feeUSD.toFixed(), + priceImpact: calcPriceImpact( + positionDetails.pool, + positionInitialAmount0, + positionInitialAmount1, + token0Out, + token1Out, + ), + token0FeeAmount, + token1FeeAmount, + } as SolverResult; + } catch (e) { + if (!(e as Error)?.message.startsWith('Expected')) { + getLogger().error('SDK.Solver.decreaseLiquiditySingle.Error', { + solver, + error: JSON.stringify((e as Error).message), + }); + } else { + console.warn('SDK.Solver.decreaseLiquiditySingle.Warning', solver); + } + return null; + } + }; + + return buildOptimalSolutions(solve, includeSolvers); +} diff --git a/src/viem/solver/get1InchSolver.ts b/src/viem/solver/get1InchSolver.ts index 08e9e6ac..60ba474e 100644 --- a/src/viem/solver/get1InchSolver.ts +++ b/src/viem/solver/get1InchSolver.ts @@ -54,10 +54,18 @@ export const get1InchSolver = (): ISolver => { slippage, poolAmountIn, zeroForOne, + isUseOptimalSwapRouter, } = props; - const { optimalSwapRouter } = getAMMInfo(chainId, amm)!; - if (!optimalSwapRouter) { + const { optimalSwapRouter, apertureAutomanV4 } = getAMMInfo( + chainId, + amm, + )!; + const from = + isUseOptimalSwapRouter == null || isUseOptimalSwapRouter + ? optimalSwapRouter + : apertureAutomanV4; + if (!from) { throw new Error('Expected: Chain or AMM not support'); } @@ -66,7 +74,7 @@ export const get1InchSolver = (): ISolver => { zeroForOne ? token0 : token1, zeroForOne ? token1 : token0, poolAmountIn.toString(), - optimalSwapRouter, + from, slippage * 100, true, ); @@ -74,8 +82,7 @@ export const get1InchSolver = (): ISolver => { const approveTarget = await get1InchApproveTarget(chainId); return { swapData: encodeOptimalSwapData( - chainId, - amm, + from, token0, token1, feeOrTickSpacing, diff --git a/src/viem/solver/getOkxSolver.ts b/src/viem/solver/getOkxSolver.ts index 7435a445..fa3d51d7 100644 --- a/src/viem/solver/getOkxSolver.ts +++ b/src/viem/solver/getOkxSolver.ts @@ -58,10 +58,18 @@ export const getOkxSolver = (): ISolver => { slippage, poolAmountIn, zeroForOne, + isUseOptimalSwapRouter, } = props; - const { optimalSwapRouter } = getAMMInfo(chainId, amm)!; - if (!optimalSwapRouter) { + const { optimalSwapRouter, apertureAutomanV4 } = getAMMInfo( + chainId, + amm, + )!; + const from = + isUseOptimalSwapRouter == null || isUseOptimalSwapRouter + ? optimalSwapRouter + : apertureAutomanV4; + if (!from) { throw new Error('Expected: Chain or AMM not support'); } @@ -70,7 +78,7 @@ export const getOkxSolver = (): ISolver => { zeroForOne ? token0 : token1, zeroForOne ? token1 : token0, poolAmountIn.toString(), - optimalSwapRouter, + from, slippage, ); @@ -81,8 +89,7 @@ export const getOkxSolver = (): ISolver => { ); return { swapData: encodeOptimalSwapData( - chainId, - amm, + from, token0, token1, feeOrTickSpacing, diff --git a/src/viem/solver/getPropellerHeadsSolver.ts b/src/viem/solver/getPropellerHeadsSolver.ts index 81fa4842..9981990e 100644 --- a/src/viem/solver/getPropellerHeadsSolver.ts +++ b/src/viem/solver/getPropellerHeadsSolver.ts @@ -28,20 +28,32 @@ export const getPropellerHeadsSolver = (): ISolver => { slippage, poolAmountIn, zeroForOne, + isUseOptimalSwapRouter, } = props; if (chainId !== ApertureSupportedChainId.ETHEREUM_MAINNET_CHAIN_ID) { throw new Error('Expected: Chain not supported'); } - const ammInfo = getAMMInfo(chainId, amm)!; + const { optimalSwapRouter, apertureAutomanV4 } = getAMMInfo( + chainId, + amm, + )!; + const from = + isUseOptimalSwapRouter == null || isUseOptimalSwapRouter + ? optimalSwapRouter + : apertureAutomanV4; + if (!from) { + throw new Error('Expected: Chain or AMM not support'); + } + // get a quote from PH const res = await quote( blockChainMap[chainId]!, zeroForOne ? token0 : token1, zeroForOne ? token1 : token0, poolAmountIn.toString(), - ammInfo.optimalSwapRouter!, + from, slippage, ); @@ -52,8 +64,7 @@ export const getPropellerHeadsSolver = (): ISolver => { return { swapData: encodeOptimalSwapData( - chainId, - amm, + from, token0, token1, feeOrTickSpacing, diff --git a/src/viem/solver/increaseLiquidityOptimal.ts b/src/viem/solver/increaseLiquidityOptimal.ts index 7585a99d..a0b201e6 100644 --- a/src/viem/solver/increaseLiquidityOptimal.ts +++ b/src/viem/solver/increaseLiquidityOptimal.ts @@ -1,330 +1,26 @@ -import { ApertureSupportedChainId, getAMMInfo, getLogger } from '@/index'; +import { ApertureSupportedChainId, getLogger } from '@/index'; import { IncreaseOptions, Position } from '@aperture_finance/uniswap-v3-sdk'; import { CurrencyAmount, Token } from '@uniswap/sdk-core'; import { AutomatedMarketMakerEnum } from 'aperture-lens/dist/src/viem'; import Big from 'big.js'; import { Address, Hex, PublicClient } from 'viem'; -import { - DEFAULT_SOLVERS, - E_Solver, - SwapRoute, - get1InchQuote, - getIsOkx, - getOkxSwap, - getSolver, -} from '.'; +import { DEFAULT_SOLVERS, E_Solver, SwapRoute, getSolver } from '.'; import { FEE_ZAP_RATIO, IncreaseLiquidityParams, - encodeOptimalSwapData, - estimateIncreaseLiquidityOptimalGas, - estimateIncreaseLiquidityOptimalV3Gas, - getAutomanContract, - simulateIncreaseLiquidityOptimal, - simulateIncreaseLiquidityOptimalV3, + estimateIncreaseLiquidityOptimalV4Gas, + simulateIncreaseLiquidityOptimalV4, } from '../automan'; -import { get1InchApproveTarget } from './get1InchSolver'; -import { getOkxApproveTarget } from './getOkxSolver'; import { - _getOptimalSwapAmount, buildOptimalSolutions, calcPriceImpact, - getOptimalSwapAmount, - getOptimalSwapAmountV3, + getOptimalSwapAmountV4, getSwapPath, getSwapRoute, } from './internal'; import { SolverResult } from './types'; -/** - * Get the optimal amount of liquidity to increase for a given pool and token amounts. - * @param chainId The chain ID. - * @param amm The Automated Market Maker. - * @param provider A JSON RPC provider or a base provider. - * @param position The current position to simulate the call from. - * @param increaseOptions Increase liquidity options. - * @param token0Amount The token0 amount. - * @param token1Amount The token1 amount. - * @param fromAddress The address to increase liquidity from. - * @param usePool Whether to use the pool or the aggregator for the swap. - * @param blockNumber Optional. The block number to simulate the call from. - * @param includeSwapInfo Optional. If set to true, the swap path and price impact will be included in the result. - */ -export async function increaseLiquidityOptimal( - chainId: ApertureSupportedChainId, - amm: AutomatedMarketMakerEnum, - publicClient: PublicClient, - position: Position, - increaseOptions: IncreaseOptions, - token0Amount: CurrencyAmount, - token1Amount: CurrencyAmount, - fromAddress: Address, - usePool = false, - blockNumber?: bigint, - includeSwapInfo?: boolean, -): Promise { - if (!token0Amount.currency.sortsBefore(token1Amount.currency)) { - throw new Error('token0 must be sorted before token1'); - } - const increaseParams: IncreaseLiquidityParams = { - tokenId: BigInt(increaseOptions.tokenId.toString()), - amount0Desired: BigInt(token0Amount.quotient.toString()), - amount1Desired: BigInt(token1Amount.quotient.toString()), - amount0Min: 0n, - amount1Min: 0n, - deadline: BigInt(Math.floor(Date.now() / 1000 + 86400)), - }; - - const getEstimate = async () => { - const { optimalSwapRouter } = getAMMInfo(chainId, amm)!; - - const poolPromise = increaseLiquidityOptimalPool( - chainId, - amm, - publicClient, - fromAddress, - position, - increaseParams, - blockNumber, - ); - - if (usePool || !optimalSwapRouter) { - return await poolPromise; - } - - const [poolEstimate, routerEstimate] = await Promise.all([ - poolPromise, - increaseLiquidityOptimalRouter( - chainId, - amm, - publicClient, - fromAddress, - position, - increaseParams, - Number(increaseOptions.slippageTolerance.toSignificant()), - ), - ]); - // use the same pool if the quote isn't better - if (poolEstimate.liquidity >= routerEstimate.liquidity) { - return poolEstimate; - } else { - return routerEstimate; - } - }; - - const ret = await getEstimate(); - - if (includeSwapInfo) { - ret.priceImpact = calcPriceImpact( - position.pool, - increaseParams.amount0Desired, - increaseParams.amount1Desired, - ret.amount0, - ret.amount1, - ); - - const token0 = (token0Amount.currency as Token).address as Address; - const token1 = (token1Amount.currency as Token).address as Address; - ret.swapPath = getSwapPath( - token0, - token1, - BigInt(token0Amount.quotient.toString()), - BigInt(token1Amount.quotient.toString()), - ret.amount0, - ret.amount1, - Number(increaseOptions.slippageTolerance.toSignificant()) / 100, - ); - } - - return ret; -} - -async function increaseLiquidityOptimalPool( - chainId: ApertureSupportedChainId, - amm: AutomatedMarketMakerEnum, - publicClient: PublicClient, - fromAddress: Address, - position: Position, - increaseParams: IncreaseLiquidityParams, - blockNumber?: bigint, -): Promise { - const [liquidity, amount0, amount1] = await simulateIncreaseLiquidityOptimal( - chainId, - amm, - publicClient, - fromAddress, - position, - increaseParams, - /* swapData= */ undefined, - blockNumber, - ); - let swapRoute: SwapRoute = []; - if (increaseParams.amount0Desired.toString() !== amount0.toString()) { - const [fromTokenAddress, toTokenAddress] = new Big( - increaseParams.amount0Desired.toString(), - ).gt(amount0.toString()) - ? [position.pool.token0.address, position.pool.token1.address] - : [position.pool.token1.address, position.pool.token0.address]; - swapRoute = [ - [ - [ - { - name: 'Pool', - part: 100, - fromTokenAddress: fromTokenAddress, - toTokenAddress: toTokenAddress, - }, - ], - ], - ]; - } - - return { - solver: E_Solver.SamePool, - amount0, - amount1, - liquidity, - swapData: '0x', - swapRoute, - }; -} - -async function increaseLiquidityOptimalRouter( - chainId: ApertureSupportedChainId, - amm: AutomatedMarketMakerEnum, - publicClient: PublicClient, - fromAddress: Address, - position: Position, - increaseParams: IncreaseLiquidityParams, - slippage: number, - blockNumber?: bigint, -): Promise { - const { solver, swapData, swapRoute } = - await getIncreaseLiquidityOptimalSwapData( - chainId, - amm, - publicClient, - position, - increaseParams, - slippage, - /* includeRoute= */ true, - ); - const [liquidity, amount0, amount1] = await simulateIncreaseLiquidityOptimal( - chainId, - amm, - publicClient, - fromAddress, - position, - increaseParams, - swapData, - blockNumber, - ); - return { - solver, - amount0, - amount1, - liquidity, - swapData, - swapRoute, - }; -} - -async function getIncreaseLiquidityOptimalSwapData( - chainId: ApertureSupportedChainId, - amm: AutomatedMarketMakerEnum, - publicClient: PublicClient, - position: Position, - increaseParams: IncreaseLiquidityParams, - slippage: number, - includeRoute?: boolean, -): Promise<{ - solver: E_Solver; - swapData: Hex; - swapRoute?: SwapRoute; -}> { - try { - const ammInfo = getAMMInfo(chainId, amm)!; - const isOkx = getIsOkx(); - - // get swap amounts using the same pool - const { poolAmountIn, zeroForOne } = await _getOptimalSwapAmount( - getAutomanContract, - chainId, - amm, - publicClient, - position.pool.token0.address as Address, - position.pool.token1.address as Address, - amm === AutomatedMarketMakerEnum.enum.SLIPSTREAM - ? position.pool.tickSpacing - : position.pool.fee, - position.tickLower, - position.tickUpper, - increaseParams.amount0Desired, - increaseParams.amount1Desired, - ); - - const approveTarget = await (isOkx - ? getOkxApproveTarget( - chainId, - zeroForOne - ? position.pool.token0.address - : position.pool.token1.address, - poolAmountIn.toString(), - ) - : get1InchApproveTarget(chainId)); - const { tx, protocols } = await (isOkx - ? getOkxSwap( - chainId, - zeroForOne - ? position.pool.token0.address - : position.pool.token1.address, - zeroForOne - ? position.pool.token1.address - : position.pool.token0.address, - poolAmountIn.toString(), - ammInfo.optimalSwapRouter!, - slippage, - ) - : get1InchQuote( - chainId, - zeroForOne - ? position.pool.token0.address - : position.pool.token1.address, - zeroForOne - ? position.pool.token1.address - : position.pool.token0.address, - poolAmountIn.toString(), - ammInfo.optimalSwapRouter!, - slippage * 100, - includeRoute, - )); - return { - solver: isOkx ? E_Solver.OKX : E_Solver.OneInch, - swapData: encodeOptimalSwapData( - chainId, - amm, - position.pool.token0.address as Address, - position.pool.token1.address as Address, - position.pool.fee, - position.tickLower, - position.tickUpper, - zeroForOne, - approveTarget, - tx.to, - tx.data, - ), - swapRoute: protocols, - }; - } catch (e) { - console.warn(`Failed to get swap data: ${e}`); - } - return { - solver: E_Solver.SamePool, - swapData: '0x', - }; -} - /** * Get the optimal amount of liquidity to increase for a given pool and token amounts. * @param chainId The chain ID. @@ -335,168 +31,11 @@ async function getIncreaseLiquidityOptimalSwapData( * @param token0Amount The token0 amount. * @param token1Amount The token1 amount. * @param fromAddress The address to increase liquidity from. + * @param tokenPricesUsd The token prices in USD. * @param blockNumber Optional. The block number to simulate the call from. * @param includeSolvers Optional. The solvers to include. */ -export async function increaseLiquidityOptimalV2( - chainId: ApertureSupportedChainId, - amm: AutomatedMarketMakerEnum, - publicClient: PublicClient, - position: Position, - increaseOptions: IncreaseOptions, - token0Amount: CurrencyAmount, - token1Amount: CurrencyAmount, - fromAddress: Address, - blockNumber?: bigint, - includeSolvers: E_Solver[] = DEFAULT_SOLVERS, -): Promise { - if (!token0Amount.currency.sortsBefore(token1Amount.currency)) { - throw new Error('token0 must be sorted before token1'); - } - - const increaseParams: IncreaseLiquidityParams = { - tokenId: BigInt(increaseOptions.tokenId.toString()), - amount0Desired: BigInt(token0Amount.quotient.toString()), - amount1Desired: BigInt(token1Amount.quotient.toString()), - amount0Min: 0n, - amount1Min: 0n, - deadline: BigInt(Math.floor(Date.now() / 1000 + 86400)), - }; - - const token0 = position.pool.token0.address as Address; - const token1 = position.pool.token1.address as Address; - const { tickLower, tickUpper } = position; - const feeOrTickSpacing = - amm === AutomatedMarketMakerEnum.enum.SLIPSTREAM - ? position.pool.tickSpacing - : position.pool.fee; - - const { poolAmountIn, zeroForOne } = await getOptimalSwapAmount( - chainId, - amm, - publicClient, - token0, - token1, - feeOrTickSpacing, - tickLower, - tickUpper, - increaseParams.amount0Desired, - increaseParams.amount1Desired, - blockNumber, - ); - - const estimateGas = async (swapData: Hex) => { - try { - const [gasPrice, gasAmount] = await Promise.all([ - publicClient.getGasPrice(), - estimateIncreaseLiquidityOptimalGas( - chainId, - amm, - publicClient, - fromAddress, - position, - increaseParams, - swapData, - blockNumber, - ), - ]); - return gasPrice * gasAmount; - } catch (e) { - getLogger().error('SDK.increaseLiquidityOptimalV2.EstimateGas.Error', { - error: JSON.stringify((e as Error).message), - swapData, - increaseParams, - }); - return 0n; - } - }; - - const solve = async (solver: E_Solver) => { - let swapData: Hex = '0x'; - let swapRoute: SwapRoute | undefined = undefined; - let liquidity: bigint = 0n; - let amount0: bigint = increaseParams.amount0Desired; - let amount1: bigint = increaseParams.amount1Desired; - let gasFeeEstimation: bigint = 0n; - - try { - const slippage = - Number(increaseOptions.slippageTolerance.toSignificant()) / 100; - if (poolAmountIn > 0n) { - ({ swapData, swapRoute } = await getSolver(solver).mintOptimal({ - chainId, - amm, - fromAddress, - token0, - token1, - feeOrTickSpacing, - tickLower, - tickUpper, - slippage, - poolAmountIn, - zeroForOne, - })); - [liquidity, amount0, amount1] = await simulateIncreaseLiquidityOptimal( - chainId, - amm, - publicClient, - fromAddress, - position, - increaseParams, - swapData, - blockNumber, - ); - gasFeeEstimation = await estimateGas(swapData); - } - - return { - solver, - amount0, - amount1, - liquidity, - swapData, - gasFeeEstimation, - swapRoute: getSwapRoute( - token0, - token1, - amount0 - increaseParams.amount0Desired, - swapRoute, - ), - priceImpact: calcPriceImpact( - position.pool, - increaseParams.amount0Desired, - increaseParams.amount1Desired, - amount0, - amount1, - ), - swapPath: getSwapPath( - token0, - token1, - increaseParams.amount0Desired, - increaseParams.amount1Desired, - amount0, - amount1, - slippage, - ), - } as SolverResult; - } catch (e) { - if (!(e as Error)?.message.startsWith('Expected')) { - getLogger().error('SDK.Solver.increaseLiquidityOptimalV2.Error', { - solver, - error: JSON.stringify((e as Error).message), - }); - } else { - console.warn('SDK.Solver.increaseLiquidityOptimalV2.Warning', solver); - } - return null; - } - }; - - return buildOptimalSolutions(solve, includeSolvers); -} - -// Same as increaseLiquidityOptimalV2, but with feeAmounts instead of feeBips. -export async function increaseLiquidityOptimalV3( +export async function increaseLiquidityOptimalV4( chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, publicClient: PublicClient, @@ -506,8 +45,8 @@ export async function increaseLiquidityOptimalV3( token1Amount: CurrencyAmount, fromAddress: Address, tokenPricesUsd: [string, string], - blockNumber?: bigint, includeSolvers: E_Solver[] = DEFAULT_SOLVERS, + blockNumber?: bigint, ): Promise { if (!token0Amount.currency.sortsBefore(token1Amount.currency)) { throw new Error('token0 must be sorted before token1'); @@ -532,7 +71,7 @@ export async function increaseLiquidityOptimalV3( // Subtract fees from poolAmountIn before passing to solver // to prevent ERC20 Error: transfer amount exceeds balance. - const { poolAmountIn, zeroForOne } = await getOptimalSwapAmountV3( + const { poolAmountIn, zeroForOne } = await getOptimalSwapAmountV4( chainId, amm, publicClient, @@ -560,7 +99,7 @@ export async function increaseLiquidityOptimalV3( .mul(tokenInPrice); // No need to subtract fees from increaseParams.amount0Desired // and increaseParams.amount1Desired because that's done in automan. - getLogger().info('SDK.increaseLiquidityOptimalV3.fees ', { + getLogger().info('SDK.increaseLiquidityOptimalV4.fees ', { amm, chainId, nftId: increaseOptions.tokenId, @@ -580,7 +119,7 @@ export async function increaseLiquidityOptimalV3( try { const [gasPrice, gasAmount] = await Promise.all([ publicClient.getGasPrice(), - estimateIncreaseLiquidityOptimalV3Gas( + estimateIncreaseLiquidityOptimalV4Gas( chainId, amm, publicClient, @@ -595,7 +134,7 @@ export async function increaseLiquidityOptimalV3( ]); return gasPrice * gasAmount; } catch (e) { - getLogger().error('SDK.increaseLiquidityOptimalV3.EstimateGas.Error', { + getLogger().error('SDK.increaseLiquidityOptimalV4.EstimateGas.Error', { error: JSON.stringify((e as Error).message), swapData, increaseParams, @@ -628,22 +167,22 @@ export async function increaseLiquidityOptimalV3( slippage, poolAmountIn: swapAmountIn, zeroForOne, + isUseOptimalSwapRouter: false, // False because frontend uses the latest automan, which has the optimalSwapRouter merged into it. })); - [liquidity, amount0, amount1] = - await simulateIncreaseLiquidityOptimalV3( - chainId, - amm, - publicClient, - fromAddress, - position, - increaseParams, - swapData, - token0FeeAmount, - token1FeeAmount, - blockNumber, - ); - gasFeeEstimation = await estimateGas(swapData); } + [liquidity, amount0, amount1] = await simulateIncreaseLiquidityOptimalV4( + chainId, + amm, + publicClient, + fromAddress, + position, + increaseParams, + swapData, + token0FeeAmount, + token1FeeAmount, + blockNumber, + ); + gasFeeEstimation = await estimateGas(swapData); return { solver, @@ -680,12 +219,12 @@ export async function increaseLiquidityOptimalV3( } as SolverResult; } catch (e) { if (!(e as Error)?.message.startsWith('Expected')) { - getLogger().error('SDK.Solver.increaseLiquidityOptimalV3.Error', { + getLogger().error('SDK.Solver.increaseLiquidityOptimalV4.Error', { solver, error: JSON.stringify((e as Error).message), }); } else { - console.warn('SDK.Solver.increaseLiquidityOptimalV3.Warning', solver); + console.warn('SDK.Solver.increaseLiquidityOptimalV4.Warning', solver); } return null; } diff --git a/src/viem/solver/index.ts b/src/viem/solver/index.ts index 3af1e77e..ada66706 100644 --- a/src/viem/solver/index.ts +++ b/src/viem/solver/index.ts @@ -7,6 +7,7 @@ export { getOkxQuote, getOkxSwap } from './getOkxSolver'; // TODO: remove when c export { get1InchQuote } from './get1InchSolver'; export * from './increaseLiquidityOptimal'; +export * from './decreaseLiquiditySingle'; export * from './mintOptimal'; export * from './rebalanceOptimal'; export * from './reinvest'; diff --git a/src/viem/solver/internal.ts b/src/viem/solver/internal.ts index 9857cd6c..fad2596b 100644 --- a/src/viem/solver/internal.ts +++ b/src/viem/solver/internal.ts @@ -1,5 +1,5 @@ import { - AutomanV3__factory, + AutomanV4__factory, Automan__factory, fractionToBig, getLogger, @@ -22,7 +22,7 @@ import { SlipStreamMintParams, UniV3MintParams, getAutomanContract, - getAutomanV3Contract, + getAutomanV4Contract, } from '../automan'; import { SwapPath } from './types'; import { SolverResult } from './types'; @@ -128,7 +128,7 @@ export const _getOptimalSwapAmount = async ( PublicClient | WalletClient > | GetContractReturnType< - typeof AutomanV3__factory.abi, + typeof AutomanV4__factory.abi, PublicClient | WalletClient >, chainId: ApertureSupportedChainId, @@ -241,7 +241,7 @@ export const getOptimalSwapAmount = async ( ); }; -export const getOptimalSwapAmountV3 = async ( +export const getOptimalSwapAmountV4 = async ( chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, publicClient: PublicClient, @@ -255,7 +255,7 @@ export const getOptimalSwapAmountV3 = async ( blockNumber?: bigint, ) => { return _getOptimalSwapAmount( - getAutomanV3Contract, + getAutomanV4Contract, chainId, amm, publicClient, diff --git a/src/viem/solver/mintOptimal.ts b/src/viem/solver/mintOptimal.ts index 245a4792..6d3e8262 100644 --- a/src/viem/solver/mintOptimal.ts +++ b/src/viem/solver/mintOptimal.ts @@ -1,4 +1,4 @@ -import { ApertureSupportedChainId, getAMMInfo, getLogger } from '@/index'; +import { ApertureSupportedChainId, getLogger } from '@/index'; import { CurrencyAmount, Token } from '@uniswap/sdk-core'; import { AutomatedMarketMakerEnum } from 'aperture-lens/dist/src/viem'; import Big from 'big.js'; @@ -9,32 +9,20 @@ import { E_Solver, SolverResult, SwapRoute, - get1InchQuote, - getIsOkx, - getOkxSwap, getSolver, } from '.'; import { FEE_ZAP_RATIO, SlipStreamMintParams, UniV3MintParams, - encodeOptimalSwapData, - estimateMintOptimalGas, - estimateMintOptimalV3Gas, - getAutomanContract, - simulateMintOptimal, - simulateMintOptimalV3, + estimateMintOptimalV4Gas, + simulateMintOptimalV4, } from '../automan'; import { getPool } from '../pool'; -import { get1InchApproveTarget } from './get1InchSolver'; -import { getOkxApproveTarget } from './getOkxSolver'; import { - _getOptimalSwapAmount, buildOptimalSolutions, calcPriceImpact, - getFeeOrTickSpacingFromMintParams, - getOptimalSwapAmount, - getOptimalSwapAmountV3, + getOptimalSwapAmountV4, getSwapPath, getSwapRoute, } from './internal'; @@ -45,502 +33,17 @@ import { * @param amm The Automated Market Maker. * @param token0Amount The token0 amount. * @param token1Amount The token1 amount. - * @param fee The pool fee tier. - * @param tickLower The lower tick of the range. - * @param tickUpper The upper tick of the range. - * @param fromAddress The address to mint from. - * @param slippage The slippage tolerance. - * @param publicClient Viem public client. - * @param usePool Whether to use the pool or the aggregator for the swap. - */ -export async function mintOptimal( - chainId: ApertureSupportedChainId, - amm: AutomatedMarketMakerEnum, - token0Amount: CurrencyAmount, - token1Amount: CurrencyAmount, - feeOrTickSpacing: number, - tickLower: number, - tickUpper: number, - fromAddress: Address, - slippage: number, - publicClient: PublicClient, - usePool = false, - blockNumber?: bigint, - includeSwapInfo?: boolean, -): Promise { - if (!token0Amount.currency.sortsBefore(token1Amount.currency)) { - throw new Error('token0 must be sorted before token1'); - } - const mintParams: SlipStreamMintParams | UniV3MintParams = - amm === AutomatedMarketMakerEnum.enum.SLIPSTREAM - ? { - token0: token0Amount.currency.address as Address, - token1: token1Amount.currency.address as Address, - tickSpacing: feeOrTickSpacing, - tickLower, - tickUpper, - amount0Desired: BigInt(token0Amount.quotient.toString()), - amount1Desired: BigInt(token1Amount.quotient.toString()), - amount0Min: 0n, - amount1Min: 0n, - recipient: fromAddress, - deadline: BigInt(Math.floor(Date.now() / 1000 + 86400)), - sqrtPriceX96: 0n, - } - : { - token0: token0Amount.currency.address as Address, - token1: token1Amount.currency.address as Address, - fee: feeOrTickSpacing, - tickLower, - tickUpper, - amount0Desired: BigInt(token0Amount.quotient.toString()), - amount1Desired: BigInt(token1Amount.quotient.toString()), - amount0Min: 0n, - amount1Min: 0n, - recipient: fromAddress, - deadline: BigInt(Math.floor(Date.now() / 1000 + 86400)), - }; - - const getEstimate = async () => { - const { optimalSwapRouter } = getAMMInfo(chainId, amm)!; - const poolPromise = mintOptimalPool( - chainId, - amm, - publicClient, - fromAddress, - mintParams, - blockNumber, - ); - - if (usePool || !optimalSwapRouter) { - return await poolPromise; - } - - const [poolEstimate, routerEstimate] = await Promise.all([ - poolPromise, - mintOptimalRouter( - chainId, - amm, - publicClient, - fromAddress, - mintParams, - slippage, - ), - ]); - // use the same pool if the quote isn't better - if (poolEstimate.liquidity > routerEstimate.liquidity) { - return poolEstimate; - } else { - return routerEstimate; - } - }; - - const ret = await getEstimate(); - - if (includeSwapInfo) { - const pool = await getPool( - mintParams.token0, - mintParams.token1, - feeOrTickSpacing, - chainId, - amm, - publicClient, - blockNumber, - ); - - ret.priceImpact = calcPriceImpact( - pool, - mintParams.amount0Desired, - mintParams.amount1Desired, - ret.amount0, - ret.amount1, - ); - - const token0 = (token0Amount.currency as Token).address as Address; - const token1 = (token1Amount.currency as Token).address as Address; - - ret.swapPath = getSwapPath( - token0, - token1, - BigInt(token0Amount.quotient.toString()), - BigInt(token1Amount.quotient.toString()), - ret.amount0, - ret.amount1, - slippage, - ); - } - - return ret; -} - -async function mintOptimalPool( - chainId: ApertureSupportedChainId, - amm: AutomatedMarketMakerEnum, - publicClient: PublicClient, - fromAddress: Address, - mintParams: SlipStreamMintParams | UniV3MintParams, - blockNumber?: bigint, -): Promise { - const [, liquidity, amount0, amount1] = await simulateMintOptimal( - chainId, - amm, - publicClient, - fromAddress, - mintParams, - /* swapData= */ undefined, - /* blockNumber= */ blockNumber, - ); - let swapRoute: SwapRoute = []; - if (mintParams.amount0Desired.toString() !== amount0.toString()) { - const [fromTokenAddress, toTokenAddress] = new Big( - mintParams.amount0Desired.toString(), - ).gt(amount0.toString()) - ? [mintParams.token0, mintParams.token1] - : [mintParams.token1, mintParams.token0]; - swapRoute = [ - [ - [ - { - name: 'Pool', - part: 100, - fromTokenAddress: fromTokenAddress, - toTokenAddress: toTokenAddress, - }, - ], - ], - ]; - } - - return { - solver: E_Solver.SamePool, - amount0, - amount1, - liquidity, - swapData: '0x', - swapRoute, - }; -} - -async function mintOptimalRouter( - chainId: ApertureSupportedChainId, - amm: AutomatedMarketMakerEnum, - publicClient: PublicClient, - fromAddress: Address, - mintParams: SlipStreamMintParams | UniV3MintParams, - slippage: number, -): Promise { - const { solver, swapData, swapRoute } = await getMintOptimalSwapData( - chainId, - amm, - publicClient, - mintParams, - slippage, - /* blockNumber= */ undefined, - /* includeRoute= */ true, - ); - const [, liquidity, amount0, amount1] = await simulateMintOptimal( - chainId, - amm, - publicClient, - fromAddress, - mintParams, - swapData, - undefined, - ); - return { - solver, - amount0, - amount1, - liquidity, - swapData, - swapRoute, - }; -} - -async function getMintOptimalSwapData( - chainId: ApertureSupportedChainId, - amm: AutomatedMarketMakerEnum, - publicClient: PublicClient, - mintParams: SlipStreamMintParams | UniV3MintParams, - slippage: number, - blockNumber?: bigint, - includeRoute?: boolean, -): Promise<{ - solver: E_Solver; - swapData: Hex; - swapRoute?: SwapRoute; -}> { - try { - const isOkx = getIsOkx(); - - const { poolAmountIn, zeroForOne } = await _getOptimalSwapAmount( - getAutomanContract, - chainId, - amm, - publicClient, - mintParams.token0, - mintParams.token1, - getFeeOrTickSpacingFromMintParams(amm, mintParams), - mintParams.tickLower, - mintParams.tickUpper, - mintParams.amount0Desired, - mintParams.amount1Desired, - blockNumber, - ); - - const ammInfo = getAMMInfo(chainId, amm)!; - const { tx, protocols } = await (isOkx - ? getOkxSwap( - chainId, - zeroForOne ? mintParams.token0 : mintParams.token1, - zeroForOne ? mintParams.token1 : mintParams.token0, - poolAmountIn.toString(), - ammInfo.optimalSwapRouter!, - slippage, - ) - : get1InchQuote( - chainId, - zeroForOne ? mintParams.token0 : mintParams.token1, - zeroForOne ? mintParams.token1 : mintParams.token0, - poolAmountIn.toString(), - ammInfo.optimalSwapRouter!, - slippage * 100, - includeRoute, - )); - - const approveTarget = await (isOkx - ? getOkxApproveTarget( - chainId, - zeroForOne ? mintParams.token0 : mintParams.token1, - poolAmountIn.toString(), - ) - : get1InchApproveTarget(chainId)); - - return { - solver: isOkx ? E_Solver.OKX : E_Solver.OneInch, - swapData: encodeOptimalSwapData( - chainId, - amm, - mintParams.token0, - mintParams.token1, - getFeeOrTickSpacingFromMintParams(amm, mintParams), - mintParams.tickLower, - mintParams.tickUpper, - zeroForOne, - approveTarget, - tx.to, - tx.data, - ), - swapRoute: protocols, - }; - } catch (e) { - console.warn(`Failed to get swap data: ${e}`); - } - return { - solver: E_Solver.SamePool, - swapData: '0x', - }; -} - -/** - * Get the optimal amount of liquidity to mint for a given pool and token amounts. - * @param chainId The chain ID. - * @param amm The Automated Market Maker. - * @param token0Amount The token0 amount. - * @param token1Amount The token1 amount. - * @param fee The pool fee tier. + * @param feeOrTickSpacing The pool fee tier or tick spacing. * @param tickLower The lower tick of the range. * @param tickUpper The upper tick of the range. * @param fromAddress The address to mint from. * @param slippage The slippage tolerance. + * @param tokenPricesUsd The token prices in USD. * @param publicClient Viem public client. * @param blockNumber Optional. The block number to use for the simulation. * @param includeSolvers Optional. The solvers to include. */ -export async function mintOptimalV2( - chainId: ApertureSupportedChainId, - amm: AutomatedMarketMakerEnum, - token0Amount: CurrencyAmount, - token1Amount: CurrencyAmount, - feeOrTickSpacing: number, - tickLower: number, - tickUpper: number, - fromAddress: Address, - slippage: number, - publicClient: PublicClient, - blockNumber?: bigint, - includeSolvers: E_Solver[] = DEFAULT_SOLVERS, -): Promise { - if (!token0Amount.currency.sortsBefore(token1Amount.currency)) { - throw new Error('token0 must be sorted before token1'); - } - if (!blockNumber) { - blockNumber = await publicClient.getBlockNumber(); - } - const token0 = token0Amount.currency.address as Address; - const token1 = token1Amount.currency.address as Address; - const mintParams: SlipStreamMintParams | UniV3MintParams = - amm === AutomatedMarketMakerEnum.enum.SLIPSTREAM - ? { - token0, - token1, - tickSpacing: feeOrTickSpacing, - tickLower, - tickUpper, - amount0Desired: BigInt(token0Amount.quotient.toString()), - amount1Desired: BigInt(token1Amount.quotient.toString()), - amount0Min: 0n, - amount1Min: 0n, - recipient: fromAddress, - deadline: BigInt(Math.floor(Date.now() / 1000 + 86400)), - sqrtPriceX96: 0n, - } - : { - token0, - token1, - fee: feeOrTickSpacing, - tickLower, - tickUpper, - amount0Desired: BigInt(token0Amount.quotient.toString()), - amount1Desired: BigInt(token1Amount.quotient.toString()), - amount0Min: 0n, - amount1Min: 0n, - recipient: fromAddress, - deadline: BigInt(Math.floor(Date.now() / 1000 + 86400)), - }; - - const { poolAmountIn, zeroForOne } = await getOptimalSwapAmount( - chainId, - amm, - publicClient, - token0, - token1, - feeOrTickSpacing, - tickLower, - tickUpper, - mintParams.amount0Desired, - mintParams.amount1Desired, - blockNumber, - ); - - const estimateGas = async (swapData: Hex) => { - try { - const [gasPrice, gasAmount] = await Promise.all([ - publicClient.getGasPrice(), - estimateMintOptimalGas( - chainId, - amm, - publicClient, - fromAddress, - mintParams, - swapData, - blockNumber, - ), - ]); - return gasPrice * gasAmount; - } catch (e) { - getLogger().error('SDK.mintOptimalV2.EstimateGas.Error', { - error: JSON.stringify((e as Error).message), - swapData, - mintParams, - }); - return 0n; - } - }; - - const solve = async (solver: E_Solver) => { - let swapData: Hex = '0x'; - let swapRoute: SwapRoute | undefined = undefined; - let liquidity: bigint = 0n; - let amount0: bigint = mintParams.amount0Desired; - let amount1: bigint = mintParams.amount1Desired; - let gasFeeEstimation: bigint = 0n; - - try { - if (poolAmountIn > 0n) { - ({ swapData, swapRoute } = await getSolver(solver).mintOptimal({ - chainId, - amm, - fromAddress, - token0, - token1, - feeOrTickSpacing, - tickLower, - tickUpper, - slippage, - poolAmountIn, - zeroForOne, - })); - [, liquidity, amount0, amount1] = await simulateMintOptimal( - chainId, - amm, - publicClient, - fromAddress, - mintParams, - swapData, - blockNumber, - ); - gasFeeEstimation = await estimateGas(swapData); - } - - const pool = await getPool( - token0, - token1, - feeOrTickSpacing, - chainId, - amm, - publicClient, - blockNumber, - ); - - return { - solver, - amount0, - amount1, - liquidity, - swapData, - gasFeeEstimation, - swapRoute: getSwapRoute( - token0, - token1, - amount0 - mintParams.amount0Desired, - swapRoute, - ), - priceImpact: calcPriceImpact( - pool, - mintParams.amount0Desired, - mintParams.amount1Desired, - amount0, - amount1, - ), - swapPath: getSwapPath( - mintParams.token0, - mintParams.token1, - mintParams.amount0Desired, - mintParams.amount1Desired, - amount0, - amount1, - slippage, - ), - } as SolverResult; - } catch (e) { - if (!(e as Error)?.message.startsWith('Expected')) { - getLogger().error('SDK.Solver.mintOptimal2.Error', { - solver, - error: JSON.stringify((e as Error).message), - }); - } else { - console.warn('SDK.Solver.mintOptimalV2.Warning', solver); - } - return null; - } - }; - - return buildOptimalSolutions(solve, includeSolvers); -} - -// Same as mintOptimalV2, but with feeAmounts instead of feeBips. -export async function mintOptimalV3( +export async function mintOptimalV4( chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, token0Amount: CurrencyAmount, @@ -596,7 +99,7 @@ export async function mintOptimalV3( // Subtract fees from poolAmountIn before passing to solver // to prevent ERC20 Error: transfer amount exceeds balance. - const { poolAmountIn, zeroForOne } = await getOptimalSwapAmountV3( + const { poolAmountIn, zeroForOne } = await getOptimalSwapAmountV4( chainId, amm, publicClient, @@ -623,7 +126,7 @@ export async function mintOptimalV3( .div(10 ** tokenInDecimals) .mul(tokenInPrice); - getLogger().info('SDK.mintOptimalV3.Fees ', { + getLogger().info('SDK.mintOptimalV4.Fees ', { amm: amm, chainId: chainId, totalMintOptimalFeeUsd: feeUSD.toString(), @@ -642,7 +145,7 @@ export async function mintOptimalV3( try { const [gasPrice, gasAmount] = await Promise.all([ publicClient.getGasPrice(), - estimateMintOptimalV3Gas( + estimateMintOptimalV4Gas( chainId, amm, publicClient, @@ -656,7 +159,7 @@ export async function mintOptimalV3( ]); return gasPrice * gasAmount; } catch (e) { - getLogger().error('SDK.mintOptimalV3.EstimateGas.Error', { + getLogger().error('SDK.mintOptimalV4.EstimateGas.Error', { error: JSON.stringify((e as Error).message), swapData, mintParams, @@ -687,20 +190,21 @@ export async function mintOptimalV3( slippage, poolAmountIn: swapAmountIn, zeroForOne, + isUseOptimalSwapRouter: false, // False because frontend uses the latest automan, which has the optimalSwapRouter merged into it. })); - [, liquidity, amount0, amount1] = await simulateMintOptimalV3( - chainId, - amm, - publicClient, - fromAddress, - mintParams, - swapData, - token0FeeAmount, - token1FeeAmount, - blockNumber, - ); - gasFeeEstimation = await estimateGas(swapData); } + [, liquidity, amount0, amount1] = await simulateMintOptimalV4( + chainId, + amm, + publicClient, + fromAddress, + mintParams, + swapData, + token0FeeAmount, + token1FeeAmount, + blockNumber, + ); + gasFeeEstimation = await estimateGas(swapData); return { solver, @@ -745,13 +249,13 @@ export async function mintOptimalV3( } as SolverResult; } catch (e) { if (!(e as Error)?.message.startsWith('Expected')) { - getLogger().error('SDK.Solver.mintOptimalV3.Error', { + getLogger().error('SDK.Solver.mintOptimalV4.Error', { solver, error: JSON.stringify((e as Error).message), mintParams, }); } else { - console.warn('SDK.Solver.mintOptimalV3.Warning', solver); + console.warn('SDK.Solver.mintOptimalV4.Warning', solver); } return null; } diff --git a/src/viem/solver/rebalanceOptimal.ts b/src/viem/solver/rebalanceOptimal.ts index 6292d433..be60464a 100644 --- a/src/viem/solver/rebalanceOptimal.ts +++ b/src/viem/solver/rebalanceOptimal.ts @@ -14,12 +14,12 @@ import { SlipStreamMintParams, UniV3MintParams, estimateRebalanceGas, - estimateRebalanceV3Gas, + estimateRebalanceV4Gas, getAutomanRebalanceCalldata, + simulateDecreaseLiquidity, simulateRebalance, - simulateRebalanceV3, + simulateRebalanceV4, simulateRemoveLiquidity, - simulateRemoveLiquidityV3, } from '../automan'; import { FEE_REBALANCE_SWAP_RATIO, @@ -34,7 +34,7 @@ import { buildOptimalSolutions, calcPriceImpact, getOptimalSwapAmount, - getOptimalSwapAmountV3, + getOptimalSwapAmountV4, getSwapPath, getSwapRoute, } from './internal'; @@ -42,12 +42,13 @@ import { SolverResult, SwapRoute } from './types'; /** * Get the optimal amount of liquidity to rebalance for a given position. + * Currently used for frontend, who can optionally be migrated to rebalanceV4. * @param chainId The chain ID. * @param amm The Automated Market Maker. * @param positionDetails Position details * @param newTickLower The new lower tick. * @param newTickUpper The new upper tick. - * @param feeBips The fee Aperture charge for the transaction. + * @param feeBips The Aperture fee for the transaction. * @param fromAddress The address to rebalance from. * @param slippage The slippage tolerance. * @param publicClient Viem public client. @@ -75,7 +76,7 @@ export async function rebalanceOptimalV2( const logdata = { chainId, amm, - position: positionDetails.tokenId, + nftId: positionDetails.tokenId, newTickLower, newTickUpper, fromAddress, @@ -200,7 +201,7 @@ export async function rebalanceOptimalV2( .mul(FEE_REBALANCE_SWAP_RATIO) .add(collectableTokenInUsd.mul(getFeeReinvestRatio(positionDetails.fee))) .add(FEE_REBALANCE_USD); - // positionUsd includes feesCollected and so does feeBips + // positionUsd and feeBips usage both includes feesCollected const feeBips = BigInt( feeUSD.div(positionUsd).mul(MAX_FEE_PIPS).toFixed(0), ); @@ -343,21 +344,22 @@ export async function rebalanceOptimalV2( slippage, poolAmountIn, zeroForOne, + isUseOptimalSwapRouter: false, // False because frontend uses the latest automan, which has the optimalSwapRouter merged into it. })); - [, liquidity, amount0, amount1] = await simulateRebalance( - chainId, - amm, - publicClient, - fromAddress, - positionDetails.owner, - mintParams, - BigInt(positionDetails.tokenId), - feeBips, - swapData, - blockNumber, - ); - gasFeeEstimation = await estimateGas(swapData); } + [, liquidity, amount0, amount1] = await simulateRebalance( + chainId, + amm, + publicClient, + fromAddress, + positionDetails.owner, + mintParams, + BigInt(positionDetails.tokenId), + feeBips, + swapData, + blockNumber, + ); + gasFeeEstimation = await estimateGas(swapData); return { solver, @@ -402,7 +404,7 @@ export async function rebalanceOptimalV2( return buildOptimalSolutions(solve, includeSolvers); } -// Used for backend. +// Used for backend with 2x solver calls for gas reimbursements. export async function rebalanceBackend( chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, @@ -417,7 +419,7 @@ export async function rebalanceBackend( includeSolvers: E_Solver[] = DEFAULT_SOLVERS, blockNumber?: bigint, ): Promise { - const tokenId = BigInt(positionDetails.tokenId); + const nftId = BigInt(positionDetails.tokenId); const token0 = positionDetails.token0; const token1 = positionDetails.token1; const feeOrTickSpacing = @@ -432,7 +434,7 @@ export async function rebalanceBackend( chainId, amm, fromAddress, - tokenId, + nftId, newTickLower, newTickUpper, slippage, @@ -445,7 +447,7 @@ export async function rebalanceBackend( publicClient, fromAddress, positionDetails.owner, - tokenId, + nftId, /* amount0Min= */ undefined, /* amount1Min= */ undefined, /* feeBips= */ 0n, @@ -543,21 +545,35 @@ export async function rebalanceBackend( feeBips: feeBips, }); - const mintParams: SlipStreamMintParams | UniV3MintParams = { - token0: token0.address as Address, - token1: token1.address as Address, - ...(amm === AutomatedMarketMakerEnum.enum.SLIPSTREAM - ? { tickSpacing: feeOrTickSpacing, sqrtPriceX96: 0n } - : { fee: feeOrTickSpacing }), - tickLower: newTickLower, - tickUpper: newTickUpper, - amount0Desired: 0n, // Not used in Automan. - amount1Desired: 0n, // Not used in Automan. - amount0Min: 0n, // Setting this to zero for tx simulation. - amount1Min: 0n, // Setting this to zero for tx simulation. - recipient: positionDetails.owner, // Param value ignored by Automan for rebalance. - deadline: BigInt(Math.floor(Date.now() / 1000 + 86400)), - }; + const mintParams: SlipStreamMintParams | UniV3MintParams = + amm === AutomatedMarketMakerEnum.enum.SLIPSTREAM + ? { + token0: token0.address as Address, + token1: token1.address as Address, + tickSpacing: feeOrTickSpacing, + tickLower: newTickLower, + tickUpper: newTickUpper, + amount0Desired: 0n, // Not used in Automan. + amount1Desired: 0n, // Not used in Automan. + amount0Min: 0n, // Setting this to zero for tx simulation. + amount1Min: 0n, // Setting this to zero for tx simulation. + recipient: positionDetails.owner, // Param value ignored by Automan for rebalance. + deadline: BigInt(Math.floor(Date.now() / 1000 + 86400)), + sqrtPriceX96: 0n, + } + : { + token0: token0.address as Address, + token1: token1.address as Address, + fee: feeOrTickSpacing, + tickLower: newTickLower, + tickUpper: newTickUpper, + amount0Desired: 0n, // Not used in Automan. + amount1Desired: 0n, // Not used in Automan. + amount0Min: 0n, // Setting this to zero for tx simulation. + amount1Min: 0n, // Setting this to zero for tx simulation. + recipient: positionDetails.owner, // Param value ignored by Automan for rebalance. + deadline: BigInt(Math.floor(Date.now() / 1000 + 86400)), + }; const estimateGasInRawNaive = async (swapData: Hex) => { // Pass errors without (try-)catch, because failing to estimate gas will fail to reimburse relayer for gas. @@ -570,7 +586,7 @@ export async function rebalanceBackend( fromAddress, positionDetails.owner, mintParams, - tokenId, + nftId, feeBips, swapData, blockNumber, @@ -596,7 +612,7 @@ export async function rebalanceBackend( data: getAutomanRebalanceCalldata( amm, mintParams, - tokenId, + nftId, feeBips, swapData, /* permitInfo= */ undefined, @@ -709,6 +725,7 @@ export async function rebalanceBackend( zeroForOne, })); } else { + // Clear prior swapData and swapRoute if no swapAmountIn after accounting for gas reimbursements. swapData = '0x'; swapRoute = undefined; } @@ -719,7 +736,7 @@ export async function rebalanceBackend( fromAddress, positionDetails.owner, mintParams, - BigInt(positionDetails.tokenId), + nftId, totalFeePips, swapData, blockNumber, @@ -774,8 +791,8 @@ export async function rebalanceBackend( } // Same as rebalanceOptimalV2, but with feeAmounts instead of feeBips. -// Do not use, but implemented to make it easier to migrate to future versions. -export async function rebalanceV3( +// Frontend don't have to use, but implemented to make it easier to migrate to future versions. +export async function rebalanceV4( chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, publicClient: PublicClient, @@ -788,7 +805,7 @@ export async function rebalanceV3( includeSolvers: E_Solver[] = DEFAULT_SOLVERS, blockNumber?: bigint, ): Promise { - const tokenId = BigInt(positionDetails.tokenId); + const nftId = BigInt(positionDetails.tokenId); const token0 = positionDetails.token0; const token1 = positionDetails.token1; const feeOrTickSpacing = @@ -802,7 +819,7 @@ export async function rebalanceV3( const logdata = { chainId, amm, - tokenId, + nftId, newTickLower, newTickUpper, fromAddress, @@ -810,21 +827,26 @@ export async function rebalanceV3( tokenPricesUsd, }; - const [receive0, receive1] = await simulateRemoveLiquidityV3( - chainId, + const [receive0, receive1] = await simulateDecreaseLiquidity( amm, + chainId, publicClient, fromAddress, positionDetails.owner, - BigInt(positionDetails.tokenId), - /* amount0Min= */ 0n, - /* amount1Min= */ 0n, + /* decreaseLiquidityParams= */ { + tokenId: nftId, + liquidity: BigInt(positionDetails.liquidity), + amount0Min: 0n, + amount1Min: 0n, + deadline: BigInt(Math.floor(Date.now() / 1000 + 86400)), + }, /* token0FeeAmount= */ 0n, /* token1FeeAmount= */ 0n, + /* isUnwrapNative= */ true, blockNumber, ); - const { poolAmountIn, zeroForOne } = await getOptimalSwapAmountV3( + const { poolAmountIn, zeroForOne } = await getOptimalSwapAmountV4( chainId, amm, publicClient, @@ -891,7 +913,7 @@ export async function rebalanceV3( const swapAmountIn = poolAmountIn - (zeroForOne ? token0FeeAmount : token1FeeAmount); - getLogger().info('SDK.rebalanceV3.fees ', { + getLogger().info('SDK.rebalanceV4.Fees', { ...logdata, rebalanceFeeUsd: feeUSD.toString(), swapFeesUsd: swapFeesUsd.toString(), @@ -910,34 +932,48 @@ export async function rebalanceV3( feeBips: feeBips, }); - const mintParams: SlipStreamMintParams | UniV3MintParams = { - token0: token0.address as Address, - token1: token1.address as Address, - ...(amm === AutomatedMarketMakerEnum.enum.SLIPSTREAM - ? { tickSpacing: feeOrTickSpacing, sqrtPriceX96: 0n } - : { fee: feeOrTickSpacing }), - tickLower: newTickLower, - tickUpper: newTickUpper, - amount0Desired: 0n, // Not used in Automan. - amount1Desired: 0n, // Not used in Automan. - amount0Min: 0n, // Setting this to zero for tx simulation. - amount1Min: 0n, // Setting this to zero for tx simulation. - recipient: positionDetails.owner, // Param value ignored by Automan for rebalance. - deadline: BigInt(Math.floor(Date.now() / 1000 + 86400)), - }; + const mintParams: SlipStreamMintParams | UniV3MintParams = + amm === AutomatedMarketMakerEnum.enum.SLIPSTREAM + ? { + token0: token0.address as Address, + token1: token1.address as Address, + tickSpacing: feeOrTickSpacing, + tickLower: newTickLower, + tickUpper: newTickUpper, + amount0Desired: 0n, // Not used in Automan. + amount1Desired: 0n, // Not used in Automan. + amount0Min: 0n, // Setting this to zero for tx simulation. + amount1Min: 0n, // Setting this to zero for tx simulation. + recipient: positionDetails.owner, // Param value ignored by Automan for rebalance. + deadline: BigInt(Math.floor(Date.now() / 1000 + 86400)), + sqrtPriceX96: 0n, + } + : { + token0: token0.address as Address, + token1: token1.address as Address, + fee: feeOrTickSpacing, + tickLower: newTickLower, + tickUpper: newTickUpper, + amount0Desired: 0n, // Not used in Automan. + amount1Desired: 0n, // Not used in Automan. + amount0Min: 0n, // Setting this to zero for tx simulation. + amount1Min: 0n, // Setting this to zero for tx simulation. + recipient: positionDetails.owner, // Param value ignored by Automan for rebalance. + deadline: BigInt(Math.floor(Date.now() / 1000 + 86400)), + }; const estimateGas = async (swapData: Hex) => { try { const [gasPrice, gasAmount] = await Promise.all([ publicClient.getGasPrice(), - estimateRebalanceV3Gas( + estimateRebalanceV4Gas( chainId, amm, publicClient, fromAddress, positionDetails.owner, mintParams, - BigInt(positionDetails.tokenId), + nftId, token0FeeAmount, token1FeeAmount, swapData, @@ -946,7 +982,7 @@ export async function rebalanceV3( ]); return gasPrice * gasAmount; } catch (e) { - getLogger().error('SDK.rebalanceV3.EstimateGas.Error', { + getLogger().error('SDK.rebalanceV4.EstimateGas.Error', { error: JSON.stringify(e), swapData, mintParams, @@ -981,16 +1017,17 @@ export async function rebalanceV3( slippage, poolAmountIn: swapAmountIn, zeroForOne, + isUseOptimalSwapRouter: false, // False because frontend uses the latest automan, which has the optimalSwapRouter merged into it. })); } - [, liquidity, amount0, amount1] = await simulateRebalanceV3( + [, liquidity, amount0, amount1] = await simulateRebalanceV4( chainId, amm, publicClient, fromAddress, positionDetails.owner, mintParams, - BigInt(positionDetails.tokenId), + nftId, token0FeeAmount, token1FeeAmount, swapData, @@ -1033,12 +1070,12 @@ export async function rebalanceV3( } as SolverResult; } catch (e) { if (!(e as Error)?.message.startsWith('Expected')) { - getLogger().error('SDK.Solver.rebalanceV3.Error', { + getLogger().error('SDK.Solver.rebalanceV4.Error', { solver, error: JSON.stringify((e as Error).message), }); } else { - console.warn('SDK.Solver.rebalanceV3.Warning', solver); + console.warn('SDK.Solver.rebalanceV4.Warning', solver); } return null; } diff --git a/src/viem/solver/reinvest.ts b/src/viem/solver/reinvest.ts index 4a957da0..9b8c0408 100644 --- a/src/viem/solver/reinvest.ts +++ b/src/viem/solver/reinvest.ts @@ -16,11 +16,11 @@ import { IncreaseLiquidityParams, MAX_FEE_PIPS, estimateReinvestGas, - estimateReinvestV3Gas, + estimateReinvestV4Gas, getAutomanReinvestCalldata, getFeeReinvestRatio, simulateReinvest, - simulateReinvestV3, + simulateReinvestV4, } from '../automan'; import { PositionDetails } from '../position'; import { estimateTotalGasCostForOptimismLikeL2Tx } from '../public_client'; @@ -28,7 +28,7 @@ import { buildOptimalSolutions, calcPriceImpact, getOptimalSwapAmount, - getOptimalSwapAmountV3, + getOptimalSwapAmountV4, getSwapPath, getSwapRoute, } from './internal'; @@ -380,7 +380,7 @@ export async function reinvestBackend( } // Used for frontend. -export async function reinvestV3( +export async function reinvestV4( chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, publicClient: PublicClient, @@ -410,7 +410,7 @@ export async function reinvestV3( // Subtract fees from poolAmountIn before passing to solver // to prevent ERC20 Error: transfer amount exceeds balance. - const { poolAmountIn, zeroForOne } = await getOptimalSwapAmountV3( + const { poolAmountIn, zeroForOne } = await getOptimalSwapAmountV4( chainId, amm, publicClient, @@ -450,7 +450,7 @@ export async function reinvestV3( .mul(tokenPricesUsd[1]), ); - getLogger().info('SDK.reinvestV3.fees ', { + getLogger().info('SDK.reinvestV4.fees ', { amm, chainId, tokenId, @@ -470,7 +470,7 @@ export async function reinvestV3( try { const [gasPrice, gasAmount] = await Promise.all([ publicClient.getGasPrice(), - estimateReinvestV3Gas( + estimateReinvestV4Gas( chainId, amm, publicClient, @@ -483,9 +483,9 @@ export async function reinvestV3( blockNumber, ), ]); - return gasPrice * gasAmount; + return BigInt(gasPrice * gasAmount); } catch (e) { - getLogger().error('SDK.reinvestV3.EstimateGas.Error', { + getLogger().error('SDK.reinvestV4.EstimateGas.Error', { error: JSON.stringify((e as Error).message), swapData, increaseLiquidityParams, @@ -520,7 +520,7 @@ export async function reinvestV3( zeroForOne, })); } - [liquidity, amount0, amount1] = await simulateReinvestV3( + [liquidity, amount0, amount1] = await simulateReinvestV4( chainId, amm, publicClient, @@ -577,12 +577,12 @@ export async function reinvestV3( } as SolverResult; } catch (e) { if (!(e as Error)?.message.startsWith('Expected')) { - getLogger().error('SDK.Solver.reinvestV3.Error', { + getLogger().error('SDK.Solver.reinvestV4.Error', { solver, error: JSON.stringify((e as Error).message), }); } else { - console.warn('SDK.Solver.reinvestV3.Warning', solver); + console.warn('SDK.Solver.reinvestV4.Warning', solver); } return null; } diff --git a/src/viem/solver/types.ts b/src/viem/solver/types.ts index 1c8d2957..15448506 100644 --- a/src/viem/solver/types.ts +++ b/src/viem/solver/types.ts @@ -28,6 +28,7 @@ export interface SolveMintOptimalProps { slippage: number; // 0.01 = 1% poolAmountIn: bigint; zeroForOne: boolean; + isUseOptimalSwapRouter?: boolean; // optional and assume true by default as implemented in automanV1, but set to false in automanV4+ (optimalSwapRouter is merged into automanV4). } export interface ISolver { diff --git a/src/viem/transaction/getDecreaseLiquiditySingleTx.ts b/src/viem/transaction/getDecreaseLiquiditySingleTx.ts new file mode 100644 index 00000000..d57c9c78 --- /dev/null +++ b/src/viem/transaction/getDecreaseLiquiditySingleTx.ts @@ -0,0 +1,81 @@ +import { ApertureSupportedChainId, PermitInfo, getAMMInfo } from '@/index'; +import { RemoveLiquidityOptions } from '@aperture_finance/uniswap-v3-sdk'; +import { AutomatedMarketMakerEnum } from 'aperture-lens/dist/src/viem'; +import { Address, Hex, PublicClient, TransactionRequest } from 'viem'; + +import { + DecreaseLiquidityParams, + getAutomanDecreaseLiquiditySingleCalldata, +} from '../automan'; +import { PositionDetails } from '../position'; + +/** + * Generates an unsigned transaction that removes partial or entire liquidity from the specified position and claim accrued fees. + * @param decreaseLiquidityOptions Remove liquidity options. RemoveLiquidityOptions can be used for decreasing liquidity (<100%). + * @param zeroForOne If true, collect in token1. If false, collect in token0. + * @param recipient The recipient address (connected wallet address). + * @param chainId Chain id. + * @param amm Automated Market Maker. + * @param client Viem public client. + * @param swapData Swap data after collecting. + * @param positionDetails Uniswap SDK PositionDetails for the specified position (optional); if undefined, one will be created. + * @param amount0Min Min amount of token0 to receive. + * @param amount1Min Min amount of token1 to receive. + * @param token0FeeAmount Fee amount for token0. + * @param token1FeeAmount Fee amount for token1. + * @param blockNumber Optional. The block number to simulate the call from. + * @returns The unsigned tx. + */ +export async function getDecreaseLiquiditySingleTx( + decreaseLiquidityOptions: Omit, + zeroForOne: boolean, + recipient: string, + chainId: ApertureSupportedChainId, + amm: AutomatedMarketMakerEnum, + client: PublicClient, + swapData: Hex, + positionDetails?: PositionDetails, + amount0Min: bigint = 0n, + amount1Min: bigint = 0n, + token0FeeAmount: bigint = 0n, + token1FeeAmount: bigint = 0n, + isUnwrapNative = true, + permitInfo?: PermitInfo, +): Promise { + if (positionDetails === undefined) { + positionDetails = await PositionDetails.fromPositionId( + chainId, + amm, + BigInt(decreaseLiquidityOptions.tokenId.toString()), + client, + ); + } + // Use BigInt math for precision, not the liquidity in SolverResult + const liquidityToDecrease = + (BigInt(positionDetails.liquidity.toString()) * + BigInt( + decreaseLiquidityOptions.liquidityPercentage.numerator.toString(), + )) / + BigInt(decreaseLiquidityOptions.liquidityPercentage.denominator.toString()); + const decreaseLiquidityParams: DecreaseLiquidityParams = { + tokenId: BigInt(decreaseLiquidityOptions.tokenId.toString()), + liquidity: liquidityToDecrease, + amount0Min, + amount1Min, + deadline: BigInt(decreaseLiquidityOptions.deadline.toString()), + }; + const data = getAutomanDecreaseLiquiditySingleCalldata( + decreaseLiquidityParams, + zeroForOne, + token0FeeAmount, + token1FeeAmount, + swapData, + isUnwrapNative, + permitInfo, + ); + return { + to: getAMMInfo(chainId, amm)!.apertureAutomanV4, + data, + from: recipient as Address, + }; +} diff --git a/src/viem/transaction/getIncreaseLiquidityOptimalTx.ts b/src/viem/transaction/getIncreaseLiquidityOptimalTx.ts index bd6c2ce9..0d36c3cb 100644 --- a/src/viem/transaction/getIncreaseLiquidityOptimalTx.ts +++ b/src/viem/transaction/getIncreaseLiquidityOptimalTx.ts @@ -4,10 +4,7 @@ import { Currency, CurrencyAmount } from '@uniswap/sdk-core'; import { AutomatedMarketMakerEnum } from 'aperture-lens/dist/src/viem'; import { Address, Hex, PublicClient, TransactionRequest } from 'viem'; -import { - getAutomanIncreaseLiquidityOptimalCallData, - getAutomanV3IncreaseLiquidityOptimalCallData, -} from '../automan'; +import { getAutomanV4IncreaseLiquidityOptimalCallData } from '../automan'; import { getNativeCurrency } from '../currency'; import { PositionDetails } from '../position'; import { SimulatedAmounts } from './types'; @@ -24,86 +21,11 @@ import { SimulatedAmounts } from './types'; * @param swapData Swap data for the position. * @param liquidity The amount of liquidity to add to the existing position. * @param position The current position to simulate the call from. + * @param token0FeeAmount The token0 fee amount. + * @param token1FeeAmount The token1 fee amount. + * @returns The transaction request and the minimum amounts of token0 and token1 in the incremental position. */ -export async function getIncreaseLiquidityOptimalTx( - increaseOptions: IncreaseOptions, - chainId: ApertureSupportedChainId, - amm: AutomatedMarketMakerEnum, - token0Amount: CurrencyAmount, - token1Amount: CurrencyAmount, - from: Address, - publicClient: PublicClient, - swapData: Hex, - liquidity: bigint, - position?: Position, -): Promise<{ - tx: TransactionRequest; - amounts: SimulatedAmounts; -}> { - if (position === undefined) { - ({ position } = await PositionDetails.fromPositionId( - chainId, - amm, - BigInt(increaseOptions.tokenId.toString()), - publicClient, - )); - } - - let value: bigint | undefined; - if (token0Amount.currency.isNative) { - token0Amount = CurrencyAmount.fromRawAmount( - getNativeCurrency(chainId).wrapped, - token0Amount.quotient, - ); - value = BigInt(token0Amount.quotient.toString()); - } else if (token1Amount.currency.isNative) { - token1Amount = CurrencyAmount.fromRawAmount( - getNativeCurrency(chainId).wrapped, - token1Amount.quotient, - ); - value = BigInt(token1Amount.quotient.toString()); - } - - // Same as `position` except that the liquidity field represents the amount of liquidity to add to the existing `position`. - const incrementalPosition = new Position({ - pool: position.pool, - liquidity: liquidity.toString(), - tickLower: position.tickLower, - tickUpper: position.tickUpper, - }); - const { amount0, amount1 } = incrementalPosition.mintAmountsWithSlippage( - increaseOptions.slippageTolerance, - ); - const increaseParams = { - tokenId: BigInt(increaseOptions.tokenId.toString()), - amount0Desired: BigInt(token0Amount.quotient.toString()), - amount1Desired: BigInt(token1Amount.quotient.toString()), - amount0Min: BigInt(amount0.toString()), - amount1Min: BigInt(amount1.toString()), - deadline: BigInt(Math.floor(Date.now() / 1000 + 86400)), - }; - - const data = getAutomanIncreaseLiquidityOptimalCallData( - increaseParams, - swapData, - ); - - return { - tx: { - to: getAMMInfo(chainId, amm)!.apertureAutoman, - data, - value, - from, - }, - amounts: { - amount0Min: amount0.toString(), - amount1Min: amount1.toString(), - }, - }; -} - -// Same as getIncreaseLiquidityOptimalTx, but enables collecting feeAmount. -export async function getIncreaseLiquidityOptimalV3Tx( +export async function getIncreaseLiquidityOptimalV4Tx( increaseOptions: IncreaseOptions, chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, @@ -163,7 +85,7 @@ export async function getIncreaseLiquidityOptimalV3Tx( deadline: BigInt(Math.floor(Date.now() / 1000 + 86400)), }; - const data = getAutomanV3IncreaseLiquidityOptimalCallData( + const data = getAutomanV4IncreaseLiquidityOptimalCallData( increaseParams, swapData, token0FeeAmount, @@ -172,7 +94,7 @@ export async function getIncreaseLiquidityOptimalV3Tx( return { tx: { - to: getAMMInfo(chainId, amm)!.apertureAutomanV3, + to: getAMMInfo(chainId, amm)!.apertureAutomanV4, data, value, from, diff --git a/src/viem/transaction/getMintOptimalTx.ts b/src/viem/transaction/getMintOptimalTx.ts index 01518b7e..46d36c24 100644 --- a/src/viem/transaction/getMintOptimalTx.ts +++ b/src/viem/transaction/getMintOptimalTx.ts @@ -7,21 +7,20 @@ import { Address, Hex, PublicClient, TransactionRequest } from 'viem'; import { SlipStreamMintParams, UniV3MintParams, - getAutomanMintOptimalCalldata, - getAutomanV3MintOptimalCalldata, + getAutomanV4MintOptimalCalldata, } from '../automan'; import { getNativeCurrency } from '../currency'; import { getPool } from '../pool'; import { SimulatedAmounts } from './types'; -// TODO: add unit test /** * Generates an unsigned transaction that mints the optimal amount of liquidity for the specified token amounts and price range. + * Includes feeAmount and enables initilizing pool with sqrtPriceX96. * @param chainId The chain ID. * @param amm The Automated Market Maker. * @param token0Amount The token0 amount. * @param token1Amount The token1 amount. - * @param fee The pool fee tier. + * @param feeOrTickSpacing The pool fee tier or tick spacing. * @param tickLower The lower tick of the range. * @param tickUpper The upper tick of the range. * @param recipient The recipient address. @@ -30,106 +29,10 @@ import { SimulatedAmounts } from './types'; * @param publicClient Viem public client. * @param swapData Swap data for the position, returned by getRebalanceSwapInfo. * @param liquidity The amount of liquidity to mint. + * @param token0FeeAmount The token0 fee amount. + * @param token1FeeAmount The token1 fee amount. */ -export async function getMintOptimalTx( - chainId: ApertureSupportedChainId, - amm: AutomatedMarketMakerEnum, - token0Amount: CurrencyAmount, - token1Amount: CurrencyAmount, - feeOrTickSpacing: number, - tickLower: number, - tickUpper: number, - recipient: Address, - deadline: bigint, - slippage: number, - publicClient: PublicClient, - swapData: Hex, - liquidity: bigint, -): Promise<{ - tx: TransactionRequest; - amounts: SimulatedAmounts; -}> { - let value: bigint | undefined; - if (token0Amount.currency.isNative) { - token0Amount = CurrencyAmount.fromRawAmount( - getNativeCurrency(chainId).wrapped, - token0Amount.quotient, - ); - value = BigInt(token0Amount.quotient.toString()); - } else if (token1Amount.currency.isNative) { - token1Amount = CurrencyAmount.fromRawAmount( - getNativeCurrency(chainId).wrapped, - token1Amount.quotient, - ); - value = BigInt(token1Amount.quotient.toString()); - } - - const token0 = (token0Amount.currency as Token).address as Address; - const token1 = (token1Amount.currency as Token).address as Address; - const position = new Position({ - pool: await getPool( - token0, - token1, - feeOrTickSpacing, - chainId, - amm, - publicClient, - ), - liquidity: liquidity.toString(), - tickLower, - tickUpper, - }); - const { amount0, amount1 } = position.mintAmountsWithSlippage( - new Percent(Math.floor(slippage * 1e6), 1e6), - ); - const mintParams: SlipStreamMintParams | UniV3MintParams = - amm === AutomatedMarketMakerEnum.enum.SLIPSTREAM - ? { - token0, - token1, - tickSpacing: feeOrTickSpacing, - tickLower, - tickUpper, - amount0Desired: BigInt(token0Amount.quotient.toString()), - amount1Desired: BigInt(token1Amount.quotient.toString()), - amount0Min: BigInt(amount0.toString()), - amount1Min: BigInt(amount1.toString()), - recipient, - deadline, - sqrtPriceX96: 0n, - } - : { - token0, - token1, - fee: feeOrTickSpacing, - tickLower, - tickUpper, - amount0Desired: BigInt(token0Amount.quotient.toString()), - amount1Desired: BigInt(token1Amount.quotient.toString()), - amount0Min: BigInt(amount0.toString()), - amount1Min: BigInt(amount1.toString()), - recipient, - deadline, - }; - - const data = getAutomanMintOptimalCalldata(amm, mintParams, swapData); - - return { - tx: { - to: getAMMInfo(chainId, amm)!.apertureAutoman, - data, - value, - from: recipient, - }, - amounts: { - amount0Min: amount0.toString(), - amount1Min: amount1.toString(), - }, - }; -} - -// Same as getIncreaseLiquidityOptimalTx, but with feeAmount and enables initilizing pool with sqrtPriceX96. -export async function getMintOptimalV3Tx( +export async function getMintOptimalV4Tx( chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, token0Amount: CurrencyAmount, @@ -212,7 +115,7 @@ export async function getMintOptimalV3Tx( deadline, }; - const data = getAutomanV3MintOptimalCalldata( + const data = getAutomanV4MintOptimalCalldata( amm, mintParams, swapData, @@ -222,7 +125,7 @@ export async function getMintOptimalV3Tx( return { tx: { - to: getAMMInfo(chainId, amm)!.apertureAutomanV3, + to: getAMMInfo(chainId, amm)!.apertureAutomanV4, data, value, from: recipient, diff --git a/src/viem/transaction/getRebalanceTx.ts b/src/viem/transaction/getRebalanceTx.ts index 3b146d08..7d4666f3 100644 --- a/src/viem/transaction/getRebalanceTx.ts +++ b/src/viem/transaction/getRebalanceTx.ts @@ -8,7 +8,7 @@ import { SlipStreamMintParams, UniV3MintParams, getAutomanRebalanceCalldata, - getAutomanV3RebalanceCalldata, + getAutomanV4RebalanceCalldata, } from '../automan'; import { PositionDetails } from '../position'; import { SimulatedAmounts } from './types'; @@ -120,7 +120,7 @@ export async function getRebalanceTx( // Same as getRebalanceTx, but with feeAmounts instead of feeBips. // Do not use, but implemented to make it easier to migrate to future versions. -export async function getRebalanceV3Tx( +export async function getRebalanceV4Tx( chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, ownerAddress: Address, @@ -191,15 +191,15 @@ export async function getRebalanceV3Tx( return { tx: { from: ownerAddress, - to: getAMMInfo(chainId, amm)!.apertureAutomanV3, - data: getAutomanV3RebalanceCalldata( + to: getAMMInfo(chainId, amm)!.apertureAutomanV4, + data: getAutomanV4RebalanceCalldata( amm, mintParams, existingPositionId, token0FeeAmount, token1FeeAmount, - permitInfo, swapData, + permitInfo, ), }, amounts: { diff --git a/src/viem/transaction/getReinvestTx.ts b/src/viem/transaction/getReinvestTx.ts index 06b4e550..7a651e52 100644 --- a/src/viem/transaction/getReinvestTx.ts +++ b/src/viem/transaction/getReinvestTx.ts @@ -6,7 +6,7 @@ import { Address, Hex, TransactionRequest } from 'viem'; import { IncreaseLiquidityParams, getAutomanReinvestCalldata, - getAutomanV3ReinvestCalldata, + getAutomanV4ReinvestCalldata, } from '../automan'; /** @@ -14,9 +14,11 @@ import { * @param chainId Chain id. * @param amm Automated Market Maker. * @param ownerAddress Owner of the specified position. - * @param slippageTolerance How much the reinvested amount of either token0 or token1 is allowed to change unfavorably. - * @param deadlineEpochSeconds Timestamp when the tx expires (in seconds since epoch). - * @param client Public client. + * @param increaseOptions Increase liquidity options. + * @param feeBips The Aperture fee for the transaction. + * @param swapData The swap data if using a router. + * @param amount0Min The minimum amount of token0 reinvested. + * @param amount1Min The minimum amount of token1 reinvested. * @param permitInfo Optional. If Automan doesn't already have authority over the existing position, this should be populated with a valid owner-signed permit info. * @returns The generated transaction request and expected amounts. */ @@ -53,7 +55,7 @@ export async function getReinvestTx( // Same as getReinvestTx, but with feeAmounts instead of feeBips. // Don't have to use, but implemented to make it easier to migrate to future versions. -export async function getReinvestV3Tx( +export async function getReinvestV4Tx( chainId: ApertureSupportedChainId, amm: AutomatedMarketMakerEnum, ownerAddress: Address, @@ -75,8 +77,8 @@ export async function getReinvestV3Tx( }; return { from: ownerAddress, - to: getAMMInfo(chainId, amm)!.apertureAutomanV3, - data: getAutomanV3ReinvestCalldata( + to: getAMMInfo(chainId, amm)!.apertureAutomanV4, + data: getAutomanV4ReinvestCalldata( increaseLiquidityParams, token0FeeAmount, token1FeeAmount, diff --git a/src/viem/transaction/index.ts b/src/viem/transaction/index.ts index 4865718f..15c1bd5c 100644 --- a/src/viem/transaction/index.ts +++ b/src/viem/transaction/index.ts @@ -1,5 +1,6 @@ export * from './getAddLiquidityTxs'; export * from './getCollectTx'; +export * from './getDecreaseLiquiditySingleTx'; export * from './getIncreaseLiquidityOptimalTx'; export * from './getMMVaultTx'; export * from './getMintOptimalTx'; diff --git a/test/hardhat/hardhat.test.ts b/test/hardhat/hardhat.test.ts index 7fa29071..9328277b 100644 --- a/test/hardhat/hardhat.test.ts +++ b/test/hardhat/hardhat.test.ts @@ -36,7 +36,9 @@ import { mainnet } from 'viem/chains'; import { ActionTypeEnum, ApertureSupportedChainId, + ConsoleLogger, IERC20__factory, + IOCKEY_LOGGER, MAX_PRICE, MIN_PRICE, Q192, @@ -60,6 +62,7 @@ import { getTokenPriceListFromCoingeckoWithAddresses, getTokenPriceListFromGeckoTerminalWithAddresses, humanPriceToClosestTick, + ioc, normalizeTicks, priceToClosestUsableTick, priceToSqrtRatioX96, @@ -76,8 +79,8 @@ import { estimateReinvestGas, generateAccessList, getERC20Overrides, - getIncreaseLiquidityOptimalSwapInfo, - getMintOptimalSwapInfo, + getIncreaseLiquidityOptimalSwapInfoV4, + getMintOptimalSwapInfoV4, getMintedPositionIdFromTxReceipt, getNPM, getPool, @@ -88,8 +91,8 @@ import { getSlipStreamPools, getSlipStreamStakePositions, getToken, - simulateIncreaseLiquidityOptimal, - simulateMintOptimal, + simulateIncreaseLiquidityOptimalV4, + simulateMintOptimalV4, simulateRemoveLiquidity, } from '../../src/viem'; import { @@ -322,8 +325,9 @@ describe('State overrides tests', function () { }); }); - it('Test simulateMintOptimal', async function () { - const blockNumber = 17975698n; + it('Test simulateMintOptimalV4', async function () { + // blockNumber needs to be after automanV4 was deployed. + const blockNumber = 21500000n; const publicClient = getApiClient(); const token0 = WBTC_ADDRESS; const token1 = WETH_ADDRESS; @@ -359,18 +363,20 @@ describe('State overrides tests', function () { deadline: BigInt(Math.floor(Date.now() / 1000 + 60 * 30)), }; - const [, liquidity, amount0, amount1] = await simulateMintOptimal( + const [, liquidity, amount0, amount1] = await simulateMintOptimalV4( chainId, UNIV3_AMM, publicClient, eoa, mintParams, - undefined, + /* swapData= */ undefined, + /* token0FeeAmount= */ 0n, + /* token1FeeAmount= */ 0n, blockNumber, ); - expect(liquidity.toString()).to.equal('716894157038546'); - expect(amount0.toString()).to.equal('51320357'); - expect(amount1.toString()).to.equal('8736560293857784398'); + expect(liquidity.toString()).to.equal('930120410912217'); + expect(amount0.toString()).to.equal('52799510'); + expect(amount1.toString()).to.equal('14303795769964736798'); }); it('Test simulateRemoveLiquidity', async function () { @@ -400,8 +406,9 @@ describe('State overrides tests', function () { expect(amount1.toString()).to.equal('3098315727923109118'); }); - it('Test simulateIncreaseLiquidityOptimal', async function () { - const blockNumber = 17975698n; + it('Test simulateIncreaseLiquidityOptimalV4', async function () { + // blockNumber needs to be after automanV4 was deployed. + const blockNumber = 21500000n; const positionId = 4n; const publicClient = getApiClient(); const amount0Desired = 100000000n; @@ -422,18 +429,20 @@ describe('State overrides tests', function () { deadline: BigInt(Math.floor(Date.now() / 1000 + 60 * 30)), }; - const [, amount0, amount1] = await simulateIncreaseLiquidityOptimal( + const [, amount0, amount1] = await simulateIncreaseLiquidityOptimalV4( chainId, UNIV3_AMM, publicClient, eoa as Address, position, increaseParams, - undefined, + /* swapData= */ undefined, + /* token0FeeAmount= */ 0n, + /* token1FeeAmount= */ 0n, blockNumber, ); - expect(amount0.toString()).to.equal('61259538'); - expect(amount1.toString()).to.equal('7156958298534991565'); + expect(amount0.toString()).to.equal('10317345'); + expect(amount1.toString()).to.equal('26271362832753520405'); }); }); @@ -863,9 +872,12 @@ describe('Viem - Automan transaction tests', function () { const automanAddress = getAMMInfo(chainId, amm)!.apertureAutoman; beforeEach(async function () { + ioc.registerSingleton(IOCKEY_LOGGER, ConsoleLogger); testClient = await hre.viem.getTestClient(); publicClient = await hre.viem.getPublicClient(); - await resetFork(testClient); + // blockNumber needs to be after automanV4 was deployed. + const blockNumber = 21500000n; + await resetFork(testClient, blockNumber); // Without this, Hardhat throws an InvalidInputError saying that WHALE_ADDRESS is an unknown account. // Likely a Hardhat bug. @@ -1026,13 +1038,13 @@ describe('Viem - Automan transaction tests', function () { token0: existingPosition.pool.token0, token1: existingPosition.pool.token1, fee: existingPosition.pool.fee, - liquidity: '13324132541941', + liquidity: '12798820775744', tickLower: 240000, tickUpper: 300000, }); }); - it('Optimal mint no need swap', async function () { + it('mintOptimalV4 no need swap', async function () { const pool = await getPool( WBTC_ADDRESS, WETH_ADDRESS, @@ -1066,7 +1078,7 @@ describe('Viem - Automan transaction tests', function () { ); const { swapRoute } = ( - await getMintOptimalSwapInfo( + await getMintOptimalSwapInfoV4( chainId, UNIV3_AMM, hypotheticalPosition.amount0, @@ -1075,7 +1087,8 @@ describe('Viem - Automan transaction tests', function () { tickLower, tickUpper, eoa, - 0.5, + /* slippage= */ 0.5, + /* tokenPricesUsd= */ ['60000', '3000'], publicClient, [E_Solver.SamePool], ) @@ -1084,7 +1097,7 @@ describe('Viem - Automan transaction tests', function () { expect(swapRoute?.length).to.equal(0); }); - it('Optimal mint with swap', async function () { + it('mintOptimalV4 with swap', async function () { const pool = await getPool( WBTC_ADDRESS, WETH_ADDRESS, @@ -1117,11 +1130,11 @@ describe('Viem - Automan transaction tests', function () { BigInt(token0Amount.quotient.toString()), BigInt(token1Amount.quotient.toString()), eoa, - getAMMInfo(chainId, UNIV3_AMM)!.apertureAutoman, + getAMMInfo(chainId, UNIV3_AMM)!.apertureAutomanV4, ); const { swapPath, swapRoute } = ( - await getMintOptimalSwapInfo( + await getMintOptimalSwapInfoV4( chainId, UNIV3_AMM, token0Amount, @@ -1130,7 +1143,8 @@ describe('Viem - Automan transaction tests', function () { tickLower, tickUpper, eoa, - 0.5, + /* slippage= */ 0.5, + /* tokenPricesUsd= */ ['60000', '3000'], publicClient, [E_Solver.SamePool], ) @@ -1173,7 +1187,7 @@ describe('Viem - Automan transaction tests', function () { ); const { swapRoute } = ( - await getIncreaseLiquidityOptimalSwapInfo( + await getIncreaseLiquidityOptimalSwapInfoV4( { tokenId: positionId, slippageTolerance: new Percent(5, 1000), @@ -1184,6 +1198,7 @@ describe('Viem - Automan transaction tests', function () { hypotheticalPosition.amount0, hypotheticalPosition.amount1, eoa as Address, + /* tokenPricesUsd= */ ['60000', '3000'], publicClient, [E_Solver.SamePool], hypotheticalPosition, diff --git a/test/hardhat/viem/pcsv3-automan-transaction.test.ts b/test/hardhat/viem/pcsv3-automan-transaction.test.ts index f61fb311..c411fbad 100644 --- a/test/hardhat/viem/pcsv3-automan-transaction.test.ts +++ b/test/hardhat/viem/pcsv3-automan-transaction.test.ts @@ -1,3 +1,4 @@ +// yarn test:hardhat test/hardhat/viem/pcsv3-automan-transaction.test.ts import { FeeAmount, nearestUsableTick } from '@aperture_finance/uniswap-v3-sdk'; import { CurrencyAmount, Percent } from '@uniswap/sdk-core'; import { AutomatedMarketMakerEnum } from 'aperture-lens/dist/src/viem'; @@ -38,7 +39,6 @@ import { getIncreaseLiquidityOptimalSwapInfo, getIncreaseLiquidityOptimalTx, getMintOptimalSwapInfo, - getMintOptimalTx, getMintedPositionIdFromTxReceipt, getPool, getRebalanceSwapInfo, @@ -50,6 +50,7 @@ import { expect, hardhatForkProvider, resetFork } from '../common'; // Tests for PCSV3Automan transactions on a forked BNB mainnet. describe('Viem - PCSV3Automan transaction tests', function () { const amm = AutomatedMarketMakerEnum.enum.PANCAKESWAP_V3; + const chainId = ApertureSupportedChainId.BNB_MAINNET_CHAIN_ID; const WHALE_ADDRESS = '0x8894E0a0c962CB723c1976a4421c95949bE2D4E3'; const positionId = 528336n; const blockNumber = 37287100n; @@ -57,14 +58,13 @@ describe('Viem - PCSV3Automan transaction tests', function () { const WETH_ADDRESS = '0x2170Ed0880ac9A755fd29B2688956BD959F933F8'; const WBTC_ADDRESS = '0x7130d2A12B9BCbFAe4f2634d864A1Ee1Ce3Ead9c'; - const chainId = ApertureSupportedChainId.BNB_MAINNET_CHAIN_ID; let automanContract: PCSV3Automan; const automanAddress = getAMMInfo(chainId, amm)!.apertureAutoman; + const feeCollector = WHALE_ADDRESS; let testClient: TestClient; let publicClient: PublicClient; let impersonatedOwnerClient: WalletClient; - ioc.registerSingleton(IOCKEY_LOGGER, ConsoleLogger); const nonForkClient = createPublicClient({ chain: bsc, @@ -91,7 +91,7 @@ describe('Viem - PCSV3Automan transaction tests', function () { ); await automanContract.deployed(); await automanContract.setFeeConfig({ - feeCollector: WHALE_ADDRESS, + feeCollector, // Set the max fee deduction to 50%. feeLimitPips: BigInt('500000000000000000'), }); @@ -238,7 +238,7 @@ describe('Viem - PCSV3Automan transaction tests', function () { /* newPositionTickLower= */ 240000, /* newPositionTickUpper= */ 300000, /* slippageTolerance= */ 0.01, - /* tokenPricesUsd= */ ['60000', '3000'], + /* tokenPricesUsd= */ ['1', '700'], // BSC-USD / WBNB publicClient, [E_Solver.SamePool], existingPosition, @@ -293,7 +293,8 @@ describe('Viem - PCSV3Automan transaction tests', function () { }); }); - it('Optimal mint without 1inch', async function () { + // Test deprecated and moved to pcsv3-automanV4-transaction.test.ts. + it.skip('Optimal mint without 1inch', async function () { const pool = await getPool( WBTC_ADDRESS, WETH_ADDRESS, @@ -341,7 +342,7 @@ describe('Viem - PCSV3Automan transaction tests', function () { [E_Solver.SamePool], ) )[0]; - const { tx: txRequest } = await getMintOptimalTx( + const { tx: txRequest } = await getMintOptimal( chainId, amm, token0Amount, @@ -390,7 +391,8 @@ describe('Viem - PCSV3Automan transaction tests', function () { }); }); - it('Increase liquidity optimal without 1inch', async function () { + // Test deprecated and moved to pcsv3-automanV4-transaction.test.ts. + it.skip('Increase liquidity optimal without 1inch', async function () { const existingPosition = await PositionDetails.fromPositionId( chainId, amm, diff --git a/test/hardhat/viem/pcsv3-automanV4-transaction.test.ts b/test/hardhat/viem/pcsv3-automanV4-transaction.test.ts new file mode 100644 index 00000000..74afb04d --- /dev/null +++ b/test/hardhat/viem/pcsv3-automanV4-transaction.test.ts @@ -0,0 +1,482 @@ +// yarn test:hardhat test/hardhat/viem/pcsv3-automanV4-transaction.test.ts +import { FeeAmount, nearestUsableTick } from '@aperture_finance/uniswap-v3-sdk'; +import { CurrencyAmount, Percent } from '@uniswap/sdk-core'; +import { AutomatedMarketMakerEnum } from 'aperture-lens/dist/src/viem'; +import hre, { ethers } from 'hardhat'; +import { + Address, + PublicClient, + TestClient, + WalletClient, + createPublicClient, + encodeAbiParameters, + http, + parseAbiParameters, + parseEther, + walletActions, +} from 'viem'; +import { bsc, mainnet } from 'viem/chains'; + +import { + ActionTypeEnum, + ApertureSupportedChainId, + ConditionTypeEnum, + ConsoleLogger, + ICommonNonfungiblePositionManager__factory, + IOCKEY_LOGGER, + PCSV3AutomanV4, + PCSV3AutomanV4__factory, + UniV3OptimalSwapRouter__factory, + getAMMInfo, + ioc, +} from '../../../src'; +import { + E_Solver, + PositionDetails, + generateAutoCompoundRequestPayload, + getBasicPositionInfo, + getERC20Overrides, + getIncreaseLiquidityOptimalSwapInfoV4, + getIncreaseLiquidityOptimalV4Tx, + getMintOptimalSwapInfoV4, + getMintOptimalV4Tx, + getMintedPositionIdFromTxReceipt, + getPool, + getRebalanceSwapInfoV4, + getRebalanceV4Tx, + getReinvestV4Tx, +} from '../../../src/viem'; +import { expect, hardhatForkProvider, resetFork } from '../common'; + +// Tests for PCSV3AutomanV4 transactions on a forked BNB mainnet. +describe('Viem - PCSV3AutomanV4 transaction tests', function () { + const amm = AutomatedMarketMakerEnum.enum.PANCAKESWAP_V3; + const chainId = ApertureSupportedChainId.BNB_MAINNET_CHAIN_ID; + const WHALE_ADDRESS = '0x8894E0a0c962CB723c1976a4421c95949bE2D4E3'; + const positionId = 528336n; + const blockNumber = 37287100n; + const eoa = '0x4B104b883104d17E618d84f766d0be06F6F6f486'; + + const WETH_ADDRESS = '0x2170Ed0880ac9A755fd29B2688956BD959F933F8'; + const WBTC_ADDRESS = '0x7130d2A12B9BCbFAe4f2634d864A1Ee1Ce3Ead9c'; + + let automanV4Contract: PCSV3AutomanV4; + const automanV4Address = getAMMInfo(chainId, amm)!.apertureAutomanV4; + const feeCollector = WHALE_ADDRESS; + let testClient: TestClient; + let publicClient: PublicClient; + let impersonatedOwnerClient: WalletClient; + ioc.registerSingleton(IOCKEY_LOGGER, ConsoleLogger); + const nonForkClient = createPublicClient({ + chain: bsc, + transport: http('https://bsc-rpc.publicnode.com'), + }); + + beforeEach(async function () { + testClient = await hre.viem.getTestClient(); + publicClient = await hre.viem.getPublicClient(); + + await resetFork(testClient, blockNumber, chainId); + await testClient.impersonateAccount({ + address: eoa, + }); + impersonatedOwnerClient = testClient.extend(walletActions); + + // Deploy AutomanV4. + automanV4Contract = await new PCSV3AutomanV4__factory( + // TODO: migrate ethers + await ethers.getImpersonatedSigner(WHALE_ADDRESS), + ).deploy( + getAMMInfo(chainId, amm)!.nonfungiblePositionManager, + /*owner=*/ WHALE_ADDRESS, + ); + await automanV4Contract.deployed(); + await automanV4Contract.setFeeConfig({ + feeCollector, + // Set the max fee deduction to 50%. + feeLimitPips: BigInt('500000000000000000'), + }); + await automanV4Contract.setControllers([WHALE_ADDRESS], [true]); + const router = await new UniV3OptimalSwapRouter__factory( + await ethers.getImpersonatedSigner(WHALE_ADDRESS), + ).deploy(getAMMInfo(chainId, amm)!.nonfungiblePositionManager); + await router.deployed(); + await automanV4Contract.setAllowlistedRouters([router.address], [true]); + + // Set AutomanV4 address in CHAIN_ID_TO_INFO. + getAMMInfo(chainId, amm)!.apertureAutomanV4 = + automanV4Contract.address as `0x${string}`; + getAMMInfo(chainId, amm)!.optimalSwapRouter = + router.address as `0x${string}`; + + // Owner of position id 528336 sets AutomanV4 as operator. + const { request } = await publicClient.simulateContract({ + abi: ICommonNonfungiblePositionManager__factory.abi, + address: getAMMInfo(chainId, amm)!.nonfungiblePositionManager, + functionName: 'setApprovalForAll', + args: [automanV4Contract.address as Address, true] as const, + account: eoa, + }); + + await testClient.setBalance({ + address: eoa, + value: parseEther('1'), + }); + + await impersonatedOwnerClient.writeContract(request); + }); + + after(() => { + // Reset AutomanV4 address in CHAIN_ID_TO_INFO. + getAMMInfo(chainId, amm)!.apertureAutomanV4 = automanV4Address; + testClient.stopImpersonatingAccount({ + address: eoa, + }); + }); + + async function dealERC20( + token0: Address, + token1: Address, + amount0: bigint, + amount1: bigint, + from: Address, + to: Address, + ) { + const [token0Overrides, token1Overrides] = await Promise.all([ + getERC20Overrides(token0, from, to, amount0, nonForkClient), + getERC20Overrides(token1, from, to, amount1, nonForkClient), + ]); + for (const slot of Object.keys(token0Overrides[token0].stateDiff!)) { + await hardhatForkProvider.send('hardhat_setStorageAt', [ + token0, + slot, + encodeAbiParameters(parseAbiParameters('uint256'), [amount0]), + ]); + } + for (const slot of Object.keys(token1Overrides[token1].stateDiff!)) { + await hardhatForkProvider.send('hardhat_setStorageAt', [ + token1, + slot, + encodeAbiParameters(parseAbiParameters('uint256'), [amount1]), + ]); + } + } + + it('Reinvest', async function () { + const liquidityBeforeReinvest = ( + await getBasicPositionInfo(chainId, amm, positionId, publicClient) + ).liquidity!; + expect(liquidityBeforeReinvest.toString()).to.equal('17360687214921889114'); + + const txRequest = await getReinvestV4Tx( + chainId, + amm, + eoa, + /* increaseOptions= */ { + tokenId: positionId.toString(), + slippageTolerance: new Percent(1, 100), + deadline: Math.floor(Date.now() / 1000), + }, + /* token0FeeAmount= */ 0n, + /* token1FeeAmount= */ 0n, + /* swapData= */ '0x', + /* amount0Min= */ 0n, + /* amount1Min= */ 0n, + ); + + await impersonatedOwnerClient.sendTransaction({ + ...txRequest, + account: eoa, + chain: mainnet, + }); + + const liquidityAfterReinvest = ( + await getBasicPositionInfo(chainId, amm, positionId, publicClient) + ).liquidity!; + expect(liquidityAfterReinvest.toString()).to.equal('17369508569204326673'); + + expect( + generateAutoCompoundRequestPayload( + eoa, + chainId, + AutomatedMarketMakerEnum.enum.PANCAKESWAP_V3, + positionId.toString(), + /* feeToPrincipalRatioThreshold= */ 0.1, + /* slippage= */ 0.05, + /* maxGasProportion= */ 0.01, + 1627776000, + ), + ).to.deep.equal({ + action: { + maxGasProportion: 0.01, + slippage: 0.05, + type: ActionTypeEnum.enum.Reinvest, + }, + chainId: chainId, + amm: AutomatedMarketMakerEnum.enum.PANCAKESWAP_V3, + condition: { + feeToPrincipalRatioThreshold: 0.1, + type: ConditionTypeEnum.enum.AccruedFees, + }, + nftId: positionId.toString(), + ownerAddr: eoa, + expiration: 1627776000, + }); + }); + + it('Rebalance', async function () { + const existingPosition = await PositionDetails.fromPositionId( + chainId, + amm, + positionId, + publicClient, + ); + const { swapData, liquidity } = ( + await getRebalanceSwapInfoV4( + chainId, + amm, + publicClient, + eoa, + existingPosition, + /* newPositionTickLower= */ 240000, + /* newPositionTickUpper= */ 300000, + /* slippageTolerance= */ 0.01, + /* tokenPricesUsd= */ ['1', '700'], // BSC-USD / WBNB + [E_Solver.SamePool], + ) + )[0]; + const { tx: txRequest } = await getRebalanceV4Tx( + chainId, + amm, + eoa, + positionId, + /* newPositionTickLower= */ 240000, + /* newPositionTickUpper= */ 300000, + /* slippageTolerance= */ new Percent(1, 100), + /* deadlineEpochSeconds= */ BigInt(Math.floor(Date.now() / 1000)), + publicClient, + swapData, + liquidity, + /* token0FeeAmount= */ 0n, + /* token1FeeAmount= */ 0n, + existingPosition.position, + ); + // Owner of position id 4 sets AutomanV4 as operator. + await testClient.impersonateAccount({ address: eoa }); + const walletClient = testClient.extend(walletActions); + const txHash = await walletClient.sendTransaction({ + to: txRequest.to, + data: txRequest.data, + account: txRequest.from, + // from: txRequest.from, + chain: walletClient.chain, + }); + const txReceipt = await publicClient.getTransactionReceipt({ + hash: txHash, + }); + const newPositionId = getMintedPositionIdFromTxReceipt( + chainId, + amm, + txReceipt, + eoa, + )!; + expect( + await getBasicPositionInfo(chainId, amm, newPositionId, publicClient), + ).to.deep.equal({ + token0: existingPosition.pool.token0, + token1: existingPosition.pool.token1, + fee: existingPosition.pool.fee, + tickSpacing: 10, + liquidity: '15250213564999769681912914', + tickLower: 240000, + tickUpper: 300000, + }); + }); + + it('Optimal mint without 1inch', async function () { + const pool = await getPool( + WBTC_ADDRESS, + WETH_ADDRESS, + FeeAmount.PCS_V3_MEDIUM, + chainId, + amm, + publicClient, + ); + const token0Amount = CurrencyAmount.fromRawAmount( + pool.token0, + '1000000000', + ); + const token1Amount = CurrencyAmount.fromRawAmount( + pool.token1, + '1000000000000000000', + ); + await dealERC20( + pool.token0.address as Address, + pool.token1.address as Address, + BigInt(token0Amount.quotient.toString()), + BigInt(token1Amount.quotient.toString()), + eoa, + getAMMInfo(chainId, amm)!.apertureAutomanV4, + ); + const tickLower = nearestUsableTick( + pool.tickCurrent - 1000, + pool.tickSpacing, + ); + const tickUpper = nearestUsableTick( + pool.tickCurrent + 1000, + pool.tickSpacing, + ); + const { swapData, liquidity } = ( + await getMintOptimalSwapInfoV4( + chainId, + amm, + token0Amount, + token1Amount, + pool.fee, + tickLower, + tickUpper, + eoa, + /* slippage= */ 0.5, + /* tokenPricesUsd= */ ['3000', '60000'], + publicClient, + [E_Solver.SamePool], + ) + )[0]; + const { tx: txRequest } = await getMintOptimalV4Tx( + chainId, + amm, + token0Amount, + token1Amount, + pool.fee, + tickLower, + tickUpper, + eoa, + /* deadlineEpochSeconds= */ BigInt(Math.floor(Date.now() / 1000)), + /* slippage= */ 0.5, + publicClient, + swapData, + liquidity, + ); + // Owner of position id 4 sets AutomanV4 as operator. + await testClient.impersonateAccount({ address: eoa }); + const walletClient = testClient.extend(walletActions); + const txHash = await walletClient.sendTransaction({ + to: txRequest.to, + data: txRequest.data, + account: txRequest.from, + // from: txRequest.from, + chain: walletClient.chain, + }); + const txReceipt = await publicClient.getTransactionReceipt({ + hash: txHash, + }); + const newPositionId = getMintedPositionIdFromTxReceipt( + chainId, + amm, + txReceipt, + eoa, + )!; + const newPosition = await getBasicPositionInfo( + chainId, + amm, + newPositionId, + publicClient, + ); + expect(newPosition).to.deep.contains({ + token0: pool.token0, + token1: pool.token1, + fee: pool.fee, + tickLower, + tickUpper, + }); + }); + + it('Increase liquidity optimal without 1inch', async function () { + const existingPosition = await PositionDetails.fromPositionId( + chainId, + amm, + positionId, + publicClient, + ); + const pool = existingPosition.pool; + const token0Amount = CurrencyAmount.fromRawAmount( + pool.token0, + '1000000000', + ); + const token1Amount = CurrencyAmount.fromRawAmount( + pool.token1, + '1000000000000000000', + ); + await dealERC20( + pool.token0.address as Address, + pool.token1.address as Address, + BigInt(token0Amount.quotient.toString()), + BigInt(token1Amount.quotient.toString()), + eoa, + getAMMInfo(chainId, amm)!.apertureAutomanV4, + ); + const { swapData, liquidity } = ( + await getIncreaseLiquidityOptimalSwapInfoV4( + { + tokenId: Number(positionId), + slippageTolerance: new Percent(5, 1000), + deadline: Math.floor(Date.now() / 1000 + 60 * 30), + }, + chainId, + amm, + token0Amount, + token1Amount, + eoa, + /* tokenPricesUsd= */ ['1', '700'], // BSC-USD / WBNB + publicClient, + [E_Solver.SamePool], + existingPosition.position, + ) + )[0]; + const { tx: txRequest } = await getIncreaseLiquidityOptimalV4Tx( + { + tokenId: Number(positionId), + slippageTolerance: new Percent(50, 100), + deadline: Math.floor(Date.now() / 1000 + 60 * 30), + }, + chainId, + amm, + token0Amount, + token1Amount, + eoa, + publicClient, + swapData, + liquidity, + existingPosition.position, + ); + + // Owner of position id 4 sets AutomanV4 as operator. + await testClient.impersonateAccount({ address: eoa }); + const walletClient = testClient.extend(walletActions); + const txHash = await walletClient.sendTransaction({ + to: txRequest.to, + data: txRequest.data, + account: txRequest.from, + // from: txRequest.from, + chain: walletClient.chain, + }); + await publicClient.getTransactionReceipt({ + hash: txHash, + }); + const newPosition = await getBasicPositionInfo( + chainId, + amm, + positionId, + publicClient, + ); + expect(newPosition).to.deep.contains({ + token0: pool.token0, + token1: pool.token1, + fee: pool.fee, + tickLower: existingPosition.tickLower, + tickUpper: existingPosition.tickUpper, + }); + }); + + // TODO: Add tests for rebalance, mintOptimal and increaseLiquidityOptimal with 1inch. +}); diff --git a/test/hardhat/viem/routing.test.ts b/test/hardhat/viem/routing.test.ts index d477b64f..3faf417c 100644 --- a/test/hardhat/viem/routing.test.ts +++ b/test/hardhat/viem/routing.test.ts @@ -1,3 +1,4 @@ +// yarn test:hardhat test/hardhat/viem/routing.test.ts import { FeeAmount, nearestUsableTick } from '@aperture_finance/uniswap-v3-sdk'; import '@nomicfoundation/hardhat-viem'; import { Percent } from '@uniswap/sdk-core'; @@ -7,9 +8,12 @@ import { parseEther } from 'viem'; import { ApertureSupportedChainId, + ConsoleLogger, + IOCKEY_LOGGER, UniswapSupportedChainId, WBTC_ARBITRUM_ONE, WRAPPED_NATIVE_CURRENCY, + ioc, } from '../../../src'; import { E_Solver, @@ -22,9 +26,8 @@ import { getPublicClient, getRebalancedPosition, getToken, - increaseLiquidityOptimal, - mintOptimal, - mintOptimalV2, + increaseLiquidityOptimalV4, + mintOptimalV4, rebalanceOptimalV2, } from '../../../src/viem'; import { @@ -37,6 +40,8 @@ import { } from '../common'; describe('Viem - Routing tests', function () { + ioc.registerSingleton(IOCKEY_LOGGER, ConsoleLogger); + // rebalanceOptimal is deprecated now, use rebalanceOptimalV2 instead it.skip('Test rebalanceOptimal', async function () { const chainId = ApertureSupportedChainId.ARBITRUM_MAINNET_CHAIN_ID; @@ -210,7 +215,7 @@ describe('Viem - Routing tests', function () { expect(Number(resultV2[i].liquidity.toString())).to.be.greaterThan(0); // The fees depends on poolAmountIn, which varies depending on solver results, // so adjust the tolerance accordingly. - expect(Number(resultV2[i].feeUSD)).to.be.closeTo(0.205, 0.017); // swap ~3.8 USDC, reinvest ~$1.62, and FEE_REBALANCE_USD, totalFeeUsd=0.2055 + expect(Number(resultV2[i].feeUSD)).to.be.closeTo(0.225, 0.02); // swap ~3.8 USDC, reinvest ~$1.62, and FEE_REBALANCE_USD, totalFeeUsd=0.2055 expect(Number(resultV2[i].feeBips) / 1e18).to.be.closeTo(0.023, 0.005); // position $8.87, bips 0.205/8.87 = ~0.023 expect(resultV2[i].swapData!).to.be.not.empty; @@ -272,11 +277,12 @@ describe('Viem - Routing tests', function () { } }); - it('Test increaseLiquidityOptimal with pool', async function () { + it('Test increaseLiquidityOptimalV4 with pool', async function () { const chainId = ApertureSupportedChainId.ETHEREUM_MAINNET_CHAIN_ID; const amm = AutomatedMarketMakerEnum.enum.UNISWAP_V3; const publicClient = getApiClient(chainId); - const blockNumber = 19866218n; + // blockNumber needs to be after automanV4 was deployed. + const blockNumber = 21500000n; const { position, pool } = await PositionDetails.fromPositionId( chainId, @@ -295,8 +301,8 @@ describe('Viem - Routing tests', function () { '1000000000000000000', ); - const { amount0, amount1, priceImpact, swapPath } = - await increaseLiquidityOptimal( + const { amount0, amount1, priceImpact, swapPath } = ( + await increaseLiquidityOptimalV4( chainId, amm, publicClient, @@ -309,10 +315,11 @@ describe('Viem - Routing tests', function () { token0Amount, token1Amount, eoa, - /* usePool= */ true, // don't use 1inch in unit test + /* tokenPricesUsd= */ ['60000', '3000'], + /* includeSolvers= */ [E_Solver.SamePool], // don't use 1inch in unit test blockNumber, - /* includeSwapInfo= */ true, - ); + ) + )[0]; const _total = Number( pool.token0Price @@ -326,13 +333,16 @@ describe('Viem - Routing tests', function () { expect(_total).to.be.closeTo(total, total * 0.03); - expect(Number(priceImpact!.toString())).to.be.closeTo(0.2224, 0.01); + expect(Number(priceImpact!.toString())).to.be.closeTo( + 0.36468586252015095, + 0.01, + ); expect(swapPath!.tokenIn).to.equal(pool.token0.address); expect(swapPath!.tokenOut).to.equal(pool.token1.address); }); - // mintOptimal is deprecated now, use mintOptimalV2 instead + // mintOptimal is deprecated now, use mintOptimalV4 instead it.skip('Test mintOptimal', async function () { const chainId = ApertureSupportedChainId.ARBITRUM_MAINNET_CHAIN_ID; const amm = AutomatedMarketMakerEnum.enum.UNISWAP_V3; @@ -403,7 +413,7 @@ describe('Viem - Routing tests', function () { }); // can pass when run alone, but fail when run with other tests, skip it currently - it.skip('Test mintOptimalV2 in mainnet', async function () { + it.skip('Test mintOptimalV4 in mainnet', async function () { const tokenId = 4n; const chainId = ApertureSupportedChainId.ETHEREUM_MAINNET_CHAIN_ID; const amm = AutomatedMarketMakerEnum.enum.UNISWAP_V3; @@ -435,7 +445,7 @@ describe('Viem - Routing tests', function () { ); const fee = FeeAmount.MEDIUM; - const resultV2 = await mintOptimalV2( + const resultV2 = await mintOptimalV4( chainId, amm, token0Amount, @@ -477,7 +487,7 @@ describe('Viem - Routing tests', function () { } }); - it('Test mintOptimalV2 in arbitrum', async function () { + it('Test mintOptimalV4 in arbitrum', async function () { const chainId = ApertureSupportedChainId.ARBITRUM_MAINNET_CHAIN_ID; const amm = AutomatedMarketMakerEnum.enum.UNISWAP_V3; const publicClient = getApiClient(chainId); @@ -514,7 +524,7 @@ describe('Viem - Routing tests', function () { pool.tickCurrent + 10 * pool.tickSpacing, pool.tickSpacing, ); - const resultV2 = await mintOptimalV2( + const resultV4 = await mintOptimalV4( chainId, amm, token0Amount, @@ -524,11 +534,12 @@ describe('Viem - Routing tests', function () { tickUpper, eoa, 0.1, + ['60000', '3000'], publicClient, blockNumber, ); - expect(resultV2.map((r) => r.solver)).to.be.not.include(E_Solver.PH); // should not include PH + expect(resultV4.map((r) => r.solver)).to.be.not.include(E_Solver.PH); // should not include PH }); it('Fetch quote swapping 1 ETH for USDC on mainnet', async function () { diff --git a/test/hardhat/viem/slipstream-automan-transaction.test.ts b/test/hardhat/viem/slipstream-automan-transaction.test.ts index e75ae936..6431335a 100644 --- a/test/hardhat/viem/slipstream-automan-transaction.test.ts +++ b/test/hardhat/viem/slipstream-automan-transaction.test.ts @@ -36,10 +36,7 @@ import { generateAutoCompoundRequestPayload, getBasicPositionInfo, getERC20Overrides, - getIncreaseLiquidityOptimalSwapInfo, - getIncreaseLiquidityOptimalTx, - getMintOptimalSwapInfo, - getMintOptimalTx, + getMintOptimalSwapInfoV4, getMintedPositionIdFromTxReceipt, getPool, getRebalanceSwapInfo, @@ -358,7 +355,8 @@ describe('SlipStreamAutoman transaction tests', function () { }); }); - it('Optimal mint without 1inch', async function () { + // Test deprecated and moved to slipstream-automanV4-transaction.test.ts. + it.skip('Optimal mint without 1inch', async function () { const pool = await getPool( '0x4200000000000000000000000000000000000006', // WETH on Base mainnet, '0x940181a94A35A4569E4529A3CDfB74e38FD98631', // AERO on Base mainnet, @@ -393,7 +391,7 @@ describe('SlipStreamAutoman transaction tests', function () { getAMMInfo(chainId, amm)!.apertureAutoman, ); const { swapData, liquidity } = ( - await getMintOptimalSwapInfo( + await getMintOptimalSwapInfoV4( chainId, amm, token0Amount, @@ -403,6 +401,7 @@ describe('SlipStreamAutoman transaction tests', function () { tickUpper, eoa, /* slippage= */ 0.5, + /* tokenPricesUsd= */ ['3000', '1'], publicClient, [E_Solver.SamePool], ) @@ -456,7 +455,8 @@ describe('SlipStreamAutoman transaction tests', function () { }); }); - it('Increase liquidity optimal without 1inch', async function () { + // Test deprecated and moved to slipstream-automanV4-transaction.test.ts. + it.skip('Increase liquidity optimal without 1inch', async function () { const existingPosition = await PositionDetails.fromPositionId( chainId, amm, diff --git a/test/hardhat/viem/slipstream-automanV4-transaction.test.ts b/test/hardhat/viem/slipstream-automanV4-transaction.test.ts new file mode 100644 index 00000000..6fcd5ce0 --- /dev/null +++ b/test/hardhat/viem/slipstream-automanV4-transaction.test.ts @@ -0,0 +1,547 @@ +// yarn test:hardhat test/hardhat/viem/slipstream-automanV4-transaction.test.ts +import { nearestUsableTick } from '@aperture_finance/uniswap-v3-sdk'; +import { CurrencyAmount, Percent } from '@uniswap/sdk-core'; +import { AutomatedMarketMakerEnum } from 'aperture-lens/dist/src/viem'; +import { BigNumber } from 'ethers'; +import { defaultAbiCoder } from 'ethers/lib/utils'; +import hre, { ethers } from 'hardhat'; +import { + Address, + PublicClient, + TestClient, + WalletClient, + createPublicClient, + http, + parseEther, + walletActions, +} from 'viem'; +import { base, mainnet } from 'viem/chains'; + +import { + ActionTypeEnum, + ApertureSupportedChainId, + ConditionTypeEnum, + ConsoleLogger, + ICommonNonfungiblePositionManager__factory, + IOCKEY_LOGGER, + SlipStreamAutomanV4, + SlipStreamAutomanV4__factory, + SlipStreamOptimalSwapRouter__factory, + getAMMInfo, + ioc, +} from '../../../src'; +import { + E_Solver, + PositionDetails, + generateAutoCompoundRequestPayload, + getBasicPositionInfo, + getERC20Overrides, + getIncreaseLiquidityOptimalSwapInfoV4, + getIncreaseLiquidityOptimalV4Tx, + getMintOptimalSwapInfoV4, + getMintOptimalV4Tx, + getMintedPositionIdFromTxReceipt, + getPool, + getRebalanceSwapInfoV4, + getRebalanceV4Tx, + getReinvestV4Tx, +} from '../../../src/viem'; +import { expect, hardhatForkProvider, resetFork } from '../common'; + +// TODO: Unify test cases for all AMMs (UniV3, PCSV3 and SlipStream). + +// Tests for SlipStreamAutomanV4 transactions on a forked Base mainnet. +describe('SlipStreamAutomanV4 transaction tests', function () { + const amm = AutomatedMarketMakerEnum.enum.SLIPSTREAM; + const chainId = ApertureSupportedChainId.BASE_MAINNET_CHAIN_ID; + const blockNumber = 17839113n; + const positionId = 13465n; + // Owner of position id `positionId` as of `blockNumber`. + const eoa = '0xeF1Ce5fddd0a1cb903b49608F6e1A37199DCf2a6'; + // A Binance hot wallet address that holds a large amount of ETH and USDC on Base mainnet. + const WHALE_ADDRESS = '0x3304E22DDaa22bCdC5fCa2269b418046aE7b566A'; + let automanV4Contract: SlipStreamAutomanV4; + const automanV4Address = getAMMInfo(chainId, amm)!.apertureAutomanV4; + const feeCollector = WHALE_ADDRESS; + let testClient: TestClient; + let publicClient: PublicClient; + let impersonatedOwnerClient: WalletClient; + const nonForkClient = createPublicClient({ + chain: base, + transport: http('https://base-rpc.publicnode.com'), + }); + ioc.registerSingleton(IOCKEY_LOGGER, ConsoleLogger); + + beforeEach(async function () { + testClient = await hre.viem.getTestClient(); + publicClient = await hre.viem.getPublicClient(); + await resetFork(testClient, blockNumber, chainId); + await testClient.impersonateAccount({ + address: eoa, + }); + impersonatedOwnerClient = testClient.extend(walletActions); + + // Deploy AutomanV4. + const impersonatedWhaleSigner = + await ethers.getImpersonatedSigner(WHALE_ADDRESS); + automanV4Contract = await new SlipStreamAutomanV4__factory( + impersonatedWhaleSigner, + ).deploy( + getAMMInfo(chainId, amm)!.nonfungiblePositionManager, + /*owner=*/ WHALE_ADDRESS, + ); + await automanV4Contract.deployed(); + await automanV4Contract.setFeeConfig({ + feeCollector, + // Set the max fee deduction to 50%. + feeLimitPips: BigNumber.from('500000000000000000'), + }); + await automanV4Contract.setControllers([WHALE_ADDRESS], [true]); + const router = await new SlipStreamOptimalSwapRouter__factory( + // TODO: migrate ethers + await ethers.getImpersonatedSigner(WHALE_ADDRESS), + ).deploy(getAMMInfo(chainId, amm)!.nonfungiblePositionManager); + await router.deployed(); + await automanV4Contract.setAllowlistedRouters([router.address], [true]); + + // Set AutomanV4 address in CHAIN_ID_TO_INFO. + getAMMInfo(chainId, amm)!.apertureAutomanV4 = + automanV4Contract.address as `0x${string}`; + getAMMInfo(chainId, amm)!.optimalSwapRouter = + router.address as `0x${string}`; + + // `eoa` sets AutomanV4 as operator. + const { request } = await publicClient.simulateContract({ + abi: ICommonNonfungiblePositionManager__factory.abi, + address: getAMMInfo(chainId, amm)!.nonfungiblePositionManager, + functionName: 'setApprovalForAll', + args: [automanV4Contract.address as Address, true] as const, + account: eoa, + }); + + await impersonatedWhaleSigner.sendTransaction({ + to: eoa, + value: parseEther('1'), + }); + await impersonatedOwnerClient.writeContract(request); + }); + + after(() => { + // Reset AutomanV4 address in CHAIN_ID_TO_INFO. + getAMMInfo(chainId, amm)!.apertureAutomanV4 = automanV4Address; + testClient.stopImpersonatingAccount({ + address: eoa, + }); + }); + + async function dealERC20( + token0: Address, + token1: Address, + amount0: bigint, + amount1: bigint, + from: Address, + to: Address, + ) { + const [token0Overrides, token1Overrides] = await Promise.all([ + getERC20Overrides(token0, from, to, amount0, nonForkClient), + getERC20Overrides(token1, from, to, amount1, nonForkClient), + ]); + for (const slot of Object.keys(token0Overrides[token0].stateDiff!)) { + await hardhatForkProvider.send('hardhat_setStorageAt', [ + token0, + slot, + defaultAbiCoder.encode(['uint256'], [amount0]), + ]); + } + for (const slot of Object.keys(token1Overrides[token1].stateDiff!)) { + await hardhatForkProvider.send('hardhat_setStorageAt', [ + token1, + slot, + defaultAbiCoder.encode(['uint256'], [amount1]), + ]); + } + } + + it('Reinvest', async function () { + const liquidityBeforeReinvest = ( + await getBasicPositionInfo(chainId, amm, positionId, publicClient) + ).liquidity!; + const txRequest = await getReinvestV4Tx( + chainId, + amm, + eoa, + /* increaseOptions= */ { + tokenId: positionId.toString(), + slippageTolerance: new Percent(1, 100), + deadline: Math.floor(Date.now() / 1000), + }, + /* token0FeeAmount= */ 0n, + /* token1FeeAmount= */ 0n, + /* swapData= */ '0x', + /* amount0Min= */ 0n, + /* amount1Min= */ 0n, + ); + + await impersonatedOwnerClient.sendTransaction({ + ...txRequest, + account: eoa, + chain: mainnet, + }); + const liquidityAfterReinvest = ( + await getBasicPositionInfo(chainId, amm, positionId, publicClient) + ).liquidity!; + expect(liquidityBeforeReinvest.toString()).to.equal('13589538797482293814'); + expect(liquidityAfterReinvest.toString()).to.equal('14018556727424907792'); + expect( + generateAutoCompoundRequestPayload( + eoa, + chainId, + AutomatedMarketMakerEnum.enum.SLIPSTREAM, + positionId.toString(), + /* feeToPrincipalRatioThreshold= */ 0.1, + /* slippage= */ 0.05, + /* maxGasProportion= */ 0.01, + /* expiration= */ 1627776000, + ), + ).to.deep.equal({ + action: { + maxGasProportion: 0.01, + slippage: 0.05, + type: ActionTypeEnum.enum.Reinvest, + }, + chainId, + amm: AutomatedMarketMakerEnum.enum.SLIPSTREAM, + condition: { + feeToPrincipalRatioThreshold: 0.1, + type: ConditionTypeEnum.enum.AccruedFees, + }, + nftId: positionId.toString(), + ownerAddr: eoa, + expiration: 1627776000, + }); + }); + + it('Rebalance', async function () { + const existingPosition = await PositionDetails.fromPositionId( + chainId, + amm, + positionId, + publicClient, + ); + const { swapData, liquidity } = ( + await getRebalanceSwapInfoV4( + chainId, + amm, + publicClient, + eoa, + existingPosition, + /* newPositionTickLower= */ 78600, + /* newPositionTickUpper= */ 79400, + /* slippageTolerance= */ 0.01, + /* tokenPricesUsd= */ ['60000', '3000'], + /* includeSolvers= */ [E_Solver.SamePool], + /* blockNumber= */ undefined, + ) + )[0]; + const { tx: txRequest } = await getRebalanceV4Tx( + chainId, + amm, + eoa, + positionId, + /* newPositionTickLower= */ 78600, + /* newPositionTickUpper= */ 79400, + /* slippageTolerance= */ new Percent(1, 100), + /* deadlineEpochSeconds= */ BigInt(Math.floor(Date.now() / 1000)), + publicClient, + swapData, + liquidity, + /* token0FeeAmount= */ 0n, + /* token0FeeAmount= */ 0n, + existingPosition.position, + ); + await testClient.impersonateAccount({ address: eoa }); + const walletClient = testClient.extend(walletActions); + const txHash = await walletClient.sendTransaction({ + to: txRequest.to, + data: txRequest.data, + account: txRequest.from, + chain: walletClient.chain, + }); + const txReceipt = await publicClient.getTransactionReceipt({ + hash: txHash, + }); + const newPositionId = getMintedPositionIdFromTxReceipt( + chainId, + amm, + txReceipt, + eoa, + )!; + expect( + await getBasicPositionInfo(chainId, amm, newPositionId, publicClient), + ).to.deep.equal({ + token0: existingPosition.pool.token0, + token1: existingPosition.pool.token1, + fee: existingPosition.pool.fee, + tickSpacing: existingPosition.pool.tickSpacing, + liquidity: '7008927949436597297', + tickLower: 78600, + tickUpper: 79400, + }); + }); + + // This test is flaky due to mismatch between the forked state and the most recent live network state which 1inch API operates on. + // TODO: Make this test stable and enable it for all AMMs. + it.skip('Rebalance with 1inch', async function () { + const existingPosition = await PositionDetails.fromPositionId( + chainId, + amm, + positionId, + publicClient, + ); + const { swapData, liquidity } = ( + await getRebalanceSwapInfoV4( + chainId, + amm, + publicClient, + eoa, + existingPosition, + /* newPositionTickLower= */ 240000, + /* newPositionTickUpper= */ 300000, + /* slippageTolerance= */ 0.01, + /* tokenPricesUsd= */ ['60000', '3000'], + [E_Solver.OneInch], + /* blockNumber= */ undefined, + ) + )[0]; + const { tx: txRequest } = await getRebalanceV4Tx( + chainId, + amm, + eoa, + positionId, + /* newPositionTickLower= */ 240000, + /* newPositionTickUpper= */ 300000, + /* slippageTolerance= */ new Percent(1, 100), + /* deadlineEpochSeconds= */ BigInt(Math.floor(Date.now() / 1000)), + publicClient, + swapData, + liquidity, + /* token0FeeAmount= */ 0n, + /* token0FeeAmount= */ 0n, + existingPosition.position, + ); + await testClient.impersonateAccount({ address: eoa }); + const walletClient = testClient.extend(walletActions); + const txHash = await walletClient.sendTransaction({ + to: txRequest.to, + data: txRequest.data, + account: txRequest.from, + chain: walletClient.chain, + }); + const txReceipt = await publicClient.getTransactionReceipt({ + hash: txHash, + }); + const newPositionId = getMintedPositionIdFromTxReceipt( + chainId, + amm, + txReceipt, + eoa, + )!; + expect( + await getBasicPositionInfo(chainId, amm, newPositionId, publicClient), + ).to.deep.contains({ + token0: existingPosition.pool.token0, + token1: existingPosition.pool.token1, + fee: existingPosition.pool.fee, + tickSpacing: existingPosition.pool.tickSpacing, + tickLower: 240000, + tickUpper: 300000, + }); + }); + + it('Optimal mint without 1inch', async function () { + const pool = await getPool( + '0x4200000000000000000000000000000000000006', // WETH on Base mainnet, + '0x940181a94A35A4569E4529A3CDfB74e38FD98631', // AERO on Base mainnet, + /* feeOrTickSpacing= */ 200, + chainId, + amm, + publicClient, + ); + const tickLower = nearestUsableTick( + pool.tickCurrent - 1000, + pool.tickSpacing, + ); + const tickUpper = nearestUsableTick( + pool.tickCurrent + 1000, + pool.tickSpacing, + ); + // 1 WETH and 1 AERO. + const token0Amount = CurrencyAmount.fromRawAmount( + pool.token0, + '1000000000000000000', + ); + const token1Amount = CurrencyAmount.fromRawAmount( + pool.token1, + '1000000000000000000', + ); + await dealERC20( + pool.token0.address as Address, + pool.token1.address as Address, + BigInt(token0Amount.quotient.toString()), + BigInt(token1Amount.quotient.toString()), + eoa, + getAMMInfo(chainId, amm)!.apertureAutomanV4, + ); + const { swapData, liquidity } = ( + await getMintOptimalSwapInfoV4( + chainId, + amm, + token0Amount, + token1Amount, + pool.tickSpacing, + tickLower, + tickUpper, + eoa, + /* slippage= */ 0.5, + /* tokenPricesUsd= */ ['3000', '1'], + publicClient, + [E_Solver.SamePool], + ) + )[0]; + const { tx: txRequest } = await getMintOptimalV4Tx( + chainId, + amm, + token0Amount, + token1Amount, + pool.tickSpacing, + tickLower, + tickUpper, + eoa, + /* deadlineEpochSeconds= */ BigInt(Math.floor(Date.now() / 1000)), + /* slippage= */ 0.5, + publicClient, + swapData, + liquidity, + ); + await testClient.impersonateAccount({ address: eoa }); + const walletClient = testClient.extend(walletActions); + const txHash = await walletClient.sendTransaction({ + to: txRequest.to, + data: txRequest.data, + account: txRequest.from, + chain: walletClient.chain, + }); + const txReceipt = await publicClient.getTransactionReceipt({ + hash: txHash, + }); + const newPositionId = getMintedPositionIdFromTxReceipt( + chainId, + amm, + txReceipt, + eoa, + )!; + const newPosition = await getBasicPositionInfo( + chainId, + amm, + newPositionId, + publicClient, + ); + expect(newPosition).to.deep.contains({ + token0: pool.token0, + token1: pool.token1, + fee: pool.fee, + tickSpacing: pool.tickSpacing, + tickLower, + tickUpper, + liquidity: '645125816475133179687', + }); + }); + + it('Increase liquidity optimal without 1inch', async function () { + const existingPosition = await PositionDetails.fromPositionId( + chainId, + amm, + positionId, + publicClient, + ); + const pool = existingPosition.pool; + const token0Amount = CurrencyAmount.fromRawAmount( + pool.token0, + '1000000000000000000', + ); + const token1Amount = CurrencyAmount.fromRawAmount( + pool.token1, + '1000000000000000000', + ); + await dealERC20( + pool.token0.address as Address, + pool.token1.address as Address, + BigInt(token0Amount.quotient.toString()), + BigInt(token1Amount.quotient.toString()), + eoa, + getAMMInfo(chainId, amm)!.apertureAutomanV4, + ); + const { swapData, liquidity } = ( + await getIncreaseLiquidityOptimalSwapInfoV4( + { + tokenId: Number(positionId), + slippageTolerance: new Percent(5, 1000), + deadline: Math.floor(Date.now() / 1000 + 60 * 30), + }, + chainId, + amm, + token0Amount, + token1Amount, + eoa, + /* tokenPricesUsd= */ ['3000', '1'], // WETH/AERO + publicClient, + [E_Solver.SamePool], + existingPosition.position, + ) + )[0]; + const { tx: txRequest } = await getIncreaseLiquidityOptimalV4Tx( + { + tokenId: Number(positionId), + slippageTolerance: new Percent(50, 100), + deadline: Math.floor(Date.now() / 1000 + 60 * 30), + }, + chainId, + amm, + token0Amount, + token1Amount, + eoa, + publicClient, + swapData, + liquidity, + existingPosition.position, + ); + + await testClient.impersonateAccount({ address: eoa }); + const walletClient = testClient.extend(walletActions); + const txHash = await walletClient.sendTransaction({ + to: txRequest.to, + data: txRequest.data, + account: txRequest.from, + chain: walletClient.chain, + }); + await publicClient.getTransactionReceipt({ + hash: txHash, + }); + const newPosition = await getBasicPositionInfo( + chainId, + amm, + positionId, + publicClient, + ); + expect(existingPosition.liquidity).to.equal('13589538797482293814'); + expect(newPosition).to.deep.equal({ + token0: pool.token0, + token1: pool.token1, + fee: pool.fee, + tickSpacing: pool.tickSpacing, + tickLower: existingPosition.tickLower, + tickUpper: existingPosition.tickUpper, + liquidity: '3825661781316041551568', + }); + }); +}); diff --git a/test/hardhat/viem/univ3-automan-transaction.test.ts b/test/hardhat/viem/univ3-automan-transaction.test.ts index 7f1e610a..456b63d3 100644 --- a/test/hardhat/viem/univ3-automan-transaction.test.ts +++ b/test/hardhat/viem/univ3-automan-transaction.test.ts @@ -1,3 +1,4 @@ +// yarn test:hardhat test/hardhat/viem/univ3-automan-transaction.test.ts import { FeeAmount, nearestUsableTick } from '@aperture_finance/uniswap-v3-sdk'; import { CurrencyAmount, Percent } from '@uniswap/sdk-core'; import { AutomatedMarketMakerEnum } from 'aperture-lens/dist/src/viem'; @@ -32,10 +33,8 @@ import { generateAutoCompoundRequestPayload, getBasicPositionInfo, getERC20Overrides, - getIncreaseLiquidityOptimalSwapInfo, - getIncreaseLiquidityOptimalTx, - getMintOptimalSwapInfo, - getMintOptimalTx, + getMintOptimalSwapInfoV4, + getMintOptimalV4Tx, getMintedPositionIdFromTxReceipt, getPool, getRebalanceSwapInfo, @@ -61,10 +60,10 @@ describe('Viem - UniV3Automan transaction tests', function () { const blockNumber = 17188000n; let automanContract: UniV3Automan; const automanAddress = getAMMInfo(chainId, amm)!.apertureAutoman; + const feeCollector = WHALE_ADDRESS; let testClient: TestClient; let publicClient: PublicClient; let impersonatedOwnerClient: WalletClient; - ioc.registerSingleton(IOCKEY_LOGGER, ConsoleLogger); beforeEach(async function () { @@ -86,7 +85,7 @@ describe('Viem - UniV3Automan transaction tests', function () { ); await automanContract.deployed(); await automanContract.setFeeConfig({ - feeCollector: WHALE_ADDRESS, + feeCollector, // Set the max fee deduction to 50%. feeLimitPips: BigInt('500000000000000000'), }); @@ -387,7 +386,7 @@ describe('Viem - UniV3Automan transaction tests', function () { getAMMInfo(chainId, amm)!.apertureAutoman, ); const { swapData, liquidity } = ( - await getMintOptimalSwapInfo( + await getMintOptimalSwapInfoV4( chainId, amm, token0Amount, @@ -397,11 +396,12 @@ describe('Viem - UniV3Automan transaction tests', function () { tickUpper, eoa, /* slippage= */ 0.5, + /* tokenPricesUsd= */ ['60000', '3000'], publicClient, [E_Solver.OneInch], ) )[0]; - const { tx: txRequest } = await getMintOptimalTx( + const { tx: txRequest } = await getMintOptimalV4Tx( chainId, amm, token0Amount, @@ -449,7 +449,8 @@ describe('Viem - UniV3Automan transaction tests', function () { }); }); - it('Optimal mint without 1inch', async function () { + // Test deprecated and moved to univ3-automanV4-transaction.test.ts. + it.skip('Optimal mint without 1inch', async function () { const pool = await getPool( WBTC_ADDRESS, WETH_ADDRESS, @@ -483,7 +484,7 @@ describe('Viem - UniV3Automan transaction tests', function () { getAMMInfo(chainId, amm)!.apertureAutoman, ); const { swapData, liquidity } = ( - await getMintOptimalSwapInfo( + await getMintOptimalSwapInfoV4( chainId, amm, token0Amount, @@ -493,11 +494,12 @@ describe('Viem - UniV3Automan transaction tests', function () { tickUpper, eoa, /* slippage= */ 0.5, + /* tokenPricesUsd= */ ['60000', '3000'], publicClient, [E_Solver.SamePool], ) )[0]; - const { tx: txRequest } = await getMintOptimalTx( + const { tx: txRequest } = await getMintOptimalV4Tx( chainId, amm, token0Amount, @@ -635,7 +637,8 @@ describe('Viem - UniV3Automan transaction tests', function () { ).to.equal(true); }); - it('Increase liquidity optimal without 1inch', async function () { + // Test deprecated and moved to univ3-automanV4-transaction.test.ts. + it.skip('Increase liquidity optimal without 1inch', async function () { const existingPosition = await PositionDetails.fromPositionId( chainId, amm, diff --git a/test/hardhat/viem/univ3-automanV3-transaction.test.ts b/test/hardhat/viem/univ3-automanV4-transaction.test.ts similarity index 60% rename from test/hardhat/viem/univ3-automanV3-transaction.test.ts rename to test/hardhat/viem/univ3-automanV4-transaction.test.ts index 69ad4534..5d8fb44e 100644 --- a/test/hardhat/viem/univ3-automanV3-transaction.test.ts +++ b/test/hardhat/viem/univ3-automanV4-transaction.test.ts @@ -1,5 +1,9 @@ -// yarn test:hardhat test/hardhat/viem/univ3-AutomanV3-transaction.test.ts -import { FeeAmount, nearestUsableTick } from '@aperture_finance/uniswap-v3-sdk'; +// yarn test:hardhat test/hardhat/viem/univ3-automanV4-transaction.test.ts +import { + FeeAmount, + RemoveLiquidityOptions, + nearestUsableTick, +} from '@aperture_finance/uniswap-v3-sdk'; import { CurrencyAmount, Percent } from '@uniswap/sdk-core'; import { AutomatedMarketMakerEnum } from 'aperture-lens/dist/src/viem'; import hre, { ethers } from 'hardhat'; @@ -10,6 +14,7 @@ import { TestClient, WalletClient, encodeAbiParameters, + getContract, parseAbiParameters, walletActions, } from 'viem'; @@ -20,9 +25,10 @@ import { ConditionTypeEnum, ConsoleLogger, ICommonNonfungiblePositionManager__factory, + IERC20__factory, IOCKEY_LOGGER, - UniV3AutomanV3, - UniV3AutomanV3__factory, + UniV3AutomanV4, + UniV3AutomanV4__factory, UniV3OptimalSwapRouter__factory, getAMMInfo, ioc, @@ -32,16 +38,18 @@ import { PositionDetails, generateAutoCompoundRequestPayload, getBasicPositionInfo, + getDecreaseLiquiditySingleSwapInfo, + getDecreaseLiquiditySingleTx, getERC20Overrides, - getIncreaseLiquidityOptimalSwapInfoV3, - getIncreaseLiquidityOptimalV3Tx, - getMintOptimalSwapInfoV3, - getMintOptimalV3Tx, + getIncreaseLiquidityOptimalSwapInfoV4, + getIncreaseLiquidityOptimalV4Tx, + getMintOptimalSwapInfoV4, + getMintOptimalV4Tx, getMintedPositionIdFromTxReceipt, getPool, - getRebalanceSwapInfoV3, - getRebalanceV3Tx, - getReinvestV3Tx, + getRebalanceSwapInfoV4, + getRebalanceV4Tx, + getReinvestV4Tx, } from '../../../src/viem'; import { WBTC_ADDRESS, @@ -56,16 +64,16 @@ import { resetFork, } from '../common'; -// Tests for UniV3AutomanV3 transactions on a forked Ethereum mainnet. -describe('Viem - UniV3AutomanV3 transaction tests', function () { +// Tests for UniV3AutomanV4 transactions on a forked Ethereum mainnet. +describe('Viem - UniV3AutomanV4 transaction tests', function () { const positionId = 4n; const blockNumber = 17188000n; - let automanV3Contract: UniV3AutomanV3; - const automanV3Address = getAMMInfo(chainId, amm)!.apertureAutomanV3; + let automanV4Contract: UniV3AutomanV4; + const automanV4Address = getAMMInfo(chainId, amm)!.apertureAutomanV4; + const feeCollector = WHALE_ADDRESS; let testClient: TestClient; let publicClient: PublicClient; let impersonatedOwnerClient: WalletClient; - ioc.registerSingleton(IOCKEY_LOGGER, ConsoleLogger); beforeEach(async function () { @@ -78,39 +86,39 @@ describe('Viem - UniV3AutomanV3 transaction tests', function () { }); impersonatedOwnerClient = testClient.extend(walletActions); - // Deploy Automan. - automanV3Contract = await new UniV3AutomanV3__factory( + // Deploy AutomanV4. + automanV4Contract = await new UniV3AutomanV4__factory( + // TODO: migrate ethers await ethers.getImpersonatedSigner(WHALE_ADDRESS), ).deploy( getAMMInfo(chainId, amm)!.nonfungiblePositionManager, /*owner=*/ WHALE_ADDRESS, ); - await automanV3Contract.deployed(); - await automanV3Contract.setFeeConfig({ - feeCollector: WHALE_ADDRESS, + await automanV4Contract.deployed(); + await automanV4Contract.setFeeConfig({ + feeCollector, // Set the max fee deduction to 50%. feeLimitPips: BigInt('500000000000000000'), }); - await automanV3Contract.setControllers([WHALE_ADDRESS], [true]); + await automanV4Contract.setControllers([WHALE_ADDRESS], [true]); const router = await new UniV3OptimalSwapRouter__factory( - // TODO: migrate ethers await ethers.getImpersonatedSigner(WHALE_ADDRESS), ).deploy(getAMMInfo(chainId, amm)!.nonfungiblePositionManager); await router.deployed(); - await automanV3Contract.setSwapRouters([router.address], [true]); + await automanV4Contract.setAllowlistedRouters([router.address], [true]); - // Set Automan address in CHAIN_ID_TO_INFO. - getAMMInfo(chainId, amm)!.apertureAutomanV3 = - automanV3Contract.address as `0x${string}`; + // Set AutomanV4 address in CHAIN_ID_TO_INFO. + getAMMInfo(chainId, amm)!.apertureAutomanV4 = + automanV4Contract.address as `0x${string}`; getAMMInfo(chainId, amm)!.optimalSwapRouter = router.address as `0x${string}`; - // Owner of position id 4 sets AutomanV3 as operator. + // Owner of position id 4 sets AutomanV4 as operator. const { request } = await publicClient.simulateContract({ abi: ICommonNonfungiblePositionManager__factory.abi, address: getAMMInfo(chainId, amm)!.nonfungiblePositionManager, functionName: 'setApprovalForAll', - args: [automanV3Contract.address as Address, true] as const, + args: [automanV4Contract.address as Address, true] as const, account: eoa, }); @@ -118,8 +126,8 @@ describe('Viem - UniV3AutomanV3 transaction tests', function () { }); after(() => { - // Reset AutomanV3 address in CHAIN_ID_TO_INFO. - getAMMInfo(chainId, amm)!.apertureAutomanV3 = automanV3Address; + // Reset AutomanV4 address in CHAIN_ID_TO_INFO. + getAMMInfo(chainId, amm)!.apertureAutomanV4 = automanV4Address; testClient.stopImpersonatingAccount({ address: eoa, }); @@ -158,7 +166,7 @@ describe('Viem - UniV3AutomanV3 transaction tests', function () { const liquidityBeforeReinvest = ( await getBasicPositionInfo(chainId, amm, positionId, publicClient) ).liquidity!; - const txRequest = await getReinvestV3Tx( + const txRequest = await getReinvestV4Tx( chainId, amm, eoa, @@ -191,7 +199,7 @@ describe('Viem - UniV3AutomanV3 transaction tests', function () { AutomatedMarketMakerEnum.enum.UNISWAP_V3, positionId.toString(), /* feeToPrincipalRatioThreshold= */ 0.1, - /* slippage =*/ 0.05, + /* slippage= */ 0.05, /* maxGasProportion= */ 0.01, /* expiration= */ 1627776000, ), @@ -221,7 +229,7 @@ describe('Viem - UniV3AutomanV3 transaction tests', function () { publicClient, ); const { swapData, liquidity } = ( - await getRebalanceSwapInfoV3( + await getRebalanceSwapInfoV4( chainId, amm, publicClient, @@ -234,7 +242,7 @@ describe('Viem - UniV3AutomanV3 transaction tests', function () { [E_Solver.SamePool], ) )[0]; - const { tx: txRequest } = await getRebalanceV3Tx( + const { tx: txRequest } = await getRebalanceV4Tx( chainId, amm, eoa, @@ -250,7 +258,7 @@ describe('Viem - UniV3AutomanV3 transaction tests', function () { /* token1FeeAmount= */ 0n, existingPosition.position, ); - // Owner of position id 4 sets Automan as operator. + // Owner of position id 4 sets AutomanV4 as operator. await testClient.impersonateAccount({ address: eoa }); const walletClient = testClient.extend(walletActions); const txHash = await walletClient.sendTransaction({ @@ -291,7 +299,7 @@ describe('Viem - UniV3AutomanV3 transaction tests', function () { publicClient, ); const { swapData, liquidity } = ( - await getRebalanceSwapInfoV3( + await getRebalanceSwapInfoV4( chainId, amm, publicClient, @@ -304,7 +312,7 @@ describe('Viem - UniV3AutomanV3 transaction tests', function () { [E_Solver.OneInch], ) )[0]; - const { tx: txRequest } = await getRebalanceV3Tx( + const { tx: txRequest } = await getRebalanceV4Tx( chainId, amm, eoa, @@ -382,10 +390,10 @@ describe('Viem - UniV3AutomanV3 transaction tests', function () { BigInt(token0Amount.quotient.toString()), BigInt(token1Amount.quotient.toString()), eoa, - getAMMInfo(chainId, amm)!.apertureAutomanV3, + getAMMInfo(chainId, amm)!.apertureAutomanV4, ); const { swapData, liquidity } = ( - await getMintOptimalSwapInfoV3( + await getMintOptimalSwapInfoV4( chainId, amm, token0Amount, @@ -400,7 +408,7 @@ describe('Viem - UniV3AutomanV3 transaction tests', function () { [E_Solver.OneInch], ) )[0]; - const { tx: txRequest } = await getMintOptimalV3Tx( + const { tx: txRequest } = await getMintOptimalV4Tx( chainId, amm, token0Amount, @@ -415,7 +423,7 @@ describe('Viem - UniV3AutomanV3 transaction tests', function () { swapData, liquidity, ); - // Owner of position id 4 sets Automan as operator. + // Owner of position id 4 sets AutomanV4 as operator. await testClient.impersonateAccount({ address: eoa }); const walletClient = testClient.extend(walletActions); const txHash = await walletClient.sendTransaction({ @@ -448,7 +456,7 @@ describe('Viem - UniV3AutomanV3 transaction tests', function () { }); }); - it('Optimal mint without 1inch', async function () { + it.skip('Optimal mint without 1inch', async function () { const pool = await getPool( WBTC_ADDRESS, WETH_ADDRESS, @@ -479,10 +487,10 @@ describe('Viem - UniV3AutomanV3 transaction tests', function () { BigInt(token0Amount.quotient.toString()), BigInt(token1Amount.quotient.toString()), eoa, - getAMMInfo(chainId, amm)!.apertureAutomanV3, + getAMMInfo(chainId, amm)!.apertureAutomanV4, ); const { swapData, liquidity } = ( - await getMintOptimalSwapInfoV3( + await getMintOptimalSwapInfoV4( chainId, amm, token0Amount, @@ -497,7 +505,7 @@ describe('Viem - UniV3AutomanV3 transaction tests', function () { [E_Solver.SamePool], ) )[0]; - const { tx: txRequest } = await getMintOptimalV3Tx( + const { tx: txRequest } = await getMintOptimalV4Tx( chainId, amm, token0Amount, @@ -568,10 +576,10 @@ describe('Viem - UniV3AutomanV3 transaction tests', function () { BigInt(token0Amount.quotient.toString()), BigInt(token1Amount.quotient.toString()), eoa, - getAMMInfo(chainId, amm)!.apertureAutomanV3, + getAMMInfo(chainId, amm)!.apertureAutomanV4, ); const { swapData, liquidity } = ( - await getIncreaseLiquidityOptimalSwapInfoV3( + await getIncreaseLiquidityOptimalSwapInfoV4( { tokenId: Number(positionId), slippageTolerance: new Percent(5, 1000), @@ -588,7 +596,7 @@ describe('Viem - UniV3AutomanV3 transaction tests', function () { existingPosition.position, ) )[0]; - const { tx: txRequest } = await getIncreaseLiquidityOptimalV3Tx( + const { tx: txRequest } = await getIncreaseLiquidityOptimalV4Tx( { tokenId: Number(positionId), slippageTolerance: new Percent(50, 100), @@ -605,7 +613,7 @@ describe('Viem - UniV3AutomanV3 transaction tests', function () { existingPosition.position, ); - // Owner of position id 4 sets Automan as operator. + // Owner of position id 4 sets AutomanV4 as operator. await testClient.impersonateAccount({ address: eoa }); const walletClient = testClient.extend(walletActions); const txHash = await walletClient.sendTransaction({ @@ -658,10 +666,10 @@ describe('Viem - UniV3AutomanV3 transaction tests', function () { BigInt(token0Amount.quotient.toString()), BigInt(token1Amount.quotient.toString()), eoa, - getAMMInfo(chainId, amm)!.apertureAutomanV3, + getAMMInfo(chainId, amm)!.apertureAutomanV4, ); const { swapData, liquidity } = ( - await getIncreaseLiquidityOptimalSwapInfoV3( + await getIncreaseLiquidityOptimalSwapInfoV4( { tokenId: Number(positionId), slippageTolerance: new Percent(5, 1000), @@ -678,7 +686,7 @@ describe('Viem - UniV3AutomanV3 transaction tests', function () { existingPosition.position, ) )[0]; - const { tx: txRequest } = await getIncreaseLiquidityOptimalV3Tx( + const { tx: txRequest } = await getIncreaseLiquidityOptimalV4Tx( { tokenId: Number(positionId), slippageTolerance: new Percent(50, 100), @@ -720,4 +728,300 @@ describe('Viem - UniV3AutomanV3 transaction tests', function () { tickUpper: existingPosition.tickUpper, }); }); + + it('Decrease Liquidity Single zeroForOne', async function () { + const zeroForOne = true; + const isUnwrapNative = true; + const existingPosition = await PositionDetails.fromPositionId( + chainId, + amm, + positionId, + publicClient, + ); + const [pool, token0Contract, token1Contract] = [ + existingPosition.pool, + getContract({ + address: existingPosition.token0.address as Address, + abi: IERC20__factory.abi, + client: publicClient, + }), + getContract({ + address: existingPosition.token1.address as Address, + abi: IERC20__factory.abi, + client: publicClient, + }), + ]; + const decreaseLiquidityOptions: RemoveLiquidityOptions = { + tokenId: Number(positionId), + liquidityPercentage: new Percent(49, 100), + slippageTolerance: new Percent(5, 1000), + deadline: Math.floor(Date.now() / 1000 + 60 * 30), + collectOptions: { + expectedCurrencyOwed0: existingPosition.tokensOwed0, + expectedCurrencyOwed1: existingPosition.tokensOwed1, + recipient: eoa, + }, + }; + const { swapData, amount0, amount1, token0FeeAmount, token1FeeAmount } = ( + await getDecreaseLiquiditySingleSwapInfo( + decreaseLiquidityOptions, + chainId, + amm, + zeroForOne, + eoa, + /* tokenPricesUsd= */ ['60000', '3000'], + publicClient, + isUnwrapNative, + [E_Solver.SamePool], + existingPosition, + ) + )[0]; + const txRequest = await getDecreaseLiquiditySingleTx( + decreaseLiquidityOptions, + zeroForOne, + eoa, + chainId, + amm, + publicClient, + swapData, + existingPosition, + /* amount0Min= */ amount0, + /* amount1Min= */ amount1, + /* token0FeeAmount= */ token0FeeAmount, + /* token1FeeAmount= */ token1FeeAmount, + ); + await testClient.impersonateAccount({ address: eoa }); + const walletClient = testClient.extend(walletActions); + + // Log states before sending the transaction. + const [ + eoaNativeBalanceBefore, + eoaToken0BalanceBefore, + eoaToken1BalanceBefore, + feeCollectorNativeBalanceBefore, + feeCollectorToken0BalanceBefore, + feeCollectorToken1BalanceBefore, + ] = await Promise.all([ + publicClient.getBalance({ address: eoa }), + token0Contract.read.balanceOf([eoa]), + token1Contract.read.balanceOf([eoa]), + publicClient.getBalance({ address: feeCollector }), + token0Contract.read.balanceOf([feeCollector]), + token1Contract.read.balanceOf([feeCollector]), + ]); + + // Send the transaction and wait for the receipt. + const txHash = await walletClient.sendTransaction({ + to: txRequest.to, + data: txRequest.data, + account: txRequest.from, + chain: walletClient.chain, + }); + await publicClient.getTransactionReceipt({ + hash: txHash, + }); + + // Get states after the transaction. + const [ + eoaNativeBalanceAfter, + eoaToken0BalanceAfter, + eoaToken1BalanceAfter, + feeCollectorNativeBalanceAfter, + feeCollectorToken0BalanceAfter, + feeCollectorToken1BalanceAfter, + ] = await Promise.all([ + publicClient.getBalance({ address: eoa }), + token0Contract.read.balanceOf([eoa]), + token1Contract.read.balanceOf([eoa]), + publicClient.getBalance({ address: feeCollector }), + token0Contract.read.balanceOf([feeCollector]), + token1Contract.read.balanceOf([feeCollector]), + ]); + + // Test balance of EOA. + expect(eoaNativeBalanceAfter - eoaNativeBalanceBefore).to.equal( + 4235189752462508733n, + ); + expect(eoaToken0BalanceAfter - eoaToken0BalanceBefore).to.equal(0n); + expect(eoaToken1BalanceAfter - eoaToken1BalanceBefore).to.equal(0n); + + // Test fees collected. + expect(token0FeeAmount).to.equal(40760n); + expect(token1FeeAmount).to.equal(0n); + expect( + feeCollectorNativeBalanceAfter - feeCollectorNativeBalanceBefore, + ).to.equal(0n); + expect( + feeCollectorToken0BalanceAfter - feeCollectorToken0BalanceBefore, + ).to.equal(40760n); + expect( + feeCollectorToken1BalanceAfter - feeCollectorToken1BalanceBefore, + ).to.equal(0n); + + // Test new position. + const newPosition = await getBasicPositionInfo( + chainId, + amm, + positionId, + publicClient, + ); + expect(newPosition).to.deep.contains({ + token0: pool.token0, + token1: pool.token1, + fee: pool.fee, + tickLower: existingPosition.tickLower, + tickUpper: existingPosition.tickUpper, + }); + expect( + JSBI.LT(newPosition.liquidity!, existingPosition.liquidity!), + ).to.equal(true); + }); + + it('Decrease Liquidity Single !zeroForOne', async function () { + const zeroForOne = false; + const isUnwrapNative = true; + const existingPosition = await PositionDetails.fromPositionId( + chainId, + amm, + positionId, + publicClient, + ); + const [pool, token0Contract, token1Contract] = [ + existingPosition.pool, + getContract({ + address: existingPosition.token0.address as Address, + abi: IERC20__factory.abi, + client: publicClient, + }), + getContract({ + address: existingPosition.token1.address as Address, + abi: IERC20__factory.abi, + client: publicClient, + }), + ]; + const decreaseLiquidityOptions: RemoveLiquidityOptions = { + tokenId: Number(positionId), + liquidityPercentage: new Percent(49, 100), + slippageTolerance: new Percent(5, 1000), + deadline: Math.floor(Date.now() / 1000 + 60 * 30), + collectOptions: { + expectedCurrencyOwed0: existingPosition.tokensOwed0, + expectedCurrencyOwed1: existingPosition.tokensOwed1, + recipient: eoa, + }, + }; + const { swapData, amount0, amount1, token0FeeAmount, token1FeeAmount } = ( + await getDecreaseLiquiditySingleSwapInfo( + decreaseLiquidityOptions, + chainId, + amm, + zeroForOne, + eoa, + /* tokenPricesUsd= */ ['60000', '3000'], + publicClient, + isUnwrapNative, + [E_Solver.SamePool], + existingPosition, + ) + )[0]; + const txRequest = await getDecreaseLiquiditySingleTx( + decreaseLiquidityOptions, + zeroForOne, + eoa, + chainId, + amm, + publicClient, + swapData, + existingPosition, + /* amount0Min= */ amount0, + /* amount1Min= */ amount1, + /* token0FeeAmount= */ token0FeeAmount, + /* token1FeeAmount= */ token1FeeAmount, + ); + await testClient.impersonateAccount({ address: eoa }); + const walletClient = testClient.extend(walletActions); + + // Log states before sending the transaction. + const [ + eoaNativeBalanceBefore, + eoaToken0BalanceBefore, + eoaToken1BalanceBefore, + feeCollectorNativeBalanceBefore, + feeCollectorToken0BalanceBefore, + feeCollectorToken1BalanceBefore, + ] = await Promise.all([ + publicClient.getBalance({ address: eoa }), + token0Contract.read.balanceOf([eoa]), + token1Contract.read.balanceOf([eoa]), + publicClient.getBalance({ address: feeCollector }), + token0Contract.read.balanceOf([feeCollector]), + token1Contract.read.balanceOf([feeCollector]), + ]); + + // Send the transaction and wait for the receipt. + const txHash = await walletClient.sendTransaction({ + to: txRequest.to, + data: txRequest.data, + account: txRequest.from, + chain: walletClient.chain, + }); + await publicClient.getTransactionReceipt({ + hash: txHash, + }); + + // Get states after the transaction. + const [ + eoaNativeBalanceAfter, + eoaToken0BalanceAfter, + eoaToken1BalanceAfter, + feeCollectorNativeBalanceAfter, + feeCollectorToken0BalanceAfter, + feeCollectorToken1BalanceAfter, + ] = await Promise.all([ + publicClient.getBalance({ address: eoa }), + token0Contract.read.balanceOf([eoa]), + token1Contract.read.balanceOf([eoa]), + publicClient.getBalance({ address: feeCollector }), + token0Contract.read.balanceOf([feeCollector]), + token1Contract.read.balanceOf([feeCollector]), + ]); + + // Test balance of EOA. + expect(eoaNativeBalanceAfter - eoaNativeBalanceBefore).to.equal( + -18493432237568736n, + ); + expect(eoaToken0BalanceAfter - eoaToken0BalanceBefore).to.equal(27827285n); + expect(eoaToken1BalanceAfter - eoaToken1BalanceBefore).to.equal(0n); + + // Test fees collected. + expect(token0FeeAmount).to.equal(0n); + expect(token1FeeAmount).to.equal(4431110560193163n); + expect( + feeCollectorNativeBalanceAfter - feeCollectorNativeBalanceBefore, + ).to.equal(4431110560193163n); + expect( + feeCollectorToken0BalanceAfter - feeCollectorToken0BalanceBefore, + ).to.equal(0n); + expect( + feeCollectorToken1BalanceAfter - feeCollectorToken1BalanceBefore, + ).to.equal(0n); + + // Test new position. + const newPosition = await getBasicPositionInfo( + chainId, + amm, + positionId, + publicClient, + ); + expect(newPosition).to.deep.contains({ + token0: pool.token0, + token1: pool.token1, + fee: pool.fee, + tickLower: existingPosition.tickLower, + tickUpper: existingPosition.tickUpper, + }); + expect( + JSBI.LT(newPosition.liquidity!, existingPosition.liquidity!), + ).to.equal(true); + }); }); diff --git a/test/playground/decreaseLiquiditySingle4063431OneForZero.ts b/test/playground/decreaseLiquiditySingle4063431OneForZero.ts new file mode 100644 index 00000000..18fbb883 --- /dev/null +++ b/test/playground/decreaseLiquiditySingle4063431OneForZero.ts @@ -0,0 +1,90 @@ +// ts-node test/playground/decreaseLiquiditySingle4063431OneForZero.ts +import { RemoveLiquidityOptions } from '@aperture_finance/uniswap-v3-sdk'; +import { Percent } from '@uniswap/sdk-core'; +import { AutomatedMarketMakerEnum } from 'aperture-lens/dist/src/viem'; + +import { + ApertureSupportedChainId, + ConsoleLogger, + IOCKEY_LOGGER, + ioc, +} from '../../src'; +import { + DEFAULT_SOLVERS, + PositionDetails, + getDecreaseLiquiditySingleSwapInfo, + getDecreaseLiquiditySingleTx, + getPublicClient, +} from '../../src/viem'; + +async function main() { + ioc.registerSingleton(IOCKEY_LOGGER, ConsoleLogger); + const amm = AutomatedMarketMakerEnum.enum.UNISWAP_V3; + const chainId = ApertureSupportedChainId.ARBITRUM_MAINNET_CHAIN_ID; + const client = getPublicClient(chainId); + const from = '0x1fFd5d818187917E0043522C3bE583A393c2BbF7'; + const tokenId = 4063431; + const zeroForOne = false; + const isUnwrapNative = true; + const positionDetails = await PositionDetails.fromPositionId( + chainId, + amm, + BigInt(tokenId), + client, + ); + // token0 = weth = 0x82af49447d8a07e3bd95bd0d56f35241523fbab1 + // token1 = usdc = 0xaf88d065e77c8cc2239327c5edb3a432268e5831 + const decreaseLiquidityOptions: RemoveLiquidityOptions = { + tokenId, + liquidityPercentage: new Percent(10, 100), // position is $3.33 100%WETH. token0=weth, token1=usdc.. should take out $0.33 eth=.33/3116*1e18 token0amount = 1.06e14, $0.07 usdc + slippageTolerance: new Percent(5, 1000), + deadline: Math.floor(Date.now() / 1000 + 60 * 30), + collectOptions: { + expectedCurrencyOwed0: positionDetails.tokensOwed0, + expectedCurrencyOwed1: positionDetails.tokensOwed1, + recipient: from, + }, + }; + const swapInfos = await getDecreaseLiquiditySingleSwapInfo( + decreaseLiquidityOptions, + chainId, + amm, + zeroForOne, + from, + /* tokenPricesUsd= */ ['3225', '1'], + client, + isUnwrapNative, + DEFAULT_SOLVERS, + positionDetails, + ); + for (const swapInfo of swapInfos) { + const { + solver, + swapData, + amount0, + amount1, + token0FeeAmount, + token1FeeAmount, + } = swapInfo; + const txRequest = await getDecreaseLiquiditySingleTx( + decreaseLiquidityOptions, + zeroForOne, + from, + chainId, + amm, + client, + swapData, + positionDetails, + /* amount0Min= */ amount0, + /* amount1Min= */ amount1, + /* token0FeeAmount= */ token0FeeAmount, + /* token1FeeAmount= */ token1FeeAmount, + ); + console.log( + `solver=${solver}, liquidity: ${swapInfo.liquidity}, to=${txRequest.to}, from=${txRequest.from}, data=${txRequest.data}`, + ); + } + process.exit(0); +} + +main(); diff --git a/test/playground/decreaseLiquiditySingle4063431ZeroForOne.ts b/test/playground/decreaseLiquiditySingle4063431ZeroForOne.ts new file mode 100644 index 00000000..29c47f7c --- /dev/null +++ b/test/playground/decreaseLiquiditySingle4063431ZeroForOne.ts @@ -0,0 +1,92 @@ +// ts-node test/playground/decreaseLiquiditySingle4063431ZeroForOne.ts +import { RemoveLiquidityOptions } from '@aperture_finance/uniswap-v3-sdk'; +import { Percent } from '@uniswap/sdk-core'; +import { AutomatedMarketMakerEnum } from 'aperture-lens/dist/src/viem'; + +import { + ApertureSupportedChainId, + ConsoleLogger, + IOCKEY_LOGGER, + ioc, +} from '../../src'; +import { + DEFAULT_SOLVERS, + PositionDetails, + getDecreaseLiquiditySingleSwapInfo, + getDecreaseLiquiditySingleTx, + getPublicClient, +} from '../../src/viem'; + +async function main() { + ioc.registerSingleton(IOCKEY_LOGGER, ConsoleLogger); + const amm = AutomatedMarketMakerEnum.enum.UNISWAP_V3; + const chainId = ApertureSupportedChainId.ARBITRUM_MAINNET_CHAIN_ID; + const client = getPublicClient(chainId); + const from = '0x1fFd5d818187917E0043522C3bE583A393c2BbF7'; + const tokenId = 4063431; + const zeroForOne = true; + const isUnwrapNative = true; + const positionDetails = await PositionDetails.fromPositionId( + chainId, + amm, + BigInt(tokenId), + client, + ); + // put weth into pool. take usdc out. + // token0 = weth = 0x82af49447d8a07e3bd95bd0d56f35241523fbab1 + // token1 = usdc = 0xaf88d065e77c8cc2239327c5edb3a432268e5831 + // tenderly revert due to not enough usdc from optSwapRouter to pool + const decreaseLiquidityOptions: RemoveLiquidityOptions = { + tokenId, + liquidityPercentage: new Percent(10, 100), // position is $3.33 100%WETH. token0=weth, token1=usdc.. should take out $0.33 eth=.33/3116*1e18 token0amount = 1.06e14, $0.07 usdc + slippageTolerance: new Percent(5, 1000), + deadline: Math.floor(Date.now() / 1000 + 60 * 30), + collectOptions: { + expectedCurrencyOwed0: positionDetails.tokensOwed0, + expectedCurrencyOwed1: positionDetails.tokensOwed1, + recipient: from, + }, + }; + const swapInfos = await getDecreaseLiquiditySingleSwapInfo( + decreaseLiquidityOptions, + chainId, + amm, + zeroForOne, + from, + /* tokenPricesUsd= */ ['3225', '1'], + client, + isUnwrapNative, + DEFAULT_SOLVERS, + positionDetails, + ); + for (const swapInfo of swapInfos) { + const { + solver, + swapData, + amount0, + amount1, + token0FeeAmount, + token1FeeAmount, + } = swapInfo; + const txRequest = await getDecreaseLiquiditySingleTx( + decreaseLiquidityOptions, + zeroForOne, + from, + chainId, + amm, + client, + swapData, + positionDetails, + /* amount0Min= */ amount0, + /* amount1Min= */ amount1, + /* token0FeeAmount= */ token0FeeAmount, + /* token1FeeAmount= */ token1FeeAmount, + ); + console.log( + `solver=${solver}, liquidity: ${swapInfo.liquidity}, to=${txRequest.to}, from=${txRequest.from}, data=${txRequest.data}`, + ); + } + process.exit(0); +} + +main(); diff --git a/test/playground/decreaseLiquiditySingle4076939OneForZero.ts b/test/playground/decreaseLiquiditySingle4076939OneForZero.ts new file mode 100644 index 00000000..5eccb429 --- /dev/null +++ b/test/playground/decreaseLiquiditySingle4076939OneForZero.ts @@ -0,0 +1,90 @@ +// ts-node test/playground/decreaseLiquiditySingle4076939OneForZero.ts +import { RemoveLiquidityOptions } from '@aperture_finance/uniswap-v3-sdk'; +import { Percent } from '@uniswap/sdk-core'; +import { AutomatedMarketMakerEnum } from 'aperture-lens/dist/src/viem'; + +import { + ApertureSupportedChainId, + ConsoleLogger, + IOCKEY_LOGGER, + ioc, +} from '../../src'; +import { + DEFAULT_SOLVERS, + PositionDetails, + getDecreaseLiquiditySingleSwapInfo, + getDecreaseLiquiditySingleTx, + getPublicClient, +} from '../../src/viem'; + +async function main() { + ioc.registerSingleton(IOCKEY_LOGGER, ConsoleLogger); + const amm = AutomatedMarketMakerEnum.enum.UNISWAP_V3; + const chainId = ApertureSupportedChainId.ARBITRUM_MAINNET_CHAIN_ID; + const client = getPublicClient(chainId); + const from = '0x1fFd5d818187917E0043522C3bE583A393c2BbF7'; + const tokenId = 4076939; + const zeroForOne = false; + const isUnwrapNative = true; + const positionDetails = await PositionDetails.fromPositionId( + chainId, + amm, + BigInt(tokenId), + client, + ); + // token0 = airdrop = https://arbiscan.io/address/0xdc5F1BF636DcAdaE7e285A484Dc71A1F5adeE0A1 + // token1 = usdt = https://arbiscan.io/address/0xfd086bc7cd5c481dcc9c85ebe478a1c0b69fcbb9 + const decreaseLiquidityOptions: RemoveLiquidityOptions = { + tokenId, + liquidityPercentage: new Percent(100, 100), // position is $3.33 100%WETH. token0=weth, token1=usdc.. should take out $0.33 eth=.33/3116*1e18 token0amount = 1.06e14, $0.07 usdc + slippageTolerance: new Percent(1000, 1000), + deadline: Math.floor(Date.now() / 1000 + 60 * 30), + collectOptions: { + expectedCurrencyOwed0: positionDetails.tokensOwed0, + expectedCurrencyOwed1: positionDetails.tokensOwed1, + recipient: from, + }, + }; + const swapInfos = await getDecreaseLiquiditySingleSwapInfo( + decreaseLiquidityOptions, + chainId, + amm, + zeroForOne, + from, + /* tokenPricesUsd= */ ['0.001', '1'], + client, + isUnwrapNative, + DEFAULT_SOLVERS, + positionDetails, + ); + for (const swapInfo of swapInfos) { + const { + solver, + swapData, + amount0, + amount1, + token0FeeAmount, + token1FeeAmount, + } = swapInfo; + const txRequest = await getDecreaseLiquiditySingleTx( + decreaseLiquidityOptions, + zeroForOne, + from, + chainId, + amm, + client, + swapData, + positionDetails, + /* amount0Min= */ amount0, + /* amount1Min= */ amount1, + /* token0FeeAmount= */ token0FeeAmount, + /* token1FeeAmount= */ token1FeeAmount, + ); + console.log( + `solver=${solver}, liquidity: ${swapInfo.liquidity}, to=${txRequest.to}, from=${txRequest.from}, data=${txRequest.data}`, + ); + } + process.exit(0); +} + +main(); diff --git a/test/playground/decreaseLiquiditySingle4076939ZeroForOne.ts b/test/playground/decreaseLiquiditySingle4076939ZeroForOne.ts new file mode 100644 index 00000000..f12f1201 --- /dev/null +++ b/test/playground/decreaseLiquiditySingle4076939ZeroForOne.ts @@ -0,0 +1,90 @@ +// ts-node test/playground/decreaseLiquiditySingle4076939ZeroForOne.ts +import { RemoveLiquidityOptions } from '@aperture_finance/uniswap-v3-sdk'; +import { Percent } from '@uniswap/sdk-core'; +import { AutomatedMarketMakerEnum } from 'aperture-lens/dist/src/viem'; + +import { + ApertureSupportedChainId, + ConsoleLogger, + IOCKEY_LOGGER, + ioc, +} from '../../src'; +import { + DEFAULT_SOLVERS, + PositionDetails, + getDecreaseLiquiditySingleSwapInfo, + getDecreaseLiquiditySingleTx, + getPublicClient, +} from '../../src/viem'; + +async function main() { + ioc.registerSingleton(IOCKEY_LOGGER, ConsoleLogger); + const amm = AutomatedMarketMakerEnum.enum.UNISWAP_V3; + const chainId = ApertureSupportedChainId.ARBITRUM_MAINNET_CHAIN_ID; + const client = getPublicClient(chainId); + const from = '0x1fFd5d818187917E0043522C3bE583A393c2BbF7'; + const tokenId = 4076939; + const zeroForOne = true; + const isUnwrapNative = true; + const positionDetails = await PositionDetails.fromPositionId( + chainId, + amm, + BigInt(tokenId), + client, + ); + // token0 = airdrop = https://arbiscan.io/address/0xdc5F1BF636DcAdaE7e285A484Dc71A1F5adeE0A1 + // token1 = usdt = https://arbiscan.io/address/0xfd086bc7cd5c481dcc9c85ebe478a1c0b69fcbb9 + const decreaseLiquidityOptions: RemoveLiquidityOptions = { + tokenId, + liquidityPercentage: new Percent(100, 100), // position is $3.33 100%WETH. token0=weth, token1=usdc.. should take out $0.33 eth=.33/3116*1e18 token0amount = 1.06e14, $0.07 usdc + slippageTolerance: new Percent(1000, 1000), + deadline: Math.floor(Date.now() / 1000 + 60 * 30), + collectOptions: { + expectedCurrencyOwed0: positionDetails.tokensOwed0, + expectedCurrencyOwed1: positionDetails.tokensOwed1, + recipient: from, + }, + }; + const swapInfos = await getDecreaseLiquiditySingleSwapInfo( + decreaseLiquidityOptions, + chainId, + amm, + zeroForOne, + from, + /* tokenPricesUsd= */ ['0.001', '1'], + client, + isUnwrapNative, + DEFAULT_SOLVERS, + positionDetails, + ); + for (const swapInfo of swapInfos) { + const { + solver, + swapData, + amount0, + amount1, + token0FeeAmount, + token1FeeAmount, + } = swapInfo; + const txRequest = await getDecreaseLiquiditySingleTx( + decreaseLiquidityOptions, + zeroForOne, + from, + chainId, + amm, + client, + swapData, + positionDetails, + /* amount0Min= */ amount0, + /* amount1Min= */ amount1, + /* token0FeeAmount= */ token0FeeAmount, + /* token1FeeAmount= */ token1FeeAmount, + ); + console.log( + `solver=${solver}, liquidity: ${swapInfo.liquidity}, to=${txRequest.to}, from=${txRequest.from}, data=${txRequest.data}`, + ); + } + process.exit(0); +} + +main(); diff --git a/test/playground/decreaseLiquiditySingle4105824.ts b/test/playground/decreaseLiquiditySingle4105824.ts new file mode 100644 index 00000000..22ca19ca --- /dev/null +++ b/test/playground/decreaseLiquiditySingle4105824.ts @@ -0,0 +1,90 @@ +// ts-node test/playground/decreaseLiquiditySingle4105824.ts +import { RemoveLiquidityOptions } from '@aperture_finance/uniswap-v3-sdk'; +import { Percent } from '@uniswap/sdk-core'; +import { AutomatedMarketMakerEnum } from 'aperture-lens/dist/src/viem'; + +import { + ApertureSupportedChainId, + ConsoleLogger, + IOCKEY_LOGGER, + ioc, +} from '../../src'; +import { + DEFAULT_SOLVERS, + PositionDetails, + getDecreaseLiquiditySingleSwapInfo, + getDecreaseLiquiditySingleTx, + getPublicClient, +} from '../../src/viem'; + +async function main() { + ioc.registerSingleton(IOCKEY_LOGGER, ConsoleLogger); + const amm = AutomatedMarketMakerEnum.enum.UNISWAP_V3; + const chainId = ApertureSupportedChainId.ARBITRUM_MAINNET_CHAIN_ID; + const client = getPublicClient(chainId); + const from = '0x1fFd5d818187917E0043522C3bE583A393c2BbF7'; + const tokenId = 4105824; + const zeroForOne = true; + const isUnwrapNative = true; + const positionDetails = await PositionDetails.fromPositionId( + chainId, + amm, + BigInt(tokenId), + client, + ); + // token0 = weth = 0x82af49447d8a07e3bd95bd0d56f35241523fbab1 + // token1 = usdc = 0xaf88d065e77c8cc2239327c5edb3a432268e5831 + const decreaseLiquidityOptions: RemoveLiquidityOptions = { + tokenId, + liquidityPercentage: new Percent(10, 100), // position is $3.33 100%WETH. token0=weth, token1=usdc.. should take out $0.33 eth=.33/3116*1e18 token0amount = 1.06e14, $0.07 usdc + slippageTolerance: new Percent(5, 1000), + deadline: Math.floor(Date.now() / 1000 + 60 * 30), + collectOptions: { + expectedCurrencyOwed0: positionDetails.tokensOwed0, + expectedCurrencyOwed1: positionDetails.tokensOwed1, + recipient: from, + }, + }; + const swapInfos = await getDecreaseLiquiditySingleSwapInfo( + decreaseLiquidityOptions, + chainId, + amm, + zeroForOne, + from, + /* tokenPricesUsd= */ ['1', '1'], + client, + isUnwrapNative, + DEFAULT_SOLVERS, + positionDetails, + ); + for (const swapInfo of swapInfos) { + const { + solver, + swapData, + amount0, + amount1, + token0FeeAmount, + token1FeeAmount, + } = swapInfo; + const txRequest = await getDecreaseLiquiditySingleTx( + decreaseLiquidityOptions, + zeroForOne, + from, + chainId, + amm, + client, + swapData, + positionDetails, + /* amount0Min= */ amount0, + /* amount1Min= */ amount1, + /* token0FeeAmount= */ token0FeeAmount, + /* token1FeeAmount= */ token1FeeAmount, + ); + console.log( + `solver=${solver}, liquidity: ${swapInfo.liquidity}, to=${txRequest.to}, from=${txRequest.from}, data=${txRequest.data}`, + ); + } + process.exit(0); +} + +main(); diff --git a/test/playground/decreaseLiquiditySingle4109421WETH_USDC.ts b/test/playground/decreaseLiquiditySingle4109421WETH_USDC.ts new file mode 100644 index 00000000..72b34c6d --- /dev/null +++ b/test/playground/decreaseLiquiditySingle4109421WETH_USDC.ts @@ -0,0 +1,90 @@ +// ts-node test/playground/decreaseLiquiditySingle4109421WETH_USDC.ts +import { RemoveLiquidityOptions } from '@aperture_finance/uniswap-v3-sdk'; +import { Percent } from '@uniswap/sdk-core'; +import { AutomatedMarketMakerEnum } from 'aperture-lens/dist/src/viem'; + +import { + ApertureSupportedChainId, + ConsoleLogger, + IOCKEY_LOGGER, + ioc, +} from '../../src'; +import { + DEFAULT_SOLVERS, + PositionDetails, + getDecreaseLiquiditySingleSwapInfo, + getDecreaseLiquiditySingleTx, + getPublicClient, +} from '../../src/viem'; + +async function main() { + ioc.registerSingleton(IOCKEY_LOGGER, ConsoleLogger); + const amm = AutomatedMarketMakerEnum.enum.UNISWAP_V3; + const chainId = ApertureSupportedChainId.ARBITRUM_MAINNET_CHAIN_ID; + const client = getPublicClient(chainId); + const from = '0x1fFd5d818187917E0043522C3bE583A393c2BbF7'; + const tokenId = 4109421; + const zeroForOne = true; + const isUnwrapNative = true; + const positionDetails = await PositionDetails.fromPositionId( + chainId, + amm, + BigInt(tokenId), + client, + ); + // token0 = weth = 0x82af49447d8a07e3bd95bd0d56f35241523fbab1 = 100% + // token1 = usdc = 0xaf88d065e77c8cc2239327c5edb3a432268e5831 + const decreaseLiquidityOptions: RemoveLiquidityOptions = { + tokenId, + liquidityPercentage: new Percent(100, 100), // position is $3.33 100%WETH. token0=weth, token1=usdc.. should take out $0.33 eth=.33/3116*1e18 token0amount = 1.06e14, $0.07 usdc + slippageTolerance: new Percent(1000, 1000), + deadline: Math.floor(Date.now() / 1000 + 60 * 30), + collectOptions: { + expectedCurrencyOwed0: positionDetails.tokensOwed0, + expectedCurrencyOwed1: positionDetails.tokensOwed1, + recipient: from, + }, + }; + const swapInfos = await getDecreaseLiquiditySingleSwapInfo( + decreaseLiquidityOptions, + chainId, + amm, + zeroForOne, + from, + /* tokenPricesUsd= */ ['3225', '1'], + client, + isUnwrapNative, + DEFAULT_SOLVERS, + positionDetails, + ); + for (const swapInfo of swapInfos) { + const { + solver, + swapData, + amount0, + amount1, + token0FeeAmount, + token1FeeAmount, + } = swapInfo; + const txRequest = await getDecreaseLiquiditySingleTx( + decreaseLiquidityOptions, + zeroForOne, + from, + chainId, + amm, + client, + swapData, + positionDetails, + /* amount0Min= */ amount0, + /* amount1Min= */ amount1, + /* token0FeeAmount= */ token0FeeAmount, + /* token1FeeAmount= */ token1FeeAmount, + ); + console.log( + `solver=${solver}, liquidity: ${swapInfo.liquidity}, to=${txRequest.to}, from=${txRequest.from}, data=${txRequest.data}`, + ); + } + process.exit(0); +} + +main(); diff --git a/test/playground/increaseLiquidityOptimal4063431.ts b/test/playground/increaseLiquidityOptimal4063431.ts new file mode 100644 index 00000000..4b689516 --- /dev/null +++ b/test/playground/increaseLiquidityOptimal4063431.ts @@ -0,0 +1,95 @@ +// ts-node test/playground/increaseLiquidityOptimal4063431.ts +import { IncreaseOptions } from '@aperture_finance/uniswap-v3-sdk'; +import { CurrencyAmount, Percent } from '@uniswap/sdk-core'; +import { AutomatedMarketMakerEnum } from 'aperture-lens/dist/src/viem'; + +import { + ApertureSupportedChainId, + ConsoleLogger, + IOCKEY_LOGGER, + ioc, +} from '../../src'; +import { + DEFAULT_SOLVERS, + PositionDetails, + getIncreaseLiquidityOptimalSwapInfoV4, + getIncreaseLiquidityOptimalV4Tx, + getPublicClient, +} from '../../src/viem'; + +async function main() { + ioc.registerSingleton(IOCKEY_LOGGER, ConsoleLogger); + const amm = AutomatedMarketMakerEnum.enum.UNISWAP_V3; + const chainId = ApertureSupportedChainId.ARBITRUM_MAINNET_CHAIN_ID; + const client = getPublicClient(chainId); + const from = '0x1fFd5d818187917E0043522C3bE583A393c2BbF7'; + const tokenId = 4063431; + const positionDetails = await PositionDetails.fromPositionId( + chainId, + amm, + BigInt(tokenId), + client, + ); + // token0 = weth = 0x82af49447d8a07e3bd95bd0d56f35241523fbab1 + // token1 = usdc = 0xaf88d065e77c8cc2239327c5edb3a432268e5831 + const increaseOptions: IncreaseOptions = { + tokenId, + slippageTolerance: new Percent(5, 1000), + deadline: Math.floor(Date.now() / 1000 + 60 * 30), + }; + const swapInfos = await getIncreaseLiquidityOptimalSwapInfoV4( + increaseOptions, + chainId, + amm, + /* token0Amount= */ CurrencyAmount.fromRawAmount( + positionDetails.token0, + '100000000000000', + ), + /* token1Amount= */ CurrencyAmount.fromRawAmount( + positionDetails.token1, + '0', + ), + from, + /* tokenPricesUsd= */ ['3100', '1'], + client, + DEFAULT_SOLVERS, + positionDetails.position, + ); + for (const swapInfo of swapInfos) { + const { + solver, + swapData, + amount0, + amount1, + token0FeeAmount, + token1FeeAmount, + liquidity, + } = swapInfo; + const txRequest = await getIncreaseLiquidityOptimalV4Tx( + increaseOptions, + chainId, + amm, + /* token0Amount= */ CurrencyAmount.fromRawAmount( + positionDetails.token0, + amount0.toString(), + ), + /* token1Amount= */ CurrencyAmount.fromRawAmount( + positionDetails.token1, + amount1.toString(), + ), + from, + client, + swapData, + liquidity, + positionDetails.position, + /* token0FeeAmount= */ token0FeeAmount, + /* token1FeeAmount= */ token1FeeAmount, + ); + console.log( + `solver=${solver}, liquidity: ${swapInfo.liquidity}, txRequest=${JSON.stringify(txRequest)}`, + ); + } + process.exit(0); +} + +main(); diff --git a/test/playground/rebalance.ts b/test/playground/rebalance.ts new file mode 100644 index 00000000..f5be6b90 --- /dev/null +++ b/test/playground/rebalance.ts @@ -0,0 +1,66 @@ +// ts-node test/playground/rebalance.ts +import { AutomatedMarketMakerEnum } from 'aperture-lens/dist/src/viem'; + +import { + ApertureSupportedChainId, + ConsoleLogger, + IOCKEY_LOGGER, + ioc, +} from '../../src'; +import { + DEFAULT_SOLVERS, + PositionDetails, + getPublicClient, + getRebalanceSwapInfo, + getRebalanceSwapInfoV4, +} from '../../src/viem'; + +async function main() { + ioc.registerSingleton(IOCKEY_LOGGER, ConsoleLogger); + const amm = AutomatedMarketMakerEnum.enum.UNISWAP_V3; + const chainId = ApertureSupportedChainId.ARBITRUM_MAINNET_CHAIN_ID; + const client = getPublicClient(chainId); + const from = '0x1fFd5d818187917E0043522C3bE583A393c2BbF7'; + const tokenId = 4063431; + const positionDetails = await PositionDetails.fromPositionId( + chainId, + amm, + BigInt(tokenId), + client, + ); + // token0 = weth = 0x82af49447d8a07e3bd95bd0d56f35241523fbab1 + // token1 = usdc = 0xaf88d065e77c8cc2239327c5edb3a432268e5831 + const swapInfos = await getRebalanceSwapInfo( + chainId, + amm, + from, + BigInt(tokenId), + -196410, + -194400, + 0.005, + ['3225', '1'], + client, + DEFAULT_SOLVERS, + positionDetails, + ); + console.log(swapInfos); + console.log('done with rebalance v1 data'); + + const swapInfosV4 = await getRebalanceSwapInfoV4( + chainId, + amm, + from, + BigInt(tokenId), + -196410, + -194400, + 0.005, + ['3225', '1'], + client, + DEFAULT_SOLVERS, + positionDetails, + ); + console.log(swapInfosV4); + console.log('done with rebalanceV4 data'); +} + +main();