DusaV0Library
Table of contents
Constructors
Methods
Constructors
constructor
• new DusaV0Library(): DusaV0Library
Returns
Methods
getAmountIn
▸ getAmountIn(amountOut
, reserveIn
, reserveOut
): u256
Parameters
Name | Type |
---|---|
amountOut | u256 |
reserveIn | u256 |
reserveOut | u256 |
Returns
u256
Defined in
assembly/libraries/DusaV0Library.ts:51
getAmountOut
▸ getAmountOut(amountIn
, reserveIn
, reserveOut
): u256
Parameters
Name | Type |
---|---|
amountIn | u256 |
reserveIn | u256 |
reserveOut | u256 |
Returns
u256
Defined in
assembly/libraries/DusaV0Library.ts:35
getAmountsIn
▸ getAmountsIn(factory
, amountOut
, path
): u256
[]
Parameters
Name | Type |
---|---|
factory | IV0Factory |
amountOut | u256 |
path | Address [] |
Returns
u256
[]
Defined in
assembly/libraries/DusaV0Library.ts:90
getAmountsOut
▸ getAmountsOut(factory
, amountIn
, path
): u256
[]
Parameters
Name | Type |
---|---|
factory | IV0Factory |
amountIn | u256 |
path | Address [] |
Returns
u256
[]
Defined in
assembly/libraries/DusaV0Library.ts:69
getReserves
▸ getReserves(factory
, tokenA
, tokenB
): Amounts
Parameters
Name | Type |
---|---|
factory | IV0Factory |
tokenA | Address |
tokenB | Address |
Returns
Amounts
Defined in
assembly/libraries/DusaV0Library.ts:11
quote
▸ quote(amountA
, reserveA
, reserveB
): u256
Parameters
Name | Type |
---|---|
amountA | u256 |
reserveA | u256 |
reserveB | u256 |
Returns
u256