MaverickV2IncentiveMatcherFactory

Inherits: IMaverickV2IncentiveMatcherFactory

IncentiveMatcherFactory creates IncentiveMatcher contracts that can be used to facilitate voting on incentive directing and external protocol incentive matching for a given veToken.

IncentiveMatcher contracts are deployed with create2 to deterministic addresses can computed prior to deployment.

State Variables

incentiveMatcherParameters

IncentiveMatcherParameters public incentiveMatcherParameters;

incentiveMatcherForVe

This function retrieves the address of the IncentiveMatcher contract associated with the current veToken.

mapping(IMaverickV2VotingEscrow => IMaverickV2IncentiveMatcher) public override incentiveMatcherForVe;

isFactoryIncentiveMatcher

This function checks if the current contract is a factory contract for IncentiveMatchers.

mapping(IMaverickV2IncentiveMatcher => bool) public isFactoryIncentiveMatcher;

_allIncentiveMatcher

IMaverickV2IncentiveMatcher[] private _allIncentiveMatcher;

veFactory

This function retrieves the address of the MaverickV2VotingEscrowFactory contract.

IMaverickV2VotingEscrowFactory public immutable veFactory;

rewardFactory

This function retrieves the address of the MaverickV2RewardFactory contract.

IMaverickV2RewardFactory public immutable rewardFactory;

Functions

constructor

constructor(IMaverickV2VotingEscrowFactory _veFactory, IMaverickV2RewardFactory _rewardFactory);

createIncentiveMatcher

This function creates a new IncentiveMatcher contract for a given base token. The basetoken is required to have a deployed ve token before incentive matcher can be created. If no ve token exists, this function will revert. A ve token can be created with the ve token factory: veFactory().

function createIncentiveMatcher(IERC20 baseToken)
    public
    returns (IMaverickV2VotingEscrow veToken, IMaverickV2IncentiveMatcher incentiveMatcher);

Parameters

Returns

incentiveMatchers

This function retrieves a list of existing IncentiveMatcher contracts.

function incentiveMatchers(uint256 startIndex, uint256 endIndex)
    external
    view
    returns (IMaverickV2IncentiveMatcher[] memory returnElements);

Parameters

Returns

incentiveMatchersLength

This function returns the total number of existing IncentiveMatcher contracts.

function incentiveMatchersLength() external view returns (uint256);

incentiveMatcherAddress

This function retrieves the address of the IncentiveMatcher contract associated with a given veToken.

function incentiveMatcherAddress(IMaverickV2VotingEscrow veToken)
    public
    view
    returns (IMaverickV2IncentiveMatcher incentiveMatcher);

Parameters

Returns

Last updated