EverclearBridge

Git Source

Inherits: BaseBridge, IBridge

State Variables

everclearFeeAdapter

IFeeAdapter public everclearFeeAdapter;

Functions

constructor

constructor(address _roles, address _feeAdapter) BaseBridge(_roles);

getFee

computes fee for bridge operation

function getFee(uint32, bytes memory, bytes memory) external pure returns (uint256);

Parameters

NameTypeDescription
<none>uint32
<none>bytes
<none>bytes

sendMsg

function sendMsg(
    uint256 _extractedAmount,
    address _market,
    uint32 _dstChainId,
    address _token,
    bytes memory _message,
    bytes memory
) external payable onlyRebalancer;

_decodeIntent

function _decodeIntent(bytes memory message) internal pure returns (IntentParams memory);

Events

MsgSent

event MsgSent(uint256 indexed dstChainId, address indexed market, uint256 amountLD, bytes32 id);

RebalancingReturnedToMarket

event RebalancingReturnedToMarket(address indexed market, uint256 toReturn, uint256 extracted);

Errors

Everclear_TokenMismatch

error Everclear_TokenMismatch();

Everclear_NotImplemented

error Everclear_NotImplemented();

Everclear_AddressNotValid

error Everclear_AddressNotValid();

Everclear_DestinationNotValid

error Everclear_DestinationNotValid();

Everclear_DestinationsLengthMismatch

error Everclear_DestinationsLengthMismatch();

Structs

IntentParams

struct IntentParams {
    uint32[] destinations;
    bytes32 receiver;
    address inputAsset;
    bytes32 outputAsset;
    uint256 amount;
    uint24 maxFee;
    uint48 ttl;
    bytes data;
    IFeeAdapter.FeeParams feeParams;
}