forked from uniswap-python/uniswap-python
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtypes.py
More file actions
62 lines (46 loc) 路 966 Bytes
/
Copy pathtypes.py
File metadata and controls
62 lines (46 loc) 路 966 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
from dataclasses import dataclass
from typing import List, Union
from eth_typing.evm import Address, ChecksumAddress
AddressLike = Union[Address, ChecksumAddress]
# Uniswap V4 classes
@dataclass
class PoolKey:
currency0: str
currency1: str
fee: int
tick_spacing: int
hooks: str
@dataclass
class PathKey:
intermediate_currency: str
fee: int
tick_spacing: int
hooks: str
hook_data: bytes
@dataclass
class PermitDetails:
token: str
amount: int
expiration: int
nonce: int
@dataclass
class PermitSingle:
details: PermitDetails
spender: str
sig_deadline: int
@dataclass
class PermitBatch:
details: List[PermitDetails]
spender: str
sig_deadline: int
@dataclass
class ModifyLiquidityParams:
tick_lower: int
tick_upper: int
liquidity_delta: int
salt: int
@dataclass
class SwapParams:
zero_for_one: bool
amount_specified: int
sqrt_price_limit_x96: int