mars

package
v0.18.0 Latest Latest
Warning

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

Go to latest
Published: Apr 3, 2022 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Bootstrap

type Bootstrap struct {
	*terra.Contract
	// contains filtered or unexported fields
}

func NewBootstrap

func NewBootstrap(ctx context.Context, lcd *terra.LCDClient) (*Bootstrap, error)

func (*Bootstrap) Config

func (b *Bootstrap) Config(ctx context.Context) (BootstrapConfig, error)

func (*Bootstrap) NewClaimRewardsMessage

func (b *Bootstrap) NewClaimRewardsMessage(withDrawUnlockedShares bool) (msg.Msg, error)

func (*Bootstrap) RewardPair

func (b *Bootstrap) RewardPair() terra.Pair

func (*Bootstrap) UserInfo

func (b *Bootstrap) UserInfo(ctx context.Context, address msg.AccAddress) (BootstrapUserInfo, error)

type BootstrapConfig

type BootstrapConfig struct {
	MarsUstPoolAddress string
}

type BootstrapUserInfo

type BootstrapUserInfo struct {
	WithdrawableLpShares decimal.Decimal `json:"withdrawable_lp_shares"`
}

type Field

type Field struct {
	*terra.Contract
}

func NewANCUSTField

func NewANCUSTField(lcd *terra.LCDClient) (*Field, error)

func NewField

func NewField(lcd *terra.LCDClient, address string) (*Field, error)

func (*Field) Snapshot

func (f *Field) Snapshot(ctx context.Context, address string) (FieldSnapshot, error)

type FieldSnapshot

type FieldSnapshot struct {
	PositionLpValue decimal.Decimal
	DebtValue       decimal.Decimal
	Ltv             decimal.Decimal
}

type Governance

type Governance struct {
	*terra.Contract
}

func NewGovernance

func NewGovernance(lcd *terra.LCDClient) (*Governance, error)

func (*Governance) NewStakeMessage

func (g *Governance) NewStakeMessage(amount decimal.Decimal) (msg.Msg, error)

type Mars added in v0.15.0

type Mars struct {
	Governance  *Governance
	Bootstrap   *Bootstrap
	ANCUSTField *Field
}

func NewMars added in v0.15.0

func NewMars(ctx context.Context, lcd *terra.LCDClient) (*Mars, error)

Jump to

Keyboard shortcuts

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