utils

package
v2.0.0-beta.3 Latest Latest
Warning

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

Go to latest
Published: Jul 27, 2022 License: Apache-2.0 Imports: 11 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ShortenedHash

func ShortenedHash(hash iotago.BlockID) string

ShortenedHash returns a shortened hex encoded hash for the given hash. this is used for the dot file.

func ShortenedTag

func ShortenedTag(cachedBlock *storage.CachedBlock) string

ShortenedTag returns a shortened tag or milestone index for the given block. this is used for the dot file.

func ShowDotFile

func ShowDotFile(testInterface testing.TB, dotCommand string, outFilePath string)

ShowDotFile creates a png file with dot and shows it in an external application.

Types

type HDWallet

type HDWallet struct {
	// contains filtered or unexported fields
}

func NewHDWallet

func NewHDWallet(name string, seed []byte, index uint64) *HDWallet

func (*HDWallet) Address

func (hd *HDWallet) Address() *iotago.Ed25519Address

Address calculates an ed25519 address by using slip10.

func (*HDWallet) AddressSigner

func (hd *HDWallet) AddressSigner() iotago.AddressSigner

func (*HDWallet) Balance

func (hd *HDWallet) Balance() uint64

func (*HDWallet) BookOutput

func (hd *HDWallet) BookOutput(output *utxo.Output)

func (*HDWallet) BookSpent

func (hd *HDWallet) BookSpent(spentOutput *utxo.Output)

func (*HDWallet) BookSpents

func (hd *HDWallet) BookSpents(spentOutputs []*utxo.Output)

func (*HDWallet) KeyPair

func (hd *HDWallet) KeyPair() (ed25519.PrivateKey, ed25519.PublicKey)

KeyPair calculates an ed25519 key pair by using slip10.

func (*HDWallet) Name

func (hd *HDWallet) Name() string

func (*HDWallet) Outputs

func (hd *HDWallet) Outputs() []*utxo.Output

func (*HDWallet) PrintStatus

func (hd *HDWallet) PrintStatus()

Jump to

Keyboard shortcuts

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