Skip to main content

ICCIPTokenPoolGetters

Git Source

Title: ICCIPTokenPoolGetters

The view surface of a Chainlink CCIP TokenPool (version 1.5.1).

Set-valued getters return the values of an enumerable set, whose order changes when entries are removed. Rate limiter states are projected to the current block timestamp before being returned, so the tokens and lastUpdated fields differ from storage. Getters for an unknown chain selector return empty values rather than reverting.

Functions​

owner​

Returns the owner of the pool.

function owner() external view returns (address owner_);

Returns

NameTypeDescription
owner_addressThe owner.

getToken​

Returns the token that the pool locks, burns, releases or mints.

function getToken() external view returns (address token);

Returns

NameTypeDescription
tokenaddressThe token.

getTokenDecimals​

Returns the decimals of the pool token on the local chain.

function getTokenDecimals() external view returns (uint8 decimals);

Returns

NameTypeDescription
decimalsuint8The token decimals.

getRmnProxy​

Returns the RMN proxy consulted for curses.

function getRmnProxy() external view returns (address rmnProxy);

Returns

NameTypeDescription
rmnProxyaddressThe RMN proxy.

getRouter​

Returns the router through which ramp authorization is resolved.

function getRouter() external view returns (address router);

Returns

NameTypeDescription
routeraddressThe router.

getRateLimitAdmin​

Returns the rate limit admin, or the zero address if none is set.

function getRateLimitAdmin() external view returns (address rateLimitAdmin);

Returns

NameTypeDescription
rateLimitAdminaddressThe rate limit admin.

isSupportedChain​

Returns whether a remote chain is configured on the pool.

function isSupportedChain(uint64 remoteChainSelector) external view returns (bool supported);

Parameters

NameTypeDescription
remoteChainSelectoruint64The chain selector of the remote chain.

Returns

NameTypeDescription
supportedboolTrue if the chain is configured.

getSupportedChains​

Returns the configured remote chain selectors.

function getSupportedChains() external view returns (uint64[] memory chainSelectors);

Returns

NameTypeDescription
chainSelectorsuint64[]The chain selectors.

getRemotePools​

Returns the accepted remote pools of a remote chain.

function getRemotePools(
uint64 remoteChainSelector
) external view returns (bytes[] memory remotePools);

Parameters

NameTypeDescription
remoteChainSelectoruint64The chain selector of the remote chain.

Returns

NameTypeDescription
remotePoolsbytes[]The remote pool addresses.

isRemotePool​

Returns whether a remote pool is accepted for a remote chain.

function isRemotePool(
uint64 remoteChainSelector,
bytes calldata remotePoolAddress
) external view returns (bool accepted);

Parameters

NameTypeDescription
remoteChainSelectoruint64The chain selector of the remote chain.
remotePoolAddressbytesThe remote pool address.

Returns

NameTypeDescription
acceptedboolTrue if the remote pool is accepted.

getRemoteToken​

Returns the token address on a remote chain.

function getRemoteToken(
uint64 remoteChainSelector
) external view returns (bytes memory remoteToken);

Parameters

NameTypeDescription
remoteChainSelectoruint64The chain selector of the remote chain.

Returns

NameTypeDescription
remoteTokenbytesThe remote token address.

getCurrentOutboundRateLimiterState​

Returns the outbound token bucket of a remote chain, projected to the current block timestamp.

function getCurrentOutboundRateLimiterState(
uint64 remoteChainSelector
) external view returns (ICCIPRateLimiter.TokenBucket memory bucket);

Parameters

NameTypeDescription
remoteChainSelectoruint64The chain selector of the remote chain.

Returns

NameTypeDescription
bucketICCIPRateLimiter.TokenBucketThe outbound token bucket.

getCurrentInboundRateLimiterState​

Returns the inbound token bucket of a remote chain, projected to the current block timestamp.

function getCurrentInboundRateLimiterState(
uint64 remoteChainSelector
) external view returns (ICCIPRateLimiter.TokenBucket memory bucket);

Parameters

NameTypeDescription
remoteChainSelectoruint64The chain selector of the remote chain.

Returns

NameTypeDescription
bucketICCIPRateLimiter.TokenBucketThe inbound token bucket.

getAllowListEnabled​

Returns whether the sender allowlist is enabled. The flag is fixed at pool construction.

function getAllowListEnabled() external view returns (bool enabled);

Returns

NameTypeDescription
enabledboolTrue if the allowlist is enabled.

getAllowList​

Returns the sender allowlist.

function getAllowList() external view returns (address[] memory allowList);

Returns

NameTypeDescription
allowListaddress[]The allowlisted addresses.

isSupportedToken​

Returns whether the pool supports a token.

function isSupportedToken(address token) external view returns (bool supported);

Parameters

NameTypeDescription
tokenaddressThe token.

Returns

NameTypeDescription
supportedboolTrue if the token is the pool token.