Documentation ¶
Index ¶
- func GetITokenAddress(genSdk *ontSDK.OntologySdk, ftokenAddress common.Address) (common.Address, error)
- type AccountSnapshot
- type FlashToken
- func (this *FlashToken) AcceptAdmin() (string, error)
- func (this *FlashToken) AccountSnapshot(owner common.Address) (*AccountSnapshot, error)
- func (this *FlashToken) AccrualBlockNumber() (uint32, error)
- func (this *FlashToken) AccrualTimestamp() (uint64, error)
- func (this *FlashToken) AccrueInterest() (string, error)
- func (this *FlashToken) AddInsurance(from common.Address, addAmount *big.Int) (string, error)
- func (this *FlashToken) AddReserves(from common.Address, addAmount *big.Int) (string, error)
- func (this *FlashToken) Admin() (common.Address, error)
- func (this *FlashToken) Allowance(owner, spender common.Address) (*big.Int, error)
- func (this *FlashToken) Approve(owner, spender common.Address, amount *big.Int) (string, error)
- func (this *FlashToken) BalanceOf(owner common.Address) (*big.Int, error)
- func (this *FlashToken) BalanceOfUnderlying(owner common.Address) (*big.Int, error)
- func (this *FlashToken) Borrow(borrower common.Address, borrowAmount *big.Int, useWing bool) (string, error)
- func (this *FlashToken) BorrowBalanceStored(account common.Address) (*big.Int, *big.Int, error)
- func (this *FlashToken) BorrowIndex() (*big.Int, error)
- func (this *FlashToken) BorrowRatePerBlock() (*big.Int, error)
- func (this *FlashToken) Decimals() (string, error)
- func (this *FlashToken) ExchangeRateStored() (*big.Int, error)
- func (this *FlashToken) GetAddr() common.Address
- func (this *FlashToken) GetCash() (*big.Int, error)
- func (this *FlashToken) GetComptroller() (common.Address, error)
- func (this *FlashToken) GetGoSdk() *ontSDK.OntologySdk
- func (this *FlashToken) GetInsuranceRedeemApply(account common.Address) (*big.Int, error)
- func (this *FlashToken) GetLastSettleTime() (*big.Int, error)
- func (this *FlashToken) GetRedeemApplyTotal() (*big.Int, error)
- func (this *FlashToken) GetSettleInterval() (*big.Int, error)
- func (this *FlashToken) GetSettlementAmtMax() (*big.Int, error)
- func (this *FlashToken) GetSigner() ontSDK.Account
- func (this *FlashToken) GlobalParam() (common.Address, error)
- func (this *FlashToken) Init(admin, underlying_ common.Address, underlyingName string, ...) (string, error)
- func (this *FlashToken) InitialExchangeRateMantissa() (*big.Int, error)
- func (this *FlashToken) InsuranceAddr() (common.Address, error)
- func (this *FlashToken) InsuranceFactorMantissa() (*big.Int, error)
- func (this *FlashToken) InsuranceMintPaused() (bool, error)
- func (this *FlashToken) InterestRateModel() (common.Address, error)
- func (this *FlashToken) IsFToken() (bool, error)
- func (this *FlashToken) IsInsurance() (bool, error)
- func (this *FlashToken) LiquidateBorrow(liquidator, borrower, tokenCollateral common.Address, repayAmount *big.Int) (string, error)
- func (this *FlashToken) MarketAddr() (common.Address, error)
- func (this *FlashToken) Mint(minter common.Address, mintAmount *big.Int) (string, error)
- func (this *FlashToken) Name() (string, error)
- func (this *FlashToken) NativeApprove(owner, spender common.Address, amount *big.Int) (string, error)
- func (this *FlashToken) NeoVMApprove(owner, spender common.Address, amount *big.Int) (string, error)
- func (this *FlashToken) NeoVMBalanceOf(owner common.Address) (*big.Int, error)
- func (this *FlashToken) PendingAdmin() (common.Address, error)
- func (this *FlashToken) PutSettleInterval(interval uint64) (string, error)
- func (this *FlashToken) PutSettlementAmtMax(amt *big.Int) (string, error)
- func (this *FlashToken) Redeem(redeemer common.Address, redeemTokens *big.Int) (string, error)
- func (this *FlashToken) RedeemApply(redeemer common.Address, redeemTokens *big.Int) (string, error)
- func (this *FlashToken) RedeemApplySettlement() (string, error)
- func (this *FlashToken) RedeemUnderlying(redeemer common.Address, redeemAmount *big.Int) (string, error)
- func (this *FlashToken) ReduceReserves(reduceAmount *big.Int) (string, error)
- func (this *FlashToken) RepayBorrow(borrower common.Address, repayAmount *big.Int) (string, error)
- func (this *FlashToken) RepayBorrowBehalf(payer, borrower common.Address, repayAmount *big.Int) (string, error)
- func (this *FlashToken) ReserveFactorMantissa() (*big.Int, error)
- func (this *FlashToken) SetAddr(address common.Address)
- func (this *FlashToken) SetComptroller(comptroller common.Address) (string, error)
- func (this *FlashToken) SetGlobalParam(globalParam common.Address) (string, error)
- func (this *FlashToken) SetInsuranceAddr(insurance common.Address) (string, error)
- func (this *FlashToken) SetInsuranceFactor(factor *big.Int) (string, error)
- func (this *FlashToken) SetInterestRateModel(interestRateModel common.Address) (string, error)
- func (this *FlashToken) SetMarketAddr(market common.Address) (string, error)
- func (this *FlashToken) SetPendingAdmin(pendingAdmin common.Address) (string, error)
- func (this *FlashToken) SetPriceOracle(oracle common.Address) (string, error)
- func (this *FlashToken) SetReserveFactor(factor *big.Int) (string, error)
- func (this *FlashToken) SupplyRatePerBlock() (*big.Int, error)
- func (this *FlashToken) Symbol() (string, error)
- func (this *FlashToken) TestBorrowRate(marketName, addr string)
- func (this *FlashToken) TestBorrowRate2Supply(marketName, addr string)
- func (this *FlashToken) TestBorrowRateSync(marketName, addr string, sy *sync.WaitGroup)
- func (this *FlashToken) TotalBorrows() (*big.Int, error)
- func (this *FlashToken) TotalInsurance() (*big.Int, error)
- func (this *FlashToken) TotalReserves() (*big.Int, error)
- func (this *FlashToken) TotalSupply() (*big.Int, error)
- func (this *FlashToken) TotalValidBorrows() (*big.Int, error)
- func (this *FlashToken) Transfer(from, to common.Address, amount *big.Int) (string, error)
- func (this *FlashToken) TransferFrom(from, src, to common.Address, amount *big.Int) (string, error)
- func (this *FlashToken) Underlying() common.Address
- func (this *FlashToken) UnderlyingName() (string, error)
- func (this *FlashToken) UpdateInsuranceMintPaused(state bool) (string, error)
- func (this *FlashToken) UpdateSigner(newSigner *ontSDK.Account)
- func (this *FlashToken) WingSpeed4BorrowTestNew(userAddr string)
- func (this *FlashToken) WingSpeed4BorrowTestNewByMarketAddr(marketAddr common.Address, userAddr string, sy *sync.WaitGroup)
- func (this *FlashToken) WingSpeed4BorrowTestNewByMarketName(marketName, userAddr string)
- func (this *FlashToken) WingSpeed4SuppluyTestNew(marketAddr common.Address, userAddr string, sy *sync.WaitGroup)
- func (this *FlashToken) WingSpeed4SupplyAndBorrowTestByName(marketName, userAddr string)
- func (this *FlashToken) WingSpeed4SupplyTest(userAddr string)
- func (this *FlashToken) WingSpeed4SupplyTestByName(marketName, userAddr string)
- func (this *FlashToken) WingSpeedByNameNew(marketName, userAddr string)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetITokenAddress ¶
Types ¶
type AccountSnapshot ¶
type AccountSnapshot struct { TokenBalance *big.Int BorrowBalance *big.Int ValidBorrowBalance *big.Int ExchangeRate *big.Int }
func DeserializeAccountSnapshot ¶
func DeserializeAccountSnapshot(data []byte) (*AccountSnapshot, error)
type FlashToken ¶
type FlashToken struct { WingGov common.Address Comptroller *comptroller.Comptroller TestConfig *config.Config // contains filtered or unexported fields }
func NewFlashToken ¶
func NewFlashToken(sdk *ontSDK.OntologySdk, contractAddr string, signer *ontSDK.Account, gasPrice, gasLimit uint64) (*FlashToken, error)
func NewFlashToken2 ¶
func NewFlashToken2(sdk *ontSDK.OntologySdk, contractAddr string, signer *ontSDK.Account, cfg *config.Config, comptroller *comptroller.Comptroller) (*FlashToken, error)
func (*FlashToken) AcceptAdmin ¶
func (this *FlashToken) AcceptAdmin() (string, error)
func (*FlashToken) AccountSnapshot ¶
func (this *FlashToken) AccountSnapshot(owner common.Address) (*AccountSnapshot, error)
func (*FlashToken) AccrualBlockNumber ¶
func (this *FlashToken) AccrualBlockNumber() (uint32, error)
func (*FlashToken) AccrualTimestamp ¶
func (this *FlashToken) AccrualTimestamp() (uint64, error)
func (*FlashToken) AccrueInterest ¶
func (this *FlashToken) AccrueInterest() (string, error)
func (*FlashToken) AddInsurance ¶
func (*FlashToken) AddReserves ¶
func (*FlashToken) BalanceOfUnderlying ¶
func (*FlashToken) BorrowBalanceStored ¶
func (*FlashToken) BorrowIndex ¶
func (this *FlashToken) BorrowIndex() (*big.Int, error)
func (*FlashToken) BorrowRatePerBlock ¶
func (this *FlashToken) BorrowRatePerBlock() (*big.Int, error)
func (*FlashToken) Decimals ¶
func (this *FlashToken) Decimals() (string, error)
func (*FlashToken) ExchangeRateStored ¶
func (this *FlashToken) ExchangeRateStored() (*big.Int, error)
func (*FlashToken) GetAddr ¶
func (this *FlashToken) GetAddr() common.Address
func (*FlashToken) GetComptroller ¶
func (this *FlashToken) GetComptroller() (common.Address, error)
func (*FlashToken) GetGoSdk ¶
func (this *FlashToken) GetGoSdk() *ontSDK.OntologySdk
func (*FlashToken) GetInsuranceRedeemApply ¶
func (*FlashToken) GetLastSettleTime ¶
func (this *FlashToken) GetLastSettleTime() (*big.Int, error)
func (*FlashToken) GetRedeemApplyTotal ¶
func (this *FlashToken) GetRedeemApplyTotal() (*big.Int, error)
func (*FlashToken) GetSettleInterval ¶
func (this *FlashToken) GetSettleInterval() (*big.Int, error)
func (*FlashToken) GetSettlementAmtMax ¶
func (this *FlashToken) GetSettlementAmtMax() (*big.Int, error)
func (*FlashToken) GetSigner ¶
func (this *FlashToken) GetSigner() ontSDK.Account
func (*FlashToken) GlobalParam ¶
func (this *FlashToken) GlobalParam() (common.Address, error)
func (*FlashToken) InitialExchangeRateMantissa ¶
func (this *FlashToken) InitialExchangeRateMantissa() (*big.Int, error)
func (*FlashToken) InsuranceAddr ¶
func (this *FlashToken) InsuranceAddr() (common.Address, error)
func (*FlashToken) InsuranceFactorMantissa ¶
func (this *FlashToken) InsuranceFactorMantissa() (*big.Int, error)
func (*FlashToken) InsuranceMintPaused ¶
func (this *FlashToken) InsuranceMintPaused() (bool, error)
func (*FlashToken) InterestRateModel ¶
func (this *FlashToken) InterestRateModel() (common.Address, error)
func (*FlashToken) IsFToken ¶
func (this *FlashToken) IsFToken() (bool, error)
func (*FlashToken) IsInsurance ¶
func (this *FlashToken) IsInsurance() (bool, error)
func (*FlashToken) LiquidateBorrow ¶
func (*FlashToken) MarketAddr ¶
func (this *FlashToken) MarketAddr() (common.Address, error)
func (*FlashToken) Name ¶
func (this *FlashToken) Name() (string, error)
func (*FlashToken) NativeApprove ¶
func (*FlashToken) NeoVMApprove ¶
func (*FlashToken) NeoVMBalanceOf ¶
func (*FlashToken) PendingAdmin ¶
func (this *FlashToken) PendingAdmin() (common.Address, error)
func (*FlashToken) PutSettleInterval ¶
func (this *FlashToken) PutSettleInterval(interval uint64) (string, error)
func (*FlashToken) PutSettlementAmtMax ¶
func (this *FlashToken) PutSettlementAmtMax(amt *big.Int) (string, error)
func (*FlashToken) RedeemApply ¶
func (*FlashToken) RedeemApplySettlement ¶
func (this *FlashToken) RedeemApplySettlement() (string, error)
func (*FlashToken) RedeemUnderlying ¶
func (*FlashToken) ReduceReserves ¶
func (this *FlashToken) ReduceReserves(reduceAmount *big.Int) (string, error)
func (*FlashToken) RepayBorrow ¶
func (*FlashToken) RepayBorrowBehalf ¶
func (*FlashToken) ReserveFactorMantissa ¶
func (this *FlashToken) ReserveFactorMantissa() (*big.Int, error)
func (*FlashToken) SetAddr ¶
func (this *FlashToken) SetAddr(address common.Address)
func (*FlashToken) SetComptroller ¶
func (this *FlashToken) SetComptroller(comptroller common.Address) (string, error)
func (*FlashToken) SetGlobalParam ¶
func (this *FlashToken) SetGlobalParam(globalParam common.Address) (string, error)
func (*FlashToken) SetInsuranceAddr ¶
func (this *FlashToken) SetInsuranceAddr(insurance common.Address) (string, error)
func (*FlashToken) SetInsuranceFactor ¶
func (this *FlashToken) SetInsuranceFactor(factor *big.Int) (string, error)
func (*FlashToken) SetInterestRateModel ¶
func (this *FlashToken) SetInterestRateModel(interestRateModel common.Address) (string, error)
func (*FlashToken) SetMarketAddr ¶
func (this *FlashToken) SetMarketAddr(market common.Address) (string, error)
func (*FlashToken) SetPendingAdmin ¶
func (this *FlashToken) SetPendingAdmin(pendingAdmin common.Address) (string, error)
func (*FlashToken) SetPriceOracle ¶
func (this *FlashToken) SetPriceOracle(oracle common.Address) (string, error)
func (*FlashToken) SetReserveFactor ¶
func (this *FlashToken) SetReserveFactor(factor *big.Int) (string, error)
func (*FlashToken) SupplyRatePerBlock ¶
func (this *FlashToken) SupplyRatePerBlock() (*big.Int, error)
func (*FlashToken) Symbol ¶
func (this *FlashToken) Symbol() (string, error)
func (*FlashToken) TestBorrowRate ¶
func (this *FlashToken) TestBorrowRate(marketName, addr string)
1.use market name and usraddr
func (*FlashToken) TestBorrowRate2Supply ¶
func (this *FlashToken) TestBorrowRate2Supply(marketName, addr string)
1.use market name and usraddr
func (*FlashToken) TestBorrowRateSync ¶
func (this *FlashToken) TestBorrowRateSync(marketName, addr string, sy *sync.WaitGroup)
1.use market name and usraddr
func (*FlashToken) TotalBorrows ¶
func (this *FlashToken) TotalBorrows() (*big.Int, error)
func (*FlashToken) TotalInsurance ¶
func (this *FlashToken) TotalInsurance() (*big.Int, error)
func (*FlashToken) TotalReserves ¶
func (this *FlashToken) TotalReserves() (*big.Int, error)
func (*FlashToken) TotalSupply ¶
func (this *FlashToken) TotalSupply() (*big.Int, error)
func (*FlashToken) TotalValidBorrows ¶
func (this *FlashToken) TotalValidBorrows() (*big.Int, error)
func (*FlashToken) TransferFrom ¶
func (*FlashToken) Underlying ¶
func (this *FlashToken) Underlying() common.Address
func (*FlashToken) UnderlyingName ¶
func (this *FlashToken) UnderlyingName() (string, error)
func (*FlashToken) UpdateInsuranceMintPaused ¶
func (this *FlashToken) UpdateInsuranceMintPaused(state bool) (string, error)
func (*FlashToken) UpdateSigner ¶
func (this *FlashToken) UpdateSigner(newSigner *ontSDK.Account)
func (*FlashToken) WingSpeed4BorrowTestNew ¶
func (this *FlashToken) WingSpeed4BorrowTestNew(userAddr string)
func (*FlashToken) WingSpeed4BorrowTestNewByMarketAddr ¶
func (*FlashToken) WingSpeed4BorrowTestNewByMarketName ¶
func (this *FlashToken) WingSpeed4BorrowTestNewByMarketName(marketName, userAddr string)
func (*FlashToken) WingSpeed4SuppluyTestNew ¶
func (*FlashToken) WingSpeed4SupplyAndBorrowTestByName ¶
func (this *FlashToken) WingSpeed4SupplyAndBorrowTestByName(marketName, userAddr string)
func (*FlashToken) WingSpeed4SupplyTest ¶
func (this *FlashToken) WingSpeed4SupplyTest(userAddr string)
func (*FlashToken) WingSpeed4SupplyTestByName ¶
func (this *FlashToken) WingSpeed4SupplyTestByName(marketName, userAddr string)
func (*FlashToken) WingSpeedByNameNew ¶
func (this *FlashToken) WingSpeedByNameNew(marketName, userAddr string)
Click to show internal directories.
Click to hide internal directories.