interop

package
v0.0.0-...-84b0f9f Latest Latest
Warning

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

Go to latest
Published: Nov 7, 2024 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	LegacyTxType     = types.LegacyTxType
	AccessListTxType = types.AccessListTxType
	DynamicFeeTxType = types.DynamicFeeTxType
	BlobTxType       = types.BlobTxType
	BTCTxType        = 0x04
)

Transaction types.

Variables

This section is empty.

Functions

func ConvBlock

func ConvBlock(block *wire.MsgBlock) (*types.Block, error)

func ConvBlockHeader

func ConvBlockHeader(header *wire.BlockHeader) (*types.Header, error)

func ConvReceipts

func ConvReceipts(tx *wire.MsgTx) (*types.Receipt, error)

Types

type Account

type Account struct {
	PubKey        []byte
	AddressP2PK   string
	AddressP2PKH  string
	AddressP2WPKH string
	AddressP2TR   string
	AddressEth    string
	// contains filtered or unexported fields
}

Account represents a blockchain account derived from a public key.

func NewAccount

func NewAccount(pubKey []byte, params *chaincfg.Params) *Account

NewAccount creates a new Account instance for a given public key and network parameters.

func (*Account) GenerateAddresses

func (a *Account) GenerateAddresses() error

GenerateAddresses generates all supported addresses (P2PK, P2PKH, P2WPKH, P2TR, and Ethereum).

Jump to

Keyboard shortcuts

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