Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • SolendMarket

Index

Constructors

Private constructor

Properties

config

Private connection

connection: Connection

programId

programId: PublicKey

reserves

reserves: SolendReserve[]

rewardsData

rewardsData: null | RewardsDataType

Methods

fetchObligationByWallet

Private getLatestRewardRate

  • getLatestRewardRate(rewardRates: { beginningSlot: number; name?: string; rewardRate: string }[], slot: number): { beginningSlot: number; name?: string; rewardRate: string }
  • Parameters

    • rewardRates: { beginningSlot: number; name?: string; rewardRate: string }[]
    • slot: number

    Returns { beginningSlot: number; name?: string; rewardRate: string }

    • beginningSlot: number
    • Optional name?: string
    • rewardRate: string

loadAll

  • loadAll(): Promise<void>

Private loadExternalRewardData

  • loadExternalRewardData(): Promise<({ lastSlot: number; rewardRates: { beginningSlot: number; name?: string; rewardRate: string }[]; rewardsPerShare: string; totalBalance: string } & { reserveID: string; rewardMint: string; rewardSymbol: string; side: "borrow" | "supply" })[]>
  • Returns Promise<({ lastSlot: number; rewardRates: { beginningSlot: number; name?: string; rewardRate: string }[]; rewardsPerShare: string; totalBalance: string } & { reserveID: string; rewardMint: string; rewardSymbol: string; side: "borrow" | "supply" })[]>

Private loadPriceData

  • loadPriceData(symbols: string[]): Promise<{}>

loadReserves

  • loadReserves(): Promise<void>

loadRewards

  • loadRewards(): Promise<void>

refreshAll

  • refreshAll(): Promise<void>

Static initialize

  • initialize(connection: Connection, environment?: "production" | "devnet" | "beta", marketAddress?: string): Promise<SolendMarket>
  • Parameters

    • connection: Connection
    • environment: "production" | "devnet" | "beta" = "production"
    • Optional marketAddress: string

    Returns Promise<SolendMarket>

Generated using TypeDoc