Proxy to execute the other contract calls. This contract is used when a user requests transfer with specific call of other contract.

Variables

DEBRIDGE_GATE_ROLE

bytes32 public constant DEBRIDGE_GATE_ROLE;
Role allowed to withdraw fee

submissionChainIdFrom

uint256 public submissionChainIdFrom;
Chain from which the current submission is received

submissionNativeSender

bytes public submissionNativeSender;
Native sender of the current submission

Functions

initialize

function initialize() public

call

function call(
    address _reserveAddress,
    address _receiver,
    bytes _data,
    uint256 _flags,
    bytes _nativeSender,
    uint256 _chainIdFrom
) external returns (bool _result)
Used for calls where native asset transfer is involved.

Parameters:

NameTypeDescription
_reserveAddressaddressReceiver of the tokens if the call to _receiver fails
_receiveraddressContract to be called
_databytesCall data
_flagsuint256Flags to change behavior; see Flags library for details
_nativeSenderbytesNative sender
_chainIdFromuint256Id of a chain that originated the request

callERC20

function callERC20(
    address _token,
    address _reserveAddress,
    address _receiver,
    bytes _data,
    uint256 _flags,
    bytes _nativeSender,
    uint256 _chainIdFrom
) external returns (bool _result)
Used for calls where ERC20 transfer is involved.

Parameters:

NameTypeDescription
_tokenaddressAsset address
_reserveAddressaddressReceiver of the tokens if the call to _receiver fails
_receiveraddressContract to be called
_databytesCall data
_flagsuint256Flags to change behavior; see Flags library for details
_nativeSenderbytesNative sender
_chainIdFromuint256Id of a chain that originated the request

externalCall

function externalCall(
    address destination,
    uint256 value,
    bytes data,
    bytes _nativeSender,
    uint256 _chainIdFrom,
    bool storeSender
) internal returns (bool result)

receive

function receive() external

version

function version() external returns (uint256)
Get this contract’s version