eWhitelist docs

EWhitelist

This contract has its own storage, which could potentially clash with pool storage if the allocated slot were already used by the implementation. Warning: careful with upgrades as pool only accesses isWhitelistedToken view method. Other methods are locked and should never be approved by governance.

_EWHITELIST_TOKEN_WHITELIST_SLOT

bytes32 _EWHITELIST_TOKEN_WHITELIST_SLOT

authority

address authority

WhitelistSlot

struct WhitelistSlot {
  mapping(address => bool) isWhitelisted;
}

onlyAuthorized

modifier onlyAuthorized()

constructor

constructor(address newAuthority) public

whitelistToken

function whitelistToken(address token) public

Allows a whitelister to whitelist a token.

Parameters

removeToken

function removeToken(address token) public

Allows a whitelister to remove a token.

Parameters

batchUpdateTokens

function batchUpdateTokens(address[] tokens, bool[] whitelisted) external

Allows a whitelister to whitelist/remove a list of tokens.

Parameters

isWhitelistedToken

function isWhitelistedToken(address token) external view returns (bool)

Returns whether a token has been whitelisted.

Parameters

Return Values

getAuthority

function getAuthority() public view returns (address)

Returns the address of the authority contract.

Return Values

_getWhitelistSlot

function _getWhitelistSlot() internal pure returns (struct EWhitelist.WhitelistSlot s)

_assertCallerIsAuthorized

function _assertCallerIsAuthorized() private view

_isContract

function _isContract(address target) private view returns (bool)

Last updated