vesting

package
v0.2.19-beta.0 Latest Latest
Warning

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

Go to latest
Published: Nov 28, 2022 License: MIT Imports: 6 Imported by: 3

Documentation

Overview

nolint

Index

Constants

View Source
const (
	TotalGasSpawn1 = multisig.TotalGasSpawn1
	TotalGasSpawn2 = multisig.TotalGasSpawn2
	TotalGasSpawn3 = multisig.TotalGasSpawn3

	TotalGasSpend1 = multisig.TotalGasSpend1
	TotalGasSpend2 = multisig.TotalGasSpend2
	TotalGasSpend3 = multisig.TotalGasSpend3

	TotalGasDrainVault1 = 100
	TotalGasDrainVault2 = 200
	TotalGasDrainVault3 = 300
)
View Source
const MethodDrainVault = 17

MethodDrainVault is used to relay a call to drain a vault.

Variables

View Source
var (
	// TemplateAddress1 is an address for 1/n vesting wallet.
	TemplateAddress1 core.Address
	// TemplateAddress2 is an address for 2/n vesting wallet.
	TemplateAddress2 core.Address
	// TemplateAddress3 is an address for 3/n vesting wallet.
	TemplateAddress3 core.Address
)

Functions

func Register

func Register(reg *registry.Registry)

Register vesting templates.

Types

type DrainVaultArguments

type DrainVaultArguments struct {
	Vault core.Address
	vault.SpendArguments
}

DrainVaultArguments are arguments for drain vault method.

func (*DrainVaultArguments) DecodeScale

func (t *DrainVaultArguments) DecodeScale(dec *scale.Decoder) (total int, err error)

func (*DrainVaultArguments) EncodeScale

func (t *DrainVaultArguments) EncodeScale(enc *scale.Encoder) (total int, err error)

type Part

type Part = multisig.Part

Part of the multisig signature.

type Vesting

type Vesting struct {
	*multisig.MultiSig
}

Vesting is a mutlsig template that supports transaction to drain vault.

func (*Vesting) MaxSpend

func (v *Vesting) MaxSpend(method uint8, args any) (uint64, error)

MaxSpend returns zero for drain vault or forwards to multisig template.

Jump to

Keyboard shortcuts

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