Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type LiquidityOtherInfo ¶
type LiquidityOtherInfo struct {
Liability decimal.Decimal // platypus Liability
Cash decimal.Decimal // platypus cash
CoverageRatio decimal.Decimal // platypus coverage ratio
}
Struct for other infos for special protocols.
type LiquidityPool ¶
type LiquidityPool struct {
ProtocolBasic *model.ProtocolBasic // protocol basic
PoolName string // pool name
LpToken *erc.ERC20Info // basic info of lp token
Tokens []*TokenOfLp // the tokens to make up the lp
ApyInfo *model.ApyInfo // apy info
Reserve decimal.Decimal // tvl in amount
ReserveUSD decimal.Decimal // tvl in usd
Volume24 decimal.Decimal // trade volume in 24 hours
OtherInfo *LiquidityOtherInfo // some other infos for special protocols
}
Struct for liquidity pools.
func (*LiquidityPool) Init ¶ added in v0.2.1
func (p *LiquidityPool) Init(protocolBasic model.ProtocolBasic) error
type TokenOfLp ¶
type TokenOfLp struct {
Basic *erc.ERC20Info // basic info of token
Underlying *erc.ERC20Info // basic info of underlying token, if has no underlying, use basic
Reserve decimal.Decimal // reserve of the single token in amount
ReserveUSD decimal.Decimal // reserve of the single token in usd
}
Struct for tokens to make up lp token.
Click to show internal directories.
Click to hide internal directories.