router

package
v1.0.3 Latest Latest
Warning

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

Go to latest
Published: Feb 8, 2024 License: LGPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Contract

type Contract struct {
	ethprecompile.BaseContract
	// contains filtered or unexported fields
}

func NewPrecompileContract

func NewPrecompileContract(r router.Router) *Contract

NewPrecompileContract returns a new instance of the Router precompile.

func (*Contract) MessageResult

func (c *Contract) MessageResult(ctx context.Context, evmTxHash string) ([]byte, string, uint32, error)

func (*Contract) Query

func (c *Contract) Query(
	ctx context.Context,
	request []byte,
	resource, namespace string,
) ([]byte, error)

func (*Contract) SendMessage

func (c *Contract) SendMessage(
	ctx context.Context,
	message []byte,
	messageID string,
	namespace string,
) (bool, error)

SendMessage implements the sendMessage precompile function in router.sol.

Jump to

Keyboard shortcuts

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