getShareOfPool

function getShareOfPool(
    address _token, 
    uint _amountDesired,  
    bool _owned
)external view returns (uint poolRatio)

μŠ€ν…Œμ΄ν‚Ή μ§€λΆ„μœ¨ ꡬ할 λ•Œ μ‚¬μš©

Parameters

Return Values

Example

// μ§€λΆ„μœ¨ μ–»κΈ°(값에 μ˜ν•œ)
await stakingRouterContract.getShareOfPool(
    mockToken0Contract.address,
    ethers.utils.parseEther("0.1"),
    false
)

// κ²°κ³Ό (0.99%의 영ν–₯도)
BigNumber { value: "99" }

// μ§€λΆ„μœ¨ μ–»κΈ°(μ†Œμœ μ€‘μΈ)
await stakingRouterContract.getShareOfPool(
    mockToken0Contract.address,
    0,
    true
)

// κ²°κ³Ό (100%의 영ν–₯도)
BigNumber { value: "10000" }

2022.12.23

Last updated