Skip to main content

IComptrollerable

Git Source

Contract module that provides a setter and getter for the Sablier Comptroller.

Functions

comptroller

Retrieves the address of the comptroller contract.

function comptroller() external view returns (ISablierComptroller);

setComptroller

Sets the comptroller to a new address.

Emits a SetComptroller event. Requirements:

  • msg.sender must be the current comptroller.
  • The new comptroller must return true from {supportsInterface} with the comptroller's minimal interface ID which is defined as the XOR of the following function selectors:
  1. {calculateMinFeeWeiFor}
  2. {convertUSDFeeToWei}
  3. {execute}
  4. {getMinFeeUSDFor}
function setComptroller(ISablierComptroller newComptroller) external;

Parameters

NameTypeDescription
newComptrollerISablierComptrollerThe address of the new comptroller contract.

transferFeesToComptroller

Transfers the fees to the comptroller contract.

Emits a TransferFeesToComptroller event._

function transferFeesToComptroller() external;

Events

SetComptroller

Emitted when the comptroller address is set by the admin.

event SetComptroller(ISablierComptroller oldComptroller, ISablierComptroller newComptroller);

TransferFeesToComptroller

Emitted when the fees are transferred to the comptroller contract.

event TransferFeesToComptroller(ISablierComptroller indexed comptroller, uint256 feeAmount);