ReserveContractAuth
Inherits:Variables, Error, Events
Functions
validAddress
validates that an address is not the zero address
modifier validAddress(address value_);
onlyAuth
Checks that the sender is an auth
modifier onlyAuth();
updateAuth
Updates an auth's status as an auth
function updateAuth(address auth_, bool isAuth_) external onlyOwner validAddress(auth_);
Parameters
Name | Type | Description |
---|---|---|
auth_ | address | The address to update |
isAuth_ | bool | Whether or not the address should be an auth |
updateRebalancer
Updates a rebalancer's status as a rebalancer
function updateRebalancer(address rebalancer_, bool isRebalancer_) external onlyAuth validAddress(rebalancer_);
Parameters
Name | Type | Description |
---|---|---|
rebalancer_ | address | The address to update |
isRebalancer_ | bool | Whether or not the address should be a rebalancer |
approve
Approves protocols to spend the reserves tokens
The parameters are parallel arrays
function approve(address[] memory protocols_, address[] memory tokens_, uint256[] memory amounts_) external onlyAuth;
Parameters
Name | Type | Description |
---|---|---|
protocols_ | address[] | The protocols that will be spending reserve tokens |
tokens_ | address[] | The tokens to approve |
amounts_ | uint256[] | The amounts to approve |
revoke
Revokes protocols' ability to spend the reserves tokens
The parameters are parallel arrays
function revoke(address[] memory protocols_, address[] memory tokens_) external onlyAuth;
Parameters
Name | Type | Description |
---|---|---|
protocols_ | address[] | The protocols that will no longer be spending reserve tokens |
tokens_ | address[] | The tokens to revoke |