L2 Message Receiver
L2MessageReceiver.sol
is an implementation of the ILayerZeroReceiver
interface used to receive messages via LayerZero. It receives instructions to mint MOR tokens (e.g. to Capital Providers) from L1Sender
on Ethereum.
Variables
Name | Type | Description |
---|---|---|
| address | The address of the wrapped reward token (wstETH) on Arbitrum. |
| Config | Configuration data for LayerZero messaging. |
Functions
lzReceive
Mints MOR tokens according to instructions sent by L1Sender
via LayerZero. This function is blocking.
Parameters:
Name | Type | Description |
---|---|---|
| uint16 | The LayerZero |
| bytes | Concatenated addresses of the sender |
| uint64 | Nonce of the message. |
| bytes | Minting instructions sent by |
nonblockingLzReceive
Mints MOR tokens according to instructions sent by L1Sender
via LayerZero. This function is non-blocking.
Parameters:
Name | Type | Description |
---|---|---|
| uint16 | The LayerZero |
| bytes | Concatenated addresses of the sender |
| bytes | Minting instructions sent by |
retryMessage
Retries the processing of a previously failed message.
Parameters
Name | Type | Description |
---|---|---|
| uint16 | The LayerZero |
| bytes | Concatenated addresses of the sender |
| uint64 | Nonce of the failed message. |
| bytes | Minting instructions sent by |
L2MessageReceiver__init
Initializes the contract for ownership and upgradeability.
setParams
Sets the parameters of the contract, including the address of the wrapped reward token (wstETH) on Arbitrum and LayerZero configuration settings.
Parameters:
Name | Type | Description |
---|---|---|
| address | The address of the wrapped reward token on Arbitrum. |
| Config | Config struct containing various parameters. |
Structs
Config
Configuration data for LayerZero messaging.
Fields
Name | Type | Description |
---|---|---|
| address | The address of the LayerZero gateway on Arbitrum. |
| address | The address of |
| uint16 | The LayerZero |
Last updated
Was this helpful?