msg

package
Version: v0.0.0-...-9c70218 Latest Latest
Warning

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

Go to latest
Published: Aug 5, 2021 License: GPL-3.0 Imports: 2 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ChainId

type ChainId uint8

type Message

type Message struct {
	Source       ChainId      // Source where message was initiated
	Destination  ChainId      // Destination chain of message
	Type         TransferType // type of bridge transfer
	DepositNonce Nonce        // Nonce for the deposit
	ResourceId   ResourceId
	Payload      []interface{} // data associated with event sequence
}

Message is used as a generic format to communicate between chains

func NewFungibleTransfer

func NewFungibleTransfer(source, dest ChainId, nonce Nonce, amount *big.Int, resourceId ResourceId, recipient []byte) Message

type Nonce

type Nonce uint64

func (Nonce) Big

func (n Nonce) Big() *big.Int

type ResourceId

type ResourceId [32]byte

func ResourceIdFromSlice

func ResourceIdFromSlice(in []byte) ResourceId

func (ResourceId) Hex

func (r ResourceId) Hex() string

type TransferType

type TransferType string
var FungibleTransfer TransferType = "FungibleTransfer"

Source Files

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL