BridgeFacet
Last updated
Last updated
This is a Solidity contract that implements the IBridge
interface. The contract has the following functions:
updates the settings of the Stargate bridge.
Input
Field | Type | Description |
---|---|---|
updates the settings of the Wormhole bridge.
Input
Field | Type | Description |
---|---|---|
The updateStargateSettings
and updateWormholeBridgeSettings
functions enforce that only the contract owner can call them, using the enforceIsContractOwner
function from the LibDiamond library.
It's a way to update and manage the settings associated with the Celer Bridge, and its execution is permissioned for the contract owner.
Input
Field | Type | Description |
---|---|---|
The function is responsible for updating the contract's settings related to chain IDs. It utilizes a modular approach where logic for handling chain IDs is encapsulated in the LibCeler
library. The ownership check at the beginning guarantees that only the contract owner can execute this function.
Input
This function is responsible for adding Magpie Celer bridge addresses to the contract's settings, associating them with specific network IDs.
Input
This function is responsible for adding the given bridge addresses to the corresponding network IDs.
Input
This function is responsible for adding the given bridge addresses to the corresponding network IDs.
Input
This function takes a uint64
parameter tokenSequence
and returns a uint64
. It calls the getTokenSequence
function from the LibWormhole
library, passing the tokenSequence
as an argument. The purpose of this function is to retrieve and return a transformed version of the tokenSequence
using the LibWormhole
library.
Input:
Output:
This function takes a BridgeInArgs
struct as a calldata
parameter and does not return a value. It overrides a function declared in an interface or parent contract. It calls the bridgeIn
function from the LibBridge
library, passing the bridgeInArgs
as an argument.
Input:
This function takes a BridgeOutArgs
struct as a calldata
parameter and returns a uint256
value. It overrides a function declared in an interface or parent contract. It calls the bridgeOut
function from the LibBridge
library, passing the bridgeOutArgs
as an argument.
Input:
Field | Type | Description |
---|---|---|
Field | Type | Description |
---|---|---|
Field | Type | Description |
---|---|---|
Field | Type | Description |
---|---|---|
Field | Type | Description |
---|---|---|
Field | Type | Description |
---|---|---|
Field | Type | Description |
---|---|---|
Field | Type | Description |
---|---|---|
The token sequence receiver from wormhole.
An array containing identifiers for networks.
An array containing chain identifiers corresponding to the networks in networkIds
.
An array containing identifiers for networks.
An array of bytes32
values representing Magpie Celer Bridge addresses.
An array of identifier defined by the magpie team for each network
An array of magpieStargateBridge addresses for each network in the form of bytes32
An array of identifier defined by the magpie team for each network
An array of magpieStargateBridge addresses for each network in the form of bytes32
The token sequence defined by magpie