EeseeAssetSpokeCCIP

EeseeAssetSpokeCCIP

supportsInterface

function supportsInterface(bytes4 interfaceId) public view returns (bool)

Inherited from CCIPCallerEeseeMessageInterface

Inherited from EeseeAssetSpokeBase

wrap

function wrap(struct Asset[] assets, struct Call[] crosschainCalls, address fallbackRecipient, bytes additionalData) external payable returns (uint256 gasPaid)

Wraps specified assets and sends them to {recipient} in the form of ERC1155 tokens.

Parameters

Name
Type
Description

assets

struct Asset[]

- Assets to wrap.

crosschainCalls

struct Call[]

- Calls to make on destination chain.

fallbackRecipient

address

- Address to transfer leftover tokens after crosschainCalls.

additionalData

bytes

- Additional information to pass to crosschain protocol.

Return Values

Name
Type
Description

gasPaid

uint256

- Gas paid for the crosschain call.

unstuck

function unstuck(bytes32 stuckAssetHash, address recipient) external returns (struct Asset asset)

_Reclaim assets that might have been stuck after unwrap. Emits Unstuck event. Note: Must be called from asset recipient address that had their asset stuck.

Parameters

Name
Type
Description

stuckAssetHash

bytes32

- Hash of the asset that got stuck.

recipient

address

- Address to transfer asset to.

Return Values

Name
Type
Description

asset

struct Asset

- Asset sent to {recipient}.

getTokenIdL2

function getTokenIdL2(struct Asset asset) external view returns (uint256)

Allows calculating token ID on L2 chain before wrapping.

Parameters

Name
Type
Description

asset

struct Asset

- Asset to calculate token Id for.

Return Values

Name
Type
Description

[0]

uint256

uint256 - Calculated token Id for wrapped asset on L2 chain.

getTokenIdL2

function getTokenIdL2(bytes32 assetHash) public view returns (uint256)

Allows calculating token ID on L2 chain before wrapping.

Parameters

Name
Type
Description

assetHash

bytes32

- Asset hash to calculate token Id for.

Return Values

Name
Type
Description

[0]

uint256

uint256 - Calculated token Id for wrapped asset on L2 chain.

getAssetHash

function getAssetHash(struct Asset asset) public pure returns (bytes32)

Calculates asset hash.

Parameters

Name
Type
Description

asset

struct Asset

- Asset to calculate asset hash for.

_transferAssetTo

function _transferAssetTo(bytes32 assetHash, uint256 amount, address to) external returns (struct Asset asset)

Stuck

event Stuck(struct Asset asset, bytes32 assetHash, address recipient, bytes err)

Unstuck

event Unstuck(struct Asset asset, bytes32 assetHash, address sender, address recipient)

Inherited from CCIPCaller

ccipReceive

function ccipReceive(struct Client.Any2EVMMessage message) external virtual

Called by the Router to deliver a message. If this reverts, any token transfers also revert. The message will move to a FAILED state and become available for manual execution.

Note ensure you check the msg.sender is the OffRampRouter

Parameters

Name
Type
Description

message

struct Client.Any2EVMMessage

CCIP Message

Inherited from EeseePausable

pause

function pause() external virtual

Called by the PAUSER_ROLE to pause, triggers stopped state.

unpause

function unpause() external virtual

Called by the PAUSER_ROLE to unpause, returns to normal state.

Inherited from EeseeRoleHandler

Inherited from Pausable

paused

function paused() public view virtual returns (bool)

Returns true if the contract is paused, and false otherwise.

Paused

event Paused(address account)

Emitted when the pause is triggered by account.

Unpaused

event Unpaused(address account)

Emitted when the pause is lifted by account.

Inherited from ERC1155Holder

onERC1155Received

function onERC1155Received(address, address, uint256, uint256, bytes) public virtual returns (bytes4)

onERC1155BatchReceived

function onERC1155BatchReceived(address, address, uint256[], uint256[], bytes) public virtual returns (bytes4)

Inherited from ICallerBase

CrosschainSend

event CrosschainSend(bytes32 projectIdentifier, struct AddressWithChain destination, bytes additionalData)

CrosschainReceive

event CrosschainReceive(bytes32 projectIdentifier, struct AddressWithChain source, bytes additionalData)

Inherited from ERC721Holder

onERC721Received

function onERC721Received(address, address, uint256, bytes) public virtual returns (bytes4)

_See {IERC721Receiver-onERC721Received}.

Always returns IERC721Receiver.onERC721Received.selector._

Inherited from ERC2771Context

isTrustedForwarder

function isTrustedForwarder(address forwarder) public view virtual returns (bool)

Inherited from IEeseeAssetSpoke

eeseeAssetHub

function eeseeAssetHub() external view returns (bytes chainSelector, address _address)

assetsStorage

function assetsStorage(bytes32) external view returns (address token, uint256 tokenID, uint256 amount, enum AssetType assetType, bytes data)

Wrap

event Wrap(struct Asset asset, bytes32 assetHash, address sender)

Unwrap

event Unwrap(struct Asset asset, bytes32 assetHash, address recipient)

Last updated