interchain

package
v1.9.2-lux Latest Latest
Warning

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

Go to latest
Published: Aug 5, 2025 License: BSD-3-Clause Imports: 16 Imported by: 0

Documentation

Overview

Copyright (C) 2025, Lux Industries Inc. All rights reserved. See the file LICENSE for licensing terms.

Copyright (C) 2025, Lux Industries Inc. All rights reserved. See the file LICENSE for licensing terms.

Index

Constants

This section is empty.

Variables

View Source
var (

	// 600 LUX
	InterchainMessagingPrefundedAddressBalance = big.NewInt(0).Mul(big.NewInt(1e18), big.NewInt(600))
)

Functions

func GetNextMessageID

func GetNextMessageID(
	rpcURL string,
	messengerAddress common.Address,
	destinationBlockchainID ids.ID,
) (ids.ID, error)

func MessageReceived

func MessageReceived(
	rpcURL string,
	messengerAddress common.Address,
	messageID ids.ID,
) (bool, error)

func SendCrossChainMessage

func SendCrossChainMessage(
	rpcURL string,
	messengerAddress common.Address,
	privateKey string,
	destinationBlockchainID ids.ID,
	destinationAddress common.Address,
	message []byte,
) (*types.Transaction, *types.Receipt, error)

func SetProposerVM

func SetProposerVM(
	app *application.Lux,
	network models.Network,
	blockchainID string,
	fundedKeyName string,
) error

Types

type WarpDeployer

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

func (*WarpDeployer) CheckAssets

func (t *WarpDeployer) CheckAssets() error

func (*WarpDeployer) Deploy

func (t *WarpDeployer) Deploy(
	subnetName string,
	rpcURL string,
	privateKey string,
	deployMessenger bool,
	deployRegistry bool,
	forceRegistryDeploy bool,
) (bool, string, string, error)

func (*WarpDeployer) DeployMessenger

func (t *WarpDeployer) DeployMessenger(
	subnetName string,
	rpcURL string,
	privateKey string,
) (bool, string, error)

func (*WarpDeployer) DeployRegistry

func (t *WarpDeployer) DeployRegistry(
	subnetName string,
	rpcURL string,
	privateKey string,
) (string, error)

func (*WarpDeployer) DownloadAssets

func (t *WarpDeployer) DownloadAssets(
	warpInstallDir string,
	version string,
) error

func (*WarpDeployer) GetAssets

func (t *WarpDeployer) GetAssets(
	warpInstallDir string,
	version string,
) (string, string, string, string, error)

func (*WarpDeployer) SetAssets

func (t *WarpDeployer) SetAssets(
	messengerContractAddress string,
	messengerDeployerAddress string,
	messengerDeployerTx string,
	registryBydecode string,
)

func (*WarpDeployer) SetAssetsFromPaths

func (t *WarpDeployer) SetAssetsFromPaths(
	messengerContractAddressPath string,
	messengerDeployerAddressPath string,
	messengerDeployerTxPath string,
	registryBydecodePath string,
) error

type WarpFeeInfo

type WarpFeeInfo struct {
	FeeTokenAddress common.Address
	Amount          *big.Int
}

type WarpInfo

type WarpInfo struct {
	Version                  string
	FundedAddress            string
	FundedBalance            *big.Int
	MessengerDeployerAddress string
}

func GetWarpInfo

func GetWarpInfo(
	app *application.Lux,
) (*WarpInfo, error)

type WarpMessage

type WarpMessage struct {
	MessageNonce            *big.Int
	OriginSenderAddress     common.Address
	DestinationBlockchainID [32]byte
	DestinationAddress      common.Address
	RequiredGasLimit        *big.Int
	AllowedRelayerAddresses []common.Address
	Receipts                []WarpMessageReceipt
	Message                 []byte
}

type WarpMessageReceipt

type WarpMessageReceipt struct {
	ReceivedMessageNonce *big.Int
	RelayerRewardAddress common.Address
}

type WarpMessengerSendCrossChainMessage

type WarpMessengerSendCrossChainMessage struct {
	MessageID               [32]byte
	DestinationBlockchainID [32]byte
	Message                 WarpMessage
	FeeInfo                 WarpFeeInfo
}

func ParseSendCrossChainMessage

func ParseSendCrossChainMessage(log types.Log) (*WarpMessengerSendCrossChainMessage, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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