lendaavelike

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 19, 2022 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

map[protocol name][network][underlying] = a token.

map[protocol name][network][underlying] = s token.

map[protocol name][network][underlying] = v token.

Functions

This section is empty.

Types

type AToken

type AToken struct {
	ProtocolBasic   *model.ProtocolBasic
	Basic           *erc.ERC20Info // basic info of the token
	UnderlyingBasic *erc.ERC20Info // basic info of the underlying token
	ApyInfo         apy.ApyInfo    // deposit apy info
}

func (*AToken) GetUnderlyingAddress

func (t *AToken) GetUnderlyingAddress(atoken string) (string, error)

Use a token address to get underlying address.

func (*AToken) UpdateATokenByUnderlying

func (t *AToken) UpdateATokenByUnderlying(underlying string) error

Use underlying address to update a token info.

type SToken

type SToken struct {
	ProtocolBasic   *model.ProtocolBasic
	Basic           *erc.ERC20Info // basic info of the token
	UnderlyingBasic *erc.ERC20Info // basic info of the underlying token
	ApyInfo         apy.ApyInfo    // borrow stable apy info
}

func (*SToken) GetUnderlyingAddress

func (t *SToken) GetUnderlyingAddress(stoken string) (string, error)

Use s token address to get underlying address.

func (*SToken) UpdateSTokenByUnderlying

func (t *SToken) UpdateSTokenByUnderlying(underlying string) error

Use underlying address to update s token info.

type VToken

type VToken struct {
	ProtocolBasic   *model.ProtocolBasic
	Basic           *erc.ERC20Info // basic info of the token
	UnderlyingBasic *erc.ERC20Info // basic info of the underlying token
	ApyInfo         apy.ApyInfo    // borrow variable apy info
}

func (*VToken) GetUnderlyingAddress

func (t *VToken) GetUnderlyingAddress(vtoken string) (string, error)

Use v token address to get underlying address.

func (*VToken) UpdateVTokenByUnderlying

func (t *VToken) UpdateVTokenByUnderlying(underlying string) error

Use underlying address to update v token info.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL