diff --git a/abi-bindings/go/CrossChainApplications/ERC20Bridge/BridgeToken/BridgeToken.go b/abi-bindings/go/CrossChainApplications/ERC20Bridge/BridgeToken/BridgeToken.go index f99df56d1..bd3e16a78 100644 --- a/abi-bindings/go/CrossChainApplications/ERC20Bridge/BridgeToken/BridgeToken.go +++ b/abi-bindings/go/CrossChainApplications/ERC20Bridge/BridgeToken/BridgeToken.go @@ -31,7 +31,7 @@ var ( // BridgeTokenMetaData contains all meta data concerning the BridgeToken contract. var BridgeTokenMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"sourceChainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"sourceBridge\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"sourceAsset\",\"type\":\"address\"},{\"internalType\":\"string\",\"name\":\"tokenName\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"tokenSymbol\",\"type\":\"string\"},{\"internalType\":\"uint8\",\"name\":\"tokenDecimals\",\"type\":\"uint8\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"bridgeContract\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"burn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"burnFrom\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"mint\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"nativeAsset\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"nativeBridge\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"nativeChainID\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + ABI: "[{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"sourceBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"sourceBridge\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"sourceAsset\",\"type\":\"address\"},{\"internalType\":\"string\",\"name\":\"tokenName\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"tokenSymbol\",\"type\":\"string\"},{\"internalType\":\"uint8\",\"name\":\"tokenDecimals\",\"type\":\"uint8\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"bridgeContract\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"burn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"burnFrom\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"mint\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"nativeAsset\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"nativeBlockchainID\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"nativeBridge\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", } // BridgeTokenABI is the input ABI used to generate the binding from. @@ -366,66 +366,66 @@ func (_BridgeToken *BridgeTokenCallerSession) NativeAsset() (common.Address, err return _BridgeToken.Contract.NativeAsset(&_BridgeToken.CallOpts) } -// NativeBridge is a free data retrieval call binding the contract method 0x1a0b79bf. +// NativeBlockchainID is a free data retrieval call binding the contract method 0xf7253968. // -// Solidity: function nativeBridge() view returns(address) -func (_BridgeToken *BridgeTokenCaller) NativeBridge(opts *bind.CallOpts) (common.Address, error) { +// Solidity: function nativeBlockchainID() view returns(bytes32) +func (_BridgeToken *BridgeTokenCaller) NativeBlockchainID(opts *bind.CallOpts) ([32]byte, error) { var out []interface{} - err := _BridgeToken.contract.Call(opts, &out, "nativeBridge") + err := _BridgeToken.contract.Call(opts, &out, "nativeBlockchainID") if err != nil { - return *new(common.Address), err + return *new([32]byte), err } - out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) return out0, err } -// NativeBridge is a free data retrieval call binding the contract method 0x1a0b79bf. +// NativeBlockchainID is a free data retrieval call binding the contract method 0xf7253968. // -// Solidity: function nativeBridge() view returns(address) -func (_BridgeToken *BridgeTokenSession) NativeBridge() (common.Address, error) { - return _BridgeToken.Contract.NativeBridge(&_BridgeToken.CallOpts) +// Solidity: function nativeBlockchainID() view returns(bytes32) +func (_BridgeToken *BridgeTokenSession) NativeBlockchainID() ([32]byte, error) { + return _BridgeToken.Contract.NativeBlockchainID(&_BridgeToken.CallOpts) } -// NativeBridge is a free data retrieval call binding the contract method 0x1a0b79bf. +// NativeBlockchainID is a free data retrieval call binding the contract method 0xf7253968. // -// Solidity: function nativeBridge() view returns(address) -func (_BridgeToken *BridgeTokenCallerSession) NativeBridge() (common.Address, error) { - return _BridgeToken.Contract.NativeBridge(&_BridgeToken.CallOpts) +// Solidity: function nativeBlockchainID() view returns(bytes32) +func (_BridgeToken *BridgeTokenCallerSession) NativeBlockchainID() ([32]byte, error) { + return _BridgeToken.Contract.NativeBlockchainID(&_BridgeToken.CallOpts) } -// NativeChainID is a free data retrieval call binding the contract method 0xd8121a53. +// NativeBridge is a free data retrieval call binding the contract method 0x1a0b79bf. // -// Solidity: function nativeChainID() view returns(bytes32) -func (_BridgeToken *BridgeTokenCaller) NativeChainID(opts *bind.CallOpts) ([32]byte, error) { +// Solidity: function nativeBridge() view returns(address) +func (_BridgeToken *BridgeTokenCaller) NativeBridge(opts *bind.CallOpts) (common.Address, error) { var out []interface{} - err := _BridgeToken.contract.Call(opts, &out, "nativeChainID") + err := _BridgeToken.contract.Call(opts, &out, "nativeBridge") if err != nil { - return *new([32]byte), err + return *new(common.Address), err } - out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) return out0, err } -// NativeChainID is a free data retrieval call binding the contract method 0xd8121a53. +// NativeBridge is a free data retrieval call binding the contract method 0x1a0b79bf. // -// Solidity: function nativeChainID() view returns(bytes32) -func (_BridgeToken *BridgeTokenSession) NativeChainID() ([32]byte, error) { - return _BridgeToken.Contract.NativeChainID(&_BridgeToken.CallOpts) +// Solidity: function nativeBridge() view returns(address) +func (_BridgeToken *BridgeTokenSession) NativeBridge() (common.Address, error) { + return _BridgeToken.Contract.NativeBridge(&_BridgeToken.CallOpts) } -// NativeChainID is a free data retrieval call binding the contract method 0xd8121a53. +// NativeBridge is a free data retrieval call binding the contract method 0x1a0b79bf. // -// Solidity: function nativeChainID() view returns(bytes32) -func (_BridgeToken *BridgeTokenCallerSession) NativeChainID() ([32]byte, error) { - return _BridgeToken.Contract.NativeChainID(&_BridgeToken.CallOpts) +// Solidity: function nativeBridge() view returns(address) +func (_BridgeToken *BridgeTokenCallerSession) NativeBridge() (common.Address, error) { + return _BridgeToken.Contract.NativeBridge(&_BridgeToken.CallOpts) } // Symbol is a free data retrieval call binding the contract method 0x95d89b41. diff --git a/abi-bindings/go/CrossChainApplications/ERC20Bridge/ERC20Bridge/ERC20Bridge.go b/abi-bindings/go/CrossChainApplications/ERC20Bridge/ERC20Bridge/ERC20Bridge.go index 7c1ec05b3..df2d04613 100644 --- a/abi-bindings/go/CrossChainApplications/ERC20Bridge/ERC20Bridge/ERC20Bridge.go +++ b/abi-bindings/go/CrossChainApplications/ERC20Bridge/ERC20Bridge/ERC20Bridge.go @@ -31,7 +31,7 @@ var ( // ERC20BridgeMetaData contains all meta data concerning the ERC20Bridge contract. var ERC20BridgeMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"teleporterRegistryAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"tokenContractAddress\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"teleporterMessageID\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destinationBridgeAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"BridgeTokens\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"nativeChainID\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"nativeBridgeAddress\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"nativeContractAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"bridgeTokenAddress\",\"type\":\"address\"}],\"name\":\"CreateBridgeToken\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"oldMinTeleporterVersion\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"newMinTeleporterVersion\",\"type\":\"uint256\"}],\"name\":\"MinTeleporterVersionUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"contractAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"MintBridgeTokens\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"previousOwner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"OwnershipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"destinationBridgeAddress\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"nativeContractAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"teleporterMessageID\",\"type\":\"uint256\"}],\"name\":\"SubmitCreateBridgeToken\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"CREATE_BRIDGE_TOKENS_REQUIRED_GAS\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MINT_BRIDGE_TOKENS_REQUIRED_GAS\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"TRANSFER_BRIDGE_TOKENS_REQUIRED_GAS\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"WARP_PRECOMPILE_ADDRESS\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationBridgeAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"tokenContractAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"totalAmount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"primaryFeeAmount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"secondaryFeeAmount\",\"type\":\"uint256\"}],\"name\":\"bridgeTokens\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationBridgeAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"nativeTokenContract\",\"type\":\"address\"}],\"name\":\"bridgedBalances\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"balance\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"currentChainID\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"nativeContractAddress\",\"type\":\"address\"},{\"internalType\":\"string\",\"name\":\"nativeName\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"nativeSymbol\",\"type\":\"string\"},{\"internalType\":\"uint8\",\"name\":\"nativeDecimals\",\"type\":\"uint8\"}],\"name\":\"encodeCreateBridgeTokenData\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"nativeContractAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"bridgeAmount\",\"type\":\"uint256\"}],\"name\":\"encodeMintBridgeTokensData\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationBridgeAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"nativeContractAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"feeAmount\",\"type\":\"uint256\"}],\"name\":\"encodeTransferBridgeTokensData\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minTeleporterVersion\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"nativeChainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"nativeBridgeAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"nativeTokenAddress\",\"type\":\"address\"}],\"name\":\"nativeToWrappedTokens\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"bridgeTokenAddress\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"nativeChainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"nativeBridgeAddress\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"message\",\"type\":\"bytes\"}],\"name\":\"receiveTeleporterMessage\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationBridgeAddress\",\"type\":\"address\"},{\"internalType\":\"contractERC20\",\"name\":\"nativeToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"messageFeeAsset\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"messageFeeAmount\",\"type\":\"uint256\"}],\"name\":\"submitCreateBridgeToken\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationBridgeAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"nativeTokenContract\",\"type\":\"address\"}],\"name\":\"submittedBridgeTokenCreations\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"tokenCreationSubmitted\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"teleporterRegistry\",\"outputs\":[{\"internalType\":\"contractTeleporterRegistry\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateMinTeleporterVersion\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"bridgeToken\",\"type\":\"address\"}],\"name\":\"wrappedTokenContracts\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"bridgeTokenExists\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"teleporterRegistryAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"tokenContractAddress\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"teleporterMessageID\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destinationBridgeAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"BridgeTokens\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"nativeBlockchainID\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"nativeBridgeAddress\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"nativeContractAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"bridgeTokenAddress\",\"type\":\"address\"}],\"name\":\"CreateBridgeToken\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"oldMinTeleporterVersion\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"newMinTeleporterVersion\",\"type\":\"uint256\"}],\"name\":\"MinTeleporterVersionUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"contractAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"MintBridgeTokens\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"previousOwner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"OwnershipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"destinationBridgeAddress\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"nativeContractAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"teleporterMessageID\",\"type\":\"uint256\"}],\"name\":\"SubmitCreateBridgeToken\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"CREATE_BRIDGE_TOKENS_REQUIRED_GAS\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MINT_BRIDGE_TOKENS_REQUIRED_GAS\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"TRANSFER_BRIDGE_TOKENS_REQUIRED_GAS\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"WARP_PRECOMPILE_ADDRESS\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationBridgeAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"tokenContractAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"totalAmount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"primaryFeeAmount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"secondaryFeeAmount\",\"type\":\"uint256\"}],\"name\":\"bridgeTokens\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationBridgeAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"nativeTokenContract\",\"type\":\"address\"}],\"name\":\"bridgedBalances\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"balance\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"currentBlockchainID\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"nativeContractAddress\",\"type\":\"address\"},{\"internalType\":\"string\",\"name\":\"nativeName\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"nativeSymbol\",\"type\":\"string\"},{\"internalType\":\"uint8\",\"name\":\"nativeDecimals\",\"type\":\"uint8\"}],\"name\":\"encodeCreateBridgeTokenData\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"nativeContractAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"bridgeAmount\",\"type\":\"uint256\"}],\"name\":\"encodeMintBridgeTokensData\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationBridgeAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"nativeContractAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"feeAmount\",\"type\":\"uint256\"}],\"name\":\"encodeTransferBridgeTokensData\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minTeleporterVersion\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"nativeBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"nativeBridgeAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"nativeTokenAddress\",\"type\":\"address\"}],\"name\":\"nativeToWrappedTokens\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"bridgeTokenAddress\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"nativeBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"nativeBridgeAddress\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"message\",\"type\":\"bytes\"}],\"name\":\"receiveTeleporterMessage\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationBridgeAddress\",\"type\":\"address\"},{\"internalType\":\"contractERC20\",\"name\":\"nativeToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"messageFeeAsset\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"messageFeeAmount\",\"type\":\"uint256\"}],\"name\":\"submitCreateBridgeToken\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationBridgeAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"nativeTokenContract\",\"type\":\"address\"}],\"name\":\"submittedBridgeTokenCreations\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"tokenCreationSubmitted\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"teleporterRegistry\",\"outputs\":[{\"internalType\":\"contractTeleporterRegistry\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateMinTeleporterVersion\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"bridgeToken\",\"type\":\"address\"}],\"name\":\"wrappedTokenContracts\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"bridgeTokenExists\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", } // ERC20BridgeABI is the input ABI used to generate the binding from. @@ -306,10 +306,10 @@ func (_ERC20Bridge *ERC20BridgeCallerSession) WARPPRECOMPILEADDRESS() (common.Ad // BridgedBalances is a free data retrieval call binding the contract method 0xb9e55da1. // -// Solidity: function bridgedBalances(bytes32 destinationChainID, address destinationBridgeAddress, address nativeTokenContract) view returns(uint256 balance) -func (_ERC20Bridge *ERC20BridgeCaller) BridgedBalances(opts *bind.CallOpts, destinationChainID [32]byte, destinationBridgeAddress common.Address, nativeTokenContract common.Address) (*big.Int, error) { +// Solidity: function bridgedBalances(bytes32 destinationBlockchainID, address destinationBridgeAddress, address nativeTokenContract) view returns(uint256 balance) +func (_ERC20Bridge *ERC20BridgeCaller) BridgedBalances(opts *bind.CallOpts, destinationBlockchainID [32]byte, destinationBridgeAddress common.Address, nativeTokenContract common.Address) (*big.Int, error) { var out []interface{} - err := _ERC20Bridge.contract.Call(opts, &out, "bridgedBalances", destinationChainID, destinationBridgeAddress, nativeTokenContract) + err := _ERC20Bridge.contract.Call(opts, &out, "bridgedBalances", destinationBlockchainID, destinationBridgeAddress, nativeTokenContract) if err != nil { return *new(*big.Int), err @@ -323,24 +323,24 @@ func (_ERC20Bridge *ERC20BridgeCaller) BridgedBalances(opts *bind.CallOpts, dest // BridgedBalances is a free data retrieval call binding the contract method 0xb9e55da1. // -// Solidity: function bridgedBalances(bytes32 destinationChainID, address destinationBridgeAddress, address nativeTokenContract) view returns(uint256 balance) -func (_ERC20Bridge *ERC20BridgeSession) BridgedBalances(destinationChainID [32]byte, destinationBridgeAddress common.Address, nativeTokenContract common.Address) (*big.Int, error) { - return _ERC20Bridge.Contract.BridgedBalances(&_ERC20Bridge.CallOpts, destinationChainID, destinationBridgeAddress, nativeTokenContract) +// Solidity: function bridgedBalances(bytes32 destinationBlockchainID, address destinationBridgeAddress, address nativeTokenContract) view returns(uint256 balance) +func (_ERC20Bridge *ERC20BridgeSession) BridgedBalances(destinationBlockchainID [32]byte, destinationBridgeAddress common.Address, nativeTokenContract common.Address) (*big.Int, error) { + return _ERC20Bridge.Contract.BridgedBalances(&_ERC20Bridge.CallOpts, destinationBlockchainID, destinationBridgeAddress, nativeTokenContract) } // BridgedBalances is a free data retrieval call binding the contract method 0xb9e55da1. // -// Solidity: function bridgedBalances(bytes32 destinationChainID, address destinationBridgeAddress, address nativeTokenContract) view returns(uint256 balance) -func (_ERC20Bridge *ERC20BridgeCallerSession) BridgedBalances(destinationChainID [32]byte, destinationBridgeAddress common.Address, nativeTokenContract common.Address) (*big.Int, error) { - return _ERC20Bridge.Contract.BridgedBalances(&_ERC20Bridge.CallOpts, destinationChainID, destinationBridgeAddress, nativeTokenContract) +// Solidity: function bridgedBalances(bytes32 destinationBlockchainID, address destinationBridgeAddress, address nativeTokenContract) view returns(uint256 balance) +func (_ERC20Bridge *ERC20BridgeCallerSession) BridgedBalances(destinationBlockchainID [32]byte, destinationBridgeAddress common.Address, nativeTokenContract common.Address) (*big.Int, error) { + return _ERC20Bridge.Contract.BridgedBalances(&_ERC20Bridge.CallOpts, destinationBlockchainID, destinationBridgeAddress, nativeTokenContract) } -// CurrentChainID is a free data retrieval call binding the contract method 0xb179e1e7. +// CurrentBlockchainID is a free data retrieval call binding the contract method 0x4950d2d0. // -// Solidity: function currentChainID() view returns(bytes32) -func (_ERC20Bridge *ERC20BridgeCaller) CurrentChainID(opts *bind.CallOpts) ([32]byte, error) { +// Solidity: function currentBlockchainID() view returns(bytes32) +func (_ERC20Bridge *ERC20BridgeCaller) CurrentBlockchainID(opts *bind.CallOpts) ([32]byte, error) { var out []interface{} - err := _ERC20Bridge.contract.Call(opts, &out, "currentChainID") + err := _ERC20Bridge.contract.Call(opts, &out, "currentBlockchainID") if err != nil { return *new([32]byte), err @@ -352,18 +352,18 @@ func (_ERC20Bridge *ERC20BridgeCaller) CurrentChainID(opts *bind.CallOpts) ([32] } -// CurrentChainID is a free data retrieval call binding the contract method 0xb179e1e7. +// CurrentBlockchainID is a free data retrieval call binding the contract method 0x4950d2d0. // -// Solidity: function currentChainID() view returns(bytes32) -func (_ERC20Bridge *ERC20BridgeSession) CurrentChainID() ([32]byte, error) { - return _ERC20Bridge.Contract.CurrentChainID(&_ERC20Bridge.CallOpts) +// Solidity: function currentBlockchainID() view returns(bytes32) +func (_ERC20Bridge *ERC20BridgeSession) CurrentBlockchainID() ([32]byte, error) { + return _ERC20Bridge.Contract.CurrentBlockchainID(&_ERC20Bridge.CallOpts) } -// CurrentChainID is a free data retrieval call binding the contract method 0xb179e1e7. +// CurrentBlockchainID is a free data retrieval call binding the contract method 0x4950d2d0. // -// Solidity: function currentChainID() view returns(bytes32) -func (_ERC20Bridge *ERC20BridgeCallerSession) CurrentChainID() ([32]byte, error) { - return _ERC20Bridge.Contract.CurrentChainID(&_ERC20Bridge.CallOpts) +// Solidity: function currentBlockchainID() view returns(bytes32) +func (_ERC20Bridge *ERC20BridgeCallerSession) CurrentBlockchainID() ([32]byte, error) { + return _ERC20Bridge.Contract.CurrentBlockchainID(&_ERC20Bridge.CallOpts) } // EncodeCreateBridgeTokenData is a free data retrieval call binding the contract method 0x367e9584. @@ -430,10 +430,10 @@ func (_ERC20Bridge *ERC20BridgeCallerSession) EncodeMintBridgeTokensData(nativeC // EncodeTransferBridgeTokensData is a free data retrieval call binding the contract method 0xc60da612. // -// Solidity: function encodeTransferBridgeTokensData(bytes32 destinationChainID, address destinationBridgeAddress, address nativeContractAddress, address recipient, uint256 amount, uint256 feeAmount) pure returns(bytes) -func (_ERC20Bridge *ERC20BridgeCaller) EncodeTransferBridgeTokensData(opts *bind.CallOpts, destinationChainID [32]byte, destinationBridgeAddress common.Address, nativeContractAddress common.Address, recipient common.Address, amount *big.Int, feeAmount *big.Int) ([]byte, error) { +// Solidity: function encodeTransferBridgeTokensData(bytes32 destinationBlockchainID, address destinationBridgeAddress, address nativeContractAddress, address recipient, uint256 amount, uint256 feeAmount) pure returns(bytes) +func (_ERC20Bridge *ERC20BridgeCaller) EncodeTransferBridgeTokensData(opts *bind.CallOpts, destinationBlockchainID [32]byte, destinationBridgeAddress common.Address, nativeContractAddress common.Address, recipient common.Address, amount *big.Int, feeAmount *big.Int) ([]byte, error) { var out []interface{} - err := _ERC20Bridge.contract.Call(opts, &out, "encodeTransferBridgeTokensData", destinationChainID, destinationBridgeAddress, nativeContractAddress, recipient, amount, feeAmount) + err := _ERC20Bridge.contract.Call(opts, &out, "encodeTransferBridgeTokensData", destinationBlockchainID, destinationBridgeAddress, nativeContractAddress, recipient, amount, feeAmount) if err != nil { return *new([]byte), err @@ -447,16 +447,16 @@ func (_ERC20Bridge *ERC20BridgeCaller) EncodeTransferBridgeTokensData(opts *bind // EncodeTransferBridgeTokensData is a free data retrieval call binding the contract method 0xc60da612. // -// Solidity: function encodeTransferBridgeTokensData(bytes32 destinationChainID, address destinationBridgeAddress, address nativeContractAddress, address recipient, uint256 amount, uint256 feeAmount) pure returns(bytes) -func (_ERC20Bridge *ERC20BridgeSession) EncodeTransferBridgeTokensData(destinationChainID [32]byte, destinationBridgeAddress common.Address, nativeContractAddress common.Address, recipient common.Address, amount *big.Int, feeAmount *big.Int) ([]byte, error) { - return _ERC20Bridge.Contract.EncodeTransferBridgeTokensData(&_ERC20Bridge.CallOpts, destinationChainID, destinationBridgeAddress, nativeContractAddress, recipient, amount, feeAmount) +// Solidity: function encodeTransferBridgeTokensData(bytes32 destinationBlockchainID, address destinationBridgeAddress, address nativeContractAddress, address recipient, uint256 amount, uint256 feeAmount) pure returns(bytes) +func (_ERC20Bridge *ERC20BridgeSession) EncodeTransferBridgeTokensData(destinationBlockchainID [32]byte, destinationBridgeAddress common.Address, nativeContractAddress common.Address, recipient common.Address, amount *big.Int, feeAmount *big.Int) ([]byte, error) { + return _ERC20Bridge.Contract.EncodeTransferBridgeTokensData(&_ERC20Bridge.CallOpts, destinationBlockchainID, destinationBridgeAddress, nativeContractAddress, recipient, amount, feeAmount) } // EncodeTransferBridgeTokensData is a free data retrieval call binding the contract method 0xc60da612. // -// Solidity: function encodeTransferBridgeTokensData(bytes32 destinationChainID, address destinationBridgeAddress, address nativeContractAddress, address recipient, uint256 amount, uint256 feeAmount) pure returns(bytes) -func (_ERC20Bridge *ERC20BridgeCallerSession) EncodeTransferBridgeTokensData(destinationChainID [32]byte, destinationBridgeAddress common.Address, nativeContractAddress common.Address, recipient common.Address, amount *big.Int, feeAmount *big.Int) ([]byte, error) { - return _ERC20Bridge.Contract.EncodeTransferBridgeTokensData(&_ERC20Bridge.CallOpts, destinationChainID, destinationBridgeAddress, nativeContractAddress, recipient, amount, feeAmount) +// Solidity: function encodeTransferBridgeTokensData(bytes32 destinationBlockchainID, address destinationBridgeAddress, address nativeContractAddress, address recipient, uint256 amount, uint256 feeAmount) pure returns(bytes) +func (_ERC20Bridge *ERC20BridgeCallerSession) EncodeTransferBridgeTokensData(destinationBlockchainID [32]byte, destinationBridgeAddress common.Address, nativeContractAddress common.Address, recipient common.Address, amount *big.Int, feeAmount *big.Int) ([]byte, error) { + return _ERC20Bridge.Contract.EncodeTransferBridgeTokensData(&_ERC20Bridge.CallOpts, destinationBlockchainID, destinationBridgeAddress, nativeContractAddress, recipient, amount, feeAmount) } // MinTeleporterVersion is a free data retrieval call binding the contract method 0xe49cc553. @@ -492,10 +492,10 @@ func (_ERC20Bridge *ERC20BridgeCallerSession) MinTeleporterVersion() (*big.Int, // NativeToWrappedTokens is a free data retrieval call binding the contract method 0x65435568. // -// Solidity: function nativeToWrappedTokens(bytes32 nativeChainID, address nativeBridgeAddress, address nativeTokenAddress) view returns(address bridgeTokenAddress) -func (_ERC20Bridge *ERC20BridgeCaller) NativeToWrappedTokens(opts *bind.CallOpts, nativeChainID [32]byte, nativeBridgeAddress common.Address, nativeTokenAddress common.Address) (common.Address, error) { +// Solidity: function nativeToWrappedTokens(bytes32 nativeBlockchainID, address nativeBridgeAddress, address nativeTokenAddress) view returns(address bridgeTokenAddress) +func (_ERC20Bridge *ERC20BridgeCaller) NativeToWrappedTokens(opts *bind.CallOpts, nativeBlockchainID [32]byte, nativeBridgeAddress common.Address, nativeTokenAddress common.Address) (common.Address, error) { var out []interface{} - err := _ERC20Bridge.contract.Call(opts, &out, "nativeToWrappedTokens", nativeChainID, nativeBridgeAddress, nativeTokenAddress) + err := _ERC20Bridge.contract.Call(opts, &out, "nativeToWrappedTokens", nativeBlockchainID, nativeBridgeAddress, nativeTokenAddress) if err != nil { return *new(common.Address), err @@ -509,16 +509,16 @@ func (_ERC20Bridge *ERC20BridgeCaller) NativeToWrappedTokens(opts *bind.CallOpts // NativeToWrappedTokens is a free data retrieval call binding the contract method 0x65435568. // -// Solidity: function nativeToWrappedTokens(bytes32 nativeChainID, address nativeBridgeAddress, address nativeTokenAddress) view returns(address bridgeTokenAddress) -func (_ERC20Bridge *ERC20BridgeSession) NativeToWrappedTokens(nativeChainID [32]byte, nativeBridgeAddress common.Address, nativeTokenAddress common.Address) (common.Address, error) { - return _ERC20Bridge.Contract.NativeToWrappedTokens(&_ERC20Bridge.CallOpts, nativeChainID, nativeBridgeAddress, nativeTokenAddress) +// Solidity: function nativeToWrappedTokens(bytes32 nativeBlockchainID, address nativeBridgeAddress, address nativeTokenAddress) view returns(address bridgeTokenAddress) +func (_ERC20Bridge *ERC20BridgeSession) NativeToWrappedTokens(nativeBlockchainID [32]byte, nativeBridgeAddress common.Address, nativeTokenAddress common.Address) (common.Address, error) { + return _ERC20Bridge.Contract.NativeToWrappedTokens(&_ERC20Bridge.CallOpts, nativeBlockchainID, nativeBridgeAddress, nativeTokenAddress) } // NativeToWrappedTokens is a free data retrieval call binding the contract method 0x65435568. // -// Solidity: function nativeToWrappedTokens(bytes32 nativeChainID, address nativeBridgeAddress, address nativeTokenAddress) view returns(address bridgeTokenAddress) -func (_ERC20Bridge *ERC20BridgeCallerSession) NativeToWrappedTokens(nativeChainID [32]byte, nativeBridgeAddress common.Address, nativeTokenAddress common.Address) (common.Address, error) { - return _ERC20Bridge.Contract.NativeToWrappedTokens(&_ERC20Bridge.CallOpts, nativeChainID, nativeBridgeAddress, nativeTokenAddress) +// Solidity: function nativeToWrappedTokens(bytes32 nativeBlockchainID, address nativeBridgeAddress, address nativeTokenAddress) view returns(address bridgeTokenAddress) +func (_ERC20Bridge *ERC20BridgeCallerSession) NativeToWrappedTokens(nativeBlockchainID [32]byte, nativeBridgeAddress common.Address, nativeTokenAddress common.Address) (common.Address, error) { + return _ERC20Bridge.Contract.NativeToWrappedTokens(&_ERC20Bridge.CallOpts, nativeBlockchainID, nativeBridgeAddress, nativeTokenAddress) } // Owner is a free data retrieval call binding the contract method 0x8da5cb5b. @@ -554,10 +554,10 @@ func (_ERC20Bridge *ERC20BridgeCallerSession) Owner() (common.Address, error) { // SubmittedBridgeTokenCreations is a free data retrieval call binding the contract method 0x8343f661. // -// Solidity: function submittedBridgeTokenCreations(bytes32 destinationChainID, address destinationBridgeAddress, address nativeTokenContract) view returns(bool tokenCreationSubmitted) -func (_ERC20Bridge *ERC20BridgeCaller) SubmittedBridgeTokenCreations(opts *bind.CallOpts, destinationChainID [32]byte, destinationBridgeAddress common.Address, nativeTokenContract common.Address) (bool, error) { +// Solidity: function submittedBridgeTokenCreations(bytes32 destinationBlockchainID, address destinationBridgeAddress, address nativeTokenContract) view returns(bool tokenCreationSubmitted) +func (_ERC20Bridge *ERC20BridgeCaller) SubmittedBridgeTokenCreations(opts *bind.CallOpts, destinationBlockchainID [32]byte, destinationBridgeAddress common.Address, nativeTokenContract common.Address) (bool, error) { var out []interface{} - err := _ERC20Bridge.contract.Call(opts, &out, "submittedBridgeTokenCreations", destinationChainID, destinationBridgeAddress, nativeTokenContract) + err := _ERC20Bridge.contract.Call(opts, &out, "submittedBridgeTokenCreations", destinationBlockchainID, destinationBridgeAddress, nativeTokenContract) if err != nil { return *new(bool), err @@ -571,16 +571,16 @@ func (_ERC20Bridge *ERC20BridgeCaller) SubmittedBridgeTokenCreations(opts *bind. // SubmittedBridgeTokenCreations is a free data retrieval call binding the contract method 0x8343f661. // -// Solidity: function submittedBridgeTokenCreations(bytes32 destinationChainID, address destinationBridgeAddress, address nativeTokenContract) view returns(bool tokenCreationSubmitted) -func (_ERC20Bridge *ERC20BridgeSession) SubmittedBridgeTokenCreations(destinationChainID [32]byte, destinationBridgeAddress common.Address, nativeTokenContract common.Address) (bool, error) { - return _ERC20Bridge.Contract.SubmittedBridgeTokenCreations(&_ERC20Bridge.CallOpts, destinationChainID, destinationBridgeAddress, nativeTokenContract) +// Solidity: function submittedBridgeTokenCreations(bytes32 destinationBlockchainID, address destinationBridgeAddress, address nativeTokenContract) view returns(bool tokenCreationSubmitted) +func (_ERC20Bridge *ERC20BridgeSession) SubmittedBridgeTokenCreations(destinationBlockchainID [32]byte, destinationBridgeAddress common.Address, nativeTokenContract common.Address) (bool, error) { + return _ERC20Bridge.Contract.SubmittedBridgeTokenCreations(&_ERC20Bridge.CallOpts, destinationBlockchainID, destinationBridgeAddress, nativeTokenContract) } // SubmittedBridgeTokenCreations is a free data retrieval call binding the contract method 0x8343f661. // -// Solidity: function submittedBridgeTokenCreations(bytes32 destinationChainID, address destinationBridgeAddress, address nativeTokenContract) view returns(bool tokenCreationSubmitted) -func (_ERC20Bridge *ERC20BridgeCallerSession) SubmittedBridgeTokenCreations(destinationChainID [32]byte, destinationBridgeAddress common.Address, nativeTokenContract common.Address) (bool, error) { - return _ERC20Bridge.Contract.SubmittedBridgeTokenCreations(&_ERC20Bridge.CallOpts, destinationChainID, destinationBridgeAddress, nativeTokenContract) +// Solidity: function submittedBridgeTokenCreations(bytes32 destinationBlockchainID, address destinationBridgeAddress, address nativeTokenContract) view returns(bool tokenCreationSubmitted) +func (_ERC20Bridge *ERC20BridgeCallerSession) SubmittedBridgeTokenCreations(destinationBlockchainID [32]byte, destinationBridgeAddress common.Address, nativeTokenContract common.Address) (bool, error) { + return _ERC20Bridge.Contract.SubmittedBridgeTokenCreations(&_ERC20Bridge.CallOpts, destinationBlockchainID, destinationBridgeAddress, nativeTokenContract) } // TeleporterRegistry is a free data retrieval call binding the contract method 0x1a7f5bec. @@ -647,44 +647,44 @@ func (_ERC20Bridge *ERC20BridgeCallerSession) WrappedTokenContracts(bridgeToken // BridgeTokens is a paid mutator transaction binding the contract method 0xc63d2207. // -// Solidity: function bridgeTokens(bytes32 destinationChainID, address destinationBridgeAddress, address tokenContractAddress, address recipient, uint256 totalAmount, uint256 primaryFeeAmount, uint256 secondaryFeeAmount) returns() -func (_ERC20Bridge *ERC20BridgeTransactor) BridgeTokens(opts *bind.TransactOpts, destinationChainID [32]byte, destinationBridgeAddress common.Address, tokenContractAddress common.Address, recipient common.Address, totalAmount *big.Int, primaryFeeAmount *big.Int, secondaryFeeAmount *big.Int) (*types.Transaction, error) { - return _ERC20Bridge.contract.Transact(opts, "bridgeTokens", destinationChainID, destinationBridgeAddress, tokenContractAddress, recipient, totalAmount, primaryFeeAmount, secondaryFeeAmount) +// Solidity: function bridgeTokens(bytes32 destinationBlockchainID, address destinationBridgeAddress, address tokenContractAddress, address recipient, uint256 totalAmount, uint256 primaryFeeAmount, uint256 secondaryFeeAmount) returns() +func (_ERC20Bridge *ERC20BridgeTransactor) BridgeTokens(opts *bind.TransactOpts, destinationBlockchainID [32]byte, destinationBridgeAddress common.Address, tokenContractAddress common.Address, recipient common.Address, totalAmount *big.Int, primaryFeeAmount *big.Int, secondaryFeeAmount *big.Int) (*types.Transaction, error) { + return _ERC20Bridge.contract.Transact(opts, "bridgeTokens", destinationBlockchainID, destinationBridgeAddress, tokenContractAddress, recipient, totalAmount, primaryFeeAmount, secondaryFeeAmount) } // BridgeTokens is a paid mutator transaction binding the contract method 0xc63d2207. // -// Solidity: function bridgeTokens(bytes32 destinationChainID, address destinationBridgeAddress, address tokenContractAddress, address recipient, uint256 totalAmount, uint256 primaryFeeAmount, uint256 secondaryFeeAmount) returns() -func (_ERC20Bridge *ERC20BridgeSession) BridgeTokens(destinationChainID [32]byte, destinationBridgeAddress common.Address, tokenContractAddress common.Address, recipient common.Address, totalAmount *big.Int, primaryFeeAmount *big.Int, secondaryFeeAmount *big.Int) (*types.Transaction, error) { - return _ERC20Bridge.Contract.BridgeTokens(&_ERC20Bridge.TransactOpts, destinationChainID, destinationBridgeAddress, tokenContractAddress, recipient, totalAmount, primaryFeeAmount, secondaryFeeAmount) +// Solidity: function bridgeTokens(bytes32 destinationBlockchainID, address destinationBridgeAddress, address tokenContractAddress, address recipient, uint256 totalAmount, uint256 primaryFeeAmount, uint256 secondaryFeeAmount) returns() +func (_ERC20Bridge *ERC20BridgeSession) BridgeTokens(destinationBlockchainID [32]byte, destinationBridgeAddress common.Address, tokenContractAddress common.Address, recipient common.Address, totalAmount *big.Int, primaryFeeAmount *big.Int, secondaryFeeAmount *big.Int) (*types.Transaction, error) { + return _ERC20Bridge.Contract.BridgeTokens(&_ERC20Bridge.TransactOpts, destinationBlockchainID, destinationBridgeAddress, tokenContractAddress, recipient, totalAmount, primaryFeeAmount, secondaryFeeAmount) } // BridgeTokens is a paid mutator transaction binding the contract method 0xc63d2207. // -// Solidity: function bridgeTokens(bytes32 destinationChainID, address destinationBridgeAddress, address tokenContractAddress, address recipient, uint256 totalAmount, uint256 primaryFeeAmount, uint256 secondaryFeeAmount) returns() -func (_ERC20Bridge *ERC20BridgeTransactorSession) BridgeTokens(destinationChainID [32]byte, destinationBridgeAddress common.Address, tokenContractAddress common.Address, recipient common.Address, totalAmount *big.Int, primaryFeeAmount *big.Int, secondaryFeeAmount *big.Int) (*types.Transaction, error) { - return _ERC20Bridge.Contract.BridgeTokens(&_ERC20Bridge.TransactOpts, destinationChainID, destinationBridgeAddress, tokenContractAddress, recipient, totalAmount, primaryFeeAmount, secondaryFeeAmount) +// Solidity: function bridgeTokens(bytes32 destinationBlockchainID, address destinationBridgeAddress, address tokenContractAddress, address recipient, uint256 totalAmount, uint256 primaryFeeAmount, uint256 secondaryFeeAmount) returns() +func (_ERC20Bridge *ERC20BridgeTransactorSession) BridgeTokens(destinationBlockchainID [32]byte, destinationBridgeAddress common.Address, tokenContractAddress common.Address, recipient common.Address, totalAmount *big.Int, primaryFeeAmount *big.Int, secondaryFeeAmount *big.Int) (*types.Transaction, error) { + return _ERC20Bridge.Contract.BridgeTokens(&_ERC20Bridge.TransactOpts, destinationBlockchainID, destinationBridgeAddress, tokenContractAddress, recipient, totalAmount, primaryFeeAmount, secondaryFeeAmount) } // ReceiveTeleporterMessage is a paid mutator transaction binding the contract method 0xc868efaa. // -// Solidity: function receiveTeleporterMessage(bytes32 nativeChainID, address nativeBridgeAddress, bytes message) returns() -func (_ERC20Bridge *ERC20BridgeTransactor) ReceiveTeleporterMessage(opts *bind.TransactOpts, nativeChainID [32]byte, nativeBridgeAddress common.Address, message []byte) (*types.Transaction, error) { - return _ERC20Bridge.contract.Transact(opts, "receiveTeleporterMessage", nativeChainID, nativeBridgeAddress, message) +// Solidity: function receiveTeleporterMessage(bytes32 nativeBlockchainID, address nativeBridgeAddress, bytes message) returns() +func (_ERC20Bridge *ERC20BridgeTransactor) ReceiveTeleporterMessage(opts *bind.TransactOpts, nativeBlockchainID [32]byte, nativeBridgeAddress common.Address, message []byte) (*types.Transaction, error) { + return _ERC20Bridge.contract.Transact(opts, "receiveTeleporterMessage", nativeBlockchainID, nativeBridgeAddress, message) } // ReceiveTeleporterMessage is a paid mutator transaction binding the contract method 0xc868efaa. // -// Solidity: function receiveTeleporterMessage(bytes32 nativeChainID, address nativeBridgeAddress, bytes message) returns() -func (_ERC20Bridge *ERC20BridgeSession) ReceiveTeleporterMessage(nativeChainID [32]byte, nativeBridgeAddress common.Address, message []byte) (*types.Transaction, error) { - return _ERC20Bridge.Contract.ReceiveTeleporterMessage(&_ERC20Bridge.TransactOpts, nativeChainID, nativeBridgeAddress, message) +// Solidity: function receiveTeleporterMessage(bytes32 nativeBlockchainID, address nativeBridgeAddress, bytes message) returns() +func (_ERC20Bridge *ERC20BridgeSession) ReceiveTeleporterMessage(nativeBlockchainID [32]byte, nativeBridgeAddress common.Address, message []byte) (*types.Transaction, error) { + return _ERC20Bridge.Contract.ReceiveTeleporterMessage(&_ERC20Bridge.TransactOpts, nativeBlockchainID, nativeBridgeAddress, message) } // ReceiveTeleporterMessage is a paid mutator transaction binding the contract method 0xc868efaa. // -// Solidity: function receiveTeleporterMessage(bytes32 nativeChainID, address nativeBridgeAddress, bytes message) returns() -func (_ERC20Bridge *ERC20BridgeTransactorSession) ReceiveTeleporterMessage(nativeChainID [32]byte, nativeBridgeAddress common.Address, message []byte) (*types.Transaction, error) { - return _ERC20Bridge.Contract.ReceiveTeleporterMessage(&_ERC20Bridge.TransactOpts, nativeChainID, nativeBridgeAddress, message) +// Solidity: function receiveTeleporterMessage(bytes32 nativeBlockchainID, address nativeBridgeAddress, bytes message) returns() +func (_ERC20Bridge *ERC20BridgeTransactorSession) ReceiveTeleporterMessage(nativeBlockchainID [32]byte, nativeBridgeAddress common.Address, message []byte) (*types.Transaction, error) { + return _ERC20Bridge.Contract.ReceiveTeleporterMessage(&_ERC20Bridge.TransactOpts, nativeBlockchainID, nativeBridgeAddress, message) } // RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6. @@ -710,23 +710,23 @@ func (_ERC20Bridge *ERC20BridgeTransactorSession) RenounceOwnership() (*types.Tr // SubmitCreateBridgeToken is a paid mutator transaction binding the contract method 0x6c7e40d1. // -// Solidity: function submitCreateBridgeToken(bytes32 destinationChainID, address destinationBridgeAddress, address nativeToken, address messageFeeAsset, uint256 messageFeeAmount) returns() -func (_ERC20Bridge *ERC20BridgeTransactor) SubmitCreateBridgeToken(opts *bind.TransactOpts, destinationChainID [32]byte, destinationBridgeAddress common.Address, nativeToken common.Address, messageFeeAsset common.Address, messageFeeAmount *big.Int) (*types.Transaction, error) { - return _ERC20Bridge.contract.Transact(opts, "submitCreateBridgeToken", destinationChainID, destinationBridgeAddress, nativeToken, messageFeeAsset, messageFeeAmount) +// Solidity: function submitCreateBridgeToken(bytes32 destinationBlockchainID, address destinationBridgeAddress, address nativeToken, address messageFeeAsset, uint256 messageFeeAmount) returns() +func (_ERC20Bridge *ERC20BridgeTransactor) SubmitCreateBridgeToken(opts *bind.TransactOpts, destinationBlockchainID [32]byte, destinationBridgeAddress common.Address, nativeToken common.Address, messageFeeAsset common.Address, messageFeeAmount *big.Int) (*types.Transaction, error) { + return _ERC20Bridge.contract.Transact(opts, "submitCreateBridgeToken", destinationBlockchainID, destinationBridgeAddress, nativeToken, messageFeeAsset, messageFeeAmount) } // SubmitCreateBridgeToken is a paid mutator transaction binding the contract method 0x6c7e40d1. // -// Solidity: function submitCreateBridgeToken(bytes32 destinationChainID, address destinationBridgeAddress, address nativeToken, address messageFeeAsset, uint256 messageFeeAmount) returns() -func (_ERC20Bridge *ERC20BridgeSession) SubmitCreateBridgeToken(destinationChainID [32]byte, destinationBridgeAddress common.Address, nativeToken common.Address, messageFeeAsset common.Address, messageFeeAmount *big.Int) (*types.Transaction, error) { - return _ERC20Bridge.Contract.SubmitCreateBridgeToken(&_ERC20Bridge.TransactOpts, destinationChainID, destinationBridgeAddress, nativeToken, messageFeeAsset, messageFeeAmount) +// Solidity: function submitCreateBridgeToken(bytes32 destinationBlockchainID, address destinationBridgeAddress, address nativeToken, address messageFeeAsset, uint256 messageFeeAmount) returns() +func (_ERC20Bridge *ERC20BridgeSession) SubmitCreateBridgeToken(destinationBlockchainID [32]byte, destinationBridgeAddress common.Address, nativeToken common.Address, messageFeeAsset common.Address, messageFeeAmount *big.Int) (*types.Transaction, error) { + return _ERC20Bridge.Contract.SubmitCreateBridgeToken(&_ERC20Bridge.TransactOpts, destinationBlockchainID, destinationBridgeAddress, nativeToken, messageFeeAsset, messageFeeAmount) } // SubmitCreateBridgeToken is a paid mutator transaction binding the contract method 0x6c7e40d1. // -// Solidity: function submitCreateBridgeToken(bytes32 destinationChainID, address destinationBridgeAddress, address nativeToken, address messageFeeAsset, uint256 messageFeeAmount) returns() -func (_ERC20Bridge *ERC20BridgeTransactorSession) SubmitCreateBridgeToken(destinationChainID [32]byte, destinationBridgeAddress common.Address, nativeToken common.Address, messageFeeAsset common.Address, messageFeeAmount *big.Int) (*types.Transaction, error) { - return _ERC20Bridge.Contract.SubmitCreateBridgeToken(&_ERC20Bridge.TransactOpts, destinationChainID, destinationBridgeAddress, nativeToken, messageFeeAsset, messageFeeAmount) +// Solidity: function submitCreateBridgeToken(bytes32 destinationBlockchainID, address destinationBridgeAddress, address nativeToken, address messageFeeAsset, uint256 messageFeeAmount) returns() +func (_ERC20Bridge *ERC20BridgeTransactorSession) SubmitCreateBridgeToken(destinationBlockchainID [32]byte, destinationBridgeAddress common.Address, nativeToken common.Address, messageFeeAsset common.Address, messageFeeAmount *big.Int) (*types.Transaction, error) { + return _ERC20Bridge.Contract.SubmitCreateBridgeToken(&_ERC20Bridge.TransactOpts, destinationBlockchainID, destinationBridgeAddress, nativeToken, messageFeeAsset, messageFeeAmount) } // TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b. @@ -841,7 +841,7 @@ func (it *ERC20BridgeBridgeTokensIterator) Close() error { // ERC20BridgeBridgeTokens represents a BridgeTokens event raised by the ERC20Bridge contract. type ERC20BridgeBridgeTokens struct { TokenContractAddress common.Address - DestinationChainID [32]byte + DestinationBlockchainID [32]byte TeleporterMessageID *big.Int DestinationBridgeAddress common.Address Recipient common.Address @@ -851,23 +851,23 @@ type ERC20BridgeBridgeTokens struct { // FilterBridgeTokens is a free log retrieval operation binding the contract event 0x97935c4470efae40c8440c3abfe968a5512232dd375cc974e712f487c2b99c31. // -// Solidity: event BridgeTokens(address indexed tokenContractAddress, bytes32 indexed destinationChainID, uint256 indexed teleporterMessageID, address destinationBridgeAddress, address recipient, uint256 amount) -func (_ERC20Bridge *ERC20BridgeFilterer) FilterBridgeTokens(opts *bind.FilterOpts, tokenContractAddress []common.Address, destinationChainID [][32]byte, teleporterMessageID []*big.Int) (*ERC20BridgeBridgeTokensIterator, error) { +// Solidity: event BridgeTokens(address indexed tokenContractAddress, bytes32 indexed destinationBlockchainID, uint256 indexed teleporterMessageID, address destinationBridgeAddress, address recipient, uint256 amount) +func (_ERC20Bridge *ERC20BridgeFilterer) FilterBridgeTokens(opts *bind.FilterOpts, tokenContractAddress []common.Address, destinationBlockchainID [][32]byte, teleporterMessageID []*big.Int) (*ERC20BridgeBridgeTokensIterator, error) { var tokenContractAddressRule []interface{} for _, tokenContractAddressItem := range tokenContractAddress { tokenContractAddressRule = append(tokenContractAddressRule, tokenContractAddressItem) } - var destinationChainIDRule []interface{} - for _, destinationChainIDItem := range destinationChainID { - destinationChainIDRule = append(destinationChainIDRule, destinationChainIDItem) + var destinationBlockchainIDRule []interface{} + for _, destinationBlockchainIDItem := range destinationBlockchainID { + destinationBlockchainIDRule = append(destinationBlockchainIDRule, destinationBlockchainIDItem) } var teleporterMessageIDRule []interface{} for _, teleporterMessageIDItem := range teleporterMessageID { teleporterMessageIDRule = append(teleporterMessageIDRule, teleporterMessageIDItem) } - logs, sub, err := _ERC20Bridge.contract.FilterLogs(opts, "BridgeTokens", tokenContractAddressRule, destinationChainIDRule, teleporterMessageIDRule) + logs, sub, err := _ERC20Bridge.contract.FilterLogs(opts, "BridgeTokens", tokenContractAddressRule, destinationBlockchainIDRule, teleporterMessageIDRule) if err != nil { return nil, err } @@ -876,23 +876,23 @@ func (_ERC20Bridge *ERC20BridgeFilterer) FilterBridgeTokens(opts *bind.FilterOpt // WatchBridgeTokens is a free log subscription operation binding the contract event 0x97935c4470efae40c8440c3abfe968a5512232dd375cc974e712f487c2b99c31. // -// Solidity: event BridgeTokens(address indexed tokenContractAddress, bytes32 indexed destinationChainID, uint256 indexed teleporterMessageID, address destinationBridgeAddress, address recipient, uint256 amount) -func (_ERC20Bridge *ERC20BridgeFilterer) WatchBridgeTokens(opts *bind.WatchOpts, sink chan<- *ERC20BridgeBridgeTokens, tokenContractAddress []common.Address, destinationChainID [][32]byte, teleporterMessageID []*big.Int) (event.Subscription, error) { +// Solidity: event BridgeTokens(address indexed tokenContractAddress, bytes32 indexed destinationBlockchainID, uint256 indexed teleporterMessageID, address destinationBridgeAddress, address recipient, uint256 amount) +func (_ERC20Bridge *ERC20BridgeFilterer) WatchBridgeTokens(opts *bind.WatchOpts, sink chan<- *ERC20BridgeBridgeTokens, tokenContractAddress []common.Address, destinationBlockchainID [][32]byte, teleporterMessageID []*big.Int) (event.Subscription, error) { var tokenContractAddressRule []interface{} for _, tokenContractAddressItem := range tokenContractAddress { tokenContractAddressRule = append(tokenContractAddressRule, tokenContractAddressItem) } - var destinationChainIDRule []interface{} - for _, destinationChainIDItem := range destinationChainID { - destinationChainIDRule = append(destinationChainIDRule, destinationChainIDItem) + var destinationBlockchainIDRule []interface{} + for _, destinationBlockchainIDItem := range destinationBlockchainID { + destinationBlockchainIDRule = append(destinationBlockchainIDRule, destinationBlockchainIDItem) } var teleporterMessageIDRule []interface{} for _, teleporterMessageIDItem := range teleporterMessageID { teleporterMessageIDRule = append(teleporterMessageIDRule, teleporterMessageIDItem) } - logs, sub, err := _ERC20Bridge.contract.WatchLogs(opts, "BridgeTokens", tokenContractAddressRule, destinationChainIDRule, teleporterMessageIDRule) + logs, sub, err := _ERC20Bridge.contract.WatchLogs(opts, "BridgeTokens", tokenContractAddressRule, destinationBlockchainIDRule, teleporterMessageIDRule) if err != nil { return nil, err } @@ -926,7 +926,7 @@ func (_ERC20Bridge *ERC20BridgeFilterer) WatchBridgeTokens(opts *bind.WatchOpts, // ParseBridgeTokens is a log parse operation binding the contract event 0x97935c4470efae40c8440c3abfe968a5512232dd375cc974e712f487c2b99c31. // -// Solidity: event BridgeTokens(address indexed tokenContractAddress, bytes32 indexed destinationChainID, uint256 indexed teleporterMessageID, address destinationBridgeAddress, address recipient, uint256 amount) +// Solidity: event BridgeTokens(address indexed tokenContractAddress, bytes32 indexed destinationBlockchainID, uint256 indexed teleporterMessageID, address destinationBridgeAddress, address recipient, uint256 amount) func (_ERC20Bridge *ERC20BridgeFilterer) ParseBridgeTokens(log types.Log) (*ERC20BridgeBridgeTokens, error) { event := new(ERC20BridgeBridgeTokens) if err := _ERC20Bridge.contract.UnpackLog(event, "BridgeTokens", log); err != nil { @@ -1005,7 +1005,7 @@ func (it *ERC20BridgeCreateBridgeTokenIterator) Close() error { // ERC20BridgeCreateBridgeToken represents a CreateBridgeToken event raised by the ERC20Bridge contract. type ERC20BridgeCreateBridgeToken struct { - NativeChainID [32]byte + NativeBlockchainID [32]byte NativeBridgeAddress common.Address NativeContractAddress common.Address BridgeTokenAddress common.Address @@ -1014,12 +1014,12 @@ type ERC20BridgeCreateBridgeToken struct { // FilterCreateBridgeToken is a free log retrieval operation binding the contract event 0xe1c61a845f79534e11924517ddbedc668d0c20e467eafb4d3bd2858e2815f3b5. // -// Solidity: event CreateBridgeToken(bytes32 indexed nativeChainID, address indexed nativeBridgeAddress, address indexed nativeContractAddress, address bridgeTokenAddress) -func (_ERC20Bridge *ERC20BridgeFilterer) FilterCreateBridgeToken(opts *bind.FilterOpts, nativeChainID [][32]byte, nativeBridgeAddress []common.Address, nativeContractAddress []common.Address) (*ERC20BridgeCreateBridgeTokenIterator, error) { +// Solidity: event CreateBridgeToken(bytes32 indexed nativeBlockchainID, address indexed nativeBridgeAddress, address indexed nativeContractAddress, address bridgeTokenAddress) +func (_ERC20Bridge *ERC20BridgeFilterer) FilterCreateBridgeToken(opts *bind.FilterOpts, nativeBlockchainID [][32]byte, nativeBridgeAddress []common.Address, nativeContractAddress []common.Address) (*ERC20BridgeCreateBridgeTokenIterator, error) { - var nativeChainIDRule []interface{} - for _, nativeChainIDItem := range nativeChainID { - nativeChainIDRule = append(nativeChainIDRule, nativeChainIDItem) + var nativeBlockchainIDRule []interface{} + for _, nativeBlockchainIDItem := range nativeBlockchainID { + nativeBlockchainIDRule = append(nativeBlockchainIDRule, nativeBlockchainIDItem) } var nativeBridgeAddressRule []interface{} for _, nativeBridgeAddressItem := range nativeBridgeAddress { @@ -1030,7 +1030,7 @@ func (_ERC20Bridge *ERC20BridgeFilterer) FilterCreateBridgeToken(opts *bind.Filt nativeContractAddressRule = append(nativeContractAddressRule, nativeContractAddressItem) } - logs, sub, err := _ERC20Bridge.contract.FilterLogs(opts, "CreateBridgeToken", nativeChainIDRule, nativeBridgeAddressRule, nativeContractAddressRule) + logs, sub, err := _ERC20Bridge.contract.FilterLogs(opts, "CreateBridgeToken", nativeBlockchainIDRule, nativeBridgeAddressRule, nativeContractAddressRule) if err != nil { return nil, err } @@ -1039,12 +1039,12 @@ func (_ERC20Bridge *ERC20BridgeFilterer) FilterCreateBridgeToken(opts *bind.Filt // WatchCreateBridgeToken is a free log subscription operation binding the contract event 0xe1c61a845f79534e11924517ddbedc668d0c20e467eafb4d3bd2858e2815f3b5. // -// Solidity: event CreateBridgeToken(bytes32 indexed nativeChainID, address indexed nativeBridgeAddress, address indexed nativeContractAddress, address bridgeTokenAddress) -func (_ERC20Bridge *ERC20BridgeFilterer) WatchCreateBridgeToken(opts *bind.WatchOpts, sink chan<- *ERC20BridgeCreateBridgeToken, nativeChainID [][32]byte, nativeBridgeAddress []common.Address, nativeContractAddress []common.Address) (event.Subscription, error) { +// Solidity: event CreateBridgeToken(bytes32 indexed nativeBlockchainID, address indexed nativeBridgeAddress, address indexed nativeContractAddress, address bridgeTokenAddress) +func (_ERC20Bridge *ERC20BridgeFilterer) WatchCreateBridgeToken(opts *bind.WatchOpts, sink chan<- *ERC20BridgeCreateBridgeToken, nativeBlockchainID [][32]byte, nativeBridgeAddress []common.Address, nativeContractAddress []common.Address) (event.Subscription, error) { - var nativeChainIDRule []interface{} - for _, nativeChainIDItem := range nativeChainID { - nativeChainIDRule = append(nativeChainIDRule, nativeChainIDItem) + var nativeBlockchainIDRule []interface{} + for _, nativeBlockchainIDItem := range nativeBlockchainID { + nativeBlockchainIDRule = append(nativeBlockchainIDRule, nativeBlockchainIDItem) } var nativeBridgeAddressRule []interface{} for _, nativeBridgeAddressItem := range nativeBridgeAddress { @@ -1055,7 +1055,7 @@ func (_ERC20Bridge *ERC20BridgeFilterer) WatchCreateBridgeToken(opts *bind.Watch nativeContractAddressRule = append(nativeContractAddressRule, nativeContractAddressItem) } - logs, sub, err := _ERC20Bridge.contract.WatchLogs(opts, "CreateBridgeToken", nativeChainIDRule, nativeBridgeAddressRule, nativeContractAddressRule) + logs, sub, err := _ERC20Bridge.contract.WatchLogs(opts, "CreateBridgeToken", nativeBlockchainIDRule, nativeBridgeAddressRule, nativeContractAddressRule) if err != nil { return nil, err } @@ -1089,7 +1089,7 @@ func (_ERC20Bridge *ERC20BridgeFilterer) WatchCreateBridgeToken(opts *bind.Watch // ParseCreateBridgeToken is a log parse operation binding the contract event 0xe1c61a845f79534e11924517ddbedc668d0c20e467eafb4d3bd2858e2815f3b5. // -// Solidity: event CreateBridgeToken(bytes32 indexed nativeChainID, address indexed nativeBridgeAddress, address indexed nativeContractAddress, address bridgeTokenAddress) +// Solidity: event CreateBridgeToken(bytes32 indexed nativeBlockchainID, address indexed nativeBridgeAddress, address indexed nativeContractAddress, address bridgeTokenAddress) func (_ERC20Bridge *ERC20BridgeFilterer) ParseCreateBridgeToken(log types.Log) (*ERC20BridgeCreateBridgeToken, error) { event := new(ERC20BridgeCreateBridgeToken) if err := _ERC20Bridge.contract.UnpackLog(event, "CreateBridgeToken", log); err != nil { @@ -1620,7 +1620,7 @@ func (it *ERC20BridgeSubmitCreateBridgeTokenIterator) Close() error { // ERC20BridgeSubmitCreateBridgeToken represents a SubmitCreateBridgeToken event raised by the ERC20Bridge contract. type ERC20BridgeSubmitCreateBridgeToken struct { - DestinationChainID [32]byte + DestinationBlockchainID [32]byte DestinationBridgeAddress common.Address NativeContractAddress common.Address TeleporterMessageID *big.Int @@ -1629,12 +1629,12 @@ type ERC20BridgeSubmitCreateBridgeToken struct { // FilterSubmitCreateBridgeToken is a free log retrieval operation binding the contract event 0x110b902745a3d7d6b66732479f01de654a3bc6e501be7c8ba2c3a6f9868cb539. // -// Solidity: event SubmitCreateBridgeToken(bytes32 indexed destinationChainID, address indexed destinationBridgeAddress, address indexed nativeContractAddress, uint256 teleporterMessageID) -func (_ERC20Bridge *ERC20BridgeFilterer) FilterSubmitCreateBridgeToken(opts *bind.FilterOpts, destinationChainID [][32]byte, destinationBridgeAddress []common.Address, nativeContractAddress []common.Address) (*ERC20BridgeSubmitCreateBridgeTokenIterator, error) { +// Solidity: event SubmitCreateBridgeToken(bytes32 indexed destinationBlockchainID, address indexed destinationBridgeAddress, address indexed nativeContractAddress, uint256 teleporterMessageID) +func (_ERC20Bridge *ERC20BridgeFilterer) FilterSubmitCreateBridgeToken(opts *bind.FilterOpts, destinationBlockchainID [][32]byte, destinationBridgeAddress []common.Address, nativeContractAddress []common.Address) (*ERC20BridgeSubmitCreateBridgeTokenIterator, error) { - var destinationChainIDRule []interface{} - for _, destinationChainIDItem := range destinationChainID { - destinationChainIDRule = append(destinationChainIDRule, destinationChainIDItem) + var destinationBlockchainIDRule []interface{} + for _, destinationBlockchainIDItem := range destinationBlockchainID { + destinationBlockchainIDRule = append(destinationBlockchainIDRule, destinationBlockchainIDItem) } var destinationBridgeAddressRule []interface{} for _, destinationBridgeAddressItem := range destinationBridgeAddress { @@ -1645,7 +1645,7 @@ func (_ERC20Bridge *ERC20BridgeFilterer) FilterSubmitCreateBridgeToken(opts *bin nativeContractAddressRule = append(nativeContractAddressRule, nativeContractAddressItem) } - logs, sub, err := _ERC20Bridge.contract.FilterLogs(opts, "SubmitCreateBridgeToken", destinationChainIDRule, destinationBridgeAddressRule, nativeContractAddressRule) + logs, sub, err := _ERC20Bridge.contract.FilterLogs(opts, "SubmitCreateBridgeToken", destinationBlockchainIDRule, destinationBridgeAddressRule, nativeContractAddressRule) if err != nil { return nil, err } @@ -1654,12 +1654,12 @@ func (_ERC20Bridge *ERC20BridgeFilterer) FilterSubmitCreateBridgeToken(opts *bin // WatchSubmitCreateBridgeToken is a free log subscription operation binding the contract event 0x110b902745a3d7d6b66732479f01de654a3bc6e501be7c8ba2c3a6f9868cb539. // -// Solidity: event SubmitCreateBridgeToken(bytes32 indexed destinationChainID, address indexed destinationBridgeAddress, address indexed nativeContractAddress, uint256 teleporterMessageID) -func (_ERC20Bridge *ERC20BridgeFilterer) WatchSubmitCreateBridgeToken(opts *bind.WatchOpts, sink chan<- *ERC20BridgeSubmitCreateBridgeToken, destinationChainID [][32]byte, destinationBridgeAddress []common.Address, nativeContractAddress []common.Address) (event.Subscription, error) { +// Solidity: event SubmitCreateBridgeToken(bytes32 indexed destinationBlockchainID, address indexed destinationBridgeAddress, address indexed nativeContractAddress, uint256 teleporterMessageID) +func (_ERC20Bridge *ERC20BridgeFilterer) WatchSubmitCreateBridgeToken(opts *bind.WatchOpts, sink chan<- *ERC20BridgeSubmitCreateBridgeToken, destinationBlockchainID [][32]byte, destinationBridgeAddress []common.Address, nativeContractAddress []common.Address) (event.Subscription, error) { - var destinationChainIDRule []interface{} - for _, destinationChainIDItem := range destinationChainID { - destinationChainIDRule = append(destinationChainIDRule, destinationChainIDItem) + var destinationBlockchainIDRule []interface{} + for _, destinationBlockchainIDItem := range destinationBlockchainID { + destinationBlockchainIDRule = append(destinationBlockchainIDRule, destinationBlockchainIDItem) } var destinationBridgeAddressRule []interface{} for _, destinationBridgeAddressItem := range destinationBridgeAddress { @@ -1670,7 +1670,7 @@ func (_ERC20Bridge *ERC20BridgeFilterer) WatchSubmitCreateBridgeToken(opts *bind nativeContractAddressRule = append(nativeContractAddressRule, nativeContractAddressItem) } - logs, sub, err := _ERC20Bridge.contract.WatchLogs(opts, "SubmitCreateBridgeToken", destinationChainIDRule, destinationBridgeAddressRule, nativeContractAddressRule) + logs, sub, err := _ERC20Bridge.contract.WatchLogs(opts, "SubmitCreateBridgeToken", destinationBlockchainIDRule, destinationBridgeAddressRule, nativeContractAddressRule) if err != nil { return nil, err } @@ -1704,7 +1704,7 @@ func (_ERC20Bridge *ERC20BridgeFilterer) WatchSubmitCreateBridgeToken(opts *bind // ParseSubmitCreateBridgeToken is a log parse operation binding the contract event 0x110b902745a3d7d6b66732479f01de654a3bc6e501be7c8ba2c3a6f9868cb539. // -// Solidity: event SubmitCreateBridgeToken(bytes32 indexed destinationChainID, address indexed destinationBridgeAddress, address indexed nativeContractAddress, uint256 teleporterMessageID) +// Solidity: event SubmitCreateBridgeToken(bytes32 indexed destinationBlockchainID, address indexed destinationBridgeAddress, address indexed nativeContractAddress, uint256 teleporterMessageID) func (_ERC20Bridge *ERC20BridgeFilterer) ParseSubmitCreateBridgeToken(log types.Log) (*ERC20BridgeSubmitCreateBridgeToken, error) { event := new(ERC20BridgeSubmitCreateBridgeToken) if err := _ERC20Bridge.contract.UnpackLog(event, "SubmitCreateBridgeToken", log); err != nil { diff --git a/abi-bindings/go/CrossChainApplications/ExampleMessenger/ExampleCrossChainMessenger/ExampleCrossChainMessenger.go b/abi-bindings/go/CrossChainApplications/ExampleMessenger/ExampleCrossChainMessenger/ExampleCrossChainMessenger.go index 2397a5078..a4e28bfeb 100644 --- a/abi-bindings/go/CrossChainApplications/ExampleMessenger/ExampleCrossChainMessenger/ExampleCrossChainMessenger.go +++ b/abi-bindings/go/CrossChainApplications/ExampleMessenger/ExampleCrossChainMessenger/ExampleCrossChainMessenger.go @@ -31,7 +31,7 @@ var ( // ExampleCrossChainMessengerMetaData contains all meta data concerning the ExampleCrossChainMessenger contract. var ExampleCrossChainMessengerMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"teleporterRegistryAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"oldMinTeleporterVersion\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"newMinTeleporterVersion\",\"type\":\"uint256\"}],\"name\":\"MinTeleporterVersionUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"previousOwner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"OwnershipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"originChainID\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"originSenderAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"ReceiveMessage\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"destinationAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"feeTokenAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"feeAmount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"requiredGasLimit\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"SendMessage\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"originChainID\",\"type\":\"bytes32\"}],\"name\":\"getCurrentMessage\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minTeleporterVersion\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"originChainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"originSenderAddress\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"message\",\"type\":\"bytes\"}],\"name\":\"receiveTeleporterMessage\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"feeTokenAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"feeAmount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"requiredGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"sendMessage\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"teleporterRegistry\",\"outputs\":[{\"internalType\":\"contractTeleporterRegistry\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateMinTeleporterVersion\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"teleporterRegistryAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"oldMinTeleporterVersion\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"newMinTeleporterVersion\",\"type\":\"uint256\"}],\"name\":\"MinTeleporterVersionUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"previousOwner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"OwnershipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"originBlockchainID\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"originSenderAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"ReceiveMessage\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"destinationAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"feeTokenAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"feeAmount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"requiredGasLimit\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"SendMessage\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"originBlockchainID\",\"type\":\"bytes32\"}],\"name\":\"getCurrentMessage\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minTeleporterVersion\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"originBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"originSenderAddress\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"message\",\"type\":\"bytes\"}],\"name\":\"receiveTeleporterMessage\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"feeTokenAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"feeAmount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"requiredGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"sendMessage\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"teleporterRegistry\",\"outputs\":[{\"internalType\":\"contractTeleporterRegistry\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateMinTeleporterVersion\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", } // ExampleCrossChainMessengerABI is the input ABI used to generate the binding from. @@ -182,10 +182,10 @@ func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerTransactorRaw) Tran // GetCurrentMessage is a free data retrieval call binding the contract method 0xb33fead4. // -// Solidity: function getCurrentMessage(bytes32 originChainID) view returns(address, string) -func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerCaller) GetCurrentMessage(opts *bind.CallOpts, originChainID [32]byte) (common.Address, string, error) { +// Solidity: function getCurrentMessage(bytes32 originBlockchainID) view returns(address, string) +func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerCaller) GetCurrentMessage(opts *bind.CallOpts, originBlockchainID [32]byte) (common.Address, string, error) { var out []interface{} - err := _ExampleCrossChainMessenger.contract.Call(opts, &out, "getCurrentMessage", originChainID) + err := _ExampleCrossChainMessenger.contract.Call(opts, &out, "getCurrentMessage", originBlockchainID) if err != nil { return *new(common.Address), *new(string), err @@ -200,16 +200,16 @@ func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerCaller) GetCurrentM // GetCurrentMessage is a free data retrieval call binding the contract method 0xb33fead4. // -// Solidity: function getCurrentMessage(bytes32 originChainID) view returns(address, string) -func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerSession) GetCurrentMessage(originChainID [32]byte) (common.Address, string, error) { - return _ExampleCrossChainMessenger.Contract.GetCurrentMessage(&_ExampleCrossChainMessenger.CallOpts, originChainID) +// Solidity: function getCurrentMessage(bytes32 originBlockchainID) view returns(address, string) +func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerSession) GetCurrentMessage(originBlockchainID [32]byte) (common.Address, string, error) { + return _ExampleCrossChainMessenger.Contract.GetCurrentMessage(&_ExampleCrossChainMessenger.CallOpts, originBlockchainID) } // GetCurrentMessage is a free data retrieval call binding the contract method 0xb33fead4. // -// Solidity: function getCurrentMessage(bytes32 originChainID) view returns(address, string) -func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerCallerSession) GetCurrentMessage(originChainID [32]byte) (common.Address, string, error) { - return _ExampleCrossChainMessenger.Contract.GetCurrentMessage(&_ExampleCrossChainMessenger.CallOpts, originChainID) +// Solidity: function getCurrentMessage(bytes32 originBlockchainID) view returns(address, string) +func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerCallerSession) GetCurrentMessage(originBlockchainID [32]byte) (common.Address, string, error) { + return _ExampleCrossChainMessenger.Contract.GetCurrentMessage(&_ExampleCrossChainMessenger.CallOpts, originBlockchainID) } // MinTeleporterVersion is a free data retrieval call binding the contract method 0xe49cc553. @@ -307,23 +307,23 @@ func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerCallerSession) Tele // ReceiveTeleporterMessage is a paid mutator transaction binding the contract method 0xc868efaa. // -// Solidity: function receiveTeleporterMessage(bytes32 originChainID, address originSenderAddress, bytes message) returns() -func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerTransactor) ReceiveTeleporterMessage(opts *bind.TransactOpts, originChainID [32]byte, originSenderAddress common.Address, message []byte) (*types.Transaction, error) { - return _ExampleCrossChainMessenger.contract.Transact(opts, "receiveTeleporterMessage", originChainID, originSenderAddress, message) +// Solidity: function receiveTeleporterMessage(bytes32 originBlockchainID, address originSenderAddress, bytes message) returns() +func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerTransactor) ReceiveTeleporterMessage(opts *bind.TransactOpts, originBlockchainID [32]byte, originSenderAddress common.Address, message []byte) (*types.Transaction, error) { + return _ExampleCrossChainMessenger.contract.Transact(opts, "receiveTeleporterMessage", originBlockchainID, originSenderAddress, message) } // ReceiveTeleporterMessage is a paid mutator transaction binding the contract method 0xc868efaa. // -// Solidity: function receiveTeleporterMessage(bytes32 originChainID, address originSenderAddress, bytes message) returns() -func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerSession) ReceiveTeleporterMessage(originChainID [32]byte, originSenderAddress common.Address, message []byte) (*types.Transaction, error) { - return _ExampleCrossChainMessenger.Contract.ReceiveTeleporterMessage(&_ExampleCrossChainMessenger.TransactOpts, originChainID, originSenderAddress, message) +// Solidity: function receiveTeleporterMessage(bytes32 originBlockchainID, address originSenderAddress, bytes message) returns() +func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerSession) ReceiveTeleporterMessage(originBlockchainID [32]byte, originSenderAddress common.Address, message []byte) (*types.Transaction, error) { + return _ExampleCrossChainMessenger.Contract.ReceiveTeleporterMessage(&_ExampleCrossChainMessenger.TransactOpts, originBlockchainID, originSenderAddress, message) } // ReceiveTeleporterMessage is a paid mutator transaction binding the contract method 0xc868efaa. // -// Solidity: function receiveTeleporterMessage(bytes32 originChainID, address originSenderAddress, bytes message) returns() -func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerTransactorSession) ReceiveTeleporterMessage(originChainID [32]byte, originSenderAddress common.Address, message []byte) (*types.Transaction, error) { - return _ExampleCrossChainMessenger.Contract.ReceiveTeleporterMessage(&_ExampleCrossChainMessenger.TransactOpts, originChainID, originSenderAddress, message) +// Solidity: function receiveTeleporterMessage(bytes32 originBlockchainID, address originSenderAddress, bytes message) returns() +func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerTransactorSession) ReceiveTeleporterMessage(originBlockchainID [32]byte, originSenderAddress common.Address, message []byte) (*types.Transaction, error) { + return _ExampleCrossChainMessenger.Contract.ReceiveTeleporterMessage(&_ExampleCrossChainMessenger.TransactOpts, originBlockchainID, originSenderAddress, message) } // RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6. @@ -349,23 +349,23 @@ func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerTransactorSession) // SendMessage is a paid mutator transaction binding the contract method 0xf63d09d7. // -// Solidity: function sendMessage(bytes32 destinationChainID, address destinationAddress, address feeTokenAddress, uint256 feeAmount, uint256 requiredGasLimit, string message) returns(uint256) -func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerTransactor) SendMessage(opts *bind.TransactOpts, destinationChainID [32]byte, destinationAddress common.Address, feeTokenAddress common.Address, feeAmount *big.Int, requiredGasLimit *big.Int, message string) (*types.Transaction, error) { - return _ExampleCrossChainMessenger.contract.Transact(opts, "sendMessage", destinationChainID, destinationAddress, feeTokenAddress, feeAmount, requiredGasLimit, message) +// Solidity: function sendMessage(bytes32 destinationBlockchainID, address destinationAddress, address feeTokenAddress, uint256 feeAmount, uint256 requiredGasLimit, string message) returns(uint256) +func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerTransactor) SendMessage(opts *bind.TransactOpts, destinationBlockchainID [32]byte, destinationAddress common.Address, feeTokenAddress common.Address, feeAmount *big.Int, requiredGasLimit *big.Int, message string) (*types.Transaction, error) { + return _ExampleCrossChainMessenger.contract.Transact(opts, "sendMessage", destinationBlockchainID, destinationAddress, feeTokenAddress, feeAmount, requiredGasLimit, message) } // SendMessage is a paid mutator transaction binding the contract method 0xf63d09d7. // -// Solidity: function sendMessage(bytes32 destinationChainID, address destinationAddress, address feeTokenAddress, uint256 feeAmount, uint256 requiredGasLimit, string message) returns(uint256) -func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerSession) SendMessage(destinationChainID [32]byte, destinationAddress common.Address, feeTokenAddress common.Address, feeAmount *big.Int, requiredGasLimit *big.Int, message string) (*types.Transaction, error) { - return _ExampleCrossChainMessenger.Contract.SendMessage(&_ExampleCrossChainMessenger.TransactOpts, destinationChainID, destinationAddress, feeTokenAddress, feeAmount, requiredGasLimit, message) +// Solidity: function sendMessage(bytes32 destinationBlockchainID, address destinationAddress, address feeTokenAddress, uint256 feeAmount, uint256 requiredGasLimit, string message) returns(uint256) +func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerSession) SendMessage(destinationBlockchainID [32]byte, destinationAddress common.Address, feeTokenAddress common.Address, feeAmount *big.Int, requiredGasLimit *big.Int, message string) (*types.Transaction, error) { + return _ExampleCrossChainMessenger.Contract.SendMessage(&_ExampleCrossChainMessenger.TransactOpts, destinationBlockchainID, destinationAddress, feeTokenAddress, feeAmount, requiredGasLimit, message) } // SendMessage is a paid mutator transaction binding the contract method 0xf63d09d7. // -// Solidity: function sendMessage(bytes32 destinationChainID, address destinationAddress, address feeTokenAddress, uint256 feeAmount, uint256 requiredGasLimit, string message) returns(uint256) -func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerTransactorSession) SendMessage(destinationChainID [32]byte, destinationAddress common.Address, feeTokenAddress common.Address, feeAmount *big.Int, requiredGasLimit *big.Int, message string) (*types.Transaction, error) { - return _ExampleCrossChainMessenger.Contract.SendMessage(&_ExampleCrossChainMessenger.TransactOpts, destinationChainID, destinationAddress, feeTokenAddress, feeAmount, requiredGasLimit, message) +// Solidity: function sendMessage(bytes32 destinationBlockchainID, address destinationAddress, address feeTokenAddress, uint256 feeAmount, uint256 requiredGasLimit, string message) returns(uint256) +func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerTransactorSession) SendMessage(destinationBlockchainID [32]byte, destinationAddress common.Address, feeTokenAddress common.Address, feeAmount *big.Int, requiredGasLimit *big.Int, message string) (*types.Transaction, error) { + return _ExampleCrossChainMessenger.Contract.SendMessage(&_ExampleCrossChainMessenger.TransactOpts, destinationBlockchainID, destinationAddress, feeTokenAddress, feeAmount, requiredGasLimit, message) } // TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b. @@ -785,7 +785,7 @@ func (it *ExampleCrossChainMessengerReceiveMessageIterator) Close() error { // ExampleCrossChainMessengerReceiveMessage represents a ReceiveMessage event raised by the ExampleCrossChainMessenger contract. type ExampleCrossChainMessengerReceiveMessage struct { - OriginChainID [32]byte + OriginBlockchainID [32]byte OriginSenderAddress common.Address Message string Raw types.Log // Blockchain specific contextual infos @@ -793,19 +793,19 @@ type ExampleCrossChainMessengerReceiveMessage struct { // FilterReceiveMessage is a free log retrieval operation binding the contract event 0x1f5c800b5f2b573929a7948f82a199c2a212851b53a6c5bd703ece23999d24aa. // -// Solidity: event ReceiveMessage(bytes32 indexed originChainID, address indexed originSenderAddress, string message) -func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerFilterer) FilterReceiveMessage(opts *bind.FilterOpts, originChainID [][32]byte, originSenderAddress []common.Address) (*ExampleCrossChainMessengerReceiveMessageIterator, error) { +// Solidity: event ReceiveMessage(bytes32 indexed originBlockchainID, address indexed originSenderAddress, string message) +func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerFilterer) FilterReceiveMessage(opts *bind.FilterOpts, originBlockchainID [][32]byte, originSenderAddress []common.Address) (*ExampleCrossChainMessengerReceiveMessageIterator, error) { - var originChainIDRule []interface{} - for _, originChainIDItem := range originChainID { - originChainIDRule = append(originChainIDRule, originChainIDItem) + var originBlockchainIDRule []interface{} + for _, originBlockchainIDItem := range originBlockchainID { + originBlockchainIDRule = append(originBlockchainIDRule, originBlockchainIDItem) } var originSenderAddressRule []interface{} for _, originSenderAddressItem := range originSenderAddress { originSenderAddressRule = append(originSenderAddressRule, originSenderAddressItem) } - logs, sub, err := _ExampleCrossChainMessenger.contract.FilterLogs(opts, "ReceiveMessage", originChainIDRule, originSenderAddressRule) + logs, sub, err := _ExampleCrossChainMessenger.contract.FilterLogs(opts, "ReceiveMessage", originBlockchainIDRule, originSenderAddressRule) if err != nil { return nil, err } @@ -814,19 +814,19 @@ func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerFilterer) FilterRec // WatchReceiveMessage is a free log subscription operation binding the contract event 0x1f5c800b5f2b573929a7948f82a199c2a212851b53a6c5bd703ece23999d24aa. // -// Solidity: event ReceiveMessage(bytes32 indexed originChainID, address indexed originSenderAddress, string message) -func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerFilterer) WatchReceiveMessage(opts *bind.WatchOpts, sink chan<- *ExampleCrossChainMessengerReceiveMessage, originChainID [][32]byte, originSenderAddress []common.Address) (event.Subscription, error) { +// Solidity: event ReceiveMessage(bytes32 indexed originBlockchainID, address indexed originSenderAddress, string message) +func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerFilterer) WatchReceiveMessage(opts *bind.WatchOpts, sink chan<- *ExampleCrossChainMessengerReceiveMessage, originBlockchainID [][32]byte, originSenderAddress []common.Address) (event.Subscription, error) { - var originChainIDRule []interface{} - for _, originChainIDItem := range originChainID { - originChainIDRule = append(originChainIDRule, originChainIDItem) + var originBlockchainIDRule []interface{} + for _, originBlockchainIDItem := range originBlockchainID { + originBlockchainIDRule = append(originBlockchainIDRule, originBlockchainIDItem) } var originSenderAddressRule []interface{} for _, originSenderAddressItem := range originSenderAddress { originSenderAddressRule = append(originSenderAddressRule, originSenderAddressItem) } - logs, sub, err := _ExampleCrossChainMessenger.contract.WatchLogs(opts, "ReceiveMessage", originChainIDRule, originSenderAddressRule) + logs, sub, err := _ExampleCrossChainMessenger.contract.WatchLogs(opts, "ReceiveMessage", originBlockchainIDRule, originSenderAddressRule) if err != nil { return nil, err } @@ -860,7 +860,7 @@ func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerFilterer) WatchRece // ParseReceiveMessage is a log parse operation binding the contract event 0x1f5c800b5f2b573929a7948f82a199c2a212851b53a6c5bd703ece23999d24aa. // -// Solidity: event ReceiveMessage(bytes32 indexed originChainID, address indexed originSenderAddress, string message) +// Solidity: event ReceiveMessage(bytes32 indexed originBlockchainID, address indexed originSenderAddress, string message) func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerFilterer) ParseReceiveMessage(log types.Log) (*ExampleCrossChainMessengerReceiveMessage, error) { event := new(ExampleCrossChainMessengerReceiveMessage) if err := _ExampleCrossChainMessenger.contract.UnpackLog(event, "ReceiveMessage", log); err != nil { @@ -939,30 +939,30 @@ func (it *ExampleCrossChainMessengerSendMessageIterator) Close() error { // ExampleCrossChainMessengerSendMessage represents a SendMessage event raised by the ExampleCrossChainMessenger contract. type ExampleCrossChainMessengerSendMessage struct { - DestinationChainID [32]byte - DestinationAddress common.Address - FeeTokenAddress common.Address - FeeAmount *big.Int - RequiredGasLimit *big.Int - Message string - Raw types.Log // Blockchain specific contextual infos + DestinationBlockchainID [32]byte + DestinationAddress common.Address + FeeTokenAddress common.Address + FeeAmount *big.Int + RequiredGasLimit *big.Int + Message string + Raw types.Log // Blockchain specific contextual infos } // FilterSendMessage is a free log retrieval operation binding the contract event 0xa06eff1edd0c66b8dc96d086dda7ba263edf88d7417e6cb15073b5e7bff8a8ca. // -// Solidity: event SendMessage(bytes32 indexed destinationChainID, address indexed destinationAddress, address feeTokenAddress, uint256 feeAmount, uint256 requiredGasLimit, string message) -func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerFilterer) FilterSendMessage(opts *bind.FilterOpts, destinationChainID [][32]byte, destinationAddress []common.Address) (*ExampleCrossChainMessengerSendMessageIterator, error) { +// Solidity: event SendMessage(bytes32 indexed destinationBlockchainID, address indexed destinationAddress, address feeTokenAddress, uint256 feeAmount, uint256 requiredGasLimit, string message) +func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerFilterer) FilterSendMessage(opts *bind.FilterOpts, destinationBlockchainID [][32]byte, destinationAddress []common.Address) (*ExampleCrossChainMessengerSendMessageIterator, error) { - var destinationChainIDRule []interface{} - for _, destinationChainIDItem := range destinationChainID { - destinationChainIDRule = append(destinationChainIDRule, destinationChainIDItem) + var destinationBlockchainIDRule []interface{} + for _, destinationBlockchainIDItem := range destinationBlockchainID { + destinationBlockchainIDRule = append(destinationBlockchainIDRule, destinationBlockchainIDItem) } var destinationAddressRule []interface{} for _, destinationAddressItem := range destinationAddress { destinationAddressRule = append(destinationAddressRule, destinationAddressItem) } - logs, sub, err := _ExampleCrossChainMessenger.contract.FilterLogs(opts, "SendMessage", destinationChainIDRule, destinationAddressRule) + logs, sub, err := _ExampleCrossChainMessenger.contract.FilterLogs(opts, "SendMessage", destinationBlockchainIDRule, destinationAddressRule) if err != nil { return nil, err } @@ -971,19 +971,19 @@ func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerFilterer) FilterSen // WatchSendMessage is a free log subscription operation binding the contract event 0xa06eff1edd0c66b8dc96d086dda7ba263edf88d7417e6cb15073b5e7bff8a8ca. // -// Solidity: event SendMessage(bytes32 indexed destinationChainID, address indexed destinationAddress, address feeTokenAddress, uint256 feeAmount, uint256 requiredGasLimit, string message) -func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerFilterer) WatchSendMessage(opts *bind.WatchOpts, sink chan<- *ExampleCrossChainMessengerSendMessage, destinationChainID [][32]byte, destinationAddress []common.Address) (event.Subscription, error) { +// Solidity: event SendMessage(bytes32 indexed destinationBlockchainID, address indexed destinationAddress, address feeTokenAddress, uint256 feeAmount, uint256 requiredGasLimit, string message) +func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerFilterer) WatchSendMessage(opts *bind.WatchOpts, sink chan<- *ExampleCrossChainMessengerSendMessage, destinationBlockchainID [][32]byte, destinationAddress []common.Address) (event.Subscription, error) { - var destinationChainIDRule []interface{} - for _, destinationChainIDItem := range destinationChainID { - destinationChainIDRule = append(destinationChainIDRule, destinationChainIDItem) + var destinationBlockchainIDRule []interface{} + for _, destinationBlockchainIDItem := range destinationBlockchainID { + destinationBlockchainIDRule = append(destinationBlockchainIDRule, destinationBlockchainIDItem) } var destinationAddressRule []interface{} for _, destinationAddressItem := range destinationAddress { destinationAddressRule = append(destinationAddressRule, destinationAddressItem) } - logs, sub, err := _ExampleCrossChainMessenger.contract.WatchLogs(opts, "SendMessage", destinationChainIDRule, destinationAddressRule) + logs, sub, err := _ExampleCrossChainMessenger.contract.WatchLogs(opts, "SendMessage", destinationBlockchainIDRule, destinationAddressRule) if err != nil { return nil, err } @@ -1017,7 +1017,7 @@ func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerFilterer) WatchSend // ParseSendMessage is a log parse operation binding the contract event 0xa06eff1edd0c66b8dc96d086dda7ba263edf88d7417e6cb15073b5e7bff8a8ca. // -// Solidity: event SendMessage(bytes32 indexed destinationChainID, address indexed destinationAddress, address feeTokenAddress, uint256 feeAmount, uint256 requiredGasLimit, string message) +// Solidity: event SendMessage(bytes32 indexed destinationBlockchainID, address indexed destinationAddress, address feeTokenAddress, uint256 feeAmount, uint256 requiredGasLimit, string message) func (_ExampleCrossChainMessenger *ExampleCrossChainMessengerFilterer) ParseSendMessage(log types.Log) (*ExampleCrossChainMessengerSendMessage, error) { event := new(ExampleCrossChainMessengerSendMessage) if err := _ExampleCrossChainMessenger.contract.UnpackLog(event, "SendMessage", log); err != nil { diff --git a/abi-bindings/go/CrossChainApplications/VerifiedBlockHash/BlockHashPublisher/BlockHashPublisher.go b/abi-bindings/go/CrossChainApplications/VerifiedBlockHash/BlockHashPublisher/BlockHashPublisher.go index bf6821c91..68ab21d5e 100644 --- a/abi-bindings/go/CrossChainApplications/VerifiedBlockHash/BlockHashPublisher/BlockHashPublisher.go +++ b/abi-bindings/go/CrossChainApplications/VerifiedBlockHash/BlockHashPublisher/BlockHashPublisher.go @@ -31,7 +31,7 @@ var ( // BlockHashPublisherMetaData contains all meta data concerning the BlockHashPublisher contract. var BlockHashPublisherMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"teleporterRegistryAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"destinationAddress\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"blockHeight\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"}],\"name\":\"PublishBlockHash\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"RECEIVE_BLOCK_HASH_REQUIRED_GAS_LIMIT\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationAddress\",\"type\":\"address\"}],\"name\":\"publishLatestBlockHash\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"teleporterRegistry\",\"outputs\":[{\"internalType\":\"contractTeleporterRegistry\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"teleporterRegistryAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"destinationAddress\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"blockHeight\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"}],\"name\":\"PublishBlockHash\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"RECEIVE_BLOCK_HASH_REQUIRED_GAS_LIMIT\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationAddress\",\"type\":\"address\"}],\"name\":\"publishLatestBlockHash\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"teleporterRegistry\",\"outputs\":[{\"internalType\":\"contractTeleporterRegistry\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", } // BlockHashPublisherABI is the input ABI used to generate the binding from. @@ -244,23 +244,23 @@ func (_BlockHashPublisher *BlockHashPublisherCallerSession) TeleporterRegistry() // PublishLatestBlockHash is a paid mutator transaction binding the contract method 0x82ab2b86. // -// Solidity: function publishLatestBlockHash(bytes32 destinationChainID, address destinationAddress) returns(uint256) -func (_BlockHashPublisher *BlockHashPublisherTransactor) PublishLatestBlockHash(opts *bind.TransactOpts, destinationChainID [32]byte, destinationAddress common.Address) (*types.Transaction, error) { - return _BlockHashPublisher.contract.Transact(opts, "publishLatestBlockHash", destinationChainID, destinationAddress) +// Solidity: function publishLatestBlockHash(bytes32 destinationBlockchainID, address destinationAddress) returns(uint256) +func (_BlockHashPublisher *BlockHashPublisherTransactor) PublishLatestBlockHash(opts *bind.TransactOpts, destinationBlockchainID [32]byte, destinationAddress common.Address) (*types.Transaction, error) { + return _BlockHashPublisher.contract.Transact(opts, "publishLatestBlockHash", destinationBlockchainID, destinationAddress) } // PublishLatestBlockHash is a paid mutator transaction binding the contract method 0x82ab2b86. // -// Solidity: function publishLatestBlockHash(bytes32 destinationChainID, address destinationAddress) returns(uint256) -func (_BlockHashPublisher *BlockHashPublisherSession) PublishLatestBlockHash(destinationChainID [32]byte, destinationAddress common.Address) (*types.Transaction, error) { - return _BlockHashPublisher.Contract.PublishLatestBlockHash(&_BlockHashPublisher.TransactOpts, destinationChainID, destinationAddress) +// Solidity: function publishLatestBlockHash(bytes32 destinationBlockchainID, address destinationAddress) returns(uint256) +func (_BlockHashPublisher *BlockHashPublisherSession) PublishLatestBlockHash(destinationBlockchainID [32]byte, destinationAddress common.Address) (*types.Transaction, error) { + return _BlockHashPublisher.Contract.PublishLatestBlockHash(&_BlockHashPublisher.TransactOpts, destinationBlockchainID, destinationAddress) } // PublishLatestBlockHash is a paid mutator transaction binding the contract method 0x82ab2b86. // -// Solidity: function publishLatestBlockHash(bytes32 destinationChainID, address destinationAddress) returns(uint256) -func (_BlockHashPublisher *BlockHashPublisherTransactorSession) PublishLatestBlockHash(destinationChainID [32]byte, destinationAddress common.Address) (*types.Transaction, error) { - return _BlockHashPublisher.Contract.PublishLatestBlockHash(&_BlockHashPublisher.TransactOpts, destinationChainID, destinationAddress) +// Solidity: function publishLatestBlockHash(bytes32 destinationBlockchainID, address destinationAddress) returns(uint256) +func (_BlockHashPublisher *BlockHashPublisherTransactorSession) PublishLatestBlockHash(destinationBlockchainID [32]byte, destinationAddress common.Address) (*types.Transaction, error) { + return _BlockHashPublisher.Contract.PublishLatestBlockHash(&_BlockHashPublisher.TransactOpts, destinationBlockchainID, destinationAddress) } // BlockHashPublisherPublishBlockHashIterator is returned from FilterPublishBlockHash and is used to iterate over the raw logs and unpacked data for PublishBlockHash events raised by the BlockHashPublisher contract. @@ -332,21 +332,21 @@ func (it *BlockHashPublisherPublishBlockHashIterator) Close() error { // BlockHashPublisherPublishBlockHash represents a PublishBlockHash event raised by the BlockHashPublisher contract. type BlockHashPublisherPublishBlockHash struct { - DestinationChainID [32]byte - DestinationAddress common.Address - BlockHeight *big.Int - BlockHash [32]byte - Raw types.Log // Blockchain specific contextual infos + DestinationBlockchainID [32]byte + DestinationAddress common.Address + BlockHeight *big.Int + BlockHash [32]byte + Raw types.Log // Blockchain specific contextual infos } // FilterPublishBlockHash is a free log retrieval operation binding the contract event 0xe13623d33d18131ce960c33b1282ceac1fe7b5ccfcf7f8c0f6dad32dd61e3bdd. // -// Solidity: event PublishBlockHash(bytes32 indexed destinationChainID, address indexed destinationAddress, uint256 indexed blockHeight, bytes32 blockHash) -func (_BlockHashPublisher *BlockHashPublisherFilterer) FilterPublishBlockHash(opts *bind.FilterOpts, destinationChainID [][32]byte, destinationAddress []common.Address, blockHeight []*big.Int) (*BlockHashPublisherPublishBlockHashIterator, error) { +// Solidity: event PublishBlockHash(bytes32 indexed destinationBlockchainID, address indexed destinationAddress, uint256 indexed blockHeight, bytes32 blockHash) +func (_BlockHashPublisher *BlockHashPublisherFilterer) FilterPublishBlockHash(opts *bind.FilterOpts, destinationBlockchainID [][32]byte, destinationAddress []common.Address, blockHeight []*big.Int) (*BlockHashPublisherPublishBlockHashIterator, error) { - var destinationChainIDRule []interface{} - for _, destinationChainIDItem := range destinationChainID { - destinationChainIDRule = append(destinationChainIDRule, destinationChainIDItem) + var destinationBlockchainIDRule []interface{} + for _, destinationBlockchainIDItem := range destinationBlockchainID { + destinationBlockchainIDRule = append(destinationBlockchainIDRule, destinationBlockchainIDItem) } var destinationAddressRule []interface{} for _, destinationAddressItem := range destinationAddress { @@ -357,7 +357,7 @@ func (_BlockHashPublisher *BlockHashPublisherFilterer) FilterPublishBlockHash(op blockHeightRule = append(blockHeightRule, blockHeightItem) } - logs, sub, err := _BlockHashPublisher.contract.FilterLogs(opts, "PublishBlockHash", destinationChainIDRule, destinationAddressRule, blockHeightRule) + logs, sub, err := _BlockHashPublisher.contract.FilterLogs(opts, "PublishBlockHash", destinationBlockchainIDRule, destinationAddressRule, blockHeightRule) if err != nil { return nil, err } @@ -366,12 +366,12 @@ func (_BlockHashPublisher *BlockHashPublisherFilterer) FilterPublishBlockHash(op // WatchPublishBlockHash is a free log subscription operation binding the contract event 0xe13623d33d18131ce960c33b1282ceac1fe7b5ccfcf7f8c0f6dad32dd61e3bdd. // -// Solidity: event PublishBlockHash(bytes32 indexed destinationChainID, address indexed destinationAddress, uint256 indexed blockHeight, bytes32 blockHash) -func (_BlockHashPublisher *BlockHashPublisherFilterer) WatchPublishBlockHash(opts *bind.WatchOpts, sink chan<- *BlockHashPublisherPublishBlockHash, destinationChainID [][32]byte, destinationAddress []common.Address, blockHeight []*big.Int) (event.Subscription, error) { +// Solidity: event PublishBlockHash(bytes32 indexed destinationBlockchainID, address indexed destinationAddress, uint256 indexed blockHeight, bytes32 blockHash) +func (_BlockHashPublisher *BlockHashPublisherFilterer) WatchPublishBlockHash(opts *bind.WatchOpts, sink chan<- *BlockHashPublisherPublishBlockHash, destinationBlockchainID [][32]byte, destinationAddress []common.Address, blockHeight []*big.Int) (event.Subscription, error) { - var destinationChainIDRule []interface{} - for _, destinationChainIDItem := range destinationChainID { - destinationChainIDRule = append(destinationChainIDRule, destinationChainIDItem) + var destinationBlockchainIDRule []interface{} + for _, destinationBlockchainIDItem := range destinationBlockchainID { + destinationBlockchainIDRule = append(destinationBlockchainIDRule, destinationBlockchainIDItem) } var destinationAddressRule []interface{} for _, destinationAddressItem := range destinationAddress { @@ -382,7 +382,7 @@ func (_BlockHashPublisher *BlockHashPublisherFilterer) WatchPublishBlockHash(opt blockHeightRule = append(blockHeightRule, blockHeightItem) } - logs, sub, err := _BlockHashPublisher.contract.WatchLogs(opts, "PublishBlockHash", destinationChainIDRule, destinationAddressRule, blockHeightRule) + logs, sub, err := _BlockHashPublisher.contract.WatchLogs(opts, "PublishBlockHash", destinationBlockchainIDRule, destinationAddressRule, blockHeightRule) if err != nil { return nil, err } @@ -416,7 +416,7 @@ func (_BlockHashPublisher *BlockHashPublisherFilterer) WatchPublishBlockHash(opt // ParsePublishBlockHash is a log parse operation binding the contract event 0xe13623d33d18131ce960c33b1282ceac1fe7b5ccfcf7f8c0f6dad32dd61e3bdd. // -// Solidity: event PublishBlockHash(bytes32 indexed destinationChainID, address indexed destinationAddress, uint256 indexed blockHeight, bytes32 blockHash) +// Solidity: event PublishBlockHash(bytes32 indexed destinationBlockchainID, address indexed destinationAddress, uint256 indexed blockHeight, bytes32 blockHash) func (_BlockHashPublisher *BlockHashPublisherFilterer) ParsePublishBlockHash(log types.Log) (*BlockHashPublisherPublishBlockHash, error) { event := new(BlockHashPublisherPublishBlockHash) if err := _BlockHashPublisher.contract.UnpackLog(event, "PublishBlockHash", log); err != nil { diff --git a/abi-bindings/go/CrossChainApplications/VerifiedBlockHash/BlockHashReceiver/BlockHashReceiver.go b/abi-bindings/go/CrossChainApplications/VerifiedBlockHash/BlockHashReceiver/BlockHashReceiver.go index 83640de58..d6448ddf8 100644 --- a/abi-bindings/go/CrossChainApplications/VerifiedBlockHash/BlockHashReceiver/BlockHashReceiver.go +++ b/abi-bindings/go/CrossChainApplications/VerifiedBlockHash/BlockHashReceiver/BlockHashReceiver.go @@ -31,7 +31,7 @@ var ( // BlockHashReceiverMetaData contains all meta data concerning the BlockHashReceiver contract. var BlockHashReceiverMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"teleporterRegistryAddress\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"publisherChainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"publisherContractAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"oldMinTeleporterVersion\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"newMinTeleporterVersion\",\"type\":\"uint256\"}],\"name\":\"MinTeleporterVersionUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"previousOwner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"OwnershipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"originChainID\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"originSenderAddress\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"blockHeight\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"}],\"name\":\"ReceiveBlockHash\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"getLatestBlockInfo\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestBlockHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestBlockHeight\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minTeleporterVersion\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"originChainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"originSenderAddress\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"message\",\"type\":\"bytes\"}],\"name\":\"receiveTeleporterMessage\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"sourceChainID\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"sourcePublisherContractAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"teleporterRegistry\",\"outputs\":[{\"internalType\":\"contractTeleporterRegistry\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateMinTeleporterVersion\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"teleporterRegistryAddress\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"publisherBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"publisherContractAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"oldMinTeleporterVersion\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"newMinTeleporterVersion\",\"type\":\"uint256\"}],\"name\":\"MinTeleporterVersionUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"previousOwner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"OwnershipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"originBlockchainID\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"originSenderAddress\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"blockHeight\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"}],\"name\":\"ReceiveBlockHash\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"getLatestBlockInfo\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestBlockHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestBlockHeight\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minTeleporterVersion\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"originBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"originSenderAddress\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"message\",\"type\":\"bytes\"}],\"name\":\"receiveTeleporterMessage\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"sourceBlockchainID\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"sourcePublisherContractAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"teleporterRegistry\",\"outputs\":[{\"internalType\":\"contractTeleporterRegistry\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateMinTeleporterVersion\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", } // BlockHashReceiverABI is the input ABI used to generate the binding from. @@ -336,12 +336,12 @@ func (_BlockHashReceiver *BlockHashReceiverCallerSession) Owner() (common.Addres return _BlockHashReceiver.Contract.Owner(&_BlockHashReceiver.CallOpts) } -// SourceChainID is a free data retrieval call binding the contract method 0x4c335368. +// SourceBlockchainID is a free data retrieval call binding the contract method 0x29b7b3fd. // -// Solidity: function sourceChainID() view returns(bytes32) -func (_BlockHashReceiver *BlockHashReceiverCaller) SourceChainID(opts *bind.CallOpts) ([32]byte, error) { +// Solidity: function sourceBlockchainID() view returns(bytes32) +func (_BlockHashReceiver *BlockHashReceiverCaller) SourceBlockchainID(opts *bind.CallOpts) ([32]byte, error) { var out []interface{} - err := _BlockHashReceiver.contract.Call(opts, &out, "sourceChainID") + err := _BlockHashReceiver.contract.Call(opts, &out, "sourceBlockchainID") if err != nil { return *new([32]byte), err @@ -353,18 +353,18 @@ func (_BlockHashReceiver *BlockHashReceiverCaller) SourceChainID(opts *bind.Call } -// SourceChainID is a free data retrieval call binding the contract method 0x4c335368. +// SourceBlockchainID is a free data retrieval call binding the contract method 0x29b7b3fd. // -// Solidity: function sourceChainID() view returns(bytes32) -func (_BlockHashReceiver *BlockHashReceiverSession) SourceChainID() ([32]byte, error) { - return _BlockHashReceiver.Contract.SourceChainID(&_BlockHashReceiver.CallOpts) +// Solidity: function sourceBlockchainID() view returns(bytes32) +func (_BlockHashReceiver *BlockHashReceiverSession) SourceBlockchainID() ([32]byte, error) { + return _BlockHashReceiver.Contract.SourceBlockchainID(&_BlockHashReceiver.CallOpts) } -// SourceChainID is a free data retrieval call binding the contract method 0x4c335368. +// SourceBlockchainID is a free data retrieval call binding the contract method 0x29b7b3fd. // -// Solidity: function sourceChainID() view returns(bytes32) -func (_BlockHashReceiver *BlockHashReceiverCallerSession) SourceChainID() ([32]byte, error) { - return _BlockHashReceiver.Contract.SourceChainID(&_BlockHashReceiver.CallOpts) +// Solidity: function sourceBlockchainID() view returns(bytes32) +func (_BlockHashReceiver *BlockHashReceiverCallerSession) SourceBlockchainID() ([32]byte, error) { + return _BlockHashReceiver.Contract.SourceBlockchainID(&_BlockHashReceiver.CallOpts) } // SourcePublisherContractAddress is a free data retrieval call binding the contract method 0x79a0710c. @@ -431,23 +431,23 @@ func (_BlockHashReceiver *BlockHashReceiverCallerSession) TeleporterRegistry() ( // ReceiveTeleporterMessage is a paid mutator transaction binding the contract method 0xc868efaa. // -// Solidity: function receiveTeleporterMessage(bytes32 originChainID, address originSenderAddress, bytes message) returns() -func (_BlockHashReceiver *BlockHashReceiverTransactor) ReceiveTeleporterMessage(opts *bind.TransactOpts, originChainID [32]byte, originSenderAddress common.Address, message []byte) (*types.Transaction, error) { - return _BlockHashReceiver.contract.Transact(opts, "receiveTeleporterMessage", originChainID, originSenderAddress, message) +// Solidity: function receiveTeleporterMessage(bytes32 originBlockchainID, address originSenderAddress, bytes message) returns() +func (_BlockHashReceiver *BlockHashReceiverTransactor) ReceiveTeleporterMessage(opts *bind.TransactOpts, originBlockchainID [32]byte, originSenderAddress common.Address, message []byte) (*types.Transaction, error) { + return _BlockHashReceiver.contract.Transact(opts, "receiveTeleporterMessage", originBlockchainID, originSenderAddress, message) } // ReceiveTeleporterMessage is a paid mutator transaction binding the contract method 0xc868efaa. // -// Solidity: function receiveTeleporterMessage(bytes32 originChainID, address originSenderAddress, bytes message) returns() -func (_BlockHashReceiver *BlockHashReceiverSession) ReceiveTeleporterMessage(originChainID [32]byte, originSenderAddress common.Address, message []byte) (*types.Transaction, error) { - return _BlockHashReceiver.Contract.ReceiveTeleporterMessage(&_BlockHashReceiver.TransactOpts, originChainID, originSenderAddress, message) +// Solidity: function receiveTeleporterMessage(bytes32 originBlockchainID, address originSenderAddress, bytes message) returns() +func (_BlockHashReceiver *BlockHashReceiverSession) ReceiveTeleporterMessage(originBlockchainID [32]byte, originSenderAddress common.Address, message []byte) (*types.Transaction, error) { + return _BlockHashReceiver.Contract.ReceiveTeleporterMessage(&_BlockHashReceiver.TransactOpts, originBlockchainID, originSenderAddress, message) } // ReceiveTeleporterMessage is a paid mutator transaction binding the contract method 0xc868efaa. // -// Solidity: function receiveTeleporterMessage(bytes32 originChainID, address originSenderAddress, bytes message) returns() -func (_BlockHashReceiver *BlockHashReceiverTransactorSession) ReceiveTeleporterMessage(originChainID [32]byte, originSenderAddress common.Address, message []byte) (*types.Transaction, error) { - return _BlockHashReceiver.Contract.ReceiveTeleporterMessage(&_BlockHashReceiver.TransactOpts, originChainID, originSenderAddress, message) +// Solidity: function receiveTeleporterMessage(bytes32 originBlockchainID, address originSenderAddress, bytes message) returns() +func (_BlockHashReceiver *BlockHashReceiverTransactorSession) ReceiveTeleporterMessage(originBlockchainID [32]byte, originSenderAddress common.Address, message []byte) (*types.Transaction, error) { + return _BlockHashReceiver.Contract.ReceiveTeleporterMessage(&_BlockHashReceiver.TransactOpts, originBlockchainID, originSenderAddress, message) } // RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6. @@ -888,7 +888,7 @@ func (it *BlockHashReceiverReceiveBlockHashIterator) Close() error { // BlockHashReceiverReceiveBlockHash represents a ReceiveBlockHash event raised by the BlockHashReceiver contract. type BlockHashReceiverReceiveBlockHash struct { - OriginChainID [32]byte + OriginBlockchainID [32]byte OriginSenderAddress common.Address BlockHeight *big.Int BlockHash [32]byte @@ -897,12 +897,12 @@ type BlockHashReceiverReceiveBlockHash struct { // FilterReceiveBlockHash is a free log retrieval operation binding the contract event 0x0bca78aa82d7575f42e4b4b2fe04765a4b2f3661786403788ce987e065ac590d. // -// Solidity: event ReceiveBlockHash(bytes32 indexed originChainID, address indexed originSenderAddress, uint256 indexed blockHeight, bytes32 blockHash) -func (_BlockHashReceiver *BlockHashReceiverFilterer) FilterReceiveBlockHash(opts *bind.FilterOpts, originChainID [][32]byte, originSenderAddress []common.Address, blockHeight []*big.Int) (*BlockHashReceiverReceiveBlockHashIterator, error) { +// Solidity: event ReceiveBlockHash(bytes32 indexed originBlockchainID, address indexed originSenderAddress, uint256 indexed blockHeight, bytes32 blockHash) +func (_BlockHashReceiver *BlockHashReceiverFilterer) FilterReceiveBlockHash(opts *bind.FilterOpts, originBlockchainID [][32]byte, originSenderAddress []common.Address, blockHeight []*big.Int) (*BlockHashReceiverReceiveBlockHashIterator, error) { - var originChainIDRule []interface{} - for _, originChainIDItem := range originChainID { - originChainIDRule = append(originChainIDRule, originChainIDItem) + var originBlockchainIDRule []interface{} + for _, originBlockchainIDItem := range originBlockchainID { + originBlockchainIDRule = append(originBlockchainIDRule, originBlockchainIDItem) } var originSenderAddressRule []interface{} for _, originSenderAddressItem := range originSenderAddress { @@ -913,7 +913,7 @@ func (_BlockHashReceiver *BlockHashReceiverFilterer) FilterReceiveBlockHash(opts blockHeightRule = append(blockHeightRule, blockHeightItem) } - logs, sub, err := _BlockHashReceiver.contract.FilterLogs(opts, "ReceiveBlockHash", originChainIDRule, originSenderAddressRule, blockHeightRule) + logs, sub, err := _BlockHashReceiver.contract.FilterLogs(opts, "ReceiveBlockHash", originBlockchainIDRule, originSenderAddressRule, blockHeightRule) if err != nil { return nil, err } @@ -922,12 +922,12 @@ func (_BlockHashReceiver *BlockHashReceiverFilterer) FilterReceiveBlockHash(opts // WatchReceiveBlockHash is a free log subscription operation binding the contract event 0x0bca78aa82d7575f42e4b4b2fe04765a4b2f3661786403788ce987e065ac590d. // -// Solidity: event ReceiveBlockHash(bytes32 indexed originChainID, address indexed originSenderAddress, uint256 indexed blockHeight, bytes32 blockHash) -func (_BlockHashReceiver *BlockHashReceiverFilterer) WatchReceiveBlockHash(opts *bind.WatchOpts, sink chan<- *BlockHashReceiverReceiveBlockHash, originChainID [][32]byte, originSenderAddress []common.Address, blockHeight []*big.Int) (event.Subscription, error) { +// Solidity: event ReceiveBlockHash(bytes32 indexed originBlockchainID, address indexed originSenderAddress, uint256 indexed blockHeight, bytes32 blockHash) +func (_BlockHashReceiver *BlockHashReceiverFilterer) WatchReceiveBlockHash(opts *bind.WatchOpts, sink chan<- *BlockHashReceiverReceiveBlockHash, originBlockchainID [][32]byte, originSenderAddress []common.Address, blockHeight []*big.Int) (event.Subscription, error) { - var originChainIDRule []interface{} - for _, originChainIDItem := range originChainID { - originChainIDRule = append(originChainIDRule, originChainIDItem) + var originBlockchainIDRule []interface{} + for _, originBlockchainIDItem := range originBlockchainID { + originBlockchainIDRule = append(originBlockchainIDRule, originBlockchainIDItem) } var originSenderAddressRule []interface{} for _, originSenderAddressItem := range originSenderAddress { @@ -938,7 +938,7 @@ func (_BlockHashReceiver *BlockHashReceiverFilterer) WatchReceiveBlockHash(opts blockHeightRule = append(blockHeightRule, blockHeightItem) } - logs, sub, err := _BlockHashReceiver.contract.WatchLogs(opts, "ReceiveBlockHash", originChainIDRule, originSenderAddressRule, blockHeightRule) + logs, sub, err := _BlockHashReceiver.contract.WatchLogs(opts, "ReceiveBlockHash", originBlockchainIDRule, originSenderAddressRule, blockHeightRule) if err != nil { return nil, err } @@ -972,7 +972,7 @@ func (_BlockHashReceiver *BlockHashReceiverFilterer) WatchReceiveBlockHash(opts // ParseReceiveBlockHash is a log parse operation binding the contract event 0x0bca78aa82d7575f42e4b4b2fe04765a4b2f3661786403788ce987e065ac590d. // -// Solidity: event ReceiveBlockHash(bytes32 indexed originChainID, address indexed originSenderAddress, uint256 indexed blockHeight, bytes32 blockHash) +// Solidity: event ReceiveBlockHash(bytes32 indexed originBlockchainID, address indexed originSenderAddress, uint256 indexed blockHeight, bytes32 blockHash) func (_BlockHashReceiver *BlockHashReceiverFilterer) ParseReceiveBlockHash(log types.Log) (*BlockHashReceiverReceiveBlockHash, error) { event := new(BlockHashReceiverReceiveBlockHash) if err := _BlockHashReceiver.contract.UnpackLog(event, "ReceiveBlockHash", log); err != nil { diff --git a/abi-bindings/go/Teleporter/TeleporterMessenger/TeleporterMessenger.go b/abi-bindings/go/Teleporter/TeleporterMessenger/TeleporterMessenger.go index ab0c1327c..fe574f6de 100644 --- a/abi-bindings/go/Teleporter/TeleporterMessenger/TeleporterMessenger.go +++ b/abi-bindings/go/Teleporter/TeleporterMessenger/TeleporterMessenger.go @@ -39,7 +39,7 @@ type TeleporterFeeInfo struct { type TeleporterMessage struct { MessageID *big.Int SenderAddress common.Address - DestinationChainID [32]byte + DestinationBlockchainID [32]byte DestinationAddress common.Address RequiredGasLimit *big.Int AllowedRelayerAddresses []common.Address @@ -49,7 +49,7 @@ type TeleporterMessage struct { // TeleporterMessageInput is an auto generated low-level Go binding around an user-defined struct. type TeleporterMessageInput struct { - DestinationChainID [32]byte + DestinationBlockchainID [32]byte DestinationAddress common.Address FeeInfo TeleporterFeeInfo RequiredGasLimit *big.Int @@ -65,7 +65,7 @@ type TeleporterMessageReceipt struct { // TeleporterMessengerMetaData contains all meta data concerning the TeleporterMessenger contract. var TeleporterMessengerMetaData = &bind.MetaData{ - ABI: "[{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"feeTokenAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"indexed\":false,\"internalType\":\"structTeleporterFeeInfo\",\"name\":\"updatedFeeInfo\",\"type\":\"tuple\"}],\"name\":\"AddFeeAmount\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"originChainID\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"}],\"name\":\"MessageExecuted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"originChainID\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"senderAddress\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"requiredGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"address[]\",\"name\":\"allowedRelayerAddresses\",\"type\":\"address[]\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"receivedMessageID\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"relayerRewardAddress\",\"type\":\"address\"}],\"internalType\":\"structTeleporterMessageReceipt[]\",\"name\":\"receipts\",\"type\":\"tuple[]\"},{\"internalType\":\"bytes\",\"name\":\"message\",\"type\":\"bytes\"}],\"indexed\":false,\"internalType\":\"structTeleporterMessage\",\"name\":\"message\",\"type\":\"tuple\"}],\"name\":\"MessageExecutionFailed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"originChainID\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"deliverer\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"rewardRedeemer\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"senderAddress\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"requiredGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"address[]\",\"name\":\"allowedRelayerAddresses\",\"type\":\"address[]\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"receivedMessageID\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"relayerRewardAddress\",\"type\":\"address\"}],\"internalType\":\"structTeleporterMessageReceipt[]\",\"name\":\"receipts\",\"type\":\"tuple[]\"},{\"internalType\":\"bytes\",\"name\":\"message\",\"type\":\"bytes\"}],\"indexed\":false,\"internalType\":\"structTeleporterMessage\",\"name\":\"message\",\"type\":\"tuple\"}],\"name\":\"ReceiveCrossChainMessage\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"redeemer\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"asset\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"RelayerRewardsRedeemed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"senderAddress\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"requiredGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"address[]\",\"name\":\"allowedRelayerAddresses\",\"type\":\"address[]\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"receivedMessageID\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"relayerRewardAddress\",\"type\":\"address\"}],\"internalType\":\"structTeleporterMessageReceipt[]\",\"name\":\"receipts\",\"type\":\"tuple[]\"},{\"internalType\":\"bytes\",\"name\":\"message\",\"type\":\"bytes\"}],\"indexed\":false,\"internalType\":\"structTeleporterMessage\",\"name\":\"message\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"feeTokenAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"indexed\":false,\"internalType\":\"structTeleporterFeeInfo\",\"name\":\"feeInfo\",\"type\":\"tuple\"}],\"name\":\"SendCrossChainMessage\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"WARP_MESSENGER\",\"outputs\":[{\"internalType\":\"contractIWarpMessenger\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"feeTokenAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"additionalFeeAmount\",\"type\":\"uint256\"}],\"name\":\"addFeeAmount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"blockchainID\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"relayer\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"feeAsset\",\"type\":\"address\"}],\"name\":\"checkRelayerRewardAmount\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"}],\"name\":\"getFeeInfo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"}],\"name\":\"getMessageHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"chainID\",\"type\":\"bytes32\"}],\"name\":\"getNextMessageID\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"chainID\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"index\",\"type\":\"uint256\"}],\"name\":\"getReceiptAtIndex\",\"outputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"receivedMessageID\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"relayerRewardAddress\",\"type\":\"address\"}],\"internalType\":\"structTeleporterMessageReceipt\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"chainID\",\"type\":\"bytes32\"}],\"name\":\"getReceiptQueueSize\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"originChainID\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"}],\"name\":\"getRelayerRewardAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"}],\"name\":\"latestMessageIDs\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"originChainID\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"}],\"name\":\"messageReceived\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"sourceChainID\",\"type\":\"bytes32\"}],\"name\":\"receiptQueues\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"first\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"last\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"messageIndex\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"relayerRewardAddress\",\"type\":\"address\"}],\"name\":\"receiveCrossChainMessage\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"sourceChainID\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"}],\"name\":\"receivedFailedMessageHashes\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"messageHash\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"feeAsset\",\"type\":\"address\"}],\"name\":\"redeemRelayerRewards\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"originChainID\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"senderAddress\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"requiredGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"address[]\",\"name\":\"allowedRelayerAddresses\",\"type\":\"address[]\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"receivedMessageID\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"relayerRewardAddress\",\"type\":\"address\"}],\"internalType\":\"structTeleporterMessageReceipt[]\",\"name\":\"receipts\",\"type\":\"tuple[]\"},{\"internalType\":\"bytes\",\"name\":\"message\",\"type\":\"bytes\"}],\"internalType\":\"structTeleporterMessage\",\"name\":\"message\",\"type\":\"tuple\"}],\"name\":\"retryMessageExecution\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"senderAddress\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"requiredGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"address[]\",\"name\":\"allowedRelayerAddresses\",\"type\":\"address[]\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"receivedMessageID\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"relayerRewardAddress\",\"type\":\"address\"}],\"internalType\":\"structTeleporterMessageReceipt[]\",\"name\":\"receipts\",\"type\":\"tuple[]\"},{\"internalType\":\"bytes\",\"name\":\"message\",\"type\":\"bytes\"}],\"internalType\":\"structTeleporterMessage\",\"name\":\"message\",\"type\":\"tuple\"}],\"name\":\"retrySendCrossChainMessage\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationAddress\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"feeTokenAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"internalType\":\"structTeleporterFeeInfo\",\"name\":\"feeInfo\",\"type\":\"tuple\"},{\"internalType\":\"uint256\",\"name\":\"requiredGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"address[]\",\"name\":\"allowedRelayerAddresses\",\"type\":\"address[]\"},{\"internalType\":\"bytes\",\"name\":\"message\",\"type\":\"bytes\"}],\"internalType\":\"structTeleporterMessageInput\",\"name\":\"messageInput\",\"type\":\"tuple\"}],\"name\":\"sendCrossChainMessage\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"originChainID\",\"type\":\"bytes32\"},{\"internalType\":\"uint256[]\",\"name\":\"messageIDs\",\"type\":\"uint256[]\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"feeTokenAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"internalType\":\"structTeleporterFeeInfo\",\"name\":\"feeInfo\",\"type\":\"tuple\"},{\"internalType\":\"address[]\",\"name\":\"allowedRelayerAddresses\",\"type\":\"address[]\"}],\"name\":\"sendSpecifiedReceipts\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationChainID\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"}],\"name\":\"sentMessageInfo\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"messageHash\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"feeTokenAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"internalType\":\"structTeleporterFeeInfo\",\"name\":\"feeInfo\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", + ABI: "[{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"feeTokenAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"indexed\":false,\"internalType\":\"structTeleporterFeeInfo\",\"name\":\"updatedFeeInfo\",\"type\":\"tuple\"}],\"name\":\"AddFeeAmount\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"originBlockchainID\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"}],\"name\":\"MessageExecuted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"originBlockchainID\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"senderAddress\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"requiredGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"address[]\",\"name\":\"allowedRelayerAddresses\",\"type\":\"address[]\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"receivedMessageID\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"relayerRewardAddress\",\"type\":\"address\"}],\"internalType\":\"structTeleporterMessageReceipt[]\",\"name\":\"receipts\",\"type\":\"tuple[]\"},{\"internalType\":\"bytes\",\"name\":\"message\",\"type\":\"bytes\"}],\"indexed\":false,\"internalType\":\"structTeleporterMessage\",\"name\":\"message\",\"type\":\"tuple\"}],\"name\":\"MessageExecutionFailed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"originBlockchainID\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"deliverer\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"rewardRedeemer\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"senderAddress\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"requiredGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"address[]\",\"name\":\"allowedRelayerAddresses\",\"type\":\"address[]\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"receivedMessageID\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"relayerRewardAddress\",\"type\":\"address\"}],\"internalType\":\"structTeleporterMessageReceipt[]\",\"name\":\"receipts\",\"type\":\"tuple[]\"},{\"internalType\":\"bytes\",\"name\":\"message\",\"type\":\"bytes\"}],\"indexed\":false,\"internalType\":\"structTeleporterMessage\",\"name\":\"message\",\"type\":\"tuple\"}],\"name\":\"ReceiveCrossChainMessage\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"redeemer\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"asset\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"RelayerRewardsRedeemed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"senderAddress\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"requiredGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"address[]\",\"name\":\"allowedRelayerAddresses\",\"type\":\"address[]\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"receivedMessageID\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"relayerRewardAddress\",\"type\":\"address\"}],\"internalType\":\"structTeleporterMessageReceipt[]\",\"name\":\"receipts\",\"type\":\"tuple[]\"},{\"internalType\":\"bytes\",\"name\":\"message\",\"type\":\"bytes\"}],\"indexed\":false,\"internalType\":\"structTeleporterMessage\",\"name\":\"message\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"feeTokenAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"indexed\":false,\"internalType\":\"structTeleporterFeeInfo\",\"name\":\"feeInfo\",\"type\":\"tuple\"}],\"name\":\"SendCrossChainMessage\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"WARP_MESSENGER\",\"outputs\":[{\"internalType\":\"contractIWarpMessenger\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"feeTokenAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"additionalFeeAmount\",\"type\":\"uint256\"}],\"name\":\"addFeeAmount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"blockchainID\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"relayer\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"feeAsset\",\"type\":\"address\"}],\"name\":\"checkRelayerRewardAmount\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"}],\"name\":\"getFeeInfo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"}],\"name\":\"getMessageHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"}],\"name\":\"getNextMessageID\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"originBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"index\",\"type\":\"uint256\"}],\"name\":\"getReceiptAtIndex\",\"outputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"receivedMessageID\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"relayerRewardAddress\",\"type\":\"address\"}],\"internalType\":\"structTeleporterMessageReceipt\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"originBlockchainID\",\"type\":\"bytes32\"}],\"name\":\"getReceiptQueueSize\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"originBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"}],\"name\":\"getRelayerRewardAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"}],\"name\":\"latestMessageIDs\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"originBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"}],\"name\":\"messageReceived\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"sourceBlockchainID\",\"type\":\"bytes32\"}],\"name\":\"receiptQueues\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"first\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"last\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"messageIndex\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"relayerRewardAddress\",\"type\":\"address\"}],\"name\":\"receiveCrossChainMessage\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"sourceBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"}],\"name\":\"receivedFailedMessageHashes\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"messageHash\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"feeAsset\",\"type\":\"address\"}],\"name\":\"redeemRelayerRewards\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"originBlockchainID\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"senderAddress\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"requiredGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"address[]\",\"name\":\"allowedRelayerAddresses\",\"type\":\"address[]\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"receivedMessageID\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"relayerRewardAddress\",\"type\":\"address\"}],\"internalType\":\"structTeleporterMessageReceipt[]\",\"name\":\"receipts\",\"type\":\"tuple[]\"},{\"internalType\":\"bytes\",\"name\":\"message\",\"type\":\"bytes\"}],\"internalType\":\"structTeleporterMessage\",\"name\":\"message\",\"type\":\"tuple\"}],\"name\":\"retryMessageExecution\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"senderAddress\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"requiredGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"address[]\",\"name\":\"allowedRelayerAddresses\",\"type\":\"address[]\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"receivedMessageID\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"relayerRewardAddress\",\"type\":\"address\"}],\"internalType\":\"structTeleporterMessageReceipt[]\",\"name\":\"receipts\",\"type\":\"tuple[]\"},{\"internalType\":\"bytes\",\"name\":\"message\",\"type\":\"bytes\"}],\"internalType\":\"structTeleporterMessage\",\"name\":\"message\",\"type\":\"tuple\"}],\"name\":\"retrySendCrossChainMessage\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"destinationAddress\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"feeTokenAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"internalType\":\"structTeleporterFeeInfo\",\"name\":\"feeInfo\",\"type\":\"tuple\"},{\"internalType\":\"uint256\",\"name\":\"requiredGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"address[]\",\"name\":\"allowedRelayerAddresses\",\"type\":\"address[]\"},{\"internalType\":\"bytes\",\"name\":\"message\",\"type\":\"bytes\"}],\"internalType\":\"structTeleporterMessageInput\",\"name\":\"messageInput\",\"type\":\"tuple\"}],\"name\":\"sendCrossChainMessage\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"originBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"uint256[]\",\"name\":\"messageIDs\",\"type\":\"uint256[]\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"feeTokenAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"internalType\":\"structTeleporterFeeInfo\",\"name\":\"feeInfo\",\"type\":\"tuple\"},{\"internalType\":\"address[]\",\"name\":\"allowedRelayerAddresses\",\"type\":\"address[]\"}],\"name\":\"sendSpecifiedReceipts\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"destinationBlockchainID\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"messageID\",\"type\":\"uint256\"}],\"name\":\"sentMessageInfo\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"messageHash\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"feeTokenAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"internalType\":\"structTeleporterFeeInfo\",\"name\":\"feeInfo\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", } // TeleporterMessengerABI is the input ABI used to generate the binding from. @@ -309,10 +309,10 @@ func (_TeleporterMessenger *TeleporterMessengerCallerSession) CheckRelayerReward // GetFeeInfo is a free data retrieval call binding the contract method 0x82f2c43a. // -// Solidity: function getFeeInfo(bytes32 destinationChainID, uint256 messageID) view returns(address, uint256) -func (_TeleporterMessenger *TeleporterMessengerCaller) GetFeeInfo(opts *bind.CallOpts, destinationChainID [32]byte, messageID *big.Int) (common.Address, *big.Int, error) { +// Solidity: function getFeeInfo(bytes32 destinationBlockchainID, uint256 messageID) view returns(address, uint256) +func (_TeleporterMessenger *TeleporterMessengerCaller) GetFeeInfo(opts *bind.CallOpts, destinationBlockchainID [32]byte, messageID *big.Int) (common.Address, *big.Int, error) { var out []interface{} - err := _TeleporterMessenger.contract.Call(opts, &out, "getFeeInfo", destinationChainID, messageID) + err := _TeleporterMessenger.contract.Call(opts, &out, "getFeeInfo", destinationBlockchainID, messageID) if err != nil { return *new(common.Address), *new(*big.Int), err @@ -327,24 +327,24 @@ func (_TeleporterMessenger *TeleporterMessengerCaller) GetFeeInfo(opts *bind.Cal // GetFeeInfo is a free data retrieval call binding the contract method 0x82f2c43a. // -// Solidity: function getFeeInfo(bytes32 destinationChainID, uint256 messageID) view returns(address, uint256) -func (_TeleporterMessenger *TeleporterMessengerSession) GetFeeInfo(destinationChainID [32]byte, messageID *big.Int) (common.Address, *big.Int, error) { - return _TeleporterMessenger.Contract.GetFeeInfo(&_TeleporterMessenger.CallOpts, destinationChainID, messageID) +// Solidity: function getFeeInfo(bytes32 destinationBlockchainID, uint256 messageID) view returns(address, uint256) +func (_TeleporterMessenger *TeleporterMessengerSession) GetFeeInfo(destinationBlockchainID [32]byte, messageID *big.Int) (common.Address, *big.Int, error) { + return _TeleporterMessenger.Contract.GetFeeInfo(&_TeleporterMessenger.CallOpts, destinationBlockchainID, messageID) } // GetFeeInfo is a free data retrieval call binding the contract method 0x82f2c43a. // -// Solidity: function getFeeInfo(bytes32 destinationChainID, uint256 messageID) view returns(address, uint256) -func (_TeleporterMessenger *TeleporterMessengerCallerSession) GetFeeInfo(destinationChainID [32]byte, messageID *big.Int) (common.Address, *big.Int, error) { - return _TeleporterMessenger.Contract.GetFeeInfo(&_TeleporterMessenger.CallOpts, destinationChainID, messageID) +// Solidity: function getFeeInfo(bytes32 destinationBlockchainID, uint256 messageID) view returns(address, uint256) +func (_TeleporterMessenger *TeleporterMessengerCallerSession) GetFeeInfo(destinationBlockchainID [32]byte, messageID *big.Int) (common.Address, *big.Int, error) { + return _TeleporterMessenger.Contract.GetFeeInfo(&_TeleporterMessenger.CallOpts, destinationBlockchainID, messageID) } // GetMessageHash is a free data retrieval call binding the contract method 0x220c9568. // -// Solidity: function getMessageHash(bytes32 destinationChainID, uint256 messageID) view returns(bytes32) -func (_TeleporterMessenger *TeleporterMessengerCaller) GetMessageHash(opts *bind.CallOpts, destinationChainID [32]byte, messageID *big.Int) ([32]byte, error) { +// Solidity: function getMessageHash(bytes32 destinationBlockchainID, uint256 messageID) view returns(bytes32) +func (_TeleporterMessenger *TeleporterMessengerCaller) GetMessageHash(opts *bind.CallOpts, destinationBlockchainID [32]byte, messageID *big.Int) ([32]byte, error) { var out []interface{} - err := _TeleporterMessenger.contract.Call(opts, &out, "getMessageHash", destinationChainID, messageID) + err := _TeleporterMessenger.contract.Call(opts, &out, "getMessageHash", destinationBlockchainID, messageID) if err != nil { return *new([32]byte), err @@ -358,24 +358,24 @@ func (_TeleporterMessenger *TeleporterMessengerCaller) GetMessageHash(opts *bind // GetMessageHash is a free data retrieval call binding the contract method 0x220c9568. // -// Solidity: function getMessageHash(bytes32 destinationChainID, uint256 messageID) view returns(bytes32) -func (_TeleporterMessenger *TeleporterMessengerSession) GetMessageHash(destinationChainID [32]byte, messageID *big.Int) ([32]byte, error) { - return _TeleporterMessenger.Contract.GetMessageHash(&_TeleporterMessenger.CallOpts, destinationChainID, messageID) +// Solidity: function getMessageHash(bytes32 destinationBlockchainID, uint256 messageID) view returns(bytes32) +func (_TeleporterMessenger *TeleporterMessengerSession) GetMessageHash(destinationBlockchainID [32]byte, messageID *big.Int) ([32]byte, error) { + return _TeleporterMessenger.Contract.GetMessageHash(&_TeleporterMessenger.CallOpts, destinationBlockchainID, messageID) } // GetMessageHash is a free data retrieval call binding the contract method 0x220c9568. // -// Solidity: function getMessageHash(bytes32 destinationChainID, uint256 messageID) view returns(bytes32) -func (_TeleporterMessenger *TeleporterMessengerCallerSession) GetMessageHash(destinationChainID [32]byte, messageID *big.Int) ([32]byte, error) { - return _TeleporterMessenger.Contract.GetMessageHash(&_TeleporterMessenger.CallOpts, destinationChainID, messageID) +// Solidity: function getMessageHash(bytes32 destinationBlockchainID, uint256 messageID) view returns(bytes32) +func (_TeleporterMessenger *TeleporterMessengerCallerSession) GetMessageHash(destinationBlockchainID [32]byte, messageID *big.Int) ([32]byte, error) { + return _TeleporterMessenger.Contract.GetMessageHash(&_TeleporterMessenger.CallOpts, destinationBlockchainID, messageID) } // GetNextMessageID is a free data retrieval call binding the contract method 0xdf20e8bc. // -// Solidity: function getNextMessageID(bytes32 chainID) view returns(uint256) -func (_TeleporterMessenger *TeleporterMessengerCaller) GetNextMessageID(opts *bind.CallOpts, chainID [32]byte) (*big.Int, error) { +// Solidity: function getNextMessageID(bytes32 destinationBlockchainID) view returns(uint256) +func (_TeleporterMessenger *TeleporterMessengerCaller) GetNextMessageID(opts *bind.CallOpts, destinationBlockchainID [32]byte) (*big.Int, error) { var out []interface{} - err := _TeleporterMessenger.contract.Call(opts, &out, "getNextMessageID", chainID) + err := _TeleporterMessenger.contract.Call(opts, &out, "getNextMessageID", destinationBlockchainID) if err != nil { return *new(*big.Int), err @@ -389,24 +389,24 @@ func (_TeleporterMessenger *TeleporterMessengerCaller) GetNextMessageID(opts *bi // GetNextMessageID is a free data retrieval call binding the contract method 0xdf20e8bc. // -// Solidity: function getNextMessageID(bytes32 chainID) view returns(uint256) -func (_TeleporterMessenger *TeleporterMessengerSession) GetNextMessageID(chainID [32]byte) (*big.Int, error) { - return _TeleporterMessenger.Contract.GetNextMessageID(&_TeleporterMessenger.CallOpts, chainID) +// Solidity: function getNextMessageID(bytes32 destinationBlockchainID) view returns(uint256) +func (_TeleporterMessenger *TeleporterMessengerSession) GetNextMessageID(destinationBlockchainID [32]byte) (*big.Int, error) { + return _TeleporterMessenger.Contract.GetNextMessageID(&_TeleporterMessenger.CallOpts, destinationBlockchainID) } // GetNextMessageID is a free data retrieval call binding the contract method 0xdf20e8bc. // -// Solidity: function getNextMessageID(bytes32 chainID) view returns(uint256) -func (_TeleporterMessenger *TeleporterMessengerCallerSession) GetNextMessageID(chainID [32]byte) (*big.Int, error) { - return _TeleporterMessenger.Contract.GetNextMessageID(&_TeleporterMessenger.CallOpts, chainID) +// Solidity: function getNextMessageID(bytes32 destinationBlockchainID) view returns(uint256) +func (_TeleporterMessenger *TeleporterMessengerCallerSession) GetNextMessageID(destinationBlockchainID [32]byte) (*big.Int, error) { + return _TeleporterMessenger.Contract.GetNextMessageID(&_TeleporterMessenger.CallOpts, destinationBlockchainID) } // GetReceiptAtIndex is a free data retrieval call binding the contract method 0x892bf412. // -// Solidity: function getReceiptAtIndex(bytes32 chainID, uint256 index) view returns((uint256,address)) -func (_TeleporterMessenger *TeleporterMessengerCaller) GetReceiptAtIndex(opts *bind.CallOpts, chainID [32]byte, index *big.Int) (TeleporterMessageReceipt, error) { +// Solidity: function getReceiptAtIndex(bytes32 originBlockchainID, uint256 index) view returns((uint256,address)) +func (_TeleporterMessenger *TeleporterMessengerCaller) GetReceiptAtIndex(opts *bind.CallOpts, originBlockchainID [32]byte, index *big.Int) (TeleporterMessageReceipt, error) { var out []interface{} - err := _TeleporterMessenger.contract.Call(opts, &out, "getReceiptAtIndex", chainID, index) + err := _TeleporterMessenger.contract.Call(opts, &out, "getReceiptAtIndex", originBlockchainID, index) if err != nil { return *new(TeleporterMessageReceipt), err @@ -420,24 +420,24 @@ func (_TeleporterMessenger *TeleporterMessengerCaller) GetReceiptAtIndex(opts *b // GetReceiptAtIndex is a free data retrieval call binding the contract method 0x892bf412. // -// Solidity: function getReceiptAtIndex(bytes32 chainID, uint256 index) view returns((uint256,address)) -func (_TeleporterMessenger *TeleporterMessengerSession) GetReceiptAtIndex(chainID [32]byte, index *big.Int) (TeleporterMessageReceipt, error) { - return _TeleporterMessenger.Contract.GetReceiptAtIndex(&_TeleporterMessenger.CallOpts, chainID, index) +// Solidity: function getReceiptAtIndex(bytes32 originBlockchainID, uint256 index) view returns((uint256,address)) +func (_TeleporterMessenger *TeleporterMessengerSession) GetReceiptAtIndex(originBlockchainID [32]byte, index *big.Int) (TeleporterMessageReceipt, error) { + return _TeleporterMessenger.Contract.GetReceiptAtIndex(&_TeleporterMessenger.CallOpts, originBlockchainID, index) } // GetReceiptAtIndex is a free data retrieval call binding the contract method 0x892bf412. // -// Solidity: function getReceiptAtIndex(bytes32 chainID, uint256 index) view returns((uint256,address)) -func (_TeleporterMessenger *TeleporterMessengerCallerSession) GetReceiptAtIndex(chainID [32]byte, index *big.Int) (TeleporterMessageReceipt, error) { - return _TeleporterMessenger.Contract.GetReceiptAtIndex(&_TeleporterMessenger.CallOpts, chainID, index) +// Solidity: function getReceiptAtIndex(bytes32 originBlockchainID, uint256 index) view returns((uint256,address)) +func (_TeleporterMessenger *TeleporterMessengerCallerSession) GetReceiptAtIndex(originBlockchainID [32]byte, index *big.Int) (TeleporterMessageReceipt, error) { + return _TeleporterMessenger.Contract.GetReceiptAtIndex(&_TeleporterMessenger.CallOpts, originBlockchainID, index) } // GetReceiptQueueSize is a free data retrieval call binding the contract method 0x2bc8b0bf. // -// Solidity: function getReceiptQueueSize(bytes32 chainID) view returns(uint256) -func (_TeleporterMessenger *TeleporterMessengerCaller) GetReceiptQueueSize(opts *bind.CallOpts, chainID [32]byte) (*big.Int, error) { +// Solidity: function getReceiptQueueSize(bytes32 originBlockchainID) view returns(uint256) +func (_TeleporterMessenger *TeleporterMessengerCaller) GetReceiptQueueSize(opts *bind.CallOpts, originBlockchainID [32]byte) (*big.Int, error) { var out []interface{} - err := _TeleporterMessenger.contract.Call(opts, &out, "getReceiptQueueSize", chainID) + err := _TeleporterMessenger.contract.Call(opts, &out, "getReceiptQueueSize", originBlockchainID) if err != nil { return *new(*big.Int), err @@ -451,24 +451,24 @@ func (_TeleporterMessenger *TeleporterMessengerCaller) GetReceiptQueueSize(opts // GetReceiptQueueSize is a free data retrieval call binding the contract method 0x2bc8b0bf. // -// Solidity: function getReceiptQueueSize(bytes32 chainID) view returns(uint256) -func (_TeleporterMessenger *TeleporterMessengerSession) GetReceiptQueueSize(chainID [32]byte) (*big.Int, error) { - return _TeleporterMessenger.Contract.GetReceiptQueueSize(&_TeleporterMessenger.CallOpts, chainID) +// Solidity: function getReceiptQueueSize(bytes32 originBlockchainID) view returns(uint256) +func (_TeleporterMessenger *TeleporterMessengerSession) GetReceiptQueueSize(originBlockchainID [32]byte) (*big.Int, error) { + return _TeleporterMessenger.Contract.GetReceiptQueueSize(&_TeleporterMessenger.CallOpts, originBlockchainID) } // GetReceiptQueueSize is a free data retrieval call binding the contract method 0x2bc8b0bf. // -// Solidity: function getReceiptQueueSize(bytes32 chainID) view returns(uint256) -func (_TeleporterMessenger *TeleporterMessengerCallerSession) GetReceiptQueueSize(chainID [32]byte) (*big.Int, error) { - return _TeleporterMessenger.Contract.GetReceiptQueueSize(&_TeleporterMessenger.CallOpts, chainID) +// Solidity: function getReceiptQueueSize(bytes32 originBlockchainID) view returns(uint256) +func (_TeleporterMessenger *TeleporterMessengerCallerSession) GetReceiptQueueSize(originBlockchainID [32]byte) (*big.Int, error) { + return _TeleporterMessenger.Contract.GetReceiptQueueSize(&_TeleporterMessenger.CallOpts, originBlockchainID) } // GetRelayerRewardAddress is a free data retrieval call binding the contract method 0x33e890fe. // -// Solidity: function getRelayerRewardAddress(bytes32 originChainID, uint256 messageID) view returns(address) -func (_TeleporterMessenger *TeleporterMessengerCaller) GetRelayerRewardAddress(opts *bind.CallOpts, originChainID [32]byte, messageID *big.Int) (common.Address, error) { +// Solidity: function getRelayerRewardAddress(bytes32 originBlockchainID, uint256 messageID) view returns(address) +func (_TeleporterMessenger *TeleporterMessengerCaller) GetRelayerRewardAddress(opts *bind.CallOpts, originBlockchainID [32]byte, messageID *big.Int) (common.Address, error) { var out []interface{} - err := _TeleporterMessenger.contract.Call(opts, &out, "getRelayerRewardAddress", originChainID, messageID) + err := _TeleporterMessenger.contract.Call(opts, &out, "getRelayerRewardAddress", originBlockchainID, messageID) if err != nil { return *new(common.Address), err @@ -482,24 +482,24 @@ func (_TeleporterMessenger *TeleporterMessengerCaller) GetRelayerRewardAddress(o // GetRelayerRewardAddress is a free data retrieval call binding the contract method 0x33e890fe. // -// Solidity: function getRelayerRewardAddress(bytes32 originChainID, uint256 messageID) view returns(address) -func (_TeleporterMessenger *TeleporterMessengerSession) GetRelayerRewardAddress(originChainID [32]byte, messageID *big.Int) (common.Address, error) { - return _TeleporterMessenger.Contract.GetRelayerRewardAddress(&_TeleporterMessenger.CallOpts, originChainID, messageID) +// Solidity: function getRelayerRewardAddress(bytes32 originBlockchainID, uint256 messageID) view returns(address) +func (_TeleporterMessenger *TeleporterMessengerSession) GetRelayerRewardAddress(originBlockchainID [32]byte, messageID *big.Int) (common.Address, error) { + return _TeleporterMessenger.Contract.GetRelayerRewardAddress(&_TeleporterMessenger.CallOpts, originBlockchainID, messageID) } // GetRelayerRewardAddress is a free data retrieval call binding the contract method 0x33e890fe. // -// Solidity: function getRelayerRewardAddress(bytes32 originChainID, uint256 messageID) view returns(address) -func (_TeleporterMessenger *TeleporterMessengerCallerSession) GetRelayerRewardAddress(originChainID [32]byte, messageID *big.Int) (common.Address, error) { - return _TeleporterMessenger.Contract.GetRelayerRewardAddress(&_TeleporterMessenger.CallOpts, originChainID, messageID) +// Solidity: function getRelayerRewardAddress(bytes32 originBlockchainID, uint256 messageID) view returns(address) +func (_TeleporterMessenger *TeleporterMessengerCallerSession) GetRelayerRewardAddress(originBlockchainID [32]byte, messageID *big.Int) (common.Address, error) { + return _TeleporterMessenger.Contract.GetRelayerRewardAddress(&_TeleporterMessenger.CallOpts, originBlockchainID, messageID) } // LatestMessageIDs is a free data retrieval call binding the contract method 0x29ec9beb. // -// Solidity: function latestMessageIDs(bytes32 destinationChainID) view returns(uint256 messageID) -func (_TeleporterMessenger *TeleporterMessengerCaller) LatestMessageIDs(opts *bind.CallOpts, destinationChainID [32]byte) (*big.Int, error) { +// Solidity: function latestMessageIDs(bytes32 destinationBlockchainID) view returns(uint256 messageID) +func (_TeleporterMessenger *TeleporterMessengerCaller) LatestMessageIDs(opts *bind.CallOpts, destinationBlockchainID [32]byte) (*big.Int, error) { var out []interface{} - err := _TeleporterMessenger.contract.Call(opts, &out, "latestMessageIDs", destinationChainID) + err := _TeleporterMessenger.contract.Call(opts, &out, "latestMessageIDs", destinationBlockchainID) if err != nil { return *new(*big.Int), err @@ -513,24 +513,24 @@ func (_TeleporterMessenger *TeleporterMessengerCaller) LatestMessageIDs(opts *bi // LatestMessageIDs is a free data retrieval call binding the contract method 0x29ec9beb. // -// Solidity: function latestMessageIDs(bytes32 destinationChainID) view returns(uint256 messageID) -func (_TeleporterMessenger *TeleporterMessengerSession) LatestMessageIDs(destinationChainID [32]byte) (*big.Int, error) { - return _TeleporterMessenger.Contract.LatestMessageIDs(&_TeleporterMessenger.CallOpts, destinationChainID) +// Solidity: function latestMessageIDs(bytes32 destinationBlockchainID) view returns(uint256 messageID) +func (_TeleporterMessenger *TeleporterMessengerSession) LatestMessageIDs(destinationBlockchainID [32]byte) (*big.Int, error) { + return _TeleporterMessenger.Contract.LatestMessageIDs(&_TeleporterMessenger.CallOpts, destinationBlockchainID) } // LatestMessageIDs is a free data retrieval call binding the contract method 0x29ec9beb. // -// Solidity: function latestMessageIDs(bytes32 destinationChainID) view returns(uint256 messageID) -func (_TeleporterMessenger *TeleporterMessengerCallerSession) LatestMessageIDs(destinationChainID [32]byte) (*big.Int, error) { - return _TeleporterMessenger.Contract.LatestMessageIDs(&_TeleporterMessenger.CallOpts, destinationChainID) +// Solidity: function latestMessageIDs(bytes32 destinationBlockchainID) view returns(uint256 messageID) +func (_TeleporterMessenger *TeleporterMessengerCallerSession) LatestMessageIDs(destinationBlockchainID [32]byte) (*big.Int, error) { + return _TeleporterMessenger.Contract.LatestMessageIDs(&_TeleporterMessenger.CallOpts, destinationBlockchainID) } // MessageReceived is a free data retrieval call binding the contract method 0xe03555df. // -// Solidity: function messageReceived(bytes32 originChainID, uint256 messageID) view returns(bool) -func (_TeleporterMessenger *TeleporterMessengerCaller) MessageReceived(opts *bind.CallOpts, originChainID [32]byte, messageID *big.Int) (bool, error) { +// Solidity: function messageReceived(bytes32 originBlockchainID, uint256 messageID) view returns(bool) +func (_TeleporterMessenger *TeleporterMessengerCaller) MessageReceived(opts *bind.CallOpts, originBlockchainID [32]byte, messageID *big.Int) (bool, error) { var out []interface{} - err := _TeleporterMessenger.contract.Call(opts, &out, "messageReceived", originChainID, messageID) + err := _TeleporterMessenger.contract.Call(opts, &out, "messageReceived", originBlockchainID, messageID) if err != nil { return *new(bool), err @@ -544,27 +544,27 @@ func (_TeleporterMessenger *TeleporterMessengerCaller) MessageReceived(opts *bin // MessageReceived is a free data retrieval call binding the contract method 0xe03555df. // -// Solidity: function messageReceived(bytes32 originChainID, uint256 messageID) view returns(bool) -func (_TeleporterMessenger *TeleporterMessengerSession) MessageReceived(originChainID [32]byte, messageID *big.Int) (bool, error) { - return _TeleporterMessenger.Contract.MessageReceived(&_TeleporterMessenger.CallOpts, originChainID, messageID) +// Solidity: function messageReceived(bytes32 originBlockchainID, uint256 messageID) view returns(bool) +func (_TeleporterMessenger *TeleporterMessengerSession) MessageReceived(originBlockchainID [32]byte, messageID *big.Int) (bool, error) { + return _TeleporterMessenger.Contract.MessageReceived(&_TeleporterMessenger.CallOpts, originBlockchainID, messageID) } // MessageReceived is a free data retrieval call binding the contract method 0xe03555df. // -// Solidity: function messageReceived(bytes32 originChainID, uint256 messageID) view returns(bool) -func (_TeleporterMessenger *TeleporterMessengerCallerSession) MessageReceived(originChainID [32]byte, messageID *big.Int) (bool, error) { - return _TeleporterMessenger.Contract.MessageReceived(&_TeleporterMessenger.CallOpts, originChainID, messageID) +// Solidity: function messageReceived(bytes32 originBlockchainID, uint256 messageID) view returns(bool) +func (_TeleporterMessenger *TeleporterMessengerCallerSession) MessageReceived(originBlockchainID [32]byte, messageID *big.Int) (bool, error) { + return _TeleporterMessenger.Contract.MessageReceived(&_TeleporterMessenger.CallOpts, originBlockchainID, messageID) } // ReceiptQueues is a free data retrieval call binding the contract method 0xe6e67bd5. // -// Solidity: function receiptQueues(bytes32 sourceChainID) view returns(uint256 first, uint256 last) -func (_TeleporterMessenger *TeleporterMessengerCaller) ReceiptQueues(opts *bind.CallOpts, sourceChainID [32]byte) (struct { +// Solidity: function receiptQueues(bytes32 sourceBlockchainID) view returns(uint256 first, uint256 last) +func (_TeleporterMessenger *TeleporterMessengerCaller) ReceiptQueues(opts *bind.CallOpts, sourceBlockchainID [32]byte) (struct { First *big.Int Last *big.Int }, error) { var out []interface{} - err := _TeleporterMessenger.contract.Call(opts, &out, "receiptQueues", sourceChainID) + err := _TeleporterMessenger.contract.Call(opts, &out, "receiptQueues", sourceBlockchainID) outstruct := new(struct { First *big.Int @@ -583,30 +583,30 @@ func (_TeleporterMessenger *TeleporterMessengerCaller) ReceiptQueues(opts *bind. // ReceiptQueues is a free data retrieval call binding the contract method 0xe6e67bd5. // -// Solidity: function receiptQueues(bytes32 sourceChainID) view returns(uint256 first, uint256 last) -func (_TeleporterMessenger *TeleporterMessengerSession) ReceiptQueues(sourceChainID [32]byte) (struct { +// Solidity: function receiptQueues(bytes32 sourceBlockchainID) view returns(uint256 first, uint256 last) +func (_TeleporterMessenger *TeleporterMessengerSession) ReceiptQueues(sourceBlockchainID [32]byte) (struct { First *big.Int Last *big.Int }, error) { - return _TeleporterMessenger.Contract.ReceiptQueues(&_TeleporterMessenger.CallOpts, sourceChainID) + return _TeleporterMessenger.Contract.ReceiptQueues(&_TeleporterMessenger.CallOpts, sourceBlockchainID) } // ReceiptQueues is a free data retrieval call binding the contract method 0xe6e67bd5. // -// Solidity: function receiptQueues(bytes32 sourceChainID) view returns(uint256 first, uint256 last) -func (_TeleporterMessenger *TeleporterMessengerCallerSession) ReceiptQueues(sourceChainID [32]byte) (struct { +// Solidity: function receiptQueues(bytes32 sourceBlockchainID) view returns(uint256 first, uint256 last) +func (_TeleporterMessenger *TeleporterMessengerCallerSession) ReceiptQueues(sourceBlockchainID [32]byte) (struct { First *big.Int Last *big.Int }, error) { - return _TeleporterMessenger.Contract.ReceiptQueues(&_TeleporterMessenger.CallOpts, sourceChainID) + return _TeleporterMessenger.Contract.ReceiptQueues(&_TeleporterMessenger.CallOpts, sourceBlockchainID) } // ReceivedFailedMessageHashes is a free data retrieval call binding the contract method 0xc9bb1143. // -// Solidity: function receivedFailedMessageHashes(bytes32 sourceChainID, uint256 messageID) view returns(bytes32 messageHash) -func (_TeleporterMessenger *TeleporterMessengerCaller) ReceivedFailedMessageHashes(opts *bind.CallOpts, sourceChainID [32]byte, messageID *big.Int) ([32]byte, error) { +// Solidity: function receivedFailedMessageHashes(bytes32 sourceBlockchainID, uint256 messageID) view returns(bytes32 messageHash) +func (_TeleporterMessenger *TeleporterMessengerCaller) ReceivedFailedMessageHashes(opts *bind.CallOpts, sourceBlockchainID [32]byte, messageID *big.Int) ([32]byte, error) { var out []interface{} - err := _TeleporterMessenger.contract.Call(opts, &out, "receivedFailedMessageHashes", sourceChainID, messageID) + err := _TeleporterMessenger.contract.Call(opts, &out, "receivedFailedMessageHashes", sourceBlockchainID, messageID) if err != nil { return *new([32]byte), err @@ -620,27 +620,27 @@ func (_TeleporterMessenger *TeleporterMessengerCaller) ReceivedFailedMessageHash // ReceivedFailedMessageHashes is a free data retrieval call binding the contract method 0xc9bb1143. // -// Solidity: function receivedFailedMessageHashes(bytes32 sourceChainID, uint256 messageID) view returns(bytes32 messageHash) -func (_TeleporterMessenger *TeleporterMessengerSession) ReceivedFailedMessageHashes(sourceChainID [32]byte, messageID *big.Int) ([32]byte, error) { - return _TeleporterMessenger.Contract.ReceivedFailedMessageHashes(&_TeleporterMessenger.CallOpts, sourceChainID, messageID) +// Solidity: function receivedFailedMessageHashes(bytes32 sourceBlockchainID, uint256 messageID) view returns(bytes32 messageHash) +func (_TeleporterMessenger *TeleporterMessengerSession) ReceivedFailedMessageHashes(sourceBlockchainID [32]byte, messageID *big.Int) ([32]byte, error) { + return _TeleporterMessenger.Contract.ReceivedFailedMessageHashes(&_TeleporterMessenger.CallOpts, sourceBlockchainID, messageID) } // ReceivedFailedMessageHashes is a free data retrieval call binding the contract method 0xc9bb1143. // -// Solidity: function receivedFailedMessageHashes(bytes32 sourceChainID, uint256 messageID) view returns(bytes32 messageHash) -func (_TeleporterMessenger *TeleporterMessengerCallerSession) ReceivedFailedMessageHashes(sourceChainID [32]byte, messageID *big.Int) ([32]byte, error) { - return _TeleporterMessenger.Contract.ReceivedFailedMessageHashes(&_TeleporterMessenger.CallOpts, sourceChainID, messageID) +// Solidity: function receivedFailedMessageHashes(bytes32 sourceBlockchainID, uint256 messageID) view returns(bytes32 messageHash) +func (_TeleporterMessenger *TeleporterMessengerCallerSession) ReceivedFailedMessageHashes(sourceBlockchainID [32]byte, messageID *big.Int) ([32]byte, error) { + return _TeleporterMessenger.Contract.ReceivedFailedMessageHashes(&_TeleporterMessenger.CallOpts, sourceBlockchainID, messageID) } // SentMessageInfo is a free data retrieval call binding the contract method 0x66533d12. // -// Solidity: function sentMessageInfo(bytes32 destinationChainID, uint256 messageID) view returns(bytes32 messageHash, (address,uint256) feeInfo) -func (_TeleporterMessenger *TeleporterMessengerCaller) SentMessageInfo(opts *bind.CallOpts, destinationChainID [32]byte, messageID *big.Int) (struct { +// Solidity: function sentMessageInfo(bytes32 destinationBlockchainID, uint256 messageID) view returns(bytes32 messageHash, (address,uint256) feeInfo) +func (_TeleporterMessenger *TeleporterMessengerCaller) SentMessageInfo(opts *bind.CallOpts, destinationBlockchainID [32]byte, messageID *big.Int) (struct { MessageHash [32]byte FeeInfo TeleporterFeeInfo }, error) { var out []interface{} - err := _TeleporterMessenger.contract.Call(opts, &out, "sentMessageInfo", destinationChainID, messageID) + err := _TeleporterMessenger.contract.Call(opts, &out, "sentMessageInfo", destinationBlockchainID, messageID) outstruct := new(struct { MessageHash [32]byte @@ -659,43 +659,43 @@ func (_TeleporterMessenger *TeleporterMessengerCaller) SentMessageInfo(opts *bin // SentMessageInfo is a free data retrieval call binding the contract method 0x66533d12. // -// Solidity: function sentMessageInfo(bytes32 destinationChainID, uint256 messageID) view returns(bytes32 messageHash, (address,uint256) feeInfo) -func (_TeleporterMessenger *TeleporterMessengerSession) SentMessageInfo(destinationChainID [32]byte, messageID *big.Int) (struct { +// Solidity: function sentMessageInfo(bytes32 destinationBlockchainID, uint256 messageID) view returns(bytes32 messageHash, (address,uint256) feeInfo) +func (_TeleporterMessenger *TeleporterMessengerSession) SentMessageInfo(destinationBlockchainID [32]byte, messageID *big.Int) (struct { MessageHash [32]byte FeeInfo TeleporterFeeInfo }, error) { - return _TeleporterMessenger.Contract.SentMessageInfo(&_TeleporterMessenger.CallOpts, destinationChainID, messageID) + return _TeleporterMessenger.Contract.SentMessageInfo(&_TeleporterMessenger.CallOpts, destinationBlockchainID, messageID) } // SentMessageInfo is a free data retrieval call binding the contract method 0x66533d12. // -// Solidity: function sentMessageInfo(bytes32 destinationChainID, uint256 messageID) view returns(bytes32 messageHash, (address,uint256) feeInfo) -func (_TeleporterMessenger *TeleporterMessengerCallerSession) SentMessageInfo(destinationChainID [32]byte, messageID *big.Int) (struct { +// Solidity: function sentMessageInfo(bytes32 destinationBlockchainID, uint256 messageID) view returns(bytes32 messageHash, (address,uint256) feeInfo) +func (_TeleporterMessenger *TeleporterMessengerCallerSession) SentMessageInfo(destinationBlockchainID [32]byte, messageID *big.Int) (struct { MessageHash [32]byte FeeInfo TeleporterFeeInfo }, error) { - return _TeleporterMessenger.Contract.SentMessageInfo(&_TeleporterMessenger.CallOpts, destinationChainID, messageID) + return _TeleporterMessenger.Contract.SentMessageInfo(&_TeleporterMessenger.CallOpts, destinationBlockchainID, messageID) } // AddFeeAmount is a paid mutator transaction binding the contract method 0x19570c74. // -// Solidity: function addFeeAmount(bytes32 destinationChainID, uint256 messageID, address feeTokenAddress, uint256 additionalFeeAmount) returns() -func (_TeleporterMessenger *TeleporterMessengerTransactor) AddFeeAmount(opts *bind.TransactOpts, destinationChainID [32]byte, messageID *big.Int, feeTokenAddress common.Address, additionalFeeAmount *big.Int) (*types.Transaction, error) { - return _TeleporterMessenger.contract.Transact(opts, "addFeeAmount", destinationChainID, messageID, feeTokenAddress, additionalFeeAmount) +// Solidity: function addFeeAmount(bytes32 destinationBlockchainID, uint256 messageID, address feeTokenAddress, uint256 additionalFeeAmount) returns() +func (_TeleporterMessenger *TeleporterMessengerTransactor) AddFeeAmount(opts *bind.TransactOpts, destinationBlockchainID [32]byte, messageID *big.Int, feeTokenAddress common.Address, additionalFeeAmount *big.Int) (*types.Transaction, error) { + return _TeleporterMessenger.contract.Transact(opts, "addFeeAmount", destinationBlockchainID, messageID, feeTokenAddress, additionalFeeAmount) } // AddFeeAmount is a paid mutator transaction binding the contract method 0x19570c74. // -// Solidity: function addFeeAmount(bytes32 destinationChainID, uint256 messageID, address feeTokenAddress, uint256 additionalFeeAmount) returns() -func (_TeleporterMessenger *TeleporterMessengerSession) AddFeeAmount(destinationChainID [32]byte, messageID *big.Int, feeTokenAddress common.Address, additionalFeeAmount *big.Int) (*types.Transaction, error) { - return _TeleporterMessenger.Contract.AddFeeAmount(&_TeleporterMessenger.TransactOpts, destinationChainID, messageID, feeTokenAddress, additionalFeeAmount) +// Solidity: function addFeeAmount(bytes32 destinationBlockchainID, uint256 messageID, address feeTokenAddress, uint256 additionalFeeAmount) returns() +func (_TeleporterMessenger *TeleporterMessengerSession) AddFeeAmount(destinationBlockchainID [32]byte, messageID *big.Int, feeTokenAddress common.Address, additionalFeeAmount *big.Int) (*types.Transaction, error) { + return _TeleporterMessenger.Contract.AddFeeAmount(&_TeleporterMessenger.TransactOpts, destinationBlockchainID, messageID, feeTokenAddress, additionalFeeAmount) } // AddFeeAmount is a paid mutator transaction binding the contract method 0x19570c74. // -// Solidity: function addFeeAmount(bytes32 destinationChainID, uint256 messageID, address feeTokenAddress, uint256 additionalFeeAmount) returns() -func (_TeleporterMessenger *TeleporterMessengerTransactorSession) AddFeeAmount(destinationChainID [32]byte, messageID *big.Int, feeTokenAddress common.Address, additionalFeeAmount *big.Int) (*types.Transaction, error) { - return _TeleporterMessenger.Contract.AddFeeAmount(&_TeleporterMessenger.TransactOpts, destinationChainID, messageID, feeTokenAddress, additionalFeeAmount) +// Solidity: function addFeeAmount(bytes32 destinationBlockchainID, uint256 messageID, address feeTokenAddress, uint256 additionalFeeAmount) returns() +func (_TeleporterMessenger *TeleporterMessengerTransactorSession) AddFeeAmount(destinationBlockchainID [32]byte, messageID *big.Int, feeTokenAddress common.Address, additionalFeeAmount *big.Int) (*types.Transaction, error) { + return _TeleporterMessenger.Contract.AddFeeAmount(&_TeleporterMessenger.TransactOpts, destinationBlockchainID, messageID, feeTokenAddress, additionalFeeAmount) } // ReceiveCrossChainMessage is a paid mutator transaction binding the contract method 0xccb5f809. @@ -742,44 +742,44 @@ func (_TeleporterMessenger *TeleporterMessengerTransactorSession) RedeemRelayerR // RetryMessageExecution is a paid mutator transaction binding the contract method 0xfc2d6197. // -// Solidity: function retryMessageExecution(bytes32 originChainID, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message) returns() -func (_TeleporterMessenger *TeleporterMessengerTransactor) RetryMessageExecution(opts *bind.TransactOpts, originChainID [32]byte, message TeleporterMessage) (*types.Transaction, error) { - return _TeleporterMessenger.contract.Transact(opts, "retryMessageExecution", originChainID, message) +// Solidity: function retryMessageExecution(bytes32 originBlockchainID, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message) returns() +func (_TeleporterMessenger *TeleporterMessengerTransactor) RetryMessageExecution(opts *bind.TransactOpts, originBlockchainID [32]byte, message TeleporterMessage) (*types.Transaction, error) { + return _TeleporterMessenger.contract.Transact(opts, "retryMessageExecution", originBlockchainID, message) } // RetryMessageExecution is a paid mutator transaction binding the contract method 0xfc2d6197. // -// Solidity: function retryMessageExecution(bytes32 originChainID, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message) returns() -func (_TeleporterMessenger *TeleporterMessengerSession) RetryMessageExecution(originChainID [32]byte, message TeleporterMessage) (*types.Transaction, error) { - return _TeleporterMessenger.Contract.RetryMessageExecution(&_TeleporterMessenger.TransactOpts, originChainID, message) +// Solidity: function retryMessageExecution(bytes32 originBlockchainID, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message) returns() +func (_TeleporterMessenger *TeleporterMessengerSession) RetryMessageExecution(originBlockchainID [32]byte, message TeleporterMessage) (*types.Transaction, error) { + return _TeleporterMessenger.Contract.RetryMessageExecution(&_TeleporterMessenger.TransactOpts, originBlockchainID, message) } // RetryMessageExecution is a paid mutator transaction binding the contract method 0xfc2d6197. // -// Solidity: function retryMessageExecution(bytes32 originChainID, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message) returns() -func (_TeleporterMessenger *TeleporterMessengerTransactorSession) RetryMessageExecution(originChainID [32]byte, message TeleporterMessage) (*types.Transaction, error) { - return _TeleporterMessenger.Contract.RetryMessageExecution(&_TeleporterMessenger.TransactOpts, originChainID, message) +// Solidity: function retryMessageExecution(bytes32 originBlockchainID, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message) returns() +func (_TeleporterMessenger *TeleporterMessengerTransactorSession) RetryMessageExecution(originBlockchainID [32]byte, message TeleporterMessage) (*types.Transaction, error) { + return _TeleporterMessenger.Contract.RetryMessageExecution(&_TeleporterMessenger.TransactOpts, originBlockchainID, message) } // RetrySendCrossChainMessage is a paid mutator transaction binding the contract method 0xaf402850. // -// Solidity: function retrySendCrossChainMessage(bytes32 destinationChainID, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message) returns() -func (_TeleporterMessenger *TeleporterMessengerTransactor) RetrySendCrossChainMessage(opts *bind.TransactOpts, destinationChainID [32]byte, message TeleporterMessage) (*types.Transaction, error) { - return _TeleporterMessenger.contract.Transact(opts, "retrySendCrossChainMessage", destinationChainID, message) +// Solidity: function retrySendCrossChainMessage(bytes32 destinationBlockchainID, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message) returns() +func (_TeleporterMessenger *TeleporterMessengerTransactor) RetrySendCrossChainMessage(opts *bind.TransactOpts, destinationBlockchainID [32]byte, message TeleporterMessage) (*types.Transaction, error) { + return _TeleporterMessenger.contract.Transact(opts, "retrySendCrossChainMessage", destinationBlockchainID, message) } // RetrySendCrossChainMessage is a paid mutator transaction binding the contract method 0xaf402850. // -// Solidity: function retrySendCrossChainMessage(bytes32 destinationChainID, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message) returns() -func (_TeleporterMessenger *TeleporterMessengerSession) RetrySendCrossChainMessage(destinationChainID [32]byte, message TeleporterMessage) (*types.Transaction, error) { - return _TeleporterMessenger.Contract.RetrySendCrossChainMessage(&_TeleporterMessenger.TransactOpts, destinationChainID, message) +// Solidity: function retrySendCrossChainMessage(bytes32 destinationBlockchainID, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message) returns() +func (_TeleporterMessenger *TeleporterMessengerSession) RetrySendCrossChainMessage(destinationBlockchainID [32]byte, message TeleporterMessage) (*types.Transaction, error) { + return _TeleporterMessenger.Contract.RetrySendCrossChainMessage(&_TeleporterMessenger.TransactOpts, destinationBlockchainID, message) } // RetrySendCrossChainMessage is a paid mutator transaction binding the contract method 0xaf402850. // -// Solidity: function retrySendCrossChainMessage(bytes32 destinationChainID, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message) returns() -func (_TeleporterMessenger *TeleporterMessengerTransactorSession) RetrySendCrossChainMessage(destinationChainID [32]byte, message TeleporterMessage) (*types.Transaction, error) { - return _TeleporterMessenger.Contract.RetrySendCrossChainMessage(&_TeleporterMessenger.TransactOpts, destinationChainID, message) +// Solidity: function retrySendCrossChainMessage(bytes32 destinationBlockchainID, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message) returns() +func (_TeleporterMessenger *TeleporterMessengerTransactorSession) RetrySendCrossChainMessage(destinationBlockchainID [32]byte, message TeleporterMessage) (*types.Transaction, error) { + return _TeleporterMessenger.Contract.RetrySendCrossChainMessage(&_TeleporterMessenger.TransactOpts, destinationBlockchainID, message) } // SendCrossChainMessage is a paid mutator transaction binding the contract method 0x62448850. @@ -805,23 +805,23 @@ func (_TeleporterMessenger *TeleporterMessengerTransactorSession) SendCrossChain // SendSpecifiedReceipts is a paid mutator transaction binding the contract method 0x191eb698. // -// Solidity: function sendSpecifiedReceipts(bytes32 originChainID, uint256[] messageIDs, (address,uint256) feeInfo, address[] allowedRelayerAddresses) returns(uint256) -func (_TeleporterMessenger *TeleporterMessengerTransactor) SendSpecifiedReceipts(opts *bind.TransactOpts, originChainID [32]byte, messageIDs []*big.Int, feeInfo TeleporterFeeInfo, allowedRelayerAddresses []common.Address) (*types.Transaction, error) { - return _TeleporterMessenger.contract.Transact(opts, "sendSpecifiedReceipts", originChainID, messageIDs, feeInfo, allowedRelayerAddresses) +// Solidity: function sendSpecifiedReceipts(bytes32 originBlockchainID, uint256[] messageIDs, (address,uint256) feeInfo, address[] allowedRelayerAddresses) returns(uint256) +func (_TeleporterMessenger *TeleporterMessengerTransactor) SendSpecifiedReceipts(opts *bind.TransactOpts, originBlockchainID [32]byte, messageIDs []*big.Int, feeInfo TeleporterFeeInfo, allowedRelayerAddresses []common.Address) (*types.Transaction, error) { + return _TeleporterMessenger.contract.Transact(opts, "sendSpecifiedReceipts", originBlockchainID, messageIDs, feeInfo, allowedRelayerAddresses) } // SendSpecifiedReceipts is a paid mutator transaction binding the contract method 0x191eb698. // -// Solidity: function sendSpecifiedReceipts(bytes32 originChainID, uint256[] messageIDs, (address,uint256) feeInfo, address[] allowedRelayerAddresses) returns(uint256) -func (_TeleporterMessenger *TeleporterMessengerSession) SendSpecifiedReceipts(originChainID [32]byte, messageIDs []*big.Int, feeInfo TeleporterFeeInfo, allowedRelayerAddresses []common.Address) (*types.Transaction, error) { - return _TeleporterMessenger.Contract.SendSpecifiedReceipts(&_TeleporterMessenger.TransactOpts, originChainID, messageIDs, feeInfo, allowedRelayerAddresses) +// Solidity: function sendSpecifiedReceipts(bytes32 originBlockchainID, uint256[] messageIDs, (address,uint256) feeInfo, address[] allowedRelayerAddresses) returns(uint256) +func (_TeleporterMessenger *TeleporterMessengerSession) SendSpecifiedReceipts(originBlockchainID [32]byte, messageIDs []*big.Int, feeInfo TeleporterFeeInfo, allowedRelayerAddresses []common.Address) (*types.Transaction, error) { + return _TeleporterMessenger.Contract.SendSpecifiedReceipts(&_TeleporterMessenger.TransactOpts, originBlockchainID, messageIDs, feeInfo, allowedRelayerAddresses) } // SendSpecifiedReceipts is a paid mutator transaction binding the contract method 0x191eb698. // -// Solidity: function sendSpecifiedReceipts(bytes32 originChainID, uint256[] messageIDs, (address,uint256) feeInfo, address[] allowedRelayerAddresses) returns(uint256) -func (_TeleporterMessenger *TeleporterMessengerTransactorSession) SendSpecifiedReceipts(originChainID [32]byte, messageIDs []*big.Int, feeInfo TeleporterFeeInfo, allowedRelayerAddresses []common.Address) (*types.Transaction, error) { - return _TeleporterMessenger.Contract.SendSpecifiedReceipts(&_TeleporterMessenger.TransactOpts, originChainID, messageIDs, feeInfo, allowedRelayerAddresses) +// Solidity: function sendSpecifiedReceipts(bytes32 originBlockchainID, uint256[] messageIDs, (address,uint256) feeInfo, address[] allowedRelayerAddresses) returns(uint256) +func (_TeleporterMessenger *TeleporterMessengerTransactorSession) SendSpecifiedReceipts(originBlockchainID [32]byte, messageIDs []*big.Int, feeInfo TeleporterFeeInfo, allowedRelayerAddresses []common.Address) (*types.Transaction, error) { + return _TeleporterMessenger.Contract.SendSpecifiedReceipts(&_TeleporterMessenger.TransactOpts, originBlockchainID, messageIDs, feeInfo, allowedRelayerAddresses) } // TeleporterMessengerAddFeeAmountIterator is returned from FilterAddFeeAmount and is used to iterate over the raw logs and unpacked data for AddFeeAmount events raised by the TeleporterMessenger contract. @@ -893,27 +893,27 @@ func (it *TeleporterMessengerAddFeeAmountIterator) Close() error { // TeleporterMessengerAddFeeAmount represents a AddFeeAmount event raised by the TeleporterMessenger contract. type TeleporterMessengerAddFeeAmount struct { - DestinationChainID [32]byte - MessageID *big.Int - UpdatedFeeInfo TeleporterFeeInfo - Raw types.Log // Blockchain specific contextual infos + DestinationBlockchainID [32]byte + MessageID *big.Int + UpdatedFeeInfo TeleporterFeeInfo + Raw types.Log // Blockchain specific contextual infos } // FilterAddFeeAmount is a free log retrieval operation binding the contract event 0x28fe05eedf0479c9159e5b6dd2a28c93fa1a408eba22dc801fd9bc493a7fc0c2. // -// Solidity: event AddFeeAmount(bytes32 indexed destinationChainID, uint256 indexed messageID, (address,uint256) updatedFeeInfo) -func (_TeleporterMessenger *TeleporterMessengerFilterer) FilterAddFeeAmount(opts *bind.FilterOpts, destinationChainID [][32]byte, messageID []*big.Int) (*TeleporterMessengerAddFeeAmountIterator, error) { +// Solidity: event AddFeeAmount(bytes32 indexed destinationBlockchainID, uint256 indexed messageID, (address,uint256) updatedFeeInfo) +func (_TeleporterMessenger *TeleporterMessengerFilterer) FilterAddFeeAmount(opts *bind.FilterOpts, destinationBlockchainID [][32]byte, messageID []*big.Int) (*TeleporterMessengerAddFeeAmountIterator, error) { - var destinationChainIDRule []interface{} - for _, destinationChainIDItem := range destinationChainID { - destinationChainIDRule = append(destinationChainIDRule, destinationChainIDItem) + var destinationBlockchainIDRule []interface{} + for _, destinationBlockchainIDItem := range destinationBlockchainID { + destinationBlockchainIDRule = append(destinationBlockchainIDRule, destinationBlockchainIDItem) } var messageIDRule []interface{} for _, messageIDItem := range messageID { messageIDRule = append(messageIDRule, messageIDItem) } - logs, sub, err := _TeleporterMessenger.contract.FilterLogs(opts, "AddFeeAmount", destinationChainIDRule, messageIDRule) + logs, sub, err := _TeleporterMessenger.contract.FilterLogs(opts, "AddFeeAmount", destinationBlockchainIDRule, messageIDRule) if err != nil { return nil, err } @@ -922,19 +922,19 @@ func (_TeleporterMessenger *TeleporterMessengerFilterer) FilterAddFeeAmount(opts // WatchAddFeeAmount is a free log subscription operation binding the contract event 0x28fe05eedf0479c9159e5b6dd2a28c93fa1a408eba22dc801fd9bc493a7fc0c2. // -// Solidity: event AddFeeAmount(bytes32 indexed destinationChainID, uint256 indexed messageID, (address,uint256) updatedFeeInfo) -func (_TeleporterMessenger *TeleporterMessengerFilterer) WatchAddFeeAmount(opts *bind.WatchOpts, sink chan<- *TeleporterMessengerAddFeeAmount, destinationChainID [][32]byte, messageID []*big.Int) (event.Subscription, error) { +// Solidity: event AddFeeAmount(bytes32 indexed destinationBlockchainID, uint256 indexed messageID, (address,uint256) updatedFeeInfo) +func (_TeleporterMessenger *TeleporterMessengerFilterer) WatchAddFeeAmount(opts *bind.WatchOpts, sink chan<- *TeleporterMessengerAddFeeAmount, destinationBlockchainID [][32]byte, messageID []*big.Int) (event.Subscription, error) { - var destinationChainIDRule []interface{} - for _, destinationChainIDItem := range destinationChainID { - destinationChainIDRule = append(destinationChainIDRule, destinationChainIDItem) + var destinationBlockchainIDRule []interface{} + for _, destinationBlockchainIDItem := range destinationBlockchainID { + destinationBlockchainIDRule = append(destinationBlockchainIDRule, destinationBlockchainIDItem) } var messageIDRule []interface{} for _, messageIDItem := range messageID { messageIDRule = append(messageIDRule, messageIDItem) } - logs, sub, err := _TeleporterMessenger.contract.WatchLogs(opts, "AddFeeAmount", destinationChainIDRule, messageIDRule) + logs, sub, err := _TeleporterMessenger.contract.WatchLogs(opts, "AddFeeAmount", destinationBlockchainIDRule, messageIDRule) if err != nil { return nil, err } @@ -968,7 +968,7 @@ func (_TeleporterMessenger *TeleporterMessengerFilterer) WatchAddFeeAmount(opts // ParseAddFeeAmount is a log parse operation binding the contract event 0x28fe05eedf0479c9159e5b6dd2a28c93fa1a408eba22dc801fd9bc493a7fc0c2. // -// Solidity: event AddFeeAmount(bytes32 indexed destinationChainID, uint256 indexed messageID, (address,uint256) updatedFeeInfo) +// Solidity: event AddFeeAmount(bytes32 indexed destinationBlockchainID, uint256 indexed messageID, (address,uint256) updatedFeeInfo) func (_TeleporterMessenger *TeleporterMessengerFilterer) ParseAddFeeAmount(log types.Log) (*TeleporterMessengerAddFeeAmount, error) { event := new(TeleporterMessengerAddFeeAmount) if err := _TeleporterMessenger.contract.UnpackLog(event, "AddFeeAmount", log); err != nil { @@ -1047,26 +1047,26 @@ func (it *TeleporterMessengerMessageExecutedIterator) Close() error { // TeleporterMessengerMessageExecuted represents a MessageExecuted event raised by the TeleporterMessenger contract. type TeleporterMessengerMessageExecuted struct { - OriginChainID [32]byte - MessageID *big.Int - Raw types.Log // Blockchain specific contextual infos + OriginBlockchainID [32]byte + MessageID *big.Int + Raw types.Log // Blockchain specific contextual infos } // FilterMessageExecuted is a free log retrieval operation binding the contract event 0x5ad362d54cba0e49d358be9ce586a7136d10a2533579c4460b7e48ec273083ef. // -// Solidity: event MessageExecuted(bytes32 indexed originChainID, uint256 indexed messageID) -func (_TeleporterMessenger *TeleporterMessengerFilterer) FilterMessageExecuted(opts *bind.FilterOpts, originChainID [][32]byte, messageID []*big.Int) (*TeleporterMessengerMessageExecutedIterator, error) { +// Solidity: event MessageExecuted(bytes32 indexed originBlockchainID, uint256 indexed messageID) +func (_TeleporterMessenger *TeleporterMessengerFilterer) FilterMessageExecuted(opts *bind.FilterOpts, originBlockchainID [][32]byte, messageID []*big.Int) (*TeleporterMessengerMessageExecutedIterator, error) { - var originChainIDRule []interface{} - for _, originChainIDItem := range originChainID { - originChainIDRule = append(originChainIDRule, originChainIDItem) + var originBlockchainIDRule []interface{} + for _, originBlockchainIDItem := range originBlockchainID { + originBlockchainIDRule = append(originBlockchainIDRule, originBlockchainIDItem) } var messageIDRule []interface{} for _, messageIDItem := range messageID { messageIDRule = append(messageIDRule, messageIDItem) } - logs, sub, err := _TeleporterMessenger.contract.FilterLogs(opts, "MessageExecuted", originChainIDRule, messageIDRule) + logs, sub, err := _TeleporterMessenger.contract.FilterLogs(opts, "MessageExecuted", originBlockchainIDRule, messageIDRule) if err != nil { return nil, err } @@ -1075,19 +1075,19 @@ func (_TeleporterMessenger *TeleporterMessengerFilterer) FilterMessageExecuted(o // WatchMessageExecuted is a free log subscription operation binding the contract event 0x5ad362d54cba0e49d358be9ce586a7136d10a2533579c4460b7e48ec273083ef. // -// Solidity: event MessageExecuted(bytes32 indexed originChainID, uint256 indexed messageID) -func (_TeleporterMessenger *TeleporterMessengerFilterer) WatchMessageExecuted(opts *bind.WatchOpts, sink chan<- *TeleporterMessengerMessageExecuted, originChainID [][32]byte, messageID []*big.Int) (event.Subscription, error) { +// Solidity: event MessageExecuted(bytes32 indexed originBlockchainID, uint256 indexed messageID) +func (_TeleporterMessenger *TeleporterMessengerFilterer) WatchMessageExecuted(opts *bind.WatchOpts, sink chan<- *TeleporterMessengerMessageExecuted, originBlockchainID [][32]byte, messageID []*big.Int) (event.Subscription, error) { - var originChainIDRule []interface{} - for _, originChainIDItem := range originChainID { - originChainIDRule = append(originChainIDRule, originChainIDItem) + var originBlockchainIDRule []interface{} + for _, originBlockchainIDItem := range originBlockchainID { + originBlockchainIDRule = append(originBlockchainIDRule, originBlockchainIDItem) } var messageIDRule []interface{} for _, messageIDItem := range messageID { messageIDRule = append(messageIDRule, messageIDItem) } - logs, sub, err := _TeleporterMessenger.contract.WatchLogs(opts, "MessageExecuted", originChainIDRule, messageIDRule) + logs, sub, err := _TeleporterMessenger.contract.WatchLogs(opts, "MessageExecuted", originBlockchainIDRule, messageIDRule) if err != nil { return nil, err } @@ -1121,7 +1121,7 @@ func (_TeleporterMessenger *TeleporterMessengerFilterer) WatchMessageExecuted(op // ParseMessageExecuted is a log parse operation binding the contract event 0x5ad362d54cba0e49d358be9ce586a7136d10a2533579c4460b7e48ec273083ef. // -// Solidity: event MessageExecuted(bytes32 indexed originChainID, uint256 indexed messageID) +// Solidity: event MessageExecuted(bytes32 indexed originBlockchainID, uint256 indexed messageID) func (_TeleporterMessenger *TeleporterMessengerFilterer) ParseMessageExecuted(log types.Log) (*TeleporterMessengerMessageExecuted, error) { event := new(TeleporterMessengerMessageExecuted) if err := _TeleporterMessenger.contract.UnpackLog(event, "MessageExecuted", log); err != nil { @@ -1200,27 +1200,27 @@ func (it *TeleporterMessengerMessageExecutionFailedIterator) Close() error { // TeleporterMessengerMessageExecutionFailed represents a MessageExecutionFailed event raised by the TeleporterMessenger contract. type TeleporterMessengerMessageExecutionFailed struct { - OriginChainID [32]byte - MessageID *big.Int - Message TeleporterMessage - Raw types.Log // Blockchain specific contextual infos + OriginBlockchainID [32]byte + MessageID *big.Int + Message TeleporterMessage + Raw types.Log // Blockchain specific contextual infos } // FilterMessageExecutionFailed is a free log retrieval operation binding the contract event 0xbedbbe6103cef0a6c9ecbf6aa23da414542c42d7918bea18aab8b601b2c3a449. // -// Solidity: event MessageExecutionFailed(bytes32 indexed originChainID, uint256 indexed messageID, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message) -func (_TeleporterMessenger *TeleporterMessengerFilterer) FilterMessageExecutionFailed(opts *bind.FilterOpts, originChainID [][32]byte, messageID []*big.Int) (*TeleporterMessengerMessageExecutionFailedIterator, error) { +// Solidity: event MessageExecutionFailed(bytes32 indexed originBlockchainID, uint256 indexed messageID, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message) +func (_TeleporterMessenger *TeleporterMessengerFilterer) FilterMessageExecutionFailed(opts *bind.FilterOpts, originBlockchainID [][32]byte, messageID []*big.Int) (*TeleporterMessengerMessageExecutionFailedIterator, error) { - var originChainIDRule []interface{} - for _, originChainIDItem := range originChainID { - originChainIDRule = append(originChainIDRule, originChainIDItem) + var originBlockchainIDRule []interface{} + for _, originBlockchainIDItem := range originBlockchainID { + originBlockchainIDRule = append(originBlockchainIDRule, originBlockchainIDItem) } var messageIDRule []interface{} for _, messageIDItem := range messageID { messageIDRule = append(messageIDRule, messageIDItem) } - logs, sub, err := _TeleporterMessenger.contract.FilterLogs(opts, "MessageExecutionFailed", originChainIDRule, messageIDRule) + logs, sub, err := _TeleporterMessenger.contract.FilterLogs(opts, "MessageExecutionFailed", originBlockchainIDRule, messageIDRule) if err != nil { return nil, err } @@ -1229,19 +1229,19 @@ func (_TeleporterMessenger *TeleporterMessengerFilterer) FilterMessageExecutionF // WatchMessageExecutionFailed is a free log subscription operation binding the contract event 0xbedbbe6103cef0a6c9ecbf6aa23da414542c42d7918bea18aab8b601b2c3a449. // -// Solidity: event MessageExecutionFailed(bytes32 indexed originChainID, uint256 indexed messageID, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message) -func (_TeleporterMessenger *TeleporterMessengerFilterer) WatchMessageExecutionFailed(opts *bind.WatchOpts, sink chan<- *TeleporterMessengerMessageExecutionFailed, originChainID [][32]byte, messageID []*big.Int) (event.Subscription, error) { +// Solidity: event MessageExecutionFailed(bytes32 indexed originBlockchainID, uint256 indexed messageID, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message) +func (_TeleporterMessenger *TeleporterMessengerFilterer) WatchMessageExecutionFailed(opts *bind.WatchOpts, sink chan<- *TeleporterMessengerMessageExecutionFailed, originBlockchainID [][32]byte, messageID []*big.Int) (event.Subscription, error) { - var originChainIDRule []interface{} - for _, originChainIDItem := range originChainID { - originChainIDRule = append(originChainIDRule, originChainIDItem) + var originBlockchainIDRule []interface{} + for _, originBlockchainIDItem := range originBlockchainID { + originBlockchainIDRule = append(originBlockchainIDRule, originBlockchainIDItem) } var messageIDRule []interface{} for _, messageIDItem := range messageID { messageIDRule = append(messageIDRule, messageIDItem) } - logs, sub, err := _TeleporterMessenger.contract.WatchLogs(opts, "MessageExecutionFailed", originChainIDRule, messageIDRule) + logs, sub, err := _TeleporterMessenger.contract.WatchLogs(opts, "MessageExecutionFailed", originBlockchainIDRule, messageIDRule) if err != nil { return nil, err } @@ -1275,7 +1275,7 @@ func (_TeleporterMessenger *TeleporterMessengerFilterer) WatchMessageExecutionFa // ParseMessageExecutionFailed is a log parse operation binding the contract event 0xbedbbe6103cef0a6c9ecbf6aa23da414542c42d7918bea18aab8b601b2c3a449. // -// Solidity: event MessageExecutionFailed(bytes32 indexed originChainID, uint256 indexed messageID, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message) +// Solidity: event MessageExecutionFailed(bytes32 indexed originBlockchainID, uint256 indexed messageID, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message) func (_TeleporterMessenger *TeleporterMessengerFilterer) ParseMessageExecutionFailed(log types.Log) (*TeleporterMessengerMessageExecutionFailed, error) { event := new(TeleporterMessengerMessageExecutionFailed) if err := _TeleporterMessenger.contract.UnpackLog(event, "MessageExecutionFailed", log); err != nil { @@ -1354,22 +1354,22 @@ func (it *TeleporterMessengerReceiveCrossChainMessageIterator) Close() error { // TeleporterMessengerReceiveCrossChainMessage represents a ReceiveCrossChainMessage event raised by the TeleporterMessenger contract. type TeleporterMessengerReceiveCrossChainMessage struct { - OriginChainID [32]byte - MessageID *big.Int - Deliverer common.Address - RewardRedeemer common.Address - Message TeleporterMessage - Raw types.Log // Blockchain specific contextual infos + OriginBlockchainID [32]byte + MessageID *big.Int + Deliverer common.Address + RewardRedeemer common.Address + Message TeleporterMessage + Raw types.Log // Blockchain specific contextual infos } // FilterReceiveCrossChainMessage is a free log retrieval operation binding the contract event 0x6b013241f9192863bc66c1f1e9a01dc592c94592bfed5e1ed380808525679575. // -// Solidity: event ReceiveCrossChainMessage(bytes32 indexed originChainID, uint256 indexed messageID, address indexed deliverer, address rewardRedeemer, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message) -func (_TeleporterMessenger *TeleporterMessengerFilterer) FilterReceiveCrossChainMessage(opts *bind.FilterOpts, originChainID [][32]byte, messageID []*big.Int, deliverer []common.Address) (*TeleporterMessengerReceiveCrossChainMessageIterator, error) { +// Solidity: event ReceiveCrossChainMessage(bytes32 indexed originBlockchainID, uint256 indexed messageID, address indexed deliverer, address rewardRedeemer, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message) +func (_TeleporterMessenger *TeleporterMessengerFilterer) FilterReceiveCrossChainMessage(opts *bind.FilterOpts, originBlockchainID [][32]byte, messageID []*big.Int, deliverer []common.Address) (*TeleporterMessengerReceiveCrossChainMessageIterator, error) { - var originChainIDRule []interface{} - for _, originChainIDItem := range originChainID { - originChainIDRule = append(originChainIDRule, originChainIDItem) + var originBlockchainIDRule []interface{} + for _, originBlockchainIDItem := range originBlockchainID { + originBlockchainIDRule = append(originBlockchainIDRule, originBlockchainIDItem) } var messageIDRule []interface{} for _, messageIDItem := range messageID { @@ -1380,7 +1380,7 @@ func (_TeleporterMessenger *TeleporterMessengerFilterer) FilterReceiveCrossChain delivererRule = append(delivererRule, delivererItem) } - logs, sub, err := _TeleporterMessenger.contract.FilterLogs(opts, "ReceiveCrossChainMessage", originChainIDRule, messageIDRule, delivererRule) + logs, sub, err := _TeleporterMessenger.contract.FilterLogs(opts, "ReceiveCrossChainMessage", originBlockchainIDRule, messageIDRule, delivererRule) if err != nil { return nil, err } @@ -1389,12 +1389,12 @@ func (_TeleporterMessenger *TeleporterMessengerFilterer) FilterReceiveCrossChain // WatchReceiveCrossChainMessage is a free log subscription operation binding the contract event 0x6b013241f9192863bc66c1f1e9a01dc592c94592bfed5e1ed380808525679575. // -// Solidity: event ReceiveCrossChainMessage(bytes32 indexed originChainID, uint256 indexed messageID, address indexed deliverer, address rewardRedeemer, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message) -func (_TeleporterMessenger *TeleporterMessengerFilterer) WatchReceiveCrossChainMessage(opts *bind.WatchOpts, sink chan<- *TeleporterMessengerReceiveCrossChainMessage, originChainID [][32]byte, messageID []*big.Int, deliverer []common.Address) (event.Subscription, error) { +// Solidity: event ReceiveCrossChainMessage(bytes32 indexed originBlockchainID, uint256 indexed messageID, address indexed deliverer, address rewardRedeemer, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message) +func (_TeleporterMessenger *TeleporterMessengerFilterer) WatchReceiveCrossChainMessage(opts *bind.WatchOpts, sink chan<- *TeleporterMessengerReceiveCrossChainMessage, originBlockchainID [][32]byte, messageID []*big.Int, deliverer []common.Address) (event.Subscription, error) { - var originChainIDRule []interface{} - for _, originChainIDItem := range originChainID { - originChainIDRule = append(originChainIDRule, originChainIDItem) + var originBlockchainIDRule []interface{} + for _, originBlockchainIDItem := range originBlockchainID { + originBlockchainIDRule = append(originBlockchainIDRule, originBlockchainIDItem) } var messageIDRule []interface{} for _, messageIDItem := range messageID { @@ -1405,7 +1405,7 @@ func (_TeleporterMessenger *TeleporterMessengerFilterer) WatchReceiveCrossChainM delivererRule = append(delivererRule, delivererItem) } - logs, sub, err := _TeleporterMessenger.contract.WatchLogs(opts, "ReceiveCrossChainMessage", originChainIDRule, messageIDRule, delivererRule) + logs, sub, err := _TeleporterMessenger.contract.WatchLogs(opts, "ReceiveCrossChainMessage", originBlockchainIDRule, messageIDRule, delivererRule) if err != nil { return nil, err } @@ -1439,7 +1439,7 @@ func (_TeleporterMessenger *TeleporterMessengerFilterer) WatchReceiveCrossChainM // ParseReceiveCrossChainMessage is a log parse operation binding the contract event 0x6b013241f9192863bc66c1f1e9a01dc592c94592bfed5e1ed380808525679575. // -// Solidity: event ReceiveCrossChainMessage(bytes32 indexed originChainID, uint256 indexed messageID, address indexed deliverer, address rewardRedeemer, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message) +// Solidity: event ReceiveCrossChainMessage(bytes32 indexed originBlockchainID, uint256 indexed messageID, address indexed deliverer, address rewardRedeemer, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message) func (_TeleporterMessenger *TeleporterMessengerFilterer) ParseReceiveCrossChainMessage(log types.Log) (*TeleporterMessengerReceiveCrossChainMessage, error) { event := new(TeleporterMessengerReceiveCrossChainMessage) if err := _TeleporterMessenger.contract.UnpackLog(event, "ReceiveCrossChainMessage", log); err != nil { @@ -1672,28 +1672,28 @@ func (it *TeleporterMessengerSendCrossChainMessageIterator) Close() error { // TeleporterMessengerSendCrossChainMessage represents a SendCrossChainMessage event raised by the TeleporterMessenger contract. type TeleporterMessengerSendCrossChainMessage struct { - DestinationChainID [32]byte - MessageID *big.Int - Message TeleporterMessage - FeeInfo TeleporterFeeInfo - Raw types.Log // Blockchain specific contextual infos + DestinationBlockchainID [32]byte + MessageID *big.Int + Message TeleporterMessage + FeeInfo TeleporterFeeInfo + Raw types.Log // Blockchain specific contextual infos } // FilterSendCrossChainMessage is a free log retrieval operation binding the contract event 0x0563d357b89128d5a0c37c9b06420836e35d193eaf17f7960fc88e47d1e02f57. // -// Solidity: event SendCrossChainMessage(bytes32 indexed destinationChainID, uint256 indexed messageID, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message, (address,uint256) feeInfo) -func (_TeleporterMessenger *TeleporterMessengerFilterer) FilterSendCrossChainMessage(opts *bind.FilterOpts, destinationChainID [][32]byte, messageID []*big.Int) (*TeleporterMessengerSendCrossChainMessageIterator, error) { +// Solidity: event SendCrossChainMessage(bytes32 indexed destinationBlockchainID, uint256 indexed messageID, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message, (address,uint256) feeInfo) +func (_TeleporterMessenger *TeleporterMessengerFilterer) FilterSendCrossChainMessage(opts *bind.FilterOpts, destinationBlockchainID [][32]byte, messageID []*big.Int) (*TeleporterMessengerSendCrossChainMessageIterator, error) { - var destinationChainIDRule []interface{} - for _, destinationChainIDItem := range destinationChainID { - destinationChainIDRule = append(destinationChainIDRule, destinationChainIDItem) + var destinationBlockchainIDRule []interface{} + for _, destinationBlockchainIDItem := range destinationBlockchainID { + destinationBlockchainIDRule = append(destinationBlockchainIDRule, destinationBlockchainIDItem) } var messageIDRule []interface{} for _, messageIDItem := range messageID { messageIDRule = append(messageIDRule, messageIDItem) } - logs, sub, err := _TeleporterMessenger.contract.FilterLogs(opts, "SendCrossChainMessage", destinationChainIDRule, messageIDRule) + logs, sub, err := _TeleporterMessenger.contract.FilterLogs(opts, "SendCrossChainMessage", destinationBlockchainIDRule, messageIDRule) if err != nil { return nil, err } @@ -1702,19 +1702,19 @@ func (_TeleporterMessenger *TeleporterMessengerFilterer) FilterSendCrossChainMes // WatchSendCrossChainMessage is a free log subscription operation binding the contract event 0x0563d357b89128d5a0c37c9b06420836e35d193eaf17f7960fc88e47d1e02f57. // -// Solidity: event SendCrossChainMessage(bytes32 indexed destinationChainID, uint256 indexed messageID, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message, (address,uint256) feeInfo) -func (_TeleporterMessenger *TeleporterMessengerFilterer) WatchSendCrossChainMessage(opts *bind.WatchOpts, sink chan<- *TeleporterMessengerSendCrossChainMessage, destinationChainID [][32]byte, messageID []*big.Int) (event.Subscription, error) { +// Solidity: event SendCrossChainMessage(bytes32 indexed destinationBlockchainID, uint256 indexed messageID, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message, (address,uint256) feeInfo) +func (_TeleporterMessenger *TeleporterMessengerFilterer) WatchSendCrossChainMessage(opts *bind.WatchOpts, sink chan<- *TeleporterMessengerSendCrossChainMessage, destinationBlockchainID [][32]byte, messageID []*big.Int) (event.Subscription, error) { - var destinationChainIDRule []interface{} - for _, destinationChainIDItem := range destinationChainID { - destinationChainIDRule = append(destinationChainIDRule, destinationChainIDItem) + var destinationBlockchainIDRule []interface{} + for _, destinationBlockchainIDItem := range destinationBlockchainID { + destinationBlockchainIDRule = append(destinationBlockchainIDRule, destinationBlockchainIDItem) } var messageIDRule []interface{} for _, messageIDItem := range messageID { messageIDRule = append(messageIDRule, messageIDItem) } - logs, sub, err := _TeleporterMessenger.contract.WatchLogs(opts, "SendCrossChainMessage", destinationChainIDRule, messageIDRule) + logs, sub, err := _TeleporterMessenger.contract.WatchLogs(opts, "SendCrossChainMessage", destinationBlockchainIDRule, messageIDRule) if err != nil { return nil, err } @@ -1748,7 +1748,7 @@ func (_TeleporterMessenger *TeleporterMessengerFilterer) WatchSendCrossChainMess // ParseSendCrossChainMessage is a log parse operation binding the contract event 0x0563d357b89128d5a0c37c9b06420836e35d193eaf17f7960fc88e47d1e02f57. // -// Solidity: event SendCrossChainMessage(bytes32 indexed destinationChainID, uint256 indexed messageID, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message, (address,uint256) feeInfo) +// Solidity: event SendCrossChainMessage(bytes32 indexed destinationBlockchainID, uint256 indexed messageID, (uint256,address,bytes32,address,uint256,address[],(uint256,address)[],bytes) message, (address,uint256) feeInfo) func (_TeleporterMessenger *TeleporterMessengerFilterer) ParseSendCrossChainMessage(log types.Log) (*TeleporterMessengerSendCrossChainMessage, error) { event := new(TeleporterMessengerSendCrossChainMessage) if err := _TeleporterMessenger.contract.UnpackLog(event, "SendCrossChainMessage", log); err != nil { diff --git a/abi-bindings/go/Teleporter/TeleporterMessenger/packing.go b/abi-bindings/go/Teleporter/TeleporterMessenger/packing.go index 11b75b443..edb4f89b4 100644 --- a/abi-bindings/go/Teleporter/TeleporterMessenger/packing.go +++ b/abi-bindings/go/Teleporter/TeleporterMessenger/packing.go @@ -20,7 +20,7 @@ func init() { teleporterMessageType, err = abi.NewType("tuple", "struct Overloader.F", []abi.ArgumentMarshaling{ {Name: "messageID", Type: "uint256"}, {Name: "senderAddress", Type: "address"}, - {Name: "destinationChainID", Type: "bytes32"}, + {Name: "destinationBlockchainID", Type: "bytes32"}, {Name: "destinationAddress", Type: "address"}, {Name: "requiredGasLimit", Type: "uint256"}, {Name: "allowedRelayerAddresses", Type: "address[]"}, diff --git a/abi-bindings/go/Teleporter/TeleporterMessenger/packing_test.go b/abi-bindings/go/Teleporter/TeleporterMessenger/packing_test.go index 212144dc4..a586c4c07 100644 --- a/abi-bindings/go/Teleporter/TeleporterMessenger/packing_test.go +++ b/abi-bindings/go/Teleporter/TeleporterMessenger/packing_test.go @@ -16,7 +16,7 @@ func createTestTeleporterMessage(messageID int64) TeleporterMessage { m := TeleporterMessage{ MessageID: big.NewInt(messageID), SenderAddress: common.HexToAddress("0x0123456789abcdef0123456789abcdef01234567"), - DestinationChainID: [32]byte{1, 2, 3, 4}, + DestinationBlockchainID: [32]byte{1, 2, 3, 4}, DestinationAddress: common.HexToAddress("0x0123456789abcdef0123456789abcdef01234567"), RequiredGasLimit: big.NewInt(2), AllowedRelayerAddresses: []common.Address{ diff --git a/contracts/src/CrossChainApplications/ERC20Bridge/BridgeToken.sol b/contracts/src/CrossChainApplications/ERC20Bridge/BridgeToken.sol index da0734aed..f8d6f10ca 100644 --- a/contracts/src/CrossChainApplications/ERC20Bridge/BridgeToken.sol +++ b/contracts/src/CrossChainApplications/ERC20Bridge/BridgeToken.sol @@ -13,7 +13,7 @@ import {ERC20, ERC20Burnable} from "@openzeppelin/contracts/token/ERC20/extensio contract BridgeToken is ERC20Burnable { address public immutable bridgeContract; - bytes32 public immutable nativeChainID; + bytes32 public immutable nativeBlockchainID; address public immutable nativeBridge; address public immutable nativeAsset; @@ -23,7 +23,7 @@ contract BridgeToken is ERC20Burnable { * @dev Initializes a BridgeToken instance. */ constructor( - bytes32 sourceChainID, + bytes32 sourceBlockchainID, address sourceBridge, address sourceAsset, string memory tokenName, @@ -31,7 +31,7 @@ contract BridgeToken is ERC20Burnable { uint8 tokenDecimals ) ERC20(tokenName, tokenSymbol) { require( - sourceChainID != bytes32(0), + sourceBlockchainID != bytes32(0), "BridgeToken: zero source chain id" ); require( @@ -43,7 +43,7 @@ contract BridgeToken is ERC20Burnable { "BridgeToken: zero source asset address" ); bridgeContract = msg.sender; - nativeChainID = sourceChainID; + nativeBlockchainID = sourceBlockchainID; nativeBridge = sourceBridge; nativeAsset = sourceAsset; _decimals = tokenDecimals; diff --git a/contracts/src/CrossChainApplications/ERC20Bridge/ERC20Bridge.sol b/contracts/src/CrossChainApplications/ERC20Bridge/ERC20Bridge.sol index d03fe764a..0cba1ebad 100644 --- a/contracts/src/CrossChainApplications/ERC20Bridge/ERC20Bridge.sol +++ b/contracts/src/CrossChainApplications/ERC20Bridge/ERC20Bridge.sol @@ -31,7 +31,7 @@ contract ERC20Bridge is using SafeERC20 for IERC20; struct WrappedTokenTransferInfo { - bytes32 destinationChainID; + bytes32 destinationBlockchainID; address destinationBridgeAddress; address wrappedContractAddress; address recipient; @@ -42,20 +42,20 @@ contract ERC20Bridge is address public constant WARP_PRECOMPILE_ADDRESS = 0x0200000000000000000000000000000000000005; - bytes32 public immutable currentChainID; + bytes32 public immutable currentBlockchainID; // Tracks which bridge tokens have been submitted to be created other bridge instances. - // (destinationChainID, destinationBridgeAddress) -> nativeTokenContract -> tokenCreationSubmitted + // (destinationBlockchainID, destinationBridgeAddress) -> nativeTokenContract -> tokenCreationSubmitted // Note that the existence of a bridge token in this mapping does not ensure that it exists on // the destination bridge because the message to create the new token may not have been // successfully delivered yet. - mapping(bytes32 destinationChainID => mapping(address destinationBridgeAddress => mapping(address nativeTokenContract => bool tokenCreationSubmitted))) + mapping(bytes32 destinationBlockchainID => mapping(address destinationBridgeAddress => mapping(address nativeTokenContract => bool tokenCreationSubmitted))) public submittedBridgeTokenCreations; // Tracks the balances of native tokens sent to other bridge instances. // Bridges are not allowed to unwrap more than has been sent to them. - // (destinationChainID, destinationBridgeAddress) -> nativeTokenContract -> balance - mapping(bytes32 destinationChainID => mapping(address destinationBridgeAddress => mapping(address nativeTokenContract => uint256 balance))) + // (destinationBlockchainID, destinationBridgeAddress) -> nativeTokenContract -> balance + mapping(bytes32 destinationBlockchainID => mapping(address destinationBridgeAddress => mapping(address nativeTokenContract => uint256 balance))) public bridgedBalances; // Set of bridge tokens created by this bridge instance. @@ -63,8 +63,8 @@ contract ERC20Bridge is public wrappedTokenContracts; // Tracks the wrapped bridge token contract address for each native token bridged to this bridge instance. - // (nativeChainID, nativeBridgeAddress, nativeTokenAddress) -> bridgeTokenAddress - mapping(bytes32 nativeChainID => mapping(address nativeBridgeAddress => mapping(address nativeTokenAddress => address bridgeTokenAddress))) + // (nativeBlockchainID, nativeBridgeAddress, nativeTokenAddress) -> bridgeTokenAddress + mapping(bytes32 nativeBlockchainID => mapping(address nativeBridgeAddress => mapping(address nativeTokenAddress => address bridgeTokenAddress))) public nativeToWrappedTokens; uint256 public constant CREATE_BRIDGE_TOKENS_REQUIRED_GAS = 2_000_000; @@ -78,7 +78,7 @@ contract ERC20Bridge is constructor( address teleporterRegistryAddress ) TeleporterOwnerUpgradeable(teleporterRegistryAddress) { - currentChainID = IWarpMessenger(WARP_PRECOMPILE_ADDRESS) + currentBlockchainID = IWarpMessenger(WARP_PRECOMPILE_ADDRESS) .getBlockchainID(); } @@ -87,12 +87,12 @@ contract ERC20Bridge is * * Requirements: * - * - `destinationChainID` cannot be the same as the current chain ID. + * - `destinationBlockchainID` cannot be the same as the current chain ID. * - For wrapped tokens, `totalAmount` must be greater than the sum of the primary and secondary fee amounts. * - For native tokens, `adjustedAmount` after safe transfer must be greater than the primary fee amount. */ function bridgeTokens( - bytes32 destinationChainID, + bytes32 destinationBlockchainID, address destinationBridgeAddress, address tokenContractAddress, address recipient, @@ -102,7 +102,7 @@ contract ERC20Bridge is ) external nonReentrant { // Bridging tokens within a single chain is not allowed. require( - destinationChainID != currentChainID, + destinationBlockchainID != currentBlockchainID, "ERC20Bridge: cannot bridge to same chain" ); @@ -131,7 +131,7 @@ contract ERC20Bridge is return _processWrappedTokenTransfer( WrappedTokenTransferInfo({ - destinationChainID: destinationChainID, + destinationBlockchainID: destinationBlockchainID, destinationBridgeAddress: destinationBridgeAddress, wrappedContractAddress: tokenContractAddress, recipient: recipient, @@ -144,7 +144,7 @@ contract ERC20Bridge is // Otherwise, this is a token "native" to this chain. require( - submittedBridgeTokenCreations[destinationChainID][ + submittedBridgeTokenCreations[destinationBlockchainID][ destinationBridgeAddress ][tokenContractAddress], "ERC20Bridge: invalid bridge token address" @@ -168,7 +168,7 @@ contract ERC20Bridge is return _processNativeTokenTransfer({ - destinationChainID: destinationChainID, + destinationBlockchainID: destinationBlockchainID, destinationBridgeAddress: destinationBridgeAddress, nativeContractAddress: tokenContractAddress, recipient: recipient, @@ -188,7 +188,7 @@ contract ERC20Bridge is * Emits a {SubmitCreateBridgeToken} event. */ function submitCreateBridgeToken( - bytes32 destinationChainID, + bytes32 destinationBlockchainID, address destinationBridgeAddress, ERC20 nativeToken, address messageFeeAsset, @@ -226,7 +226,7 @@ contract ERC20Bridge is // Send Teleporter message. uint256 messageID = teleporterMessenger.sendCrossChainMessage( TeleporterMessageInput({ - destinationChainID: destinationChainID, + destinationBlockchainID: destinationBlockchainID, destinationAddress: destinationBridgeAddress, feeInfo: TeleporterFeeInfo({ feeTokenAddress: messageFeeAsset, @@ -238,12 +238,12 @@ contract ERC20Bridge is }) ); - submittedBridgeTokenCreations[destinationChainID][ + submittedBridgeTokenCreations[destinationBlockchainID][ destinationBridgeAddress ][address(nativeToken)] = true; emit SubmitCreateBridgeToken( - destinationChainID, + destinationBlockchainID, destinationBridgeAddress, address(nativeToken), messageID @@ -256,7 +256,7 @@ contract ERC20Bridge is * Receives a Teleporter message and routes to the appropriate internal function call. */ function receiveTeleporterMessage( - bytes32 nativeChainID, + bytes32 nativeBlockchainID, address nativeBridgeAddress, bytes calldata message ) external onlyAllowedTeleporter { @@ -275,7 +275,7 @@ contract ERC20Bridge is uint8 nativeDecimals ) = abi.decode(actionData, (address, string, string, uint8)); _createBridgeToken({ - nativeChainID: nativeChainID, + nativeBlockchainID: nativeBlockchainID, nativeBridgeAddress: nativeBridgeAddress, nativeContractAddress: nativeContractAddress, nativeName: nativeName, @@ -289,7 +289,7 @@ contract ERC20Bridge is uint256 amount ) = abi.decode(actionData, (address, address, uint256)); _mintBridgeTokens( - nativeChainID, + nativeBlockchainID, nativeBridgeAddress, nativeContractAddress, recipient, @@ -297,7 +297,7 @@ contract ERC20Bridge is ); } else if (action == BridgeAction.Transfer) { ( - bytes32 destinationChainID, + bytes32 destinationBlockchainID, address destinationBridgeAddress, address nativeContractAddress, address recipient, @@ -308,9 +308,9 @@ contract ERC20Bridge is (bytes32, address, address, address, uint256, uint256) ); _transferBridgeTokens({ - sourceChainID: nativeChainID, + sourceBlockchainID: nativeBlockchainID, sourceBridgeAddress: nativeBridgeAddress, - destinationChainID: destinationChainID, + destinationBlockchainID: destinationBlockchainID, destinationBridgeAddress: destinationBridgeAddress, nativeContractAddress: nativeContractAddress, recipient: recipient, @@ -364,7 +364,7 @@ contract ERC20Bridge is * @dev Encodes the parameters for the Transfer action to be decoded and executed on the destination. */ function encodeTransferBridgeTokensData( - bytes32 destinationChainID, + bytes32 destinationBlockchainID, address destinationBridgeAddress, address nativeContractAddress, address recipient, @@ -375,7 +375,7 @@ contract ERC20Bridge is // call to to be decoded and executed on the destination. // solhint-disable-next-line func-named-parameters bytes memory paramsData = abi.encode( - destinationChainID, + destinationBlockchainID, destinationBridgeAddress, nativeContractAddress, recipient, @@ -394,7 +394,7 @@ contract ERC20Bridge is * called by the Teleporter Messenger. */ function _createBridgeToken( - bytes32 nativeChainID, + bytes32 nativeBlockchainID, address nativeBridgeAddress, address nativeContractAddress, string memory nativeName, @@ -403,7 +403,7 @@ contract ERC20Bridge is ) private { // Check that the bridge token doesn't already exist. require( - nativeToWrappedTokens[nativeChainID][nativeBridgeAddress][ + nativeToWrappedTokens[nativeBlockchainID][nativeBridgeAddress][ nativeContractAddress ] == address(0), "ERC20Bridge: bridge token already exists" @@ -411,7 +411,7 @@ contract ERC20Bridge is address bridgeTokenAddress = address( new BridgeToken({ - sourceChainID: nativeChainID, + sourceBlockchainID: nativeBlockchainID, sourceBridge: nativeBridgeAddress, sourceAsset: nativeContractAddress, tokenName: nativeName, @@ -421,12 +421,12 @@ contract ERC20Bridge is ); wrappedTokenContracts[bridgeTokenAddress] = true; - nativeToWrappedTokens[nativeChainID][nativeBridgeAddress][ + nativeToWrappedTokens[nativeBlockchainID][nativeBridgeAddress][ nativeContractAddress ] = bridgeTokenAddress; emit CreateBridgeToken( - nativeChainID, + nativeBlockchainID, nativeBridgeAddress, nativeContractAddress, bridgeTokenAddress @@ -442,7 +442,7 @@ contract ERC20Bridge is * called by the Teleporter Messenger. */ function _mintBridgeTokens( - bytes32 nativeChainID, + bytes32 nativeBlockchainID, address nativeBridgeAddress, address nativeContractAddress, address recipient, @@ -455,7 +455,7 @@ contract ERC20Bridge is // If not, one needs to be created by the delivery of a "createBridgeToken" message first // before this mint can be processed. Once the bridge token is create, this message // could then be retried to mint the tokens. - address bridgeTokenAddress = nativeToWrappedTokens[nativeChainID][ + address bridgeTokenAddress = nativeToWrappedTokens[nativeBlockchainID][ nativeBridgeAddress ][nativeContractAddress]; require( @@ -476,9 +476,9 @@ contract ERC20Bridge is * called by the Teleporter Messenger. */ function _transferBridgeTokens( - bytes32 sourceChainID, + bytes32 sourceBlockchainID, address sourceBridgeAddress, - bytes32 destinationChainID, + bytes32 destinationBlockchainID, address destinationBridgeAddress, address nativeContractAddress, address recipient, @@ -493,7 +493,7 @@ contract ERC20Bridge is ); // Check that the bridge returning the tokens has sufficient balance to do so. - uint256 currentBalance = bridgedBalances[sourceChainID][ + uint256 currentBalance = bridgedBalances[sourceBlockchainID][ sourceBridgeAddress ][nativeContractAddress]; require( @@ -501,13 +501,13 @@ contract ERC20Bridge is "ERC20Bridge: insufficient balance" ); - bridgedBalances[sourceChainID][sourceBridgeAddress][ + bridgedBalances[sourceBlockchainID][sourceBridgeAddress][ nativeContractAddress ] = currentBalance - totalAmount; // If the destination chain ID and bridge is this bridge instance, then release the tokens back to the recipient. // In this case, since there is no secondary Teleporter message, the secondary fee amount is not used. - if (destinationChainID == currentChainID) { + if (destinationBlockchainID == currentBlockchainID) { require( destinationBridgeAddress == address(this), "ERC20Bridge: invalid destination bridge address" @@ -528,7 +528,7 @@ contract ERC20Bridge is // balance of the destination bridge instance. return _processNativeTokenTransfer({ - destinationChainID: destinationChainID, + destinationBlockchainID: destinationBlockchainID, destinationBridgeAddress: destinationBridgeAddress, nativeContractAddress: nativeContractAddress, recipient: recipient, @@ -545,11 +545,11 @@ contract ERC20Bridge is * Emits a {BridgeTokens} event. * Requirements: * - * - `destinationChainID` cannot be the same as the current chain ID. + * - `destinationBlockchainID` cannot be the same as the current chain ID. * - can not do nested bridging of wrapped tokens. */ function _processNativeTokenTransfer( - bytes32 destinationChainID, + bytes32 destinationBlockchainID, address destinationBridgeAddress, address nativeContractAddress, address recipient, @@ -566,7 +566,7 @@ contract ERC20Bridge is // This function is called by bridgeTokens and transferBridgeTokens which both already make this check, // so this check is redundant but left in for clarity. require( - destinationChainID != currentChainID, + destinationBlockchainID != currentBlockchainID, "ERC20Bridge: cannot bridge to same chain" ); ITeleporterMessenger teleporterMessenger = teleporterRegistry @@ -582,7 +582,7 @@ contract ERC20Bridge is // Update balances. uint256 bridgeAmount = totalAmount - feeAmount; - bridgedBalances[destinationChainID][destinationBridgeAddress][ + bridgedBalances[destinationBlockchainID][destinationBridgeAddress][ nativeContractAddress ] += bridgeAmount; @@ -595,7 +595,7 @@ contract ERC20Bridge is uint256 messageID = teleporterMessenger.sendCrossChainMessage( TeleporterMessageInput({ - destinationChainID: destinationChainID, + destinationBlockchainID: destinationBlockchainID, destinationAddress: destinationBridgeAddress, feeInfo: TeleporterFeeInfo({ feeTokenAddress: nativeContractAddress, @@ -609,7 +609,7 @@ contract ERC20Bridge is emit BridgeTokens({ tokenContractAddress: nativeContractAddress, - destinationChainID: destinationChainID, + destinationBlockchainID: destinationBlockchainID, teleporterMessageID: messageID, destinationBridgeAddress: destinationBridgeAddress, recipient: recipient, @@ -664,9 +664,9 @@ contract ERC20Bridge is // If the destination chain ID is the native chain ID for the wrapped token, the bridge address must also match. // This is because you are not allowed to bridge a token within its native chain. - bytes32 nativeChainID = bridgeToken.nativeChainID(); + bytes32 nativeBlockchainID = bridgeToken.nativeBlockchainID(); address nativeBridgeAddress = bridgeToken.nativeBridge(); - if (wrappedTransferInfo.destinationChainID == nativeChainID) { + if (wrappedTransferInfo.destinationBlockchainID == nativeBlockchainID) { require( wrappedTransferInfo.destinationBridgeAddress == nativeBridgeAddress, @@ -678,7 +678,7 @@ contract ERC20Bridge is // The message includes the destination chain ID and bridge contract, which will differ from the native // ones in the event that the tokens are being bridge from one non-native chain to another with two hops. bytes memory messageData = encodeTransferBridgeTokensData({ - destinationChainID: wrappedTransferInfo.destinationChainID, + destinationBlockchainID: wrappedTransferInfo.destinationBlockchainID, destinationBridgeAddress: wrappedTransferInfo .destinationBridgeAddress, nativeContractAddress: bridgeToken.nativeAsset(), @@ -689,7 +689,7 @@ contract ERC20Bridge is uint256 messageID = teleporterMessenger.sendCrossChainMessage( TeleporterMessageInput({ - destinationChainID: nativeChainID, + destinationBlockchainID: nativeBlockchainID, destinationAddress: nativeBridgeAddress, feeInfo: TeleporterFeeInfo({ feeTokenAddress: wrappedTransferInfo.wrappedContractAddress, @@ -702,7 +702,7 @@ contract ERC20Bridge is ); emit BridgeTokens({ tokenContractAddress: wrappedTransferInfo.wrappedContractAddress, - destinationChainID: wrappedTransferInfo.destinationChainID, + destinationBlockchainID: wrappedTransferInfo.destinationBlockchainID, teleporterMessageID: messageID, destinationBridgeAddress: wrappedTransferInfo .destinationBridgeAddress, diff --git a/contracts/src/CrossChainApplications/ERC20Bridge/IERC20Bridge.sol b/contracts/src/CrossChainApplications/ERC20Bridge/IERC20Bridge.sol index ee928e160..7489f6b13 100644 --- a/contracts/src/CrossChainApplications/ERC20Bridge/IERC20Bridge.sol +++ b/contracts/src/CrossChainApplications/ERC20Bridge/IERC20Bridge.sol @@ -25,7 +25,7 @@ interface IERC20Bridge { */ event BridgeTokens( address indexed tokenContractAddress, - bytes32 indexed destinationChainID, + bytes32 indexed destinationBlockchainID, uint256 indexed teleporterMessageID, address destinationBridgeAddress, address recipient, @@ -36,7 +36,7 @@ interface IERC20Bridge { * @dev Emitted when submitting a request to create a new bridge token on another chain. */ event SubmitCreateBridgeToken( - bytes32 indexed destinationChainID, + bytes32 indexed destinationBlockchainID, address indexed destinationBridgeAddress, address indexed nativeContractAddress, uint256 teleporterMessageID @@ -46,7 +46,7 @@ interface IERC20Bridge { * @dev Emitted when creating a new bridge token. */ event CreateBridgeToken( - bytes32 indexed nativeChainID, + bytes32 indexed nativeBlockchainID, address indexed nativeBridgeAddress, address indexed nativeContractAddress, address bridgeTokenAddress @@ -67,7 +67,7 @@ interface IERC20Bridge { * This can be wrapping, unwrapping, and transferring a wrapped token between two non-native chains. */ function bridgeTokens( - bytes32 destinationChainID, + bytes32 destinationBlockchainID, address destinationBridgeAddress, address tokenContractAddress, address recipient, @@ -80,7 +80,7 @@ interface IERC20Bridge { * @dev Creates a new bridge token on another chain. */ function submitCreateBridgeToken( - bytes32 destinationChainID, + bytes32 destinationBlockchainID, address destinationBridgeAddress, ERC20 nativeToken, address messageFeeAsset, diff --git a/contracts/src/CrossChainApplications/ERC20Bridge/tests/ERC20BridgeTests.t.sol b/contracts/src/CrossChainApplications/ERC20Bridge/tests/ERC20BridgeTests.t.sol index b6714079d..98bd67dd8 100644 --- a/contracts/src/CrossChainApplications/ERC20Bridge/tests/ERC20BridgeTests.t.sol +++ b/contracts/src/CrossChainApplications/ERC20Bridge/tests/ERC20BridgeTests.t.sol @@ -35,7 +35,7 @@ contract ERC20BridgeTest is Test { event BridgeTokens( address indexed tokenContractAddress, - bytes32 indexed destinationChainID, + bytes32 indexed destinationBlockchainID, uint256 indexed teleporterMessageID, address destinationBridgeAddress, address recipient, @@ -43,14 +43,14 @@ contract ERC20BridgeTest is Test { ); event SubmitCreateBridgeToken( - bytes32 indexed destinationChainID, + bytes32 indexed destinationBlockchainID, address indexed destinationBridgeAddress, address indexed nativeContractAddress, uint256 teleporterMessageID ); event CreateBridgeToken( - bytes32 indexed nativeChainID, + bytes32 indexed nativeBlockchainID, address indexed nativeBridgeAddress, address indexed nativeContractAddress, address bridgeTokenAddress @@ -93,12 +93,12 @@ contract ERC20BridgeTest is Test { mockERC20 = new UnitTestMockERC20(); } - function testSameChainID() public { + function testSameBlockchainID() public { vm.expectRevert( _formatERC20BridgeErrorMessage("cannot bridge to same chain") ); erc20Bridge.bridgeTokens({ - destinationChainID: _MOCK_BLOCKCHAIN_ID, + destinationBlockchainID: _MOCK_BLOCKCHAIN_ID, destinationBridgeAddress: _DEFAULT_OTHER_BRIDGE_ADDRESS, tokenContractAddress: address(mockERC20), recipient: _DEFAULT_RECIPIENT, @@ -119,7 +119,7 @@ contract ERC20BridgeTest is Test { _formatERC20BridgeErrorMessage("insufficient adjusted amount") ); erc20Bridge.bridgeTokens({ - destinationChainID: _DEFAULT_OTHER_CHAIN_ID, + destinationBlockchainID: _DEFAULT_OTHER_CHAIN_ID, destinationBridgeAddress: _DEFAULT_OTHER_BRIDGE_ADDRESS, tokenContractAddress: address(mockERC20), recipient: _DEFAULT_RECIPIENT, @@ -131,7 +131,7 @@ contract ERC20BridgeTest is Test { function testInvalidFeeAmountsWrappedTransfer() public { address bridgeTokenAddress = _setUpBridgeToken({ - nativeChainID: _DEFAULT_OTHER_CHAIN_ID, + nativeBlockchainID: _DEFAULT_OTHER_CHAIN_ID, nativeBridgeAddress: _DEFAULT_OTHER_BRIDGE_ADDRESS, nativeContractAddress: address(mockERC20), nativeName: _DEFAULT_TOKEN_NAME, @@ -144,7 +144,7 @@ contract ERC20BridgeTest is Test { _formatERC20BridgeErrorMessage("insufficient total amount") ); erc20Bridge.bridgeTokens({ - destinationChainID: _DEFAULT_OTHER_CHAIN_ID, + destinationBlockchainID: _DEFAULT_OTHER_CHAIN_ID, destinationBridgeAddress: _DEFAULT_OTHER_BRIDGE_ADDRESS, tokenContractAddress: bridgeTokenAddress, recipient: _DEFAULT_RECIPIENT, @@ -181,7 +181,7 @@ contract ERC20BridgeTest is Test { vm.expectRevert("SafeERC20: ERC20 operation did not succeed"); erc20Bridge.bridgeTokens({ - destinationChainID: _DEFAULT_OTHER_CHAIN_ID, + destinationBlockchainID: _DEFAULT_OTHER_CHAIN_ID, destinationBridgeAddress: _DEFAULT_OTHER_BRIDGE_ADDRESS, tokenContractAddress: address(mockERC20), recipient: _DEFAULT_RECIPIENT, @@ -203,7 +203,7 @@ contract ERC20BridgeTest is Test { TeleporterMessageInput memory expectedMessageInput = TeleporterMessageInput({ - destinationChainID: _DEFAULT_OTHER_CHAIN_ID, + destinationBlockchainID: _DEFAULT_OTHER_CHAIN_ID, destinationAddress: _DEFAULT_OTHER_BRIDGE_ADDRESS, feeInfo: TeleporterFeeInfo({ feeTokenAddress: address(mockERC20), @@ -238,7 +238,7 @@ contract ERC20BridgeTest is Test { vm.expectEmit(true, true, true, true, address(erc20Bridge)); emit BridgeTokens({ tokenContractAddress: address(mockERC20), - destinationChainID: _DEFAULT_OTHER_CHAIN_ID, + destinationBlockchainID: _DEFAULT_OTHER_CHAIN_ID, teleporterMessageID: mockMessageID, destinationBridgeAddress: _DEFAULT_OTHER_BRIDGE_ADDRESS, recipient: _DEFAULT_RECIPIENT, @@ -246,7 +246,7 @@ contract ERC20BridgeTest is Test { }); erc20Bridge.bridgeTokens({ - destinationChainID: _DEFAULT_OTHER_CHAIN_ID, + destinationBlockchainID: _DEFAULT_OTHER_CHAIN_ID, destinationBridgeAddress: _DEFAULT_OTHER_BRIDGE_ADDRESS, tokenContractAddress: address(mockERC20), recipient: _DEFAULT_RECIPIENT, @@ -294,7 +294,7 @@ contract ERC20BridgeTest is Test { vm.expectRevert("SafeERC20: ERC20 operation did not succeed"); erc20Bridge.bridgeTokens({ - destinationChainID: _DEFAULT_OTHER_CHAIN_ID, + destinationBlockchainID: _DEFAULT_OTHER_CHAIN_ID, destinationBridgeAddress: _DEFAULT_OTHER_BRIDGE_ADDRESS, tokenContractAddress: address(mockERC20), recipient: _DEFAULT_RECIPIENT, @@ -318,7 +318,7 @@ contract ERC20BridgeTest is Test { TeleporterMessageInput memory expectedMessageInput = TeleporterMessageInput({ - destinationChainID: _DEFAULT_OTHER_CHAIN_ID, + destinationBlockchainID: _DEFAULT_OTHER_CHAIN_ID, destinationAddress: _DEFAULT_OTHER_BRIDGE_ADDRESS, feeInfo: TeleporterFeeInfo({ feeTokenAddress: address(mockERC20), @@ -377,7 +377,7 @@ contract ERC20BridgeTest is Test { vm.expectEmit(true, true, true, true, address(erc20Bridge)); emit BridgeTokens({ tokenContractAddress: address(mockERC20), - destinationChainID: _DEFAULT_OTHER_CHAIN_ID, + destinationBlockchainID: _DEFAULT_OTHER_CHAIN_ID, teleporterMessageID: mockMessageID, destinationBridgeAddress: _DEFAULT_OTHER_BRIDGE_ADDRESS, recipient: _DEFAULT_RECIPIENT, @@ -385,7 +385,7 @@ contract ERC20BridgeTest is Test { }); erc20Bridge.bridgeTokens({ - destinationChainID: _DEFAULT_OTHER_CHAIN_ID, + destinationBlockchainID: _DEFAULT_OTHER_CHAIN_ID, destinationBridgeAddress: _DEFAULT_OTHER_BRIDGE_ADDRESS, tokenContractAddress: address(mockERC20), recipient: _DEFAULT_RECIPIENT, @@ -421,7 +421,7 @@ contract ERC20BridgeTest is Test { TeleporterMessageInput memory expectedMessageInput = TeleporterMessageInput({ - destinationChainID: _DEFAULT_OTHER_CHAIN_ID, + destinationBlockchainID: _DEFAULT_OTHER_CHAIN_ID, destinationAddress: _DEFAULT_OTHER_BRIDGE_ADDRESS, feeInfo: TeleporterFeeInfo({ feeTokenAddress: address(mockERC20), @@ -480,7 +480,7 @@ contract ERC20BridgeTest is Test { vm.expectEmit(true, true, true, true, address(erc20Bridge)); emit BridgeTokens({ tokenContractAddress: address(mockERC20), - destinationChainID: _DEFAULT_OTHER_CHAIN_ID, + destinationBlockchainID: _DEFAULT_OTHER_CHAIN_ID, teleporterMessageID: mockMessageID, destinationBridgeAddress: _DEFAULT_OTHER_BRIDGE_ADDRESS, recipient: _DEFAULT_RECIPIENT, @@ -488,7 +488,7 @@ contract ERC20BridgeTest is Test { }); erc20Bridge.bridgeTokens({ - destinationChainID: _DEFAULT_OTHER_CHAIN_ID, + destinationBlockchainID: _DEFAULT_OTHER_CHAIN_ID, destinationBridgeAddress: _DEFAULT_OTHER_BRIDGE_ADDRESS, tokenContractAddress: address(mockERC20), recipient: _DEFAULT_RECIPIENT, @@ -523,7 +523,7 @@ contract ERC20BridgeTest is Test { _formatERC20BridgeErrorMessage("insufficient adjusted amount") ); erc20Bridge.bridgeTokens({ - destinationChainID: _DEFAULT_OTHER_CHAIN_ID, + destinationBlockchainID: _DEFAULT_OTHER_CHAIN_ID, destinationBridgeAddress: _DEFAULT_OTHER_BRIDGE_ADDRESS, tokenContractAddress: address(mockERC20), recipient: _DEFAULT_RECIPIENT, @@ -536,7 +536,7 @@ contract ERC20BridgeTest is Test { function testNewBridgeTokenMint() public { uint256 amount = 654321; address bridgeTokenAddress = _setUpBridgeToken({ - nativeChainID: _DEFAULT_OTHER_CHAIN_ID, + nativeBlockchainID: _DEFAULT_OTHER_CHAIN_ID, nativeBridgeAddress: _DEFAULT_OTHER_BRIDGE_ADDRESS, nativeContractAddress: address(mockERC20), nativeName: _DEFAULT_TOKEN_NAME, @@ -567,7 +567,7 @@ contract ERC20BridgeTest is Test { assertEq(_DEFAULT_TOKEN_NAME, newBridgeToken.name()); assertEq(_DEFAULT_SYMBOL, newBridgeToken.symbol()); assertEq(_DEFAULT_DECIMALS, newBridgeToken.decimals()); - assertEq(_DEFAULT_OTHER_CHAIN_ID, newBridgeToken.nativeChainID()); + assertEq(_DEFAULT_OTHER_CHAIN_ID, newBridgeToken.nativeBlockchainID()); assertEq(_DEFAULT_OTHER_BRIDGE_ADDRESS, newBridgeToken.nativeBridge()); assertEq(address(mockERC20), newBridgeToken.nativeAsset()); } @@ -578,7 +578,7 @@ contract ERC20BridgeTest is Test { address recipient2 = address(57); uint256 amount2 = 123456; address bridgeTokenAddress = _setUpBridgeToken({ - nativeChainID: _DEFAULT_OTHER_CHAIN_ID, + nativeBlockchainID: _DEFAULT_OTHER_CHAIN_ID, nativeBridgeAddress: _DEFAULT_OTHER_BRIDGE_ADDRESS, nativeContractAddress: address(mockERC20), nativeName: _DEFAULT_TOKEN_NAME, @@ -627,7 +627,7 @@ contract ERC20BridgeTest is Test { assertEq(_DEFAULT_TOKEN_NAME, newBridgeToken.name()); assertEq(_DEFAULT_SYMBOL, newBridgeToken.symbol()); assertEq(_DEFAULT_DECIMALS, newBridgeToken.decimals()); - assertEq(_DEFAULT_OTHER_CHAIN_ID, newBridgeToken.nativeChainID()); + assertEq(_DEFAULT_OTHER_CHAIN_ID, newBridgeToken.nativeBlockchainID()); assertEq(_DEFAULT_OTHER_BRIDGE_ADDRESS, newBridgeToken.nativeBridge()); assertEq(address(mockERC20), newBridgeToken.nativeAsset()); } @@ -695,14 +695,14 @@ contract ERC20BridgeTest is Test { // call to the Teleporter contract is made and that the expected event is emitted. This is // required before attempting to call bridgeTokens for the given token and bridge. function _submitCreateBridgeToken( - bytes32 destinationChainID, + bytes32 destinationBlockchainID, address destinationBridgeAddress, address nativeContractAddress ) private { ERC20 nativeToken = ERC20(nativeContractAddress); TeleporterMessageInput memory expectedMessageInput = TeleporterMessageInput({ - destinationChainID: destinationChainID, + destinationBlockchainID: destinationBlockchainID, destinationAddress: destinationBridgeAddress, feeInfo: TeleporterFeeInfo({ feeTokenAddress: address(0), @@ -738,14 +738,14 @@ contract ERC20BridgeTest is Test { vm.expectEmit(true, true, true, true, address(erc20Bridge)); emit SubmitCreateBridgeToken( - destinationChainID, + destinationBlockchainID, destinationBridgeAddress, nativeContractAddress, mockMessageID ); erc20Bridge.submitCreateBridgeToken( - destinationChainID, + destinationBlockchainID, destinationBridgeAddress, nativeToken, address(0), @@ -754,7 +754,7 @@ contract ERC20BridgeTest is Test { } function _setUpBridgeToken( - bytes32 nativeChainID, + bytes32 nativeBlockchainID, address nativeBridgeAddress, address nativeContractAddress, string memory nativeName, @@ -775,13 +775,13 @@ contract ERC20BridgeTest is Test { vm.prank(MOCK_TELEPORTER_MESSENGER_ADDRESS); vm.expectEmit(true, true, true, true, address(erc20Bridge)); emit CreateBridgeToken( - nativeChainID, + nativeBlockchainID, nativeBridgeAddress, nativeContractAddress, expectedBridgeTokenAddress ); erc20Bridge.receiveTeleporterMessage( - nativeChainID, + nativeBlockchainID, nativeBridgeAddress, message ); diff --git a/contracts/src/CrossChainApplications/ExampleMessenger/ExampleCrossChainMessenger.sol b/contracts/src/CrossChainApplications/ExampleMessenger/ExampleCrossChainMessenger.sol index dced22e3e..b04e9c675 100644 --- a/contracts/src/CrossChainApplications/ExampleMessenger/ExampleCrossChainMessenger.sol +++ b/contracts/src/CrossChainApplications/ExampleMessenger/ExampleCrossChainMessenger.sol @@ -29,13 +29,13 @@ contract ExampleCrossChainMessenger is string message; } - mapping(bytes32 originChainID => Message message) private _messages; + mapping(bytes32 originBlockchainID => Message message) private _messages; /** * @dev Emitted when a message is submited to be sent. */ event SendMessage( - bytes32 indexed destinationChainID, + bytes32 indexed destinationBlockchainID, address indexed destinationAddress, address feeTokenAddress, uint256 feeAmount, @@ -47,7 +47,7 @@ contract ExampleCrossChainMessenger is * @dev Emitted when a new message is received from a given chain ID. */ event ReceiveMessage( - bytes32 indexed originChainID, + bytes32 indexed originBlockchainID, address indexed originSenderAddress, string message ); @@ -62,14 +62,14 @@ contract ExampleCrossChainMessenger is * Receives a message from another chain. */ function receiveTeleporterMessage( - bytes32 originChainID, + bytes32 originBlockchainID, address originSenderAddress, bytes calldata message ) external onlyAllowedTeleporter { // Store the message. string memory messageString = abi.decode(message, (string)); - _messages[originChainID] = Message(originSenderAddress, messageString); - emit ReceiveMessage(originChainID, originSenderAddress, messageString); + _messages[originBlockchainID] = Message(originSenderAddress, messageString); + emit ReceiveMessage(originBlockchainID, originSenderAddress, messageString); } /** @@ -77,7 +77,7 @@ contract ExampleCrossChainMessenger is * @return The message ID of the newly sent message. */ function sendMessage( - bytes32 destinationChainID, + bytes32 destinationBlockchainID, address destinationAddress, address feeTokenAddress, uint256 feeAmount, @@ -101,7 +101,7 @@ contract ExampleCrossChainMessenger is } emit SendMessage({ - destinationChainID: destinationChainID, + destinationBlockchainID: destinationBlockchainID, destinationAddress: destinationAddress, feeTokenAddress: feeTokenAddress, feeAmount: adjustedFeeAmount, @@ -111,7 +111,7 @@ contract ExampleCrossChainMessenger is return teleporterMessenger.sendCrossChainMessage( TeleporterMessageInput({ - destinationChainID: destinationChainID, + destinationBlockchainID: destinationBlockchainID, destinationAddress: destinationAddress, feeInfo: TeleporterFeeInfo({ feeTokenAddress: feeTokenAddress, @@ -129,9 +129,9 @@ contract ExampleCrossChainMessenger is * @return The sender of the message, and the message itself. */ function getCurrentMessage( - bytes32 originChainID + bytes32 originBlockchainID ) external view returns (address, string memory) { - Message memory messageInfo = _messages[originChainID]; + Message memory messageInfo = _messages[originBlockchainID]; return (messageInfo.sender, messageInfo.message); } } diff --git a/contracts/src/CrossChainApplications/README.md b/contracts/src/CrossChainApplications/README.md index 9caec5b35..50a20e1a4 100644 --- a/contracts/src/CrossChainApplications/README.md +++ b/contracts/src/CrossChainApplications/README.md @@ -66,7 +66,7 @@ To start, create the function declarations for `sendMessage`, which will send st ```solidity // Send a new message to another chain. function sendMessage( - bytes32 destinationChainID, + bytes32 destinationBlockchainID, address destinationAddress, address feeTokenAddress, uint256 feeAmount, @@ -80,7 +80,7 @@ function sendMessage( ```solidity // Receive a new message from another chain. function receiveTeleporterMessage( - bytes32 originChainID, + bytes32 originBlockchainID, address originSenderAddress, bytes calldata message ) external {} @@ -113,7 +113,7 @@ Next, add the call to the `TeleporterMessenger` contract with the message data t return teleporterMessenger.sendCrossChainMessage( TeleporterMessageInput({ - destinationChainID: destinationChainID, + destinationBlockchainID: destinationBlockchainID, destinationAddress: destinationAddress, feeInfo: TeleporterFeeInfo({ feeTokenAddress: feeTokenAddress, @@ -131,7 +131,7 @@ With the sending side complete, the next step is to implement `ITeleporterReceiv ```solidity // Receive a new message from another chain. function receiveTeleporterMessage( - bytes32 originChainID, + bytes32 originBlockchainID, address originSenderAddress, bytes calldata message ) external { @@ -149,7 +149,7 @@ The base of sending and receiving messages cross chain is complete. `MyExampleCr Start by defining the `struct` for how to save our messages. It saves the string message itself and the address of the sender. -A map will also be added where the key is the `originChainID`, and the value is the latest `message` sent from that chain. +A map will also be added where the key is the `originBlockchainID`, and the value is the latest `message` sent from that chain. ```solidity // Messages sent to this contract. @@ -158,7 +158,7 @@ struct Message { string message; } -mapping(bytes32 originChainID => Message message) private _messages; +mapping(bytes32 originBlockchainID => Message message) private _messages; ``` Next, update `receiveTeleporterMessage` to save the message into our mapping after we receive and verify that it's sent from Teleporter. ABI decode the `message` bytes into a string. @@ -166,7 +166,7 @@ Next, update `receiveTeleporterMessage` to save the message into our mapping aft ```solidity // Receive a new message from another chain. function receiveTeleporterMessage( - bytes32 originChainID, + bytes32 originBlockchainID, address originSenderAddress, bytes calldata message ) external { @@ -174,7 +174,7 @@ function receiveTeleporterMessage( require(msg.sender == address(teleporterMessenger), "Unauthorized."); // Store the message. - messages[originChainID] = Message(originSenderAddress, abi.decode(message, (string))); + messages[originBlockchainID] = Message(originSenderAddress, abi.decode(message, (string))); } ``` @@ -183,9 +183,9 @@ Next, add a function called `getCurrentMessage` that allows users or contracts t ```solidity // Check the current message from another chain. function getCurrentMessage( - bytes32 originChainID + bytes32 originBlockchainID ) external view returns (address, string memory) { - Message memory messageInfo = messages[originChainID]; + Message memory messageInfo = messages[originBlockchainID]; return (messageInfo.sender, messageInfo.message); } ``` diff --git a/contracts/src/CrossChainApplications/VerifiedBlockHash/BlockHashPublisher.sol b/contracts/src/CrossChainApplications/VerifiedBlockHash/BlockHashPublisher.sol index 88405ea00..93550a5fd 100644 --- a/contracts/src/CrossChainApplications/VerifiedBlockHash/BlockHashPublisher.sol +++ b/contracts/src/CrossChainApplications/VerifiedBlockHash/BlockHashPublisher.sol @@ -20,7 +20,7 @@ contract BlockHashPublisher { * @dev Emitted when a block hash is submitted to be published to another chain. */ event PublishBlockHash( - bytes32 indexed destinationChainID, + bytes32 indexed destinationBlockchainID, address indexed destinationAddress, uint256 indexed blockHeight, bytes32 blockHash @@ -40,7 +40,7 @@ contract BlockHashPublisher { * @return The message of the of the message sent to publish the hash. */ function publishLatestBlockHash( - bytes32 destinationChainID, + bytes32 destinationBlockchainID, address destinationAddress ) external returns (uint256) { // Get the latest block info. Note it must the previous block @@ -49,11 +49,11 @@ contract BlockHashPublisher { bytes32 blockHash = blockhash(blockHeight); // ABI encode the function arguments to be called on the destination. - // The originChainID and originSenderAddress arguments of the target function are provided by Warp/Teleporter. + // The originBlockchainID and originSenderAddress arguments of the target function are provided by Warp/Teleporter. bytes memory messageData = abi.encode(blockHeight, blockHash); emit PublishBlockHash( - destinationChainID, + destinationBlockchainID, destinationAddress, blockHeight, blockHash @@ -61,7 +61,7 @@ contract BlockHashPublisher { return teleporterRegistry.getLatestTeleporter().sendCrossChainMessage( TeleporterMessageInput({ - destinationChainID: destinationChainID, + destinationBlockchainID: destinationBlockchainID, destinationAddress: destinationAddress, feeInfo: TeleporterFeeInfo({ feeTokenAddress: address(0), diff --git a/contracts/src/CrossChainApplications/VerifiedBlockHash/BlockHashReceiver.sol b/contracts/src/CrossChainApplications/VerifiedBlockHash/BlockHashReceiver.sol index 27a15c4c9..e69d8201c 100644 --- a/contracts/src/CrossChainApplications/VerifiedBlockHash/BlockHashReceiver.sol +++ b/contracts/src/CrossChainApplications/VerifiedBlockHash/BlockHashReceiver.sol @@ -13,7 +13,7 @@ import {TeleporterOwnerUpgradeable} from "../../Teleporter/upgrades/TeleporterOw */ contract BlockHashReceiver is ITeleporterReceiver, TeleporterOwnerUpgradeable { // Source chain information - bytes32 public immutable sourceChainID; + bytes32 public immutable sourceBlockchainID; address public immutable sourcePublisherContractAddress; // Latest received block information @@ -24,7 +24,7 @@ contract BlockHashReceiver is ITeleporterReceiver, TeleporterOwnerUpgradeable { * @dev Emitted when a new block hash is received from a given origin chain ID. */ event ReceiveBlockHash( - bytes32 indexed originChainID, + bytes32 indexed originBlockchainID, address indexed originSenderAddress, uint256 indexed blockHeight, bytes32 blockHash @@ -32,10 +32,10 @@ contract BlockHashReceiver is ITeleporterReceiver, TeleporterOwnerUpgradeable { constructor( address teleporterRegistryAddress, - bytes32 publisherChainID, + bytes32 publisherBlockchainID, address publisherContractAddress ) TeleporterOwnerUpgradeable(teleporterRegistryAddress) { - sourceChainID = publisherChainID; + sourceBlockchainID = publisherBlockchainID; sourcePublisherContractAddress = publisherContractAddress; } @@ -51,12 +51,12 @@ contract BlockHashReceiver is ITeleporterReceiver, TeleporterOwnerUpgradeable { */ function receiveTeleporterMessage( - bytes32 originChainID, + bytes32 originBlockchainID, address originSenderAddress, bytes calldata message ) external onlyAllowedTeleporter { require( - originChainID == sourceChainID, + originBlockchainID == sourceBlockchainID, "BlockHashReceiver: invalid source chain ID" ); require( @@ -73,7 +73,7 @@ contract BlockHashReceiver is ITeleporterReceiver, TeleporterOwnerUpgradeable { latestBlockHeight = blockHeight; latestBlockHash = blockHash; emit ReceiveBlockHash( - originChainID, + originBlockchainID, originSenderAddress, blockHeight, blockHash diff --git a/contracts/src/Teleporter/ITeleporterMessenger.sol b/contracts/src/Teleporter/ITeleporterMessenger.sol index ea7faf58d..3bc8d0750 100644 --- a/contracts/src/Teleporter/ITeleporterMessenger.sol +++ b/contracts/src/Teleporter/ITeleporterMessenger.sol @@ -18,7 +18,7 @@ struct TeleporterMessageReceipt { // the message on the destination chain, the relayer accounts allowed to deliver the // message, and the message data itself. struct TeleporterMessageInput { - bytes32 destinationChainID; + bytes32 destinationBlockchainID; address destinationAddress; TeleporterFeeInfo feeInfo; uint256 requiredGasLimit; @@ -30,7 +30,7 @@ struct TeleporterMessageInput { struct TeleporterMessage { uint256 messageID; address senderAddress; - bytes32 destinationChainID; + bytes32 destinationBlockchainID; address destinationAddress; uint256 requiredGasLimit; address[] allowedRelayerAddresses; @@ -56,7 +56,7 @@ interface ITeleporterMessenger { * @dev Emitted when sending a Teleporter message cross-chain. */ event SendCrossChainMessage( - bytes32 indexed destinationChainID, + bytes32 indexed destinationBlockchainID, uint256 indexed messageID, TeleporterMessage message, TeleporterFeeInfo feeInfo @@ -67,7 +67,7 @@ interface ITeleporterMessenger { * been sent, but not yet delivered to the destination chain. */ event AddFeeAmount( - bytes32 indexed destinationChainID, + bytes32 indexed destinationBlockchainID, uint256 indexed messageID, TeleporterFeeInfo updatedFeeInfo ); @@ -77,7 +77,7 @@ interface ITeleporterMessenger { * but message execution fails. Failed messages can then be retried with `retryMessageExecution` */ event MessageExecutionFailed( - bytes32 indexed originChainID, + bytes32 indexed originBlockchainID, uint256 indexed messageID, TeleporterMessage message ); @@ -90,7 +90,7 @@ interface ITeleporterMessenger { * Each message received can be executed successfully at most once. */ event MessageExecuted( - bytes32 indexed originChainID, + bytes32 indexed originBlockchainID, uint256 indexed messageID ); @@ -98,7 +98,7 @@ interface ITeleporterMessenger { * @dev Emitted when a TeleporterMessage is successfully received. */ event ReceiveCrossChainMessage( - bytes32 indexed originChainID, + bytes32 indexed originBlockchainID, uint256 indexed messageID, address indexed deliverer, address rewardRedeemer, @@ -132,7 +132,7 @@ interface ITeleporterMessenger { * state until a receipt is received for the message. */ function retrySendCrossChainMessage( - bytes32 destinationChainID, + bytes32 destinationBlockchainID, TeleporterMessage calldata message ) external; @@ -145,7 +145,7 @@ interface ITeleporterMessenger { * receipt of delivery of the message. */ function addFeeAmount( - bytes32 destinationChainID, + bytes32 destinationBlockchainID, uint256 messageID, address feeTokenAddress, uint256 additionalFeeAmount @@ -172,7 +172,7 @@ interface ITeleporterMessenger { * was later deployed to that address. Messages are ensured to be successfully executed at most once. */ function retryMessageExecution( - bytes32 originChainID, + bytes32 originBlockchainID, TeleporterMessage calldata message ) external; @@ -185,7 +185,7 @@ interface ITeleporterMessenger { * @return The message ID of the newly sent message. */ function sendSpecifiedReceipts( - bytes32 originChainID, + bytes32 originBlockchainID, uint256[] calldata messageIDs, TeleporterFeeInfo calldata feeInfo, address[] calldata allowedRelayerAddresses @@ -201,7 +201,7 @@ interface ITeleporterMessenger { * @return The message hash */ function getMessageHash( - bytes32 destinationChainID, + bytes32 destinationBlockchainID, uint256 messageID ) external view returns (bytes32); @@ -210,7 +210,7 @@ interface ITeleporterMessenger { * @return Boolean representing if the given message has been received. */ function messageReceived( - bytes32 originChainID, + bytes32 originBlockchainID, uint256 messageID ) external view returns (bool); @@ -220,7 +220,7 @@ interface ITeleporterMessenger { * @return The relayer reward address for the given message. */ function getRelayerRewardAddress( - bytes32 originChainID, + bytes32 originBlockchainID, uint256 messageID ) external view returns (address); @@ -238,7 +238,7 @@ interface ITeleporterMessenger { * @return The fee token address and fee amount for a the given message. */ function getFeeInfo( - bytes32 destinationChainID, + bytes32 destinationBlockchainID, uint256 messageID ) external view returns (address, uint256); @@ -246,22 +246,22 @@ interface ITeleporterMessenger { * @dev Gets the next message ID to be used for a given chain ID. * @return The next message ID to be used to send a message to the given chain ID. */ - function getNextMessageID(bytes32 chainID) external view returns (uint256); + function getNextMessageID(bytes32 destinationBlockchainID) external view returns (uint256); /** - * @dev Gets the number of receipts that have been sent to the given destination chain ID. + * @dev Gets the number of receipts that are waiting to be sent to the given origin chain ID. * @return Size of the given queue. */ function getReceiptQueueSize( - bytes32 chainID + bytes32 originBlockchainID ) external view returns (uint256); /** - * @dev Gets the receipt at the given index in the queue for the given chain ID. + * @dev Gets the receipt at the given index in the queue for the given origin chain ID. * @return The receipt requested. */ function getReceiptAtIndex( - bytes32 chainID, + bytes32 originBlockchainID, uint256 index ) external view returns (TeleporterMessageReceipt memory); } diff --git a/contracts/src/Teleporter/ITeleporterReceiver.sol b/contracts/src/Teleporter/ITeleporterReceiver.sol index c45241fb5..d97f9e496 100644 --- a/contracts/src/Teleporter/ITeleporterReceiver.sol +++ b/contracts/src/Teleporter/ITeleporterReceiver.sol @@ -14,12 +14,12 @@ interface ITeleporterReceiver { /** * @dev Called by TeleporterMessenger on the receiving chain. * - * @param originChainID is provided by the TeleporterMessenger contract. + * @param originBlockchainID is provided by the TeleporterMessenger contract. * @param originSenderAddress is provided by the TeleporterMessenger contract. * @param message is the TeleporterMessage payload set by the sender. */ function receiveTeleporterMessage( - bytes32 originChainID, + bytes32 originBlockchainID, address originSenderAddress, bytes calldata message ) external; diff --git a/contracts/src/Teleporter/TeleporterMessenger.sol b/contracts/src/Teleporter/TeleporterMessenger.sol index dfb8397dc..d58e3dd14 100644 --- a/contracts/src/Teleporter/TeleporterMessenger.sol +++ b/contracts/src/Teleporter/TeleporterMessenger.sol @@ -43,34 +43,34 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { // Tracks the latest message ID used for a given destination chain. // Key is the destination blockchain ID, and the value is the last message ID used for that chain. // Note that the first message ID used for each chain will be 1 (not 0). - mapping(bytes32 destinationChainID => uint256 messageID) + mapping(bytes32 destinationBlockchainID => uint256 messageID) public latestMessageIDs; // Tracks the outstanding receipts to send back to a given chain in subsequent messages sent to that chain. // Key is the blockchain ID of the other chain, and the value is a queue of pending receipts for messages // received from that chain. - mapping(bytes32 sourceChainID => ReceiptQueue.TeleporterMessageReceiptQueue receiptQueue) + mapping(bytes32 sourceBlockchainID => ReceiptQueue.TeleporterMessageReceiptQueue receiptQueue) public receiptQueues; // Tracks the message hash and fee information for each message sent that has yet to be acknowledged // with a receipt. The messages are tracked per chain and keyed by message ID. // The first key is the blockchain ID of the destination chain, the second key is the message ID, and the value is the info // for the uniquely identified message. - mapping(bytes32 destinationChainID => mapping(uint256 messageID => SentMessageInfo messageInfo)) + mapping(bytes32 destinationBlockchainID => mapping(uint256 messageID => SentMessageInfo messageInfo)) public sentMessageInfo; // Tracks the hash of messages that have been received but whose execution has never succeeded. // Enables retrying of failed messages with higher gas limits. Message execution is guaranteed to // succeed at most once. The first key is the blockchain ID of the sending chain, the second key is the message ID, and // the value is the hash of the uniquely identified message whose execution failed. - mapping(bytes32 sourceChainID => mapping(uint256 messageID => bytes32 messageHash)) + mapping(bytes32 sourceBlockchainID => mapping(uint256 messageID => bytes32 messageHash)) public receivedFailedMessageHashes; // Tracks the relayer reward address for each message delivered from a given chain. // Note that these values are also used to determine if a given message has been delivered or not. // The first key is the blockchain ID, the second key is the message ID, and the value is the reward address // provided by the deliverer of the uniquely identified message. - mapping(bytes32 sourceChainID => mapping(uint256 messageID => address relayerRewardAddress)) + mapping(bytes32 sourceBlockchainID => mapping(uint256 messageID => address relayerRewardAddress)) internal _relayerRewardAddresses; // Tracks the reward amounts for a given asset able to be redeemed by a given relayer. @@ -96,7 +96,7 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { return _sendTeleporterMessage( messageInput, - receiptQueues[messageInput.destinationChainID] + receiptQueues[messageInput.destinationBlockchainID] .getOutstandingReceiptsToSend() ); } @@ -107,16 +107,16 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { * Emits a {SendCrossChainMessage} event. * Requirements: * - * - `message` must have been previously sent to the given `destinationChainID`. + * - `message` must have been previously sent to the given `destinationBlockchainID`. * - `message` encoding must match previously sent message. */ function retrySendCrossChainMessage( - bytes32 destinationChainID, + bytes32 destinationBlockchainID, TeleporterMessage calldata message ) external senderNonReentrant { // Get the previously sent message hash. SentMessageInfo memory existingMessageInfo = sentMessageInfo[ - destinationChainID + destinationBlockchainID ][message.messageID]; // If the message hash is zero, the message was never sent. require( @@ -134,7 +134,7 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { // Emit and make state variable changes before external calls when possible, // though this function is protected by sender reentrancy guard. emit SendCrossChainMessage( - destinationChainID, + destinationBlockchainID, message.messageID, message, existingMessageInfo.feeInfo @@ -156,7 +156,7 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { * - `feeTokenAddress` must match the fee asset contract address used in the original call to `sendCrossChainMessage`. */ function addFeeAmount( - bytes32 destinationChainID, + bytes32 destinationBlockchainID, uint256 messageID, address feeTokenAddress, uint256 additionalFeeAmount @@ -177,7 +177,7 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { // will be cleared from state. At this point, you can not add to its fee. This is also the // case if the given message never existed. require( - sentMessageInfo[destinationChainID][messageID].messageHash != + sentMessageInfo[destinationBlockchainID][messageID].messageHash != bytes32(0), "TeleporterMessenger: message not found" ); @@ -188,7 +188,7 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { // the previously submitted asset type as a defensive measure to avoid having users accidentally confuse // which asset they are paying. require( - sentMessageInfo[destinationChainID][messageID] + sentMessageInfo[destinationBlockchainID][messageID] .feeInfo .feeTokenAddress == feeTokenAddress, "TeleporterMessenger: invalid fee asset contract address" @@ -201,14 +201,14 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { ); // Store the updated fee amount, and emit it as an event. - sentMessageInfo[destinationChainID][messageID] + sentMessageInfo[destinationBlockchainID][messageID] .feeInfo .amount += adjustedAmount; emit AddFeeAmount( - destinationChainID, + destinationBlockchainID, messageID, - sentMessageInfo[destinationChainID][messageID].feeInfo + sentMessageInfo[destinationBlockchainID][messageID].feeInfo ); } @@ -222,7 +222,7 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { * - `relayerRewardAddress` must not be the zero address. * - `messageIndex` must specify a valid warp message in the transaction's storage slots. * - Valid warp message provided in storage slots, and sender address matches the address of this contract. - * - Teleporter message `destinationChainID` must match the `blockchainID` of this contract. + * - Teleporter message `destinationBlockchainID` must match the `blockchainID` of this contract. * - Teleporter message was not previously delivered. * - Transaction was sent by an allowed relayer for corresponding teleporter message. */ @@ -265,7 +265,7 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { // Require that the message was intended for this blockchain. require( - teleporterMessage.destinationChainID == blockchainID, + teleporterMessage.destinationBlockchainID == blockchainID, "TeleporterMessenger: invalid destination chain ID" ); @@ -349,11 +349,11 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { * - `message` must have previously failed to execute, and matches the hash of the failed message. */ function retryMessageExecution( - bytes32 originChainID, + bytes32 originBlockchainID, TeleporterMessage calldata message ) external receiverNonReentrant { // Check that the hash of the payload provided matches the hash of the payload that previously failed to execute. - bytes32 failedMessageHash = receivedFailedMessageHashes[originChainID][ + bytes32 failedMessageHash = receivedFailedMessageHashes[originBlockchainID][ message.messageID ]; require( @@ -374,14 +374,14 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { // Clear the failed message hash from state prior to retrying its execution to redundantly prevent // reentrance attacks (on top of the nonReentrant guard). - emit MessageExecuted(originChainID, message.messageID); - delete receivedFailedMessageHashes[originChainID][message.messageID]; + emit MessageExecuted(originBlockchainID, message.messageID); + delete receivedFailedMessageHashes[originBlockchainID][message.messageID]; // Re-encode the payload by ABI encoding a call to the {receiveTeleporterMessage} function // defined by the {ITeleporterReceiver} interface. bytes memory payload = abi.encodeCall( ITeleporterReceiver.receiveTeleporterMessage, - (originChainID, message.senderAddress, message.message) + (originBlockchainID, message.senderAddress, message.message) ); // Reattempt the message execution with all of the gas left available for execution of this transaction. @@ -416,7 +416,7 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { * - `messageIDs` must all be valid and have existing receipts. */ function sendSpecifiedReceipts( - bytes32 originChainID, + bytes32 originBlockchainID, uint256[] calldata messageIDs, TeleporterFeeInfo calldata feeInfo, address[] calldata allowedRelayerAddresses @@ -430,7 +430,7 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { uint256 receivedMessageID = messageIDs[i]; // Get the relayer reward address for the message. address relayerRewardAddress = _relayerRewardAddresses[ - originChainID + originBlockchainID ][receivedMessageID]; require( relayerRewardAddress != address(0), @@ -446,7 +446,7 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { return _sendTeleporterMessage( TeleporterMessageInput({ - destinationChainID: originChainID, + destinationBlockchainID: originBlockchainID, destinationAddress: address(0), feeInfo: feeInfo, requiredGasLimit: uint256(0), @@ -484,30 +484,30 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { * See {ITeleporterMessenger-getMessageHash} */ function getMessageHash( - bytes32 destinationChainID, + bytes32 destinationBlockchainID, uint256 messageID ) external view returns (bytes32) { - return sentMessageInfo[destinationChainID][messageID].messageHash; + return sentMessageInfo[destinationBlockchainID][messageID].messageHash; } /** * @dev See {ITeleporterMessenger-messageReceived} */ function messageReceived( - bytes32 originChainID, + bytes32 originBlockchainID, uint256 messageID ) external view returns (bool) { - return _messageReceived(originChainID, messageID); + return _messageReceived(originBlockchainID, messageID); } /** * @dev See {ITeleporterMessenger-getRelayerRewardAddress} */ function getRelayerRewardAddress( - bytes32 originChainID, + bytes32 originBlockchainID, uint256 messageID ) external view returns (address) { - return _relayerRewardAddresses[originChainID][messageID]; + return _relayerRewardAddresses[originBlockchainID][messageID]; } /** @@ -524,39 +524,39 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { * @dev See {ITeleporterMessenger-getFeeInfo} */ function getFeeInfo( - bytes32 destinationChainID, + bytes32 destinationBlockchainID, uint256 messageID ) external view returns (address, uint256) { - TeleporterFeeInfo memory feeInfo = sentMessageInfo[destinationChainID][ + TeleporterFeeInfo memory feeInfo = sentMessageInfo[destinationBlockchainID][ messageID ].feeInfo; return (feeInfo.feeTokenAddress, feeInfo.amount); } /** - * @dev Returns the next message ID to be used to send a message to the given chain ID. + * @dev Returns the next message ID to be used to send a message to the given blockchain ID. */ - function getNextMessageID(bytes32 chainID) external view returns (uint256) { - return _getNextMessageID(chainID); + function getNextMessageID(bytes32 destinationBlockchainID) external view returns (uint256) { + return _getNextMessageID(destinationBlockchainID); } /** * @dev See {ITeleporterMessenger-getReceiptQueueSize} */ function getReceiptQueueSize( - bytes32 chainID + bytes32 originBlockchainID ) external view returns (uint256) { - return receiptQueues[chainID].size(); + return receiptQueues[originBlockchainID].size(); } /** * @dev See {ITeleporterMessenger-getReceiptAtIndex} */ function getReceiptAtIndex( - bytes32 chainID, + bytes32 originBlockchainID, uint256 index ) external view returns (TeleporterMessageReceipt memory) { - return receiptQueues[chainID].getReceiptAtIndex(index); + return receiptQueues[originBlockchainID].getReceiptAtIndex(index); } /** @@ -564,10 +564,10 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { * @return A boolean representing if the given message has been received or not. */ function _messageReceived( - bytes32 originChainID, + bytes32 originBlockchainID, uint256 messageID ) internal view returns (bool) { - return _relayerRewardAddresses[originChainID][messageID] != address(0); + return _relayerRewardAddresses[originBlockchainID][messageID] != address(0); } /** @@ -603,13 +603,13 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { TeleporterMessageReceipt[] memory receipts ) private returns (uint256) { // Get the message ID to use for this message. - uint256 messageID = _getNextMessageID(messageInput.destinationChainID); + uint256 messageID = _getNextMessageID(messageInput.destinationBlockchainID); // Construct and serialize the message. TeleporterMessage memory teleporterMessage = TeleporterMessage({ messageID: messageID, senderAddress: msg.sender, - destinationChainID: messageInput.destinationChainID, + destinationBlockchainID: messageInput.destinationBlockchainID, destinationAddress: messageInput.destinationAddress, requiredGasLimit: messageInput.requiredGasLimit, allowedRelayerAddresses: messageInput.allowedRelayerAddresses, @@ -619,7 +619,7 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { bytes memory teleporterMessageBytes = abi.encode(teleporterMessage); // Set the message ID value as being used. - latestMessageIDs[messageInput.destinationChainID] = messageID; + latestMessageIDs[messageInput.destinationBlockchainID] = messageID; // If the fee amount is non-zero, transfer the asset into control of this TeleporterMessenger contract instance. // The fee is allowed to be 0 because it's possible for someone to run their own relayer and deliver their own messages, @@ -645,7 +645,7 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { feeTokenAddress: messageInput.feeInfo.feeTokenAddress, amount: adjustedFeeAmount }); - sentMessageInfo[messageInput.destinationChainID][ + sentMessageInfo[messageInput.destinationBlockchainID][ messageID ] = SentMessageInfo({ messageHash: keccak256(teleporterMessageBytes), @@ -653,7 +653,7 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { }); emit SendCrossChainMessage( - messageInput.destinationChainID, + messageInput.destinationBlockchainID, messageID, teleporterMessage, adjustedFeeInfo @@ -666,19 +666,19 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { } /** - * @dev Records the receival of a receipt for a message previously sent to the `destinationChainID` with the given `messageID`. + * @dev Records the receival of a receipt for a message previously sent to the `destinationBlockchainID` with the given `messageID`. * * Returns early if a receipt was already previously received for this message, or if the message never existed. Otherwise, deletes * the message information from `sentMessageInfo` and increments the reward redeemable by the specified relayer reward address. */ function _markReceipt( - bytes32 destinationChainID, + bytes32 destinationBlockchainID, uint256 messageID, address relayerRewardAddress ) private { // Get the information about the sent message to be marked as received. SentMessageInfo memory messageInfo = sentMessageInfo[ - destinationChainID + destinationBlockchainID ][messageID]; // If the message hash does not exist, it could be the case that the receipt was already @@ -690,7 +690,7 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { } // Delete the message information from state now that it is known to be delivered. - delete sentMessageInfo[destinationChainID][messageID]; + delete sentMessageInfo[destinationBlockchainID][messageID]; // Increment the fee/reward amount owed to the relayer for having delivered // the message identified in this receipt. @@ -713,7 +713,7 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { * - There is enough gas left to cover `message.requiredGasLimit`. */ function _handleInitialMessageExecution( - bytes32 originChainID, + bytes32 originBlockchainID, TeleporterMessage memory message ) private { // Check that the message delivery was provided the required gas amount as specified by the sender. @@ -731,7 +731,7 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { // execution so that it can be retried in the future should a contract be later deployed to // the address. if (message.destinationAddress.code.length == 0) { - _storeFailedMessageExecution(originChainID, message); + _storeFailedMessageExecution(originBlockchainID, message); return; } @@ -739,7 +739,7 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { // defined by the {ITeleporterReceiver} interface. bytes memory payload = abi.encodeCall( ITeleporterReceiver.receiveTeleporterMessage, - (originChainID, message.senderAddress, message.message) + (originBlockchainID, message.senderAddress, message.message) ); // Call the destination address of the message with the formatted call data. Only provide the required @@ -755,11 +755,11 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { // retries). Either way, the message will now be considered "delivered" since the relayer // provided enough gas to meet the required gas limit. if (!success) { - _storeFailedMessageExecution(originChainID, message); + _storeFailedMessageExecution(originBlockchainID, message); return; } - emit MessageExecuted(originChainID, message.messageID); + emit MessageExecuted(originBlockchainID, message.messageID); } function _tryExecuteMessage( @@ -793,21 +793,21 @@ contract TeleporterMessenger is ITeleporterMessenger, ReentrancyGuards { * such that the message execution can be retried by anyone in the future. */ function _storeFailedMessageExecution( - bytes32 originChainID, + bytes32 originBlockchainID, TeleporterMessage memory message ) private { - receivedFailedMessageHashes[originChainID][ + receivedFailedMessageHashes[originBlockchainID][ message.messageID ] = keccak256(abi.encode(message)); // Emit a failed execution event for anyone monitoring unsuccessful messages to retry. - emit MessageExecutionFailed(originChainID, message.messageID, message); + emit MessageExecutionFailed(originBlockchainID, message.messageID, message); } /** - * @dev Returns the next message ID to be used to send a message to the given `chainID`. + * @dev Returns the next message ID to be used to send a message to the given `originBlockchainID`. */ - function _getNextMessageID(bytes32 chainID) private view returns (uint256) { - return latestMessageIDs[chainID] + 1; + function _getNextMessageID(bytes32 originBlockchainID) private view returns (uint256) { + return latestMessageIDs[originBlockchainID] + 1; } } diff --git a/contracts/src/Teleporter/tests/GetMessageHashTests.t.sol b/contracts/src/Teleporter/tests/GetMessageHashTests.t.sol index 66c59437c..a7f4cc44b 100644 --- a/contracts/src/Teleporter/tests/GetMessageHashTests.t.sol +++ b/contracts/src/Teleporter/tests/GetMessageHashTests.t.sol @@ -23,7 +23,7 @@ contract GetMessageHashTest is TeleporterMessengerTest { TeleporterMessage memory expectedMessage = TeleporterMessage({ messageID: messageID, senderAddress: address(this), - destinationChainID: DEFAULT_DESTINATION_CHAIN_ID, + destinationBlockchainID: DEFAULT_DESTINATION_CHAIN_ID, destinationAddress: DEFAULT_DESTINATION_ADDRESS, requiredGasLimit: DEFAULT_REQUIRED_GAS_LIMIT, allowedRelayerAddresses: new address[](0), diff --git a/contracts/src/Teleporter/tests/GetNextMessageIdTests.t.sol b/contracts/src/Teleporter/tests/GetNextMessageIdTests.t.sol index 0dfa0fc31..0241276c9 100644 --- a/contracts/src/Teleporter/tests/GetNextMessageIdTests.t.sol +++ b/contracts/src/Teleporter/tests/GetNextMessageIdTests.t.sol @@ -16,15 +16,15 @@ contract GetNextMessageIDTest is TeleporterMessengerTest { } function testFirstMessageID() public { - bytes32 chainID = bytes32( + bytes32 blockchainID = bytes32( hex"11223344556677889900aabbccddeeff11223344556677889900aabbccddeeff" ); - assertEq(teleporterMessenger.getNextMessageID(chainID), 1); + assertEq(teleporterMessenger.getNextMessageID(blockchainID), 1); } function testSecondMessageID() public { - bytes32 chainID = bytes32( + bytes32 blockchainID = bytes32( hex"11223344556677889900aabbccddeeff11223344556677889900aabbccddeeff" ); @@ -34,7 +34,7 @@ contract GetNextMessageIDTest is TeleporterMessengerTest { abi.encode(bytes32(0)) ); TeleporterMessageInput memory messageInput = TeleporterMessageInput({ - destinationChainID: chainID, + destinationBlockchainID: blockchainID, destinationAddress: address(0), feeInfo: TeleporterFeeInfo({ feeTokenAddress: address(0), @@ -46,17 +46,17 @@ contract GetNextMessageIDTest is TeleporterMessengerTest { }); uint256 first = teleporterMessenger.sendCrossChainMessage(messageInput); - uint256 second = teleporterMessenger.getNextMessageID(chainID); + uint256 second = teleporterMessenger.getNextMessageID(blockchainID); assertEq(first, 1); assertEq(second, 2); } function testOtherDestinationSubnetID() public { - bytes32 chainID = bytes32( + bytes32 blockchainID = bytes32( hex"11223344556677889900aabbccddeeff11223344556677889900aabbccddeeff" ); - bytes32 otherChainID = bytes32( + bytes32 otherBlockchainID = bytes32( hex"00000000556677889900aabbccddeeff11223344556677889900aabbccddeeff" ); @@ -66,7 +66,7 @@ contract GetNextMessageIDTest is TeleporterMessengerTest { abi.encode(bytes32(0)) ); TeleporterMessageInput memory messageInput = TeleporterMessageInput({ - destinationChainID: chainID, + destinationBlockchainID: blockchainID, destinationAddress: address(0), feeInfo: TeleporterFeeInfo({ feeTokenAddress: address(0), @@ -78,7 +78,7 @@ contract GetNextMessageIDTest is TeleporterMessengerTest { }); uint256 first = teleporterMessenger.sendCrossChainMessage(messageInput); - uint256 other = teleporterMessenger.getNextMessageID(otherChainID); + uint256 other = teleporterMessenger.getNextMessageID(otherBlockchainID); assertEq(first, 1); assertEq(other, 1); diff --git a/contracts/src/Teleporter/tests/GetOutstandingReceiptsToSendTests.t.sol b/contracts/src/Teleporter/tests/GetOutstandingReceiptsToSendTests.t.sol index 1b56b67be..1f2cbbff5 100644 --- a/contracts/src/Teleporter/tests/GetOutstandingReceiptsToSendTests.t.sol +++ b/contracts/src/Teleporter/tests/GetOutstandingReceiptsToSendTests.t.sol @@ -40,12 +40,12 @@ contract GetOutstandingReceiptsToSendTest is TeleporterMessengerTest { ); // Mock receiving each of the messages corresponding to the receipts. - bytes32 chainID = bytes32( + bytes32 blockchainID = bytes32( hex"11223344556677889900aabbccddeeff11223344556677889900aabbccddeeff" ); for (uint256 i = 0; i < expectedReceipts.length; i++) { _receiveTestMessage( - chainID, + blockchainID, expectedReceipts[i].receivedMessageID, expectedReceipts[i].relayerRewardAddress, new TeleporterMessageReceipt[](0) @@ -59,10 +59,10 @@ contract GetOutstandingReceiptsToSendTest is TeleporterMessengerTest { hex"deadbeef" ); expectedMessage.receipts = expectedReceipts; - expectedMessage.destinationChainID = chainID; + expectedMessage.destinationBlockchainID = blockchainID; TeleporterFeeInfo memory feeInfo = TeleporterFeeInfo(address(0), 0); TeleporterMessageInput memory messageInput = TeleporterMessageInput({ - destinationChainID: expectedMessage.destinationChainID, + destinationBlockchainID: expectedMessage.destinationBlockchainID, destinationAddress: expectedMessage.destinationAddress, feeInfo: feeInfo, requiredGasLimit: expectedMessage.requiredGasLimit, @@ -88,7 +88,7 @@ contract GetOutstandingReceiptsToSendTest is TeleporterMessengerTest { // Expect the SendCrossChainMessage event to be emitted. vm.expectEmit(true, true, true, true, address(teleporterMessenger)); emit SendCrossChainMessage( - messageInput.destinationChainID, + messageInput.destinationBlockchainID, expectedMessage.messageID, expectedMessage, feeInfo @@ -103,7 +103,7 @@ contract GetOutstandingReceiptsToSendTest is TeleporterMessengerTest { 2, hex"deadbeef" ); - nextExpectedMessage.destinationChainID = chainID; + nextExpectedMessage.destinationBlockchainID = blockchainID; vm.expectCall( WARP_PRECOMPILE_ADDRESS, abi.encodeCall( @@ -113,7 +113,7 @@ contract GetOutstandingReceiptsToSendTest is TeleporterMessengerTest { ); vm.expectEmit(true, true, true, true, address(teleporterMessenger)); emit SendCrossChainMessage( - messageInput.destinationChainID, + messageInput.destinationBlockchainID, nextExpectedMessage.messageID, nextExpectedMessage, feeInfo @@ -164,12 +164,12 @@ contract GetOutstandingReceiptsToSendTest is TeleporterMessengerTest { ); // Mock receiving each of the messages corresponding to the receipts. - bytes32 chainID = bytes32( + bytes32 blockchainID = bytes32( hex"11223344556677889900aabbccddeeff11223344556677889900aabbccddeeff" ); for (uint256 i = 0; i < expectedReceiptsBatch1.length; i++) { _receiveTestMessage( - chainID, + blockchainID, expectedReceiptsBatch1[i].receivedMessageID, expectedReceiptsBatch1[i].relayerRewardAddress, new TeleporterMessageReceipt[](0) @@ -177,7 +177,7 @@ contract GetOutstandingReceiptsToSendTest is TeleporterMessengerTest { } for (uint256 i = 0; i < expectedReceiptsBatch2.length; i++) { _receiveTestMessage( - chainID, + blockchainID, expectedReceiptsBatch2[i].receivedMessageID, expectedReceiptsBatch2[i].relayerRewardAddress, new TeleporterMessageReceipt[](0) @@ -192,10 +192,10 @@ contract GetOutstandingReceiptsToSendTest is TeleporterMessengerTest { hex"deadbeef" ); expectedMessage.receipts = expectedReceiptsBatch1; - expectedMessage.destinationChainID = chainID; + expectedMessage.destinationBlockchainID = blockchainID; TeleporterFeeInfo memory feeInfo = TeleporterFeeInfo(address(0), 0); TeleporterMessageInput memory messageInput = TeleporterMessageInput({ - destinationChainID: expectedMessage.destinationChainID, + destinationBlockchainID: expectedMessage.destinationBlockchainID, destinationAddress: expectedMessage.destinationAddress, feeInfo: feeInfo, requiredGasLimit: expectedMessage.requiredGasLimit, @@ -221,7 +221,7 @@ contract GetOutstandingReceiptsToSendTest is TeleporterMessengerTest { // Expect the SendCrossChainMessage event to be emitted. vm.expectEmit(true, true, true, true, address(teleporterMessenger)); emit SendCrossChainMessage( - messageInput.destinationChainID, + messageInput.destinationBlockchainID, expectedMessage.messageID, expectedMessage, feeInfo @@ -237,7 +237,7 @@ contract GetOutstandingReceiptsToSendTest is TeleporterMessengerTest { hex"deadbeef" ); nextExpectedMessage.receipts = expectedReceiptsBatch2; - nextExpectedMessage.destinationChainID = chainID; + nextExpectedMessage.destinationBlockchainID = blockchainID; vm.expectCall( WARP_PRECOMPILE_ADDRESS, abi.encodeCall( @@ -247,7 +247,7 @@ contract GetOutstandingReceiptsToSendTest is TeleporterMessengerTest { ); vm.expectEmit(true, true, true, true, address(teleporterMessenger)); emit SendCrossChainMessage( - messageInput.destinationChainID, + messageInput.destinationBlockchainID, nextExpectedMessage.messageID, nextExpectedMessage, feeInfo diff --git a/contracts/src/Teleporter/tests/HandleInitialMessageExecutionTests.t.sol b/contracts/src/Teleporter/tests/HandleInitialMessageExecutionTests.t.sol index eaedbda18..766cffe66 100644 --- a/contracts/src/Teleporter/tests/HandleInitialMessageExecutionTests.t.sol +++ b/contracts/src/Teleporter/tests/HandleInitialMessageExecutionTests.t.sol @@ -25,7 +25,7 @@ contract SampleMessageReceiver is ITeleporterReceiver { } function receiveTeleporterMessage( - bytes32 originChainID, + bytes32 originBlockchainID, address originSenderAddress, bytes calldata message ) external { @@ -39,7 +39,7 @@ contract SampleMessageReceiver is ITeleporterReceiver { (string, bool) ); _receiveMessage( - originChainID, + originBlockchainID, originSenderAddress, messageString, succeed @@ -47,7 +47,7 @@ contract SampleMessageReceiver is ITeleporterReceiver { } else if (action == SampleMessageReceiverAction.ReceiveRecursive) { string memory messageString = abi.decode(actionData, (string)); _receiveMessageRecursive( - originChainID, + originBlockchainID, originSenderAddress, messageString ); @@ -58,7 +58,7 @@ contract SampleMessageReceiver is ITeleporterReceiver { // Stores the message in this contract to be fetched by anyone. function _receiveMessage( - bytes32 originChainID, + bytes32 originBlockchainID, address originSenderAddress, string memory message, bool succeed @@ -66,13 +66,13 @@ contract SampleMessageReceiver is ITeleporterReceiver { require(msg.sender == teleporterContract, "unauthorized"); require(succeed, "intended to fail"); latestMessage = message; - latestMessageSenderSubnetID = originChainID; + latestMessageSenderSubnetID = originBlockchainID; latestMessageSenderAddress = originSenderAddress; } // Tries to recursively call the teleporterContract to receive a message, which should always fail. function _receiveMessageRecursive( - bytes32 originChainID, + bytes32 originBlockchainID, address originSenderAddress, string memory message ) internal { @@ -82,7 +82,7 @@ contract SampleMessageReceiver is ITeleporterReceiver { ); messenger.receiveCrossChainMessage(0, address(42)); latestMessage = message; - latestMessageSenderSubnetID = originChainID; + latestMessageSenderSubnetID = originBlockchainID; latestMessageSenderAddress = originSenderAddress; } } @@ -106,7 +106,7 @@ contract HandleInitialMessageExecutionTest is TeleporterMessengerTest { TeleporterMessage memory messageToReceive = TeleporterMessage({ messageID: 42, senderAddress: address(this), - destinationChainID: DEFAULT_DESTINATION_CHAIN_ID, + destinationBlockchainID: DEFAULT_DESTINATION_CHAIN_ID, destinationAddress: address(destinationContract), requiredGasLimit: DEFAULT_REQUIRED_GAS_LIMIT, allowedRelayerAddresses: new address[](0), @@ -168,7 +168,7 @@ contract HandleInitialMessageExecutionTest is TeleporterMessengerTest { TeleporterMessage memory messageToReceive = TeleporterMessage({ messageID: 42, senderAddress: address(this), - destinationChainID: DEFAULT_DESTINATION_CHAIN_ID, + destinationBlockchainID: DEFAULT_DESTINATION_CHAIN_ID, destinationAddress: address(destinationContract), requiredGasLimit: uint256( bytes32( @@ -204,7 +204,7 @@ contract HandleInitialMessageExecutionTest is TeleporterMessengerTest { TeleporterMessage memory messageToReceive = TeleporterMessage({ messageID: 42, senderAddress: address(this), - destinationChainID: DEFAULT_DESTINATION_CHAIN_ID, + destinationBlockchainID: DEFAULT_DESTINATION_CHAIN_ID, destinationAddress: address(destinationContract), requiredGasLimit: DEFAULT_REQUIRED_GAS_LIMIT, allowedRelayerAddresses: new address[](0), @@ -270,7 +270,7 @@ contract HandleInitialMessageExecutionTest is TeleporterMessengerTest { TeleporterMessage memory messageToReceive = TeleporterMessage({ messageID: 42, senderAddress: address(this), - destinationChainID: DEFAULT_DESTINATION_CHAIN_ID, + destinationBlockchainID: DEFAULT_DESTINATION_CHAIN_ID, destinationAddress: address(destinationContract), requiredGasLimit: DEFAULT_REQUIRED_GAS_LIMIT, allowedRelayerAddresses: new address[](0), diff --git a/contracts/src/Teleporter/tests/ReceiveCrossChainMessageTests.t.sol b/contracts/src/Teleporter/tests/ReceiveCrossChainMessageTests.t.sol index 2bf0b3d28..5906a953b 100644 --- a/contracts/src/Teleporter/tests/ReceiveCrossChainMessageTests.t.sol +++ b/contracts/src/Teleporter/tests/ReceiveCrossChainMessageTests.t.sol @@ -32,7 +32,7 @@ contract ReceiveCrossChainMessagedTest is TeleporterMessengerTest { TeleporterMessage memory messageToReceive = TeleporterMessage({ messageID: 1, senderAddress: address(this), - destinationChainID: DEFAULT_DESTINATION_CHAIN_ID, + destinationBlockchainID: DEFAULT_DESTINATION_CHAIN_ID, destinationAddress: DEFAULT_DESTINATION_ADDRESS, requiredGasLimit: DEFAULT_REQUIRED_GAS_LIMIT, allowedRelayerAddresses: allowedRelayers, @@ -178,17 +178,17 @@ contract ReceiveCrossChainMessagedTest is TeleporterMessengerTest { ); } - function testInvalidDestinationChainID() public { + function testInvalidDestinationBlockchainID() public { // Construct the test message to be received. TeleporterMessage memory messageToReceive = _createMockTeleporterMessage( 1, new bytes(0) ); - bytes32 invalidDestinationChainID = bytes32( + bytes32 invalidDestinationBlockchainID = bytes32( hex"deadbeefcafebabedeadbeefcafebabedeadbeefcafebabedeadbeefcafebabe" ); - messageToReceive.destinationChainID = invalidDestinationChainID; + messageToReceive.destinationBlockchainID = invalidDestinationBlockchainID; WarpMessage memory warpMessage = _createDefaultWarpMessage( DEFAULT_ORIGIN_CHAIN_ID, @@ -238,7 +238,7 @@ contract ReceiveCrossChainMessagedTest is TeleporterMessengerTest { TeleporterMessage memory messageToReceive = TeleporterMessage({ messageID: 42, senderAddress: address(this), - destinationChainID: DEFAULT_DESTINATION_CHAIN_ID, + destinationBlockchainID: DEFAULT_DESTINATION_CHAIN_ID, destinationAddress: DEFAULT_DESTINATION_ADDRESS, requiredGasLimit: DEFAULT_REQUIRED_GAS_LIMIT, allowedRelayerAddresses: allowedRelayers, diff --git a/contracts/src/Teleporter/tests/RetryMessageExecutionTests.t.sol b/contracts/src/Teleporter/tests/RetryMessageExecutionTests.t.sol index 0cfaf0872..1361a8346 100644 --- a/contracts/src/Teleporter/tests/RetryMessageExecutionTests.t.sol +++ b/contracts/src/Teleporter/tests/RetryMessageExecutionTests.t.sol @@ -28,7 +28,7 @@ contract FlakyMessageReceiver is ITeleporterReceiver { } function receiveTeleporterMessage( - bytes32 originChainID, + bytes32 originBlockchainID, address originSenderAddress, bytes calldata messageBytes ) external { @@ -38,10 +38,10 @@ contract FlakyMessageReceiver is ITeleporterReceiver { .decode(messageBytes, (FlakyMessageReceiverAction, bytes)); if (action == FlakyMessageReceiverAction.ReceiveMessage) { string memory message = abi.decode(actionData, (string)); - _receiveMessage(originChainID, originSenderAddress, message); + _receiveMessage(originBlockchainID, originSenderAddress, message); } else if (action == FlakyMessageReceiverAction.RetryReceive) { string memory message = abi.decode(actionData, (string)); - _retryReceive(originChainID, originSenderAddress, message); + _retryReceive(originBlockchainID, originSenderAddress, message); } else { revert("invalid action"); } @@ -49,20 +49,20 @@ contract FlakyMessageReceiver is ITeleporterReceiver { // Stores the message in this contract to be fetched by anyone. function _receiveMessage( - bytes32 originChainID, + bytes32 originBlockchainID, address originSenderAddress, string memory message ) internal { require(msg.sender == teleporterContract, "unauthorized"); require(block.number % 2 != 0, "even block number"); latestMessage = message; - latestMessageSenderSubnetID = originChainID; + latestMessageSenderSubnetID = originBlockchainID; latestMessageSenderAddress = originSenderAddress; } // Tries to call the teleporterContract to receive a message, which should always fail. function _retryReceive( - bytes32 originChainID, + bytes32 originBlockchainID, address originSenderAddress, string memory message ) internal { @@ -74,7 +74,7 @@ contract FlakyMessageReceiver is ITeleporterReceiver { ); messenger.receiveCrossChainMessage(0, address(42)); latestMessage = message; - latestMessageSenderSubnetID = originChainID; + latestMessageSenderSubnetID = originBlockchainID; latestMessageSenderAddress = originSenderAddress; } } @@ -99,7 +99,7 @@ contract RetryMessageExecutionTest is TeleporterMessengerTest { function testExecutionFailsAgain() public { // First submit a message whose execution fails. ( - bytes32 originChainID, + bytes32 originBlockchainID, TeleporterMessage memory message, ) = _receiveFailedMessage(false); @@ -108,7 +108,7 @@ contract RetryMessageExecutionTest is TeleporterMessengerTest { vm.expectRevert( _formatTeleporterErrorMessage("retry execution failed") ); - teleporterMessenger.retryMessageExecution(originChainID, message); + teleporterMessenger.retryMessageExecution(originBlockchainID, message); } function testMessageHashNotFound() public { @@ -116,7 +116,7 @@ contract RetryMessageExecutionTest is TeleporterMessengerTest { TeleporterMessage memory fakeMessage = TeleporterMessage({ messageID: 12345, senderAddress: address(this), - destinationChainID: DEFAULT_DESTINATION_CHAIN_ID, + destinationBlockchainID: DEFAULT_DESTINATION_CHAIN_ID, destinationAddress: address(destinationContract), requiredGasLimit: DEFAULT_REQUIRED_GAS_LIMIT, allowedRelayerAddresses: new address[](0), @@ -134,7 +134,7 @@ contract RetryMessageExecutionTest is TeleporterMessengerTest { function testInvalidMessageHash() public { // First submit a message whose execution fails. ( - bytes32 originChainID, + bytes32 originBlockchainID, TeleporterMessage memory message, ) = _receiveFailedMessage(false); @@ -142,25 +142,25 @@ contract RetryMessageExecutionTest is TeleporterMessengerTest { // Alter the message before retrying it. message.message = "altered message"; vm.expectRevert(_formatTeleporterErrorMessage("invalid message hash")); - teleporterMessenger.retryMessageExecution(originChainID, message); + teleporterMessenger.retryMessageExecution(originBlockchainID, message); } function testCanNotRetryAgainAfterSuccess() public { // Successfully retry a message execution. ( - bytes32 originChainID, + bytes32 originBlockchainID, TeleporterMessage memory message ) = _successfullyRetryMessage(); // Now try again and make sure it's been cleared from state vm.expectRevert(_formatTeleporterErrorMessage("message not found")); - teleporterMessenger.retryMessageExecution(originChainID, message); + teleporterMessenger.retryMessageExecution(originBlockchainID, message); } function testCanNotReceiveMessageWhileRetrying() public { // First submit a message whose execution fails. ( - bytes32 originChainID, + bytes32 originBlockchainID, TeleporterMessage memory message, ) = _receiveFailedMessage(false); @@ -168,12 +168,12 @@ contract RetryMessageExecutionTest is TeleporterMessengerTest { // Now retry it within a block with an odd timestamp. // It should still fail because it tries to re-enter the teleporter contract. vm.expectRevert(); - teleporterMessenger.retryMessageExecution(originChainID, message); + teleporterMessenger.retryMessageExecution(originBlockchainID, message); } function testEOAFailsThenRetrySucceeds() public { ( - bytes32 originChainID, + bytes32 originBlockchainID, address destinationAddress, TeleporterMessage memory message ) = _receiveMessageSentToEOA(); @@ -183,12 +183,12 @@ contract RetryMessageExecutionTest is TeleporterMessengerTest { vm.etch(destinationAddress, new bytes(10)); // Retrying the message execution should not revert. - teleporterMessenger.retryMessageExecution(originChainID, message); + teleporterMessenger.retryMessageExecution(originBlockchainID, message); } function testEOAFailsAgainOnRetry() public { ( - bytes32 originChainID, + bytes32 originBlockchainID, , TeleporterMessage memory message ) = _receiveMessageSentToEOA(); @@ -198,7 +198,7 @@ contract RetryMessageExecutionTest is TeleporterMessengerTest { vm.expectRevert( _formatTeleporterErrorMessage("destination address has no code") ); - teleporterMessenger.retryMessageExecution(originChainID, message); + teleporterMessenger.retryMessageExecution(originBlockchainID, message); } function _receiveFailedMessage( @@ -215,7 +215,7 @@ contract RetryMessageExecutionTest is TeleporterMessengerTest { TeleporterMessage memory messageToReceive = TeleporterMessage({ messageID: 42, senderAddress: address(this), - destinationChainID: DEFAULT_DESTINATION_CHAIN_ID, + destinationBlockchainID: DEFAULT_DESTINATION_CHAIN_ID, destinationAddress: address(destinationContract), requiredGasLimit: DEFAULT_REQUIRED_GAS_LIMIT, allowedRelayerAddresses: new address[](0), @@ -280,7 +280,7 @@ contract RetryMessageExecutionTest is TeleporterMessengerTest { { // First submit a message whose execution fails. ( - bytes32 originChainID, + bytes32 originBlockchainID, TeleporterMessage memory message, string memory messageString ) = _receiveFailedMessage(false); @@ -288,20 +288,20 @@ contract RetryMessageExecutionTest is TeleporterMessengerTest { // Now retry the message execution in a block with an odd height, which should succeed. vm.roll(13); vm.expectEmit(true, true, true, true, address(teleporterMessenger)); - emit MessageExecuted(originChainID, message.messageID); - teleporterMessenger.retryMessageExecution(originChainID, message); + emit MessageExecuted(originBlockchainID, message.messageID); + teleporterMessenger.retryMessageExecution(originBlockchainID, message); // Check that the message had the proper affect on the destination contract. assertEq(destinationContract.latestMessage(), messageString); assertEq( destinationContract.latestMessageSenderSubnetID(), - originChainID + originBlockchainID ); assertEq( destinationContract.latestMessageSenderAddress(), address(this) ); - return (originChainID, message); + return (originBlockchainID, message); } } diff --git a/contracts/src/Teleporter/tests/RetrySendCrossChainMessageTests.t.sol b/contracts/src/Teleporter/tests/RetrySendCrossChainMessageTests.t.sol index 72bf862e9..73dd98f95 100644 --- a/contracts/src/Teleporter/tests/RetrySendCrossChainMessageTests.t.sol +++ b/contracts/src/Teleporter/tests/RetrySendCrossChainMessageTests.t.sol @@ -24,7 +24,7 @@ contract RetrySendCrossChainMessageTest is TeleporterMessengerTest { TeleporterMessage memory expectedMessage = TeleporterMessage({ messageID: messageID, senderAddress: address(this), - destinationChainID: DEFAULT_DESTINATION_CHAIN_ID, + destinationBlockchainID: DEFAULT_DESTINATION_CHAIN_ID, destinationAddress: DEFAULT_DESTINATION_ADDRESS, requiredGasLimit: DEFAULT_REQUIRED_GAS_LIMIT, allowedRelayerAddresses: new address[](0), @@ -43,7 +43,7 @@ contract RetrySendCrossChainMessageTest is TeleporterMessengerTest { TeleporterMessage memory fakeMessage = TeleporterMessage({ messageID: 354, senderAddress: address(this), - destinationChainID: DEFAULT_DESTINATION_CHAIN_ID, + destinationBlockchainID: DEFAULT_DESTINATION_CHAIN_ID, destinationAddress: DEFAULT_DESTINATION_ADDRESS, requiredGasLimit: DEFAULT_REQUIRED_GAS_LIMIT, allowedRelayerAddresses: new address[](0), @@ -66,7 +66,7 @@ contract RetrySendCrossChainMessageTest is TeleporterMessengerTest { TeleporterMessage memory alteredMessage = TeleporterMessage({ messageID: messageID, senderAddress: address(this), - destinationChainID: DEFAULT_DESTINATION_CHAIN_ID, + destinationBlockchainID: DEFAULT_DESTINATION_CHAIN_ID, destinationAddress: DEFAULT_DESTINATION_ADDRESS, requiredGasLimit: DEFAULT_REQUIRED_GAS_LIMIT, allowedRelayerAddresses: new address[](0), diff --git a/contracts/src/Teleporter/tests/SendCrossChainMessageTests.t.sol b/contracts/src/Teleporter/tests/SendCrossChainMessageTests.t.sol index 490c0b70c..9ab50cd34 100644 --- a/contracts/src/Teleporter/tests/SendCrossChainMessageTests.t.sol +++ b/contracts/src/Teleporter/tests/SendCrossChainMessageTests.t.sol @@ -23,7 +23,7 @@ contract SendCrossChainMessageTest is TeleporterMessengerTest { ); TeleporterFeeInfo memory feeInfo = TeleporterFeeInfo(address(0), 0); TeleporterMessageInput memory messageInput = TeleporterMessageInput({ - destinationChainID: DEFAULT_DESTINATION_CHAIN_ID, + destinationBlockchainID: DEFAULT_DESTINATION_CHAIN_ID, destinationAddress: expectedMessage.destinationAddress, feeInfo: feeInfo, requiredGasLimit: expectedMessage.requiredGasLimit, @@ -50,7 +50,7 @@ contract SendCrossChainMessageTest is TeleporterMessengerTest { // Expect the SendCrossChainMessage event to be emitted. vm.expectEmit(true, true, true, true, address(teleporterMessenger)); emit SendCrossChainMessage( - messageInput.destinationChainID, + messageInput.destinationBlockchainID, expectedMessage.messageID, expectedMessage, feeInfo @@ -66,7 +66,7 @@ contract SendCrossChainMessageTest is TeleporterMessengerTest { // Check receipt queue uint256 queueSize = teleporterMessenger.getReceiptQueueSize( - messageInput.destinationChainID + messageInput.destinationBlockchainID ); assertEq(queueSize, 0); } @@ -83,7 +83,7 @@ contract SendCrossChainMessageTest is TeleporterMessengerTest { 13131313131313131313 ); TeleporterMessageInput memory messageInput = TeleporterMessageInput({ - destinationChainID: DEFAULT_DESTINATION_CHAIN_ID, + destinationBlockchainID: DEFAULT_DESTINATION_CHAIN_ID, destinationAddress: expectedMessage.destinationAddress, feeInfo: feeInfo, requiredGasLimit: expectedMessage.requiredGasLimit, @@ -110,7 +110,7 @@ contract SendCrossChainMessageTest is TeleporterMessengerTest { // Expect the SendCrossChainMessage event to be emitted. vm.expectEmit(true, true, true, true, address(teleporterMessenger)); emit SendCrossChainMessage( - messageInput.destinationChainID, + messageInput.destinationBlockchainID, expectedMessage.messageID, expectedMessage, feeInfo @@ -142,7 +142,7 @@ contract SendCrossChainMessageTest is TeleporterMessengerTest { address invalidFeeAsset = 0xb8be9140D8717f4a8fd7e8ae23C5668bc3A4B39c; uint256 feeAmount = 4567; TeleporterMessageInput memory messageInput = TeleporterMessageInput({ - destinationChainID: DEFAULT_DESTINATION_CHAIN_ID, + destinationBlockchainID: DEFAULT_DESTINATION_CHAIN_ID, destinationAddress: DEFAULT_DESTINATION_ADDRESS, feeInfo: TeleporterFeeInfo(invalidFeeAsset, feeAmount), requiredGasLimit: DEFAULT_REQUIRED_GAS_LIMIT, @@ -163,7 +163,7 @@ contract SendCrossChainMessageTest is TeleporterMessengerTest { function testFeeTransferFailure() public { uint256 feeAmount = 4567; TeleporterMessageInput memory messageInput = TeleporterMessageInput({ - destinationChainID: DEFAULT_DESTINATION_CHAIN_ID, + destinationBlockchainID: DEFAULT_DESTINATION_CHAIN_ID, destinationAddress: DEFAULT_DESTINATION_ADDRESS, feeInfo: TeleporterFeeInfo(address(_mockFeeAsset), feeAmount), requiredGasLimit: DEFAULT_REQUIRED_GAS_LIMIT, @@ -194,7 +194,7 @@ contract SendCrossChainMessageTest is TeleporterMessengerTest { address invalidFeeAsset = address(0); uint256 feeAmount = 4567; TeleporterMessageInput memory messageInput = TeleporterMessageInput({ - destinationChainID: DEFAULT_DESTINATION_CHAIN_ID, + destinationBlockchainID: DEFAULT_DESTINATION_CHAIN_ID, destinationAddress: DEFAULT_DESTINATION_ADDRESS, feeInfo: TeleporterFeeInfo(invalidFeeAsset, feeAmount), requiredGasLimit: DEFAULT_REQUIRED_GAS_LIMIT, diff --git a/contracts/src/Teleporter/tests/SendSpecifiedReceiptsTests.t.sol b/contracts/src/Teleporter/tests/SendSpecifiedReceiptsTests.t.sol index 247eee942..0dd092d08 100644 --- a/contracts/src/Teleporter/tests/SendSpecifiedReceiptsTests.t.sol +++ b/contracts/src/Teleporter/tests/SendSpecifiedReceiptsTests.t.sol @@ -42,7 +42,7 @@ contract SendSpecifiedReceiptsTest is TeleporterMessengerTest { TeleporterMessage memory expectedMessage = TeleporterMessage({ messageID: 1, senderAddress: address(this), - destinationChainID: DEFAULT_DESTINATION_CHAIN_ID, + destinationBlockchainID: DEFAULT_DESTINATION_CHAIN_ID, destinationAddress: DEFAULT_DESTINATION_ADDRESS, requiredGasLimit: DEFAULT_REQUIRED_GAS_LIMIT, allowedRelayerAddresses: new address[](0), @@ -83,7 +83,7 @@ contract SendSpecifiedReceiptsTest is TeleporterMessengerTest { TeleporterMessage memory newExpectedMessage = TeleporterMessage({ messageID: 2, senderAddress: address(this), - destinationChainID: DEFAULT_DESTINATION_CHAIN_ID, + destinationBlockchainID: DEFAULT_DESTINATION_CHAIN_ID, destinationAddress: address(0), requiredGasLimit: uint256(0), allowedRelayerAddresses: new address[](0), @@ -134,7 +134,7 @@ contract SendSpecifiedReceiptsTest is TeleporterMessengerTest { TeleporterMessage memory expectedMessage = TeleporterMessage({ messageID: 1, senderAddress: address(this), - destinationChainID: DEFAULT_DESTINATION_CHAIN_ID, + destinationBlockchainID: DEFAULT_DESTINATION_CHAIN_ID, destinationAddress: address(0), requiredGasLimit: uint256(0), allowedRelayerAddresses: new address[](0), @@ -183,7 +183,7 @@ contract SendSpecifiedReceiptsTest is TeleporterMessengerTest { } function _sendSpecifiedReceiptsWithFee( - bytes32 chainID, + bytes32 blockchainID, uint256[] memory messageIDs, address feeAddress, uint256 feeAmount @@ -222,7 +222,7 @@ contract SendSpecifiedReceiptsTest is TeleporterMessengerTest { return teleporterMessenger.sendSpecifiedReceipts( - chainID, + blockchainID, messageIDs, feeInfo, new address[](0) @@ -230,10 +230,10 @@ contract SendSpecifiedReceiptsTest is TeleporterMessengerTest { } function _sendSpecifiedReceiptsWithNoFee( - bytes32 chainID, + bytes32 blockchainID, uint256[] memory messageIDs ) private returns (uint256) { return - _sendSpecifiedReceiptsWithFee(chainID, messageIDs, address(0), 0); + _sendSpecifiedReceiptsWithFee(blockchainID, messageIDs, address(0), 0); } } diff --git a/contracts/src/Teleporter/tests/TeleporterMessengerTest.t.sol b/contracts/src/Teleporter/tests/TeleporterMessengerTest.t.sol index 1b9ce1e74..10c748f29 100644 --- a/contracts/src/Teleporter/tests/TeleporterMessengerTest.t.sol +++ b/contracts/src/Teleporter/tests/TeleporterMessengerTest.t.sol @@ -35,20 +35,20 @@ contract TeleporterMessengerTest is Test { UnitTestMockERC20 internal _mockFeeAsset; event SendCrossChainMessage( - bytes32 indexed destinationChainID, + bytes32 indexed destinationBlockchainID, uint256 indexed messageID, TeleporterMessage message, TeleporterFeeInfo feeInfo ); event AddFeeAmount( - bytes32 indexed destinationChainID, + bytes32 indexed destinationBlockchainID, uint256 indexed messageID, TeleporterFeeInfo updatedFeeInfo ); event ReceiveCrossChainMessage( - bytes32 indexed originChainID, + bytes32 indexed originBlockchainID, uint256 indexed messageID, address indexed deliverer, address rewardRedeemer, @@ -56,18 +56,18 @@ contract TeleporterMessengerTest is Test { ); event MessageExecutionFailed( - bytes32 indexed originChainID, + bytes32 indexed originBlockchainID, uint256 indexed messageID, TeleporterMessage message ); event MessageExecuted( - bytes32 indexed originChainID, + bytes32 indexed originBlockchainID, uint256 indexed messageID ); event FailedFeePayment( - bytes32 indexed destinationChainID, + bytes32 indexed destinationBlockchainID, uint256 indexed messageID, address indexed feeAsset, uint256 feeAmount, @@ -115,7 +115,7 @@ contract TeleporterMessengerTest is Test { */ function _sendTestMessageWithFee( - bytes32 chainID, + bytes32 blockchainID, uint256 feeAmount ) internal returns (uint256) { vm.mockCall( @@ -134,7 +134,7 @@ contract TeleporterMessengerTest is Test { }); TeleporterMessageInput memory messageInput = TeleporterMessageInput({ - destinationChainID: chainID, + destinationBlockchainID: blockchainID, destinationAddress: DEFAULT_DESTINATION_ADDRESS, feeInfo: feeInfo, requiredGasLimit: DEFAULT_REQUIRED_GAS_LIMIT, @@ -157,9 +157,9 @@ contract TeleporterMessengerTest is Test { } function _sendTestMessageWithNoFee( - bytes32 chainID + bytes32 blockchainID ) internal returns (uint256) { - return _sendTestMessageWithFee(chainID, 0); + return _sendTestMessageWithFee(blockchainID, 0); } function _setUpSuccessGetVerifiedWarpMessageMock( @@ -178,7 +178,7 @@ contract TeleporterMessengerTest is Test { } function _receiveTestMessage( - bytes32 originChainID, + bytes32 originBlockchainID, uint256 messageID, address relayerRewardAddress, TeleporterMessageReceipt[] memory receipts @@ -194,7 +194,7 @@ contract TeleporterMessengerTest is Test { // Both the sender and destination address should be the teleporter contract address, // mocking as if the universal deployer pattern was used. WarpMessage memory warpMessage = _createDefaultWarpMessage( - originChainID, + originBlockchainID, abi.encode(messageToReceive) ); @@ -278,7 +278,7 @@ contract TeleporterMessengerTest is Test { TeleporterMessage({ messageID: messageID, senderAddress: address(this), - destinationChainID: DEFAULT_DESTINATION_CHAIN_ID, + destinationBlockchainID: DEFAULT_DESTINATION_CHAIN_ID, destinationAddress: DEFAULT_DESTINATION_ADDRESS, requiredGasLimit: DEFAULT_REQUIRED_GAS_LIMIT, allowedRelayerAddresses: new address[](0), @@ -288,12 +288,12 @@ contract TeleporterMessengerTest is Test { } function _createDefaultWarpMessage( - bytes32 originChainID, + bytes32 originBlockchainID, bytes memory payload ) internal view returns (WarpMessage memory) { return WarpMessage({ - sourceChainID: originChainID, + sourceChainID: originBlockchainID, originSenderAddress: address(teleporterMessenger), payload: payload }); diff --git a/contracts/src/Teleporter/upgrades/README.md b/contracts/src/Teleporter/upgrades/README.md index fd990e624..89f1b8e8d 100644 --- a/contracts/src/Teleporter/upgrades/README.md +++ b/contracts/src/Teleporter/upgrades/README.md @@ -10,8 +10,8 @@ The `TeleporterRegistry` maintains a mapping of `TeleporterMessenger` contract v - `sourceChainAddress` must match `VALIDATORS_SOURCE_ADDRESS = address(0)` - The zero address can only be set as the source chain address by a Warp off-chain message, and cannot be set by an on-chain Warp message. -- `sourceChainID` must match the blockchain ID that the registry is deployed on -- `destinationChainID` must match the blockchain ID that the registry is deployed on +- `sourceBlockchainID` must match the blockchain ID that the registry is deployed on +- `destinationBlockchainID` must match the blockchain ID that the registry is deployed on - `destinationAddress` must match the address of the registry In the `TeleporterRegistry` contract, the `latestVersion` state variable returns the highest version number that has been registered in the registry. The `getLatestTeleporter` function returns the `ITeleporterMessenger` that is registered with the corresponding version. @@ -41,7 +41,7 @@ contract ERC20Bridge is constructor( address teleporterRegistryAddress ) TeleporterUpgradeable(teleporterRegistryAddress) { - currentChainID = IWarpMessenger(WARP_PRECOMPILE_ADDRESS) + currentBlockchainID = IWarpMessenger(WARP_PRECOMPILE_ADDRESS) .getBlockchainID(); } ... diff --git a/docker/run_setup.sh b/docker/run_setup.sh index 10dc3f713..d47c487f5 100755 --- a/docker/run_setup.sh +++ b/docker/run_setup.sh @@ -167,14 +167,14 @@ if [ ! -e $dir_prefix/NETWORK_RUNNING ]; then cast send --private-key $user_private_key --value 500ether $relayer_address --rpc-url $c_chain_url echo "Sent ether to relayer account on each subnet." - subnet_a_chain_id_hex=$(getBlockChainIDHex $subnet_a_chain_id) - subnet_b_chain_id_hex=$(getBlockChainIDHex $subnet_b_chain_id) - subnet_c_chain_id_hex=$(getBlockChainIDHex $subnet_c_chain_id) - subnet_a_subnet_id_hex=$(getBlockChainIDHex $subnet_a_subnet_id) - subnet_b_subnet_id_hex=$(getBlockChainIDHex $subnet_b_subnet_id) - subnet_c_subnet_id_hex=$(getBlockChainIDHex $subnet_c_subnet_id) - c_chain_chain_id_hex=$(getBlockChainIDHex $c_chain_chain_id) - c_chain_subnet_id_hex=$(getBlockChainIDHex $c_chain_subnet_id) + subnet_a_chain_id_hex=$(getBlockchainIDHex $subnet_a_chain_id) + subnet_b_chain_id_hex=$(getBlockchainIDHex $subnet_b_chain_id) + subnet_c_chain_id_hex=$(getBlockchainIDHex $subnet_c_chain_id) + subnet_a_subnet_id_hex=$(getBlockchainIDHex $subnet_a_subnet_id) + subnet_b_subnet_id_hex=$(getBlockchainIDHex $subnet_b_subnet_id) + subnet_c_subnet_id_hex=$(getBlockchainIDHex $subnet_c_subnet_id) + c_chain_chain_id_hex=$(getBlockchainIDHex $c_chain_chain_id) + c_chain_subnet_id_hex=$(getBlockchainIDHex $c_chain_subnet_id) warp_messenger_precompile_addr=0x0200000000000000000000000000000000000005 # Write all vars to file so that they can be imported from another container diff --git a/scripts/local/integration-tests/erc20_bridge_multihop.sh b/scripts/local/integration-tests/erc20_bridge_multihop.sh index 11eea5241..481af3b97 100755 --- a/scripts/local/integration-tests/erc20_bridge_multihop.sh +++ b/scripts/local/integration-tests/erc20_bridge_multihop.sh @@ -142,7 +142,7 @@ echo "Sent a transaction to bridgeTokens from Subnet A to Subnet B." sleep 10 # Check that all the settings of the new bridge token are correct. -actual_native_chain_id=$(cast call $bridge_token_subnet_b_contract_address "nativeChainID()(bytes32)" --rpc-url $subnet_b_url) +actual_native_chain_id=$(cast call $bridge_token_subnet_b_contract_address "nativeBlockchainID()(bytes32)" --rpc-url $subnet_b_url) echo "Bridge token native chain ID: $actual_native_chain_id" actual_native_bridge=$(cast call $bridge_token_subnet_b_contract_address "nativeBridge()(address)" --rpc-url $subnet_b_url) echo "Bridge token native bridge address: $actual_native_bridge" diff --git a/scripts/utils.sh b/scripts/utils.sh index a0fbb9b00..fbdb469f2 100644 --- a/scripts/utils.sh +++ b/scripts/utils.sh @@ -2,7 +2,7 @@ # Copyright (C) 2023, Ava Labs, Inc. All rights reserved. # See the file LICENSE for licensing terms. -function getBlockChainIDHex() { +function getBlockchainIDHex() { python3 -c "import base58,sys; sys.stdout.write(base58.b58decode(b'$1').hex()[:-8])"; } diff --git a/tests/basic_one_way_send.go b/tests/basic_one_way_send.go index 3f5c8f9e1..fcaf8fb05 100644 --- a/tests/basic_one_way_send.go +++ b/tests/basic_one_way_send.go @@ -33,7 +33,7 @@ func BasicOneWaySend() { ctx := context.Background() sendCrossChainMessageInput := teleportermessenger.TeleporterMessageInput{ - DestinationChainID: subnetBInfo.BlockchainID, + DestinationBlockchainID: subnetBInfo.BlockchainID, DestinationAddress: fundedAddress, FeeInfo: teleportermessenger.TeleporterFeeInfo{ FeeTokenAddress: fundedAddress, @@ -45,14 +45,14 @@ func BasicOneWaySend() { } signedTx := utils.CreateSendCrossChainMessageTransaction(ctx, subnetAInfo, sendCrossChainMessageInput, fundedAddress, fundedKey, teleporterContractAddress) - log.Info("Sending Teleporter transaction on source chain", "destinationChainID", subnetBInfo.BlockchainID, "txHash", signedTx.Hash()) + log.Info("Sending Teleporter transaction on source chain", "destinationBlockchainID", subnetBInfo.BlockchainID, "txHash", signedTx.Hash()) receipt := utils.SendTransactionAndWaitForAcceptance(ctx, subnetAInfo.ChainWSClient, signedTx) bind, err := teleportermessenger.NewTeleporterMessenger(teleporterContractAddress, subnetAInfo.ChainWSClient) Expect(err).Should(BeNil()) event, err := utils.GetEventFromLogs(receipt.Logs, bind.ParseSendCrossChainMessage) Expect(err).Should(BeNil()) - Expect(event.DestinationChainID[:]).Should(Equal(subnetBInfo.BlockchainID[:])) + Expect(event.DestinationBlockchainID[:]).Should(Equal(subnetBInfo.BlockchainID[:])) teleporterMessageID = event.Message.MessageID diff --git a/tests/utils/utils.go b/tests/utils/utils.go index d637ef2fe..387b02b8c 100644 --- a/tests/utils/utils.go +++ b/tests/utils/utils.go @@ -278,7 +278,7 @@ func RelayMessage( // Check the transaction logs for the ReceiveCrossChainMessage event emitted by the Teleporter contract event, err := GetEventFromLogs(receipt.Logs, bind.ParseReceiveCrossChainMessage) Expect(err).Should(BeNil()) - Expect(event.OriginChainID[:]).Should(Equal(source.BlockchainID[:])) + Expect(event.OriginBlockchainID[:]).Should(Equal(source.BlockchainID[:])) return nil }