Documentation ¶
Index ¶
Constants ¶
View Source
const ( // 0 // VariantWrap to wrap spl tokens into fluid tokens VariantWrap = iota // VariantUnwrap to unwrap fluid tokens to spl tokens VariantUnwrap // VariantPayout to pay winnings to users VariantPayout // VariantInitSolendObligation to initialize solend accounts VariantInitSolendObligation // VariantLogTvl to write the current TVL to an account VariantLogTvl // 5 // VariantInitData to initialize contract account VariantInitData // VariantDrain to drain the prize pool VariantDrain // VariantUpdateMintLimits to update the mint caps VariantUpdateMintLimits // VariantUpdatePayoutLimits to update the amount that can be freely // minted VariantUpdatePayoutLimits // VariantUpdatePayoutAuthority to update the worker key VariantUpdatePayoutAuthority // 10 // VariantUpdateOperator to update the admin account VariantUpdateOperator // VariantConfirmUpdatePayoutAuthority to finalise a worker update VariantConfirmUpdatePayoutAuthority // VariantEmergency to lock down the contract VariantEmergency )
Variables ¶
View Source
var UnknownInstructionError = solana.UnknownInstructionError
Functions ¶
func GetBaseToken ¶
GetBaseToken takes a fluid token and returns its counterpart
Types ¶
type FluidityInstruction ¶
type FluidityInstruction struct { Wrap *FluidityWrap Unwrap *FluidityUnwrap Payout *FluidityPayout }
FluidityInstruction is a container storing a single variant of the decoded fluidity instruction enum
func DecodeFluidityInstruction ¶
func DecodeFluidityInstruction(data string) (FluidityInstruction, error)
DecodeFluidityInstruction tries to decode base58 encoded solana transaction data into a fluidity instruction
type FluidityPayout ¶
type FluidityPayout struct {
Value uint64
}
FluidityPayout represents Payout(u64), giving a reward payout to two users
type FluidityUnwrap ¶
type FluidityUnwrap struct {
Value uint64
}
FluidityUnwrap represents Unwrap(u64), converting from fluid -> normal tokens
type FluidityWrap ¶
type FluidityWrap struct {
Value uint64
}
FluidityWrap represents Wrap(u64), converting from normal -> fluid tokens
Click to show internal directories.
Click to hide internal directories.