IWorldContextConsumer
Git Source (opens in a new tab)
Inherits: IERC165
This contract is designed to extract trusted context values (like msg.sender and msg.value) from the appended calldata. It provides mechanisms similar to EIP-2771 (https://eips.ethereum.org/EIPS/eip-2771 (opens in a new tab)), but allowing any contract to be the trusted forwarder.
World Context Consumer Interface This interface defines the functions a contract needs to consume the world context. It includes helper functions to retrieve the message sender, value, and world address. Additionally, it integrates with the ERC-165 standard for interface detection.
This contract should only be used for contracts without their own storage, like Systems.
Functions
_msgSender
Extract the msg.sender
from the context appended to the calldata.
function _msgSender() external view returns (address);
Returns
Name | Type | Description |
---|---|---|
<none> | address | The address of the msg.sender that called the World contract before the World routed the call to the WorldContextConsumer contract. |
_msgValue
Extract the msg.value
from the context appended to the calldata.
function _msgValue() external view returns (uint256);
Returns
Name | Type | Description |
---|---|---|
<none> | uint256 | The msg.value in the call to the World contract before the World routed the call to the WorldContextConsumer contract. |
_world
Get the address of the World contract that routed the call to this WorldContextConsumer.
function _world() external view returns (address);
Returns
Name | Type | Description |
---|---|---|
<none> | address | The address of the World contract that routed the call to this WorldContextConsumer. |