vesting

package
v1.4.2 Latest Latest
Warning

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

Go to latest
Published: Mar 20, 2024 License: MIT Imports: 5 Imported by: 3

Documentation

Overview

nolint

Index

Constants

View Source
const MethodDrainVault = 17

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

Variables

View Source
var TemplateAddress core.Address

Functions

func BaseGas

func BaseGas(method uint8, signatures int) uint64

func ExecGas

func ExecGas(method uint8, keys int) uint64

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) BaseGas

func (v *Vesting) BaseGas(method uint8) uint64

func (*Vesting) ExecGas

func (v *Vesting) ExecGas(method uint8) uint64

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