Documentation ¶
Index ¶
- type CapProvider_CoinMarketCap
- func (p *CapProvider_CoinMarketCap) GetEthCap() (*big.Rat, error)
- func (p *CapProvider_CoinMarketCap) GetMarketCap(tokenAddress common.Address) (*big.Rat, error)
- func (p *CapProvider_CoinMarketCap) GetMarketCapByCurrency(tokenAddress common.Address, currencyStr string) (*big.Rat, error)
- func (p *CapProvider_CoinMarketCap) LegalCurrencyValue(tokenAddress common.Address, amount *big.Rat) (*big.Rat, error)
- func (p *CapProvider_CoinMarketCap) LegalCurrencyValueByCurrency(tokenAddress common.Address, amount *big.Rat, currencyStr string) (*big.Rat, error)
- func (p *CapProvider_CoinMarketCap) LegalCurrencyValueOfEth(amount *big.Rat) (*big.Rat, error)
- func (p *CapProvider_CoinMarketCap) Start()
- func (p *CapProvider_CoinMarketCap) Stop()
- type CapProvider_LocalCap
- type LegalCurrency
- type MarketCapProvider
- type MixMarketCap
- func (cap *MixMarketCap) GetEthCap() (*big.Rat, error)
- func (cap *MixMarketCap) GetMarketCap(tokenAddress common.Address) (*big.Rat, error)
- func (cap *MixMarketCap) GetMarketCapByCurrency(tokenAddress common.Address, currencyStr string) (*big.Rat, error)
- func (cap *MixMarketCap) LegalCurrencyValue(tokenAddress common.Address, amount *big.Rat) (*big.Rat, error)
- func (cap *MixMarketCap) LegalCurrencyValueByCurrency(tokenAddress common.Address, amount *big.Rat, currencyStr string) (*big.Rat, error)
- func (cap *MixMarketCap) LegalCurrencyValueOfEth(amount *big.Rat) (*big.Rat, error)
- func (cap *MixMarketCap) Start()
- func (cap *MixMarketCap) Stop()
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CapProvider_CoinMarketCap ¶
type CapProvider_CoinMarketCap struct {
// contains filtered or unexported fields
}
func NewMarketCapProvider ¶
func NewMarketCapProvider(options config.MarketCapOptions) *CapProvider_CoinMarketCap
func (*CapProvider_CoinMarketCap) GetEthCap ¶
func (p *CapProvider_CoinMarketCap) GetEthCap() (*big.Rat, error)
func (*CapProvider_CoinMarketCap) GetMarketCap ¶
func (*CapProvider_CoinMarketCap) GetMarketCapByCurrency ¶
func (*CapProvider_CoinMarketCap) LegalCurrencyValue ¶
func (*CapProvider_CoinMarketCap) LegalCurrencyValueByCurrency ¶
func (*CapProvider_CoinMarketCap) LegalCurrencyValueOfEth ¶
func (*CapProvider_CoinMarketCap) Start ¶
func (p *CapProvider_CoinMarketCap) Start()
func (*CapProvider_CoinMarketCap) Stop ¶
func (p *CapProvider_CoinMarketCap) Stop()
type CapProvider_LocalCap ¶
type CapProvider_LocalCap struct {
// contains filtered or unexported fields
}
func (*CapProvider_LocalCap) Start ¶
func (cap *CapProvider_LocalCap) Start()
func (*CapProvider_LocalCap) Stop ¶
func (cap *CapProvider_LocalCap) Stop()
type LegalCurrency ¶
type LegalCurrency int
const ( CNY LegalCurrency = iota USD EUR BTC )
func StringToLegalCurrency ¶
func StringToLegalCurrency(currency string) LegalCurrency
type MarketCapProvider ¶
type MarketCapProvider interface { Start() Stop() LegalCurrencyValue(tokenAddress common.Address, amount *big.Rat) (*big.Rat, error) LegalCurrencyValueOfEth(amount *big.Rat) (*big.Rat, error) LegalCurrencyValueByCurrency(tokenAddress common.Address, amount *big.Rat, currencyStr string) (*big.Rat, error) GetMarketCap(tokenAddress common.Address) (*big.Rat, error) GetEthCap() (*big.Rat, error) GetMarketCapByCurrency(tokenAddress common.Address, currencyStr string) (*big.Rat, error) }
type MixMarketCap ¶
type MixMarketCap struct {
// contains filtered or unexported fields
}
func (*MixMarketCap) GetMarketCap ¶
func (*MixMarketCap) GetMarketCapByCurrency ¶
func (*MixMarketCap) LegalCurrencyValue ¶
func (*MixMarketCap) LegalCurrencyValueByCurrency ¶
func (*MixMarketCap) LegalCurrencyValueOfEth ¶
func (*MixMarketCap) Start ¶
func (cap *MixMarketCap) Start()
func (*MixMarketCap) Stop ¶
func (cap *MixMarketCap) Stop()
Click to show internal directories.
Click to hide internal directories.