diff --git a/.github/workflows/deploy-local.yml b/.github/workflows/deploy-local.yml index 8575645f6..33b29c10a 100644 --- a/.github/workflows/deploy-local.yml +++ b/.github/workflows/deploy-local.yml @@ -42,7 +42,7 @@ jobs: export RPC_URL="http://127.0.0.1:8545" echo "Extracted PRIVATE_KEY: $PRIVATE_KEY" echo "---Deploying Contracts" - RUST_LOG=forge,foundry=trace forge script script/deploy/local/Deploy_From_Scratch.s.sol \ + RUST_LOG=forge,foundry=trace forge script script/deploy/local/Deploy_From_Scratch.s.sol --slow \ --rpc-url $RPC_URL \ --private-key "0xac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80" \ --broadcast \ diff --git a/docs/storage-report/BackingEigen.md b/docs/storage-report/BackingEigen.md index 14adcdc6e..648f111b2 100644 --- a/docs/storage-report/BackingEigen.md +++ b/docs/storage-report/BackingEigen.md @@ -26,3 +26,4 @@ | transferRestrictionsDisabledAfter | uint256 | 304 | 0 | 32 | src/contracts/token/BackingEigen.sol:BackingEigen | | allowedFrom | mapping(address => bool) | 305 | 0 | 32 | src/contracts/token/BackingEigen.sol:BackingEigen | | allowedTo | mapping(address => bool) | 306 | 0 | 32 | src/contracts/token/BackingEigen.sol:BackingEigen | +| isMinter | mapping(address => bool) | 307 | 0 | 32 | src/contracts/token/BackingEigen.sol:BackingEigen | diff --git a/docs/storage-report/RewardsCoordinator.md b/docs/storage-report/RewardsCoordinator.md index c3ac38649..7b39dec3c 100644 --- a/docs/storage-report/RewardsCoordinator.md +++ b/docs/storage-report/RewardsCoordinator.md @@ -1,26 +1,29 @@ -| Name | Type | Slot | Offset | Bytes | Contract | -|--------------------------------------|---------------------------------------------------------|------|--------|-------|--------------------------------------------------------------| -| _initialized | uint8 | 0 | 0 | 1 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | -| _initializing | bool | 0 | 1 | 1 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | -| __gap | uint256[50] | 1 | 0 | 1600 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | -| _owner | address | 51 | 0 | 20 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | -| __gap | uint256[49] | 52 | 0 | 1568 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | -| pauserRegistry | contract IPauserRegistry | 101 | 0 | 20 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | -| _paused | uint256 | 102 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | -| __gap | uint256[48] | 103 | 0 | 1536 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | -| _status | uint256 | 151 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | -| __gap | uint256[49] | 152 | 0 | 1568 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | -| _DOMAIN_SEPARATOR | bytes32 | 201 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | -| _distributionRoots | struct IRewardsCoordinator.DistributionRoot[] | 202 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | -| rewardsUpdater | address | 203 | 0 | 20 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | -| activationDelay | uint32 | 203 | 20 | 4 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | -| currRewardsCalculationEndTimestamp | uint32 | 203 | 24 | 4 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | -| globalOperatorCommissionBips | uint16 | 203 | 28 | 2 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | -| claimerFor | mapping(address => address) | 204 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | -| cumulativeClaimed | mapping(address => mapping(contract IERC20 => uint256)) | 205 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | -| submissionNonce | mapping(address => uint256) | 206 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | -| isAVSRewardsSubmissionHash | mapping(address => mapping(bytes32 => bool)) | 207 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | -| isRewardsSubmissionForAllHash | mapping(address => mapping(bytes32 => bool)) | 208 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | -| isRewardsForAllSubmitter | mapping(address => bool) | 209 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | -| isRewardsSubmissionForAllEarnersHash | mapping(address => mapping(bytes32 => bool)) | 210 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | -| __gap | uint256[39] | 211 | 0 | 1248 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| Name | Type | Slot | Offset | Bytes | Contract | +|--------------------------------------------|----------------------------------------------------------------------------------|------|--------|-------|--------------------------------------------------------------| +| _initialized | uint8 | 0 | 0 | 1 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| _initializing | bool | 0 | 1 | 1 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| __gap | uint256[50] | 1 | 0 | 1600 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| _owner | address | 51 | 0 | 20 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| __gap | uint256[49] | 52 | 0 | 1568 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| pauserRegistry | contract IPauserRegistry | 101 | 0 | 20 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| _paused | uint256 | 102 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| __gap | uint256[48] | 103 | 0 | 1536 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| _status | uint256 | 151 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| __gap | uint256[49] | 152 | 0 | 1568 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| _DOMAIN_SEPARATOR | bytes32 | 201 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| _distributionRoots | struct IRewardsCoordinator.DistributionRoot[] | 202 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| rewardsUpdater | address | 203 | 0 | 20 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| activationDelay | uint32 | 203 | 20 | 4 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| currRewardsCalculationEndTimestamp | uint32 | 203 | 24 | 4 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| defaultOperatorSplitBips | uint16 | 203 | 28 | 2 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| claimerFor | mapping(address => address) | 204 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| cumulativeClaimed | mapping(address => mapping(contract IERC20 => uint256)) | 205 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| submissionNonce | mapping(address => uint256) | 206 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| isAVSRewardsSubmissionHash | mapping(address => mapping(bytes32 => bool)) | 207 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| isRewardsSubmissionForAllHash | mapping(address => mapping(bytes32 => bool)) | 208 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| isRewardsForAllSubmitter | mapping(address => bool) | 209 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| isRewardsSubmissionForAllEarnersHash | mapping(address => mapping(bytes32 => bool)) | 210 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| isOperatorDirectedAVSRewardsSubmissionHash | mapping(address => mapping(bytes32 => bool)) | 211 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| operatorAVSSplitBips | mapping(address => mapping(address => struct IRewardsCoordinator.OperatorSplit)) | 212 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| operatorPISplitBips | mapping(address => struct IRewardsCoordinator.OperatorSplit) | 213 | 0 | 32 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | +| __gap | uint256[37] | 214 | 0 | 1184 | src/contracts/core/RewardsCoordinator.sol:RewardsCoordinator | diff --git a/docs/storage-report/RewardsCoordinatorStorage.md b/docs/storage-report/RewardsCoordinatorStorage.md index e5f8f26bc..463c08bc1 100644 --- a/docs/storage-report/RewardsCoordinatorStorage.md +++ b/docs/storage-report/RewardsCoordinatorStorage.md @@ -1,16 +1,19 @@ -| Name | Type | Slot | Offset | Bytes | Contract | -|--------------------------------------|---------------------------------------------------------|------|--------|-------|----------------------------------------------------------------------------| -| _DOMAIN_SEPARATOR | bytes32 | 0 | 0 | 32 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | -| _distributionRoots | struct IRewardsCoordinator.DistributionRoot[] | 1 | 0 | 32 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | -| rewardsUpdater | address | 2 | 0 | 20 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | -| activationDelay | uint32 | 2 | 20 | 4 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | -| currRewardsCalculationEndTimestamp | uint32 | 2 | 24 | 4 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | -| globalOperatorCommissionBips | uint16 | 2 | 28 | 2 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | -| claimerFor | mapping(address => address) | 3 | 0 | 32 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | -| cumulativeClaimed | mapping(address => mapping(contract IERC20 => uint256)) | 4 | 0 | 32 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | -| submissionNonce | mapping(address => uint256) | 5 | 0 | 32 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | -| isAVSRewardsSubmissionHash | mapping(address => mapping(bytes32 => bool)) | 6 | 0 | 32 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | -| isRewardsSubmissionForAllHash | mapping(address => mapping(bytes32 => bool)) | 7 | 0 | 32 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | -| isRewardsForAllSubmitter | mapping(address => bool) | 8 | 0 | 32 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | -| isRewardsSubmissionForAllEarnersHash | mapping(address => mapping(bytes32 => bool)) | 9 | 0 | 32 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | -| __gap | uint256[39] | 10 | 0 | 1248 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | +| Name | Type | Slot | Offset | Bytes | Contract | +|--------------------------------------------|----------------------------------------------------------------------------------|------|--------|-------|----------------------------------------------------------------------------| +| _DOMAIN_SEPARATOR | bytes32 | 0 | 0 | 32 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | +| _distributionRoots | struct IRewardsCoordinator.DistributionRoot[] | 1 | 0 | 32 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | +| rewardsUpdater | address | 2 | 0 | 20 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | +| activationDelay | uint32 | 2 | 20 | 4 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | +| currRewardsCalculationEndTimestamp | uint32 | 2 | 24 | 4 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | +| defaultOperatorSplitBips | uint16 | 2 | 28 | 2 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | +| claimerFor | mapping(address => address) | 3 | 0 | 32 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | +| cumulativeClaimed | mapping(address => mapping(contract IERC20 => uint256)) | 4 | 0 | 32 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | +| submissionNonce | mapping(address => uint256) | 5 | 0 | 32 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | +| isAVSRewardsSubmissionHash | mapping(address => mapping(bytes32 => bool)) | 6 | 0 | 32 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | +| isRewardsSubmissionForAllHash | mapping(address => mapping(bytes32 => bool)) | 7 | 0 | 32 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | +| isRewardsForAllSubmitter | mapping(address => bool) | 8 | 0 | 32 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | +| isRewardsSubmissionForAllEarnersHash | mapping(address => mapping(bytes32 => bool)) | 9 | 0 | 32 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | +| isOperatorDirectedAVSRewardsSubmissionHash | mapping(address => mapping(bytes32 => bool)) | 10 | 0 | 32 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | +| operatorAVSSplitBips | mapping(address => mapping(address => struct IRewardsCoordinator.OperatorSplit)) | 11 | 0 | 32 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | +| operatorPISplitBips | mapping(address => struct IRewardsCoordinator.OperatorSplit) | 12 | 0 | 32 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | +| __gap | uint256[37] | 13 | 0 | 1184 | src/contracts/core/RewardsCoordinatorStorage.sol:RewardsCoordinatorStorage | diff --git a/pkg/bindings/IRewardsCoordinator/binding.go b/pkg/bindings/IRewardsCoordinator/binding.go index 253371411..be0e62f80 100644 --- a/pkg/bindings/IRewardsCoordinator/binding.go +++ b/pkg/bindings/IRewardsCoordinator/binding.go @@ -43,6 +43,22 @@ type IRewardsCoordinatorEarnerTreeMerkleLeaf struct { EarnerTokenRoot [32]byte } +// IRewardsCoordinatorOperatorDirectedRewardsSubmission is an auto generated low-level Go binding around an user-defined struct. +type IRewardsCoordinatorOperatorDirectedRewardsSubmission struct { + StrategiesAndMultipliers []IRewardsCoordinatorStrategyAndMultiplier + Token common.Address + OperatorRewards []IRewardsCoordinatorOperatorReward + StartTimestamp uint32 + Duration uint32 + Description string +} + +// IRewardsCoordinatorOperatorReward is an auto generated low-level Go binding around an user-defined struct. +type IRewardsCoordinatorOperatorReward struct { + Operator common.Address + Amount *big.Int +} + // IRewardsCoordinatorRewardsMerkleClaim is an auto generated low-level Go binding around an user-defined struct. type IRewardsCoordinatorRewardsMerkleClaim struct { RootIndex uint32 @@ -77,7 +93,7 @@ type IRewardsCoordinatorTokenTreeMerkleLeaf struct { // IRewardsCoordinatorMetaData contains all meta data concerning the IRewardsCoordinator contract. var IRewardsCoordinatorMetaData = &bind.MetaData{ - ABI: "[{\"type\":\"function\",\"name\":\"CALCULATION_INTERVAL_SECONDS\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"GENESIS_REWARDS_TIMESTAMP\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"MAX_FUTURE_LENGTH\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"MAX_RETROACTIVE_LENGTH\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"MAX_REWARDS_DURATION\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"activationDelay\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"calculateEarnerLeafHash\",\"inputs\":[{\"name\":\"leaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.EarnerTreeMerkleLeaf\",\"components\":[{\"name\":\"earner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"earnerTokenRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"pure\"},{\"type\":\"function\",\"name\":\"calculateTokenLeafHash\",\"inputs\":[{\"name\":\"leaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.TokenTreeMerkleLeaf\",\"components\":[{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"cumulativeEarnings\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"pure\"},{\"type\":\"function\",\"name\":\"checkClaim\",\"inputs\":[{\"name\":\"claim\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.RewardsMerkleClaim\",\"components\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerTreeProof\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"earnerLeaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.EarnerTreeMerkleLeaf\",\"components\":[{\"name\":\"earner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"earnerTokenRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]},{\"name\":\"tokenIndices\",\"type\":\"uint32[]\",\"internalType\":\"uint32[]\"},{\"name\":\"tokenTreeProofs\",\"type\":\"bytes[]\",\"internalType\":\"bytes[]\"},{\"name\":\"tokenLeaves\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.TokenTreeMerkleLeaf[]\",\"components\":[{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"cumulativeEarnings\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]}]}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"claimerFor\",\"inputs\":[{\"name\":\"earner\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"createAVSRewardsSubmission\",\"inputs\":[{\"name\":\"rewardsSubmissions\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.RewardsSubmission[]\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"createRewardsForAllEarners\",\"inputs\":[{\"name\":\"rewardsSubmissions\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.RewardsSubmission[]\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"createRewardsForAllSubmission\",\"inputs\":[{\"name\":\"rewardsSubmission\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.RewardsSubmission[]\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"cumulativeClaimed\",\"inputs\":[{\"name\":\"claimer\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"currRewardsCalculationEndTimestamp\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"disableRoot\",\"inputs\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"domainSeparator\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getCurrentClaimableDistributionRoot\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.DistributionRoot\",\"components\":[{\"name\":\"root\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"disabled\",\"type\":\"bool\",\"internalType\":\"bool\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getCurrentDistributionRoot\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.DistributionRoot\",\"components\":[{\"name\":\"root\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"disabled\",\"type\":\"bool\",\"internalType\":\"bool\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getDistributionRootAtIndex\",\"inputs\":[{\"name\":\"index\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.DistributionRoot\",\"components\":[{\"name\":\"root\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"disabled\",\"type\":\"bool\",\"internalType\":\"bool\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getDistributionRootsLength\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getRootIndexFromHash\",\"inputs\":[{\"name\":\"rootHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"globalOperatorCommissionBips\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"operatorCommissionBips\",\"inputs\":[{\"name\":\"operator\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"avs\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"processClaim\",\"inputs\":[{\"name\":\"claim\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.RewardsMerkleClaim\",\"components\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerTreeProof\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"earnerLeaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.EarnerTreeMerkleLeaf\",\"components\":[{\"name\":\"earner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"earnerTokenRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]},{\"name\":\"tokenIndices\",\"type\":\"uint32[]\",\"internalType\":\"uint32[]\"},{\"name\":\"tokenTreeProofs\",\"type\":\"bytes[]\",\"internalType\":\"bytes[]\"},{\"name\":\"tokenLeaves\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.TokenTreeMerkleLeaf[]\",\"components\":[{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"cumulativeEarnings\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]}]},{\"name\":\"recipient\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"rewardsUpdater\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"setActivationDelay\",\"inputs\":[{\"name\":\"_activationDelay\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setClaimerFor\",\"inputs\":[{\"name\":\"claimer\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setGlobalOperatorCommission\",\"inputs\":[{\"name\":\"_globalCommissionBips\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setRewardsForAllSubmitter\",\"inputs\":[{\"name\":\"_submitter\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_newValue\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setRewardsUpdater\",\"inputs\":[{\"name\":\"_rewardsUpdater\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"submitRoot\",\"inputs\":[{\"name\":\"root\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"event\",\"name\":\"AVSRewardsSubmissionCreated\",\"inputs\":[{\"name\":\"avs\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"submissionNonce\",\"type\":\"uint256\",\"indexed\":true,\"internalType\":\"uint256\"},{\"name\":\"rewardsSubmissionHash\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"rewardsSubmission\",\"type\":\"tuple\",\"indexed\":false,\"internalType\":\"structIRewardsCoordinator.RewardsSubmission\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ActivationDelaySet\",\"inputs\":[{\"name\":\"oldActivationDelay\",\"type\":\"uint32\",\"indexed\":false,\"internalType\":\"uint32\"},{\"name\":\"newActivationDelay\",\"type\":\"uint32\",\"indexed\":false,\"internalType\":\"uint32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ClaimerForSet\",\"inputs\":[{\"name\":\"earner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"oldClaimer\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"claimer\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"DistributionRootDisabled\",\"inputs\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"indexed\":true,\"internalType\":\"uint32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"DistributionRootSubmitted\",\"inputs\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"indexed\":true,\"internalType\":\"uint32\"},{\"name\":\"root\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"indexed\":true,\"internalType\":\"uint32\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"indexed\":false,\"internalType\":\"uint32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"GlobalCommissionBipsSet\",\"inputs\":[{\"name\":\"oldGlobalCommissionBips\",\"type\":\"uint16\",\"indexed\":false,\"internalType\":\"uint16\"},{\"name\":\"newGlobalCommissionBips\",\"type\":\"uint16\",\"indexed\":false,\"internalType\":\"uint16\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsClaimed\",\"inputs\":[{\"name\":\"root\",\"type\":\"bytes32\",\"indexed\":false,\"internalType\":\"bytes32\"},{\"name\":\"earner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"claimer\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"token\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"contractIERC20\"},{\"name\":\"claimedAmount\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsForAllSubmitterSet\",\"inputs\":[{\"name\":\"rewardsForAllSubmitter\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"oldValue\",\"type\":\"bool\",\"indexed\":true,\"internalType\":\"bool\"},{\"name\":\"newValue\",\"type\":\"bool\",\"indexed\":true,\"internalType\":\"bool\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsSubmissionForAllCreated\",\"inputs\":[{\"name\":\"submitter\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"submissionNonce\",\"type\":\"uint256\",\"indexed\":true,\"internalType\":\"uint256\"},{\"name\":\"rewardsSubmissionHash\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"rewardsSubmission\",\"type\":\"tuple\",\"indexed\":false,\"internalType\":\"structIRewardsCoordinator.RewardsSubmission\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsSubmissionForAllEarnersCreated\",\"inputs\":[{\"name\":\"tokenHopper\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"submissionNonce\",\"type\":\"uint256\",\"indexed\":true,\"internalType\":\"uint256\"},{\"name\":\"rewardsSubmissionHash\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"rewardsSubmission\",\"type\":\"tuple\",\"indexed\":false,\"internalType\":\"structIRewardsCoordinator.RewardsSubmission\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsUpdaterSet\",\"inputs\":[{\"name\":\"oldRewardsUpdater\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newRewardsUpdater\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false}]", + ABI: "[{\"type\":\"function\",\"name\":\"CALCULATION_INTERVAL_SECONDS\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"GENESIS_REWARDS_TIMESTAMP\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"MAX_FUTURE_LENGTH\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"MAX_RETROACTIVE_LENGTH\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"MAX_REWARDS_DURATION\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"activationDelay\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"calculateEarnerLeafHash\",\"inputs\":[{\"name\":\"leaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.EarnerTreeMerkleLeaf\",\"components\":[{\"name\":\"earner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"earnerTokenRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"pure\"},{\"type\":\"function\",\"name\":\"calculateTokenLeafHash\",\"inputs\":[{\"name\":\"leaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.TokenTreeMerkleLeaf\",\"components\":[{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"cumulativeEarnings\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"pure\"},{\"type\":\"function\",\"name\":\"checkClaim\",\"inputs\":[{\"name\":\"claim\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.RewardsMerkleClaim\",\"components\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerTreeProof\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"earnerLeaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.EarnerTreeMerkleLeaf\",\"components\":[{\"name\":\"earner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"earnerTokenRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]},{\"name\":\"tokenIndices\",\"type\":\"uint32[]\",\"internalType\":\"uint32[]\"},{\"name\":\"tokenTreeProofs\",\"type\":\"bytes[]\",\"internalType\":\"bytes[]\"},{\"name\":\"tokenLeaves\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.TokenTreeMerkleLeaf[]\",\"components\":[{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"cumulativeEarnings\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]}]}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"claimerFor\",\"inputs\":[{\"name\":\"earner\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"createAVSRewardsSubmission\",\"inputs\":[{\"name\":\"rewardsSubmissions\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.RewardsSubmission[]\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"createOperatorDirectedAVSRewardsSubmission\",\"inputs\":[{\"name\":\"avs\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"operatorDirectedRewardsSubmissions\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.OperatorDirectedRewardsSubmission[]\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"operatorRewards\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.OperatorReward[]\",\"components\":[{\"name\":\"operator\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"description\",\"type\":\"string\",\"internalType\":\"string\"}]}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"createRewardsForAllEarners\",\"inputs\":[{\"name\":\"rewardsSubmissions\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.RewardsSubmission[]\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"createRewardsForAllSubmission\",\"inputs\":[{\"name\":\"rewardsSubmission\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.RewardsSubmission[]\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"cumulativeClaimed\",\"inputs\":[{\"name\":\"claimer\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"currRewardsCalculationEndTimestamp\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"defaultOperatorSplitBips\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"disableRoot\",\"inputs\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"domainSeparator\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getCurrentClaimableDistributionRoot\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.DistributionRoot\",\"components\":[{\"name\":\"root\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"disabled\",\"type\":\"bool\",\"internalType\":\"bool\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getCurrentDistributionRoot\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.DistributionRoot\",\"components\":[{\"name\":\"root\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"disabled\",\"type\":\"bool\",\"internalType\":\"bool\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getDistributionRootAtIndex\",\"inputs\":[{\"name\":\"index\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.DistributionRoot\",\"components\":[{\"name\":\"root\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"disabled\",\"type\":\"bool\",\"internalType\":\"bool\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getDistributionRootsLength\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getOperatorAVSSplit\",\"inputs\":[{\"name\":\"operator\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"avs\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getOperatorPISplit\",\"inputs\":[{\"name\":\"operator\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getRootIndexFromHash\",\"inputs\":[{\"name\":\"rootHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"processClaim\",\"inputs\":[{\"name\":\"claim\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.RewardsMerkleClaim\",\"components\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerTreeProof\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"earnerLeaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.EarnerTreeMerkleLeaf\",\"components\":[{\"name\":\"earner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"earnerTokenRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]},{\"name\":\"tokenIndices\",\"type\":\"uint32[]\",\"internalType\":\"uint32[]\"},{\"name\":\"tokenTreeProofs\",\"type\":\"bytes[]\",\"internalType\":\"bytes[]\"},{\"name\":\"tokenLeaves\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.TokenTreeMerkleLeaf[]\",\"components\":[{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"cumulativeEarnings\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]}]},{\"name\":\"recipient\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"processClaims\",\"inputs\":[{\"name\":\"claims\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.RewardsMerkleClaim[]\",\"components\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerTreeProof\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"earnerLeaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.EarnerTreeMerkleLeaf\",\"components\":[{\"name\":\"earner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"earnerTokenRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]},{\"name\":\"tokenIndices\",\"type\":\"uint32[]\",\"internalType\":\"uint32[]\"},{\"name\":\"tokenTreeProofs\",\"type\":\"bytes[]\",\"internalType\":\"bytes[]\"},{\"name\":\"tokenLeaves\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.TokenTreeMerkleLeaf[]\",\"components\":[{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"cumulativeEarnings\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]}]},{\"name\":\"recipient\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"rewardsUpdater\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"setActivationDelay\",\"inputs\":[{\"name\":\"_activationDelay\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setClaimerFor\",\"inputs\":[{\"name\":\"claimer\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setDefaultOperatorSplit\",\"inputs\":[{\"name\":\"split\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setOperatorAVSSplit\",\"inputs\":[{\"name\":\"operator\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"avs\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"split\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setOperatorPISplit\",\"inputs\":[{\"name\":\"operator\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"split\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setRewardsForAllSubmitter\",\"inputs\":[{\"name\":\"_submitter\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_newValue\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setRewardsUpdater\",\"inputs\":[{\"name\":\"_rewardsUpdater\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"submitRoot\",\"inputs\":[{\"name\":\"root\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"event\",\"name\":\"AVSRewardsSubmissionCreated\",\"inputs\":[{\"name\":\"avs\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"submissionNonce\",\"type\":\"uint256\",\"indexed\":true,\"internalType\":\"uint256\"},{\"name\":\"rewardsSubmissionHash\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"rewardsSubmission\",\"type\":\"tuple\",\"indexed\":false,\"internalType\":\"structIRewardsCoordinator.RewardsSubmission\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ActivationDelaySet\",\"inputs\":[{\"name\":\"oldActivationDelay\",\"type\":\"uint32\",\"indexed\":false,\"internalType\":\"uint32\"},{\"name\":\"newActivationDelay\",\"type\":\"uint32\",\"indexed\":false,\"internalType\":\"uint32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ClaimerForSet\",\"inputs\":[{\"name\":\"earner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"oldClaimer\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"claimer\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"DefaultOperatorSplitBipsSet\",\"inputs\":[{\"name\":\"oldDefaultOperatorSplitBips\",\"type\":\"uint16\",\"indexed\":false,\"internalType\":\"uint16\"},{\"name\":\"newDefaultOperatorSplitBips\",\"type\":\"uint16\",\"indexed\":false,\"internalType\":\"uint16\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"DistributionRootDisabled\",\"inputs\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"indexed\":true,\"internalType\":\"uint32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"DistributionRootSubmitted\",\"inputs\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"indexed\":true,\"internalType\":\"uint32\"},{\"name\":\"root\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"indexed\":true,\"internalType\":\"uint32\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"indexed\":false,\"internalType\":\"uint32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"OperatorAVSSplitBipsSet\",\"inputs\":[{\"name\":\"caller\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"operator\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"avs\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"indexed\":false,\"internalType\":\"uint32\"},{\"name\":\"oldOperatorAVSSplitBips\",\"type\":\"uint16\",\"indexed\":false,\"internalType\":\"uint16\"},{\"name\":\"newOperatorAVSSplitBips\",\"type\":\"uint16\",\"indexed\":false,\"internalType\":\"uint16\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"OperatorDirectedAVSRewardsSubmissionCreated\",\"inputs\":[{\"name\":\"caller\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"avs\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"operatorDirectedRewardsSubmissionHash\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"submissionNonce\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"operatorDirectedRewardsSubmission\",\"type\":\"tuple\",\"indexed\":false,\"internalType\":\"structIRewardsCoordinator.OperatorDirectedRewardsSubmission\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"operatorRewards\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.OperatorReward[]\",\"components\":[{\"name\":\"operator\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"description\",\"type\":\"string\",\"internalType\":\"string\"}]}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"OperatorPISplitBipsSet\",\"inputs\":[{\"name\":\"caller\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"operator\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"indexed\":false,\"internalType\":\"uint32\"},{\"name\":\"oldOperatorPISplitBips\",\"type\":\"uint16\",\"indexed\":false,\"internalType\":\"uint16\"},{\"name\":\"newOperatorPISplitBips\",\"type\":\"uint16\",\"indexed\":false,\"internalType\":\"uint16\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsClaimed\",\"inputs\":[{\"name\":\"root\",\"type\":\"bytes32\",\"indexed\":false,\"internalType\":\"bytes32\"},{\"name\":\"earner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"claimer\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"token\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"contractIERC20\"},{\"name\":\"claimedAmount\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsForAllSubmitterSet\",\"inputs\":[{\"name\":\"rewardsForAllSubmitter\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"oldValue\",\"type\":\"bool\",\"indexed\":true,\"internalType\":\"bool\"},{\"name\":\"newValue\",\"type\":\"bool\",\"indexed\":true,\"internalType\":\"bool\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsSubmissionForAllCreated\",\"inputs\":[{\"name\":\"submitter\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"submissionNonce\",\"type\":\"uint256\",\"indexed\":true,\"internalType\":\"uint256\"},{\"name\":\"rewardsSubmissionHash\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"rewardsSubmission\",\"type\":\"tuple\",\"indexed\":false,\"internalType\":\"structIRewardsCoordinator.RewardsSubmission\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsSubmissionForAllEarnersCreated\",\"inputs\":[{\"name\":\"tokenHopper\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"submissionNonce\",\"type\":\"uint256\",\"indexed\":true,\"internalType\":\"uint256\"},{\"name\":\"rewardsSubmissionHash\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"rewardsSubmission\",\"type\":\"tuple\",\"indexed\":false,\"internalType\":\"structIRewardsCoordinator.RewardsSubmission\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsUpdaterSet\",\"inputs\":[{\"name\":\"oldRewardsUpdater\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newRewardsUpdater\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false}]", } // IRewardsCoordinatorABI is the input ABI used to generate the binding from. @@ -598,6 +614,37 @@ func (_IRewardsCoordinator *IRewardsCoordinatorCallerSession) CurrRewardsCalcula return _IRewardsCoordinator.Contract.CurrRewardsCalculationEndTimestamp(&_IRewardsCoordinator.CallOpts) } +// DefaultOperatorSplitBips is a free data retrieval call binding the contract method 0x63f6a798. +// +// Solidity: function defaultOperatorSplitBips() view returns(uint16) +func (_IRewardsCoordinator *IRewardsCoordinatorCaller) DefaultOperatorSplitBips(opts *bind.CallOpts) (uint16, error) { + var out []interface{} + err := _IRewardsCoordinator.contract.Call(opts, &out, "defaultOperatorSplitBips") + + if err != nil { + return *new(uint16), err + } + + out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) + + return out0, err + +} + +// DefaultOperatorSplitBips is a free data retrieval call binding the contract method 0x63f6a798. +// +// Solidity: function defaultOperatorSplitBips() view returns(uint16) +func (_IRewardsCoordinator *IRewardsCoordinatorSession) DefaultOperatorSplitBips() (uint16, error) { + return _IRewardsCoordinator.Contract.DefaultOperatorSplitBips(&_IRewardsCoordinator.CallOpts) +} + +// DefaultOperatorSplitBips is a free data retrieval call binding the contract method 0x63f6a798. +// +// Solidity: function defaultOperatorSplitBips() view returns(uint16) +func (_IRewardsCoordinator *IRewardsCoordinatorCallerSession) DefaultOperatorSplitBips() (uint16, error) { + return _IRewardsCoordinator.Contract.DefaultOperatorSplitBips(&_IRewardsCoordinator.CallOpts) +} + // DomainSeparator is a free data retrieval call binding the contract method 0xf698da25. // // Solidity: function domainSeparator() view returns(bytes32) @@ -753,43 +800,43 @@ func (_IRewardsCoordinator *IRewardsCoordinatorCallerSession) GetDistributionRoo return _IRewardsCoordinator.Contract.GetDistributionRootsLength(&_IRewardsCoordinator.CallOpts) } -// GetRootIndexFromHash is a free data retrieval call binding the contract method 0xe810ce21. +// GetOperatorAVSSplit is a free data retrieval call binding the contract method 0xe063f81f. // -// Solidity: function getRootIndexFromHash(bytes32 rootHash) view returns(uint32) -func (_IRewardsCoordinator *IRewardsCoordinatorCaller) GetRootIndexFromHash(opts *bind.CallOpts, rootHash [32]byte) (uint32, error) { +// Solidity: function getOperatorAVSSplit(address operator, address avs) view returns(uint16) +func (_IRewardsCoordinator *IRewardsCoordinatorCaller) GetOperatorAVSSplit(opts *bind.CallOpts, operator common.Address, avs common.Address) (uint16, error) { var out []interface{} - err := _IRewardsCoordinator.contract.Call(opts, &out, "getRootIndexFromHash", rootHash) + err := _IRewardsCoordinator.contract.Call(opts, &out, "getOperatorAVSSplit", operator, avs) if err != nil { - return *new(uint32), err + return *new(uint16), err } - out0 := *abi.ConvertType(out[0], new(uint32)).(*uint32) + out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) return out0, err } -// GetRootIndexFromHash is a free data retrieval call binding the contract method 0xe810ce21. +// GetOperatorAVSSplit is a free data retrieval call binding the contract method 0xe063f81f. // -// Solidity: function getRootIndexFromHash(bytes32 rootHash) view returns(uint32) -func (_IRewardsCoordinator *IRewardsCoordinatorSession) GetRootIndexFromHash(rootHash [32]byte) (uint32, error) { - return _IRewardsCoordinator.Contract.GetRootIndexFromHash(&_IRewardsCoordinator.CallOpts, rootHash) +// Solidity: function getOperatorAVSSplit(address operator, address avs) view returns(uint16) +func (_IRewardsCoordinator *IRewardsCoordinatorSession) GetOperatorAVSSplit(operator common.Address, avs common.Address) (uint16, error) { + return _IRewardsCoordinator.Contract.GetOperatorAVSSplit(&_IRewardsCoordinator.CallOpts, operator, avs) } -// GetRootIndexFromHash is a free data retrieval call binding the contract method 0xe810ce21. +// GetOperatorAVSSplit is a free data retrieval call binding the contract method 0xe063f81f. // -// Solidity: function getRootIndexFromHash(bytes32 rootHash) view returns(uint32) -func (_IRewardsCoordinator *IRewardsCoordinatorCallerSession) GetRootIndexFromHash(rootHash [32]byte) (uint32, error) { - return _IRewardsCoordinator.Contract.GetRootIndexFromHash(&_IRewardsCoordinator.CallOpts, rootHash) +// Solidity: function getOperatorAVSSplit(address operator, address avs) view returns(uint16) +func (_IRewardsCoordinator *IRewardsCoordinatorCallerSession) GetOperatorAVSSplit(operator common.Address, avs common.Address) (uint16, error) { + return _IRewardsCoordinator.Contract.GetOperatorAVSSplit(&_IRewardsCoordinator.CallOpts, operator, avs) } -// GlobalOperatorCommissionBips is a free data retrieval call binding the contract method 0x092db007. +// GetOperatorPISplit is a free data retrieval call binding the contract method 0x4b943960. // -// Solidity: function globalOperatorCommissionBips() view returns(uint16) -func (_IRewardsCoordinator *IRewardsCoordinatorCaller) GlobalOperatorCommissionBips(opts *bind.CallOpts) (uint16, error) { +// Solidity: function getOperatorPISplit(address operator) view returns(uint16) +func (_IRewardsCoordinator *IRewardsCoordinatorCaller) GetOperatorPISplit(opts *bind.CallOpts, operator common.Address) (uint16, error) { var out []interface{} - err := _IRewardsCoordinator.contract.Call(opts, &out, "globalOperatorCommissionBips") + err := _IRewardsCoordinator.contract.Call(opts, &out, "getOperatorPISplit", operator) if err != nil { return *new(uint16), err @@ -801,49 +848,49 @@ func (_IRewardsCoordinator *IRewardsCoordinatorCaller) GlobalOperatorCommissionB } -// GlobalOperatorCommissionBips is a free data retrieval call binding the contract method 0x092db007. +// GetOperatorPISplit is a free data retrieval call binding the contract method 0x4b943960. // -// Solidity: function globalOperatorCommissionBips() view returns(uint16) -func (_IRewardsCoordinator *IRewardsCoordinatorSession) GlobalOperatorCommissionBips() (uint16, error) { - return _IRewardsCoordinator.Contract.GlobalOperatorCommissionBips(&_IRewardsCoordinator.CallOpts) +// Solidity: function getOperatorPISplit(address operator) view returns(uint16) +func (_IRewardsCoordinator *IRewardsCoordinatorSession) GetOperatorPISplit(operator common.Address) (uint16, error) { + return _IRewardsCoordinator.Contract.GetOperatorPISplit(&_IRewardsCoordinator.CallOpts, operator) } -// GlobalOperatorCommissionBips is a free data retrieval call binding the contract method 0x092db007. +// GetOperatorPISplit is a free data retrieval call binding the contract method 0x4b943960. // -// Solidity: function globalOperatorCommissionBips() view returns(uint16) -func (_IRewardsCoordinator *IRewardsCoordinatorCallerSession) GlobalOperatorCommissionBips() (uint16, error) { - return _IRewardsCoordinator.Contract.GlobalOperatorCommissionBips(&_IRewardsCoordinator.CallOpts) +// Solidity: function getOperatorPISplit(address operator) view returns(uint16) +func (_IRewardsCoordinator *IRewardsCoordinatorCallerSession) GetOperatorPISplit(operator common.Address) (uint16, error) { + return _IRewardsCoordinator.Contract.GetOperatorPISplit(&_IRewardsCoordinator.CallOpts, operator) } -// OperatorCommissionBips is a free data retrieval call binding the contract method 0x22f19a64. +// GetRootIndexFromHash is a free data retrieval call binding the contract method 0xe810ce21. // -// Solidity: function operatorCommissionBips(address operator, address avs) view returns(uint16) -func (_IRewardsCoordinator *IRewardsCoordinatorCaller) OperatorCommissionBips(opts *bind.CallOpts, operator common.Address, avs common.Address) (uint16, error) { +// Solidity: function getRootIndexFromHash(bytes32 rootHash) view returns(uint32) +func (_IRewardsCoordinator *IRewardsCoordinatorCaller) GetRootIndexFromHash(opts *bind.CallOpts, rootHash [32]byte) (uint32, error) { var out []interface{} - err := _IRewardsCoordinator.contract.Call(opts, &out, "operatorCommissionBips", operator, avs) + err := _IRewardsCoordinator.contract.Call(opts, &out, "getRootIndexFromHash", rootHash) if err != nil { - return *new(uint16), err + return *new(uint32), err } - out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) + out0 := *abi.ConvertType(out[0], new(uint32)).(*uint32) return out0, err } -// OperatorCommissionBips is a free data retrieval call binding the contract method 0x22f19a64. +// GetRootIndexFromHash is a free data retrieval call binding the contract method 0xe810ce21. // -// Solidity: function operatorCommissionBips(address operator, address avs) view returns(uint16) -func (_IRewardsCoordinator *IRewardsCoordinatorSession) OperatorCommissionBips(operator common.Address, avs common.Address) (uint16, error) { - return _IRewardsCoordinator.Contract.OperatorCommissionBips(&_IRewardsCoordinator.CallOpts, operator, avs) +// Solidity: function getRootIndexFromHash(bytes32 rootHash) view returns(uint32) +func (_IRewardsCoordinator *IRewardsCoordinatorSession) GetRootIndexFromHash(rootHash [32]byte) (uint32, error) { + return _IRewardsCoordinator.Contract.GetRootIndexFromHash(&_IRewardsCoordinator.CallOpts, rootHash) } -// OperatorCommissionBips is a free data retrieval call binding the contract method 0x22f19a64. +// GetRootIndexFromHash is a free data retrieval call binding the contract method 0xe810ce21. // -// Solidity: function operatorCommissionBips(address operator, address avs) view returns(uint16) -func (_IRewardsCoordinator *IRewardsCoordinatorCallerSession) OperatorCommissionBips(operator common.Address, avs common.Address) (uint16, error) { - return _IRewardsCoordinator.Contract.OperatorCommissionBips(&_IRewardsCoordinator.CallOpts, operator, avs) +// Solidity: function getRootIndexFromHash(bytes32 rootHash) view returns(uint32) +func (_IRewardsCoordinator *IRewardsCoordinatorCallerSession) GetRootIndexFromHash(rootHash [32]byte) (uint32, error) { + return _IRewardsCoordinator.Contract.GetRootIndexFromHash(&_IRewardsCoordinator.CallOpts, rootHash) } // RewardsUpdater is a free data retrieval call binding the contract method 0xfbf1e2c1. @@ -898,6 +945,27 @@ func (_IRewardsCoordinator *IRewardsCoordinatorTransactorSession) CreateAVSRewar return _IRewardsCoordinator.Contract.CreateAVSRewardsSubmission(&_IRewardsCoordinator.TransactOpts, rewardsSubmissions) } +// CreateOperatorDirectedAVSRewardsSubmission is a paid mutator transaction binding the contract method 0x9cb9a5fa. +// +// Solidity: function createOperatorDirectedAVSRewardsSubmission(address avs, ((address,uint96)[],address,(address,uint256)[],uint32,uint32,string)[] operatorDirectedRewardsSubmissions) returns() +func (_IRewardsCoordinator *IRewardsCoordinatorTransactor) CreateOperatorDirectedAVSRewardsSubmission(opts *bind.TransactOpts, avs common.Address, operatorDirectedRewardsSubmissions []IRewardsCoordinatorOperatorDirectedRewardsSubmission) (*types.Transaction, error) { + return _IRewardsCoordinator.contract.Transact(opts, "createOperatorDirectedAVSRewardsSubmission", avs, operatorDirectedRewardsSubmissions) +} + +// CreateOperatorDirectedAVSRewardsSubmission is a paid mutator transaction binding the contract method 0x9cb9a5fa. +// +// Solidity: function createOperatorDirectedAVSRewardsSubmission(address avs, ((address,uint96)[],address,(address,uint256)[],uint32,uint32,string)[] operatorDirectedRewardsSubmissions) returns() +func (_IRewardsCoordinator *IRewardsCoordinatorSession) CreateOperatorDirectedAVSRewardsSubmission(avs common.Address, operatorDirectedRewardsSubmissions []IRewardsCoordinatorOperatorDirectedRewardsSubmission) (*types.Transaction, error) { + return _IRewardsCoordinator.Contract.CreateOperatorDirectedAVSRewardsSubmission(&_IRewardsCoordinator.TransactOpts, avs, operatorDirectedRewardsSubmissions) +} + +// CreateOperatorDirectedAVSRewardsSubmission is a paid mutator transaction binding the contract method 0x9cb9a5fa. +// +// Solidity: function createOperatorDirectedAVSRewardsSubmission(address avs, ((address,uint96)[],address,(address,uint256)[],uint32,uint32,string)[] operatorDirectedRewardsSubmissions) returns() +func (_IRewardsCoordinator *IRewardsCoordinatorTransactorSession) CreateOperatorDirectedAVSRewardsSubmission(avs common.Address, operatorDirectedRewardsSubmissions []IRewardsCoordinatorOperatorDirectedRewardsSubmission) (*types.Transaction, error) { + return _IRewardsCoordinator.Contract.CreateOperatorDirectedAVSRewardsSubmission(&_IRewardsCoordinator.TransactOpts, avs, operatorDirectedRewardsSubmissions) +} + // CreateRewardsForAllEarners is a paid mutator transaction binding the contract method 0xff9f6cce. // // Solidity: function createRewardsForAllEarners(((address,uint96)[],address,uint256,uint32,uint32)[] rewardsSubmissions) returns() @@ -982,6 +1050,27 @@ func (_IRewardsCoordinator *IRewardsCoordinatorTransactorSession) ProcessClaim(c return _IRewardsCoordinator.Contract.ProcessClaim(&_IRewardsCoordinator.TransactOpts, claim, recipient) } +// ProcessClaims is a paid mutator transaction binding the contract method 0x4596021c. +// +// Solidity: function processClaims((uint32,uint32,bytes,(address,bytes32),uint32[],bytes[],(address,uint256)[])[] claims, address recipient) returns() +func (_IRewardsCoordinator *IRewardsCoordinatorTransactor) ProcessClaims(opts *bind.TransactOpts, claims []IRewardsCoordinatorRewardsMerkleClaim, recipient common.Address) (*types.Transaction, error) { + return _IRewardsCoordinator.contract.Transact(opts, "processClaims", claims, recipient) +} + +// ProcessClaims is a paid mutator transaction binding the contract method 0x4596021c. +// +// Solidity: function processClaims((uint32,uint32,bytes,(address,bytes32),uint32[],bytes[],(address,uint256)[])[] claims, address recipient) returns() +func (_IRewardsCoordinator *IRewardsCoordinatorSession) ProcessClaims(claims []IRewardsCoordinatorRewardsMerkleClaim, recipient common.Address) (*types.Transaction, error) { + return _IRewardsCoordinator.Contract.ProcessClaims(&_IRewardsCoordinator.TransactOpts, claims, recipient) +} + +// ProcessClaims is a paid mutator transaction binding the contract method 0x4596021c. +// +// Solidity: function processClaims((uint32,uint32,bytes,(address,bytes32),uint32[],bytes[],(address,uint256)[])[] claims, address recipient) returns() +func (_IRewardsCoordinator *IRewardsCoordinatorTransactorSession) ProcessClaims(claims []IRewardsCoordinatorRewardsMerkleClaim, recipient common.Address) (*types.Transaction, error) { + return _IRewardsCoordinator.Contract.ProcessClaims(&_IRewardsCoordinator.TransactOpts, claims, recipient) +} + // SetActivationDelay is a paid mutator transaction binding the contract method 0x58baaa3e. // // Solidity: function setActivationDelay(uint32 _activationDelay) returns() @@ -1024,25 +1113,67 @@ func (_IRewardsCoordinator *IRewardsCoordinatorTransactorSession) SetClaimerFor( return _IRewardsCoordinator.Contract.SetClaimerFor(&_IRewardsCoordinator.TransactOpts, claimer) } -// SetGlobalOperatorCommission is a paid mutator transaction binding the contract method 0xe221b245. +// SetDefaultOperatorSplit is a paid mutator transaction binding the contract method 0xa50a1d9c. +// +// Solidity: function setDefaultOperatorSplit(uint16 split) returns() +func (_IRewardsCoordinator *IRewardsCoordinatorTransactor) SetDefaultOperatorSplit(opts *bind.TransactOpts, split uint16) (*types.Transaction, error) { + return _IRewardsCoordinator.contract.Transact(opts, "setDefaultOperatorSplit", split) +} + +// SetDefaultOperatorSplit is a paid mutator transaction binding the contract method 0xa50a1d9c. +// +// Solidity: function setDefaultOperatorSplit(uint16 split) returns() +func (_IRewardsCoordinator *IRewardsCoordinatorSession) SetDefaultOperatorSplit(split uint16) (*types.Transaction, error) { + return _IRewardsCoordinator.Contract.SetDefaultOperatorSplit(&_IRewardsCoordinator.TransactOpts, split) +} + +// SetDefaultOperatorSplit is a paid mutator transaction binding the contract method 0xa50a1d9c. +// +// Solidity: function setDefaultOperatorSplit(uint16 split) returns() +func (_IRewardsCoordinator *IRewardsCoordinatorTransactorSession) SetDefaultOperatorSplit(split uint16) (*types.Transaction, error) { + return _IRewardsCoordinator.Contract.SetDefaultOperatorSplit(&_IRewardsCoordinator.TransactOpts, split) +} + +// SetOperatorAVSSplit is a paid mutator transaction binding the contract method 0xdcbb03b3. +// +// Solidity: function setOperatorAVSSplit(address operator, address avs, uint16 split) returns() +func (_IRewardsCoordinator *IRewardsCoordinatorTransactor) SetOperatorAVSSplit(opts *bind.TransactOpts, operator common.Address, avs common.Address, split uint16) (*types.Transaction, error) { + return _IRewardsCoordinator.contract.Transact(opts, "setOperatorAVSSplit", operator, avs, split) +} + +// SetOperatorAVSSplit is a paid mutator transaction binding the contract method 0xdcbb03b3. +// +// Solidity: function setOperatorAVSSplit(address operator, address avs, uint16 split) returns() +func (_IRewardsCoordinator *IRewardsCoordinatorSession) SetOperatorAVSSplit(operator common.Address, avs common.Address, split uint16) (*types.Transaction, error) { + return _IRewardsCoordinator.Contract.SetOperatorAVSSplit(&_IRewardsCoordinator.TransactOpts, operator, avs, split) +} + +// SetOperatorAVSSplit is a paid mutator transaction binding the contract method 0xdcbb03b3. +// +// Solidity: function setOperatorAVSSplit(address operator, address avs, uint16 split) returns() +func (_IRewardsCoordinator *IRewardsCoordinatorTransactorSession) SetOperatorAVSSplit(operator common.Address, avs common.Address, split uint16) (*types.Transaction, error) { + return _IRewardsCoordinator.Contract.SetOperatorAVSSplit(&_IRewardsCoordinator.TransactOpts, operator, avs, split) +} + +// SetOperatorPISplit is a paid mutator transaction binding the contract method 0xb3dbb0e0. // -// Solidity: function setGlobalOperatorCommission(uint16 _globalCommissionBips) returns() -func (_IRewardsCoordinator *IRewardsCoordinatorTransactor) SetGlobalOperatorCommission(opts *bind.TransactOpts, _globalCommissionBips uint16) (*types.Transaction, error) { - return _IRewardsCoordinator.contract.Transact(opts, "setGlobalOperatorCommission", _globalCommissionBips) +// Solidity: function setOperatorPISplit(address operator, uint16 split) returns() +func (_IRewardsCoordinator *IRewardsCoordinatorTransactor) SetOperatorPISplit(opts *bind.TransactOpts, operator common.Address, split uint16) (*types.Transaction, error) { + return _IRewardsCoordinator.contract.Transact(opts, "setOperatorPISplit", operator, split) } -// SetGlobalOperatorCommission is a paid mutator transaction binding the contract method 0xe221b245. +// SetOperatorPISplit is a paid mutator transaction binding the contract method 0xb3dbb0e0. // -// Solidity: function setGlobalOperatorCommission(uint16 _globalCommissionBips) returns() -func (_IRewardsCoordinator *IRewardsCoordinatorSession) SetGlobalOperatorCommission(_globalCommissionBips uint16) (*types.Transaction, error) { - return _IRewardsCoordinator.Contract.SetGlobalOperatorCommission(&_IRewardsCoordinator.TransactOpts, _globalCommissionBips) +// Solidity: function setOperatorPISplit(address operator, uint16 split) returns() +func (_IRewardsCoordinator *IRewardsCoordinatorSession) SetOperatorPISplit(operator common.Address, split uint16) (*types.Transaction, error) { + return _IRewardsCoordinator.Contract.SetOperatorPISplit(&_IRewardsCoordinator.TransactOpts, operator, split) } -// SetGlobalOperatorCommission is a paid mutator transaction binding the contract method 0xe221b245. +// SetOperatorPISplit is a paid mutator transaction binding the contract method 0xb3dbb0e0. // -// Solidity: function setGlobalOperatorCommission(uint16 _globalCommissionBips) returns() -func (_IRewardsCoordinator *IRewardsCoordinatorTransactorSession) SetGlobalOperatorCommission(_globalCommissionBips uint16) (*types.Transaction, error) { - return _IRewardsCoordinator.Contract.SetGlobalOperatorCommission(&_IRewardsCoordinator.TransactOpts, _globalCommissionBips) +// Solidity: function setOperatorPISplit(address operator, uint16 split) returns() +func (_IRewardsCoordinator *IRewardsCoordinatorTransactorSession) SetOperatorPISplit(operator common.Address, split uint16) (*types.Transaction, error) { + return _IRewardsCoordinator.Contract.SetOperatorPISplit(&_IRewardsCoordinator.TransactOpts, operator, split) } // SetRewardsForAllSubmitter is a paid mutator transaction binding the contract method 0x0eb38345. @@ -1568,6 +1699,141 @@ func (_IRewardsCoordinator *IRewardsCoordinatorFilterer) ParseClaimerForSet(log return event, nil } +// IRewardsCoordinatorDefaultOperatorSplitBipsSetIterator is returned from FilterDefaultOperatorSplitBipsSet and is used to iterate over the raw logs and unpacked data for DefaultOperatorSplitBipsSet events raised by the IRewardsCoordinator contract. +type IRewardsCoordinatorDefaultOperatorSplitBipsSetIterator struct { + Event *IRewardsCoordinatorDefaultOperatorSplitBipsSet // Event containing the contract specifics and raw log + + contract *bind.BoundContract // Generic contract to use for unpacking event data + event string // Event name to use for unpacking event data + + logs chan types.Log // Log channel receiving the found contract events + sub ethereum.Subscription // Subscription for errors, completion and termination + done bool // Whether the subscription completed delivering logs + fail error // Occurred error to stop iteration +} + +// Next advances the iterator to the subsequent event, returning whether there +// are any more events found. In case of a retrieval or parsing error, false is +// returned and Error() can be queried for the exact failure. +func (it *IRewardsCoordinatorDefaultOperatorSplitBipsSetIterator) Next() bool { + // If the iterator failed, stop iterating + if it.fail != nil { + return false + } + // If the iterator completed, deliver directly whatever's available + if it.done { + select { + case log := <-it.logs: + it.Event = new(IRewardsCoordinatorDefaultOperatorSplitBipsSet) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + // Iterator still in progress, wait for either a data or an error event + select { + case log := <-it.logs: + it.Event = new(IRewardsCoordinatorDefaultOperatorSplitBipsSet) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +// Error returns any retrieval or parsing error occurred during filtering. +func (it *IRewardsCoordinatorDefaultOperatorSplitBipsSetIterator) Error() error { + return it.fail +} + +// Close terminates the iteration process, releasing any pending underlying +// resources. +func (it *IRewardsCoordinatorDefaultOperatorSplitBipsSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +// IRewardsCoordinatorDefaultOperatorSplitBipsSet represents a DefaultOperatorSplitBipsSet event raised by the IRewardsCoordinator contract. +type IRewardsCoordinatorDefaultOperatorSplitBipsSet struct { + OldDefaultOperatorSplitBips uint16 + NewDefaultOperatorSplitBips uint16 + Raw types.Log // Blockchain specific contextual infos +} + +// FilterDefaultOperatorSplitBipsSet is a free log retrieval operation binding the contract event 0xe6cd4edfdcc1f6d130ab35f73d72378f3a642944fb4ee5bd84b7807a81ea1c4e. +// +// Solidity: event DefaultOperatorSplitBipsSet(uint16 oldDefaultOperatorSplitBips, uint16 newDefaultOperatorSplitBips) +func (_IRewardsCoordinator *IRewardsCoordinatorFilterer) FilterDefaultOperatorSplitBipsSet(opts *bind.FilterOpts) (*IRewardsCoordinatorDefaultOperatorSplitBipsSetIterator, error) { + + logs, sub, err := _IRewardsCoordinator.contract.FilterLogs(opts, "DefaultOperatorSplitBipsSet") + if err != nil { + return nil, err + } + return &IRewardsCoordinatorDefaultOperatorSplitBipsSetIterator{contract: _IRewardsCoordinator.contract, event: "DefaultOperatorSplitBipsSet", logs: logs, sub: sub}, nil +} + +// WatchDefaultOperatorSplitBipsSet is a free log subscription operation binding the contract event 0xe6cd4edfdcc1f6d130ab35f73d72378f3a642944fb4ee5bd84b7807a81ea1c4e. +// +// Solidity: event DefaultOperatorSplitBipsSet(uint16 oldDefaultOperatorSplitBips, uint16 newDefaultOperatorSplitBips) +func (_IRewardsCoordinator *IRewardsCoordinatorFilterer) WatchDefaultOperatorSplitBipsSet(opts *bind.WatchOpts, sink chan<- *IRewardsCoordinatorDefaultOperatorSplitBipsSet) (event.Subscription, error) { + + logs, sub, err := _IRewardsCoordinator.contract.WatchLogs(opts, "DefaultOperatorSplitBipsSet") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + // New log arrived, parse the event and forward to the user + event := new(IRewardsCoordinatorDefaultOperatorSplitBipsSet) + if err := _IRewardsCoordinator.contract.UnpackLog(event, "DefaultOperatorSplitBipsSet", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +// ParseDefaultOperatorSplitBipsSet is a log parse operation binding the contract event 0xe6cd4edfdcc1f6d130ab35f73d72378f3a642944fb4ee5bd84b7807a81ea1c4e. +// +// Solidity: event DefaultOperatorSplitBipsSet(uint16 oldDefaultOperatorSplitBips, uint16 newDefaultOperatorSplitBips) +func (_IRewardsCoordinator *IRewardsCoordinatorFilterer) ParseDefaultOperatorSplitBipsSet(log types.Log) (*IRewardsCoordinatorDefaultOperatorSplitBipsSet, error) { + event := new(IRewardsCoordinatorDefaultOperatorSplitBipsSet) + if err := _IRewardsCoordinator.contract.UnpackLog(event, "DefaultOperatorSplitBipsSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + // IRewardsCoordinatorDistributionRootDisabledIterator is returned from FilterDistributionRootDisabled and is used to iterate over the raw logs and unpacked data for DistributionRootDisabled events raised by the IRewardsCoordinator contract. type IRewardsCoordinatorDistributionRootDisabledIterator struct { Event *IRewardsCoordinatorDistributionRootDisabled // Event containing the contract specifics and raw log @@ -1875,9 +2141,9 @@ func (_IRewardsCoordinator *IRewardsCoordinatorFilterer) ParseDistributionRootSu return event, nil } -// IRewardsCoordinatorGlobalCommissionBipsSetIterator is returned from FilterGlobalCommissionBipsSet and is used to iterate over the raw logs and unpacked data for GlobalCommissionBipsSet events raised by the IRewardsCoordinator contract. -type IRewardsCoordinatorGlobalCommissionBipsSetIterator struct { - Event *IRewardsCoordinatorGlobalCommissionBipsSet // Event containing the contract specifics and raw log +// IRewardsCoordinatorOperatorAVSSplitBipsSetIterator is returned from FilterOperatorAVSSplitBipsSet and is used to iterate over the raw logs and unpacked data for OperatorAVSSplitBipsSet events raised by the IRewardsCoordinator contract. +type IRewardsCoordinatorOperatorAVSSplitBipsSetIterator struct { + Event *IRewardsCoordinatorOperatorAVSSplitBipsSet // Event containing the contract specifics and raw log contract *bind.BoundContract // Generic contract to use for unpacking event data event string // Event name to use for unpacking event data @@ -1891,7 +2157,7 @@ type IRewardsCoordinatorGlobalCommissionBipsSetIterator struct { // Next advances the iterator to the subsequent event, returning whether there // are any more events found. In case of a retrieval or parsing error, false is // returned and Error() can be queried for the exact failure. -func (it *IRewardsCoordinatorGlobalCommissionBipsSetIterator) Next() bool { +func (it *IRewardsCoordinatorOperatorAVSSplitBipsSetIterator) Next() bool { // If the iterator failed, stop iterating if it.fail != nil { return false @@ -1900,7 +2166,7 @@ func (it *IRewardsCoordinatorGlobalCommissionBipsSetIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(IRewardsCoordinatorGlobalCommissionBipsSet) + it.Event = new(IRewardsCoordinatorOperatorAVSSplitBipsSet) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -1915,7 +2181,7 @@ func (it *IRewardsCoordinatorGlobalCommissionBipsSetIterator) Next() bool { // Iterator still in progress, wait for either a data or an error event select { case log := <-it.logs: - it.Event = new(IRewardsCoordinatorGlobalCommissionBipsSet) + it.Event = new(IRewardsCoordinatorOperatorAVSSplitBipsSet) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -1931,42 +2197,392 @@ func (it *IRewardsCoordinatorGlobalCommissionBipsSetIterator) Next() bool { } // Error returns any retrieval or parsing error occurred during filtering. -func (it *IRewardsCoordinatorGlobalCommissionBipsSetIterator) Error() error { +func (it *IRewardsCoordinatorOperatorAVSSplitBipsSetIterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. -func (it *IRewardsCoordinatorGlobalCommissionBipsSetIterator) Close() error { +func (it *IRewardsCoordinatorOperatorAVSSplitBipsSetIterator) Close() error { it.sub.Unsubscribe() return nil } -// IRewardsCoordinatorGlobalCommissionBipsSet represents a GlobalCommissionBipsSet event raised by the IRewardsCoordinator contract. -type IRewardsCoordinatorGlobalCommissionBipsSet struct { - OldGlobalCommissionBips uint16 - NewGlobalCommissionBips uint16 +// IRewardsCoordinatorOperatorAVSSplitBipsSet represents a OperatorAVSSplitBipsSet event raised by the IRewardsCoordinator contract. +type IRewardsCoordinatorOperatorAVSSplitBipsSet struct { + Caller common.Address + Operator common.Address + Avs common.Address + ActivatedAt uint32 + OldOperatorAVSSplitBips uint16 + NewOperatorAVSSplitBips uint16 Raw types.Log // Blockchain specific contextual infos } -// FilterGlobalCommissionBipsSet is a free log retrieval operation binding the contract event 0x8cdc428b0431b82d1619763f443a48197db344ba96905f3949643acd1c863a06. +// FilterOperatorAVSSplitBipsSet is a free log retrieval operation binding the contract event 0x48e198b6ae357e529204ee53a8e514c470ff77d9cc8e4f7207f8b5d490ae6934. +// +// Solidity: event OperatorAVSSplitBipsSet(address indexed caller, address indexed operator, address indexed avs, uint32 activatedAt, uint16 oldOperatorAVSSplitBips, uint16 newOperatorAVSSplitBips) +func (_IRewardsCoordinator *IRewardsCoordinatorFilterer) FilterOperatorAVSSplitBipsSet(opts *bind.FilterOpts, caller []common.Address, operator []common.Address, avs []common.Address) (*IRewardsCoordinatorOperatorAVSSplitBipsSetIterator, error) { + + var callerRule []interface{} + for _, callerItem := range caller { + callerRule = append(callerRule, callerItem) + } + var operatorRule []interface{} + for _, operatorItem := range operator { + operatorRule = append(operatorRule, operatorItem) + } + var avsRule []interface{} + for _, avsItem := range avs { + avsRule = append(avsRule, avsItem) + } + + logs, sub, err := _IRewardsCoordinator.contract.FilterLogs(opts, "OperatorAVSSplitBipsSet", callerRule, operatorRule, avsRule) + if err != nil { + return nil, err + } + return &IRewardsCoordinatorOperatorAVSSplitBipsSetIterator{contract: _IRewardsCoordinator.contract, event: "OperatorAVSSplitBipsSet", logs: logs, sub: sub}, nil +} + +// WatchOperatorAVSSplitBipsSet is a free log subscription operation binding the contract event 0x48e198b6ae357e529204ee53a8e514c470ff77d9cc8e4f7207f8b5d490ae6934. +// +// Solidity: event OperatorAVSSplitBipsSet(address indexed caller, address indexed operator, address indexed avs, uint32 activatedAt, uint16 oldOperatorAVSSplitBips, uint16 newOperatorAVSSplitBips) +func (_IRewardsCoordinator *IRewardsCoordinatorFilterer) WatchOperatorAVSSplitBipsSet(opts *bind.WatchOpts, sink chan<- *IRewardsCoordinatorOperatorAVSSplitBipsSet, caller []common.Address, operator []common.Address, avs []common.Address) (event.Subscription, error) { + + var callerRule []interface{} + for _, callerItem := range caller { + callerRule = append(callerRule, callerItem) + } + var operatorRule []interface{} + for _, operatorItem := range operator { + operatorRule = append(operatorRule, operatorItem) + } + var avsRule []interface{} + for _, avsItem := range avs { + avsRule = append(avsRule, avsItem) + } + + logs, sub, err := _IRewardsCoordinator.contract.WatchLogs(opts, "OperatorAVSSplitBipsSet", callerRule, operatorRule, avsRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + // New log arrived, parse the event and forward to the user + event := new(IRewardsCoordinatorOperatorAVSSplitBipsSet) + if err := _IRewardsCoordinator.contract.UnpackLog(event, "OperatorAVSSplitBipsSet", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +// ParseOperatorAVSSplitBipsSet is a log parse operation binding the contract event 0x48e198b6ae357e529204ee53a8e514c470ff77d9cc8e4f7207f8b5d490ae6934. +// +// Solidity: event OperatorAVSSplitBipsSet(address indexed caller, address indexed operator, address indexed avs, uint32 activatedAt, uint16 oldOperatorAVSSplitBips, uint16 newOperatorAVSSplitBips) +func (_IRewardsCoordinator *IRewardsCoordinatorFilterer) ParseOperatorAVSSplitBipsSet(log types.Log) (*IRewardsCoordinatorOperatorAVSSplitBipsSet, error) { + event := new(IRewardsCoordinatorOperatorAVSSplitBipsSet) + if err := _IRewardsCoordinator.contract.UnpackLog(event, "OperatorAVSSplitBipsSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +// IRewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreatedIterator is returned from FilterOperatorDirectedAVSRewardsSubmissionCreated and is used to iterate over the raw logs and unpacked data for OperatorDirectedAVSRewardsSubmissionCreated events raised by the IRewardsCoordinator contract. +type IRewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreatedIterator struct { + Event *IRewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreated // Event containing the contract specifics and raw log + + contract *bind.BoundContract // Generic contract to use for unpacking event data + event string // Event name to use for unpacking event data + + logs chan types.Log // Log channel receiving the found contract events + sub ethereum.Subscription // Subscription for errors, completion and termination + done bool // Whether the subscription completed delivering logs + fail error // Occurred error to stop iteration +} + +// Next advances the iterator to the subsequent event, returning whether there +// are any more events found. In case of a retrieval or parsing error, false is +// returned and Error() can be queried for the exact failure. +func (it *IRewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreatedIterator) Next() bool { + // If the iterator failed, stop iterating + if it.fail != nil { + return false + } + // If the iterator completed, deliver directly whatever's available + if it.done { + select { + case log := <-it.logs: + it.Event = new(IRewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreated) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + // Iterator still in progress, wait for either a data or an error event + select { + case log := <-it.logs: + it.Event = new(IRewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreated) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +// Error returns any retrieval or parsing error occurred during filtering. +func (it *IRewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreatedIterator) Error() error { + return it.fail +} + +// Close terminates the iteration process, releasing any pending underlying +// resources. +func (it *IRewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreatedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +// IRewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreated represents a OperatorDirectedAVSRewardsSubmissionCreated event raised by the IRewardsCoordinator contract. +type IRewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreated struct { + Caller common.Address + Avs common.Address + OperatorDirectedRewardsSubmissionHash [32]byte + SubmissionNonce *big.Int + OperatorDirectedRewardsSubmission IRewardsCoordinatorOperatorDirectedRewardsSubmission + Raw types.Log // Blockchain specific contextual infos +} + +// FilterOperatorDirectedAVSRewardsSubmissionCreated is a free log retrieval operation binding the contract event 0xfc8888bffd711da60bc5092b33f677d81896fe80ecc677b84cfab8184462b6e0. +// +// Solidity: event OperatorDirectedAVSRewardsSubmissionCreated(address indexed caller, address indexed avs, bytes32 indexed operatorDirectedRewardsSubmissionHash, uint256 submissionNonce, ((address,uint96)[],address,(address,uint256)[],uint32,uint32,string) operatorDirectedRewardsSubmission) +func (_IRewardsCoordinator *IRewardsCoordinatorFilterer) FilterOperatorDirectedAVSRewardsSubmissionCreated(opts *bind.FilterOpts, caller []common.Address, avs []common.Address, operatorDirectedRewardsSubmissionHash [][32]byte) (*IRewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreatedIterator, error) { + + var callerRule []interface{} + for _, callerItem := range caller { + callerRule = append(callerRule, callerItem) + } + var avsRule []interface{} + for _, avsItem := range avs { + avsRule = append(avsRule, avsItem) + } + var operatorDirectedRewardsSubmissionHashRule []interface{} + for _, operatorDirectedRewardsSubmissionHashItem := range operatorDirectedRewardsSubmissionHash { + operatorDirectedRewardsSubmissionHashRule = append(operatorDirectedRewardsSubmissionHashRule, operatorDirectedRewardsSubmissionHashItem) + } + + logs, sub, err := _IRewardsCoordinator.contract.FilterLogs(opts, "OperatorDirectedAVSRewardsSubmissionCreated", callerRule, avsRule, operatorDirectedRewardsSubmissionHashRule) + if err != nil { + return nil, err + } + return &IRewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreatedIterator{contract: _IRewardsCoordinator.contract, event: "OperatorDirectedAVSRewardsSubmissionCreated", logs: logs, sub: sub}, nil +} + +// WatchOperatorDirectedAVSRewardsSubmissionCreated is a free log subscription operation binding the contract event 0xfc8888bffd711da60bc5092b33f677d81896fe80ecc677b84cfab8184462b6e0. +// +// Solidity: event OperatorDirectedAVSRewardsSubmissionCreated(address indexed caller, address indexed avs, bytes32 indexed operatorDirectedRewardsSubmissionHash, uint256 submissionNonce, ((address,uint96)[],address,(address,uint256)[],uint32,uint32,string) operatorDirectedRewardsSubmission) +func (_IRewardsCoordinator *IRewardsCoordinatorFilterer) WatchOperatorDirectedAVSRewardsSubmissionCreated(opts *bind.WatchOpts, sink chan<- *IRewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreated, caller []common.Address, avs []common.Address, operatorDirectedRewardsSubmissionHash [][32]byte) (event.Subscription, error) { + + var callerRule []interface{} + for _, callerItem := range caller { + callerRule = append(callerRule, callerItem) + } + var avsRule []interface{} + for _, avsItem := range avs { + avsRule = append(avsRule, avsItem) + } + var operatorDirectedRewardsSubmissionHashRule []interface{} + for _, operatorDirectedRewardsSubmissionHashItem := range operatorDirectedRewardsSubmissionHash { + operatorDirectedRewardsSubmissionHashRule = append(operatorDirectedRewardsSubmissionHashRule, operatorDirectedRewardsSubmissionHashItem) + } + + logs, sub, err := _IRewardsCoordinator.contract.WatchLogs(opts, "OperatorDirectedAVSRewardsSubmissionCreated", callerRule, avsRule, operatorDirectedRewardsSubmissionHashRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + // New log arrived, parse the event and forward to the user + event := new(IRewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreated) + if err := _IRewardsCoordinator.contract.UnpackLog(event, "OperatorDirectedAVSRewardsSubmissionCreated", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +// ParseOperatorDirectedAVSRewardsSubmissionCreated is a log parse operation binding the contract event 0xfc8888bffd711da60bc5092b33f677d81896fe80ecc677b84cfab8184462b6e0. +// +// Solidity: event OperatorDirectedAVSRewardsSubmissionCreated(address indexed caller, address indexed avs, bytes32 indexed operatorDirectedRewardsSubmissionHash, uint256 submissionNonce, ((address,uint96)[],address,(address,uint256)[],uint32,uint32,string) operatorDirectedRewardsSubmission) +func (_IRewardsCoordinator *IRewardsCoordinatorFilterer) ParseOperatorDirectedAVSRewardsSubmissionCreated(log types.Log) (*IRewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreated, error) { + event := new(IRewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreated) + if err := _IRewardsCoordinator.contract.UnpackLog(event, "OperatorDirectedAVSRewardsSubmissionCreated", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +// IRewardsCoordinatorOperatorPISplitBipsSetIterator is returned from FilterOperatorPISplitBipsSet and is used to iterate over the raw logs and unpacked data for OperatorPISplitBipsSet events raised by the IRewardsCoordinator contract. +type IRewardsCoordinatorOperatorPISplitBipsSetIterator struct { + Event *IRewardsCoordinatorOperatorPISplitBipsSet // Event containing the contract specifics and raw log + + contract *bind.BoundContract // Generic contract to use for unpacking event data + event string // Event name to use for unpacking event data + + logs chan types.Log // Log channel receiving the found contract events + sub ethereum.Subscription // Subscription for errors, completion and termination + done bool // Whether the subscription completed delivering logs + fail error // Occurred error to stop iteration +} + +// Next advances the iterator to the subsequent event, returning whether there +// are any more events found. In case of a retrieval or parsing error, false is +// returned and Error() can be queried for the exact failure. +func (it *IRewardsCoordinatorOperatorPISplitBipsSetIterator) Next() bool { + // If the iterator failed, stop iterating + if it.fail != nil { + return false + } + // If the iterator completed, deliver directly whatever's available + if it.done { + select { + case log := <-it.logs: + it.Event = new(IRewardsCoordinatorOperatorPISplitBipsSet) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + // Iterator still in progress, wait for either a data or an error event + select { + case log := <-it.logs: + it.Event = new(IRewardsCoordinatorOperatorPISplitBipsSet) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +// Error returns any retrieval or parsing error occurred during filtering. +func (it *IRewardsCoordinatorOperatorPISplitBipsSetIterator) Error() error { + return it.fail +} + +// Close terminates the iteration process, releasing any pending underlying +// resources. +func (it *IRewardsCoordinatorOperatorPISplitBipsSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +// IRewardsCoordinatorOperatorPISplitBipsSet represents a OperatorPISplitBipsSet event raised by the IRewardsCoordinator contract. +type IRewardsCoordinatorOperatorPISplitBipsSet struct { + Caller common.Address + Operator common.Address + ActivatedAt uint32 + OldOperatorPISplitBips uint16 + NewOperatorPISplitBips uint16 + Raw types.Log // Blockchain specific contextual infos +} + +// FilterOperatorPISplitBipsSet is a free log retrieval operation binding the contract event 0xd1e028bd664486a46ad26040e999cd2d22e1e9a094ee6afe19fcf64678f16f74. // -// Solidity: event GlobalCommissionBipsSet(uint16 oldGlobalCommissionBips, uint16 newGlobalCommissionBips) -func (_IRewardsCoordinator *IRewardsCoordinatorFilterer) FilterGlobalCommissionBipsSet(opts *bind.FilterOpts) (*IRewardsCoordinatorGlobalCommissionBipsSetIterator, error) { +// Solidity: event OperatorPISplitBipsSet(address indexed caller, address indexed operator, uint32 activatedAt, uint16 oldOperatorPISplitBips, uint16 newOperatorPISplitBips) +func (_IRewardsCoordinator *IRewardsCoordinatorFilterer) FilterOperatorPISplitBipsSet(opts *bind.FilterOpts, caller []common.Address, operator []common.Address) (*IRewardsCoordinatorOperatorPISplitBipsSetIterator, error) { + + var callerRule []interface{} + for _, callerItem := range caller { + callerRule = append(callerRule, callerItem) + } + var operatorRule []interface{} + for _, operatorItem := range operator { + operatorRule = append(operatorRule, operatorItem) + } - logs, sub, err := _IRewardsCoordinator.contract.FilterLogs(opts, "GlobalCommissionBipsSet") + logs, sub, err := _IRewardsCoordinator.contract.FilterLogs(opts, "OperatorPISplitBipsSet", callerRule, operatorRule) if err != nil { return nil, err } - return &IRewardsCoordinatorGlobalCommissionBipsSetIterator{contract: _IRewardsCoordinator.contract, event: "GlobalCommissionBipsSet", logs: logs, sub: sub}, nil + return &IRewardsCoordinatorOperatorPISplitBipsSetIterator{contract: _IRewardsCoordinator.contract, event: "OperatorPISplitBipsSet", logs: logs, sub: sub}, nil } -// WatchGlobalCommissionBipsSet is a free log subscription operation binding the contract event 0x8cdc428b0431b82d1619763f443a48197db344ba96905f3949643acd1c863a06. +// WatchOperatorPISplitBipsSet is a free log subscription operation binding the contract event 0xd1e028bd664486a46ad26040e999cd2d22e1e9a094ee6afe19fcf64678f16f74. // -// Solidity: event GlobalCommissionBipsSet(uint16 oldGlobalCommissionBips, uint16 newGlobalCommissionBips) -func (_IRewardsCoordinator *IRewardsCoordinatorFilterer) WatchGlobalCommissionBipsSet(opts *bind.WatchOpts, sink chan<- *IRewardsCoordinatorGlobalCommissionBipsSet) (event.Subscription, error) { +// Solidity: event OperatorPISplitBipsSet(address indexed caller, address indexed operator, uint32 activatedAt, uint16 oldOperatorPISplitBips, uint16 newOperatorPISplitBips) +func (_IRewardsCoordinator *IRewardsCoordinatorFilterer) WatchOperatorPISplitBipsSet(opts *bind.WatchOpts, sink chan<- *IRewardsCoordinatorOperatorPISplitBipsSet, caller []common.Address, operator []common.Address) (event.Subscription, error) { + + var callerRule []interface{} + for _, callerItem := range caller { + callerRule = append(callerRule, callerItem) + } + var operatorRule []interface{} + for _, operatorItem := range operator { + operatorRule = append(operatorRule, operatorItem) + } - logs, sub, err := _IRewardsCoordinator.contract.WatchLogs(opts, "GlobalCommissionBipsSet") + logs, sub, err := _IRewardsCoordinator.contract.WatchLogs(opts, "OperatorPISplitBipsSet", callerRule, operatorRule) if err != nil { return nil, err } @@ -1976,8 +2592,8 @@ func (_IRewardsCoordinator *IRewardsCoordinatorFilterer) WatchGlobalCommissionBi select { case log := <-logs: // New log arrived, parse the event and forward to the user - event := new(IRewardsCoordinatorGlobalCommissionBipsSet) - if err := _IRewardsCoordinator.contract.UnpackLog(event, "GlobalCommissionBipsSet", log); err != nil { + event := new(IRewardsCoordinatorOperatorPISplitBipsSet) + if err := _IRewardsCoordinator.contract.UnpackLog(event, "OperatorPISplitBipsSet", log); err != nil { return err } event.Raw = log @@ -1998,12 +2614,12 @@ func (_IRewardsCoordinator *IRewardsCoordinatorFilterer) WatchGlobalCommissionBi }), nil } -// ParseGlobalCommissionBipsSet is a log parse operation binding the contract event 0x8cdc428b0431b82d1619763f443a48197db344ba96905f3949643acd1c863a06. +// ParseOperatorPISplitBipsSet is a log parse operation binding the contract event 0xd1e028bd664486a46ad26040e999cd2d22e1e9a094ee6afe19fcf64678f16f74. // -// Solidity: event GlobalCommissionBipsSet(uint16 oldGlobalCommissionBips, uint16 newGlobalCommissionBips) -func (_IRewardsCoordinator *IRewardsCoordinatorFilterer) ParseGlobalCommissionBipsSet(log types.Log) (*IRewardsCoordinatorGlobalCommissionBipsSet, error) { - event := new(IRewardsCoordinatorGlobalCommissionBipsSet) - if err := _IRewardsCoordinator.contract.UnpackLog(event, "GlobalCommissionBipsSet", log); err != nil { +// Solidity: event OperatorPISplitBipsSet(address indexed caller, address indexed operator, uint32 activatedAt, uint16 oldOperatorPISplitBips, uint16 newOperatorPISplitBips) +func (_IRewardsCoordinator *IRewardsCoordinatorFilterer) ParseOperatorPISplitBipsSet(log types.Log) (*IRewardsCoordinatorOperatorPISplitBipsSet, error) { + event := new(IRewardsCoordinatorOperatorPISplitBipsSet) + if err := _IRewardsCoordinator.contract.UnpackLog(event, "OperatorPISplitBipsSet", log); err != nil { return nil, err } event.Raw = log diff --git a/pkg/bindings/RewardsCoordinator/binding.go b/pkg/bindings/RewardsCoordinator/binding.go index 08349f643..b888d121e 100644 --- a/pkg/bindings/RewardsCoordinator/binding.go +++ b/pkg/bindings/RewardsCoordinator/binding.go @@ -43,6 +43,22 @@ type IRewardsCoordinatorEarnerTreeMerkleLeaf struct { EarnerTokenRoot [32]byte } +// IRewardsCoordinatorOperatorDirectedRewardsSubmission is an auto generated low-level Go binding around an user-defined struct. +type IRewardsCoordinatorOperatorDirectedRewardsSubmission struct { + StrategiesAndMultipliers []IRewardsCoordinatorStrategyAndMultiplier + Token common.Address + OperatorRewards []IRewardsCoordinatorOperatorReward + StartTimestamp uint32 + Duration uint32 + Description string +} + +// IRewardsCoordinatorOperatorReward is an auto generated low-level Go binding around an user-defined struct. +type IRewardsCoordinatorOperatorReward struct { + Operator common.Address + Amount *big.Int +} + // IRewardsCoordinatorRewardsMerkleClaim is an auto generated low-level Go binding around an user-defined struct. type IRewardsCoordinatorRewardsMerkleClaim struct { RootIndex uint32 @@ -77,8 +93,8 @@ type IRewardsCoordinatorTokenTreeMerkleLeaf struct { // RewardsCoordinatorMetaData contains all meta data concerning the RewardsCoordinator contract. var RewardsCoordinatorMetaData = &bind.MetaData{ - ABI: "[{\"type\":\"constructor\",\"inputs\":[{\"name\":\"_delegationManager\",\"type\":\"address\",\"internalType\":\"contractIDelegationManager\"},{\"name\":\"_strategyManager\",\"type\":\"address\",\"internalType\":\"contractIStrategyManager\"},{\"name\":\"_CALCULATION_INTERVAL_SECONDS\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"_MAX_REWARDS_DURATION\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"_MAX_RETROACTIVE_LENGTH\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"_MAX_FUTURE_LENGTH\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"__GENESIS_REWARDS_TIMESTAMP\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"CALCULATION_INTERVAL_SECONDS\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"GENESIS_REWARDS_TIMESTAMP\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"MAX_FUTURE_LENGTH\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"MAX_RETROACTIVE_LENGTH\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"MAX_REWARDS_DURATION\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"activationDelay\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"beaconChainETHStrategy\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"calculateEarnerLeafHash\",\"inputs\":[{\"name\":\"leaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.EarnerTreeMerkleLeaf\",\"components\":[{\"name\":\"earner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"earnerTokenRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"pure\"},{\"type\":\"function\",\"name\":\"calculateTokenLeafHash\",\"inputs\":[{\"name\":\"leaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.TokenTreeMerkleLeaf\",\"components\":[{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"cumulativeEarnings\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"pure\"},{\"type\":\"function\",\"name\":\"checkClaim\",\"inputs\":[{\"name\":\"claim\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.RewardsMerkleClaim\",\"components\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerTreeProof\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"earnerLeaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.EarnerTreeMerkleLeaf\",\"components\":[{\"name\":\"earner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"earnerTokenRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]},{\"name\":\"tokenIndices\",\"type\":\"uint32[]\",\"internalType\":\"uint32[]\"},{\"name\":\"tokenTreeProofs\",\"type\":\"bytes[]\",\"internalType\":\"bytes[]\"},{\"name\":\"tokenLeaves\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.TokenTreeMerkleLeaf[]\",\"components\":[{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"cumulativeEarnings\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]}]}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"claimerFor\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"createAVSRewardsSubmission\",\"inputs\":[{\"name\":\"rewardsSubmissions\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.RewardsSubmission[]\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"createRewardsForAllEarners\",\"inputs\":[{\"name\":\"rewardsSubmissions\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.RewardsSubmission[]\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"createRewardsForAllSubmission\",\"inputs\":[{\"name\":\"rewardsSubmissions\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.RewardsSubmission[]\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"cumulativeClaimed\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIERC20\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"currRewardsCalculationEndTimestamp\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"delegationManager\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIDelegationManager\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"disableRoot\",\"inputs\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"domainSeparator\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getCurrentClaimableDistributionRoot\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.DistributionRoot\",\"components\":[{\"name\":\"root\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"disabled\",\"type\":\"bool\",\"internalType\":\"bool\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getCurrentDistributionRoot\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.DistributionRoot\",\"components\":[{\"name\":\"root\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"disabled\",\"type\":\"bool\",\"internalType\":\"bool\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getDistributionRootAtIndex\",\"inputs\":[{\"name\":\"index\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.DistributionRoot\",\"components\":[{\"name\":\"root\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"disabled\",\"type\":\"bool\",\"internalType\":\"bool\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getDistributionRootsLength\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getRootIndexFromHash\",\"inputs\":[{\"name\":\"rootHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"globalOperatorCommissionBips\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"initialize\",\"inputs\":[{\"name\":\"initialOwner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_pauserRegistry\",\"type\":\"address\",\"internalType\":\"contractIPauserRegistry\"},{\"name\":\"initialPausedStatus\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_rewardsUpdater\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_activationDelay\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"_globalCommissionBips\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"isAVSRewardsSubmissionHash\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"isRewardsForAllSubmitter\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"isRewardsSubmissionForAllEarnersHash\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"isRewardsSubmissionForAllHash\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"operatorCommissionBips\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"owner\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"pause\",\"inputs\":[{\"name\":\"newPausedStatus\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"pauseAll\",\"inputs\":[],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"paused\",\"inputs\":[{\"name\":\"index\",\"type\":\"uint8\",\"internalType\":\"uint8\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"paused\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"pauserRegistry\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIPauserRegistry\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"processClaim\",\"inputs\":[{\"name\":\"claim\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.RewardsMerkleClaim\",\"components\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerTreeProof\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"earnerLeaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.EarnerTreeMerkleLeaf\",\"components\":[{\"name\":\"earner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"earnerTokenRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]},{\"name\":\"tokenIndices\",\"type\":\"uint32[]\",\"internalType\":\"uint32[]\"},{\"name\":\"tokenTreeProofs\",\"type\":\"bytes[]\",\"internalType\":\"bytes[]\"},{\"name\":\"tokenLeaves\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.TokenTreeMerkleLeaf[]\",\"components\":[{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"cumulativeEarnings\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]}]},{\"name\":\"recipient\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"renounceOwnership\",\"inputs\":[],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"rewardsUpdater\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"setActivationDelay\",\"inputs\":[{\"name\":\"_activationDelay\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setClaimerFor\",\"inputs\":[{\"name\":\"claimer\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setGlobalOperatorCommission\",\"inputs\":[{\"name\":\"_globalCommissionBips\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setPauserRegistry\",\"inputs\":[{\"name\":\"newPauserRegistry\",\"type\":\"address\",\"internalType\":\"contractIPauserRegistry\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setRewardsForAllSubmitter\",\"inputs\":[{\"name\":\"_submitter\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_newValue\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setRewardsUpdater\",\"inputs\":[{\"name\":\"_rewardsUpdater\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"strategyManager\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIStrategyManager\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"submissionNonce\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"submitRoot\",\"inputs\":[{\"name\":\"root\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"transferOwnership\",\"inputs\":[{\"name\":\"newOwner\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"unpause\",\"inputs\":[{\"name\":\"newPausedStatus\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"event\",\"name\":\"AVSRewardsSubmissionCreated\",\"inputs\":[{\"name\":\"avs\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"submissionNonce\",\"type\":\"uint256\",\"indexed\":true,\"internalType\":\"uint256\"},{\"name\":\"rewardsSubmissionHash\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"rewardsSubmission\",\"type\":\"tuple\",\"indexed\":false,\"internalType\":\"structIRewardsCoordinator.RewardsSubmission\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ActivationDelaySet\",\"inputs\":[{\"name\":\"oldActivationDelay\",\"type\":\"uint32\",\"indexed\":false,\"internalType\":\"uint32\"},{\"name\":\"newActivationDelay\",\"type\":\"uint32\",\"indexed\":false,\"internalType\":\"uint32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ClaimerForSet\",\"inputs\":[{\"name\":\"earner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"oldClaimer\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"claimer\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"DistributionRootDisabled\",\"inputs\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"indexed\":true,\"internalType\":\"uint32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"DistributionRootSubmitted\",\"inputs\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"indexed\":true,\"internalType\":\"uint32\"},{\"name\":\"root\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"indexed\":true,\"internalType\":\"uint32\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"indexed\":false,\"internalType\":\"uint32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"GlobalCommissionBipsSet\",\"inputs\":[{\"name\":\"oldGlobalCommissionBips\",\"type\":\"uint16\",\"indexed\":false,\"internalType\":\"uint16\"},{\"name\":\"newGlobalCommissionBips\",\"type\":\"uint16\",\"indexed\":false,\"internalType\":\"uint16\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"Initialized\",\"inputs\":[{\"name\":\"version\",\"type\":\"uint8\",\"indexed\":false,\"internalType\":\"uint8\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"OwnershipTransferred\",\"inputs\":[{\"name\":\"previousOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"Paused\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newPausedStatus\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"PauserRegistrySet\",\"inputs\":[{\"name\":\"pauserRegistry\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"contractIPauserRegistry\"},{\"name\":\"newPauserRegistry\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"contractIPauserRegistry\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsClaimed\",\"inputs\":[{\"name\":\"root\",\"type\":\"bytes32\",\"indexed\":false,\"internalType\":\"bytes32\"},{\"name\":\"earner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"claimer\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"token\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"contractIERC20\"},{\"name\":\"claimedAmount\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsForAllSubmitterSet\",\"inputs\":[{\"name\":\"rewardsForAllSubmitter\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"oldValue\",\"type\":\"bool\",\"indexed\":true,\"internalType\":\"bool\"},{\"name\":\"newValue\",\"type\":\"bool\",\"indexed\":true,\"internalType\":\"bool\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsSubmissionForAllCreated\",\"inputs\":[{\"name\":\"submitter\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"submissionNonce\",\"type\":\"uint256\",\"indexed\":true,\"internalType\":\"uint256\"},{\"name\":\"rewardsSubmissionHash\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"rewardsSubmission\",\"type\":\"tuple\",\"indexed\":false,\"internalType\":\"structIRewardsCoordinator.RewardsSubmission\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsSubmissionForAllEarnersCreated\",\"inputs\":[{\"name\":\"tokenHopper\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"submissionNonce\",\"type\":\"uint256\",\"indexed\":true,\"internalType\":\"uint256\"},{\"name\":\"rewardsSubmissionHash\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"rewardsSubmission\",\"type\":\"tuple\",\"indexed\":false,\"internalType\":\"structIRewardsCoordinator.RewardsSubmission\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsUpdaterSet\",\"inputs\":[{\"name\":\"oldRewardsUpdater\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newRewardsUpdater\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"Unpaused\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newPausedStatus\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false}]", - Bin: "0x6101806040523480156200001257600080fd5b50604051620045b8380380620045b88339810160408190526200003591620002e4565b868686868686866200004885826200037e565b63ffffffff1615620000ed5760405162461bcd60e51b815260206004820152606060248201527f52657761726473436f6f7264696e61746f723a2047454e455349535f5245574160448201527f5244535f54494d455354414d50206d7573742062652061206d756c7469706c6560648201527f206f662043414c43554c4154494f4e5f494e54455256414c5f5345434f4e4453608482015260a4015b60405180910390fd5b620000fc62015180866200037e565b63ffffffff16156200019d5760405162461bcd60e51b815260206004820152605760248201527f52657761726473436f6f7264696e61746f723a2043414c43554c4154494f4e5f60448201527f494e54455256414c5f5345434f4e4453206d7573742062652061206d756c746960648201527f706c65206f6620534e415053484f545f434144454e4345000000000000000000608482015260a401620000e4565b6001600160a01b0396871661012052949095166101405263ffffffff92831660805290821660a052811660c05291821660e0521661010052620001df620001f2565b5050466101605250620003b09350505050565b600054610100900460ff16156200025c5760405162461bcd60e51b815260206004820152602760248201527f496e697469616c697a61626c653a20636f6e747261637420697320696e697469604482015266616c697a696e6760c81b6064820152608401620000e4565b60005460ff9081161015620002af576000805460ff191660ff9081179091556040519081527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b565b6001600160a01b0381168114620002c757600080fd5b50565b805163ffffffff81168114620002df57600080fd5b919050565b600080600080600080600060e0888a0312156200030057600080fd5b87516200030d81620002b1565b60208901519097506200032081620002b1565b95506200033060408901620002ca565b94506200034060608901620002ca565b93506200035060808901620002ca565b92506200036060a08901620002ca565b91506200037060c08901620002ca565b905092959891949750929550565b600063ffffffff80841680620003a457634e487b7160e01b600052601260045260246000fd5b92169190910692915050565b60805160a05160c05160e05161010051610120516101405161016051614171620004476000396000611a900152600081816104fd01526128f8015260006107bd015260008181610406015261272701526000818161033201526127d30152600081816104d601526126d601526000818161071c015261244d0152600081816106940152818161250401526125df01526141716000f3fe608060405234801561001057600080fd5b50600436106102f05760003560e01c80637b8f8b051161019d578063d4540a55116100e9578063f698da25116100a2578063fabc1cbc1161007c578063fabc1cbc14610820578063fbf1e2c114610833578063fce36c7d14610846578063ff9f6cce1461085957600080fd5b8063f698da25146107f2578063f8cd8448146107fa578063f96abf2e1461080d57600080fd5b8063d4540a551461076c578063de02e5031461077f578063e221b24514610792578063e810ce21146107a5578063ea4d3c9b146107b8578063f2fde38b146107df57600080fd5b80639be3d4e411610156578063aebd8bae11610130578063aebd8bae146106c9578063bb7e451f146106f7578063bf21a8aa14610717578063c46db6061461073e57600080fd5b80639be3d4e4146106875780639d45c2811461068f578063a0169ddd146106b657600080fd5b80637b8f8b0514610602578063863cb9a91461060a578063865c69531461061d578063886f1195146106485780638da5cb5b1461065b5780639104c3191461066c57600080fd5b806337838ed01161025c57806358baaa3e116102155780635c975abb116101ef5780635c975abb146105b15780635e9d8348146105b95780636d21117e146105cc578063715018a6146105fa57600080fd5b806358baaa3e14610573578063595c6a67146105865780635ac86ab71461058e57600080fd5b806337838ed0146104d157806339b70e38146104f85780633a8c07861461051f5780633ccc861d146105365780633efe1db6146105495780634d18cc351461055c57600080fd5b8063131433b4116102ae578063131433b414610401578063136439dd14610428578063149bc8721461043b57806322f19a641461045c5780632b9f64a41461047d57806336af41fa146104be57600080fd5b806218572c146102f557806304a0c5021461032d578063092db007146103695780630e9a53cf146103915780630eb38345146103d957806310d67a2f146103ee575b600080fd5b610318610303366004613783565b60d16020526000908152604090205460ff1681565b60405190151581526020015b60405180910390f35b6103547f000000000000000000000000000000000000000000000000000000000000000081565b60405163ffffffff9091168152602001610324565b60cb5461037e90600160e01b900461ffff1681565b60405161ffff9091168152602001610324565b61039961086c565b604080518251815260208084015163ffffffff90811691830191909152838301511691810191909152606091820151151591810191909152608001610324565b6103ec6103e73660046137ae565b610970565b005b6103ec6103fc366004613783565b6109f2565b6103547f000000000000000000000000000000000000000000000000000000000000000081565b6103ec6104363660046137e7565b610aae565b61044e610449366004613818565b610bed565b604051908152602001610324565b61037e61046a366004613834565b505060cb54600160e01b900461ffff1690565b6104a661048b366004613783565b60cc602052600090815260409020546001600160a01b031681565b6040516001600160a01b039091168152602001610324565b6103ec6104cc366004613862565b610c63565b6103547f000000000000000000000000000000000000000000000000000000000000000081565b6104a67f000000000000000000000000000000000000000000000000000000000000000081565b60cb5461035490600160a01b900463ffffffff1681565b6103ec6105443660046138ea565b610e2d565b6103ec61055736600461394a565b6111f1565b60cb5461035490600160c01b900463ffffffff1681565b6103ec610581366004613976565b6114c2565b6103ec6114d3565b61031861059c366004613991565b606654600160ff9092169190911b9081161490565b60665461044e565b6103186105c73660046139b4565b61159a565b6103186105da3660046139e9565b60cf60209081526000928352604080842090915290825290205460ff1681565b6103ec611627565b60ca5461044e565b6103ec610618366004613783565b61163b565b61044e61062b366004613834565b60cd60209081526000928352604080842090915290825290205481565b6065546104a6906001600160a01b031681565b6033546001600160a01b03166104a6565b6104a673beac0eeeeeeeeeeeeeeeeeeeeeeeeeeeeeebeac081565b61039961164c565b6103547f000000000000000000000000000000000000000000000000000000000000000081565b6103ec6106c4366004613783565b6116ea565b6103186106d73660046139e9565b60d260209081526000928352604080842090915290825290205460ff1681565b61044e610705366004613783565b60ce6020526000908152604090205481565b6103547f000000000000000000000000000000000000000000000000000000000000000081565b61031861074c3660046139e9565b60d060209081526000928352604080842090915290825290205460ff1681565b6103ec61077a366004613a32565b611749565b61039961078d3660046137e7565b611891565b6103ec6107a0366004613aa5565b611923565b6103546107b33660046137e7565b611934565b6104a67f000000000000000000000000000000000000000000000000000000000000000081565b6103ec6107ed366004613783565b611a16565b61044e611a8c565b61044e610808366004613818565b611aca565b6103ec61081b366004613976565b611adb565b6103ec61082e3660046137e7565b611d11565b60cb546104a6906001600160a01b031681565b6103ec610854366004613862565b611e6d565b6103ec610867366004613862565b611fec565b60408051608081018252600080825260208201819052918101829052606081019190915260ca545b801561094757600060ca6108a9600184613ad6565b815481106108b9576108b9613aed565b600091825260209182902060408051608081018252600293909302909101805483526001015463ffffffff80821694840194909452600160201b810490931690820152600160401b90910460ff1615801560608301819052919250906109295750806040015163ffffffff164210155b156109345792915050565b508061093f81613b03565b915050610894565b505060408051608081018252600080825260208201819052918101829052606081019190915290565b61097861219a565b6001600160a01b038216600081815260d1602052604080822054905160ff9091169284151592841515927f4de6293e668df1398422e1def12118052c1539a03cbfedc145895d48d7685f1c9190a4506001600160a01b0391909116600090815260d160205260409020805460ff1916911515919091179055565b606560009054906101000a90046001600160a01b03166001600160a01b031663eab66d7a6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610a45573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a699190613b1a565b6001600160a01b0316336001600160a01b031614610aa25760405162461bcd60e51b8152600401610a9990613b37565b60405180910390fd5b610aab816121f4565b50565b60655460405163237dfb4760e11b81523360048201526001600160a01b03909116906346fbf68e90602401602060405180830381865afa158015610af6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b1a9190613b81565b610b365760405162461bcd60e51b8152600401610a9990613b9e565b60665481811614610baf5760405162461bcd60e51b815260206004820152603860248201527f5061757361626c652e70617573653a20696e76616c696420617474656d70742060448201527f746f20756e70617573652066756e6374696f6e616c69747900000000000000006064820152608401610a99565b606681905560405181815233907fab40a374bc51de372200a8bc981af8c9ecdc08dfdaef0bb6e09f88f3c616ef3d906020015b60405180910390a250565b600080610bfd6020840184613783565b8360200135604051602001610c469392919060f89390931b6001600160f81b031916835260609190911b6bffffffffffffffffffffffff19166001830152601582015260350190565b604051602081830303815290604052805190602001209050919050565b60665460019060029081161415610c8c5760405162461bcd60e51b8152600401610a9990613be6565b33600090815260d1602052604090205460ff16610cbb5760405162461bcd60e51b8152600401610a9990613c1d565b60026097541415610cde5760405162461bcd60e51b8152600401610a9990613c94565b600260975560005b82811015610e225736848483818110610d0157610d01613aed565b9050602002810190610d139190613ccb565b33600081815260ce60209081526040808320549051949550939192610d3e9290918591879101613e10565b604051602081830303815290604052805190602001209050610d5f836122eb565b33600090815260d0602090815260408083208484529091529020805460ff19166001908117909155610d92908390613e40565b33600081815260ce602052604090819020929092559051829184917f51088b8c89628df3a8174002c2a034d0152fce6af8415d651b2a4734bf27048290610dda908890613e58565b60405180910390a4610e0c333060408601803590610dfb9060208901613783565b6001600160a01b0316929190612ac3565b5050508080610e1a90613e6b565b915050610ce6565b505060016097555050565b60665460029060049081161415610e565760405162461bcd60e51b8152600401610a9990613be6565b60026097541415610e795760405162461bcd60e51b8152600401610a9990613c94565b6002609755600060ca610e8f6020860186613976565b63ffffffff1681548110610ea557610ea5613aed565b600091825260209182902060408051608081018252600293909302909101805483526001015463ffffffff80821694840194909452600160201b810490931690820152600160401b90910460ff16151560608201529050610f068482612b34565b6000610f186080860160608701613783565b6001600160a01b03808216600090815260cc60205260409020549192501680610f3e5750805b336001600160a01b03821614610fbc5760405162461bcd60e51b815260206004820152603c60248201527f52657761726473436f6f7264696e61746f722e70726f63657373436c61696d3a60448201527f2063616c6c6572206973206e6f742076616c696420636c61696d6572000000006064820152608401610a99565b60005b610fcc60a0880188613e86565b90508110156111e35736610fe360e0890189613ed7565b83818110610ff357610ff3613aed565b6001600160a01b038716600090815260cd60209081526040808320930294909401945092909150829061102890850185613783565b6001600160a01b03166001600160a01b03168152602001908152602001600020549050808260200135116110e25760405162461bcd60e51b815260206004820152605560248201527f52657761726473436f6f7264696e61746f722e70726f63657373436c61696d3a60448201527f2063756d756c61746976654561726e696e6773206d75737420626520677420746064820152741a185b8818dd5b5d5b185d1a5d9950db185a5b5959605a1b608482015260a401610a99565b60006110f2826020850135613ad6565b6001600160a01b038716600090815260cd602090815260408220929350850180359291906111209087613783565b6001600160a01b0316815260208082019290925260400160002091909155611162908a90839061115290870187613783565b6001600160a01b03169190612e00565b86516001600160a01b03808b1691878216918916907f9543dbd55580842586a951f0386e24d68a5df99ae29e3b216588b45fd684ce31906111a66020890189613783565b604080519283526001600160a01b039091166020830152810186905260600160405180910390a450505080806111db90613e6b565b915050610fbf565b505060016097555050505050565b6066546003906008908116141561121a5760405162461bcd60e51b8152600401610a9990613be6565b60cb546001600160a01b031633146112445760405162461bcd60e51b8152600401610a9990613f21565b60cb5463ffffffff600160c01b9091048116908316116112e05760405162461bcd60e51b815260206004820152604b60248201527f52657761726473436f6f7264696e61746f722e7375626d6974526f6f743a206e60448201527f657720726f6f74206d75737420626520666f72206e657765722063616c63756c60648201526a185d1959081c195c9a5bd960aa1b608482015260a401610a99565b428263ffffffff16106113795760405162461bcd60e51b815260206004820152605560248201527f52657761726473436f6f7264696e61746f722e7375626d6974526f6f743a207260448201527f65776172647343616c63756c6174696f6e456e6454696d657374616d702063616064820152746e6e6f7420626520696e207468652066757475726560581b608482015260a401610a99565b60ca5460cb5460009061139990600160a01b900463ffffffff1642613f75565b6040805160808101825287815263ffffffff878116602080840182815286841685870181815260006060880181815260ca8054600181018255925297517f42d72674974f694b5f5159593243114d38a5c39c89d6b62fee061ff523240ee160029092029182015592517f42d72674974f694b5f5159593243114d38a5c39c89d6b62fee061ff523240ee290930180549151975193871667ffffffffffffffff1990921691909117600160201b978716979097029690961760ff60401b1916600160401b921515929092029190911790945560cb805463ffffffff60c01b1916600160c01b840217905593519283529394508892908616917fecd866c3c158fa00bf34d803d5f6023000b57080bcb48af004c2b4b46b3afd08910160405180910390a45050505050565b6114ca61219a565b610aab81612e30565b60655460405163237dfb4760e11b81523360048201526001600160a01b03909116906346fbf68e90602401602060405180830381865afa15801561151b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061153f9190613b81565b61155b5760405162461bcd60e51b8152600401610a9990613b9e565b600019606681905560405190815233907fab40a374bc51de372200a8bc981af8c9ecdc08dfdaef0bb6e09f88f3c616ef3d9060200160405180910390a2565b600061161f8260ca6115af6020830183613976565b63ffffffff16815481106115c5576115c5613aed565b600091825260209182902060408051608081018252600293909302909101805483526001015463ffffffff80821694840194909452600160201b810490931690820152600160401b90910460ff1615156060820152612b34565b506001919050565b61162f61219a565b6116396000612ea1565b565b61164361219a565b610aab81612ef3565b60408051608081018252600080825260208201819052918101829052606081019190915260ca805461168090600190613ad6565b8154811061169057611690613aed565b600091825260209182902060408051608081018252600293909302909101805483526001015463ffffffff80821694840194909452600160201b810490931690820152600160401b90910460ff1615156060820152919050565b33600081815260cc602052604080822080546001600160a01b031981166001600160a01b038781169182179093559251911692839185917fbab947934d42e0ad206f25c9cab18b5bb6ae144acfb00f40b4e3aa59590ca31291a4505050565b600054610100900460ff16158080156117695750600054600160ff909116105b806117835750303b158015611783575060005460ff166001145b6117e65760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610a99565b6000805460ff191660011790558015611809576000805461ff0019166101001790555b611811612f4f565b60c95561181e8686612fe6565b61182787612ea1565b61183084612ef3565b61183983612e30565b611842826130d0565b8015611888576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b50505050505050565b60408051608081018252600080825260208201819052918101829052606081019190915260ca82815481106118c8576118c8613aed565b600091825260209182902060408051608081018252600293909302909101805483526001015463ffffffff80821694840194909452600160201b810490931690820152600160401b90910460ff161515606082015292915050565b61192b61219a565b610aab816130d0565b60ca546000905b63ffffffff8116156119a7578260ca611955600184613f9d565b63ffffffff168154811061196b5761196b613aed565b90600052602060002090600202016000015414156119955761198e600182613f9d565b9392505050565b8061199f81613fc2565b91505061193b565b5060405162461bcd60e51b815260206004820152603760248201527f52657761726473436f6f7264696e61746f722e676574526f6f74496e6465784660448201527f726f6d486173683a20726f6f74206e6f7420666f756e640000000000000000006064820152608401610a99565b611a1e61219a565b6001600160a01b038116611a835760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610a99565b610aab81612ea1565b60007f0000000000000000000000000000000000000000000000000000000000000000461415611abd575060c95490565b611ac5612f4f565b905090565b60006001610bfd6020840184613783565b60665460039060089081161415611b045760405162461bcd60e51b8152600401610a9990613be6565b60cb546001600160a01b03163314611b2e5760405162461bcd60e51b8152600401610a9990613f21565b60ca5463ffffffff831610611b9f5760405162461bcd60e51b815260206004820152603160248201527f52657761726473436f6f7264696e61746f722e64697361626c65526f6f743a206044820152700d2dcecc2d8d2c840e4dedee892dcc8caf607b1b6064820152608401610a99565b600060ca8363ffffffff1681548110611bba57611bba613aed565b906000526020600020906002020190508060010160089054906101000a900460ff1615611c475760405162461bcd60e51b815260206004820152603560248201527f52657761726473436f6f7264696e61746f722e64697361626c65526f6f743a206044820152741c9bdbdd08185b1c9958591e48191a5cd8589b1959605a1b6064820152608401610a99565b6001810154600160201b900463ffffffff164210611cc65760405162461bcd60e51b815260206004820152603660248201527f52657761726473436f6f7264696e61746f722e64697361626c65526f6f743a206044820152751c9bdbdd08185b1c9958591e481858dd1a5d985d195960521b6064820152608401610a99565b60018101805460ff60401b1916600160401b17905560405163ffffffff8416907fd850e6e5dfa497b72661fa73df2923464eaed9dc2ff1d3cb82bccbfeabe5c41e90600090a2505050565b606560009054906101000a90046001600160a01b03166001600160a01b031663eab66d7a6040518163ffffffff1660e01b8152600401602060405180830381865afa158015611d64573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d889190613b1a565b6001600160a01b0316336001600160a01b031614611db85760405162461bcd60e51b8152600401610a9990613b37565b606654198119606654191614611e365760405162461bcd60e51b815260206004820152603860248201527f5061757361626c652e756e70617573653a20696e76616c696420617474656d7060448201527f7420746f2070617573652066756e6374696f6e616c69747900000000000000006064820152608401610a99565b606681905560405181815233907f3582d1828e26bf56bd801502bc021ac0bc8afb57c826e4986b45593c8fad389c90602001610be2565b60665460009060019081161415611e965760405162461bcd60e51b8152600401610a9990613be6565b60026097541415611eb95760405162461bcd60e51b8152600401610a9990613c94565b600260975560005b82811015610e225736848483818110611edc57611edc613aed565b9050602002810190611eee9190613ccb565b33600081815260ce60209081526040808320549051949550939192611f199290918591879101613e10565b604051602081830303815290604052805190602001209050611f3a836122eb565b33600090815260cf602090815260408083208484529091529020805460ff19166001908117909155611f6d908390613e40565b33600081815260ce602052604090819020929092559051829184917f450a367a380c4e339e5ae7340c8464ef27af7781ad9945cfe8abd828f89e628190611fb5908890613e58565b60405180910390a4611fd6333060408601803590610dfb9060208901613783565b5050508080611fe490613e6b565b915050611ec1565b606654600490601090811614156120155760405162461bcd60e51b8152600401610a9990613be6565b33600090815260d1602052604090205460ff166120445760405162461bcd60e51b8152600401610a9990613c1d565b600260975414156120675760405162461bcd60e51b8152600401610a9990613c94565b600260975560005b82811015610e22573684848381811061208a5761208a613aed565b905060200281019061209c9190613ccb565b33600081815260ce602090815260408083205490519495509391926120c79290918591879101613e10565b6040516020818303038152906040528051906020012090506120e8836122eb565b33600090815260d2602090815260408083208484529091529020805460ff1916600190811790915561211b908390613e40565b33600081815260ce602052604090819020929092559051829184917f5251b6fdefcb5d81144e735f69ea4c695fd43b0289ca53dc075033f5fc80068b90612163908890613e58565b60405180910390a4612184333060408601803590610dfb9060208901613783565b505050808061219290613e6b565b91505061206f565b6033546001600160a01b031633146116395760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610a99565b6001600160a01b0381166122825760405162461bcd60e51b815260206004820152604960248201527f5061757361626c652e5f73657450617573657252656769737472793a206e657760448201527f50617573657252656769737472792063616e6e6f7420626520746865207a65726064820152686f206164647265737360b81b608482015260a401610a99565b606554604080516001600160a01b03928316815291831660208301527f6e9fcd539896fca60e8b0f01dd580233e48a6b0f7df013b89ba7f565869acdb6910160405180910390a1606580546001600160a01b0319166001600160a01b0392909216919091179055565b60006122f78280613ed7565b90501161235c576040805162461bcd60e51b815260206004820152602481019190915260008051602061411c83398151915260448201527f7264735375626d697373696f6e3a206e6f2073747261746567696573207365746064820152608401610a99565b60008160400135116123ce5760405162461bcd60e51b8152602060048201526041602482015260008051602061411c83398151915260448201527f7264735375626d697373696f6e3a20616d6f756e742063616e6e6f74206265206064820152600360fc1b608482015260a401610a99565b6f4b3b4ca85a86c47a098a223fffffffff816040013511156124465760405162461bcd60e51b815260206004820152603f602482015260008051602061411c83398151915260448201527f7264735375626d697373696f6e3a20616d6f756e7420746f6f206c61726765006064820152608401610a99565b63ffffffff7f00000000000000000000000000000000000000000000000000000000000000001661247d60a0830160808401613976565b63ffffffff1611156125025760405162461bcd60e51b8152602060048201526054602482015260008051602061411c83398151915260448201527f7264735375626d697373696f6e3a206475726174696f6e20657863656564732060648201527326a0ac2fa922aba0a92229afa22aa920aa24a7a760611b608482015260a401610a99565b7f000000000000000000000000000000000000000000000000000000000000000061253360a0830160808401613976565b61253d9190613ff8565b63ffffffff16156125dd5760405162461bcd60e51b815260206004820152606a602482015260008051602061411c83398151915260448201527f7264735375626d697373696f6e3a206475726174696f6e206d7573742062652060648201527f61206d756c7469706c65206f662043414c43554c4154494f4e5f494e54455256608482015269414c5f5345434f4e445360b01b60a482015260c401610a99565b7f000000000000000000000000000000000000000000000000000000000000000061260e6080830160608401613976565b6126189190613ff8565b63ffffffff16156126be5760405162461bcd60e51b8152602060048201526070602482015260008051602061411c83398151915260448201527f7264735375626d697373696f6e3a20737461727454696d657374616d70206d7560648201527f73742062652061206d756c7469706c65206f662043414c43554c4154494f4e5f60848201526f494e54455256414c5f5345434f4e445360801b60a482015260c401610a99565b6126ce6080820160608301613976565b63ffffffff167f000000000000000000000000000000000000000000000000000000000000000063ffffffff16426127069190613ad6565b1115801561274f575061271f6080820160608301613976565b63ffffffff167f000000000000000000000000000000000000000000000000000000000000000063ffffffff1611155b6127c95760405162461bcd60e51b8152602060048201526051602482015260008051602061411c83398151915260448201527f7264735375626d697373696f6e3a20737461727454696d657374616d7020746f6064820152701bc819985c881a5b881d1a19481c185cdd607a1b608482015260a401610a99565b6127f963ffffffff7f00000000000000000000000000000000000000000000000000000000000000001642613e40565b6128096080830160608401613976565b63ffffffff16111561288d5760405162461bcd60e51b8152602060048201526053602482015260008051602061411c83398151915260448201527f7264735375626d697373696f6e3a20737461727454696d657374616d7020746f6064820152726f2066617220696e207468652066757475726560681b608482015260a401610a99565b6000805b61289b8380613ed7565b9050811015612abe5760006128b08480613ed7565b838181106128c0576128c0613aed565b6128d69260206040909202019081019150613783565b60405163198f077960e21b81526001600160a01b0380831660048301529192507f00000000000000000000000000000000000000000000000000000000000000009091169063663c1de490602401602060405180830381865afa158015612941573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906129659190613b81565b8061298c57506001600160a01b03811673beac0eeeeeeeeeeeeeeeeeeeeeeeeeeeeeebeac0145b6129ff5760405162461bcd60e51b815260206004820152604a602482015260008051602061411c83398151915260448201527f7264735375626d697373696f6e3a20696e76616c69642073747261746567792060648201526918dbdb9cda59195c995960b21b608482015260a401610a99565b806001600160a01b0316836001600160a01b031610612aac5760405162461bcd60e51b8152602060048201526069602482015260008051602061411c83398151915260448201527f7264735375626d697373696f6e3a2073747261746567696573206d757374206260648201527f6520696e20617363656e64696e67206f7264657220746f2068616e646c65206460848201526875706c69636174657360b81b60a482015260c401610a99565b9150612ab781613e6b565b9050612891565b505050565b6040516001600160a01b0380851660248301528316604482015260648101829052612b2e9085906323b872dd60e01b906084015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b03199093169290921790915261313b565b50505050565b806060015115612b8d5760405162461bcd60e51b815260206004820152603060248201526000805160206140fc83398151915260448201526f1c9bdbdd081a5cc8191a5cd8589b195960821b6064820152608401610a99565b806040015163ffffffff16421015612bf45760405162461bcd60e51b815260206004820152603660248201526000805160206140fc8339815191526044820152751c9bdbdd081b9bdd081858dd1a5d985d1959081e595d60521b6064820152608401610a99565b612c0160c0830183613e86565b9050612c1060a0840184613e86565b905014612c885760405162461bcd60e51b815260206004820152604c60248201526000805160206140fc83398151915260448201527f746f6b656e496e646963657320616e6420746f6b656e50726f6f6673206c656e60648201526b0cee8d040dad2e6dac2e8c6d60a31b608482015260a401610a99565b612c9560e0830183613ed7565b9050612ca460c0840184613e86565b905014612d1a5760405162461bcd60e51b815260206004820152604a60248201526000805160206140fc83398151915260448201527f746f6b656e5472656550726f6f667320616e64206c6561766573206c656e67746064820152690d040dad2e6dac2e8c6d60b31b608482015260a401610a99565b8051612d4690612d306040850160208601613976565b612d3d604086018661401b565b8660600161320d565b60005b612d5660a0840184613e86565b9050811015612abe57612df06080840135612d7460a0860186613e86565b84818110612d8457612d84613aed565b9050602002016020810190612d999190613976565b612da660c0870187613e86565b85818110612db657612db6613aed565b9050602002810190612dc8919061401b565b612dd560e0890189613ed7565b87818110612de557612de5613aed565b905060400201613381565b612df981613e6b565b9050612d49565b6040516001600160a01b038316602482015260448101829052612abe90849063a9059cbb60e01b90606401612af7565b60cb546040805163ffffffff600160a01b9093048316815291831660208301527faf557c6c02c208794817a705609cfa935f827312a1adfdd26494b6b95dd2b4b3910160405180910390a160cb805463ffffffff909216600160a01b0263ffffffff60a01b19909216919091179055565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60cb546040516001600160a01b038084169216907f237b82f438d75fc568ebab484b75b01d9287b9e98b490b7c23221623b6705dbb90600090a360cb80546001600160a01b0319166001600160a01b0392909216919091179055565b604080518082018252600a81526922b4b3b2b72630bcb2b960b11b60209182015281517f8cad95687ba82c2ce50e74f7b754645e5117c3a5bec8151c0726d5857980a866818301527f71b625cfad44bac63b13dba07f2e1d6084ee04b6f8752101ece6126d584ee6ea81840152466060820152306080808301919091528351808303909101815260a0909101909252815191012090565b6065546001600160a01b031615801561300757506001600160a01b03821615155b6130895760405162461bcd60e51b815260206004820152604760248201527f5061757361626c652e5f696e697469616c697a655061757365723a205f696e6960448201527f7469616c697a6550617573657228292063616e206f6e6c792062652063616c6c6064820152666564206f6e636560c81b608482015260a401610a99565b606681905560405181815233907fab40a374bc51de372200a8bc981af8c9ecdc08dfdaef0bb6e09f88f3c616ef3d9060200160405180910390a26130cc826121f4565b5050565b60cb546040805161ffff600160e01b9093048316815291831660208301527f8cdc428b0431b82d1619763f443a48197db344ba96905f3949643acd1c863a06910160405180910390a160cb805461ffff909216600160e01b0261ffff60e01b19909216919091179055565b6000613190826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166134d29092919063ffffffff16565b805190915015612abe57808060200190518101906131ae9190613b81565b612abe5760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b6064820152608401610a99565b613218602083614062565b6001901b8463ffffffff16106132a25760405162461bcd60e51b815260206004820152604360248201527f52657761726473436f6f7264696e61746f722e5f7665726966794561726e657260448201527f436c61696d50726f6f663a20696e76616c6964206561726e65724c656166496e6064820152620c8caf60eb1b608482015260a401610a99565b60006132ad82610bed565b90506132f884848080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508a92508591505063ffffffff89166134e9565b6133795760405162461bcd60e51b815260206004820152604660248201527f52657761726473436f6f7264696e61746f722e5f7665726966794561726e657260448201527f436c61696d50726f6f663a20696e76616c6964206561726e657220636c61696d60648201526510383937b7b360d11b608482015260a401610a99565b505050505050565b61338c602083614062565b6001901b8463ffffffff161061340a5760405162461bcd60e51b815260206004820152603c60248201527f52657761726473436f6f7264696e61746f722e5f766572696679546f6b656e4360448201527f6c61696d3a20696e76616c696420746f6b656e4c656166496e646578000000006064820152608401610a99565b600061341582611aca565b905061346084848080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508a92508591505063ffffffff89166134e9565b6133795760405162461bcd60e51b815260206004820152603f60248201527f52657761726473436f6f7264696e61746f722e5f766572696679546f6b656e4360448201527f6c61696d3a20696e76616c696420746f6b656e20636c61696d2070726f6f66006064820152608401610a99565b60606134e18484600085613501565b949350505050565b6000836134f7868585613632565b1495945050505050565b6060824710156135625760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b6064820152608401610a99565b6001600160a01b0385163b6135b95760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610a99565b600080866001600160a01b031685876040516135d591906140a2565b60006040518083038185875af1925050503d8060008114613612576040519150601f19603f3d011682016040523d82523d6000602084013e613617565b606091505b5091509150613627828286613735565b979650505050505050565b60006020845161364291906140b4565b156136c95760405162461bcd60e51b815260206004820152604b60248201527f4d65726b6c652e70726f63657373496e636c7573696f6e50726f6f664b65636360448201527f616b3a2070726f6f66206c656e6774682073686f756c642062652061206d756c60648201526a3a34b836329037b310199960a91b608482015260a401610a99565b8260205b8551811161372c576136e06002856140b4565b6137015781600052808601516020526040600020915060028404935061371a565b8086015160005281602052604060002091506002840493505b613725602082613e40565b90506136cd565b50949350505050565b6060831561374457508161198e565b8251156137545782518084602001fd5b8160405162461bcd60e51b8152600401610a9991906140c8565b6001600160a01b0381168114610aab57600080fd5b60006020828403121561379557600080fd5b813561198e8161376e565b8015158114610aab57600080fd5b600080604083850312156137c157600080fd5b82356137cc8161376e565b915060208301356137dc816137a0565b809150509250929050565b6000602082840312156137f957600080fd5b5035919050565b60006040828403121561381257600080fd5b50919050565b60006040828403121561382a57600080fd5b61198e8383613800565b6000806040838503121561384757600080fd5b82356138528161376e565b915060208301356137dc8161376e565b6000806020838503121561387557600080fd5b823567ffffffffffffffff8082111561388d57600080fd5b818501915085601f8301126138a157600080fd5b8135818111156138b057600080fd5b8660208260051b85010111156138c557600080fd5b60209290920196919550909350505050565b6000610100828403121561381257600080fd5b600080604083850312156138fd57600080fd5b823567ffffffffffffffff81111561391457600080fd5b613920858286016138d7565b92505060208301356137dc8161376e565b803563ffffffff8116811461394557600080fd5b919050565b6000806040838503121561395d57600080fd5b8235915061396d60208401613931565b90509250929050565b60006020828403121561398857600080fd5b61198e82613931565b6000602082840312156139a357600080fd5b813560ff8116811461198e57600080fd5b6000602082840312156139c657600080fd5b813567ffffffffffffffff8111156139dd57600080fd5b6134e1848285016138d7565b600080604083850312156139fc57600080fd5b8235613a078161376e565b946020939093013593505050565b80356139458161376e565b803561ffff8116811461394557600080fd5b60008060008060008060c08789031215613a4b57600080fd5b8635613a568161376e565b95506020870135613a668161376e565b9450604087013593506060870135613a7d8161376e565b9250613a8b60808801613931565b9150613a9960a08801613a20565b90509295509295509295565b600060208284031215613ab757600080fd5b61198e82613a20565b634e487b7160e01b600052601160045260246000fd5b600082821015613ae857613ae8613ac0565b500390565b634e487b7160e01b600052603260045260246000fd5b600081613b1257613b12613ac0565b506000190190565b600060208284031215613b2c57600080fd5b815161198e8161376e565b6020808252602a908201527f6d73672e73656e646572206973206e6f74207065726d697373696f6e6564206160408201526939903ab73830bab9b2b960b11b606082015260800190565b600060208284031215613b9357600080fd5b815161198e816137a0565b60208082526028908201527f6d73672e73656e646572206973206e6f74207065726d697373696f6e6564206160408201526739903830bab9b2b960c11b606082015260800190565b60208082526019908201527f5061757361626c653a20696e6465782069732070617573656400000000000000604082015260600190565b60208082526051908201527f52657761726473436f6f7264696e61746f723a2063616c6c6572206973206e6f60408201527f7420612076616c69642063726561746552657761726473466f72416c6c53756260608201527036b4b9b9b4b7b71039bab136b4ba3a32b960791b608082015260a00190565b6020808252601f908201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604082015260600190565b60008235609e19833603018112613ce157600080fd5b9190910192915050565b818352600060208085019450826000805b86811015613d50578235613d0f8161376e565b6001600160a01b03168852828401356bffffffffffffffffffffffff8116808214613d38578384fd5b89860152506040978801979290920191600101613cfc565b50959695505050505050565b60008135601e19833603018112613d7257600080fd5b8201803567ffffffffffffffff811115613d8b57600080fd5b8060061b3603841315613d9d57600080fd5b60a08552613db260a086018260208501613ceb565b915050613dc160208401613a15565b6001600160a01b0316602085015260408381013590850152613de560608401613931565b63ffffffff166060850152613dfc60808401613931565b63ffffffff81166080860152509392505050565b60018060a01b0384168152826020820152606060408201526000613e376060830184613d5c565b95945050505050565b60008219821115613e5357613e53613ac0565b500190565b60208152600061198e6020830184613d5c565b6000600019821415613e7f57613e7f613ac0565b5060010190565b6000808335601e19843603018112613e9d57600080fd5b83018035915067ffffffffffffffff821115613eb857600080fd5b6020019150600581901b3603821315613ed057600080fd5b9250929050565b6000808335601e19843603018112613eee57600080fd5b83018035915067ffffffffffffffff821115613f0957600080fd5b6020019150600681901b3603821315613ed057600080fd5b60208082526034908201527f52657761726473436f6f7264696e61746f723a2063616c6c6572206973206e6f6040820152733a103a3432903932bbb0b93239aab83230ba32b960611b606082015260800190565b600063ffffffff808316818516808303821115613f9457613f94613ac0565b01949350505050565b600063ffffffff83811690831681811015613fba57613fba613ac0565b039392505050565b600063ffffffff821680613fd857613fd8613ac0565b6000190192915050565b634e487b7160e01b600052601260045260246000fd5b600063ffffffff8084168061400f5761400f613fe2565b92169190910692915050565b6000808335601e1984360301811261403257600080fd5b83018035915067ffffffffffffffff82111561404d57600080fd5b602001915036819003821315613ed057600080fd5b60008261407157614071613fe2565b500490565b60005b83811015614091578181015183820152602001614079565b83811115612b2e5750506000910152565b60008251613ce1818460208701614076565b6000826140c3576140c3613fe2565b500690565b60208152600082518060208401526140e7816040850160208701614076565b601f01601f1916919091016040019291505056fe52657761726473436f6f7264696e61746f722e5f636865636b436c61696d3a2052657761726473436f6f7264696e61746f722e5f76616c696461746552657761a26469706673582212203b6aebaf69ddd8437d9691d3e48219d37fef7746b74aca6c6e347d0e4c279cbd64736f6c634300080c0033", + ABI: "[{\"type\":\"constructor\",\"inputs\":[{\"name\":\"_delegationManager\",\"type\":\"address\",\"internalType\":\"contractIDelegationManager\"},{\"name\":\"_strategyManager\",\"type\":\"address\",\"internalType\":\"contractIStrategyManager\"},{\"name\":\"_CALCULATION_INTERVAL_SECONDS\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"_MAX_REWARDS_DURATION\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"_MAX_RETROACTIVE_LENGTH\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"_MAX_FUTURE_LENGTH\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"__GENESIS_REWARDS_TIMESTAMP\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"CALCULATION_INTERVAL_SECONDS\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"GENESIS_REWARDS_TIMESTAMP\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"MAX_FUTURE_LENGTH\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"MAX_RETROACTIVE_LENGTH\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"MAX_REWARDS_DURATION\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"activationDelay\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"beaconChainETHStrategy\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"calculateEarnerLeafHash\",\"inputs\":[{\"name\":\"leaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.EarnerTreeMerkleLeaf\",\"components\":[{\"name\":\"earner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"earnerTokenRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"pure\"},{\"type\":\"function\",\"name\":\"calculateTokenLeafHash\",\"inputs\":[{\"name\":\"leaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.TokenTreeMerkleLeaf\",\"components\":[{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"cumulativeEarnings\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"pure\"},{\"type\":\"function\",\"name\":\"checkClaim\",\"inputs\":[{\"name\":\"claim\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.RewardsMerkleClaim\",\"components\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerTreeProof\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"earnerLeaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.EarnerTreeMerkleLeaf\",\"components\":[{\"name\":\"earner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"earnerTokenRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]},{\"name\":\"tokenIndices\",\"type\":\"uint32[]\",\"internalType\":\"uint32[]\"},{\"name\":\"tokenTreeProofs\",\"type\":\"bytes[]\",\"internalType\":\"bytes[]\"},{\"name\":\"tokenLeaves\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.TokenTreeMerkleLeaf[]\",\"components\":[{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"cumulativeEarnings\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]}]}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"claimerFor\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"createAVSRewardsSubmission\",\"inputs\":[{\"name\":\"rewardsSubmissions\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.RewardsSubmission[]\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"createOperatorDirectedAVSRewardsSubmission\",\"inputs\":[{\"name\":\"avs\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"operatorDirectedRewardsSubmissions\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.OperatorDirectedRewardsSubmission[]\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"operatorRewards\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.OperatorReward[]\",\"components\":[{\"name\":\"operator\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"description\",\"type\":\"string\",\"internalType\":\"string\"}]}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"createRewardsForAllEarners\",\"inputs\":[{\"name\":\"rewardsSubmissions\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.RewardsSubmission[]\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"createRewardsForAllSubmission\",\"inputs\":[{\"name\":\"rewardsSubmissions\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.RewardsSubmission[]\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"cumulativeClaimed\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIERC20\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"currRewardsCalculationEndTimestamp\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"defaultOperatorSplitBips\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"delegationManager\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIDelegationManager\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"disableRoot\",\"inputs\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"domainSeparator\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getCurrentClaimableDistributionRoot\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.DistributionRoot\",\"components\":[{\"name\":\"root\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"disabled\",\"type\":\"bool\",\"internalType\":\"bool\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getCurrentDistributionRoot\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.DistributionRoot\",\"components\":[{\"name\":\"root\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"disabled\",\"type\":\"bool\",\"internalType\":\"bool\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getDistributionRootAtIndex\",\"inputs\":[{\"name\":\"index\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.DistributionRoot\",\"components\":[{\"name\":\"root\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"disabled\",\"type\":\"bool\",\"internalType\":\"bool\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getDistributionRootsLength\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getOperatorAVSSplit\",\"inputs\":[{\"name\":\"operator\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"avs\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getOperatorPISplit\",\"inputs\":[{\"name\":\"operator\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getRootIndexFromHash\",\"inputs\":[{\"name\":\"rootHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"initialize\",\"inputs\":[{\"name\":\"initialOwner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_pauserRegistry\",\"type\":\"address\",\"internalType\":\"contractIPauserRegistry\"},{\"name\":\"initialPausedStatus\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_rewardsUpdater\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_activationDelay\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"_defaultSplitBips\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"isAVSRewardsSubmissionHash\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"isOperatorDirectedAVSRewardsSubmissionHash\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"isRewardsForAllSubmitter\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"isRewardsSubmissionForAllEarnersHash\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"isRewardsSubmissionForAllHash\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"owner\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"pause\",\"inputs\":[{\"name\":\"newPausedStatus\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"pauseAll\",\"inputs\":[],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"paused\",\"inputs\":[{\"name\":\"index\",\"type\":\"uint8\",\"internalType\":\"uint8\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"paused\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"pauserRegistry\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIPauserRegistry\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"processClaim\",\"inputs\":[{\"name\":\"claim\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.RewardsMerkleClaim\",\"components\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerTreeProof\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"earnerLeaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.EarnerTreeMerkleLeaf\",\"components\":[{\"name\":\"earner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"earnerTokenRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]},{\"name\":\"tokenIndices\",\"type\":\"uint32[]\",\"internalType\":\"uint32[]\"},{\"name\":\"tokenTreeProofs\",\"type\":\"bytes[]\",\"internalType\":\"bytes[]\"},{\"name\":\"tokenLeaves\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.TokenTreeMerkleLeaf[]\",\"components\":[{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"cumulativeEarnings\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]}]},{\"name\":\"recipient\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"processClaims\",\"inputs\":[{\"name\":\"claims\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.RewardsMerkleClaim[]\",\"components\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerTreeProof\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"earnerLeaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.EarnerTreeMerkleLeaf\",\"components\":[{\"name\":\"earner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"earnerTokenRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]},{\"name\":\"tokenIndices\",\"type\":\"uint32[]\",\"internalType\":\"uint32[]\"},{\"name\":\"tokenTreeProofs\",\"type\":\"bytes[]\",\"internalType\":\"bytes[]\"},{\"name\":\"tokenLeaves\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.TokenTreeMerkleLeaf[]\",\"components\":[{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"cumulativeEarnings\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]}]},{\"name\":\"recipient\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"renounceOwnership\",\"inputs\":[],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"rewardsUpdater\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"setActivationDelay\",\"inputs\":[{\"name\":\"_activationDelay\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setClaimerFor\",\"inputs\":[{\"name\":\"claimer\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setDefaultOperatorSplit\",\"inputs\":[{\"name\":\"split\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setOperatorAVSSplit\",\"inputs\":[{\"name\":\"operator\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"avs\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"split\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setOperatorPISplit\",\"inputs\":[{\"name\":\"operator\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"split\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setPauserRegistry\",\"inputs\":[{\"name\":\"newPauserRegistry\",\"type\":\"address\",\"internalType\":\"contractIPauserRegistry\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setRewardsForAllSubmitter\",\"inputs\":[{\"name\":\"_submitter\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_newValue\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setRewardsUpdater\",\"inputs\":[{\"name\":\"_rewardsUpdater\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"strategyManager\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIStrategyManager\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"submissionNonce\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"submitRoot\",\"inputs\":[{\"name\":\"root\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"transferOwnership\",\"inputs\":[{\"name\":\"newOwner\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"unpause\",\"inputs\":[{\"name\":\"newPausedStatus\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"event\",\"name\":\"AVSRewardsSubmissionCreated\",\"inputs\":[{\"name\":\"avs\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"submissionNonce\",\"type\":\"uint256\",\"indexed\":true,\"internalType\":\"uint256\"},{\"name\":\"rewardsSubmissionHash\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"rewardsSubmission\",\"type\":\"tuple\",\"indexed\":false,\"internalType\":\"structIRewardsCoordinator.RewardsSubmission\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ActivationDelaySet\",\"inputs\":[{\"name\":\"oldActivationDelay\",\"type\":\"uint32\",\"indexed\":false,\"internalType\":\"uint32\"},{\"name\":\"newActivationDelay\",\"type\":\"uint32\",\"indexed\":false,\"internalType\":\"uint32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ClaimerForSet\",\"inputs\":[{\"name\":\"earner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"oldClaimer\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"claimer\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"DefaultOperatorSplitBipsSet\",\"inputs\":[{\"name\":\"oldDefaultOperatorSplitBips\",\"type\":\"uint16\",\"indexed\":false,\"internalType\":\"uint16\"},{\"name\":\"newDefaultOperatorSplitBips\",\"type\":\"uint16\",\"indexed\":false,\"internalType\":\"uint16\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"DistributionRootDisabled\",\"inputs\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"indexed\":true,\"internalType\":\"uint32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"DistributionRootSubmitted\",\"inputs\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"indexed\":true,\"internalType\":\"uint32\"},{\"name\":\"root\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"indexed\":true,\"internalType\":\"uint32\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"indexed\":false,\"internalType\":\"uint32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"Initialized\",\"inputs\":[{\"name\":\"version\",\"type\":\"uint8\",\"indexed\":false,\"internalType\":\"uint8\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"OperatorAVSSplitBipsSet\",\"inputs\":[{\"name\":\"caller\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"operator\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"avs\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"indexed\":false,\"internalType\":\"uint32\"},{\"name\":\"oldOperatorAVSSplitBips\",\"type\":\"uint16\",\"indexed\":false,\"internalType\":\"uint16\"},{\"name\":\"newOperatorAVSSplitBips\",\"type\":\"uint16\",\"indexed\":false,\"internalType\":\"uint16\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"OperatorDirectedAVSRewardsSubmissionCreated\",\"inputs\":[{\"name\":\"caller\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"avs\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"operatorDirectedRewardsSubmissionHash\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"submissionNonce\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"operatorDirectedRewardsSubmission\",\"type\":\"tuple\",\"indexed\":false,\"internalType\":\"structIRewardsCoordinator.OperatorDirectedRewardsSubmission\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"operatorRewards\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.OperatorReward[]\",\"components\":[{\"name\":\"operator\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"description\",\"type\":\"string\",\"internalType\":\"string\"}]}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"OperatorPISplitBipsSet\",\"inputs\":[{\"name\":\"caller\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"operator\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"indexed\":false,\"internalType\":\"uint32\"},{\"name\":\"oldOperatorPISplitBips\",\"type\":\"uint16\",\"indexed\":false,\"internalType\":\"uint16\"},{\"name\":\"newOperatorPISplitBips\",\"type\":\"uint16\",\"indexed\":false,\"internalType\":\"uint16\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"OwnershipTransferred\",\"inputs\":[{\"name\":\"previousOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"Paused\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newPausedStatus\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"PauserRegistrySet\",\"inputs\":[{\"name\":\"pauserRegistry\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"contractIPauserRegistry\"},{\"name\":\"newPauserRegistry\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"contractIPauserRegistry\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsClaimed\",\"inputs\":[{\"name\":\"root\",\"type\":\"bytes32\",\"indexed\":false,\"internalType\":\"bytes32\"},{\"name\":\"earner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"claimer\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"token\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"contractIERC20\"},{\"name\":\"claimedAmount\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsForAllSubmitterSet\",\"inputs\":[{\"name\":\"rewardsForAllSubmitter\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"oldValue\",\"type\":\"bool\",\"indexed\":true,\"internalType\":\"bool\"},{\"name\":\"newValue\",\"type\":\"bool\",\"indexed\":true,\"internalType\":\"bool\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsSubmissionForAllCreated\",\"inputs\":[{\"name\":\"submitter\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"submissionNonce\",\"type\":\"uint256\",\"indexed\":true,\"internalType\":\"uint256\"},{\"name\":\"rewardsSubmissionHash\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"rewardsSubmission\",\"type\":\"tuple\",\"indexed\":false,\"internalType\":\"structIRewardsCoordinator.RewardsSubmission\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsSubmissionForAllEarnersCreated\",\"inputs\":[{\"name\":\"tokenHopper\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"submissionNonce\",\"type\":\"uint256\",\"indexed\":true,\"internalType\":\"uint256\"},{\"name\":\"rewardsSubmissionHash\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"rewardsSubmission\",\"type\":\"tuple\",\"indexed\":false,\"internalType\":\"structIRewardsCoordinator.RewardsSubmission\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsUpdaterSet\",\"inputs\":[{\"name\":\"oldRewardsUpdater\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newRewardsUpdater\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"Unpaused\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newPausedStatus\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false}]", + Bin: "0x6101806040523480156200001257600080fd5b506040516200572e3803806200572e8339810160408190526200003591620002e4565b868686868686866200004885826200037e565b63ffffffff1615620000ed5760405162461bcd60e51b815260206004820152606060248201527f52657761726473436f6f7264696e61746f723a2047454e455349535f5245574160448201527f5244535f54494d455354414d50206d7573742062652061206d756c7469706c6560648201527f206f662043414c43554c4154494f4e5f494e54455256414c5f5345434f4e4453608482015260a4015b60405180910390fd5b620000fc62015180866200037e565b63ffffffff16156200019d5760405162461bcd60e51b815260206004820152605760248201527f52657761726473436f6f7264696e61746f723a2043414c43554c4154494f4e5f60448201527f494e54455256414c5f5345434f4e4453206d7573742062652061206d756c746960648201527f706c65206f6620534e415053484f545f434144454e4345000000000000000000608482015260a401620000e4565b6001600160a01b0396871661012052949095166101405263ffffffff92831660805290821660a052811660c05291821660e0521661010052620001df620001f2565b5050466101605250620003b09350505050565b600054610100900460ff16156200025c5760405162461bcd60e51b815260206004820152602760248201527f496e697469616c697a61626c653a20636f6e747261637420697320696e697469604482015266616c697a696e6760c81b6064820152608401620000e4565b60005460ff9081161015620002af576000805460ff191660ff9081179091556040519081527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b565b6001600160a01b0381168114620002c757600080fd5b50565b805163ffffffff81168114620002df57600080fd5b919050565b600080600080600080600060e0888a0312156200030057600080fd5b87516200030d81620002b1565b60208901519097506200032081620002b1565b95506200033060408901620002ca565b94506200034060608901620002ca565b93506200035060808901620002ca565b92506200036060a08901620002ca565b91506200037060c08901620002ca565b905092959891949750929550565b600063ffffffff80841680620003a457634e487b7160e01b600052601260045260246000fd5b92169190910692915050565b60805160a05160c05160e051610100516101205161014051610160516152e762000447600039600061206e0152600081816105460152613d6f015260006108a00152600081816104700152613c690152600081816103c40152612a1301526000818161051f0152613c270152600081816107ec01526139c401526000818161073e01528181613a7d0152613b4d01526152e76000f3fe608060405234801561001057600080fd5b50600436106103825760003560e01c8063865c6953116101de578063d4540a551161010f578063f2fde38b116100ad578063fabc1cbc1161007c578063fabc1cbc14610931578063fbf1e2c114610944578063fce36c7d14610957578063ff9f6cce1461096a57600080fd5b8063f2fde38b146108f0578063f698da2514610903578063f8cd84481461090b578063f96abf2e1461091e57600080fd5b8063e063f81f116100e9578063e063f81f14610875578063e810ce2114610888578063ea4d3c9b1461089b578063ed71e6a2146108c257600080fd5b8063d4540a551461083c578063dcbb03b31461084f578063de02e5031461086257600080fd5b8063a0169ddd1161017c578063b3dbb0e011610156578063b3dbb0e0146107b4578063bb7e451f146107c7578063bf21a8aa146107e7578063c46db6061461080e57600080fd5b8063a0169ddd14610760578063a50a1d9c14610773578063aebd8bae1461078657600080fd5b80639104c319116101b85780639104c319146107035780639be3d4e41461071e5780639cb9a5fa146107265780639d45c2811461073957600080fd5b8063865c6953146106b4578063886f1195146106df5780638da5cb5b146106f257600080fd5b80633efe1db6116102b85780635c975abb116102565780636d21117e116102305780636d21117e14610663578063715018a6146106915780637b8f8b0514610699578063863cb9a9146106a157600080fd5b80635c975abb146106335780635e9d83481461063b57806363f6a7981461064e57600080fd5b80634d18cc35116102925780634d18cc35146105de57806358baaa3e146105f5578063595c6a67146106085780635ac86ab71461061057600080fd5b80633efe1db6146105925780634596021c146105a55780634b943960146105b857600080fd5b8063149bc8721161032557806337838ed0116102ff57806337838ed01461051a57806339b70e38146105415780633a8c0786146105685780633ccc861d1461057f57600080fd5b8063149bc872146104a55780632b9f64a4146104c657806336af41fa1461050757600080fd5b80630eb38345116103615780630eb383451461044357806310d67a2f14610458578063131433b41461046b578063136439dd1461049257600080fd5b806218572c1461038757806304a0c502146103bf5780630e9a53cf146103fb575b600080fd5b6103aa6103953660046145b1565b60d16020526000908152604090205460ff1681565b60405190151581526020015b60405180910390f35b6103e67f000000000000000000000000000000000000000000000000000000000000000081565b60405163ffffffff90911681526020016103b6565b61040361097d565b604080518251815260208084015163ffffffff908116918301919091528383015116918101919091526060918201511515918101919091526080016103b6565b6104566104513660046145dc565b610a81565b005b6104566104663660046145b1565b610b03565b6103e67f000000000000000000000000000000000000000000000000000000000000000081565b6104566104a0366004614615565b610bbf565b6104b86104b3366004614646565b610cfe565b6040519081526020016103b6565b6104ef6104d43660046145b1565b60cc602052600090815260409020546001600160a01b031681565b6040516001600160a01b0390911681526020016103b6565b6104566105153660046146ae565b610d74565b6103e67f000000000000000000000000000000000000000000000000000000000000000081565b6104ef7f000000000000000000000000000000000000000000000000000000000000000081565b60cb546103e690600160a01b900463ffffffff1681565b61045661058d366004614703565b610f3e565b6104566105a036600461475e565b610fa3565b6104566105b336600461478a565b611274565b6105cb6105c63660046145b1565b61131b565b60405161ffff90911681526020016103b6565b60cb546103e690600160c01b900463ffffffff1681565b6104566106033660046147e1565b611377565b610456611388565b6103aa61061e3660046147fc565b606654600160ff9092169190911b9081161490565b6066546104b8565b6103aa61064936600461481f565b61144f565b60cb546105cb90600160e01b900461ffff1681565b6103aa610671366004614854565b60cf60209081526000928352604080842090915290825290205460ff1681565b6104566114dc565b60ca546104b8565b6104566106af3660046145b1565b6114f0565b6104b86106c2366004614880565b60cd60209081526000928352604080842090915290825290205481565b6065546104ef906001600160a01b031681565b6033546001600160a01b03166104ef565b6104ef73beac0eeeeeeeeeeeeeeeeeeeeeeeeeeeeeebeac081565b610403611501565b6104566107343660046148ae565b61159f565b6103e67f000000000000000000000000000000000000000000000000000000000000000081565b61045661076e3660046145b1565b6117d8565b610456610781366004614915565b611837565b6103aa610794366004614854565b60d260209081526000928352604080842090915290825290205460ff1681565b6104566107c2366004614930565b611848565b6104b86107d53660046145b1565b60ce6020526000908152604090205481565b6103e67f000000000000000000000000000000000000000000000000000000000000000081565b6103aa61081c366004614854565b60d060209081526000928352604080842090915290825290205460ff1681565b61045661084a36600461495c565b611a7b565b61045661085d3660046149cf565b611bc3565b610403610870366004614615565b611e1a565b6105cb610883366004614880565b611eac565b6103e6610896366004614615565b611f19565b6104ef7f000000000000000000000000000000000000000000000000000000000000000081565b6103aa6108d0366004614854565b60d360209081526000928352604080842090915290825290205460ff1681565b6104566108fe3660046145b1565b611ff4565b6104b861206a565b6104b8610919366004614646565b6120a8565b61045661092c3660046147e1565b6120b9565b61045661093f366004614615565b6122ef565b60cb546104ef906001600160a01b031681565b6104566109653660046146ae565b61244b565b6104566109783660046146ae565b6125ca565b60408051608081018252600080825260208201819052918101829052606081019190915260ca545b8015610a5857600060ca6109ba600184614a2c565b815481106109ca576109ca614a43565b600091825260209182902060408051608081018252600293909302909101805483526001015463ffffffff80821694840194909452600160201b810490931690820152600160401b90910460ff161580156060830181905291925090610a3a5750806040015163ffffffff164210155b15610a455792915050565b5080610a5081614a59565b9150506109a5565b505060408051608081018252600080825260208201819052918101829052606081019190915290565b610a89612778565b6001600160a01b038216600081815260d1602052604080822054905160ff9091169284151592841515927f4de6293e668df1398422e1def12118052c1539a03cbfedc145895d48d7685f1c9190a4506001600160a01b0391909116600090815260d160205260409020805460ff1916911515919091179055565b606560009054906101000a90046001600160a01b03166001600160a01b031663eab66d7a6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610b56573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b7a9190614a70565b6001600160a01b0316336001600160a01b031614610bb35760405162461bcd60e51b8152600401610baa90614a8d565b60405180910390fd5b610bbc816127d2565b50565b60655460405163237dfb4760e11b81523360048201526001600160a01b03909116906346fbf68e90602401602060405180830381865afa158015610c07573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c2b9190614ad7565b610c475760405162461bcd60e51b8152600401610baa90614af4565b60665481811614610cc05760405162461bcd60e51b815260206004820152603860248201527f5061757361626c652e70617573653a20696e76616c696420617474656d70742060448201527f746f20756e70617573652066756e6374696f6e616c69747900000000000000006064820152608401610baa565b606681905560405181815233907fab40a374bc51de372200a8bc981af8c9ecdc08dfdaef0bb6e09f88f3c616ef3d906020015b60405180910390a250565b600080610d0e60208401846145b1565b8360200135604051602001610d579392919060f89390931b6001600160f81b031916835260609190911b6bffffffffffffffffffffffff19166001830152601582015260350190565b604051602081830303815290604052805190602001209050919050565b60665460019060029081161415610d9d5760405162461bcd60e51b8152600401610baa90614b3c565b33600090815260d1602052604090205460ff16610dcc5760405162461bcd60e51b8152600401610baa90614b73565b60026097541415610def5760405162461bcd60e51b8152600401610baa90614bea565b600260975560005b82811015610f335736848483818110610e1257610e12614a43565b9050602002810190610e249190614c21565b33600081815260ce60209081526040808320549051949550939192610e4f9290918591879101614d7a565b604051602081830303815290604052805190602001209050610e70836128c9565b33600090815260d0602090815260408083208484529091529020805460ff19166001908117909155610ea3908390614daa565b33600081815260ce602052604090819020929092559051829184917f51088b8c89628df3a8174002c2a034d0152fce6af8415d651b2a4734bf27048290610eeb908890614dc2565b60405180910390a4610f1d333060408601803590610f0c90602089016145b1565b6001600160a01b0316929190612adf565b5050508080610f2b90614dd5565b915050610df7565b505060016097555050565b60665460029060049081161415610f675760405162461bcd60e51b8152600401610baa90614b3c565b60026097541415610f8a5760405162461bcd60e51b8152600401610baa90614bea565b6002609755610f998383612b50565b5050600160975550565b60665460039060089081161415610fcc5760405162461bcd60e51b8152600401610baa90614b3c565b60cb546001600160a01b03163314610ff65760405162461bcd60e51b8152600401610baa90614df0565b60cb5463ffffffff600160c01b9091048116908316116110925760405162461bcd60e51b815260206004820152604b60248201527f52657761726473436f6f7264696e61746f722e7375626d6974526f6f743a206e60448201527f657720726f6f74206d75737420626520666f72206e657765722063616c63756c60648201526a185d1959081c195c9a5bd960aa1b608482015260a401610baa565b428263ffffffff161061112b5760405162461bcd60e51b815260206004820152605560248201527f52657761726473436f6f7264696e61746f722e7375626d6974526f6f743a207260448201527f65776172647343616c63756c6174696f6e456e6454696d657374616d702063616064820152746e6e6f7420626520696e207468652066757475726560581b608482015260a401610baa565b60ca5460cb5460009061114b90600160a01b900463ffffffff1642614e44565b6040805160808101825287815263ffffffff878116602080840182815286841685870181815260006060880181815260ca8054600181018255925297517f42d72674974f694b5f5159593243114d38a5c39c89d6b62fee061ff523240ee160029092029182015592517f42d72674974f694b5f5159593243114d38a5c39c89d6b62fee061ff523240ee290930180549151975193871667ffffffffffffffff1990921691909117600160201b978716979097029690961760ff60401b1916600160401b921515929092029190911790945560cb805463ffffffff60c01b1916600160c01b840217905593519283529394508892908616917fecd866c3c158fa00bf34d803d5f6023000b57080bcb48af004c2b4b46b3afd08910160405180910390a45050505050565b6066546002906004908116141561129d5760405162461bcd60e51b8152600401610baa90614b3c565b600260975414156112c05760405162461bcd60e51b8152600401610baa90614bea565b600260975560005b8381101561130f576112fd8585838181106112e5576112e5614a43565b90506020028101906112f79190614e6c565b84612b50565b8061130781614dd5565b9150506112c8565b50506001609755505050565b6001600160a01b038116600090815260d5602090815260408083208151606081018352905461ffff80821683526201000082041693820193909352600160201b90920463ffffffff169082015261137190612ebd565b92915050565b61137f612778565b610bbc81612f0b565b60655460405163237dfb4760e11b81523360048201526001600160a01b03909116906346fbf68e90602401602060405180830381865afa1580156113d0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113f49190614ad7565b6114105760405162461bcd60e51b8152600401610baa90614af4565b600019606681905560405190815233907fab40a374bc51de372200a8bc981af8c9ecdc08dfdaef0bb6e09f88f3c616ef3d9060200160405180910390a2565b60006114d48260ca61146460208301836147e1565b63ffffffff168154811061147a5761147a614a43565b600091825260209182902060408051608081018252600293909302909101805483526001015463ffffffff80821694840194909452600160201b810490931690820152600160401b90910460ff1615156060820152612f7c565b506001919050565b6114e4612778565b6114ee600061324d565b565b6114f8612778565b610bbc8161329f565b60408051608081018252600080825260208201819052918101829052606081019190915260ca805461153590600190614a2c565b8154811061154557611545614a43565b600091825260209182902060408051608081018252600293909302909101805483526001015463ffffffff80821694840194909452600160201b810490931690820152600160401b90910460ff1615156060820152919050565b606654600590602090811614156115c85760405162461bcd60e51b8152600401610baa90614b3c565b600260975414156115eb5760405162461bcd60e51b8152600401610baa90614bea565b6002609755336001600160a01b0385161461168b5760405162461bcd60e51b815260206004820152605460248201527f52657761726473436f6f7264696e61746f722e6372656174654f70657261746f60448201527f724469726563746564415653526577617264735375626d697373696f6e3a2063606482015273616c6c6572206973206e6f74207468652041565360601b608482015260a401610baa565b60005b8281101561130f57368484838181106116a9576116a9614a43565b90506020028101906116bb9190614e82565b6001600160a01b038716600090815260ce60209081526040808320549051939450926116ed918a918591879101614fff565b6040516020818303038152906040528051906020012090506000611710846132fb565b6001600160a01b038a16600090815260d3602090815260408083208684529091529020805460ff1916600190811790915590915061174f908490614daa565b6001600160a01b038a16600081815260ce60205260409081902092909255905183919033907ffc8888bffd711da60bc5092b33f677d81896fe80ecc677b84cfab8184462b6e0906117a39088908a90615026565b60405180910390a46117c1333083610f0c6040890160208a016145b1565b5050505080806117d090614dd5565b91505061168e565b33600081815260cc602052604080822080546001600160a01b031981166001600160a01b038781169182179093559251911692839185917fbab947934d42e0ad206f25c9cab18b5bb6ae144acfb00f40b4e3aa59590ca31291a4505050565b61183f612778565b610bbc816136cb565b606654600790608090811614156118715760405162461bcd60e51b8152600401610baa90614b3c565b336001600160a01b038416146118f95760405162461bcd60e51b815260206004820152604160248201527f52657761726473436f6f7264696e61746f722e7365744f70657261746f72504960448201527f53706c69743a2063616c6c6572206973206e6f7420746865206f70657261746f6064820152603960f91b608482015260a401610baa565b61271061ffff831611156119805760405162461bcd60e51b815260206004820152604260248201527f52657761726473436f6f7264696e61746f722e7365744f70657261746f72504960448201527f53706c69743a2073706c6974206d757374206265203c3d203130303030206269606482015261707360f01b608482015260a401610baa565b60cb5460009061199d90600160a01b900463ffffffff1642614e44565b6001600160a01b038516600090815260d5602090815260408083208151606081018352905461ffff80821683526201000082041693820193909352600160201b90920463ffffffff1690820152919250906119f790612ebd565b6001600160a01b038616600090815260d560205260409020909150611a1d908584613736565b6040805163ffffffff8416815261ffff838116602083015286168183015290516001600160a01b0387169133917fd1e028bd664486a46ad26040e999cd2d22e1e9a094ee6afe19fcf64678f16f749181900360600190a35050505050565b600054610100900460ff1615808015611a9b5750600054600160ff909116105b80611ab55750303b158015611ab5575060005460ff166001145b611b185760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610baa565b6000805460ff191660011790558015611b3b576000805461ff0019166101001790555b611b436137d1565b60c955611b508686613868565b611b598761324d565b611b628461329f565b611b6b83612f0b565b611b74826136cb565b8015611bba576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b50505050505050565b60665460069060409081161415611bec5760405162461bcd60e51b8152600401610baa90614b3c565b336001600160a01b03851614611c755760405162461bcd60e51b815260206004820152604260248201527f52657761726473436f6f7264696e61746f722e7365744f70657261746f72415660448201527f5353706c69743a2063616c6c6572206973206e6f7420746865206f706572617460648201526137b960f11b608482015260a401610baa565b61271061ffff83161115611cfd5760405162461bcd60e51b815260206004820152604360248201527f52657761726473436f6f7264696e61746f722e7365744f70657261746f72415660448201527f5353706c69743a2073706c6974206d757374206265203c3d203130303030206260648201526269707360e81b608482015260a401610baa565b60cb54600090611d1a90600160a01b900463ffffffff1642614e44565b6001600160a01b03868116600090815260d46020908152604080832093891683529281528282208351606081018552905461ffff80821683526201000082041692820192909252600160201b90910463ffffffff1692810192909252919250611d8290612ebd565b6001600160a01b03808816600090815260d460209081526040808320938a16835292905220909150611db5908584613736565b6040805163ffffffff8416815261ffff838116602083015286168183015290516001600160a01b03878116929089169133917f48e198b6ae357e529204ee53a8e514c470ff77d9cc8e4f7207f8b5d490ae6934919081900360600190a4505050505050565b60408051608081018252600080825260208201819052918101829052606081019190915260ca8281548110611e5157611e51614a43565b600091825260209182902060408051608081018252600293909302909101805483526001015463ffffffff80821694840194909452600160201b810490931690820152600160401b90910460ff161515606082015292915050565b6001600160a01b03828116600090815260d46020908152604080832093851683529281528282208351606081018552905461ffff80821683526201000082041692820192909252600160201b90910463ffffffff169281019290925290611f1290612ebd565b9392505050565b60ca546000905b63ffffffff811615611f85578260ca611f3a60018461503f565b63ffffffff1681548110611f5057611f50614a43565b9060005260206000209060020201600001541415611f7357611f1260018261503f565b80611f7d81615064565b915050611f20565b5060405162461bcd60e51b815260206004820152603760248201527f52657761726473436f6f7264696e61746f722e676574526f6f74496e6465784660448201527f726f6d486173683a20726f6f74206e6f7420666f756e640000000000000000006064820152608401610baa565b611ffc612778565b6001600160a01b0381166120615760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610baa565b610bbc8161324d565b60007f000000000000000000000000000000000000000000000000000000000000000046141561209b575060c95490565b6120a36137d1565b905090565b60006001610d0e60208401846145b1565b606654600390600890811614156120e25760405162461bcd60e51b8152600401610baa90614b3c565b60cb546001600160a01b0316331461210c5760405162461bcd60e51b8152600401610baa90614df0565b60ca5463ffffffff83161061217d5760405162461bcd60e51b815260206004820152603160248201527f52657761726473436f6f7264696e61746f722e64697361626c65526f6f743a206044820152700d2dcecc2d8d2c840e4dedee892dcc8caf607b1b6064820152608401610baa565b600060ca8363ffffffff168154811061219857612198614a43565b906000526020600020906002020190508060010160089054906101000a900460ff16156122255760405162461bcd60e51b815260206004820152603560248201527f52657761726473436f6f7264696e61746f722e64697361626c65526f6f743a206044820152741c9bdbdd08185b1c9958591e48191a5cd8589b1959605a1b6064820152608401610baa565b6001810154600160201b900463ffffffff1642106122a45760405162461bcd60e51b815260206004820152603660248201527f52657761726473436f6f7264696e61746f722e64697361626c65526f6f743a206044820152751c9bdbdd08185b1c9958591e481858dd1a5d985d195960521b6064820152608401610baa565b60018101805460ff60401b1916600160401b17905560405163ffffffff8416907fd850e6e5dfa497b72661fa73df2923464eaed9dc2ff1d3cb82bccbfeabe5c41e90600090a2505050565b606560009054906101000a90046001600160a01b03166001600160a01b031663eab66d7a6040518163ffffffff1660e01b8152600401602060405180830381865afa158015612342573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906123669190614a70565b6001600160a01b0316336001600160a01b0316146123965760405162461bcd60e51b8152600401610baa90614a8d565b6066541981196066541916146124145760405162461bcd60e51b815260206004820152603860248201527f5061757361626c652e756e70617573653a20696e76616c696420617474656d7060448201527f7420746f2070617573652066756e6374696f6e616c69747900000000000000006064820152608401610baa565b606681905560405181815233907f3582d1828e26bf56bd801502bc021ac0bc8afb57c826e4986b45593c8fad389c90602001610cf3565b606654600090600190811614156124745760405162461bcd60e51b8152600401610baa90614b3c565b600260975414156124975760405162461bcd60e51b8152600401610baa90614bea565b600260975560005b82811015610f3357368484838181106124ba576124ba614a43565b90506020028101906124cc9190614c21565b33600081815260ce602090815260408083205490519495509391926124f79290918591879101614d7a565b604051602081830303815290604052805190602001209050612518836128c9565b33600090815260cf602090815260408083208484529091529020805460ff1916600190811790915561254b908390614daa565b33600081815260ce602052604090819020929092559051829184917f450a367a380c4e339e5ae7340c8464ef27af7781ad9945cfe8abd828f89e628190612593908890614dc2565b60405180910390a46125b4333060408601803590610f0c90602089016145b1565b50505080806125c290614dd5565b91505061249f565b606654600490601090811614156125f35760405162461bcd60e51b8152600401610baa90614b3c565b33600090815260d1602052604090205460ff166126225760405162461bcd60e51b8152600401610baa90614b73565b600260975414156126455760405162461bcd60e51b8152600401610baa90614bea565b600260975560005b82811015610f33573684848381811061266857612668614a43565b905060200281019061267a9190614c21565b33600081815260ce602090815260408083205490519495509391926126a59290918591879101614d7a565b6040516020818303038152906040528051906020012090506126c6836128c9565b33600090815260d2602090815260408083208484529091529020805460ff191660019081179091556126f9908390614daa565b33600081815260ce602052604090819020929092559051829184917f5251b6fdefcb5d81144e735f69ea4c695fd43b0289ca53dc075033f5fc80068b90612741908890614dc2565b60405180910390a4612762333060408601803590610f0c90602089016145b1565b505050808061277090614dd5565b91505061264d565b6033546001600160a01b031633146114ee5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610baa565b6001600160a01b0381166128605760405162461bcd60e51b815260206004820152604960248201527f5061757361626c652e5f73657450617573657252656769737472793a206e657760448201527f50617573657252656769737472792063616e6e6f7420626520746865207a65726064820152686f206164647265737360b81b608482015260a401610baa565b606554604080516001600160a01b03928316815291831660208301527f6e9fcd539896fca60e8b0f01dd580233e48a6b0f7df013b89ba7f565869acdb6910160405180910390a1606580546001600160a01b0319166001600160a01b0392909216919091179055565b6128fb6128d68280615084565b6128e660808501606086016147e1565b6128f660a08601608087016147e1565b613952565b600081604001351161297f5760405162461bcd60e51b815260206004820152604160248201527f52657761726473436f6f7264696e61746f722e5f76616c69646174655265776160448201527f7264735375626d697373696f6e3a20616d6f756e742063616e6e6f74206265206064820152600360fc1b608482015260a401610baa565b6f4b3b4ca85a86c47a098a223fffffffff81604001351115612a095760405162461bcd60e51b815260206004820152603f60248201527f52657761726473436f6f7264696e61746f722e5f76616c69646174655265776160448201527f7264735375626d697373696f6e3a20616d6f756e7420746f6f206c61726765006064820152608401610baa565b612a3963ffffffff7f00000000000000000000000000000000000000000000000000000000000000001642614daa565b612a4960808301606084016147e1565b63ffffffff161115610bbc5760405162461bcd60e51b815260206004820152605360248201527f52657761726473436f6f7264696e61746f722e5f76616c69646174655265776160448201527f7264735375626d697373696f6e3a20737461727454696d657374616d7020746f6064820152726f2066617220696e207468652066757475726560681b608482015260a401610baa565b6040516001600160a01b0380851660248301528316604482015260648101829052612b4a9085906323b872dd60e01b906084015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b031990931692909217909152613f41565b50505050565b600060ca612b6160208501856147e1565b63ffffffff1681548110612b7757612b77614a43565b600091825260209182902060408051608081018252600293909302909101805483526001015463ffffffff80821694840194909452600160201b810490931690820152600160401b90910460ff16151560608201529050612bd88382612f7c565b6000612bea60808501606086016145b1565b6001600160a01b03808216600090815260cc60205260409020549192501680612c105750805b336001600160a01b03821614612c8e5760405162461bcd60e51b815260206004820152603c60248201527f52657761726473436f6f7264696e61746f722e70726f63657373436c61696d3a60448201527f2063616c6c6572206973206e6f742076616c696420636c61696d6572000000006064820152608401610baa565b60005b612c9e60a08701876150ce565b9050811015612eb55736612cb560e0880188615084565b83818110612cc557612cc5614a43565b6001600160a01b038716600090815260cd602090815260408083209302949094019450929091508290612cfa908501856145b1565b6001600160a01b03166001600160a01b0316815260200190815260200160002054905080826020013511612db45760405162461bcd60e51b815260206004820152605560248201527f52657761726473436f6f7264696e61746f722e70726f63657373436c61696d3a60448201527f2063756d756c61746976654561726e696e6773206d75737420626520677420746064820152741a185b8818dd5b5d5b185d1a5d9950db185a5b5959605a1b608482015260a401610baa565b6000612dc4826020850135614a2c565b6001600160a01b038716600090815260cd60209081526040822092935085018035929190612df290876145b1565b6001600160a01b0316815260208082019290925260400160002091909155612e349089908390612e24908701876145b1565b6001600160a01b03169190614013565b86516001600160a01b03808a1691878216918916907f9543dbd55580842586a951f0386e24d68a5df99ae29e3b216588b45fd684ce3190612e7860208901896145b1565b604080519283526001600160a01b039091166020830152810186905260600160405180910390a45050508080612ead90614dd5565b915050612c91565b505050505050565b6000816040015163ffffffff1660001415612ee557505060cb54600160e01b900461ffff1690565b816040015163ffffffff16421015612efe578151611371565b506020015190565b919050565b60cb546040805163ffffffff600160a01b9093048316815291831660208301527faf557c6c02c208794817a705609cfa935f827312a1adfdd26494b6b95dd2b4b3910160405180910390a160cb805463ffffffff909216600160a01b0263ffffffff60a01b19909216919091179055565b806060015115612fd55760405162461bcd60e51b8152602060048201526030602482015260008051602061523283398151915260448201526f1c9bdbdd081a5cc8191a5cd8589b195960821b6064820152608401610baa565b806040015163ffffffff1642101561303c5760405162461bcd60e51b815260206004820152603660248201526000805160206152328339815191526044820152751c9bdbdd081b9bdd081858dd1a5d985d1959081e595d60521b6064820152608401610baa565b61304960c08301836150ce565b905061305860a08401846150ce565b9050146130d05760405162461bcd60e51b815260206004820152604c602482015260008051602061523283398151915260448201527f746f6b656e496e646963657320616e6420746f6b656e50726f6f6673206c656e60648201526b0cee8d040dad2e6dac2e8c6d60a31b608482015260a401610baa565b6130dd60e0830183615084565b90506130ec60c08401846150ce565b9050146131625760405162461bcd60e51b815260206004820152604a602482015260008051602061523283398151915260448201527f746f6b656e5472656550726f6f667320616e64206c6561766573206c656e67746064820152690d040dad2e6dac2e8c6d60b31b608482015260a401610baa565b805161318e9061317860408501602086016147e1565b6131856040860186615118565b86606001614043565b60005b61319e60a08401846150ce565b90508110156132485761323860808401356131bc60a08601866150ce565b848181106131cc576131cc614a43565b90506020020160208101906131e191906147e1565b6131ee60c08701876150ce565b858181106131fe576131fe614a43565b90506020028101906132109190615118565b61321d60e0890189615084565b8781811061322d5761322d614a43565b9050604002016141af565b61324181614dd5565b9050613191565b505050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60cb546040516001600160a01b038084169216907f237b82f438d75fc568ebab484b75b01d9287b9e98b490b7c23221623b6705dbb90600090a360cb80546001600160a01b0319166001600160a01b0392909216919091179055565b600061332a61330a8380615084565b61331a60808601606087016147e1565b6128f660a08701608088016147e1565b60006133396040840184615084565b9050116133b95760405162461bcd60e51b8152602060048201526054602482015260008051602061527283398151915260448201527f61746f724469726563746564526577617264735375626d697373696f6e3a206e6064820152731bc81bdc195c985d1bdc9cc81c995dd85c99195960621b608482015260a401610baa565b60008060005b6133cc6040860186615084565b90508110156135fe57366133e36040870187615084565b838181106133f3576133f3614a43565b6040029190910191506000905061340d60208301836145b1565b6001600160a01b0316141561348c5760405162461bcd60e51b815260206004820152605b6024820152600080516020615272833981519152604482015260008051602061525283398151915260648201527f70657261746f722063616e6e6f74206265203020616464726573730000000000608482015260a401610baa565b61349960208201826145b1565b6001600160a01b0316836001600160a01b0316106135475760405162461bcd60e51b81526020600482015260786024820152600080516020615272833981519152604482015260008051602061525283398151915260648201527f70657261746f7273206d75737420626520696e20617363656e64696e67206f7260848201527f64657220746f2068616e646c65206475706c696361746573000000000000000060a482015260c401610baa565b61355460208201826145b1565b925060008160200135116135dc5760405162461bcd60e51b81526020600482015260616024820152600080516020615272833981519152604482015260008051602061525283398151915260648201527f70657261746f722072657761726420616d6f756e742063616e6e6f74206265206084820152600360fc1b60a482015260c401610baa565b6135ea602082013585614daa565b935050806135f790614dd5565b90506133bf565b504261361060a08601608087016147e1565b61362060808701606088016147e1565b61362a9190614e44565b63ffffffff16106136c45760405162461bcd60e51b81526020600482015260766024820152600080516020615272833981519152604482015260008051602061525283398151915260648201527f70657261746f722d64697265637465642072657761726473207375626d697373608482015275696f6e206973206e6f7420726574726f61637469766560501b60a482015260c401610baa565b5092915050565b60cb546040805161ffff600160e01b9093048316815291831660208301527fe6cd4edfdcc1f6d130ab35f73d72378f3a642944fb4ee5bd84b7807a81ea1c4e910160405180910390a160cb805461ffff909216600160e01b0261ffff60e01b19909216919091179055565b8254600160201b900463ffffffff164210613795578254600160201b900463ffffffff1661377e5760cb548354600160e01b90910461ffff1661ffff19909116178355613795565b825462010000810461ffff1661ffff199091161783555b825463ffffffff909116600160201b0267ffffffff000000001961ffff90931662010000029290921667ffffffffffff00001990911617179055565b604080518082018252600a81526922b4b3b2b72630bcb2b960b11b60209182015281517f8cad95687ba82c2ce50e74f7b754645e5117c3a5bec8151c0726d5857980a866818301527f71b625cfad44bac63b13dba07f2e1d6084ee04b6f8752101ece6126d584ee6ea81840152466060820152306080808301919091528351808303909101815260a0909101909252815191012090565b6065546001600160a01b031615801561388957506001600160a01b03821615155b61390b5760405162461bcd60e51b815260206004820152604760248201527f5061757361626c652e5f696e697469616c697a655061757365723a205f696e6960448201527f7469616c697a6550617573657228292063616e206f6e6c792062652063616c6c6064820152666564206f6e636560c81b608482015260a401610baa565b606681905560405181815233907fab40a374bc51de372200a8bc981af8c9ecdc08dfdaef0bb6e09f88f3c616ef3d9060200160405180910390a261394e826127d2565b5050565b826139c25760405162461bcd60e51b8152602060048201526046602482015260008051602061529283398151915260448201527f6f6e526577617264735375626d697373696f6e3a206e6f207374726174656769606482015265195cc81cd95d60d21b608482015260a401610baa565b7f000000000000000000000000000000000000000000000000000000000000000063ffffffff168163ffffffff161115613a785760405162461bcd60e51b815260206004820152605a602482015260008051602061529283398151915260448201527f6f6e526577617264735375626d697373696f6e3a206475726174696f6e20657860648201527f6365656473204d41585f524557415244535f4455524154494f4e000000000000608482015260a401610baa565b613aa27f000000000000000000000000000000000000000000000000000000000000000082615175565b63ffffffff1615613b485760405162461bcd60e51b8152602060048201526070602482015260008051602061529283398151915260448201527f6f6e526577617264735375626d697373696f6e3a206475726174696f6e206d7560648201527f73742062652061206d756c7469706c65206f662043414c43554c4154494f4e5f60848201526f494e54455256414c5f5345434f4e445360801b60a482015260c401610baa565b613b727f000000000000000000000000000000000000000000000000000000000000000083615175565b63ffffffff1615613c1e5760405162461bcd60e51b8152602060048201526076602482015260008051602061529283398151915260448201527f6f6e526577617264735375626d697373696f6e3a20737461727454696d65737460648201527f616d70206d7573742062652061206d756c7469706c65206f662043414c43554c6084820152754154494f4e5f494e54455256414c5f5345434f4e445360501b60a482015260c401610baa565b8163ffffffff167f000000000000000000000000000000000000000000000000000000000000000063ffffffff1642613c579190614a2c565b11158015613c9157508163ffffffff167f000000000000000000000000000000000000000000000000000000000000000063ffffffff1611155b613d175760405162461bcd60e51b8152602060048201526057602482015260008051602061529283398151915260448201527f6f6e526577617264735375626d697373696f6e3a20737461727454696d65737460648201527f616d7020746f6f2066617220696e207468652070617374000000000000000000608482015260a401610baa565b6000805b84811015612eb5576000868683818110613d3757613d37614a43565b613d4d92602060409092020190810191506145b1565b60405163198f077960e21b81526001600160a01b0380831660048301529192507f00000000000000000000000000000000000000000000000000000000000000009091169063663c1de490602401602060405180830381865afa158015613db8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613ddc9190614ad7565b80613e0357506001600160a01b03811673beac0eeeeeeeeeeeeeeeeeeeeeeeeeeeeeebeac0145b613e7c5760405162461bcd60e51b8152602060048201526050602482015260008051602061529283398151915260448201527f6f6e526577617264735375626d697373696f6e3a20696e76616c69642073747260648201526f185d1959de4818dbdb9cda59195c995960821b608482015260a401610baa565b806001600160a01b0316836001600160a01b031610613f2f5760405162461bcd60e51b815260206004820152606f602482015260008051602061529283398151915260448201527f6f6e526577617264735375626d697373696f6e3a20737472617465676965732060648201527f6d75737420626520696e20617363656e64696e67206f7264657220746f20686160848201526e6e646c65206475706c69636174657360881b60a482015260c401610baa565b9150613f3a81614dd5565b9050613d1b565b6000613f96826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166143009092919063ffffffff16565b8051909150156132485780806020019051810190613fb49190614ad7565b6132485760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b6064820152608401610baa565b6040516001600160a01b03831660248201526044810182905261324890849063a9059cbb60e01b90606401612b13565b61404e602083615198565b6001901b8463ffffffff16106140d85760405162461bcd60e51b815260206004820152604360248201527f52657761726473436f6f7264696e61746f722e5f7665726966794561726e657260448201527f436c61696d50726f6f663a20696e76616c6964206561726e65724c656166496e6064820152620c8caf60eb1b608482015260a401610baa565b60006140e382610cfe565b905061412e84848080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508a92508591505063ffffffff8916614317565b612eb55760405162461bcd60e51b815260206004820152604660248201527f52657761726473436f6f7264696e61746f722e5f7665726966794561726e657260448201527f436c61696d50726f6f663a20696e76616c6964206561726e657220636c61696d60648201526510383937b7b360d11b608482015260a401610baa565b6141ba602083615198565b6001901b8463ffffffff16106142385760405162461bcd60e51b815260206004820152603c60248201527f52657761726473436f6f7264696e61746f722e5f766572696679546f6b656e4360448201527f6c61696d3a20696e76616c696420746f6b656e4c656166496e646578000000006064820152608401610baa565b6000614243826120a8565b905061428e84848080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508a92508591505063ffffffff8916614317565b612eb55760405162461bcd60e51b815260206004820152603f60248201527f52657761726473436f6f7264696e61746f722e5f766572696679546f6b656e4360448201527f6c61696d3a20696e76616c696420746f6b656e20636c61696d2070726f6f66006064820152608401610baa565b606061430f848460008561432f565b949350505050565b600083614325868585614460565b1495945050505050565b6060824710156143905760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b6064820152608401610baa565b6001600160a01b0385163b6143e75760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610baa565b600080866001600160a01b0316858760405161440391906151d8565b60006040518083038185875af1925050503d8060008114614440576040519150601f19603f3d011682016040523d82523d6000602084013e614445565b606091505b5091509150614455828286614563565b979650505050505050565b60006020845161447091906151ea565b156144f75760405162461bcd60e51b815260206004820152604b60248201527f4d65726b6c652e70726f63657373496e636c7573696f6e50726f6f664b65636360448201527f616b3a2070726f6f66206c656e6774682073686f756c642062652061206d756c60648201526a3a34b836329037b310199960a91b608482015260a401610baa565b8260205b8551811161455a5761450e6002856151ea565b61452f57816000528086015160205260406000209150600284049350614548565b8086015160005281602052604060002091506002840493505b614553602082614daa565b90506144fb565b50949350505050565b60608315614572575081611f12565b8251156145825782518084602001fd5b8160405162461bcd60e51b8152600401610baa91906151fe565b6001600160a01b0381168114610bbc57600080fd5b6000602082840312156145c357600080fd5b8135611f128161459c565b8015158114610bbc57600080fd5b600080604083850312156145ef57600080fd5b82356145fa8161459c565b9150602083013561460a816145ce565b809150509250929050565b60006020828403121561462757600080fd5b5035919050565b60006040828403121561464057600080fd5b50919050565b60006040828403121561465857600080fd5b611f12838361462e565b60008083601f84011261467457600080fd5b50813567ffffffffffffffff81111561468c57600080fd5b6020830191508360208260051b85010111156146a757600080fd5b9250929050565b600080602083850312156146c157600080fd5b823567ffffffffffffffff8111156146d857600080fd5b6146e485828601614662565b90969095509350505050565b6000610100828403121561464057600080fd5b6000806040838503121561471657600080fd5b823567ffffffffffffffff81111561472d57600080fd5b614739858286016146f0565b925050602083013561460a8161459c565b803563ffffffff81168114612f0657600080fd5b6000806040838503121561477157600080fd5b823591506147816020840161474a565b90509250929050565b60008060006040848603121561479f57600080fd5b833567ffffffffffffffff8111156147b657600080fd5b6147c286828701614662565b90945092505060208401356147d68161459c565b809150509250925092565b6000602082840312156147f357600080fd5b611f128261474a565b60006020828403121561480e57600080fd5b813560ff81168114611f1257600080fd5b60006020828403121561483157600080fd5b813567ffffffffffffffff81111561484857600080fd5b61430f848285016146f0565b6000806040838503121561486757600080fd5b82356148728161459c565b946020939093013593505050565b6000806040838503121561489357600080fd5b823561489e8161459c565b9150602083013561460a8161459c565b6000806000604084860312156148c357600080fd5b83356148ce8161459c565b9250602084013567ffffffffffffffff8111156148ea57600080fd5b6148f686828701614662565b9497909650939450505050565b803561ffff81168114612f0657600080fd5b60006020828403121561492757600080fd5b611f1282614903565b6000806040838503121561494357600080fd5b823561494e8161459c565b915061478160208401614903565b60008060008060008060c0878903121561497557600080fd5b86356149808161459c565b955060208701356149908161459c565b94506040870135935060608701356149a78161459c565b92506149b56080880161474a565b91506149c360a08801614903565b90509295509295509295565b6000806000606084860312156149e457600080fd5b83356149ef8161459c565b925060208401356149ff8161459c565b9150614a0d60408501614903565b90509250925092565b634e487b7160e01b600052601160045260246000fd5b600082821015614a3e57614a3e614a16565b500390565b634e487b7160e01b600052603260045260246000fd5b600081614a6857614a68614a16565b506000190190565b600060208284031215614a8257600080fd5b8151611f128161459c565b6020808252602a908201527f6d73672e73656e646572206973206e6f74207065726d697373696f6e6564206160408201526939903ab73830bab9b2b960b11b606082015260800190565b600060208284031215614ae957600080fd5b8151611f12816145ce565b60208082526028908201527f6d73672e73656e646572206973206e6f74207065726d697373696f6e6564206160408201526739903830bab9b2b960c11b606082015260800190565b60208082526019908201527f5061757361626c653a20696e6465782069732070617573656400000000000000604082015260600190565b60208082526051908201527f52657761726473436f6f7264696e61746f723a2063616c6c6572206973206e6f60408201527f7420612076616c69642063726561746552657761726473466f72416c6c53756260608201527036b4b9b9b4b7b71039bab136b4ba3a32b960791b608082015260a00190565b6020808252601f908201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604082015260600190565b60008235609e19833603018112614c3757600080fd5b9190910192915050565b6000808335601e19843603018112614c5857600080fd5b830160208101925035905067ffffffffffffffff811115614c7857600080fd5b8060061b36038313156146a757600080fd5b818352600060208085019450826000805b86811015614cef578235614cae8161459c565b6001600160a01b03168852828401356bffffffffffffffffffffffff8116808214614cd7578384fd5b89860152506040978801979290920191600101614c9b565b50959695505050505050565b6000614d078283614c41565b60a08552614d1960a086018284614c8a565b9150506020830135614d2a8161459c565b6001600160a01b0316602085015260408381013590850152614d4e6060840161474a565b63ffffffff808216606087015280614d686080870161474a565b16608087015250508091505092915050565b60018060a01b0384168152826020820152606060408201526000614da16060830184614cfb565b95945050505050565b60008219821115614dbd57614dbd614a16565b500190565b602081526000611f126020830184614cfb565b6000600019821415614de957614de9614a16565b5060010190565b60208082526034908201527f52657761726473436f6f7264696e61746f723a2063616c6c6572206973206e6f6040820152733a103a3432903932bbb0b93239aab83230ba32b960611b606082015260800190565b600063ffffffff808316818516808303821115614e6357614e63614a16565b01949350505050565b6000823560fe19833603018112614c3757600080fd5b6000823560be19833603018112614c3757600080fd5b6000808335601e19843603018112614eaf57600080fd5b830160208101925035905067ffffffffffffffff811115614ecf57600080fd5b8036038313156146a757600080fd5b81835281816020850137506000828201602090810191909152601f909101601f19169091010190565b6000614f138283614c41565b60c08552614f2560c086018284614c8a565b915050602080840135614f378161459c565b6001600160a01b0390811686830152604090614f5586830187614c41565b888603848a015280865290946000919085015b81831015614f99578635614f7b8161459c565b84168152868601358682015295840195600192909201918401614f68565b614fa560608a0161474a565b63ffffffff811660608c01529650614fbf60808a0161474a565b63ffffffff811660808c01529650614fda60a08a018a614e98565b9750955089810360a08b0152614ff1818888614ede565b9a9950505050505050505050565b60018060a01b0384168152826020820152606060408201526000614da16060830184614f07565b82815260406020820152600061430f6040830184614f07565b600063ffffffff8381169083168181101561505c5761505c614a16565b039392505050565b600063ffffffff82168061507a5761507a614a16565b6000190192915050565b6000808335601e1984360301811261509b57600080fd5b83018035915067ffffffffffffffff8211156150b657600080fd5b6020019150600681901b36038213156146a757600080fd5b6000808335601e198436030181126150e557600080fd5b83018035915067ffffffffffffffff82111561510057600080fd5b6020019150600581901b36038213156146a757600080fd5b6000808335601e1984360301811261512f57600080fd5b83018035915067ffffffffffffffff82111561514a57600080fd5b6020019150368190038213156146a757600080fd5b634e487b7160e01b600052601260045260246000fd5b600063ffffffff8084168061518c5761518c61515f565b92169190910692915050565b6000826151a7576151a761515f565b500490565b60005b838110156151c75781810151838201526020016151af565b83811115612b4a5750506000910152565b60008251614c378184602087016151ac565b6000826151f9576151f961515f565b500690565b602081526000825180602084015261521d8160408501602087016151ac565b601f01601f1916919091016040019291505056fe52657761726473436f6f7264696e61746f722e5f636865636b436c61696d3a2061746f724469726563746564526577617264735375626d697373696f6e3a206f52657761726473436f6f7264696e61746f722e5f76616c69646174654f70657252657761726473436f6f7264696e61746f722e5f76616c6964617465436f6d6da2646970667358221220081e7033322140012f1d9ef09b55b455e888c99c5a08a478635131f15ff9795b64736f6c634300080c0033", } // RewardsCoordinatorABI is the input ABI used to generate the binding from. @@ -651,6 +667,37 @@ func (_RewardsCoordinator *RewardsCoordinatorCallerSession) CurrRewardsCalculati return _RewardsCoordinator.Contract.CurrRewardsCalculationEndTimestamp(&_RewardsCoordinator.CallOpts) } +// DefaultOperatorSplitBips is a free data retrieval call binding the contract method 0x63f6a798. +// +// Solidity: function defaultOperatorSplitBips() view returns(uint16) +func (_RewardsCoordinator *RewardsCoordinatorCaller) DefaultOperatorSplitBips(opts *bind.CallOpts) (uint16, error) { + var out []interface{} + err := _RewardsCoordinator.contract.Call(opts, &out, "defaultOperatorSplitBips") + + if err != nil { + return *new(uint16), err + } + + out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) + + return out0, err + +} + +// DefaultOperatorSplitBips is a free data retrieval call binding the contract method 0x63f6a798. +// +// Solidity: function defaultOperatorSplitBips() view returns(uint16) +func (_RewardsCoordinator *RewardsCoordinatorSession) DefaultOperatorSplitBips() (uint16, error) { + return _RewardsCoordinator.Contract.DefaultOperatorSplitBips(&_RewardsCoordinator.CallOpts) +} + +// DefaultOperatorSplitBips is a free data retrieval call binding the contract method 0x63f6a798. +// +// Solidity: function defaultOperatorSplitBips() view returns(uint16) +func (_RewardsCoordinator *RewardsCoordinatorCallerSession) DefaultOperatorSplitBips() (uint16, error) { + return _RewardsCoordinator.Contract.DefaultOperatorSplitBips(&_RewardsCoordinator.CallOpts) +} + // DelegationManager is a free data retrieval call binding the contract method 0xea4d3c9b. // // Solidity: function delegationManager() view returns(address) @@ -837,43 +884,43 @@ func (_RewardsCoordinator *RewardsCoordinatorCallerSession) GetDistributionRoots return _RewardsCoordinator.Contract.GetDistributionRootsLength(&_RewardsCoordinator.CallOpts) } -// GetRootIndexFromHash is a free data retrieval call binding the contract method 0xe810ce21. +// GetOperatorAVSSplit is a free data retrieval call binding the contract method 0xe063f81f. // -// Solidity: function getRootIndexFromHash(bytes32 rootHash) view returns(uint32) -func (_RewardsCoordinator *RewardsCoordinatorCaller) GetRootIndexFromHash(opts *bind.CallOpts, rootHash [32]byte) (uint32, error) { +// Solidity: function getOperatorAVSSplit(address operator, address avs) view returns(uint16) +func (_RewardsCoordinator *RewardsCoordinatorCaller) GetOperatorAVSSplit(opts *bind.CallOpts, operator common.Address, avs common.Address) (uint16, error) { var out []interface{} - err := _RewardsCoordinator.contract.Call(opts, &out, "getRootIndexFromHash", rootHash) + err := _RewardsCoordinator.contract.Call(opts, &out, "getOperatorAVSSplit", operator, avs) if err != nil { - return *new(uint32), err + return *new(uint16), err } - out0 := *abi.ConvertType(out[0], new(uint32)).(*uint32) + out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) return out0, err } -// GetRootIndexFromHash is a free data retrieval call binding the contract method 0xe810ce21. +// GetOperatorAVSSplit is a free data retrieval call binding the contract method 0xe063f81f. // -// Solidity: function getRootIndexFromHash(bytes32 rootHash) view returns(uint32) -func (_RewardsCoordinator *RewardsCoordinatorSession) GetRootIndexFromHash(rootHash [32]byte) (uint32, error) { - return _RewardsCoordinator.Contract.GetRootIndexFromHash(&_RewardsCoordinator.CallOpts, rootHash) +// Solidity: function getOperatorAVSSplit(address operator, address avs) view returns(uint16) +func (_RewardsCoordinator *RewardsCoordinatorSession) GetOperatorAVSSplit(operator common.Address, avs common.Address) (uint16, error) { + return _RewardsCoordinator.Contract.GetOperatorAVSSplit(&_RewardsCoordinator.CallOpts, operator, avs) } -// GetRootIndexFromHash is a free data retrieval call binding the contract method 0xe810ce21. +// GetOperatorAVSSplit is a free data retrieval call binding the contract method 0xe063f81f. // -// Solidity: function getRootIndexFromHash(bytes32 rootHash) view returns(uint32) -func (_RewardsCoordinator *RewardsCoordinatorCallerSession) GetRootIndexFromHash(rootHash [32]byte) (uint32, error) { - return _RewardsCoordinator.Contract.GetRootIndexFromHash(&_RewardsCoordinator.CallOpts, rootHash) +// Solidity: function getOperatorAVSSplit(address operator, address avs) view returns(uint16) +func (_RewardsCoordinator *RewardsCoordinatorCallerSession) GetOperatorAVSSplit(operator common.Address, avs common.Address) (uint16, error) { + return _RewardsCoordinator.Contract.GetOperatorAVSSplit(&_RewardsCoordinator.CallOpts, operator, avs) } -// GlobalOperatorCommissionBips is a free data retrieval call binding the contract method 0x092db007. +// GetOperatorPISplit is a free data retrieval call binding the contract method 0x4b943960. // -// Solidity: function globalOperatorCommissionBips() view returns(uint16) -func (_RewardsCoordinator *RewardsCoordinatorCaller) GlobalOperatorCommissionBips(opts *bind.CallOpts) (uint16, error) { +// Solidity: function getOperatorPISplit(address operator) view returns(uint16) +func (_RewardsCoordinator *RewardsCoordinatorCaller) GetOperatorPISplit(opts *bind.CallOpts, operator common.Address) (uint16, error) { var out []interface{} - err := _RewardsCoordinator.contract.Call(opts, &out, "globalOperatorCommissionBips") + err := _RewardsCoordinator.contract.Call(opts, &out, "getOperatorPISplit", operator) if err != nil { return *new(uint16), err @@ -885,18 +932,49 @@ func (_RewardsCoordinator *RewardsCoordinatorCaller) GlobalOperatorCommissionBip } -// GlobalOperatorCommissionBips is a free data retrieval call binding the contract method 0x092db007. +// GetOperatorPISplit is a free data retrieval call binding the contract method 0x4b943960. +// +// Solidity: function getOperatorPISplit(address operator) view returns(uint16) +func (_RewardsCoordinator *RewardsCoordinatorSession) GetOperatorPISplit(operator common.Address) (uint16, error) { + return _RewardsCoordinator.Contract.GetOperatorPISplit(&_RewardsCoordinator.CallOpts, operator) +} + +// GetOperatorPISplit is a free data retrieval call binding the contract method 0x4b943960. +// +// Solidity: function getOperatorPISplit(address operator) view returns(uint16) +func (_RewardsCoordinator *RewardsCoordinatorCallerSession) GetOperatorPISplit(operator common.Address) (uint16, error) { + return _RewardsCoordinator.Contract.GetOperatorPISplit(&_RewardsCoordinator.CallOpts, operator) +} + +// GetRootIndexFromHash is a free data retrieval call binding the contract method 0xe810ce21. +// +// Solidity: function getRootIndexFromHash(bytes32 rootHash) view returns(uint32) +func (_RewardsCoordinator *RewardsCoordinatorCaller) GetRootIndexFromHash(opts *bind.CallOpts, rootHash [32]byte) (uint32, error) { + var out []interface{} + err := _RewardsCoordinator.contract.Call(opts, &out, "getRootIndexFromHash", rootHash) + + if err != nil { + return *new(uint32), err + } + + out0 := *abi.ConvertType(out[0], new(uint32)).(*uint32) + + return out0, err + +} + +// GetRootIndexFromHash is a free data retrieval call binding the contract method 0xe810ce21. // -// Solidity: function globalOperatorCommissionBips() view returns(uint16) -func (_RewardsCoordinator *RewardsCoordinatorSession) GlobalOperatorCommissionBips() (uint16, error) { - return _RewardsCoordinator.Contract.GlobalOperatorCommissionBips(&_RewardsCoordinator.CallOpts) +// Solidity: function getRootIndexFromHash(bytes32 rootHash) view returns(uint32) +func (_RewardsCoordinator *RewardsCoordinatorSession) GetRootIndexFromHash(rootHash [32]byte) (uint32, error) { + return _RewardsCoordinator.Contract.GetRootIndexFromHash(&_RewardsCoordinator.CallOpts, rootHash) } -// GlobalOperatorCommissionBips is a free data retrieval call binding the contract method 0x092db007. +// GetRootIndexFromHash is a free data retrieval call binding the contract method 0xe810ce21. // -// Solidity: function globalOperatorCommissionBips() view returns(uint16) -func (_RewardsCoordinator *RewardsCoordinatorCallerSession) GlobalOperatorCommissionBips() (uint16, error) { - return _RewardsCoordinator.Contract.GlobalOperatorCommissionBips(&_RewardsCoordinator.CallOpts) +// Solidity: function getRootIndexFromHash(bytes32 rootHash) view returns(uint32) +func (_RewardsCoordinator *RewardsCoordinatorCallerSession) GetRootIndexFromHash(rootHash [32]byte) (uint32, error) { + return _RewardsCoordinator.Contract.GetRootIndexFromHash(&_RewardsCoordinator.CallOpts, rootHash) } // IsAVSRewardsSubmissionHash is a free data retrieval call binding the contract method 0x6d21117e. @@ -930,6 +1008,37 @@ func (_RewardsCoordinator *RewardsCoordinatorCallerSession) IsAVSRewardsSubmissi return _RewardsCoordinator.Contract.IsAVSRewardsSubmissionHash(&_RewardsCoordinator.CallOpts, arg0, arg1) } +// IsOperatorDirectedAVSRewardsSubmissionHash is a free data retrieval call binding the contract method 0xed71e6a2. +// +// Solidity: function isOperatorDirectedAVSRewardsSubmissionHash(address , bytes32 ) view returns(bool) +func (_RewardsCoordinator *RewardsCoordinatorCaller) IsOperatorDirectedAVSRewardsSubmissionHash(opts *bind.CallOpts, arg0 common.Address, arg1 [32]byte) (bool, error) { + var out []interface{} + err := _RewardsCoordinator.contract.Call(opts, &out, "isOperatorDirectedAVSRewardsSubmissionHash", arg0, arg1) + + if err != nil { + return *new(bool), err + } + + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) + + return out0, err + +} + +// IsOperatorDirectedAVSRewardsSubmissionHash is a free data retrieval call binding the contract method 0xed71e6a2. +// +// Solidity: function isOperatorDirectedAVSRewardsSubmissionHash(address , bytes32 ) view returns(bool) +func (_RewardsCoordinator *RewardsCoordinatorSession) IsOperatorDirectedAVSRewardsSubmissionHash(arg0 common.Address, arg1 [32]byte) (bool, error) { + return _RewardsCoordinator.Contract.IsOperatorDirectedAVSRewardsSubmissionHash(&_RewardsCoordinator.CallOpts, arg0, arg1) +} + +// IsOperatorDirectedAVSRewardsSubmissionHash is a free data retrieval call binding the contract method 0xed71e6a2. +// +// Solidity: function isOperatorDirectedAVSRewardsSubmissionHash(address , bytes32 ) view returns(bool) +func (_RewardsCoordinator *RewardsCoordinatorCallerSession) IsOperatorDirectedAVSRewardsSubmissionHash(arg0 common.Address, arg1 [32]byte) (bool, error) { + return _RewardsCoordinator.Contract.IsOperatorDirectedAVSRewardsSubmissionHash(&_RewardsCoordinator.CallOpts, arg0, arg1) +} + // IsRewardsForAllSubmitter is a free data retrieval call binding the contract method 0x0018572c. // // Solidity: function isRewardsForAllSubmitter(address ) view returns(bool) @@ -1023,37 +1132,6 @@ func (_RewardsCoordinator *RewardsCoordinatorCallerSession) IsRewardsSubmissionF return _RewardsCoordinator.Contract.IsRewardsSubmissionForAllHash(&_RewardsCoordinator.CallOpts, arg0, arg1) } -// OperatorCommissionBips is a free data retrieval call binding the contract method 0x22f19a64. -// -// Solidity: function operatorCommissionBips(address , address ) view returns(uint16) -func (_RewardsCoordinator *RewardsCoordinatorCaller) OperatorCommissionBips(opts *bind.CallOpts, arg0 common.Address, arg1 common.Address) (uint16, error) { - var out []interface{} - err := _RewardsCoordinator.contract.Call(opts, &out, "operatorCommissionBips", arg0, arg1) - - if err != nil { - return *new(uint16), err - } - - out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) - - return out0, err - -} - -// OperatorCommissionBips is a free data retrieval call binding the contract method 0x22f19a64. -// -// Solidity: function operatorCommissionBips(address , address ) view returns(uint16) -func (_RewardsCoordinator *RewardsCoordinatorSession) OperatorCommissionBips(arg0 common.Address, arg1 common.Address) (uint16, error) { - return _RewardsCoordinator.Contract.OperatorCommissionBips(&_RewardsCoordinator.CallOpts, arg0, arg1) -} - -// OperatorCommissionBips is a free data retrieval call binding the contract method 0x22f19a64. -// -// Solidity: function operatorCommissionBips(address , address ) view returns(uint16) -func (_RewardsCoordinator *RewardsCoordinatorCallerSession) OperatorCommissionBips(arg0 common.Address, arg1 common.Address) (uint16, error) { - return _RewardsCoordinator.Contract.OperatorCommissionBips(&_RewardsCoordinator.CallOpts, arg0, arg1) -} - // Owner is a free data retrieval call binding the contract method 0x8da5cb5b. // // Solidity: function owner() view returns(address) @@ -1292,6 +1370,27 @@ func (_RewardsCoordinator *RewardsCoordinatorTransactorSession) CreateAVSRewards return _RewardsCoordinator.Contract.CreateAVSRewardsSubmission(&_RewardsCoordinator.TransactOpts, rewardsSubmissions) } +// CreateOperatorDirectedAVSRewardsSubmission is a paid mutator transaction binding the contract method 0x9cb9a5fa. +// +// Solidity: function createOperatorDirectedAVSRewardsSubmission(address avs, ((address,uint96)[],address,(address,uint256)[],uint32,uint32,string)[] operatorDirectedRewardsSubmissions) returns() +func (_RewardsCoordinator *RewardsCoordinatorTransactor) CreateOperatorDirectedAVSRewardsSubmission(opts *bind.TransactOpts, avs common.Address, operatorDirectedRewardsSubmissions []IRewardsCoordinatorOperatorDirectedRewardsSubmission) (*types.Transaction, error) { + return _RewardsCoordinator.contract.Transact(opts, "createOperatorDirectedAVSRewardsSubmission", avs, operatorDirectedRewardsSubmissions) +} + +// CreateOperatorDirectedAVSRewardsSubmission is a paid mutator transaction binding the contract method 0x9cb9a5fa. +// +// Solidity: function createOperatorDirectedAVSRewardsSubmission(address avs, ((address,uint96)[],address,(address,uint256)[],uint32,uint32,string)[] operatorDirectedRewardsSubmissions) returns() +func (_RewardsCoordinator *RewardsCoordinatorSession) CreateOperatorDirectedAVSRewardsSubmission(avs common.Address, operatorDirectedRewardsSubmissions []IRewardsCoordinatorOperatorDirectedRewardsSubmission) (*types.Transaction, error) { + return _RewardsCoordinator.Contract.CreateOperatorDirectedAVSRewardsSubmission(&_RewardsCoordinator.TransactOpts, avs, operatorDirectedRewardsSubmissions) +} + +// CreateOperatorDirectedAVSRewardsSubmission is a paid mutator transaction binding the contract method 0x9cb9a5fa. +// +// Solidity: function createOperatorDirectedAVSRewardsSubmission(address avs, ((address,uint96)[],address,(address,uint256)[],uint32,uint32,string)[] operatorDirectedRewardsSubmissions) returns() +func (_RewardsCoordinator *RewardsCoordinatorTransactorSession) CreateOperatorDirectedAVSRewardsSubmission(avs common.Address, operatorDirectedRewardsSubmissions []IRewardsCoordinatorOperatorDirectedRewardsSubmission) (*types.Transaction, error) { + return _RewardsCoordinator.Contract.CreateOperatorDirectedAVSRewardsSubmission(&_RewardsCoordinator.TransactOpts, avs, operatorDirectedRewardsSubmissions) +} + // CreateRewardsForAllEarners is a paid mutator transaction binding the contract method 0xff9f6cce. // // Solidity: function createRewardsForAllEarners(((address,uint96)[],address,uint256,uint32,uint32)[] rewardsSubmissions) returns() @@ -1357,23 +1456,23 @@ func (_RewardsCoordinator *RewardsCoordinatorTransactorSession) DisableRoot(root // Initialize is a paid mutator transaction binding the contract method 0xd4540a55. // -// Solidity: function initialize(address initialOwner, address _pauserRegistry, uint256 initialPausedStatus, address _rewardsUpdater, uint32 _activationDelay, uint16 _globalCommissionBips) returns() -func (_RewardsCoordinator *RewardsCoordinatorTransactor) Initialize(opts *bind.TransactOpts, initialOwner common.Address, _pauserRegistry common.Address, initialPausedStatus *big.Int, _rewardsUpdater common.Address, _activationDelay uint32, _globalCommissionBips uint16) (*types.Transaction, error) { - return _RewardsCoordinator.contract.Transact(opts, "initialize", initialOwner, _pauserRegistry, initialPausedStatus, _rewardsUpdater, _activationDelay, _globalCommissionBips) +// Solidity: function initialize(address initialOwner, address _pauserRegistry, uint256 initialPausedStatus, address _rewardsUpdater, uint32 _activationDelay, uint16 _defaultSplitBips) returns() +func (_RewardsCoordinator *RewardsCoordinatorTransactor) Initialize(opts *bind.TransactOpts, initialOwner common.Address, _pauserRegistry common.Address, initialPausedStatus *big.Int, _rewardsUpdater common.Address, _activationDelay uint32, _defaultSplitBips uint16) (*types.Transaction, error) { + return _RewardsCoordinator.contract.Transact(opts, "initialize", initialOwner, _pauserRegistry, initialPausedStatus, _rewardsUpdater, _activationDelay, _defaultSplitBips) } // Initialize is a paid mutator transaction binding the contract method 0xd4540a55. // -// Solidity: function initialize(address initialOwner, address _pauserRegistry, uint256 initialPausedStatus, address _rewardsUpdater, uint32 _activationDelay, uint16 _globalCommissionBips) returns() -func (_RewardsCoordinator *RewardsCoordinatorSession) Initialize(initialOwner common.Address, _pauserRegistry common.Address, initialPausedStatus *big.Int, _rewardsUpdater common.Address, _activationDelay uint32, _globalCommissionBips uint16) (*types.Transaction, error) { - return _RewardsCoordinator.Contract.Initialize(&_RewardsCoordinator.TransactOpts, initialOwner, _pauserRegistry, initialPausedStatus, _rewardsUpdater, _activationDelay, _globalCommissionBips) +// Solidity: function initialize(address initialOwner, address _pauserRegistry, uint256 initialPausedStatus, address _rewardsUpdater, uint32 _activationDelay, uint16 _defaultSplitBips) returns() +func (_RewardsCoordinator *RewardsCoordinatorSession) Initialize(initialOwner common.Address, _pauserRegistry common.Address, initialPausedStatus *big.Int, _rewardsUpdater common.Address, _activationDelay uint32, _defaultSplitBips uint16) (*types.Transaction, error) { + return _RewardsCoordinator.Contract.Initialize(&_RewardsCoordinator.TransactOpts, initialOwner, _pauserRegistry, initialPausedStatus, _rewardsUpdater, _activationDelay, _defaultSplitBips) } // Initialize is a paid mutator transaction binding the contract method 0xd4540a55. // -// Solidity: function initialize(address initialOwner, address _pauserRegistry, uint256 initialPausedStatus, address _rewardsUpdater, uint32 _activationDelay, uint16 _globalCommissionBips) returns() -func (_RewardsCoordinator *RewardsCoordinatorTransactorSession) Initialize(initialOwner common.Address, _pauserRegistry common.Address, initialPausedStatus *big.Int, _rewardsUpdater common.Address, _activationDelay uint32, _globalCommissionBips uint16) (*types.Transaction, error) { - return _RewardsCoordinator.Contract.Initialize(&_RewardsCoordinator.TransactOpts, initialOwner, _pauserRegistry, initialPausedStatus, _rewardsUpdater, _activationDelay, _globalCommissionBips) +// Solidity: function initialize(address initialOwner, address _pauserRegistry, uint256 initialPausedStatus, address _rewardsUpdater, uint32 _activationDelay, uint16 _defaultSplitBips) returns() +func (_RewardsCoordinator *RewardsCoordinatorTransactorSession) Initialize(initialOwner common.Address, _pauserRegistry common.Address, initialPausedStatus *big.Int, _rewardsUpdater common.Address, _activationDelay uint32, _defaultSplitBips uint16) (*types.Transaction, error) { + return _RewardsCoordinator.Contract.Initialize(&_RewardsCoordinator.TransactOpts, initialOwner, _pauserRegistry, initialPausedStatus, _rewardsUpdater, _activationDelay, _defaultSplitBips) } // Pause is a paid mutator transaction binding the contract method 0x136439dd. @@ -1439,6 +1538,27 @@ func (_RewardsCoordinator *RewardsCoordinatorTransactorSession) ProcessClaim(cla return _RewardsCoordinator.Contract.ProcessClaim(&_RewardsCoordinator.TransactOpts, claim, recipient) } +// ProcessClaims is a paid mutator transaction binding the contract method 0x4596021c. +// +// Solidity: function processClaims((uint32,uint32,bytes,(address,bytes32),uint32[],bytes[],(address,uint256)[])[] claims, address recipient) returns() +func (_RewardsCoordinator *RewardsCoordinatorTransactor) ProcessClaims(opts *bind.TransactOpts, claims []IRewardsCoordinatorRewardsMerkleClaim, recipient common.Address) (*types.Transaction, error) { + return _RewardsCoordinator.contract.Transact(opts, "processClaims", claims, recipient) +} + +// ProcessClaims is a paid mutator transaction binding the contract method 0x4596021c. +// +// Solidity: function processClaims((uint32,uint32,bytes,(address,bytes32),uint32[],bytes[],(address,uint256)[])[] claims, address recipient) returns() +func (_RewardsCoordinator *RewardsCoordinatorSession) ProcessClaims(claims []IRewardsCoordinatorRewardsMerkleClaim, recipient common.Address) (*types.Transaction, error) { + return _RewardsCoordinator.Contract.ProcessClaims(&_RewardsCoordinator.TransactOpts, claims, recipient) +} + +// ProcessClaims is a paid mutator transaction binding the contract method 0x4596021c. +// +// Solidity: function processClaims((uint32,uint32,bytes,(address,bytes32),uint32[],bytes[],(address,uint256)[])[] claims, address recipient) returns() +func (_RewardsCoordinator *RewardsCoordinatorTransactorSession) ProcessClaims(claims []IRewardsCoordinatorRewardsMerkleClaim, recipient common.Address) (*types.Transaction, error) { + return _RewardsCoordinator.Contract.ProcessClaims(&_RewardsCoordinator.TransactOpts, claims, recipient) +} + // RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6. // // Solidity: function renounceOwnership() returns() @@ -1502,25 +1622,67 @@ func (_RewardsCoordinator *RewardsCoordinatorTransactorSession) SetClaimerFor(cl return _RewardsCoordinator.Contract.SetClaimerFor(&_RewardsCoordinator.TransactOpts, claimer) } -// SetGlobalOperatorCommission is a paid mutator transaction binding the contract method 0xe221b245. +// SetDefaultOperatorSplit is a paid mutator transaction binding the contract method 0xa50a1d9c. +// +// Solidity: function setDefaultOperatorSplit(uint16 split) returns() +func (_RewardsCoordinator *RewardsCoordinatorTransactor) SetDefaultOperatorSplit(opts *bind.TransactOpts, split uint16) (*types.Transaction, error) { + return _RewardsCoordinator.contract.Transact(opts, "setDefaultOperatorSplit", split) +} + +// SetDefaultOperatorSplit is a paid mutator transaction binding the contract method 0xa50a1d9c. +// +// Solidity: function setDefaultOperatorSplit(uint16 split) returns() +func (_RewardsCoordinator *RewardsCoordinatorSession) SetDefaultOperatorSplit(split uint16) (*types.Transaction, error) { + return _RewardsCoordinator.Contract.SetDefaultOperatorSplit(&_RewardsCoordinator.TransactOpts, split) +} + +// SetDefaultOperatorSplit is a paid mutator transaction binding the contract method 0xa50a1d9c. +// +// Solidity: function setDefaultOperatorSplit(uint16 split) returns() +func (_RewardsCoordinator *RewardsCoordinatorTransactorSession) SetDefaultOperatorSplit(split uint16) (*types.Transaction, error) { + return _RewardsCoordinator.Contract.SetDefaultOperatorSplit(&_RewardsCoordinator.TransactOpts, split) +} + +// SetOperatorAVSSplit is a paid mutator transaction binding the contract method 0xdcbb03b3. +// +// Solidity: function setOperatorAVSSplit(address operator, address avs, uint16 split) returns() +func (_RewardsCoordinator *RewardsCoordinatorTransactor) SetOperatorAVSSplit(opts *bind.TransactOpts, operator common.Address, avs common.Address, split uint16) (*types.Transaction, error) { + return _RewardsCoordinator.contract.Transact(opts, "setOperatorAVSSplit", operator, avs, split) +} + +// SetOperatorAVSSplit is a paid mutator transaction binding the contract method 0xdcbb03b3. +// +// Solidity: function setOperatorAVSSplit(address operator, address avs, uint16 split) returns() +func (_RewardsCoordinator *RewardsCoordinatorSession) SetOperatorAVSSplit(operator common.Address, avs common.Address, split uint16) (*types.Transaction, error) { + return _RewardsCoordinator.Contract.SetOperatorAVSSplit(&_RewardsCoordinator.TransactOpts, operator, avs, split) +} + +// SetOperatorAVSSplit is a paid mutator transaction binding the contract method 0xdcbb03b3. +// +// Solidity: function setOperatorAVSSplit(address operator, address avs, uint16 split) returns() +func (_RewardsCoordinator *RewardsCoordinatorTransactorSession) SetOperatorAVSSplit(operator common.Address, avs common.Address, split uint16) (*types.Transaction, error) { + return _RewardsCoordinator.Contract.SetOperatorAVSSplit(&_RewardsCoordinator.TransactOpts, operator, avs, split) +} + +// SetOperatorPISplit is a paid mutator transaction binding the contract method 0xb3dbb0e0. // -// Solidity: function setGlobalOperatorCommission(uint16 _globalCommissionBips) returns() -func (_RewardsCoordinator *RewardsCoordinatorTransactor) SetGlobalOperatorCommission(opts *bind.TransactOpts, _globalCommissionBips uint16) (*types.Transaction, error) { - return _RewardsCoordinator.contract.Transact(opts, "setGlobalOperatorCommission", _globalCommissionBips) +// Solidity: function setOperatorPISplit(address operator, uint16 split) returns() +func (_RewardsCoordinator *RewardsCoordinatorTransactor) SetOperatorPISplit(opts *bind.TransactOpts, operator common.Address, split uint16) (*types.Transaction, error) { + return _RewardsCoordinator.contract.Transact(opts, "setOperatorPISplit", operator, split) } -// SetGlobalOperatorCommission is a paid mutator transaction binding the contract method 0xe221b245. +// SetOperatorPISplit is a paid mutator transaction binding the contract method 0xb3dbb0e0. // -// Solidity: function setGlobalOperatorCommission(uint16 _globalCommissionBips) returns() -func (_RewardsCoordinator *RewardsCoordinatorSession) SetGlobalOperatorCommission(_globalCommissionBips uint16) (*types.Transaction, error) { - return _RewardsCoordinator.Contract.SetGlobalOperatorCommission(&_RewardsCoordinator.TransactOpts, _globalCommissionBips) +// Solidity: function setOperatorPISplit(address operator, uint16 split) returns() +func (_RewardsCoordinator *RewardsCoordinatorSession) SetOperatorPISplit(operator common.Address, split uint16) (*types.Transaction, error) { + return _RewardsCoordinator.Contract.SetOperatorPISplit(&_RewardsCoordinator.TransactOpts, operator, split) } -// SetGlobalOperatorCommission is a paid mutator transaction binding the contract method 0xe221b245. +// SetOperatorPISplit is a paid mutator transaction binding the contract method 0xb3dbb0e0. // -// Solidity: function setGlobalOperatorCommission(uint16 _globalCommissionBips) returns() -func (_RewardsCoordinator *RewardsCoordinatorTransactorSession) SetGlobalOperatorCommission(_globalCommissionBips uint16) (*types.Transaction, error) { - return _RewardsCoordinator.Contract.SetGlobalOperatorCommission(&_RewardsCoordinator.TransactOpts, _globalCommissionBips) +// Solidity: function setOperatorPISplit(address operator, uint16 split) returns() +func (_RewardsCoordinator *RewardsCoordinatorTransactorSession) SetOperatorPISplit(operator common.Address, split uint16) (*types.Transaction, error) { + return _RewardsCoordinator.Contract.SetOperatorPISplit(&_RewardsCoordinator.TransactOpts, operator, split) } // SetPauserRegistry is a paid mutator transaction binding the contract method 0x10d67a2f. @@ -2109,6 +2271,141 @@ func (_RewardsCoordinator *RewardsCoordinatorFilterer) ParseClaimerForSet(log ty return event, nil } +// RewardsCoordinatorDefaultOperatorSplitBipsSetIterator is returned from FilterDefaultOperatorSplitBipsSet and is used to iterate over the raw logs and unpacked data for DefaultOperatorSplitBipsSet events raised by the RewardsCoordinator contract. +type RewardsCoordinatorDefaultOperatorSplitBipsSetIterator struct { + Event *RewardsCoordinatorDefaultOperatorSplitBipsSet // Event containing the contract specifics and raw log + + contract *bind.BoundContract // Generic contract to use for unpacking event data + event string // Event name to use for unpacking event data + + logs chan types.Log // Log channel receiving the found contract events + sub ethereum.Subscription // Subscription for errors, completion and termination + done bool // Whether the subscription completed delivering logs + fail error // Occurred error to stop iteration +} + +// Next advances the iterator to the subsequent event, returning whether there +// are any more events found. In case of a retrieval or parsing error, false is +// returned and Error() can be queried for the exact failure. +func (it *RewardsCoordinatorDefaultOperatorSplitBipsSetIterator) Next() bool { + // If the iterator failed, stop iterating + if it.fail != nil { + return false + } + // If the iterator completed, deliver directly whatever's available + if it.done { + select { + case log := <-it.logs: + it.Event = new(RewardsCoordinatorDefaultOperatorSplitBipsSet) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + // Iterator still in progress, wait for either a data or an error event + select { + case log := <-it.logs: + it.Event = new(RewardsCoordinatorDefaultOperatorSplitBipsSet) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +// Error returns any retrieval or parsing error occurred during filtering. +func (it *RewardsCoordinatorDefaultOperatorSplitBipsSetIterator) Error() error { + return it.fail +} + +// Close terminates the iteration process, releasing any pending underlying +// resources. +func (it *RewardsCoordinatorDefaultOperatorSplitBipsSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +// RewardsCoordinatorDefaultOperatorSplitBipsSet represents a DefaultOperatorSplitBipsSet event raised by the RewardsCoordinator contract. +type RewardsCoordinatorDefaultOperatorSplitBipsSet struct { + OldDefaultOperatorSplitBips uint16 + NewDefaultOperatorSplitBips uint16 + Raw types.Log // Blockchain specific contextual infos +} + +// FilterDefaultOperatorSplitBipsSet is a free log retrieval operation binding the contract event 0xe6cd4edfdcc1f6d130ab35f73d72378f3a642944fb4ee5bd84b7807a81ea1c4e. +// +// Solidity: event DefaultOperatorSplitBipsSet(uint16 oldDefaultOperatorSplitBips, uint16 newDefaultOperatorSplitBips) +func (_RewardsCoordinator *RewardsCoordinatorFilterer) FilterDefaultOperatorSplitBipsSet(opts *bind.FilterOpts) (*RewardsCoordinatorDefaultOperatorSplitBipsSetIterator, error) { + + logs, sub, err := _RewardsCoordinator.contract.FilterLogs(opts, "DefaultOperatorSplitBipsSet") + if err != nil { + return nil, err + } + return &RewardsCoordinatorDefaultOperatorSplitBipsSetIterator{contract: _RewardsCoordinator.contract, event: "DefaultOperatorSplitBipsSet", logs: logs, sub: sub}, nil +} + +// WatchDefaultOperatorSplitBipsSet is a free log subscription operation binding the contract event 0xe6cd4edfdcc1f6d130ab35f73d72378f3a642944fb4ee5bd84b7807a81ea1c4e. +// +// Solidity: event DefaultOperatorSplitBipsSet(uint16 oldDefaultOperatorSplitBips, uint16 newDefaultOperatorSplitBips) +func (_RewardsCoordinator *RewardsCoordinatorFilterer) WatchDefaultOperatorSplitBipsSet(opts *bind.WatchOpts, sink chan<- *RewardsCoordinatorDefaultOperatorSplitBipsSet) (event.Subscription, error) { + + logs, sub, err := _RewardsCoordinator.contract.WatchLogs(opts, "DefaultOperatorSplitBipsSet") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + // New log arrived, parse the event and forward to the user + event := new(RewardsCoordinatorDefaultOperatorSplitBipsSet) + if err := _RewardsCoordinator.contract.UnpackLog(event, "DefaultOperatorSplitBipsSet", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +// ParseDefaultOperatorSplitBipsSet is a log parse operation binding the contract event 0xe6cd4edfdcc1f6d130ab35f73d72378f3a642944fb4ee5bd84b7807a81ea1c4e. +// +// Solidity: event DefaultOperatorSplitBipsSet(uint16 oldDefaultOperatorSplitBips, uint16 newDefaultOperatorSplitBips) +func (_RewardsCoordinator *RewardsCoordinatorFilterer) ParseDefaultOperatorSplitBipsSet(log types.Log) (*RewardsCoordinatorDefaultOperatorSplitBipsSet, error) { + event := new(RewardsCoordinatorDefaultOperatorSplitBipsSet) + if err := _RewardsCoordinator.contract.UnpackLog(event, "DefaultOperatorSplitBipsSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + // RewardsCoordinatorDistributionRootDisabledIterator is returned from FilterDistributionRootDisabled and is used to iterate over the raw logs and unpacked data for DistributionRootDisabled events raised by the RewardsCoordinator contract. type RewardsCoordinatorDistributionRootDisabledIterator struct { Event *RewardsCoordinatorDistributionRootDisabled // Event containing the contract specifics and raw log @@ -2416,11 +2713,11 @@ func (_RewardsCoordinator *RewardsCoordinatorFilterer) ParseDistributionRootSubm return event, nil } -// RewardsCoordinatorGlobalCommissionBipsSetIterator is returned from FilterGlobalCommissionBipsSet and is used to iterate over the raw logs and unpacked data for GlobalCommissionBipsSet events raised by the RewardsCoordinator contract. -type RewardsCoordinatorGlobalCommissionBipsSetIterator struct { - Event *RewardsCoordinatorGlobalCommissionBipsSet // Event containing the contract specifics and raw log - - contract *bind.BoundContract // Generic contract to use for unpacking event data +// RewardsCoordinatorInitializedIterator is returned from FilterInitialized and is used to iterate over the raw logs and unpacked data for Initialized events raised by the RewardsCoordinator contract. +type RewardsCoordinatorInitializedIterator struct { + Event *RewardsCoordinatorInitialized // Event containing the contract specifics and raw log + + contract *bind.BoundContract // Generic contract to use for unpacking event data event string // Event name to use for unpacking event data logs chan types.Log // Log channel receiving the found contract events @@ -2432,7 +2729,7 @@ type RewardsCoordinatorGlobalCommissionBipsSetIterator struct { // Next advances the iterator to the subsequent event, returning whether there // are any more events found. In case of a retrieval or parsing error, false is // returned and Error() can be queried for the exact failure. -func (it *RewardsCoordinatorGlobalCommissionBipsSetIterator) Next() bool { +func (it *RewardsCoordinatorInitializedIterator) Next() bool { // If the iterator failed, stop iterating if it.fail != nil { return false @@ -2441,7 +2738,7 @@ func (it *RewardsCoordinatorGlobalCommissionBipsSetIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(RewardsCoordinatorGlobalCommissionBipsSet) + it.Event = new(RewardsCoordinatorInitialized) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2456,7 +2753,7 @@ func (it *RewardsCoordinatorGlobalCommissionBipsSetIterator) Next() bool { // Iterator still in progress, wait for either a data or an error event select { case log := <-it.logs: - it.Event = new(RewardsCoordinatorGlobalCommissionBipsSet) + it.Event = new(RewardsCoordinatorInitialized) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2472,42 +2769,206 @@ func (it *RewardsCoordinatorGlobalCommissionBipsSetIterator) Next() bool { } // Error returns any retrieval or parsing error occurred during filtering. -func (it *RewardsCoordinatorGlobalCommissionBipsSetIterator) Error() error { +func (it *RewardsCoordinatorInitializedIterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. -func (it *RewardsCoordinatorGlobalCommissionBipsSetIterator) Close() error { +func (it *RewardsCoordinatorInitializedIterator) Close() error { it.sub.Unsubscribe() return nil } -// RewardsCoordinatorGlobalCommissionBipsSet represents a GlobalCommissionBipsSet event raised by the RewardsCoordinator contract. -type RewardsCoordinatorGlobalCommissionBipsSet struct { - OldGlobalCommissionBips uint16 - NewGlobalCommissionBips uint16 +// RewardsCoordinatorInitialized represents a Initialized event raised by the RewardsCoordinator contract. +type RewardsCoordinatorInitialized struct { + Version uint8 + Raw types.Log // Blockchain specific contextual infos +} + +// FilterInitialized is a free log retrieval operation binding the contract event 0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498. +// +// Solidity: event Initialized(uint8 version) +func (_RewardsCoordinator *RewardsCoordinatorFilterer) FilterInitialized(opts *bind.FilterOpts) (*RewardsCoordinatorInitializedIterator, error) { + + logs, sub, err := _RewardsCoordinator.contract.FilterLogs(opts, "Initialized") + if err != nil { + return nil, err + } + return &RewardsCoordinatorInitializedIterator{contract: _RewardsCoordinator.contract, event: "Initialized", logs: logs, sub: sub}, nil +} + +// WatchInitialized is a free log subscription operation binding the contract event 0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498. +// +// Solidity: event Initialized(uint8 version) +func (_RewardsCoordinator *RewardsCoordinatorFilterer) WatchInitialized(opts *bind.WatchOpts, sink chan<- *RewardsCoordinatorInitialized) (event.Subscription, error) { + + logs, sub, err := _RewardsCoordinator.contract.WatchLogs(opts, "Initialized") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + // New log arrived, parse the event and forward to the user + event := new(RewardsCoordinatorInitialized) + if err := _RewardsCoordinator.contract.UnpackLog(event, "Initialized", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +// ParseInitialized is a log parse operation binding the contract event 0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498. +// +// Solidity: event Initialized(uint8 version) +func (_RewardsCoordinator *RewardsCoordinatorFilterer) ParseInitialized(log types.Log) (*RewardsCoordinatorInitialized, error) { + event := new(RewardsCoordinatorInitialized) + if err := _RewardsCoordinator.contract.UnpackLog(event, "Initialized", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +// RewardsCoordinatorOperatorAVSSplitBipsSetIterator is returned from FilterOperatorAVSSplitBipsSet and is used to iterate over the raw logs and unpacked data for OperatorAVSSplitBipsSet events raised by the RewardsCoordinator contract. +type RewardsCoordinatorOperatorAVSSplitBipsSetIterator struct { + Event *RewardsCoordinatorOperatorAVSSplitBipsSet // Event containing the contract specifics and raw log + + contract *bind.BoundContract // Generic contract to use for unpacking event data + event string // Event name to use for unpacking event data + + logs chan types.Log // Log channel receiving the found contract events + sub ethereum.Subscription // Subscription for errors, completion and termination + done bool // Whether the subscription completed delivering logs + fail error // Occurred error to stop iteration +} + +// Next advances the iterator to the subsequent event, returning whether there +// are any more events found. In case of a retrieval or parsing error, false is +// returned and Error() can be queried for the exact failure. +func (it *RewardsCoordinatorOperatorAVSSplitBipsSetIterator) Next() bool { + // If the iterator failed, stop iterating + if it.fail != nil { + return false + } + // If the iterator completed, deliver directly whatever's available + if it.done { + select { + case log := <-it.logs: + it.Event = new(RewardsCoordinatorOperatorAVSSplitBipsSet) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + // Iterator still in progress, wait for either a data or an error event + select { + case log := <-it.logs: + it.Event = new(RewardsCoordinatorOperatorAVSSplitBipsSet) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +// Error returns any retrieval or parsing error occurred during filtering. +func (it *RewardsCoordinatorOperatorAVSSplitBipsSetIterator) Error() error { + return it.fail +} + +// Close terminates the iteration process, releasing any pending underlying +// resources. +func (it *RewardsCoordinatorOperatorAVSSplitBipsSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +// RewardsCoordinatorOperatorAVSSplitBipsSet represents a OperatorAVSSplitBipsSet event raised by the RewardsCoordinator contract. +type RewardsCoordinatorOperatorAVSSplitBipsSet struct { + Caller common.Address + Operator common.Address + Avs common.Address + ActivatedAt uint32 + OldOperatorAVSSplitBips uint16 + NewOperatorAVSSplitBips uint16 Raw types.Log // Blockchain specific contextual infos } -// FilterGlobalCommissionBipsSet is a free log retrieval operation binding the contract event 0x8cdc428b0431b82d1619763f443a48197db344ba96905f3949643acd1c863a06. +// FilterOperatorAVSSplitBipsSet is a free log retrieval operation binding the contract event 0x48e198b6ae357e529204ee53a8e514c470ff77d9cc8e4f7207f8b5d490ae6934. // -// Solidity: event GlobalCommissionBipsSet(uint16 oldGlobalCommissionBips, uint16 newGlobalCommissionBips) -func (_RewardsCoordinator *RewardsCoordinatorFilterer) FilterGlobalCommissionBipsSet(opts *bind.FilterOpts) (*RewardsCoordinatorGlobalCommissionBipsSetIterator, error) { +// Solidity: event OperatorAVSSplitBipsSet(address indexed caller, address indexed operator, address indexed avs, uint32 activatedAt, uint16 oldOperatorAVSSplitBips, uint16 newOperatorAVSSplitBips) +func (_RewardsCoordinator *RewardsCoordinatorFilterer) FilterOperatorAVSSplitBipsSet(opts *bind.FilterOpts, caller []common.Address, operator []common.Address, avs []common.Address) (*RewardsCoordinatorOperatorAVSSplitBipsSetIterator, error) { + + var callerRule []interface{} + for _, callerItem := range caller { + callerRule = append(callerRule, callerItem) + } + var operatorRule []interface{} + for _, operatorItem := range operator { + operatorRule = append(operatorRule, operatorItem) + } + var avsRule []interface{} + for _, avsItem := range avs { + avsRule = append(avsRule, avsItem) + } - logs, sub, err := _RewardsCoordinator.contract.FilterLogs(opts, "GlobalCommissionBipsSet") + logs, sub, err := _RewardsCoordinator.contract.FilterLogs(opts, "OperatorAVSSplitBipsSet", callerRule, operatorRule, avsRule) if err != nil { return nil, err } - return &RewardsCoordinatorGlobalCommissionBipsSetIterator{contract: _RewardsCoordinator.contract, event: "GlobalCommissionBipsSet", logs: logs, sub: sub}, nil + return &RewardsCoordinatorOperatorAVSSplitBipsSetIterator{contract: _RewardsCoordinator.contract, event: "OperatorAVSSplitBipsSet", logs: logs, sub: sub}, nil } -// WatchGlobalCommissionBipsSet is a free log subscription operation binding the contract event 0x8cdc428b0431b82d1619763f443a48197db344ba96905f3949643acd1c863a06. +// WatchOperatorAVSSplitBipsSet is a free log subscription operation binding the contract event 0x48e198b6ae357e529204ee53a8e514c470ff77d9cc8e4f7207f8b5d490ae6934. // -// Solidity: event GlobalCommissionBipsSet(uint16 oldGlobalCommissionBips, uint16 newGlobalCommissionBips) -func (_RewardsCoordinator *RewardsCoordinatorFilterer) WatchGlobalCommissionBipsSet(opts *bind.WatchOpts, sink chan<- *RewardsCoordinatorGlobalCommissionBipsSet) (event.Subscription, error) { +// Solidity: event OperatorAVSSplitBipsSet(address indexed caller, address indexed operator, address indexed avs, uint32 activatedAt, uint16 oldOperatorAVSSplitBips, uint16 newOperatorAVSSplitBips) +func (_RewardsCoordinator *RewardsCoordinatorFilterer) WatchOperatorAVSSplitBipsSet(opts *bind.WatchOpts, sink chan<- *RewardsCoordinatorOperatorAVSSplitBipsSet, caller []common.Address, operator []common.Address, avs []common.Address) (event.Subscription, error) { - logs, sub, err := _RewardsCoordinator.contract.WatchLogs(opts, "GlobalCommissionBipsSet") + var callerRule []interface{} + for _, callerItem := range caller { + callerRule = append(callerRule, callerItem) + } + var operatorRule []interface{} + for _, operatorItem := range operator { + operatorRule = append(operatorRule, operatorItem) + } + var avsRule []interface{} + for _, avsItem := range avs { + avsRule = append(avsRule, avsItem) + } + + logs, sub, err := _RewardsCoordinator.contract.WatchLogs(opts, "OperatorAVSSplitBipsSet", callerRule, operatorRule, avsRule) if err != nil { return nil, err } @@ -2517,8 +2978,8 @@ func (_RewardsCoordinator *RewardsCoordinatorFilterer) WatchGlobalCommissionBips select { case log := <-logs: // New log arrived, parse the event and forward to the user - event := new(RewardsCoordinatorGlobalCommissionBipsSet) - if err := _RewardsCoordinator.contract.UnpackLog(event, "GlobalCommissionBipsSet", log); err != nil { + event := new(RewardsCoordinatorOperatorAVSSplitBipsSet) + if err := _RewardsCoordinator.contract.UnpackLog(event, "OperatorAVSSplitBipsSet", log); err != nil { return err } event.Raw = log @@ -2539,21 +3000,21 @@ func (_RewardsCoordinator *RewardsCoordinatorFilterer) WatchGlobalCommissionBips }), nil } -// ParseGlobalCommissionBipsSet is a log parse operation binding the contract event 0x8cdc428b0431b82d1619763f443a48197db344ba96905f3949643acd1c863a06. +// ParseOperatorAVSSplitBipsSet is a log parse operation binding the contract event 0x48e198b6ae357e529204ee53a8e514c470ff77d9cc8e4f7207f8b5d490ae6934. // -// Solidity: event GlobalCommissionBipsSet(uint16 oldGlobalCommissionBips, uint16 newGlobalCommissionBips) -func (_RewardsCoordinator *RewardsCoordinatorFilterer) ParseGlobalCommissionBipsSet(log types.Log) (*RewardsCoordinatorGlobalCommissionBipsSet, error) { - event := new(RewardsCoordinatorGlobalCommissionBipsSet) - if err := _RewardsCoordinator.contract.UnpackLog(event, "GlobalCommissionBipsSet", log); err != nil { +// Solidity: event OperatorAVSSplitBipsSet(address indexed caller, address indexed operator, address indexed avs, uint32 activatedAt, uint16 oldOperatorAVSSplitBips, uint16 newOperatorAVSSplitBips) +func (_RewardsCoordinator *RewardsCoordinatorFilterer) ParseOperatorAVSSplitBipsSet(log types.Log) (*RewardsCoordinatorOperatorAVSSplitBipsSet, error) { + event := new(RewardsCoordinatorOperatorAVSSplitBipsSet) + if err := _RewardsCoordinator.contract.UnpackLog(event, "OperatorAVSSplitBipsSet", log); err != nil { return nil, err } event.Raw = log return event, nil } -// RewardsCoordinatorInitializedIterator is returned from FilterInitialized and is used to iterate over the raw logs and unpacked data for Initialized events raised by the RewardsCoordinator contract. -type RewardsCoordinatorInitializedIterator struct { - Event *RewardsCoordinatorInitialized // Event containing the contract specifics and raw log +// RewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreatedIterator is returned from FilterOperatorDirectedAVSRewardsSubmissionCreated and is used to iterate over the raw logs and unpacked data for OperatorDirectedAVSRewardsSubmissionCreated events raised by the RewardsCoordinator contract. +type RewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreatedIterator struct { + Event *RewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreated // Event containing the contract specifics and raw log contract *bind.BoundContract // Generic contract to use for unpacking event data event string // Event name to use for unpacking event data @@ -2567,7 +3028,7 @@ type RewardsCoordinatorInitializedIterator struct { // Next advances the iterator to the subsequent event, returning whether there // are any more events found. In case of a retrieval or parsing error, false is // returned and Error() can be queried for the exact failure. -func (it *RewardsCoordinatorInitializedIterator) Next() bool { +func (it *RewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreatedIterator) Next() bool { // If the iterator failed, stop iterating if it.fail != nil { return false @@ -2576,7 +3037,7 @@ func (it *RewardsCoordinatorInitializedIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(RewardsCoordinatorInitialized) + it.Event = new(RewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreated) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2591,7 +3052,7 @@ func (it *RewardsCoordinatorInitializedIterator) Next() bool { // Iterator still in progress, wait for either a data or an error event select { case log := <-it.logs: - it.Event = new(RewardsCoordinatorInitialized) + it.Event = new(RewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreated) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2607,41 +3068,71 @@ func (it *RewardsCoordinatorInitializedIterator) Next() bool { } // Error returns any retrieval or parsing error occurred during filtering. -func (it *RewardsCoordinatorInitializedIterator) Error() error { +func (it *RewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreatedIterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. -func (it *RewardsCoordinatorInitializedIterator) Close() error { +func (it *RewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreatedIterator) Close() error { it.sub.Unsubscribe() return nil } -// RewardsCoordinatorInitialized represents a Initialized event raised by the RewardsCoordinator contract. -type RewardsCoordinatorInitialized struct { - Version uint8 - Raw types.Log // Blockchain specific contextual infos +// RewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreated represents a OperatorDirectedAVSRewardsSubmissionCreated event raised by the RewardsCoordinator contract. +type RewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreated struct { + Caller common.Address + Avs common.Address + OperatorDirectedRewardsSubmissionHash [32]byte + SubmissionNonce *big.Int + OperatorDirectedRewardsSubmission IRewardsCoordinatorOperatorDirectedRewardsSubmission + Raw types.Log // Blockchain specific contextual infos } -// FilterInitialized is a free log retrieval operation binding the contract event 0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498. +// FilterOperatorDirectedAVSRewardsSubmissionCreated is a free log retrieval operation binding the contract event 0xfc8888bffd711da60bc5092b33f677d81896fe80ecc677b84cfab8184462b6e0. // -// Solidity: event Initialized(uint8 version) -func (_RewardsCoordinator *RewardsCoordinatorFilterer) FilterInitialized(opts *bind.FilterOpts) (*RewardsCoordinatorInitializedIterator, error) { +// Solidity: event OperatorDirectedAVSRewardsSubmissionCreated(address indexed caller, address indexed avs, bytes32 indexed operatorDirectedRewardsSubmissionHash, uint256 submissionNonce, ((address,uint96)[],address,(address,uint256)[],uint32,uint32,string) operatorDirectedRewardsSubmission) +func (_RewardsCoordinator *RewardsCoordinatorFilterer) FilterOperatorDirectedAVSRewardsSubmissionCreated(opts *bind.FilterOpts, caller []common.Address, avs []common.Address, operatorDirectedRewardsSubmissionHash [][32]byte) (*RewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreatedIterator, error) { - logs, sub, err := _RewardsCoordinator.contract.FilterLogs(opts, "Initialized") + var callerRule []interface{} + for _, callerItem := range caller { + callerRule = append(callerRule, callerItem) + } + var avsRule []interface{} + for _, avsItem := range avs { + avsRule = append(avsRule, avsItem) + } + var operatorDirectedRewardsSubmissionHashRule []interface{} + for _, operatorDirectedRewardsSubmissionHashItem := range operatorDirectedRewardsSubmissionHash { + operatorDirectedRewardsSubmissionHashRule = append(operatorDirectedRewardsSubmissionHashRule, operatorDirectedRewardsSubmissionHashItem) + } + + logs, sub, err := _RewardsCoordinator.contract.FilterLogs(opts, "OperatorDirectedAVSRewardsSubmissionCreated", callerRule, avsRule, operatorDirectedRewardsSubmissionHashRule) if err != nil { return nil, err } - return &RewardsCoordinatorInitializedIterator{contract: _RewardsCoordinator.contract, event: "Initialized", logs: logs, sub: sub}, nil + return &RewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreatedIterator{contract: _RewardsCoordinator.contract, event: "OperatorDirectedAVSRewardsSubmissionCreated", logs: logs, sub: sub}, nil } -// WatchInitialized is a free log subscription operation binding the contract event 0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498. +// WatchOperatorDirectedAVSRewardsSubmissionCreated is a free log subscription operation binding the contract event 0xfc8888bffd711da60bc5092b33f677d81896fe80ecc677b84cfab8184462b6e0. // -// Solidity: event Initialized(uint8 version) -func (_RewardsCoordinator *RewardsCoordinatorFilterer) WatchInitialized(opts *bind.WatchOpts, sink chan<- *RewardsCoordinatorInitialized) (event.Subscription, error) { +// Solidity: event OperatorDirectedAVSRewardsSubmissionCreated(address indexed caller, address indexed avs, bytes32 indexed operatorDirectedRewardsSubmissionHash, uint256 submissionNonce, ((address,uint96)[],address,(address,uint256)[],uint32,uint32,string) operatorDirectedRewardsSubmission) +func (_RewardsCoordinator *RewardsCoordinatorFilterer) WatchOperatorDirectedAVSRewardsSubmissionCreated(opts *bind.WatchOpts, sink chan<- *RewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreated, caller []common.Address, avs []common.Address, operatorDirectedRewardsSubmissionHash [][32]byte) (event.Subscription, error) { - logs, sub, err := _RewardsCoordinator.contract.WatchLogs(opts, "Initialized") + var callerRule []interface{} + for _, callerItem := range caller { + callerRule = append(callerRule, callerItem) + } + var avsRule []interface{} + for _, avsItem := range avs { + avsRule = append(avsRule, avsItem) + } + var operatorDirectedRewardsSubmissionHashRule []interface{} + for _, operatorDirectedRewardsSubmissionHashItem := range operatorDirectedRewardsSubmissionHash { + operatorDirectedRewardsSubmissionHashRule = append(operatorDirectedRewardsSubmissionHashRule, operatorDirectedRewardsSubmissionHashItem) + } + + logs, sub, err := _RewardsCoordinator.contract.WatchLogs(opts, "OperatorDirectedAVSRewardsSubmissionCreated", callerRule, avsRule, operatorDirectedRewardsSubmissionHashRule) if err != nil { return nil, err } @@ -2651,8 +3142,8 @@ func (_RewardsCoordinator *RewardsCoordinatorFilterer) WatchInitialized(opts *bi select { case log := <-logs: // New log arrived, parse the event and forward to the user - event := new(RewardsCoordinatorInitialized) - if err := _RewardsCoordinator.contract.UnpackLog(event, "Initialized", log); err != nil { + event := new(RewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreated) + if err := _RewardsCoordinator.contract.UnpackLog(event, "OperatorDirectedAVSRewardsSubmissionCreated", log); err != nil { return err } event.Raw = log @@ -2673,12 +3164,168 @@ func (_RewardsCoordinator *RewardsCoordinatorFilterer) WatchInitialized(opts *bi }), nil } -// ParseInitialized is a log parse operation binding the contract event 0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498. +// ParseOperatorDirectedAVSRewardsSubmissionCreated is a log parse operation binding the contract event 0xfc8888bffd711da60bc5092b33f677d81896fe80ecc677b84cfab8184462b6e0. // -// Solidity: event Initialized(uint8 version) -func (_RewardsCoordinator *RewardsCoordinatorFilterer) ParseInitialized(log types.Log) (*RewardsCoordinatorInitialized, error) { - event := new(RewardsCoordinatorInitialized) - if err := _RewardsCoordinator.contract.UnpackLog(event, "Initialized", log); err != nil { +// Solidity: event OperatorDirectedAVSRewardsSubmissionCreated(address indexed caller, address indexed avs, bytes32 indexed operatorDirectedRewardsSubmissionHash, uint256 submissionNonce, ((address,uint96)[],address,(address,uint256)[],uint32,uint32,string) operatorDirectedRewardsSubmission) +func (_RewardsCoordinator *RewardsCoordinatorFilterer) ParseOperatorDirectedAVSRewardsSubmissionCreated(log types.Log) (*RewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreated, error) { + event := new(RewardsCoordinatorOperatorDirectedAVSRewardsSubmissionCreated) + if err := _RewardsCoordinator.contract.UnpackLog(event, "OperatorDirectedAVSRewardsSubmissionCreated", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +// RewardsCoordinatorOperatorPISplitBipsSetIterator is returned from FilterOperatorPISplitBipsSet and is used to iterate over the raw logs and unpacked data for OperatorPISplitBipsSet events raised by the RewardsCoordinator contract. +type RewardsCoordinatorOperatorPISplitBipsSetIterator struct { + Event *RewardsCoordinatorOperatorPISplitBipsSet // Event containing the contract specifics and raw log + + contract *bind.BoundContract // Generic contract to use for unpacking event data + event string // Event name to use for unpacking event data + + logs chan types.Log // Log channel receiving the found contract events + sub ethereum.Subscription // Subscription for errors, completion and termination + done bool // Whether the subscription completed delivering logs + fail error // Occurred error to stop iteration +} + +// Next advances the iterator to the subsequent event, returning whether there +// are any more events found. In case of a retrieval or parsing error, false is +// returned and Error() can be queried for the exact failure. +func (it *RewardsCoordinatorOperatorPISplitBipsSetIterator) Next() bool { + // If the iterator failed, stop iterating + if it.fail != nil { + return false + } + // If the iterator completed, deliver directly whatever's available + if it.done { + select { + case log := <-it.logs: + it.Event = new(RewardsCoordinatorOperatorPISplitBipsSet) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + // Iterator still in progress, wait for either a data or an error event + select { + case log := <-it.logs: + it.Event = new(RewardsCoordinatorOperatorPISplitBipsSet) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +// Error returns any retrieval or parsing error occurred during filtering. +func (it *RewardsCoordinatorOperatorPISplitBipsSetIterator) Error() error { + return it.fail +} + +// Close terminates the iteration process, releasing any pending underlying +// resources. +func (it *RewardsCoordinatorOperatorPISplitBipsSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +// RewardsCoordinatorOperatorPISplitBipsSet represents a OperatorPISplitBipsSet event raised by the RewardsCoordinator contract. +type RewardsCoordinatorOperatorPISplitBipsSet struct { + Caller common.Address + Operator common.Address + ActivatedAt uint32 + OldOperatorPISplitBips uint16 + NewOperatorPISplitBips uint16 + Raw types.Log // Blockchain specific contextual infos +} + +// FilterOperatorPISplitBipsSet is a free log retrieval operation binding the contract event 0xd1e028bd664486a46ad26040e999cd2d22e1e9a094ee6afe19fcf64678f16f74. +// +// Solidity: event OperatorPISplitBipsSet(address indexed caller, address indexed operator, uint32 activatedAt, uint16 oldOperatorPISplitBips, uint16 newOperatorPISplitBips) +func (_RewardsCoordinator *RewardsCoordinatorFilterer) FilterOperatorPISplitBipsSet(opts *bind.FilterOpts, caller []common.Address, operator []common.Address) (*RewardsCoordinatorOperatorPISplitBipsSetIterator, error) { + + var callerRule []interface{} + for _, callerItem := range caller { + callerRule = append(callerRule, callerItem) + } + var operatorRule []interface{} + for _, operatorItem := range operator { + operatorRule = append(operatorRule, operatorItem) + } + + logs, sub, err := _RewardsCoordinator.contract.FilterLogs(opts, "OperatorPISplitBipsSet", callerRule, operatorRule) + if err != nil { + return nil, err + } + return &RewardsCoordinatorOperatorPISplitBipsSetIterator{contract: _RewardsCoordinator.contract, event: "OperatorPISplitBipsSet", logs: logs, sub: sub}, nil +} + +// WatchOperatorPISplitBipsSet is a free log subscription operation binding the contract event 0xd1e028bd664486a46ad26040e999cd2d22e1e9a094ee6afe19fcf64678f16f74. +// +// Solidity: event OperatorPISplitBipsSet(address indexed caller, address indexed operator, uint32 activatedAt, uint16 oldOperatorPISplitBips, uint16 newOperatorPISplitBips) +func (_RewardsCoordinator *RewardsCoordinatorFilterer) WatchOperatorPISplitBipsSet(opts *bind.WatchOpts, sink chan<- *RewardsCoordinatorOperatorPISplitBipsSet, caller []common.Address, operator []common.Address) (event.Subscription, error) { + + var callerRule []interface{} + for _, callerItem := range caller { + callerRule = append(callerRule, callerItem) + } + var operatorRule []interface{} + for _, operatorItem := range operator { + operatorRule = append(operatorRule, operatorItem) + } + + logs, sub, err := _RewardsCoordinator.contract.WatchLogs(opts, "OperatorPISplitBipsSet", callerRule, operatorRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + // New log arrived, parse the event and forward to the user + event := new(RewardsCoordinatorOperatorPISplitBipsSet) + if err := _RewardsCoordinator.contract.UnpackLog(event, "OperatorPISplitBipsSet", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +// ParseOperatorPISplitBipsSet is a log parse operation binding the contract event 0xd1e028bd664486a46ad26040e999cd2d22e1e9a094ee6afe19fcf64678f16f74. +// +// Solidity: event OperatorPISplitBipsSet(address indexed caller, address indexed operator, uint32 activatedAt, uint16 oldOperatorPISplitBips, uint16 newOperatorPISplitBips) +func (_RewardsCoordinator *RewardsCoordinatorFilterer) ParseOperatorPISplitBipsSet(log types.Log) (*RewardsCoordinatorOperatorPISplitBipsSet, error) { + event := new(RewardsCoordinatorOperatorPISplitBipsSet) + if err := _RewardsCoordinator.contract.UnpackLog(event, "OperatorPISplitBipsSet", log); err != nil { return nil, err } event.Raw = log diff --git a/pkg/bindings/RewardsCoordinatorStorage/binding.go b/pkg/bindings/RewardsCoordinatorStorage/binding.go index 0742ccec3..adaad400b 100644 --- a/pkg/bindings/RewardsCoordinatorStorage/binding.go +++ b/pkg/bindings/RewardsCoordinatorStorage/binding.go @@ -43,6 +43,22 @@ type IRewardsCoordinatorEarnerTreeMerkleLeaf struct { EarnerTokenRoot [32]byte } +// IRewardsCoordinatorOperatorDirectedRewardsSubmission is an auto generated low-level Go binding around an user-defined struct. +type IRewardsCoordinatorOperatorDirectedRewardsSubmission struct { + StrategiesAndMultipliers []IRewardsCoordinatorStrategyAndMultiplier + Token common.Address + OperatorRewards []IRewardsCoordinatorOperatorReward + StartTimestamp uint32 + Duration uint32 + Description string +} + +// IRewardsCoordinatorOperatorReward is an auto generated low-level Go binding around an user-defined struct. +type IRewardsCoordinatorOperatorReward struct { + Operator common.Address + Amount *big.Int +} + // IRewardsCoordinatorRewardsMerkleClaim is an auto generated low-level Go binding around an user-defined struct. type IRewardsCoordinatorRewardsMerkleClaim struct { RootIndex uint32 @@ -77,7 +93,7 @@ type IRewardsCoordinatorTokenTreeMerkleLeaf struct { // RewardsCoordinatorStorageMetaData contains all meta data concerning the RewardsCoordinatorStorage contract. var RewardsCoordinatorStorageMetaData = &bind.MetaData{ - ABI: "[{\"type\":\"function\",\"name\":\"CALCULATION_INTERVAL_SECONDS\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"GENESIS_REWARDS_TIMESTAMP\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"MAX_FUTURE_LENGTH\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"MAX_RETROACTIVE_LENGTH\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"MAX_REWARDS_DURATION\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"activationDelay\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"calculateEarnerLeafHash\",\"inputs\":[{\"name\":\"leaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.EarnerTreeMerkleLeaf\",\"components\":[{\"name\":\"earner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"earnerTokenRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"pure\"},{\"type\":\"function\",\"name\":\"calculateTokenLeafHash\",\"inputs\":[{\"name\":\"leaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.TokenTreeMerkleLeaf\",\"components\":[{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"cumulativeEarnings\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"pure\"},{\"type\":\"function\",\"name\":\"checkClaim\",\"inputs\":[{\"name\":\"claim\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.RewardsMerkleClaim\",\"components\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerTreeProof\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"earnerLeaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.EarnerTreeMerkleLeaf\",\"components\":[{\"name\":\"earner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"earnerTokenRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]},{\"name\":\"tokenIndices\",\"type\":\"uint32[]\",\"internalType\":\"uint32[]\"},{\"name\":\"tokenTreeProofs\",\"type\":\"bytes[]\",\"internalType\":\"bytes[]\"},{\"name\":\"tokenLeaves\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.TokenTreeMerkleLeaf[]\",\"components\":[{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"cumulativeEarnings\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]}]}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"claimerFor\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"createAVSRewardsSubmission\",\"inputs\":[{\"name\":\"rewardsSubmissions\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.RewardsSubmission[]\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"createRewardsForAllEarners\",\"inputs\":[{\"name\":\"rewardsSubmissions\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.RewardsSubmission[]\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"createRewardsForAllSubmission\",\"inputs\":[{\"name\":\"rewardsSubmission\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.RewardsSubmission[]\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"cumulativeClaimed\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIERC20\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"currRewardsCalculationEndTimestamp\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"delegationManager\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIDelegationManager\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"disableRoot\",\"inputs\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"domainSeparator\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getCurrentClaimableDistributionRoot\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.DistributionRoot\",\"components\":[{\"name\":\"root\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"disabled\",\"type\":\"bool\",\"internalType\":\"bool\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getCurrentDistributionRoot\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.DistributionRoot\",\"components\":[{\"name\":\"root\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"disabled\",\"type\":\"bool\",\"internalType\":\"bool\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getDistributionRootAtIndex\",\"inputs\":[{\"name\":\"index\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.DistributionRoot\",\"components\":[{\"name\":\"root\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"disabled\",\"type\":\"bool\",\"internalType\":\"bool\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getDistributionRootsLength\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getRootIndexFromHash\",\"inputs\":[{\"name\":\"rootHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"globalOperatorCommissionBips\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"isAVSRewardsSubmissionHash\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"isRewardsForAllSubmitter\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"isRewardsSubmissionForAllEarnersHash\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"isRewardsSubmissionForAllHash\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"operatorCommissionBips\",\"inputs\":[{\"name\":\"operator\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"avs\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"processClaim\",\"inputs\":[{\"name\":\"claim\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.RewardsMerkleClaim\",\"components\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerTreeProof\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"earnerLeaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.EarnerTreeMerkleLeaf\",\"components\":[{\"name\":\"earner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"earnerTokenRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]},{\"name\":\"tokenIndices\",\"type\":\"uint32[]\",\"internalType\":\"uint32[]\"},{\"name\":\"tokenTreeProofs\",\"type\":\"bytes[]\",\"internalType\":\"bytes[]\"},{\"name\":\"tokenLeaves\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.TokenTreeMerkleLeaf[]\",\"components\":[{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"cumulativeEarnings\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]}]},{\"name\":\"recipient\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"rewardsUpdater\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"setActivationDelay\",\"inputs\":[{\"name\":\"_activationDelay\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setClaimerFor\",\"inputs\":[{\"name\":\"claimer\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setGlobalOperatorCommission\",\"inputs\":[{\"name\":\"_globalCommissionBips\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setRewardsForAllSubmitter\",\"inputs\":[{\"name\":\"_submitter\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_newValue\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setRewardsUpdater\",\"inputs\":[{\"name\":\"_rewardsUpdater\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"strategyManager\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIStrategyManager\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"submissionNonce\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"submitRoot\",\"inputs\":[{\"name\":\"root\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"event\",\"name\":\"AVSRewardsSubmissionCreated\",\"inputs\":[{\"name\":\"avs\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"submissionNonce\",\"type\":\"uint256\",\"indexed\":true,\"internalType\":\"uint256\"},{\"name\":\"rewardsSubmissionHash\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"rewardsSubmission\",\"type\":\"tuple\",\"indexed\":false,\"internalType\":\"structIRewardsCoordinator.RewardsSubmission\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ActivationDelaySet\",\"inputs\":[{\"name\":\"oldActivationDelay\",\"type\":\"uint32\",\"indexed\":false,\"internalType\":\"uint32\"},{\"name\":\"newActivationDelay\",\"type\":\"uint32\",\"indexed\":false,\"internalType\":\"uint32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ClaimerForSet\",\"inputs\":[{\"name\":\"earner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"oldClaimer\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"claimer\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"DistributionRootDisabled\",\"inputs\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"indexed\":true,\"internalType\":\"uint32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"DistributionRootSubmitted\",\"inputs\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"indexed\":true,\"internalType\":\"uint32\"},{\"name\":\"root\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"indexed\":true,\"internalType\":\"uint32\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"indexed\":false,\"internalType\":\"uint32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"GlobalCommissionBipsSet\",\"inputs\":[{\"name\":\"oldGlobalCommissionBips\",\"type\":\"uint16\",\"indexed\":false,\"internalType\":\"uint16\"},{\"name\":\"newGlobalCommissionBips\",\"type\":\"uint16\",\"indexed\":false,\"internalType\":\"uint16\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsClaimed\",\"inputs\":[{\"name\":\"root\",\"type\":\"bytes32\",\"indexed\":false,\"internalType\":\"bytes32\"},{\"name\":\"earner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"claimer\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"token\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"contractIERC20\"},{\"name\":\"claimedAmount\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsForAllSubmitterSet\",\"inputs\":[{\"name\":\"rewardsForAllSubmitter\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"oldValue\",\"type\":\"bool\",\"indexed\":true,\"internalType\":\"bool\"},{\"name\":\"newValue\",\"type\":\"bool\",\"indexed\":true,\"internalType\":\"bool\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsSubmissionForAllCreated\",\"inputs\":[{\"name\":\"submitter\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"submissionNonce\",\"type\":\"uint256\",\"indexed\":true,\"internalType\":\"uint256\"},{\"name\":\"rewardsSubmissionHash\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"rewardsSubmission\",\"type\":\"tuple\",\"indexed\":false,\"internalType\":\"structIRewardsCoordinator.RewardsSubmission\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsSubmissionForAllEarnersCreated\",\"inputs\":[{\"name\":\"tokenHopper\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"submissionNonce\",\"type\":\"uint256\",\"indexed\":true,\"internalType\":\"uint256\"},{\"name\":\"rewardsSubmissionHash\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"rewardsSubmission\",\"type\":\"tuple\",\"indexed\":false,\"internalType\":\"structIRewardsCoordinator.RewardsSubmission\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsUpdaterSet\",\"inputs\":[{\"name\":\"oldRewardsUpdater\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newRewardsUpdater\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false}]", + ABI: "[{\"type\":\"function\",\"name\":\"CALCULATION_INTERVAL_SECONDS\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"GENESIS_REWARDS_TIMESTAMP\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"MAX_FUTURE_LENGTH\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"MAX_RETROACTIVE_LENGTH\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"MAX_REWARDS_DURATION\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"activationDelay\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"calculateEarnerLeafHash\",\"inputs\":[{\"name\":\"leaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.EarnerTreeMerkleLeaf\",\"components\":[{\"name\":\"earner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"earnerTokenRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"pure\"},{\"type\":\"function\",\"name\":\"calculateTokenLeafHash\",\"inputs\":[{\"name\":\"leaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.TokenTreeMerkleLeaf\",\"components\":[{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"cumulativeEarnings\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"pure\"},{\"type\":\"function\",\"name\":\"checkClaim\",\"inputs\":[{\"name\":\"claim\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.RewardsMerkleClaim\",\"components\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerTreeProof\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"earnerLeaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.EarnerTreeMerkleLeaf\",\"components\":[{\"name\":\"earner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"earnerTokenRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]},{\"name\":\"tokenIndices\",\"type\":\"uint32[]\",\"internalType\":\"uint32[]\"},{\"name\":\"tokenTreeProofs\",\"type\":\"bytes[]\",\"internalType\":\"bytes[]\"},{\"name\":\"tokenLeaves\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.TokenTreeMerkleLeaf[]\",\"components\":[{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"cumulativeEarnings\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]}]}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"claimerFor\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"createAVSRewardsSubmission\",\"inputs\":[{\"name\":\"rewardsSubmissions\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.RewardsSubmission[]\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"createOperatorDirectedAVSRewardsSubmission\",\"inputs\":[{\"name\":\"avs\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"operatorDirectedRewardsSubmissions\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.OperatorDirectedRewardsSubmission[]\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"operatorRewards\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.OperatorReward[]\",\"components\":[{\"name\":\"operator\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"description\",\"type\":\"string\",\"internalType\":\"string\"}]}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"createRewardsForAllEarners\",\"inputs\":[{\"name\":\"rewardsSubmissions\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.RewardsSubmission[]\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"createRewardsForAllSubmission\",\"inputs\":[{\"name\":\"rewardsSubmission\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.RewardsSubmission[]\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"cumulativeClaimed\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIERC20\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"currRewardsCalculationEndTimestamp\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"defaultOperatorSplitBips\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"delegationManager\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIDelegationManager\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"disableRoot\",\"inputs\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"domainSeparator\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getCurrentClaimableDistributionRoot\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.DistributionRoot\",\"components\":[{\"name\":\"root\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"disabled\",\"type\":\"bool\",\"internalType\":\"bool\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getCurrentDistributionRoot\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.DistributionRoot\",\"components\":[{\"name\":\"root\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"disabled\",\"type\":\"bool\",\"internalType\":\"bool\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getDistributionRootAtIndex\",\"inputs\":[{\"name\":\"index\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.DistributionRoot\",\"components\":[{\"name\":\"root\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"disabled\",\"type\":\"bool\",\"internalType\":\"bool\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getDistributionRootsLength\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getOperatorAVSSplit\",\"inputs\":[{\"name\":\"operator\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"avs\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getOperatorPISplit\",\"inputs\":[{\"name\":\"operator\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getRootIndexFromHash\",\"inputs\":[{\"name\":\"rootHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"isAVSRewardsSubmissionHash\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"isOperatorDirectedAVSRewardsSubmissionHash\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"isRewardsForAllSubmitter\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"isRewardsSubmissionForAllEarnersHash\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"isRewardsSubmissionForAllHash\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"processClaim\",\"inputs\":[{\"name\":\"claim\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.RewardsMerkleClaim\",\"components\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerTreeProof\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"earnerLeaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.EarnerTreeMerkleLeaf\",\"components\":[{\"name\":\"earner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"earnerTokenRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]},{\"name\":\"tokenIndices\",\"type\":\"uint32[]\",\"internalType\":\"uint32[]\"},{\"name\":\"tokenTreeProofs\",\"type\":\"bytes[]\",\"internalType\":\"bytes[]\"},{\"name\":\"tokenLeaves\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.TokenTreeMerkleLeaf[]\",\"components\":[{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"cumulativeEarnings\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]}]},{\"name\":\"recipient\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"processClaims\",\"inputs\":[{\"name\":\"claims\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.RewardsMerkleClaim[]\",\"components\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"earnerTreeProof\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"earnerLeaf\",\"type\":\"tuple\",\"internalType\":\"structIRewardsCoordinator.EarnerTreeMerkleLeaf\",\"components\":[{\"name\":\"earner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"earnerTokenRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]},{\"name\":\"tokenIndices\",\"type\":\"uint32[]\",\"internalType\":\"uint32[]\"},{\"name\":\"tokenTreeProofs\",\"type\":\"bytes[]\",\"internalType\":\"bytes[]\"},{\"name\":\"tokenLeaves\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.TokenTreeMerkleLeaf[]\",\"components\":[{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"cumulativeEarnings\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]}]},{\"name\":\"recipient\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"rewardsUpdater\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"setActivationDelay\",\"inputs\":[{\"name\":\"_activationDelay\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setClaimerFor\",\"inputs\":[{\"name\":\"claimer\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setDefaultOperatorSplit\",\"inputs\":[{\"name\":\"split\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setOperatorAVSSplit\",\"inputs\":[{\"name\":\"operator\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"avs\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"split\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setOperatorPISplit\",\"inputs\":[{\"name\":\"operator\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"split\",\"type\":\"uint16\",\"internalType\":\"uint16\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setRewardsForAllSubmitter\",\"inputs\":[{\"name\":\"_submitter\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_newValue\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setRewardsUpdater\",\"inputs\":[{\"name\":\"_rewardsUpdater\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"strategyManager\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIStrategyManager\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"submissionNonce\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"submitRoot\",\"inputs\":[{\"name\":\"root\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"event\",\"name\":\"AVSRewardsSubmissionCreated\",\"inputs\":[{\"name\":\"avs\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"submissionNonce\",\"type\":\"uint256\",\"indexed\":true,\"internalType\":\"uint256\"},{\"name\":\"rewardsSubmissionHash\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"rewardsSubmission\",\"type\":\"tuple\",\"indexed\":false,\"internalType\":\"structIRewardsCoordinator.RewardsSubmission\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ActivationDelaySet\",\"inputs\":[{\"name\":\"oldActivationDelay\",\"type\":\"uint32\",\"indexed\":false,\"internalType\":\"uint32\"},{\"name\":\"newActivationDelay\",\"type\":\"uint32\",\"indexed\":false,\"internalType\":\"uint32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ClaimerForSet\",\"inputs\":[{\"name\":\"earner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"oldClaimer\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"claimer\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"DefaultOperatorSplitBipsSet\",\"inputs\":[{\"name\":\"oldDefaultOperatorSplitBips\",\"type\":\"uint16\",\"indexed\":false,\"internalType\":\"uint16\"},{\"name\":\"newDefaultOperatorSplitBips\",\"type\":\"uint16\",\"indexed\":false,\"internalType\":\"uint16\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"DistributionRootDisabled\",\"inputs\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"indexed\":true,\"internalType\":\"uint32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"DistributionRootSubmitted\",\"inputs\":[{\"name\":\"rootIndex\",\"type\":\"uint32\",\"indexed\":true,\"internalType\":\"uint32\"},{\"name\":\"root\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"rewardsCalculationEndTimestamp\",\"type\":\"uint32\",\"indexed\":true,\"internalType\":\"uint32\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"indexed\":false,\"internalType\":\"uint32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"OperatorAVSSplitBipsSet\",\"inputs\":[{\"name\":\"caller\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"operator\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"avs\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"indexed\":false,\"internalType\":\"uint32\"},{\"name\":\"oldOperatorAVSSplitBips\",\"type\":\"uint16\",\"indexed\":false,\"internalType\":\"uint16\"},{\"name\":\"newOperatorAVSSplitBips\",\"type\":\"uint16\",\"indexed\":false,\"internalType\":\"uint16\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"OperatorDirectedAVSRewardsSubmissionCreated\",\"inputs\":[{\"name\":\"caller\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"avs\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"operatorDirectedRewardsSubmissionHash\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"submissionNonce\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"operatorDirectedRewardsSubmission\",\"type\":\"tuple\",\"indexed\":false,\"internalType\":\"structIRewardsCoordinator.OperatorDirectedRewardsSubmission\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"operatorRewards\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.OperatorReward[]\",\"components\":[{\"name\":\"operator\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"description\",\"type\":\"string\",\"internalType\":\"string\"}]}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"OperatorPISplitBipsSet\",\"inputs\":[{\"name\":\"caller\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"operator\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"activatedAt\",\"type\":\"uint32\",\"indexed\":false,\"internalType\":\"uint32\"},{\"name\":\"oldOperatorPISplitBips\",\"type\":\"uint16\",\"indexed\":false,\"internalType\":\"uint16\"},{\"name\":\"newOperatorPISplitBips\",\"type\":\"uint16\",\"indexed\":false,\"internalType\":\"uint16\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsClaimed\",\"inputs\":[{\"name\":\"root\",\"type\":\"bytes32\",\"indexed\":false,\"internalType\":\"bytes32\"},{\"name\":\"earner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"claimer\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"token\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"contractIERC20\"},{\"name\":\"claimedAmount\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsForAllSubmitterSet\",\"inputs\":[{\"name\":\"rewardsForAllSubmitter\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"oldValue\",\"type\":\"bool\",\"indexed\":true,\"internalType\":\"bool\"},{\"name\":\"newValue\",\"type\":\"bool\",\"indexed\":true,\"internalType\":\"bool\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsSubmissionForAllCreated\",\"inputs\":[{\"name\":\"submitter\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"submissionNonce\",\"type\":\"uint256\",\"indexed\":true,\"internalType\":\"uint256\"},{\"name\":\"rewardsSubmissionHash\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"rewardsSubmission\",\"type\":\"tuple\",\"indexed\":false,\"internalType\":\"structIRewardsCoordinator.RewardsSubmission\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsSubmissionForAllEarnersCreated\",\"inputs\":[{\"name\":\"tokenHopper\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"submissionNonce\",\"type\":\"uint256\",\"indexed\":true,\"internalType\":\"uint256\"},{\"name\":\"rewardsSubmissionHash\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"rewardsSubmission\",\"type\":\"tuple\",\"indexed\":false,\"internalType\":\"structIRewardsCoordinator.RewardsSubmission\",\"components\":[{\"name\":\"strategiesAndMultipliers\",\"type\":\"tuple[]\",\"internalType\":\"structIRewardsCoordinator.StrategyAndMultiplier[]\",\"components\":[{\"name\":\"strategy\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"},{\"name\":\"multiplier\",\"type\":\"uint96\",\"internalType\":\"uint96\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20\"},{\"name\":\"amount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"startTimestamp\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"duration\",\"type\":\"uint32\",\"internalType\":\"uint32\"}]}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RewardsUpdaterSet\",\"inputs\":[{\"name\":\"oldRewardsUpdater\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newRewardsUpdater\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false}]", } // RewardsCoordinatorStorageABI is the input ABI used to generate the binding from. @@ -598,6 +614,37 @@ func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageCallerSession) CurrRe return _RewardsCoordinatorStorage.Contract.CurrRewardsCalculationEndTimestamp(&_RewardsCoordinatorStorage.CallOpts) } +// DefaultOperatorSplitBips is a free data retrieval call binding the contract method 0x63f6a798. +// +// Solidity: function defaultOperatorSplitBips() view returns(uint16) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageCaller) DefaultOperatorSplitBips(opts *bind.CallOpts) (uint16, error) { + var out []interface{} + err := _RewardsCoordinatorStorage.contract.Call(opts, &out, "defaultOperatorSplitBips") + + if err != nil { + return *new(uint16), err + } + + out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) + + return out0, err + +} + +// DefaultOperatorSplitBips is a free data retrieval call binding the contract method 0x63f6a798. +// +// Solidity: function defaultOperatorSplitBips() view returns(uint16) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageSession) DefaultOperatorSplitBips() (uint16, error) { + return _RewardsCoordinatorStorage.Contract.DefaultOperatorSplitBips(&_RewardsCoordinatorStorage.CallOpts) +} + +// DefaultOperatorSplitBips is a free data retrieval call binding the contract method 0x63f6a798. +// +// Solidity: function defaultOperatorSplitBips() view returns(uint16) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageCallerSession) DefaultOperatorSplitBips() (uint16, error) { + return _RewardsCoordinatorStorage.Contract.DefaultOperatorSplitBips(&_RewardsCoordinatorStorage.CallOpts) +} + // DelegationManager is a free data retrieval call binding the contract method 0xea4d3c9b. // // Solidity: function delegationManager() view returns(address) @@ -784,43 +831,43 @@ func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageCallerSession) GetDis return _RewardsCoordinatorStorage.Contract.GetDistributionRootsLength(&_RewardsCoordinatorStorage.CallOpts) } -// GetRootIndexFromHash is a free data retrieval call binding the contract method 0xe810ce21. +// GetOperatorAVSSplit is a free data retrieval call binding the contract method 0xe063f81f. // -// Solidity: function getRootIndexFromHash(bytes32 rootHash) view returns(uint32) -func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageCaller) GetRootIndexFromHash(opts *bind.CallOpts, rootHash [32]byte) (uint32, error) { +// Solidity: function getOperatorAVSSplit(address operator, address avs) view returns(uint16) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageCaller) GetOperatorAVSSplit(opts *bind.CallOpts, operator common.Address, avs common.Address) (uint16, error) { var out []interface{} - err := _RewardsCoordinatorStorage.contract.Call(opts, &out, "getRootIndexFromHash", rootHash) + err := _RewardsCoordinatorStorage.contract.Call(opts, &out, "getOperatorAVSSplit", operator, avs) if err != nil { - return *new(uint32), err + return *new(uint16), err } - out0 := *abi.ConvertType(out[0], new(uint32)).(*uint32) + out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) return out0, err } -// GetRootIndexFromHash is a free data retrieval call binding the contract method 0xe810ce21. +// GetOperatorAVSSplit is a free data retrieval call binding the contract method 0xe063f81f. // -// Solidity: function getRootIndexFromHash(bytes32 rootHash) view returns(uint32) -func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageSession) GetRootIndexFromHash(rootHash [32]byte) (uint32, error) { - return _RewardsCoordinatorStorage.Contract.GetRootIndexFromHash(&_RewardsCoordinatorStorage.CallOpts, rootHash) +// Solidity: function getOperatorAVSSplit(address operator, address avs) view returns(uint16) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageSession) GetOperatorAVSSplit(operator common.Address, avs common.Address) (uint16, error) { + return _RewardsCoordinatorStorage.Contract.GetOperatorAVSSplit(&_RewardsCoordinatorStorage.CallOpts, operator, avs) } -// GetRootIndexFromHash is a free data retrieval call binding the contract method 0xe810ce21. +// GetOperatorAVSSplit is a free data retrieval call binding the contract method 0xe063f81f. // -// Solidity: function getRootIndexFromHash(bytes32 rootHash) view returns(uint32) -func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageCallerSession) GetRootIndexFromHash(rootHash [32]byte) (uint32, error) { - return _RewardsCoordinatorStorage.Contract.GetRootIndexFromHash(&_RewardsCoordinatorStorage.CallOpts, rootHash) +// Solidity: function getOperatorAVSSplit(address operator, address avs) view returns(uint16) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageCallerSession) GetOperatorAVSSplit(operator common.Address, avs common.Address) (uint16, error) { + return _RewardsCoordinatorStorage.Contract.GetOperatorAVSSplit(&_RewardsCoordinatorStorage.CallOpts, operator, avs) } -// GlobalOperatorCommissionBips is a free data retrieval call binding the contract method 0x092db007. +// GetOperatorPISplit is a free data retrieval call binding the contract method 0x4b943960. // -// Solidity: function globalOperatorCommissionBips() view returns(uint16) -func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageCaller) GlobalOperatorCommissionBips(opts *bind.CallOpts) (uint16, error) { +// Solidity: function getOperatorPISplit(address operator) view returns(uint16) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageCaller) GetOperatorPISplit(opts *bind.CallOpts, operator common.Address) (uint16, error) { var out []interface{} - err := _RewardsCoordinatorStorage.contract.Call(opts, &out, "globalOperatorCommissionBips") + err := _RewardsCoordinatorStorage.contract.Call(opts, &out, "getOperatorPISplit", operator) if err != nil { return *new(uint16), err @@ -832,18 +879,49 @@ func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageCaller) GlobalOperato } -// GlobalOperatorCommissionBips is a free data retrieval call binding the contract method 0x092db007. +// GetOperatorPISplit is a free data retrieval call binding the contract method 0x4b943960. +// +// Solidity: function getOperatorPISplit(address operator) view returns(uint16) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageSession) GetOperatorPISplit(operator common.Address) (uint16, error) { + return _RewardsCoordinatorStorage.Contract.GetOperatorPISplit(&_RewardsCoordinatorStorage.CallOpts, operator) +} + +// GetOperatorPISplit is a free data retrieval call binding the contract method 0x4b943960. +// +// Solidity: function getOperatorPISplit(address operator) view returns(uint16) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageCallerSession) GetOperatorPISplit(operator common.Address) (uint16, error) { + return _RewardsCoordinatorStorage.Contract.GetOperatorPISplit(&_RewardsCoordinatorStorage.CallOpts, operator) +} + +// GetRootIndexFromHash is a free data retrieval call binding the contract method 0xe810ce21. +// +// Solidity: function getRootIndexFromHash(bytes32 rootHash) view returns(uint32) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageCaller) GetRootIndexFromHash(opts *bind.CallOpts, rootHash [32]byte) (uint32, error) { + var out []interface{} + err := _RewardsCoordinatorStorage.contract.Call(opts, &out, "getRootIndexFromHash", rootHash) + + if err != nil { + return *new(uint32), err + } + + out0 := *abi.ConvertType(out[0], new(uint32)).(*uint32) + + return out0, err + +} + +// GetRootIndexFromHash is a free data retrieval call binding the contract method 0xe810ce21. // -// Solidity: function globalOperatorCommissionBips() view returns(uint16) -func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageSession) GlobalOperatorCommissionBips() (uint16, error) { - return _RewardsCoordinatorStorage.Contract.GlobalOperatorCommissionBips(&_RewardsCoordinatorStorage.CallOpts) +// Solidity: function getRootIndexFromHash(bytes32 rootHash) view returns(uint32) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageSession) GetRootIndexFromHash(rootHash [32]byte) (uint32, error) { + return _RewardsCoordinatorStorage.Contract.GetRootIndexFromHash(&_RewardsCoordinatorStorage.CallOpts, rootHash) } -// GlobalOperatorCommissionBips is a free data retrieval call binding the contract method 0x092db007. +// GetRootIndexFromHash is a free data retrieval call binding the contract method 0xe810ce21. // -// Solidity: function globalOperatorCommissionBips() view returns(uint16) -func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageCallerSession) GlobalOperatorCommissionBips() (uint16, error) { - return _RewardsCoordinatorStorage.Contract.GlobalOperatorCommissionBips(&_RewardsCoordinatorStorage.CallOpts) +// Solidity: function getRootIndexFromHash(bytes32 rootHash) view returns(uint32) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageCallerSession) GetRootIndexFromHash(rootHash [32]byte) (uint32, error) { + return _RewardsCoordinatorStorage.Contract.GetRootIndexFromHash(&_RewardsCoordinatorStorage.CallOpts, rootHash) } // IsAVSRewardsSubmissionHash is a free data retrieval call binding the contract method 0x6d21117e. @@ -877,6 +955,37 @@ func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageCallerSession) IsAVSR return _RewardsCoordinatorStorage.Contract.IsAVSRewardsSubmissionHash(&_RewardsCoordinatorStorage.CallOpts, arg0, arg1) } +// IsOperatorDirectedAVSRewardsSubmissionHash is a free data retrieval call binding the contract method 0xed71e6a2. +// +// Solidity: function isOperatorDirectedAVSRewardsSubmissionHash(address , bytes32 ) view returns(bool) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageCaller) IsOperatorDirectedAVSRewardsSubmissionHash(opts *bind.CallOpts, arg0 common.Address, arg1 [32]byte) (bool, error) { + var out []interface{} + err := _RewardsCoordinatorStorage.contract.Call(opts, &out, "isOperatorDirectedAVSRewardsSubmissionHash", arg0, arg1) + + if err != nil { + return *new(bool), err + } + + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) + + return out0, err + +} + +// IsOperatorDirectedAVSRewardsSubmissionHash is a free data retrieval call binding the contract method 0xed71e6a2. +// +// Solidity: function isOperatorDirectedAVSRewardsSubmissionHash(address , bytes32 ) view returns(bool) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageSession) IsOperatorDirectedAVSRewardsSubmissionHash(arg0 common.Address, arg1 [32]byte) (bool, error) { + return _RewardsCoordinatorStorage.Contract.IsOperatorDirectedAVSRewardsSubmissionHash(&_RewardsCoordinatorStorage.CallOpts, arg0, arg1) +} + +// IsOperatorDirectedAVSRewardsSubmissionHash is a free data retrieval call binding the contract method 0xed71e6a2. +// +// Solidity: function isOperatorDirectedAVSRewardsSubmissionHash(address , bytes32 ) view returns(bool) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageCallerSession) IsOperatorDirectedAVSRewardsSubmissionHash(arg0 common.Address, arg1 [32]byte) (bool, error) { + return _RewardsCoordinatorStorage.Contract.IsOperatorDirectedAVSRewardsSubmissionHash(&_RewardsCoordinatorStorage.CallOpts, arg0, arg1) +} + // IsRewardsForAllSubmitter is a free data retrieval call binding the contract method 0x0018572c. // // Solidity: function isRewardsForAllSubmitter(address ) view returns(bool) @@ -970,37 +1079,6 @@ func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageCallerSession) IsRewa return _RewardsCoordinatorStorage.Contract.IsRewardsSubmissionForAllHash(&_RewardsCoordinatorStorage.CallOpts, arg0, arg1) } -// OperatorCommissionBips is a free data retrieval call binding the contract method 0x22f19a64. -// -// Solidity: function operatorCommissionBips(address operator, address avs) view returns(uint16) -func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageCaller) OperatorCommissionBips(opts *bind.CallOpts, operator common.Address, avs common.Address) (uint16, error) { - var out []interface{} - err := _RewardsCoordinatorStorage.contract.Call(opts, &out, "operatorCommissionBips", operator, avs) - - if err != nil { - return *new(uint16), err - } - - out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) - - return out0, err - -} - -// OperatorCommissionBips is a free data retrieval call binding the contract method 0x22f19a64. -// -// Solidity: function operatorCommissionBips(address operator, address avs) view returns(uint16) -func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageSession) OperatorCommissionBips(operator common.Address, avs common.Address) (uint16, error) { - return _RewardsCoordinatorStorage.Contract.OperatorCommissionBips(&_RewardsCoordinatorStorage.CallOpts, operator, avs) -} - -// OperatorCommissionBips is a free data retrieval call binding the contract method 0x22f19a64. -// -// Solidity: function operatorCommissionBips(address operator, address avs) view returns(uint16) -func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageCallerSession) OperatorCommissionBips(operator common.Address, avs common.Address) (uint16, error) { - return _RewardsCoordinatorStorage.Contract.OperatorCommissionBips(&_RewardsCoordinatorStorage.CallOpts, operator, avs) -} - // RewardsUpdater is a free data retrieval call binding the contract method 0xfbf1e2c1. // // Solidity: function rewardsUpdater() view returns(address) @@ -1115,6 +1193,27 @@ func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageTransactorSession) Cr return _RewardsCoordinatorStorage.Contract.CreateAVSRewardsSubmission(&_RewardsCoordinatorStorage.TransactOpts, rewardsSubmissions) } +// CreateOperatorDirectedAVSRewardsSubmission is a paid mutator transaction binding the contract method 0x9cb9a5fa. +// +// Solidity: function createOperatorDirectedAVSRewardsSubmission(address avs, ((address,uint96)[],address,(address,uint256)[],uint32,uint32,string)[] operatorDirectedRewardsSubmissions) returns() +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageTransactor) CreateOperatorDirectedAVSRewardsSubmission(opts *bind.TransactOpts, avs common.Address, operatorDirectedRewardsSubmissions []IRewardsCoordinatorOperatorDirectedRewardsSubmission) (*types.Transaction, error) { + return _RewardsCoordinatorStorage.contract.Transact(opts, "createOperatorDirectedAVSRewardsSubmission", avs, operatorDirectedRewardsSubmissions) +} + +// CreateOperatorDirectedAVSRewardsSubmission is a paid mutator transaction binding the contract method 0x9cb9a5fa. +// +// Solidity: function createOperatorDirectedAVSRewardsSubmission(address avs, ((address,uint96)[],address,(address,uint256)[],uint32,uint32,string)[] operatorDirectedRewardsSubmissions) returns() +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageSession) CreateOperatorDirectedAVSRewardsSubmission(avs common.Address, operatorDirectedRewardsSubmissions []IRewardsCoordinatorOperatorDirectedRewardsSubmission) (*types.Transaction, error) { + return _RewardsCoordinatorStorage.Contract.CreateOperatorDirectedAVSRewardsSubmission(&_RewardsCoordinatorStorage.TransactOpts, avs, operatorDirectedRewardsSubmissions) +} + +// CreateOperatorDirectedAVSRewardsSubmission is a paid mutator transaction binding the contract method 0x9cb9a5fa. +// +// Solidity: function createOperatorDirectedAVSRewardsSubmission(address avs, ((address,uint96)[],address,(address,uint256)[],uint32,uint32,string)[] operatorDirectedRewardsSubmissions) returns() +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageTransactorSession) CreateOperatorDirectedAVSRewardsSubmission(avs common.Address, operatorDirectedRewardsSubmissions []IRewardsCoordinatorOperatorDirectedRewardsSubmission) (*types.Transaction, error) { + return _RewardsCoordinatorStorage.Contract.CreateOperatorDirectedAVSRewardsSubmission(&_RewardsCoordinatorStorage.TransactOpts, avs, operatorDirectedRewardsSubmissions) +} + // CreateRewardsForAllEarners is a paid mutator transaction binding the contract method 0xff9f6cce. // // Solidity: function createRewardsForAllEarners(((address,uint96)[],address,uint256,uint32,uint32)[] rewardsSubmissions) returns() @@ -1199,6 +1298,27 @@ func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageTransactorSession) Pr return _RewardsCoordinatorStorage.Contract.ProcessClaim(&_RewardsCoordinatorStorage.TransactOpts, claim, recipient) } +// ProcessClaims is a paid mutator transaction binding the contract method 0x4596021c. +// +// Solidity: function processClaims((uint32,uint32,bytes,(address,bytes32),uint32[],bytes[],(address,uint256)[])[] claims, address recipient) returns() +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageTransactor) ProcessClaims(opts *bind.TransactOpts, claims []IRewardsCoordinatorRewardsMerkleClaim, recipient common.Address) (*types.Transaction, error) { + return _RewardsCoordinatorStorage.contract.Transact(opts, "processClaims", claims, recipient) +} + +// ProcessClaims is a paid mutator transaction binding the contract method 0x4596021c. +// +// Solidity: function processClaims((uint32,uint32,bytes,(address,bytes32),uint32[],bytes[],(address,uint256)[])[] claims, address recipient) returns() +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageSession) ProcessClaims(claims []IRewardsCoordinatorRewardsMerkleClaim, recipient common.Address) (*types.Transaction, error) { + return _RewardsCoordinatorStorage.Contract.ProcessClaims(&_RewardsCoordinatorStorage.TransactOpts, claims, recipient) +} + +// ProcessClaims is a paid mutator transaction binding the contract method 0x4596021c. +// +// Solidity: function processClaims((uint32,uint32,bytes,(address,bytes32),uint32[],bytes[],(address,uint256)[])[] claims, address recipient) returns() +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageTransactorSession) ProcessClaims(claims []IRewardsCoordinatorRewardsMerkleClaim, recipient common.Address) (*types.Transaction, error) { + return _RewardsCoordinatorStorage.Contract.ProcessClaims(&_RewardsCoordinatorStorage.TransactOpts, claims, recipient) +} + // SetActivationDelay is a paid mutator transaction binding the contract method 0x58baaa3e. // // Solidity: function setActivationDelay(uint32 _activationDelay) returns() @@ -1241,25 +1361,67 @@ func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageTransactorSession) Se return _RewardsCoordinatorStorage.Contract.SetClaimerFor(&_RewardsCoordinatorStorage.TransactOpts, claimer) } -// SetGlobalOperatorCommission is a paid mutator transaction binding the contract method 0xe221b245. +// SetDefaultOperatorSplit is a paid mutator transaction binding the contract method 0xa50a1d9c. +// +// Solidity: function setDefaultOperatorSplit(uint16 split) returns() +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageTransactor) SetDefaultOperatorSplit(opts *bind.TransactOpts, split uint16) (*types.Transaction, error) { + return _RewardsCoordinatorStorage.contract.Transact(opts, "setDefaultOperatorSplit", split) +} + +// SetDefaultOperatorSplit is a paid mutator transaction binding the contract method 0xa50a1d9c. +// +// Solidity: function setDefaultOperatorSplit(uint16 split) returns() +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageSession) SetDefaultOperatorSplit(split uint16) (*types.Transaction, error) { + return _RewardsCoordinatorStorage.Contract.SetDefaultOperatorSplit(&_RewardsCoordinatorStorage.TransactOpts, split) +} + +// SetDefaultOperatorSplit is a paid mutator transaction binding the contract method 0xa50a1d9c. +// +// Solidity: function setDefaultOperatorSplit(uint16 split) returns() +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageTransactorSession) SetDefaultOperatorSplit(split uint16) (*types.Transaction, error) { + return _RewardsCoordinatorStorage.Contract.SetDefaultOperatorSplit(&_RewardsCoordinatorStorage.TransactOpts, split) +} + +// SetOperatorAVSSplit is a paid mutator transaction binding the contract method 0xdcbb03b3. +// +// Solidity: function setOperatorAVSSplit(address operator, address avs, uint16 split) returns() +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageTransactor) SetOperatorAVSSplit(opts *bind.TransactOpts, operator common.Address, avs common.Address, split uint16) (*types.Transaction, error) { + return _RewardsCoordinatorStorage.contract.Transact(opts, "setOperatorAVSSplit", operator, avs, split) +} + +// SetOperatorAVSSplit is a paid mutator transaction binding the contract method 0xdcbb03b3. // -// Solidity: function setGlobalOperatorCommission(uint16 _globalCommissionBips) returns() -func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageTransactor) SetGlobalOperatorCommission(opts *bind.TransactOpts, _globalCommissionBips uint16) (*types.Transaction, error) { - return _RewardsCoordinatorStorage.contract.Transact(opts, "setGlobalOperatorCommission", _globalCommissionBips) +// Solidity: function setOperatorAVSSplit(address operator, address avs, uint16 split) returns() +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageSession) SetOperatorAVSSplit(operator common.Address, avs common.Address, split uint16) (*types.Transaction, error) { + return _RewardsCoordinatorStorage.Contract.SetOperatorAVSSplit(&_RewardsCoordinatorStorage.TransactOpts, operator, avs, split) } -// SetGlobalOperatorCommission is a paid mutator transaction binding the contract method 0xe221b245. +// SetOperatorAVSSplit is a paid mutator transaction binding the contract method 0xdcbb03b3. // -// Solidity: function setGlobalOperatorCommission(uint16 _globalCommissionBips) returns() -func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageSession) SetGlobalOperatorCommission(_globalCommissionBips uint16) (*types.Transaction, error) { - return _RewardsCoordinatorStorage.Contract.SetGlobalOperatorCommission(&_RewardsCoordinatorStorage.TransactOpts, _globalCommissionBips) +// Solidity: function setOperatorAVSSplit(address operator, address avs, uint16 split) returns() +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageTransactorSession) SetOperatorAVSSplit(operator common.Address, avs common.Address, split uint16) (*types.Transaction, error) { + return _RewardsCoordinatorStorage.Contract.SetOperatorAVSSplit(&_RewardsCoordinatorStorage.TransactOpts, operator, avs, split) } -// SetGlobalOperatorCommission is a paid mutator transaction binding the contract method 0xe221b245. +// SetOperatorPISplit is a paid mutator transaction binding the contract method 0xb3dbb0e0. // -// Solidity: function setGlobalOperatorCommission(uint16 _globalCommissionBips) returns() -func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageTransactorSession) SetGlobalOperatorCommission(_globalCommissionBips uint16) (*types.Transaction, error) { - return _RewardsCoordinatorStorage.Contract.SetGlobalOperatorCommission(&_RewardsCoordinatorStorage.TransactOpts, _globalCommissionBips) +// Solidity: function setOperatorPISplit(address operator, uint16 split) returns() +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageTransactor) SetOperatorPISplit(opts *bind.TransactOpts, operator common.Address, split uint16) (*types.Transaction, error) { + return _RewardsCoordinatorStorage.contract.Transact(opts, "setOperatorPISplit", operator, split) +} + +// SetOperatorPISplit is a paid mutator transaction binding the contract method 0xb3dbb0e0. +// +// Solidity: function setOperatorPISplit(address operator, uint16 split) returns() +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageSession) SetOperatorPISplit(operator common.Address, split uint16) (*types.Transaction, error) { + return _RewardsCoordinatorStorage.Contract.SetOperatorPISplit(&_RewardsCoordinatorStorage.TransactOpts, operator, split) +} + +// SetOperatorPISplit is a paid mutator transaction binding the contract method 0xb3dbb0e0. +// +// Solidity: function setOperatorPISplit(address operator, uint16 split) returns() +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageTransactorSession) SetOperatorPISplit(operator common.Address, split uint16) (*types.Transaction, error) { + return _RewardsCoordinatorStorage.Contract.SetOperatorPISplit(&_RewardsCoordinatorStorage.TransactOpts, operator, split) } // SetRewardsForAllSubmitter is a paid mutator transaction binding the contract method 0x0eb38345. @@ -1785,6 +1947,141 @@ func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageFilterer) ParseClaime return event, nil } +// RewardsCoordinatorStorageDefaultOperatorSplitBipsSetIterator is returned from FilterDefaultOperatorSplitBipsSet and is used to iterate over the raw logs and unpacked data for DefaultOperatorSplitBipsSet events raised by the RewardsCoordinatorStorage contract. +type RewardsCoordinatorStorageDefaultOperatorSplitBipsSetIterator struct { + Event *RewardsCoordinatorStorageDefaultOperatorSplitBipsSet // Event containing the contract specifics and raw log + + contract *bind.BoundContract // Generic contract to use for unpacking event data + event string // Event name to use for unpacking event data + + logs chan types.Log // Log channel receiving the found contract events + sub ethereum.Subscription // Subscription for errors, completion and termination + done bool // Whether the subscription completed delivering logs + fail error // Occurred error to stop iteration +} + +// Next advances the iterator to the subsequent event, returning whether there +// are any more events found. In case of a retrieval or parsing error, false is +// returned and Error() can be queried for the exact failure. +func (it *RewardsCoordinatorStorageDefaultOperatorSplitBipsSetIterator) Next() bool { + // If the iterator failed, stop iterating + if it.fail != nil { + return false + } + // If the iterator completed, deliver directly whatever's available + if it.done { + select { + case log := <-it.logs: + it.Event = new(RewardsCoordinatorStorageDefaultOperatorSplitBipsSet) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + // Iterator still in progress, wait for either a data or an error event + select { + case log := <-it.logs: + it.Event = new(RewardsCoordinatorStorageDefaultOperatorSplitBipsSet) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +// Error returns any retrieval or parsing error occurred during filtering. +func (it *RewardsCoordinatorStorageDefaultOperatorSplitBipsSetIterator) Error() error { + return it.fail +} + +// Close terminates the iteration process, releasing any pending underlying +// resources. +func (it *RewardsCoordinatorStorageDefaultOperatorSplitBipsSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +// RewardsCoordinatorStorageDefaultOperatorSplitBipsSet represents a DefaultOperatorSplitBipsSet event raised by the RewardsCoordinatorStorage contract. +type RewardsCoordinatorStorageDefaultOperatorSplitBipsSet struct { + OldDefaultOperatorSplitBips uint16 + NewDefaultOperatorSplitBips uint16 + Raw types.Log // Blockchain specific contextual infos +} + +// FilterDefaultOperatorSplitBipsSet is a free log retrieval operation binding the contract event 0xe6cd4edfdcc1f6d130ab35f73d72378f3a642944fb4ee5bd84b7807a81ea1c4e. +// +// Solidity: event DefaultOperatorSplitBipsSet(uint16 oldDefaultOperatorSplitBips, uint16 newDefaultOperatorSplitBips) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageFilterer) FilterDefaultOperatorSplitBipsSet(opts *bind.FilterOpts) (*RewardsCoordinatorStorageDefaultOperatorSplitBipsSetIterator, error) { + + logs, sub, err := _RewardsCoordinatorStorage.contract.FilterLogs(opts, "DefaultOperatorSplitBipsSet") + if err != nil { + return nil, err + } + return &RewardsCoordinatorStorageDefaultOperatorSplitBipsSetIterator{contract: _RewardsCoordinatorStorage.contract, event: "DefaultOperatorSplitBipsSet", logs: logs, sub: sub}, nil +} + +// WatchDefaultOperatorSplitBipsSet is a free log subscription operation binding the contract event 0xe6cd4edfdcc1f6d130ab35f73d72378f3a642944fb4ee5bd84b7807a81ea1c4e. +// +// Solidity: event DefaultOperatorSplitBipsSet(uint16 oldDefaultOperatorSplitBips, uint16 newDefaultOperatorSplitBips) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageFilterer) WatchDefaultOperatorSplitBipsSet(opts *bind.WatchOpts, sink chan<- *RewardsCoordinatorStorageDefaultOperatorSplitBipsSet) (event.Subscription, error) { + + logs, sub, err := _RewardsCoordinatorStorage.contract.WatchLogs(opts, "DefaultOperatorSplitBipsSet") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + // New log arrived, parse the event and forward to the user + event := new(RewardsCoordinatorStorageDefaultOperatorSplitBipsSet) + if err := _RewardsCoordinatorStorage.contract.UnpackLog(event, "DefaultOperatorSplitBipsSet", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +// ParseDefaultOperatorSplitBipsSet is a log parse operation binding the contract event 0xe6cd4edfdcc1f6d130ab35f73d72378f3a642944fb4ee5bd84b7807a81ea1c4e. +// +// Solidity: event DefaultOperatorSplitBipsSet(uint16 oldDefaultOperatorSplitBips, uint16 newDefaultOperatorSplitBips) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageFilterer) ParseDefaultOperatorSplitBipsSet(log types.Log) (*RewardsCoordinatorStorageDefaultOperatorSplitBipsSet, error) { + event := new(RewardsCoordinatorStorageDefaultOperatorSplitBipsSet) + if err := _RewardsCoordinatorStorage.contract.UnpackLog(event, "DefaultOperatorSplitBipsSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + // RewardsCoordinatorStorageDistributionRootDisabledIterator is returned from FilterDistributionRootDisabled and is used to iterate over the raw logs and unpacked data for DistributionRootDisabled events raised by the RewardsCoordinatorStorage contract. type RewardsCoordinatorStorageDistributionRootDisabledIterator struct { Event *RewardsCoordinatorStorageDistributionRootDisabled // Event containing the contract specifics and raw log @@ -2092,9 +2389,9 @@ func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageFilterer) ParseDistri return event, nil } -// RewardsCoordinatorStorageGlobalCommissionBipsSetIterator is returned from FilterGlobalCommissionBipsSet and is used to iterate over the raw logs and unpacked data for GlobalCommissionBipsSet events raised by the RewardsCoordinatorStorage contract. -type RewardsCoordinatorStorageGlobalCommissionBipsSetIterator struct { - Event *RewardsCoordinatorStorageGlobalCommissionBipsSet // Event containing the contract specifics and raw log +// RewardsCoordinatorStorageOperatorAVSSplitBipsSetIterator is returned from FilterOperatorAVSSplitBipsSet and is used to iterate over the raw logs and unpacked data for OperatorAVSSplitBipsSet events raised by the RewardsCoordinatorStorage contract. +type RewardsCoordinatorStorageOperatorAVSSplitBipsSetIterator struct { + Event *RewardsCoordinatorStorageOperatorAVSSplitBipsSet // Event containing the contract specifics and raw log contract *bind.BoundContract // Generic contract to use for unpacking event data event string // Event name to use for unpacking event data @@ -2108,7 +2405,7 @@ type RewardsCoordinatorStorageGlobalCommissionBipsSetIterator struct { // Next advances the iterator to the subsequent event, returning whether there // are any more events found. In case of a retrieval or parsing error, false is // returned and Error() can be queried for the exact failure. -func (it *RewardsCoordinatorStorageGlobalCommissionBipsSetIterator) Next() bool { +func (it *RewardsCoordinatorStorageOperatorAVSSplitBipsSetIterator) Next() bool { // If the iterator failed, stop iterating if it.fail != nil { return false @@ -2117,7 +2414,7 @@ func (it *RewardsCoordinatorStorageGlobalCommissionBipsSetIterator) Next() bool if it.done { select { case log := <-it.logs: - it.Event = new(RewardsCoordinatorStorageGlobalCommissionBipsSet) + it.Event = new(RewardsCoordinatorStorageOperatorAVSSplitBipsSet) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2132,7 +2429,7 @@ func (it *RewardsCoordinatorStorageGlobalCommissionBipsSetIterator) Next() bool // Iterator still in progress, wait for either a data or an error event select { case log := <-it.logs: - it.Event = new(RewardsCoordinatorStorageGlobalCommissionBipsSet) + it.Event = new(RewardsCoordinatorStorageOperatorAVSSplitBipsSet) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2148,42 +2445,392 @@ func (it *RewardsCoordinatorStorageGlobalCommissionBipsSetIterator) Next() bool } // Error returns any retrieval or parsing error occurred during filtering. -func (it *RewardsCoordinatorStorageGlobalCommissionBipsSetIterator) Error() error { +func (it *RewardsCoordinatorStorageOperatorAVSSplitBipsSetIterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. -func (it *RewardsCoordinatorStorageGlobalCommissionBipsSetIterator) Close() error { +func (it *RewardsCoordinatorStorageOperatorAVSSplitBipsSetIterator) Close() error { it.sub.Unsubscribe() return nil } -// RewardsCoordinatorStorageGlobalCommissionBipsSet represents a GlobalCommissionBipsSet event raised by the RewardsCoordinatorStorage contract. -type RewardsCoordinatorStorageGlobalCommissionBipsSet struct { - OldGlobalCommissionBips uint16 - NewGlobalCommissionBips uint16 +// RewardsCoordinatorStorageOperatorAVSSplitBipsSet represents a OperatorAVSSplitBipsSet event raised by the RewardsCoordinatorStorage contract. +type RewardsCoordinatorStorageOperatorAVSSplitBipsSet struct { + Caller common.Address + Operator common.Address + Avs common.Address + ActivatedAt uint32 + OldOperatorAVSSplitBips uint16 + NewOperatorAVSSplitBips uint16 Raw types.Log // Blockchain specific contextual infos } -// FilterGlobalCommissionBipsSet is a free log retrieval operation binding the contract event 0x8cdc428b0431b82d1619763f443a48197db344ba96905f3949643acd1c863a06. +// FilterOperatorAVSSplitBipsSet is a free log retrieval operation binding the contract event 0x48e198b6ae357e529204ee53a8e514c470ff77d9cc8e4f7207f8b5d490ae6934. +// +// Solidity: event OperatorAVSSplitBipsSet(address indexed caller, address indexed operator, address indexed avs, uint32 activatedAt, uint16 oldOperatorAVSSplitBips, uint16 newOperatorAVSSplitBips) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageFilterer) FilterOperatorAVSSplitBipsSet(opts *bind.FilterOpts, caller []common.Address, operator []common.Address, avs []common.Address) (*RewardsCoordinatorStorageOperatorAVSSplitBipsSetIterator, error) { + + var callerRule []interface{} + for _, callerItem := range caller { + callerRule = append(callerRule, callerItem) + } + var operatorRule []interface{} + for _, operatorItem := range operator { + operatorRule = append(operatorRule, operatorItem) + } + var avsRule []interface{} + for _, avsItem := range avs { + avsRule = append(avsRule, avsItem) + } + + logs, sub, err := _RewardsCoordinatorStorage.contract.FilterLogs(opts, "OperatorAVSSplitBipsSet", callerRule, operatorRule, avsRule) + if err != nil { + return nil, err + } + return &RewardsCoordinatorStorageOperatorAVSSplitBipsSetIterator{contract: _RewardsCoordinatorStorage.contract, event: "OperatorAVSSplitBipsSet", logs: logs, sub: sub}, nil +} + +// WatchOperatorAVSSplitBipsSet is a free log subscription operation binding the contract event 0x48e198b6ae357e529204ee53a8e514c470ff77d9cc8e4f7207f8b5d490ae6934. +// +// Solidity: event OperatorAVSSplitBipsSet(address indexed caller, address indexed operator, address indexed avs, uint32 activatedAt, uint16 oldOperatorAVSSplitBips, uint16 newOperatorAVSSplitBips) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageFilterer) WatchOperatorAVSSplitBipsSet(opts *bind.WatchOpts, sink chan<- *RewardsCoordinatorStorageOperatorAVSSplitBipsSet, caller []common.Address, operator []common.Address, avs []common.Address) (event.Subscription, error) { + + var callerRule []interface{} + for _, callerItem := range caller { + callerRule = append(callerRule, callerItem) + } + var operatorRule []interface{} + for _, operatorItem := range operator { + operatorRule = append(operatorRule, operatorItem) + } + var avsRule []interface{} + for _, avsItem := range avs { + avsRule = append(avsRule, avsItem) + } + + logs, sub, err := _RewardsCoordinatorStorage.contract.WatchLogs(opts, "OperatorAVSSplitBipsSet", callerRule, operatorRule, avsRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + // New log arrived, parse the event and forward to the user + event := new(RewardsCoordinatorStorageOperatorAVSSplitBipsSet) + if err := _RewardsCoordinatorStorage.contract.UnpackLog(event, "OperatorAVSSplitBipsSet", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +// ParseOperatorAVSSplitBipsSet is a log parse operation binding the contract event 0x48e198b6ae357e529204ee53a8e514c470ff77d9cc8e4f7207f8b5d490ae6934. +// +// Solidity: event OperatorAVSSplitBipsSet(address indexed caller, address indexed operator, address indexed avs, uint32 activatedAt, uint16 oldOperatorAVSSplitBips, uint16 newOperatorAVSSplitBips) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageFilterer) ParseOperatorAVSSplitBipsSet(log types.Log) (*RewardsCoordinatorStorageOperatorAVSSplitBipsSet, error) { + event := new(RewardsCoordinatorStorageOperatorAVSSplitBipsSet) + if err := _RewardsCoordinatorStorage.contract.UnpackLog(event, "OperatorAVSSplitBipsSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +// RewardsCoordinatorStorageOperatorDirectedAVSRewardsSubmissionCreatedIterator is returned from FilterOperatorDirectedAVSRewardsSubmissionCreated and is used to iterate over the raw logs and unpacked data for OperatorDirectedAVSRewardsSubmissionCreated events raised by the RewardsCoordinatorStorage contract. +type RewardsCoordinatorStorageOperatorDirectedAVSRewardsSubmissionCreatedIterator struct { + Event *RewardsCoordinatorStorageOperatorDirectedAVSRewardsSubmissionCreated // Event containing the contract specifics and raw log + + contract *bind.BoundContract // Generic contract to use for unpacking event data + event string // Event name to use for unpacking event data + + logs chan types.Log // Log channel receiving the found contract events + sub ethereum.Subscription // Subscription for errors, completion and termination + done bool // Whether the subscription completed delivering logs + fail error // Occurred error to stop iteration +} + +// Next advances the iterator to the subsequent event, returning whether there +// are any more events found. In case of a retrieval or parsing error, false is +// returned and Error() can be queried for the exact failure. +func (it *RewardsCoordinatorStorageOperatorDirectedAVSRewardsSubmissionCreatedIterator) Next() bool { + // If the iterator failed, stop iterating + if it.fail != nil { + return false + } + // If the iterator completed, deliver directly whatever's available + if it.done { + select { + case log := <-it.logs: + it.Event = new(RewardsCoordinatorStorageOperatorDirectedAVSRewardsSubmissionCreated) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + // Iterator still in progress, wait for either a data or an error event + select { + case log := <-it.logs: + it.Event = new(RewardsCoordinatorStorageOperatorDirectedAVSRewardsSubmissionCreated) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +// Error returns any retrieval or parsing error occurred during filtering. +func (it *RewardsCoordinatorStorageOperatorDirectedAVSRewardsSubmissionCreatedIterator) Error() error { + return it.fail +} + +// Close terminates the iteration process, releasing any pending underlying +// resources. +func (it *RewardsCoordinatorStorageOperatorDirectedAVSRewardsSubmissionCreatedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +// RewardsCoordinatorStorageOperatorDirectedAVSRewardsSubmissionCreated represents a OperatorDirectedAVSRewardsSubmissionCreated event raised by the RewardsCoordinatorStorage contract. +type RewardsCoordinatorStorageOperatorDirectedAVSRewardsSubmissionCreated struct { + Caller common.Address + Avs common.Address + OperatorDirectedRewardsSubmissionHash [32]byte + SubmissionNonce *big.Int + OperatorDirectedRewardsSubmission IRewardsCoordinatorOperatorDirectedRewardsSubmission + Raw types.Log // Blockchain specific contextual infos +} + +// FilterOperatorDirectedAVSRewardsSubmissionCreated is a free log retrieval operation binding the contract event 0xfc8888bffd711da60bc5092b33f677d81896fe80ecc677b84cfab8184462b6e0. +// +// Solidity: event OperatorDirectedAVSRewardsSubmissionCreated(address indexed caller, address indexed avs, bytes32 indexed operatorDirectedRewardsSubmissionHash, uint256 submissionNonce, ((address,uint96)[],address,(address,uint256)[],uint32,uint32,string) operatorDirectedRewardsSubmission) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageFilterer) FilterOperatorDirectedAVSRewardsSubmissionCreated(opts *bind.FilterOpts, caller []common.Address, avs []common.Address, operatorDirectedRewardsSubmissionHash [][32]byte) (*RewardsCoordinatorStorageOperatorDirectedAVSRewardsSubmissionCreatedIterator, error) { + + var callerRule []interface{} + for _, callerItem := range caller { + callerRule = append(callerRule, callerItem) + } + var avsRule []interface{} + for _, avsItem := range avs { + avsRule = append(avsRule, avsItem) + } + var operatorDirectedRewardsSubmissionHashRule []interface{} + for _, operatorDirectedRewardsSubmissionHashItem := range operatorDirectedRewardsSubmissionHash { + operatorDirectedRewardsSubmissionHashRule = append(operatorDirectedRewardsSubmissionHashRule, operatorDirectedRewardsSubmissionHashItem) + } + + logs, sub, err := _RewardsCoordinatorStorage.contract.FilterLogs(opts, "OperatorDirectedAVSRewardsSubmissionCreated", callerRule, avsRule, operatorDirectedRewardsSubmissionHashRule) + if err != nil { + return nil, err + } + return &RewardsCoordinatorStorageOperatorDirectedAVSRewardsSubmissionCreatedIterator{contract: _RewardsCoordinatorStorage.contract, event: "OperatorDirectedAVSRewardsSubmissionCreated", logs: logs, sub: sub}, nil +} + +// WatchOperatorDirectedAVSRewardsSubmissionCreated is a free log subscription operation binding the contract event 0xfc8888bffd711da60bc5092b33f677d81896fe80ecc677b84cfab8184462b6e0. // -// Solidity: event GlobalCommissionBipsSet(uint16 oldGlobalCommissionBips, uint16 newGlobalCommissionBips) -func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageFilterer) FilterGlobalCommissionBipsSet(opts *bind.FilterOpts) (*RewardsCoordinatorStorageGlobalCommissionBipsSetIterator, error) { +// Solidity: event OperatorDirectedAVSRewardsSubmissionCreated(address indexed caller, address indexed avs, bytes32 indexed operatorDirectedRewardsSubmissionHash, uint256 submissionNonce, ((address,uint96)[],address,(address,uint256)[],uint32,uint32,string) operatorDirectedRewardsSubmission) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageFilterer) WatchOperatorDirectedAVSRewardsSubmissionCreated(opts *bind.WatchOpts, sink chan<- *RewardsCoordinatorStorageOperatorDirectedAVSRewardsSubmissionCreated, caller []common.Address, avs []common.Address, operatorDirectedRewardsSubmissionHash [][32]byte) (event.Subscription, error) { + + var callerRule []interface{} + for _, callerItem := range caller { + callerRule = append(callerRule, callerItem) + } + var avsRule []interface{} + for _, avsItem := range avs { + avsRule = append(avsRule, avsItem) + } + var operatorDirectedRewardsSubmissionHashRule []interface{} + for _, operatorDirectedRewardsSubmissionHashItem := range operatorDirectedRewardsSubmissionHash { + operatorDirectedRewardsSubmissionHashRule = append(operatorDirectedRewardsSubmissionHashRule, operatorDirectedRewardsSubmissionHashItem) + } - logs, sub, err := _RewardsCoordinatorStorage.contract.FilterLogs(opts, "GlobalCommissionBipsSet") + logs, sub, err := _RewardsCoordinatorStorage.contract.WatchLogs(opts, "OperatorDirectedAVSRewardsSubmissionCreated", callerRule, avsRule, operatorDirectedRewardsSubmissionHashRule) if err != nil { return nil, err } - return &RewardsCoordinatorStorageGlobalCommissionBipsSetIterator{contract: _RewardsCoordinatorStorage.contract, event: "GlobalCommissionBipsSet", logs: logs, sub: sub}, nil + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + // New log arrived, parse the event and forward to the user + event := new(RewardsCoordinatorStorageOperatorDirectedAVSRewardsSubmissionCreated) + if err := _RewardsCoordinatorStorage.contract.UnpackLog(event, "OperatorDirectedAVSRewardsSubmissionCreated", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil } -// WatchGlobalCommissionBipsSet is a free log subscription operation binding the contract event 0x8cdc428b0431b82d1619763f443a48197db344ba96905f3949643acd1c863a06. +// ParseOperatorDirectedAVSRewardsSubmissionCreated is a log parse operation binding the contract event 0xfc8888bffd711da60bc5092b33f677d81896fe80ecc677b84cfab8184462b6e0. // -// Solidity: event GlobalCommissionBipsSet(uint16 oldGlobalCommissionBips, uint16 newGlobalCommissionBips) -func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageFilterer) WatchGlobalCommissionBipsSet(opts *bind.WatchOpts, sink chan<- *RewardsCoordinatorStorageGlobalCommissionBipsSet) (event.Subscription, error) { +// Solidity: event OperatorDirectedAVSRewardsSubmissionCreated(address indexed caller, address indexed avs, bytes32 indexed operatorDirectedRewardsSubmissionHash, uint256 submissionNonce, ((address,uint96)[],address,(address,uint256)[],uint32,uint32,string) operatorDirectedRewardsSubmission) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageFilterer) ParseOperatorDirectedAVSRewardsSubmissionCreated(log types.Log) (*RewardsCoordinatorStorageOperatorDirectedAVSRewardsSubmissionCreated, error) { + event := new(RewardsCoordinatorStorageOperatorDirectedAVSRewardsSubmissionCreated) + if err := _RewardsCoordinatorStorage.contract.UnpackLog(event, "OperatorDirectedAVSRewardsSubmissionCreated", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +// RewardsCoordinatorStorageOperatorPISplitBipsSetIterator is returned from FilterOperatorPISplitBipsSet and is used to iterate over the raw logs and unpacked data for OperatorPISplitBipsSet events raised by the RewardsCoordinatorStorage contract. +type RewardsCoordinatorStorageOperatorPISplitBipsSetIterator struct { + Event *RewardsCoordinatorStorageOperatorPISplitBipsSet // Event containing the contract specifics and raw log + + contract *bind.BoundContract // Generic contract to use for unpacking event data + event string // Event name to use for unpacking event data + + logs chan types.Log // Log channel receiving the found contract events + sub ethereum.Subscription // Subscription for errors, completion and termination + done bool // Whether the subscription completed delivering logs + fail error // Occurred error to stop iteration +} + +// Next advances the iterator to the subsequent event, returning whether there +// are any more events found. In case of a retrieval or parsing error, false is +// returned and Error() can be queried for the exact failure. +func (it *RewardsCoordinatorStorageOperatorPISplitBipsSetIterator) Next() bool { + // If the iterator failed, stop iterating + if it.fail != nil { + return false + } + // If the iterator completed, deliver directly whatever's available + if it.done { + select { + case log := <-it.logs: + it.Event = new(RewardsCoordinatorStorageOperatorPISplitBipsSet) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + // Iterator still in progress, wait for either a data or an error event + select { + case log := <-it.logs: + it.Event = new(RewardsCoordinatorStorageOperatorPISplitBipsSet) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +// Error returns any retrieval or parsing error occurred during filtering. +func (it *RewardsCoordinatorStorageOperatorPISplitBipsSetIterator) Error() error { + return it.fail +} + +// Close terminates the iteration process, releasing any pending underlying +// resources. +func (it *RewardsCoordinatorStorageOperatorPISplitBipsSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +// RewardsCoordinatorStorageOperatorPISplitBipsSet represents a OperatorPISplitBipsSet event raised by the RewardsCoordinatorStorage contract. +type RewardsCoordinatorStorageOperatorPISplitBipsSet struct { + Caller common.Address + Operator common.Address + ActivatedAt uint32 + OldOperatorPISplitBips uint16 + NewOperatorPISplitBips uint16 + Raw types.Log // Blockchain specific contextual infos +} + +// FilterOperatorPISplitBipsSet is a free log retrieval operation binding the contract event 0xd1e028bd664486a46ad26040e999cd2d22e1e9a094ee6afe19fcf64678f16f74. +// +// Solidity: event OperatorPISplitBipsSet(address indexed caller, address indexed operator, uint32 activatedAt, uint16 oldOperatorPISplitBips, uint16 newOperatorPISplitBips) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageFilterer) FilterOperatorPISplitBipsSet(opts *bind.FilterOpts, caller []common.Address, operator []common.Address) (*RewardsCoordinatorStorageOperatorPISplitBipsSetIterator, error) { + + var callerRule []interface{} + for _, callerItem := range caller { + callerRule = append(callerRule, callerItem) + } + var operatorRule []interface{} + for _, operatorItem := range operator { + operatorRule = append(operatorRule, operatorItem) + } + + logs, sub, err := _RewardsCoordinatorStorage.contract.FilterLogs(opts, "OperatorPISplitBipsSet", callerRule, operatorRule) + if err != nil { + return nil, err + } + return &RewardsCoordinatorStorageOperatorPISplitBipsSetIterator{contract: _RewardsCoordinatorStorage.contract, event: "OperatorPISplitBipsSet", logs: logs, sub: sub}, nil +} + +// WatchOperatorPISplitBipsSet is a free log subscription operation binding the contract event 0xd1e028bd664486a46ad26040e999cd2d22e1e9a094ee6afe19fcf64678f16f74. +// +// Solidity: event OperatorPISplitBipsSet(address indexed caller, address indexed operator, uint32 activatedAt, uint16 oldOperatorPISplitBips, uint16 newOperatorPISplitBips) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageFilterer) WatchOperatorPISplitBipsSet(opts *bind.WatchOpts, sink chan<- *RewardsCoordinatorStorageOperatorPISplitBipsSet, caller []common.Address, operator []common.Address) (event.Subscription, error) { + + var callerRule []interface{} + for _, callerItem := range caller { + callerRule = append(callerRule, callerItem) + } + var operatorRule []interface{} + for _, operatorItem := range operator { + operatorRule = append(operatorRule, operatorItem) + } - logs, sub, err := _RewardsCoordinatorStorage.contract.WatchLogs(opts, "GlobalCommissionBipsSet") + logs, sub, err := _RewardsCoordinatorStorage.contract.WatchLogs(opts, "OperatorPISplitBipsSet", callerRule, operatorRule) if err != nil { return nil, err } @@ -2193,8 +2840,8 @@ func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageFilterer) WatchGlobal select { case log := <-logs: // New log arrived, parse the event and forward to the user - event := new(RewardsCoordinatorStorageGlobalCommissionBipsSet) - if err := _RewardsCoordinatorStorage.contract.UnpackLog(event, "GlobalCommissionBipsSet", log); err != nil { + event := new(RewardsCoordinatorStorageOperatorPISplitBipsSet) + if err := _RewardsCoordinatorStorage.contract.UnpackLog(event, "OperatorPISplitBipsSet", log); err != nil { return err } event.Raw = log @@ -2215,12 +2862,12 @@ func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageFilterer) WatchGlobal }), nil } -// ParseGlobalCommissionBipsSet is a log parse operation binding the contract event 0x8cdc428b0431b82d1619763f443a48197db344ba96905f3949643acd1c863a06. +// ParseOperatorPISplitBipsSet is a log parse operation binding the contract event 0xd1e028bd664486a46ad26040e999cd2d22e1e9a094ee6afe19fcf64678f16f74. // -// Solidity: event GlobalCommissionBipsSet(uint16 oldGlobalCommissionBips, uint16 newGlobalCommissionBips) -func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageFilterer) ParseGlobalCommissionBipsSet(log types.Log) (*RewardsCoordinatorStorageGlobalCommissionBipsSet, error) { - event := new(RewardsCoordinatorStorageGlobalCommissionBipsSet) - if err := _RewardsCoordinatorStorage.contract.UnpackLog(event, "GlobalCommissionBipsSet", log); err != nil { +// Solidity: event OperatorPISplitBipsSet(address indexed caller, address indexed operator, uint32 activatedAt, uint16 oldOperatorPISplitBips, uint16 newOperatorPISplitBips) +func (_RewardsCoordinatorStorage *RewardsCoordinatorStorageFilterer) ParseOperatorPISplitBipsSet(log types.Log) (*RewardsCoordinatorStorageOperatorPISplitBipsSet, error) { + event := new(RewardsCoordinatorStorageOperatorPISplitBipsSet) + if err := _RewardsCoordinatorStorage.contract.UnpackLog(event, "OperatorPISplitBipsSet", log); err != nil { return nil, err } event.Raw = log diff --git a/script/configs/local/deploy_from_scratch.anvil.config.json b/script/configs/local/deploy_from_scratch.anvil.config.json index 81c6ef2c5..a665924b0 100644 --- a/script/configs/local/deploy_from_scratch.anvil.config.json +++ b/script/configs/local/deploy_from_scratch.anvil.config.json @@ -47,9 +47,9 @@ "rewards_updater_address": "0x18a0f92Ad9645385E8A8f3db7d0f6CF7aBBb0aD4", "activation_delay": 7200, "calculation_interval_seconds": 604800, - "global_operator_commission_bips": 1000, + "default_operator_split_bips": 1000, "OPERATOR_SET_GENESIS_REWARDS_TIMESTAMP": 1720656000, "OPERATOR_SET_MAX_RETROACTIVE_LENGTH": 2592000 }, "ethPOSDepositAddress": "0x00000000219ab540356cBB839Cbe05303d7705Fa" - } \ No newline at end of file + } diff --git a/script/deploy/local/Deploy_From_Scratch.s.sol b/script/deploy/local/Deploy_From_Scratch.s.sol index 365773c49..24cd2b85f 100644 --- a/script/deploy/local/Deploy_From_Scratch.s.sol +++ b/script/deploy/local/Deploy_From_Scratch.s.sol @@ -94,7 +94,7 @@ contract DeployFromScratch is Script, Test { address REWARDS_COORDINATOR_UPDATER; uint32 REWARDS_COORDINATOR_ACTIVATION_DELAY; uint32 REWARDS_COORDINATOR_CALCULATION_INTERVAL_SECONDS; - uint32 REWARDS_COORDINATOR_GLOBAL_OPERATOR_COMMISSION_BIPS; + uint32 REWARDS_COORDINATOR_DEFAULT_OPERATOR_SPLIT_BIPS; uint32 REWARDS_COORDINATOR_OPERATOR_SET_GENESIS_REWARDS_TIMESTAMP; uint32 REWARDS_COORDINATOR_OPERATOR_SET_MAX_RETROACTIVE_LENGTH; @@ -124,17 +124,27 @@ contract DeployFromScratch is Script, Test { REWARDS_COORDINATOR_CALCULATION_INTERVAL_SECONDS = uint32( stdJson.readUint(config_data, ".rewardsCoordinator.CALCULATION_INTERVAL_SECONDS") ); - REWARDS_COORDINATOR_MAX_REWARDS_DURATION = uint32(stdJson.readUint(config_data, ".rewardsCoordinator.MAX_REWARDS_DURATION")); - REWARDS_COORDINATOR_MAX_RETROACTIVE_LENGTH = uint32(stdJson.readUint(config_data, ".rewardsCoordinator.MAX_RETROACTIVE_LENGTH")); - REWARDS_COORDINATOR_MAX_FUTURE_LENGTH = uint32(stdJson.readUint(config_data, ".rewardsCoordinator.MAX_FUTURE_LENGTH")); - REWARDS_COORDINATOR_GENESIS_REWARDS_TIMESTAMP = uint32(stdJson.readUint(config_data, ".rewardsCoordinator.GENESIS_REWARDS_TIMESTAMP")); + REWARDS_COORDINATOR_MAX_REWARDS_DURATION = uint32( + stdJson.readUint(config_data, ".rewardsCoordinator.MAX_REWARDS_DURATION") + ); + REWARDS_COORDINATOR_MAX_RETROACTIVE_LENGTH = uint32( + stdJson.readUint(config_data, ".rewardsCoordinator.MAX_RETROACTIVE_LENGTH") + ); + REWARDS_COORDINATOR_MAX_FUTURE_LENGTH = uint32( + stdJson.readUint(config_data, ".rewardsCoordinator.MAX_FUTURE_LENGTH") + ); + REWARDS_COORDINATOR_GENESIS_REWARDS_TIMESTAMP = uint32( + stdJson.readUint(config_data, ".rewardsCoordinator.GENESIS_REWARDS_TIMESTAMP") + ); REWARDS_COORDINATOR_UPDATER = stdJson.readAddress(config_data, ".rewardsCoordinator.rewards_updater_address"); - REWARDS_COORDINATOR_ACTIVATION_DELAY = uint32(stdJson.readUint(config_data, ".rewardsCoordinator.activation_delay")); + REWARDS_COORDINATOR_ACTIVATION_DELAY = uint32( + stdJson.readUint(config_data, ".rewardsCoordinator.activation_delay") + ); REWARDS_COORDINATOR_CALCULATION_INTERVAL_SECONDS = uint32( stdJson.readUint(config_data, ".rewardsCoordinator.calculation_interval_seconds") ); - REWARDS_COORDINATOR_GLOBAL_OPERATOR_COMMISSION_BIPS = uint32( - stdJson.readUint(config_data, ".rewardsCoordinator.global_operator_commission_bips") + REWARDS_COORDINATOR_DEFAULT_OPERATOR_SPLIT_BIPS = uint32( + stdJson.readUint(config_data, ".rewardsCoordinator.default_operator_split_bips") ); REWARDS_COORDINATOR_OPERATOR_SET_GENESIS_REWARDS_TIMESTAMP = uint32( stdJson.readUint(config_data, ".rewardsCoordinator.OPERATOR_SET_GENESIS_REWARDS_TIMESTAMP") @@ -206,11 +216,7 @@ contract DeployFromScratch is Script, Test { } else { ethPOSDeposit = IETHPOSDeposit(stdJson.readAddress(config_data, ".ethPOSDepositAddress")); } - eigenPodImplementation = new EigenPod( - ethPOSDeposit, - eigenPodManager, - GOERLI_GENESIS_TIME - ); + eigenPodImplementation = new EigenPod(ethPOSDeposit, eigenPodManager, GOERLI_GENESIS_TIME); eigenPodBeacon = new UpgradeableBeacon(address(eigenPodImplementation)); @@ -300,7 +306,7 @@ contract DeployFromScratch is Script, Test { REWARDS_COORDINATOR_INIT_PAUSED_STATUS, REWARDS_COORDINATOR_UPDATER, REWARDS_COORDINATOR_ACTIVATION_DELAY, - REWARDS_COORDINATOR_GLOBAL_OPERATOR_COMMISSION_BIPS + REWARDS_COORDINATOR_DEFAULT_OPERATOR_SPLIT_BIPS ) ); @@ -309,7 +315,9 @@ contract DeployFromScratch is Script, Test { // create upgradeable proxies that each point to the implementation and initialize them for (uint256 i = 0; i < strategyConfigs.length; ++i) { if (strategyConfigs[i].tokenAddress == address(0)) { - strategyConfigs[i].tokenAddress = address(new ERC20PresetFixedSupply("TestToken", "TEST", uint256(type(uint128).max), executorMultisig)); + strategyConfigs[i].tokenAddress = address( + new ERC20PresetFixedSupply("TestToken", "TEST", uint256(type(uint128).max), executorMultisig) + ); } deployedStrategyArray.push( StrategyBaseTVLLimits( @@ -344,13 +352,7 @@ contract DeployFromScratch is Script, Test { eigenPodManagerImplementation, rewardsCoordinatorImplementation ); - _verifyContractsPointAtOneAnother( - delegation, - strategyManager, - slasher, - eigenPodManager, - rewardsCoordinator - ); + _verifyContractsPointAtOneAnother(delegation, strategyManager, slasher, eigenPodManager, rewardsCoordinator); _verifyImplementationsSetCorrectly(); _verifyInitialOwners(); _checkPauserInitializations(); @@ -412,7 +414,8 @@ contract DeployFromScratch is Script, Test { { // dummy token data - string memory token = '{"tokenProxyAdmin": "0x0000000000000000000000000000000000000000", "EIGEN": "0x0000000000000000000000000000000000000000","bEIGEN": "0x0000000000000000000000000000000000000000","EIGENImpl": "0x0000000000000000000000000000000000000000","bEIGENImpl": "0x0000000000000000000000000000000000000000","eigenStrategy": "0x0000000000000000000000000000000000000000","eigenStrategyImpl": "0x0000000000000000000000000000000000000000"}'; + string + memory token = '{"tokenProxyAdmin": "0x0000000000000000000000000000000000000000", "EIGEN": "0x0000000000000000000000000000000000000000","bEIGEN": "0x0000000000000000000000000000000000000000","EIGENImpl": "0x0000000000000000000000000000000000000000","bEIGENImpl": "0x0000000000000000000000000000000000000000","eigenStrategy": "0x0000000000000000000000000000000000000000","eigenStrategyImpl": "0x0000000000000000000000000000000000000000"}'; deployed_addresses_output = vm.serializeString(deployed_addresses, "token", token); } diff --git a/script/output/devnet/local_from_scratch_deployment_data.json b/script/output/devnet/local_from_scratch_deployment_data.json deleted file mode 100644 index e69de29bb..000000000 diff --git a/script/utils/ExistingDeploymentParser.sol b/script/utils/ExistingDeploymentParser.sol index af725f030..0ee3ae863 100644 --- a/script/utils/ExistingDeploymentParser.sol +++ b/script/utils/ExistingDeploymentParser.sol @@ -116,7 +116,7 @@ contract ExistingDeploymentParser is Script, Test { address REWARDS_COORDINATOR_UPDATER; uint32 REWARDS_COORDINATOR_ACTIVATION_DELAY; uint32 REWARDS_COORDINATOR_CALCULATION_INTERVAL_SECONDS; - uint32 REWARDS_COORDINATOR_GLOBAL_OPERATOR_COMMISSION_BIPS; + uint32 REWARDS_COORDINATOR_DEFAULT_OPERATOR_SPLIT_BIPS; // EigenPodManager uint256 EIGENPOD_MANAGER_INIT_PAUSED_STATUS; // EigenPod @@ -129,9 +129,7 @@ contract ExistingDeploymentParser is Script, Test { uint256 STRATEGY_MAX_TOTAL_DEPOSITS; /// @notice use for parsing already deployed EigenLayer contracts - function _parseDeployedContracts( - string memory existingDeploymentInfoPath - ) internal virtual { + function _parseDeployedContracts(string memory existingDeploymentInfoPath) internal virtual { // read and log the chainID uint256 currentChainId = block.chainid; emit log_named_uint("You are parsing on ChainID", currentChainId); @@ -153,38 +151,51 @@ contract ExistingDeploymentParser is Script, Test { pauserMultisig = stdJson.readAddress(existingDeploymentData, ".parameters.pauserMultisig"); timelock = stdJson.readAddress(existingDeploymentData, ".parameters.timelock"); - eigenLayerProxyAdmin = - ProxyAdmin(stdJson.readAddress(existingDeploymentData, ".addresses.eigenLayerProxyAdmin")); - eigenLayerPauserReg = - PauserRegistry(stdJson.readAddress(existingDeploymentData, ".addresses.eigenLayerPauserReg")); + eigenLayerProxyAdmin = ProxyAdmin( + stdJson.readAddress(existingDeploymentData, ".addresses.eigenLayerProxyAdmin") + ); + eigenLayerPauserReg = PauserRegistry( + stdJson.readAddress(existingDeploymentData, ".addresses.eigenLayerPauserReg") + ); slasher = Slasher(stdJson.readAddress(existingDeploymentData, ".addresses.slasher")); - slasherImplementation = Slasher(stdJson.readAddress(existingDeploymentData, ".addresses.slasherImplementation")); - delegationManager = - DelegationManager(stdJson.readAddress(existingDeploymentData, ".addresses.delegationManager")); - delegationManagerImplementation = - DelegationManager(stdJson.readAddress(existingDeploymentData, ".addresses.delegationManagerImplementation")); + slasherImplementation = Slasher( + stdJson.readAddress(existingDeploymentData, ".addresses.slasherImplementation") + ); + delegationManager = DelegationManager( + stdJson.readAddress(existingDeploymentData, ".addresses.delegationManager") + ); + delegationManagerImplementation = DelegationManager( + stdJson.readAddress(existingDeploymentData, ".addresses.delegationManagerImplementation") + ); avsDirectory = AVSDirectory(stdJson.readAddress(existingDeploymentData, ".addresses.avsDirectory")); - avsDirectoryImplementation = - AVSDirectory(stdJson.readAddress(existingDeploymentData, ".addresses.avsDirectoryImplementation")); - rewardsCoordinator = - RewardsCoordinator(stdJson.readAddress(existingDeploymentData, ".addresses.rewardsCoordinator")); + avsDirectoryImplementation = AVSDirectory( + stdJson.readAddress(existingDeploymentData, ".addresses.avsDirectoryImplementation") + ); + rewardsCoordinator = RewardsCoordinator( + stdJson.readAddress(existingDeploymentData, ".addresses.rewardsCoordinator") + ); rewardsCoordinatorImplementation = RewardsCoordinator( stdJson.readAddress(existingDeploymentData, ".addresses.rewardsCoordinatorImplementation") ); strategyManager = StrategyManager(stdJson.readAddress(existingDeploymentData, ".addresses.strategyManager")); - strategyManagerImplementation = - StrategyManager(stdJson.readAddress(existingDeploymentData, ".addresses.strategyManagerImplementation")); + strategyManagerImplementation = StrategyManager( + stdJson.readAddress(existingDeploymentData, ".addresses.strategyManagerImplementation") + ); strategyFactory = StrategyFactory(stdJson.readAddress(existingDeploymentData, ".addresses.strategyFactory")); - strategyFactoryImplementation = - StrategyFactory(stdJson.readAddress(existingDeploymentData, ".addresses.strategyFactoryImplementation")); + strategyFactoryImplementation = StrategyFactory( + stdJson.readAddress(existingDeploymentData, ".addresses.strategyFactoryImplementation") + ); eigenPodManager = EigenPodManager(stdJson.readAddress(existingDeploymentData, ".addresses.eigenPodManager")); - eigenPodManagerImplementation = - EigenPodManager(stdJson.readAddress(existingDeploymentData, ".addresses.eigenPodManagerImplementation")); + eigenPodManagerImplementation = EigenPodManager( + stdJson.readAddress(existingDeploymentData, ".addresses.eigenPodManagerImplementation") + ); eigenPodBeacon = UpgradeableBeacon(stdJson.readAddress(existingDeploymentData, ".addresses.eigenPodBeacon")); - eigenPodImplementation = - EigenPod(payable(stdJson.readAddress(existingDeploymentData, ".addresses.eigenPodImplementation"))); - baseStrategyImplementation = - StrategyBase(stdJson.readAddress(existingDeploymentData, ".addresses.baseStrategyImplementation")); + eigenPodImplementation = EigenPod( + payable(stdJson.readAddress(existingDeploymentData, ".addresses.eigenPodImplementation")) + ); + baseStrategyImplementation = StrategyBase( + stdJson.readAddress(existingDeploymentData, ".addresses.baseStrategyImplementation") + ); emptyContract = EmptyContract(stdJson.readAddress(existingDeploymentData, ".addresses.emptyContract")); // Strategies Deployed, load strategy list @@ -205,8 +216,9 @@ contract ExistingDeploymentParser is Script, Test { bEIGEN = IBackingEigen(stdJson.readAddress(existingDeploymentData, ".addresses.token.bEIGEN")); bEIGENImpl = IBackingEigen(stdJson.readAddress(existingDeploymentData, ".addresses.token.bEIGENImpl")); eigenStrategy = EigenStrategy(stdJson.readAddress(existingDeploymentData, ".addresses.token.eigenStrategy")); - eigenStrategyImpl = - EigenStrategy(stdJson.readAddress(existingDeploymentData, ".addresses.token.eigenStrategyImpl")); + eigenStrategyImpl = EigenStrategy( + stdJson.readAddress(existingDeploymentData, ".addresses.token.eigenStrategyImpl") + ); } function _parseDeployedEigenPods( @@ -225,18 +237,17 @@ contract ExistingDeploymentParser is Script, Test { singleValidatorPods = stdJson.readAddressArray(existingDeploymentData, ".eigenPods.singleValidatorPods"); inActivePods = stdJson.readAddressArray(existingDeploymentData, ".eigenPods.inActivePods"); allEigenPods = stdJson.readAddressArray(existingDeploymentData, ".eigenPods.allEigenPods"); - return DeployedEigenPods({ - multiValidatorPods: multiValidatorPods, - singleValidatorPods: singleValidatorPods, - inActivePods: inActivePods - }); + return + DeployedEigenPods({ + multiValidatorPods: multiValidatorPods, + singleValidatorPods: singleValidatorPods, + inActivePods: inActivePods + }); } /// @notice use for deploying a new set of EigenLayer contracts /// Note that this does require multisigs to already be deployed - function _parseInitialDeploymentParams( - string memory initialDeploymentParamsPath - ) internal virtual { + function _parseInitialDeploymentParams(string memory initialDeploymentParamsPath) internal virtual { // read and log the chainID uint256 currentChainId = block.chainid; emit log_named_uint("You are parsing on ChainID", currentChainId); @@ -269,47 +280,71 @@ contract ExistingDeploymentParser is Script, Test { bytes memory tokenInfoBytes = stdJson.parseRaw(initialDeploymentData, key); // Decode the token information into the Token struct - StrategyUnderlyingTokenConfig memory tokenInfo = abi.decode(tokenInfoBytes, (StrategyUnderlyingTokenConfig)); + StrategyUnderlyingTokenConfig memory tokenInfo = abi.decode( + tokenInfoBytes, + (StrategyUnderlyingTokenConfig) + ); strategiesToDeploy.push(tokenInfo); } // Read initialize params for upgradeable contracts - STRATEGY_MANAGER_INIT_PAUSED_STATUS = - stdJson.readUint(initialDeploymentData, ".strategyManager.init_paused_status"); - STRATEGY_MANAGER_WHITELISTER = - stdJson.readAddress(initialDeploymentData, ".strategyManager.init_strategy_whitelister"); + STRATEGY_MANAGER_INIT_PAUSED_STATUS = stdJson.readUint( + initialDeploymentData, + ".strategyManager.init_paused_status" + ); + STRATEGY_MANAGER_WHITELISTER = stdJson.readAddress( + initialDeploymentData, + ".strategyManager.init_strategy_whitelister" + ); // Slasher SLASHER_INIT_PAUSED_STATUS = stdJson.readUint(initialDeploymentData, ".slasher.init_paused_status"); // DelegationManager - DELEGATION_MANAGER_MIN_WITHDRAWAL_DELAY_BLOCKS = - stdJson.readUint(initialDeploymentData, ".delegationManager.init_minWithdrawalDelayBlocks"); - DELEGATION_MANAGER_INIT_PAUSED_STATUS = - stdJson.readUint(initialDeploymentData, ".delegationManager.init_paused_status"); + DELEGATION_MANAGER_MIN_WITHDRAWAL_DELAY_BLOCKS = stdJson.readUint( + initialDeploymentData, + ".delegationManager.init_minWithdrawalDelayBlocks" + ); + DELEGATION_MANAGER_INIT_PAUSED_STATUS = stdJson.readUint( + initialDeploymentData, + ".delegationManager.init_paused_status" + ); // RewardsCoordinator - REWARDS_COORDINATOR_INIT_PAUSED_STATUS = - stdJson.readUint(initialDeploymentData, ".rewardsCoordinator.init_paused_status"); - REWARDS_COORDINATOR_CALCULATION_INTERVAL_SECONDS = - uint32(stdJson.readUint(initialDeploymentData, ".rewardsCoordinator.CALCULATION_INTERVAL_SECONDS")); - REWARDS_COORDINATOR_MAX_REWARDS_DURATION = - uint32(stdJson.readUint(initialDeploymentData, ".rewardsCoordinator.MAX_REWARDS_DURATION")); - REWARDS_COORDINATOR_MAX_RETROACTIVE_LENGTH = - uint32(stdJson.readUint(initialDeploymentData, ".rewardsCoordinator.MAX_RETROACTIVE_LENGTH")); - REWARDS_COORDINATOR_MAX_FUTURE_LENGTH = - uint32(stdJson.readUint(initialDeploymentData, ".rewardsCoordinator.MAX_FUTURE_LENGTH")); - REWARDS_COORDINATOR_GENESIS_REWARDS_TIMESTAMP = - uint32(stdJson.readUint(initialDeploymentData, ".rewardsCoordinator.GENESIS_REWARDS_TIMESTAMP")); - REWARDS_COORDINATOR_UPDATER = - stdJson.readAddress(initialDeploymentData, ".rewardsCoordinator.rewards_updater_address"); - REWARDS_COORDINATOR_ACTIVATION_DELAY = - uint32(stdJson.readUint(initialDeploymentData, ".rewardsCoordinator.activation_delay")); - REWARDS_COORDINATOR_GLOBAL_OPERATOR_COMMISSION_BIPS = - uint32(stdJson.readUint(initialDeploymentData, ".rewardsCoordinator.global_operator_commission_bips")); + REWARDS_COORDINATOR_INIT_PAUSED_STATUS = stdJson.readUint( + initialDeploymentData, + ".rewardsCoordinator.init_paused_status" + ); + REWARDS_COORDINATOR_CALCULATION_INTERVAL_SECONDS = uint32( + stdJson.readUint(initialDeploymentData, ".rewardsCoordinator.CALCULATION_INTERVAL_SECONDS") + ); + REWARDS_COORDINATOR_MAX_REWARDS_DURATION = uint32( + stdJson.readUint(initialDeploymentData, ".rewardsCoordinator.MAX_REWARDS_DURATION") + ); + REWARDS_COORDINATOR_MAX_RETROACTIVE_LENGTH = uint32( + stdJson.readUint(initialDeploymentData, ".rewardsCoordinator.MAX_RETROACTIVE_LENGTH") + ); + REWARDS_COORDINATOR_MAX_FUTURE_LENGTH = uint32( + stdJson.readUint(initialDeploymentData, ".rewardsCoordinator.MAX_FUTURE_LENGTH") + ); + REWARDS_COORDINATOR_GENESIS_REWARDS_TIMESTAMP = uint32( + stdJson.readUint(initialDeploymentData, ".rewardsCoordinator.GENESIS_REWARDS_TIMESTAMP") + ); + REWARDS_COORDINATOR_UPDATER = stdJson.readAddress( + initialDeploymentData, + ".rewardsCoordinator.rewards_updater_address" + ); + REWARDS_COORDINATOR_ACTIVATION_DELAY = uint32( + stdJson.readUint(initialDeploymentData, ".rewardsCoordinator.activation_delay") + ); + REWARDS_COORDINATOR_DEFAULT_OPERATOR_SPLIT_BIPS = uint32( + stdJson.readUint(initialDeploymentData, ".rewardsCoordinator.default_operator_split_bips") + ); // AVSDirectory AVS_DIRECTORY_INIT_PAUSED_STATUS = stdJson.readUint(initialDeploymentData, ".avsDirectory.init_paused_status"); // EigenPodManager - EIGENPOD_MANAGER_INIT_PAUSED_STATUS = - stdJson.readUint(initialDeploymentData, ".eigenPodManager.init_paused_status"); + EIGENPOD_MANAGER_INIT_PAUSED_STATUS = stdJson.readUint( + initialDeploymentData, + ".eigenPodManager.init_paused_status" + ); // EigenPod EIGENPOD_GENESIS_TIME = uint64(stdJson.readUint(initialDeploymentData, ".eigenPod.GENESIS_TIME")); ETHPOSDepositAddress = stdJson.readAddress(initialDeploymentData, ".ethPOSDepositAddress"); @@ -321,7 +356,8 @@ contract ExistingDeploymentParser is Script, Test { function _verifyContractPointers() internal view virtual { // AVSDirectory require( - avsDirectory.delegation() == delegationManager, "avsDirectory: delegationManager address not set correctly" + avsDirectory.delegation() == delegationManager, + "avsDirectory: delegationManager address not set correctly" ); // RewardsCoordinator require( @@ -375,8 +411,8 @@ contract ExistingDeploymentParser is Script, Test { /// @notice verify implementations for Transparent Upgradeable Proxies function _verifyImplementations() internal view virtual { require( - eigenLayerProxyAdmin.getProxyImplementation(TransparentUpgradeableProxy(payable(address(avsDirectory)))) - == address(avsDirectoryImplementation), + eigenLayerProxyAdmin.getProxyImplementation(TransparentUpgradeableProxy(payable(address(avsDirectory)))) == + address(avsDirectoryImplementation), "avsDirectory: implementation set incorrectly" ); require( @@ -392,18 +428,20 @@ contract ExistingDeploymentParser is Script, Test { "delegationManager: implementation set incorrectly" ); require( - eigenLayerProxyAdmin.getProxyImplementation(TransparentUpgradeableProxy(payable(address(strategyManager)))) - == address(strategyManagerImplementation), + eigenLayerProxyAdmin.getProxyImplementation( + TransparentUpgradeableProxy(payable(address(strategyManager))) + ) == address(strategyManagerImplementation), "strategyManager: implementation set incorrectly" ); require( - eigenLayerProxyAdmin.getProxyImplementation(TransparentUpgradeableProxy(payable(address(slasher)))) - == address(slasherImplementation), + eigenLayerProxyAdmin.getProxyImplementation(TransparentUpgradeableProxy(payable(address(slasher)))) == + address(slasherImplementation), "slasher: implementation set incorrectly" ); require( - eigenLayerProxyAdmin.getProxyImplementation(TransparentUpgradeableProxy(payable(address(eigenPodManager)))) - == address(eigenPodManagerImplementation), + eigenLayerProxyAdmin.getProxyImplementation( + TransparentUpgradeableProxy(payable(address(eigenPodManager))) + ) == address(eigenPodManagerImplementation), "eigenPodManager: implementation set incorrectly" ); @@ -427,15 +465,7 @@ contract ExistingDeploymentParser is Script, Test { * initialization params if this is the first deployment. * @dev isInitialDeployment True if this is the first deployment of contracts from scratch */ - function _verifyContractsInitialized( - bool - ) - /** - * isInitialDeployment * - */ - internal - virtual - { + function _verifyContractsInitialized(bool /* isInitialDeployment */) internal virtual { // AVSDirectory vm.expectRevert(bytes("Initializable: contract is already initialized")); avsDirectory.initialize(address(0), eigenLayerPauserReg, AVS_DIRECTORY_INIT_PAUSED_STATUS); @@ -447,7 +477,7 @@ contract ExistingDeploymentParser is Script, Test { 0, // initialPausedStatus address(0), // rewardsUpdater 0, // activationDelay - 0 // globalCommissionBips + 0 // defaultSplitBips ); // DelegationManager vm.expectRevert(bytes("Initializable: contract is already initialized")); @@ -471,7 +501,10 @@ contract ExistingDeploymentParser is Script, Test { for (uint256 i = 0; i < deployedStrategyArray.length; ++i) { vm.expectRevert(bytes("Initializable: contract is already initialized")); StrategyBaseTVLLimits(address(deployedStrategyArray[i])).initialize( - 0, 0, IERC20(address(0)), eigenLayerPauserReg + 0, + 0, + IERC20(address(0)), + eigenLayerPauserReg ); } } @@ -479,7 +512,10 @@ contract ExistingDeploymentParser is Script, Test { /// @notice Verify params based on config constants that are updated from calling `_parseInitialDeploymentParams` function _verifyInitializationParams() internal view virtual { // AVSDirectory - require(avsDirectory.pauserRegistry() == eigenLayerPauserReg, "avsdirectory: pauser registry not set correctly"); + require( + avsDirectory.pauserRegistry() == eigenLayerPauserReg, + "avsdirectory: pauser registry not set correctly" + ); require(avsDirectory.owner() == executorMultisig, "avsdirectory: owner not set correctly"); require( avsDirectory.paused() == AVS_DIRECTORY_INIT_PAUSED_STATUS, @@ -527,8 +563,8 @@ contract ExistingDeploymentParser is Script, Test { "rewardsCoordinator: CALCULATION_INTERVAL_SECONDS not set correctly" ); require( - rewardsCoordinator.globalOperatorCommissionBips() == REWARDS_COORDINATOR_GLOBAL_OPERATOR_COMMISSION_BIPS, - "rewardsCoordinator: globalCommissionBips not set correctly" + rewardsCoordinator.defaultOperatorSplitBips() == REWARDS_COORDINATOR_DEFAULT_OPERATOR_SPLIT_BIPS, + "rewardsCoordinator: defaultSplitBips not set correctly" ); // DelegationManager require( @@ -597,7 +633,10 @@ contract ExistingDeploymentParser is Script, Test { deployedStrategyArray[i].pauserRegistry() == eigenLayerPauserReg, "StrategyBaseTVLLimits: pauser registry not set correctly" ); - require(deployedStrategyArray[i].paused() == 0, "StrategyBaseTVLLimits: init paused status set incorrectly"); + require( + deployedStrategyArray[i].paused() == 0, + "StrategyBaseTVLLimits: init paused status set incorrectly" + ); require( strategyManager.strategyIsWhitelistedForDeposit(deployedStrategyArray[i]), "StrategyBaseTVLLimits: strategy should be whitelisted" @@ -623,7 +662,8 @@ contract ExistingDeploymentParser is Script, Test { emit log_named_address("STRATEGY_MANAGER_WHITELISTER", STRATEGY_MANAGER_WHITELISTER); emit log_named_uint("SLASHER_INIT_PAUSED_STATUS", SLASHER_INIT_PAUSED_STATUS); emit log_named_uint( - "DELEGATION_MANAGER_MIN_WITHDRAWAL_DELAY_BLOCKS", DELEGATION_MANAGER_MIN_WITHDRAWAL_DELAY_BLOCKS + "DELEGATION_MANAGER_MIN_WITHDRAWAL_DELAY_BLOCKS", + DELEGATION_MANAGER_MIN_WITHDRAWAL_DELAY_BLOCKS ); emit log_named_uint("DELEGATION_MANAGER_INIT_PAUSED_STATUS", DELEGATION_MANAGER_INIT_PAUSED_STATUS); emit log_named_uint("AVS_DIRECTORY_INIT_PAUSED_STATUS", AVS_DIRECTORY_INIT_PAUSED_STATUS); @@ -648,16 +688,16 @@ contract ExistingDeploymentParser is Script, Test { /** * @notice Log contract addresses and write to output json file */ - function logAndOutputContractAddresses( - string memory outputPath - ) public { + function logAndOutputContractAddresses(string memory outputPath) public { // WRITE JSON DATA string memory parent_object = "parent object"; string memory deployed_strategies = "strategies"; for (uint256 i = 0; i < numStrategiesToDeploy; ++i) { vm.serializeAddress( - deployed_strategies, strategiesToDeploy[i].tokenSymbol, address(deployedStrategyArray[i]) + deployed_strategies, + strategiesToDeploy[i].tokenSymbol, + address(deployedStrategyArray[i]) ); } string memory deployed_strategies_output = numStrategiesToDeploy == 0 @@ -677,22 +717,37 @@ contract ExistingDeploymentParser is Script, Test { vm.serializeAddress(deployed_addresses, "avsDirectoryImplementation", address(avsDirectoryImplementation)); vm.serializeAddress(deployed_addresses, "delegationManager", address(delegationManager)); vm.serializeAddress( - deployed_addresses, "delegationManagerImplementation", address(delegationManagerImplementation) + deployed_addresses, + "delegationManagerImplementation", + address(delegationManagerImplementation) ); vm.serializeAddress(deployed_addresses, "strategyManager", address(strategyManager)); - vm.serializeAddress(deployed_addresses, "strategyManagerImplementation", address(strategyManagerImplementation)); + vm.serializeAddress( + deployed_addresses, + "strategyManagerImplementation", + address(strategyManagerImplementation) + ); vm.serializeAddress(deployed_addresses, "rewardsCoordinator", address(rewardsCoordinator)); vm.serializeAddress( - deployed_addresses, "rewardsCoordinatorImplementation", address(rewardsCoordinatorImplementation) + deployed_addresses, + "rewardsCoordinatorImplementation", + address(rewardsCoordinatorImplementation) ); vm.serializeAddress(deployed_addresses, "eigenPodManager", address(eigenPodManager)); - vm.serializeAddress(deployed_addresses, "eigenPodManagerImplementation", address(eigenPodManagerImplementation)); + vm.serializeAddress( + deployed_addresses, + "eigenPodManagerImplementation", + address(eigenPodManagerImplementation) + ); vm.serializeAddress(deployed_addresses, "eigenPodBeacon", address(eigenPodBeacon)); vm.serializeAddress(deployed_addresses, "eigenPodImplementation", address(eigenPodImplementation)); vm.serializeAddress(deployed_addresses, "baseStrategyImplementation", address(baseStrategyImplementation)); vm.serializeAddress(deployed_addresses, "emptyContract", address(emptyContract)); - string memory deployed_addresses_output = - vm.serializeString(deployed_addresses, "strategies", deployed_strategies_output); + string memory deployed_addresses_output = vm.serializeString( + deployed_addresses, + "strategies", + deployed_strategies_output + ); string memory parameters = "parameters"; vm.serializeAddress(parameters, "executorMultisig", executorMultisig); diff --git a/src/contracts/core/RewardsCoordinator.sol b/src/contracts/core/RewardsCoordinator.sol index 1bc73c99b..c9ae561a5 100644 --- a/src/contracts/core/RewardsCoordinator.sol +++ b/src/contracts/core/RewardsCoordinator.sol @@ -15,7 +15,7 @@ import "./RewardsCoordinatorStorage.sol"; * @notice Terms of Service: https://docs.eigenlayer.xyz/overview/terms-of-service * @notice This is the contract for rewards in EigenLayer. The main functionalities of this contract are * - enabling any ERC20 rewards from AVSs to their operators and stakers for a given time range - * - allowing stakers and operators to claim their earnings including a commission bips for operators + * - allowing stakers and operators to claim their earnings including a split bips for operators * - allowing the protocol to provide ERC20 tokens to stakers over a specified time range */ contract RewardsCoordinator is @@ -34,6 +34,8 @@ contract RewardsCoordinator is uint256 internal immutable ORIGINAL_CHAIN_ID; /// @notice The maximum rewards token amount for a single rewards submission, constrained by off-chain calculation uint256 internal constant MAX_REWARDS_AMOUNT = 1e38 - 1; + /// @notice Equivalent to 100%, but in basis points. + uint16 internal constant ONE_HUNDRED_IN_BIPS = 10_000; /// @dev Index for flag that pauses calling createAVSRewardsSubmission uint8 internal constant PAUSED_AVS_REWARDS_SUBMISSION = 0; @@ -45,6 +47,12 @@ contract RewardsCoordinator is uint8 internal constant PAUSED_SUBMIT_DISABLE_ROOTS = 3; /// @dev Index for flag that pauses calling rewardAllStakersAndOperators uint8 internal constant PAUSED_REWARD_ALL_STAKERS_AND_OPERATORS = 4; + /// @dev Index for flag that pauses calling createOperatorDirectedAVSRewardsSubmission + uint8 internal constant PAUSED_OPERATOR_DIRECTED_AVS_REWARDS_SUBMISSION = 5; + /// @dev Index for flag that pauses calling setOperatorAVSSplit + uint8 internal constant PAUSED_OPERATOR_AVS_SPLIT = 6; + /// @dev Index for flag that pauses calling setOperatorPISplit + uint8 internal constant PAUSED_OPERATOR_PI_SPLIT = 7; /// @dev Salt for the earner leaf, meant to distinguish from tokenLeaf since they have the same sized data uint8 internal constant EARNER_LEAF_SALT = 0; @@ -93,7 +101,7 @@ contract RewardsCoordinator is /** * @dev Initializes the addresses of the initial owner, pauser registry, rewardsUpdater and - * configures the initial paused status, activationDelay, and globalOperatorCommissionBips. + * configures the initial paused status, activationDelay, and defaultOperatorSplitBips. */ function initialize( address initialOwner, @@ -101,14 +109,14 @@ contract RewardsCoordinator is uint256 initialPausedStatus, address _rewardsUpdater, uint32 _activationDelay, - uint16 _globalCommissionBips + uint16 _defaultSplitBips ) external initializer { _DOMAIN_SEPARATOR = _calculateDomainSeparator(); _initializePauser(_pauserRegistry, initialPausedStatus); _transferOwnership(initialOwner); _setRewardsUpdater(_rewardsUpdater); _setActivationDelay(_activationDelay); - _setGlobalOperatorCommission(_globalCommissionBips); + _setDefaultOperatorSplit(_defaultSplitBips); } /** @@ -118,11 +126,9 @@ contract RewardsCoordinator is */ /// @inheritdoc IRewardsCoordinator - function createAVSRewardsSubmission(RewardsSubmission[] calldata rewardsSubmissions) - external - onlyWhenNotPaused(PAUSED_AVS_REWARDS_SUBMISSION) - nonReentrant - { + function createAVSRewardsSubmission( + RewardsSubmission[] calldata rewardsSubmissions + ) external onlyWhenNotPaused(PAUSED_AVS_REWARDS_SUBMISSION) nonReentrant { for (uint256 i = 0; i < rewardsSubmissions.length; i++) { RewardsSubmission calldata rewardsSubmission = rewardsSubmissions[i]; uint256 nonce = submissionNonce[msg.sender]; @@ -139,12 +145,9 @@ contract RewardsCoordinator is } /// @inheritdoc IRewardsCoordinator - function createRewardsForAllSubmission(RewardsSubmission[] calldata rewardsSubmissions) - external - onlyWhenNotPaused(PAUSED_REWARDS_FOR_ALL_SUBMISSION) - onlyRewardsForAllSubmitter - nonReentrant - { + function createRewardsForAllSubmission( + RewardsSubmission[] calldata rewardsSubmissions + ) external onlyWhenNotPaused(PAUSED_REWARDS_FOR_ALL_SUBMISSION) onlyRewardsForAllSubmitter nonReentrant { for (uint256 i = 0; i < rewardsSubmissions.length; i++) { RewardsSubmission calldata rewardsSubmission = rewardsSubmissions[i]; uint256 nonce = submissionNonce[msg.sender]; @@ -161,12 +164,9 @@ contract RewardsCoordinator is } /// @inheritdoc IRewardsCoordinator - function createRewardsForAllEarners(RewardsSubmission[] calldata rewardsSubmissions) - external - onlyWhenNotPaused(PAUSED_REWARD_ALL_STAKERS_AND_OPERATORS) - onlyRewardsForAllSubmitter - nonReentrant - { + function createRewardsForAllEarners( + RewardsSubmission[] calldata rewardsSubmissions + ) external onlyWhenNotPaused(PAUSED_REWARD_ALL_STAKERS_AND_OPERATORS) onlyRewardsForAllSubmitter nonReentrant { for (uint256 i = 0; i < rewardsSubmissions.length; i++) { RewardsSubmission calldata rewardsSubmission = rewardsSubmissions[i]; uint256 nonce = submissionNonce[msg.sender]; @@ -178,41 +178,64 @@ contract RewardsCoordinator is submissionNonce[msg.sender] = nonce + 1; emit RewardsSubmissionForAllEarnersCreated( - msg.sender, nonce, rewardsSubmissionForAllEarnersHash, rewardsSubmission + msg.sender, + nonce, + rewardsSubmissionForAllEarnersHash, + rewardsSubmission ); rewardsSubmission.token.safeTransferFrom(msg.sender, address(this), rewardsSubmission.amount); } } + /// @inheritdoc IRewardsCoordinator + function createOperatorDirectedAVSRewardsSubmission( + address avs, + OperatorDirectedRewardsSubmission[] calldata operatorDirectedRewardsSubmissions + ) external onlyWhenNotPaused(PAUSED_OPERATOR_DIRECTED_AVS_REWARDS_SUBMISSION) nonReentrant { + require( + msg.sender == avs, + "RewardsCoordinator.createOperatorDirectedAVSRewardsSubmission: caller is not the AVS" + ); + + for (uint256 i = 0; i < operatorDirectedRewardsSubmissions.length; i++) { + OperatorDirectedRewardsSubmission + calldata operatorDirectedRewardsSubmission = operatorDirectedRewardsSubmissions[i]; + uint256 nonce = submissionNonce[avs]; + bytes32 operatorDirectedRewardsSubmissionHash = keccak256( + abi.encode(avs, nonce, operatorDirectedRewardsSubmission) + ); + + uint256 totalAmount = _validateOperatorDirectedRewardsSubmission(operatorDirectedRewardsSubmission); + + isOperatorDirectedAVSRewardsSubmissionHash[avs][operatorDirectedRewardsSubmissionHash] = true; + submissionNonce[avs] = nonce + 1; + + emit OperatorDirectedAVSRewardsSubmissionCreated( + msg.sender, + avs, + operatorDirectedRewardsSubmissionHash, + nonce, + operatorDirectedRewardsSubmission + ); + operatorDirectedRewardsSubmission.token.safeTransferFrom(msg.sender, address(this), totalAmount); + } + } + /// @inheritdoc IRewardsCoordinator function processClaim( RewardsMerkleClaim calldata claim, address recipient ) external onlyWhenNotPaused(PAUSED_PROCESS_CLAIM) nonReentrant { - DistributionRoot memory root = _distributionRoots[claim.rootIndex]; - _checkClaim(claim, root); - // If claimerFor earner is not set, claimer is by default the earner. Else set to claimerFor - address earner = claim.earnerLeaf.earner; - address claimer = claimerFor[earner]; - if (claimer == address(0)) { - claimer = earner; - } - require(msg.sender == claimer, "RewardsCoordinator.processClaim: caller is not valid claimer"); - for (uint256 i = 0; i < claim.tokenIndices.length; i++) { - TokenTreeMerkleLeaf calldata tokenLeaf = claim.tokenLeaves[i]; - - uint256 currCumulativeClaimed = cumulativeClaimed[earner][tokenLeaf.token]; - require( - tokenLeaf.cumulativeEarnings > currCumulativeClaimed, - "RewardsCoordinator.processClaim: cumulativeEarnings must be gt than cumulativeClaimed" - ); - - // Calculate amount to claim and update cumulativeClaimed - uint256 claimAmount = tokenLeaf.cumulativeEarnings - currCumulativeClaimed; - cumulativeClaimed[earner][tokenLeaf.token] = tokenLeaf.cumulativeEarnings; + _processClaim(claim, recipient); + } - tokenLeaf.token.safeTransfer(recipient, claimAmount); - emit RewardsClaimed(root.root, earner, claimer, recipient, tokenLeaf.token, claimAmount); + /// @inheritdoc IRewardsCoordinator + function processClaims( + RewardsMerkleClaim[] calldata claims, + address recipient + ) external onlyWhenNotPaused(PAUSED_PROCESS_CLAIM) nonReentrant { + for (uint256 i = 0; i < claims.length; i++) { + _processClaim(claims[i], recipient); } } @@ -267,8 +290,36 @@ contract RewardsCoordinator is } /// @inheritdoc IRewardsCoordinator - function setGlobalOperatorCommission(uint16 _globalCommissionBips) external onlyOwner { - _setGlobalOperatorCommission(_globalCommissionBips); + function setDefaultOperatorSplit(uint16 split) external onlyOwner { + _setDefaultOperatorSplit(split); + } + + /// @inheritdoc IRewardsCoordinator + function setOperatorAVSSplit( + address operator, + address avs, + uint16 split + ) external onlyWhenNotPaused(PAUSED_OPERATOR_AVS_SPLIT) { + require(msg.sender == operator, "RewardsCoordinator.setOperatorAVSSplit: caller is not the operator"); + require(split <= ONE_HUNDRED_IN_BIPS, "RewardsCoordinator.setOperatorAVSSplit: split must be <= 10000 bips"); + + uint32 activatedAt = uint32(block.timestamp) + activationDelay; + uint16 oldSplit = _getOperatorSplit(operatorAVSSplitBips[operator][avs]); + _setOperatorSplit(operatorAVSSplitBips[operator][avs], split, activatedAt); + + emit OperatorAVSSplitBipsSet(msg.sender, operator, avs, activatedAt, oldSplit, split); + } + + /// @inheritdoc IRewardsCoordinator + function setOperatorPISplit(address operator, uint16 split) external onlyWhenNotPaused(PAUSED_OPERATOR_PI_SPLIT) { + require(msg.sender == operator, "RewardsCoordinator.setOperatorPISplit: caller is not the operator"); + require(split <= ONE_HUNDRED_IN_BIPS, "RewardsCoordinator.setOperatorPISplit: split must be <= 10000 bips"); + + uint32 activatedAt = uint32(block.timestamp) + activationDelay; + uint16 oldSplit = _getOperatorSplit(operatorPISplitBips[operator]); + _setOperatorSplit(operatorPISplitBips[operator], split, activatedAt); + + emit OperatorPISplitBipsSet(msg.sender, operator, activatedAt, oldSplit, split); } /// @inheritdoc IRewardsCoordinator @@ -290,54 +341,117 @@ contract RewardsCoordinator is */ /** - * @notice Validate a RewardsSubmission. Called from both `createAVSRewardsSubmission` and `createRewardsForAllSubmission` + * @notice Common checks for all RewardsSubmissions. */ - function _validateRewardsSubmission(RewardsSubmission calldata rewardsSubmission) internal view { + function _validateCommonRewardsSubmission( + StrategyAndMultiplier[] calldata strategiesAndMultipliers, + uint32 startTimestamp, + uint32 duration + ) internal view { require( - rewardsSubmission.strategiesAndMultipliers.length > 0, - "RewardsCoordinator._validateRewardsSubmission: no strategies set" + strategiesAndMultipliers.length > 0, + "RewardsCoordinator._validateCommonRewardsSubmission: no strategies set" ); - require(rewardsSubmission.amount > 0, "RewardsCoordinator._validateRewardsSubmission: amount cannot be 0"); require( - rewardsSubmission.amount <= MAX_REWARDS_AMOUNT, - "RewardsCoordinator._validateRewardsSubmission: amount too large" + duration <= MAX_REWARDS_DURATION, + "RewardsCoordinator._validateCommonRewardsSubmission: duration exceeds MAX_REWARDS_DURATION" ); require( - rewardsSubmission.duration <= MAX_REWARDS_DURATION, - "RewardsCoordinator._validateRewardsSubmission: duration exceeds MAX_REWARDS_DURATION" + duration % CALCULATION_INTERVAL_SECONDS == 0, + "RewardsCoordinator._validateCommonRewardsSubmission: duration must be a multiple of CALCULATION_INTERVAL_SECONDS" ); require( - rewardsSubmission.duration % CALCULATION_INTERVAL_SECONDS == 0, - "RewardsCoordinator._validateRewardsSubmission: duration must be a multiple of CALCULATION_INTERVAL_SECONDS" + startTimestamp % CALCULATION_INTERVAL_SECONDS == 0, + "RewardsCoordinator._validateCommonRewardsSubmission: startTimestamp must be a multiple of CALCULATION_INTERVAL_SECONDS" ); require( - rewardsSubmission.startTimestamp % CALCULATION_INTERVAL_SECONDS == 0, - "RewardsCoordinator._validateRewardsSubmission: startTimestamp must be a multiple of CALCULATION_INTERVAL_SECONDS" + block.timestamp - MAX_RETROACTIVE_LENGTH <= startTimestamp && GENESIS_REWARDS_TIMESTAMP <= startTimestamp, + "RewardsCoordinator._validateCommonRewardsSubmission: startTimestamp too far in the past" ); + + // Require reward submission is for whitelisted strategy or beaconChainETHStrategy + address currAddress = address(0); + for (uint256 i = 0; i < strategiesAndMultipliers.length; ++i) { + IStrategy strategy = strategiesAndMultipliers[i].strategy; + require( + strategyManager.strategyIsWhitelistedForDeposit(strategy) || strategy == beaconChainETHStrategy, + "RewardsCoordinator._validateCommonRewardsSubmission: invalid strategy considered" + ); + require( + currAddress < address(strategy), + "RewardsCoordinator._validateCommonRewardsSubmission: strategies must be in ascending order to handle duplicates" + ); + currAddress = address(strategy); + } + } + + /** + * @notice Validate a RewardsSubmission. Called from both `createAVSRewardsSubmission` and `createRewardsForAllSubmission` + */ + function _validateRewardsSubmission(RewardsSubmission calldata rewardsSubmission) internal view { + _validateCommonRewardsSubmission( + rewardsSubmission.strategiesAndMultipliers, + rewardsSubmission.startTimestamp, + rewardsSubmission.duration + ); + require(rewardsSubmission.amount > 0, "RewardsCoordinator._validateRewardsSubmission: amount cannot be 0"); require( - block.timestamp - MAX_RETROACTIVE_LENGTH <= rewardsSubmission.startTimestamp - && GENESIS_REWARDS_TIMESTAMP <= rewardsSubmission.startTimestamp, - "RewardsCoordinator._validateRewardsSubmission: startTimestamp too far in the past" + rewardsSubmission.amount <= MAX_REWARDS_AMOUNT, + "RewardsCoordinator._validateRewardsSubmission: amount too large" ); require( rewardsSubmission.startTimestamp <= block.timestamp + MAX_FUTURE_LENGTH, "RewardsCoordinator._validateRewardsSubmission: startTimestamp too far in the future" ); + } + + /** + * @notice Validate a OperatorDirectedRewardsSubmission. Called from `createOperatorDirectedAVSRewardsSubmission`. + * @dev Not checking for `MAX_FUTURE_LENGTH` (Since operator-directed reward submissions are strictly retroactive) + * or `MAX_REWARDS_AMOUNT` (Since we no longer have the `1e38 - 1` limitation in the offchain rewards calculation) + * @param operatorDirectedRewardsSubmission OperatorDirectedRewardsSubmission to validate. + * @return total amount to be transferred from the avs to the contract. + */ + function _validateOperatorDirectedRewardsSubmission( + OperatorDirectedRewardsSubmission calldata operatorDirectedRewardsSubmission + ) internal view returns (uint256) { + _validateCommonRewardsSubmission( + operatorDirectedRewardsSubmission.strategiesAndMultipliers, + operatorDirectedRewardsSubmission.startTimestamp, + operatorDirectedRewardsSubmission.duration + ); - // Require rewardsSubmission is for whitelisted strategy or beaconChainETHStrategy - address currAddress = address(0); - for (uint256 i = 0; i < rewardsSubmission.strategiesAndMultipliers.length; ++i) { - IStrategy strategy = rewardsSubmission.strategiesAndMultipliers[i].strategy; + require( + operatorDirectedRewardsSubmission.operatorRewards.length > 0, + "RewardsCoordinator._validateOperatorDirectedRewardsSubmission: no operators rewarded" + ); + uint256 totalAmount = 0; + address currOperatorAddress = address(0); + for (uint256 i = 0; i < operatorDirectedRewardsSubmission.operatorRewards.length; ++i) { + OperatorReward calldata operatorReward = operatorDirectedRewardsSubmission.operatorRewards[i]; require( - strategyManager.strategyIsWhitelistedForDeposit(strategy) || strategy == beaconChainETHStrategy, - "RewardsCoordinator._validateRewardsSubmission: invalid strategy considered" + operatorReward.operator != address(0), + "RewardsCoordinator._validateOperatorDirectedRewardsSubmission: operator cannot be 0 address" ); require( - currAddress < address(strategy), - "RewardsCoordinator._validateRewardsSubmission: strategies must be in ascending order to handle duplicates" + currOperatorAddress < operatorReward.operator, + "RewardsCoordinator._validateOperatorDirectedRewardsSubmission: operators must be in ascending order to handle duplicates" ); - currAddress = address(strategy); + currOperatorAddress = operatorReward.operator; + require( + operatorReward.amount > 0, + "RewardsCoordinator._validateOperatorDirectedRewardsSubmission: operator reward amount cannot be 0" + ); + totalAmount += operatorReward.amount; } + + require( + operatorDirectedRewardsSubmission.startTimestamp + operatorDirectedRewardsSubmission.duration < + block.timestamp, + "RewardsCoordinator._validateOperatorDirectedRewardsSubmission: operator-directed rewards submission is not retroactive" + ); + + return totalAmount; } function _checkClaim(RewardsMerkleClaim calldata claim, DistributionRoot memory root) internal view { @@ -430,23 +544,56 @@ contract RewardsCoordinator is // forgefmt: disable-next-item require( Merkle.verifyInclusionKeccak({ - root: root, - index: earnerLeafIndex, - proof: earnerProof, + root: root, + index: earnerLeafIndex, + proof: earnerProof, leaf: earnerLeafHash }), "RewardsCoordinator._verifyEarnerClaimProof: invalid earner claim proof" ); } + /** + * @notice Internal helper to process reward claims. + * @param claim The RewardsMerkleClaims to be processed. + * @param recipient The address recipient that receives the ERC20 rewards + */ + function _processClaim(RewardsMerkleClaim calldata claim, address recipient) internal { + DistributionRoot memory root = _distributionRoots[claim.rootIndex]; + _checkClaim(claim, root); + // If claimerFor earner is not set, claimer is by default the earner. Else set to claimerFor + address earner = claim.earnerLeaf.earner; + address claimer = claimerFor[earner]; + if (claimer == address(0)) { + claimer = earner; + } + require(msg.sender == claimer, "RewardsCoordinator.processClaim: caller is not valid claimer"); + for (uint256 i = 0; i < claim.tokenIndices.length; i++) { + TokenTreeMerkleLeaf calldata tokenLeaf = claim.tokenLeaves[i]; + + uint256 currCumulativeClaimed = cumulativeClaimed[earner][tokenLeaf.token]; + require( + tokenLeaf.cumulativeEarnings > currCumulativeClaimed, + "RewardsCoordinator.processClaim: cumulativeEarnings must be gt than cumulativeClaimed" + ); + + // Calculate amount to claim and update cumulativeClaimed + uint256 claimAmount = tokenLeaf.cumulativeEarnings - currCumulativeClaimed; + cumulativeClaimed[earner][tokenLeaf.token] = tokenLeaf.cumulativeEarnings; + + tokenLeaf.token.safeTransfer(recipient, claimAmount); + emit RewardsClaimed(root.root, earner, claimer, recipient, tokenLeaf.token, claimAmount); + } + } + function _setActivationDelay(uint32 _activationDelay) internal { emit ActivationDelaySet(activationDelay, _activationDelay); activationDelay = _activationDelay; } - function _setGlobalOperatorCommission(uint16 _globalCommissionBips) internal { - emit GlobalCommissionBipsSet(globalOperatorCommissionBips, _globalCommissionBips); - globalOperatorCommissionBips = _globalCommissionBips; + function _setDefaultOperatorSplit(uint16 split) internal { + emit DefaultOperatorSplitBipsSet(defaultOperatorSplitBips, split); + defaultOperatorSplitBips = split; } function _setRewardsUpdater(address _rewardsUpdater) internal { @@ -454,6 +601,47 @@ contract RewardsCoordinator is rewardsUpdater = _rewardsUpdater; } + /** + * @notice Internal helper to set the operator split. + * @param operatorSplit The split struct for an Operator + * @param split The split in basis points. + * @param activatedAt The timestamp when the split is activated. + */ + function _setOperatorSplit(OperatorSplit storage operatorSplit, uint16 split, uint32 activatedAt) internal { + // If, the earlier 'new' split is activated, we update the 'old' split with the earlier 'new' split. + // Else, the earlier 'old' split remains the same. This is essentially resetting the activation delay window + // since the earlier split setting didn't complete. + if (block.timestamp >= operatorSplit.activatedAt) { + if (operatorSplit.activatedAt == 0) { + // If the operator split has not been initialized yet, set the old split to the default split. + operatorSplit.oldSplitBips = defaultOperatorSplitBips; + } else { + operatorSplit.oldSplitBips = operatorSplit.newSplitBips; + } + } + operatorSplit.newSplitBips = split; + operatorSplit.activatedAt = activatedAt; + } + + /** + * @notice Internal helper to get the operator split in basis points. + * @dev It takes default split and activation delay into account while calculating the split. + * @param operatorSplit The split struct for an Operator + * @return The split in basis points. + */ + function _getOperatorSplit(OperatorSplit memory operatorSplit) internal view returns (uint16) { + if (operatorSplit.activatedAt == 0) { + // Return the Default Operator Split if the operator split has not been initialized. + return defaultOperatorSplitBips; + } else { + // Return the new split if the new split has been activated, else return the old split. + return + (block.timestamp >= operatorSplit.activatedAt) + ? operatorSplit.newSplitBips + : operatorSplit.oldSplitBips; + } + } + /** * * VIEW FUNCTIONS @@ -477,8 +665,13 @@ contract RewardsCoordinator is } /// @inheritdoc IRewardsCoordinator - function operatorCommissionBips(address /* operator */, address /* avs */) external view returns (uint16) { - return globalOperatorCommissionBips; + function getOperatorAVSSplit(address operator, address avs) external view returns (uint16) { + return _getOperatorSplit(operatorAVSSplitBips[operator][avs]); + } + + /// @inheritdoc IRewardsCoordinator + function getOperatorPISplit(address operator) external view returns (uint16) { + return _getOperatorSplit(operatorPISplitBips[operator]); } /// @inheritdoc IRewardsCoordinator diff --git a/src/contracts/core/RewardsCoordinatorStorage.sol b/src/contracts/core/RewardsCoordinatorStorage.sol index ca30e0f18..0e27e9d84 100644 --- a/src/contracts/core/RewardsCoordinatorStorage.sol +++ b/src/contracts/core/RewardsCoordinatorStorage.sol @@ -57,15 +57,15 @@ abstract contract RewardsCoordinatorStorage is IRewardsCoordinator { */ DistributionRoot[] internal _distributionRoots; - /// Slot 3 + /// Slot 2 /// @notice The address of the entity that can update the contract with new merkle roots address public rewardsUpdater; /// @notice Delay in timestamp (seconds) before a posted root can be claimed against uint32 public activationDelay; /// @notice Timestamp for last submitted DistributionRoot uint32 public currRewardsCalculationEndTimestamp; - /// @notice the commission for all operators across all avss - uint16 public globalOperatorCommissionBips; + /// @notice the default split for all operators across all avss in bips. + uint16 public defaultOperatorSplitBips; /// @notice Mapping: earner => the address of the entity who can call `processClaim` on behalf of the earner mapping(address => address) public claimerFor; @@ -89,6 +89,15 @@ abstract contract RewardsCoordinatorStorage is IRewardsCoordinator { /// if rewards submission hash for all stakers and operators has been submitted mapping(address => mapping(bytes32 => bool)) public isRewardsSubmissionForAllEarnersHash; + /// @notice Mapping: avs => operatorDirectedAVSRewardsSubmissionHash => bool to check if operator-directed rewards submission hash has been submitted + mapping(address => mapping(bytes32 => bool)) public isOperatorDirectedAVSRewardsSubmissionHash; + + /// @notice Mapping: operator => avs => OperatorSplit. The split an operator takes for a specific AVS. + mapping(address => mapping(address => OperatorSplit)) internal operatorAVSSplitBips; + + /// @notice Mapping: operator => OperatorPISplit. The split an operator takes for Programmatic Incentives. + mapping(address => OperatorSplit) internal operatorPISplitBips; + constructor( IDelegationManager _delegationManager, IStrategyManager _strategyManager, @@ -120,5 +129,5 @@ abstract contract RewardsCoordinatorStorage is IRewardsCoordinator { * variables without shifting down storage in the inheritance chain. * See https://docs.openzeppelin.com/contracts/4.x/upgradeable#storage_gaps */ - uint256[40] private __gap; + uint256[37] private __gap; } diff --git a/src/contracts/interfaces/IRewardsCoordinator.sol b/src/contracts/interfaces/IRewardsCoordinator.sol index 933758618..ff6d3f6e7 100644 --- a/src/contracts/interfaces/IRewardsCoordinator.sol +++ b/src/contracts/interfaces/IRewardsCoordinator.sol @@ -26,6 +26,28 @@ interface IRewardsCoordinator { uint96 multiplier; } + /** + * @notice A reward struct for an operator + * @param operator The operator to be rewarded + * @param amount The reward amount for the operator + */ + struct OperatorReward { + address operator; + uint256 amount; + } + + /** + * @notice A split struct for an Operator + * @param oldSplitBips The old split in basis points. This is the split that is active if `block.timestamp < activatedAt` + * @param newSplitBips The new split in basis points. This is the split that is active if `block.timestamp >= activatedAt` + * @param activatedAt The timestamp at which the split will be activated + */ + struct OperatorSplit { + uint16 oldSplitBips; + uint16 newSplitBips; + uint32 activatedAt; + } + /** * Sliding Window for valid RewardsSubmission startTimestamp * @@ -60,6 +82,24 @@ interface IRewardsCoordinator { uint32 duration; } + /** + * @notice OperatorDirectedRewardsSubmission struct submitted by AVSs when making operator-directed rewards for their operators and stakers. + * @param strategiesAndMultipliers The strategies and their relative weights. + * @param token The rewards token to be distributed. + * @param operatorRewards The rewards for the operators. + * @param startTimestamp The timestamp (seconds) at which the submission range is considered for distribution. + * @param duration The duration of the submission range in seconds. + * @param description Describes what the rewards submission is for. + */ + struct OperatorDirectedRewardsSubmission { + StrategyAndMultiplier[] strategiesAndMultipliers; + IERC20 token; + OperatorReward[] operatorRewards; + uint32 startTimestamp; + uint32 duration; + string description; + } + /** * @notice A distribution root is a merkle root of the distribution of earnings for a given period. * The RewardsCoordinator stores all historical distribution roots so that earners can claim their earnings against older roots @@ -150,13 +190,67 @@ interface IRewardsCoordinator { bytes32 indexed rewardsSubmissionHash, RewardsSubmission rewardsSubmission ); + + /** + * @notice Emitted when an AVS creates a valid `OperatorDirectedRewardsSubmission` + * @param caller The address calling `createOperatorDirectedAVSRewardsSubmission`. + * @param avs The avs on behalf of which the operator-directed rewards are being submitted. + * @param operatorDirectedRewardsSubmissionHash Keccak256 hash of (`avs`, `submissionNonce` and `operatorDirectedRewardsSubmission`). + * @param submissionNonce Current nonce of the avs. Used to generate a unique submission hash. + * @param operatorDirectedRewardsSubmission The Operator-Directed Rewards Submission. Contains the token, start timestamp, duration, operator rewards, description and, strategy and multipliers. + */ + event OperatorDirectedAVSRewardsSubmissionCreated( + address indexed caller, + address indexed avs, + bytes32 indexed operatorDirectedRewardsSubmissionHash, + uint256 submissionNonce, + OperatorDirectedRewardsSubmission operatorDirectedRewardsSubmission + ); + /// @notice rewardsUpdater is responsible for submiting DistributionRoots, only owner can set rewardsUpdater event RewardsUpdaterSet(address indexed oldRewardsUpdater, address indexed newRewardsUpdater); event RewardsForAllSubmitterSet( - address indexed rewardsForAllSubmitter, bool indexed oldValue, bool indexed newValue + address indexed rewardsForAllSubmitter, + bool indexed oldValue, + bool indexed newValue ); event ActivationDelaySet(uint32 oldActivationDelay, uint32 newActivationDelay); - event GlobalCommissionBipsSet(uint16 oldGlobalCommissionBips, uint16 newGlobalCommissionBips); + event DefaultOperatorSplitBipsSet(uint16 oldDefaultOperatorSplitBips, uint16 newDefaultOperatorSplitBips); + + /** + * @notice Emitted when the operator split for an AVS is set. + * @param caller The address calling `setOperatorAVSSplit`. + * @param operator The operator on behalf of which the split is being set. + * @param avs The avs for which the split is being set by the operator. + * @param activatedAt The timestamp at which the split will be activated. + * @param oldOperatorAVSSplitBips The old split for the operator for the AVS. + * @param newOperatorAVSSplitBips The new split for the operator for the AVS. + */ + event OperatorAVSSplitBipsSet( + address indexed caller, + address indexed operator, + address indexed avs, + uint32 activatedAt, + uint16 oldOperatorAVSSplitBips, + uint16 newOperatorAVSSplitBips + ); + + /** + * @notice Emitted when the operator split for Programmatic Incentives is set. + * @param caller The address calling `setOperatorPISplit`. + * @param operator The operator on behalf of which the split is being set. + * @param activatedAt The timestamp at which the split will be activated. + * @param oldOperatorPISplitBips The old split for the operator for Programmatic Incentives. + * @param newOperatorPISplitBips The new split for the operator for Programmatic Incentives. + */ + event OperatorPISplitBipsSet( + address indexed caller, + address indexed operator, + uint32 activatedAt, + uint16 oldOperatorPISplitBips, + uint16 newOperatorPISplitBips + ); + event ClaimerForSet(address indexed earner, address indexed oldClaimer, address indexed claimer); /// @notice rootIndex is the specific array index of the newly created root in the storage array event DistributionRootSubmitted( @@ -212,12 +306,14 @@ interface IRewardsCoordinator { /// @notice Mapping: claimer => token => total amount claimed function cumulativeClaimed(address claimer, IERC20 token) external view returns (uint256); - /// @notice the commission for all operators across all avss - function globalOperatorCommissionBips() external view returns (uint16); + /// @notice the defautl split for all operators across all avss + function defaultOperatorSplitBips() external view returns (uint16); - /// @notice the commission for a specific operator for a specific avs - /// NOTE: Currently unused and simply returns the globalOperatorCommissionBips value but will be used in future release - function operatorCommissionBips(address operator, address avs) external view returns (uint16); + /// @notice the split for a specific `operator` for a specific `avs` + function getOperatorAVSSplit(address operator, address avs) external view returns (uint16); + + /// @notice the split for a specific `operator` for Programmatic Incentives + function getOperatorPISplit(address operator) external view returns (uint16); /// @notice return the hash of the earner's leaf function calculateEarnerLeafHash(EarnerTreeMerkleLeaf calldata leaf) external pure returns (bytes32); @@ -284,6 +380,24 @@ interface IRewardsCoordinator { */ function createRewardsForAllEarners(RewardsSubmission[] calldata rewardsSubmissions) external; + /** + * @notice Creates a new operator-directed rewards submission on behalf of an AVS, to be split amongst the operators and + * set of stakers delegated to operators who are registered to the `avs`. + * @param avs The AVS on behalf of which the reward is being submitted + * @param operatorDirectedRewardsSubmissions The operator-directed rewards submissions being created + * @dev Expected to be called by the ServiceManager of the AVS on behalf of which the submission is being made + * @dev The duration of the `rewardsSubmission` cannot exceed `MAX_REWARDS_DURATION` + * @dev The tokens are sent to the `RewardsCoordinator` contract + * @dev The `RewardsCoordinator` contract needs a token approval of sum of all `operatorRewards` in the `operatorDirectedRewardsSubmissions`, before calling this function. + * @dev Strategies must be in ascending order of addresses to check for duplicates + * @dev Operators must be in ascending order of addresses to check for duplicates. + * @dev This function will revert if the `operatorDirectedRewardsSubmissions` is malformed. + */ + function createOperatorDirectedAVSRewardsSubmission( + address avs, + OperatorDirectedRewardsSubmission[] calldata operatorDirectedRewardsSubmissions + ) external; + /** * @notice Claim rewards against a given root (read from _distributionRoots[claim.rootIndex]). * Earnings are cumulative so earners don't have to claim against all distribution roots they have earnings for, @@ -298,6 +412,20 @@ interface IRewardsCoordinator { */ function processClaim(RewardsMerkleClaim calldata claim, address recipient) external; + /** + * @notice Batch claim rewards against a given root (read from _distributionRoots[claim.rootIndex]). + * Earnings are cumulative so earners don't have to claim against all distribution roots they have earnings for, + * they can simply claim against the latest root and the contract will calculate the difference between + * their cumulativeEarnings and cumulativeClaimed. This difference is then transferred to recipient address. + * @param claims The RewardsMerkleClaims to be processed. + * Contains the root index, earner, token leaves, and required proofs + * @param recipient The address recipient that receives the ERC20 rewards + * @dev only callable by the valid claimer, that is + * if claimerFor[claim.earner] is address(0) then only the earner can claim, otherwise only + * claimerFor[claim.earner] can claim the rewards. + */ + function processClaims(RewardsMerkleClaim[] calldata claims, address recipient) external; + /** * @notice Creates a new distribution root. activatedAt is set to block.timestamp + activationDelay * @param root The merkle root of the distribution @@ -327,11 +455,32 @@ interface IRewardsCoordinator { function setActivationDelay(uint32 _activationDelay) external; /** - * @notice Sets the global commission for all operators across all avss - * @param _globalCommissionBips The commission for all operators across all avss - * @dev Only callable by the contract owner + * @notice Sets the default split for all operators across all avss. + * @param split The default split for all operators across all avss in bips. + * @dev Only callable by the contract owner. + */ + function setDefaultOperatorSplit(uint16 split) external; + + /** + * @notice Sets the split for a specific operator for a specific avs + * @param operator The operator who is setting the split + * @param avs The avs for which the split is being set by the operator + * @param split The split for the operator for the specific avs in bips. + * @dev Only callable by the operator + * @dev Split has to be between 0 and 10000 bips (inclusive) + * @dev The split will be activated after the activation delay + */ + function setOperatorAVSSplit(address operator, address avs, uint16 split) external; + + /** + * @notice Sets the split for a specific operator for Programmatic Incentives. + * @param operator The operator on behalf of which the split is being set. + * @param split The split for the operator for Programmatic Incentives in bips. + * @dev Only callable by the operator + * @dev Split has to be between 0 and 10000 bips (inclusive) + * @dev The split will be activated after the activation delay */ - function setGlobalOperatorCommission(uint16 _globalCommissionBips) external; + function setOperatorPISplit(address operator, uint16 split) external; /** * @notice Sets the permissioned `rewardsUpdater` address which can post new roots diff --git a/src/test/events/IRewardsCoordinatorEvents.sol b/src/test/events/IRewardsCoordinatorEvents.sol index 72832ae68..e4da12e6f 100644 --- a/src/test/events/IRewardsCoordinatorEvents.sol +++ b/src/test/events/IRewardsCoordinatorEvents.sol @@ -27,6 +27,21 @@ interface IRewardsCoordinatorEvents { bytes32 indexed rewardsSubmissionHash, IRewardsCoordinator.RewardsSubmission rewardsSubmission ); + /** + * @notice Emitted when an AVS creates a valid `OperatorDirectedRewardsSubmission` + * @param caller The address calling `createOperatorDirectedAVSRewardsSubmission`. + * @param avs The avs on behalf of which the operator-directed rewards are being submitted. + * @param operatorDirectedRewardsSubmissionHash Keccak256 hash of (`avs`, `submissionNonce` and `operatorDirectedRewardsSubmission`). + * @param submissionNonce Current nonce of the avs. Used to generate a unique submission hash. + * @param operatorDirectedRewardsSubmission The Operator-Directed Rewards Submission. Contains the token, start timestamp, duration, operator rewards, description and, strategy and multipliers. + */ + event OperatorDirectedAVSRewardsSubmissionCreated( + address indexed caller, + address indexed avs, + bytes32 indexed operatorDirectedRewardsSubmissionHash, + uint256 submissionNonce, + IRewardsCoordinator.OperatorDirectedRewardsSubmission operatorDirectedRewardsSubmission + ); /// @notice rewardsUpdater is responsible for submiting DistributionRoots, only owner can set rewardsUpdater event RewardsUpdaterSet(address indexed oldRewardsUpdater, address indexed newRewardsUpdater); event RewardsForAllSubmitterSet( @@ -35,7 +50,40 @@ interface IRewardsCoordinatorEvents { bool indexed newValue ); event ActivationDelaySet(uint32 oldActivationDelay, uint32 newActivationDelay); - event GlobalCommissionBipsSet(uint16 oldGlobalCommissionBips, uint16 newGlobalCommissionBips); + event DefaultOperatorSplitBipsSet(uint16 oldDefaultOperatorSplitBips, uint16 newDefaultOperatorSplitBips); + /** + * @notice Emitted when the operator split for an AVS is set. + * @param caller The address calling `setOperatorAVSSplit`. + * @param operator The operator on behalf of which the split is being set. + * @param avs The avs for which the split is being set by the operator. + * @param activatedAt The timestamp at which the split will be activated. + * @param oldOperatorAVSSplitBips The old split for the operator for the AVS. + * @param newOperatorAVSSplitBips The new split for the operator for the AVS. + */ + event OperatorAVSSplitBipsSet( + address indexed caller, + address indexed operator, + address indexed avs, + uint32 activatedAt, + uint16 oldOperatorAVSSplitBips, + uint16 newOperatorAVSSplitBips + ); + + /** + * @notice Emitted when the operator split for Programmatic Incentives is set. + * @param caller The address calling `setOperatorPISplit`. + * @param operator The operator on behalf of which the split is being set. + * @param activatedAt The timestamp at which the split will be activated. + * @param oldOperatorPISplitBips The old split for the operator for Programmatic Incentives. + * @param newOperatorPISplitBips The new split for the operator for Programmatic Incentives. + */ + event OperatorPISplitBipsSet( + address indexed caller, + address indexed operator, + uint32 activatedAt, + uint16 oldOperatorPISplitBips, + uint16 newOperatorPISplitBips + ); event ClaimerForSet(address indexed earner, address indexed oldClaimer, address indexed claimer); /// @notice rootIndex is the specific array index of the newly created root in the storage array event DistributionRootSubmitted( @@ -54,8 +102,6 @@ interface IRewardsCoordinatorEvents { uint256 claimedAmount ); - - /// TOKEN EVENTS FOR TESTING /// /** * @dev Emitted when `value` tokens are moved from one account (`from`) to diff --git a/src/test/unit/RewardsCoordinatorUnit.t.sol b/src/test/unit/RewardsCoordinatorUnit.t.sol index c23498a82..8f81f5996 100644 --- a/src/test/unit/RewardsCoordinatorUnit.t.sol +++ b/src/test/unit/RewardsCoordinatorUnit.t.sol @@ -54,11 +54,13 @@ contract RewardsCoordinatorUnitTests is EigenLayerUnitTestSetup, IRewardsCoordin uint32 MAX_FUTURE_LENGTH = 28 days; /// @notice absolute min timestamp that a rewards can start at uint32 GENESIS_REWARDS_TIMESTAMP = 1712188800; + /// @notice Equivalent to 100%, but in basis points. + uint16 internal constant ONE_HUNDRED_IN_BIPS = 10_000; /// @notice Delay in timestamp before a posted root can be claimed against uint32 activationDelay = 7 days; - /// @notice the commission for all operators across all avss - uint16 globalCommissionBips = 1000; + /// @notice the split for all operators across all avss + uint16 defaultSplitBips = 1000; IERC20[] rewardTokens; @@ -79,6 +81,15 @@ contract RewardsCoordinatorUnitTests is EigenLayerUnitTestSetup, IRewardsCoordin /// @dev Index for flag that pauses rewardAllStakersAndOperators uint8 internal constant PAUSED_REWARD_ALL_STAKERS_AND_OPERATORS = 4; + /// @dev Index for flag that pauses calling createOperatorDirectedAVSRewardsSubmission + uint8 internal constant PAUSED_OPERATOR_DIRECTED_AVS_REWARDS_SUBMISSION = 5; + + /// @dev Index for flag that pauses calling setOperatorAVSSplit + uint8 internal constant PAUSED_OPERATOR_AVS_SPLIT = 6; + + /// @dev Index for flag that pauses calling setOperatorPISplit + uint8 internal constant PAUSED_OPERATOR_PI_SPLIT = 7; + // RewardsCoordinator entities address rewardsUpdater = address(1000); address defaultAVS = address(1001); @@ -111,7 +122,7 @@ contract RewardsCoordinatorUnitTests is EigenLayerUnitTestSetup, IRewardsCoordin 0, // 0 is initialPausedStatus rewardsUpdater, activationDelay, - globalCommissionBips + defaultSplitBips ) ) ) @@ -204,7 +215,11 @@ contract RewardsCoordinatorUnitTests is EigenLayerUnitTestSetup, IRewardsCoordin return timestamp1 > timestamp2 ? timestamp1 : timestamp2; } - function _assertRewardsClaimedEvents(bytes32 root, IRewardsCoordinator.RewardsMerkleClaim memory claim, address recipient) internal { + function _assertRewardsClaimedEvents( + bytes32 root, + IRewardsCoordinator.RewardsMerkleClaim memory claim, + address recipient + ) internal { address earner = claim.earnerLeaf.earner; address claimer = rewardsCoordinator.claimerFor(earner); if (claimer == address(0)) { @@ -313,27 +328,23 @@ contract RewardsCoordinatorUnitTests_initializeAndSetters is RewardsCoordinatorU rewardsCoordinator.setActivationDelay(activationDelay); } - function testFuzz_setGlobalOperatorCommission(uint16 globalCommissionBips) public { + function testFuzz_setDefaultOperatorSplit(uint16 defaultSplitBips) public { cheats.startPrank(rewardsCoordinator.owner()); cheats.expectEmit(true, true, true, true, address(rewardsCoordinator)); - emit GlobalCommissionBipsSet(rewardsCoordinator.globalOperatorCommissionBips(), globalCommissionBips); - rewardsCoordinator.setGlobalOperatorCommission(globalCommissionBips); - assertEq( - globalCommissionBips, - rewardsCoordinator.globalOperatorCommissionBips(), - "globalOperatorCommissionBips not set" - ); + emit DefaultOperatorSplitBipsSet(rewardsCoordinator.defaultOperatorSplitBips(), defaultSplitBips); + rewardsCoordinator.setDefaultOperatorSplit(defaultSplitBips); + assertEq(defaultSplitBips, rewardsCoordinator.defaultOperatorSplitBips(), "defaultOperatorSplitBips not set"); cheats.stopPrank(); } - function testFuzz_setGlobalOperatorCommission_Revert_WhenNotOwner( + function testFuzz_setDefaultOperatorSplit_Revert_WhenNotOwner( address caller, - uint16 globalCommissionBips + uint16 defaultSplitBips ) public filterFuzzedAddressInputs(caller) { cheats.assume(caller != rewardsCoordinator.owner()); cheats.prank(caller); cheats.expectRevert("Ownable: caller is not the owner"); - rewardsCoordinator.setGlobalOperatorCommission(globalCommissionBips); + rewardsCoordinator.setDefaultOperatorSplit(defaultSplitBips); } function testFuzz_setRewardsUpdater(address newRewardsUpdater) public { @@ -360,11 +371,7 @@ contract RewardsCoordinatorUnitTests_initializeAndSetters is RewardsCoordinatorU cheats.expectEmit(true, true, true, true, address(rewardsCoordinator)); emit RewardsForAllSubmitterSet(submitter, rewardsCoordinator.isRewardsForAllSubmitter(submitter), newValue); rewardsCoordinator.setRewardsForAllSubmitter(submitter, newValue); - assertEq( - newValue, - rewardsCoordinator.isRewardsForAllSubmitter(submitter), - "isRewardsForAllSubmitter not set" - ); + assertEq(newValue, rewardsCoordinator.isRewardsForAllSubmitter(submitter), "isRewardsForAllSubmitter not set"); cheats.stopPrank(); } @@ -380,6 +387,297 @@ contract RewardsCoordinatorUnitTests_initializeAndSetters is RewardsCoordinatorU } } +contract RewardsCoordinatorUnitTests_setOperatorAVSSplit is RewardsCoordinatorUnitTests { + // Revert when paused + function testFuzz_Revert_WhenPaused( + address operator, + address avs, + uint16 split + ) public filterFuzzedAddressInputs(operator) { + cheats.assume(operator != address(0)); + split = uint16(bound(split, 0, ONE_HUNDRED_IN_BIPS)); + cheats.prank(pauser); + rewardsCoordinator.pause(2 ** PAUSED_OPERATOR_AVS_SPLIT); + + cheats.prank(operator); + cheats.expectRevert("Pausable: index is paused"); + rewardsCoordinator.setOperatorAVSSplit(operator, avs, split); + } + + // Revert when operator is not caller + function testFuzz_Revert_WhenOperatorIsNotMsgSender( + address operator, + address avs, + uint16 split + ) public filterFuzzedAddressInputs(operator) { + cheats.assume(operator != address(0) && operator != address(this)); + split = uint16(bound(split, 0, ONE_HUNDRED_IN_BIPS)); + + cheats.expectRevert("RewardsCoordinator.setOperatorAVSSplit: caller is not the operator"); + rewardsCoordinator.setOperatorAVSSplit(operator, avs, split); + } + + // Revert when split is greater than 100% + function testFuzz_Revert_WhenSplitGreaterThan100( + address operator, + address avs, + uint16 split + ) public filterFuzzedAddressInputs(operator) { + cheats.assume(operator != address(0)); + split = uint16(bound(split, ONE_HUNDRED_IN_BIPS + 1, type(uint16).max)); + + cheats.prank(operator); + cheats.expectRevert("RewardsCoordinator.setOperatorAVSSplit: split must be <= 10000 bips"); + rewardsCoordinator.setOperatorAVSSplit(operator, avs, split); + } + + function testFuzz_setOperatorAVSSplit( + address operator, + address avs, + uint16 split + ) public filterFuzzedAddressInputs(operator) { + cheats.assume(operator != address(0)); + split = uint16(bound(split, 0, ONE_HUNDRED_IN_BIPS)); + uint32 activatedAt = uint32(block.timestamp) + activationDelay; + uint16 oldSplit = rewardsCoordinator.getOperatorAVSSplit(operator, avs); + + cheats.expectEmit(true, true, true, true, address(rewardsCoordinator)); + emit OperatorAVSSplitBipsSet(operator, operator, avs, activatedAt, oldSplit, split); + cheats.prank(operator); + rewardsCoordinator.setOperatorAVSSplit(operator, avs, split); + + assertEq(oldSplit, rewardsCoordinator.getOperatorAVSSplit(operator, avs), "Incorrect Operator split"); + cheats.warp(activatedAt); + assertEq(split, rewardsCoordinator.getOperatorAVSSplit(operator, avs), "Incorrect Operator split"); + } + + // Testing that the split has been initialized for the first time. + function testFuzz_setOperatorAVSSplitFirstTime( + address operator, + address avs, + uint16 split + ) public filterFuzzedAddressInputs(operator) { + cheats.assume(operator != address(0)); + split = uint16(bound(split, 0, ONE_HUNDRED_IN_BIPS)); + uint32 activatedAt = uint32(block.timestamp) + activationDelay; + uint16 oldSplit = rewardsCoordinator.getOperatorAVSSplit(operator, avs); + assertEq(oldSplit, defaultSplitBips, "Operator split is not Default split before Initialization"); + + cheats.expectEmit(true, true, true, true, address(rewardsCoordinator)); + emit OperatorAVSSplitBipsSet(operator, operator, avs, activatedAt, oldSplit, split); + cheats.prank(operator); + rewardsCoordinator.setOperatorAVSSplit(operator, avs, split); + + assertEq(oldSplit, rewardsCoordinator.getOperatorAVSSplit(operator, avs), "Incorrect Operator split"); + cheats.warp(activatedAt); + assertEq(split, rewardsCoordinator.getOperatorAVSSplit(operator, avs), "Incorrect Operator split"); + } + + // Testing the split setting for a second time prior to the earlier activation. + function testFuzz_setOperatorAVSSplitSecondTimeBeforePriorActivation( + address operator, + address avs, + uint16 firstSplit, + uint16 secondSplit, + uint32 warpTime + ) public filterFuzzedAddressInputs(operator) { + cheats.assume(operator != address(0)); + firstSplit = uint16(bound(firstSplit, 0, ONE_HUNDRED_IN_BIPS)); + secondSplit = uint16(bound(secondSplit, 0, ONE_HUNDRED_IN_BIPS)); + warpTime = uint32(bound(warpTime, uint32(block.timestamp), uint32(block.timestamp) + activationDelay - 1)); + uint16 oldSplit = rewardsCoordinator.getOperatorAVSSplit(operator, avs); + + // Setting First Split + cheats.prank(operator); + rewardsCoordinator.setOperatorAVSSplit(operator, avs, firstSplit); + // Warping to time before activation of First split + cheats.warp(warpTime); + uint32 activatedAt = uint32(block.timestamp) + activationDelay; + + // Setting Second Split + cheats.expectEmit(true, true, true, true, address(rewardsCoordinator)); + emit OperatorAVSSplitBipsSet(operator, operator, avs, activatedAt, oldSplit, secondSplit); + cheats.prank(operator); + rewardsCoordinator.setOperatorAVSSplit(operator, avs, secondSplit); + + assertEq(oldSplit, rewardsCoordinator.getOperatorAVSSplit(operator, avs), "Incorrect Operator split"); + cheats.warp(activatedAt); + assertEq(secondSplit, rewardsCoordinator.getOperatorAVSSplit(operator, avs), "Incorrect Operator split"); + } + + // Testing the split setting for a second time after earlier activation. + function testFuzz_setOperatorAVSSplitSecondTimeAfterPriorActivation( + address operator, + address avs, + uint16 firstSplit, + uint16 secondSplit, + uint32 warpTime + ) public filterFuzzedAddressInputs(operator) { + cheats.assume(operator != address(0)); + firstSplit = uint16(bound(firstSplit, 0, ONE_HUNDRED_IN_BIPS)); + secondSplit = uint16(bound(secondSplit, 0, ONE_HUNDRED_IN_BIPS)); + warpTime = uint32( + bound(warpTime, uint32(block.timestamp) + activationDelay, type(uint32).max - activationDelay) + ); + + // Setting First Split + cheats.prank(operator); + rewardsCoordinator.setOperatorAVSSplit(operator, avs, firstSplit); + // Warping to time after activation of First split + cheats.warp(warpTime); + uint32 activatedAt = uint32(block.timestamp) + activationDelay; + + // Setting Second Split + cheats.expectEmit(true, true, true, true, address(rewardsCoordinator)); + emit OperatorAVSSplitBipsSet(operator, operator, avs, activatedAt, firstSplit, secondSplit); + cheats.prank(operator); + rewardsCoordinator.setOperatorAVSSplit(operator, avs, secondSplit); + + assertEq(firstSplit, rewardsCoordinator.getOperatorAVSSplit(operator, avs), "Incorrect Operator split"); + cheats.warp(activatedAt); + assertEq(secondSplit, rewardsCoordinator.getOperatorAVSSplit(operator, avs), "Incorrect Operator split"); + } +} + +contract RewardsCoordinatorUnitTests_setOperatorPISplit is RewardsCoordinatorUnitTests { + // Revert when paused + function testFuzz_Revert_WhenPaused(address operator, uint16 split) public filterFuzzedAddressInputs(operator) { + cheats.assume(operator != address(0)); + split = uint16(bound(split, 0, ONE_HUNDRED_IN_BIPS)); + cheats.prank(pauser); + rewardsCoordinator.pause(2 ** PAUSED_OPERATOR_PI_SPLIT); + + cheats.prank(operator); + cheats.expectRevert("Pausable: index is paused"); + rewardsCoordinator.setOperatorPISplit(operator, split); + } + + // Revert when operator is not caller + function testFuzz_Revert_WhenOperatorIsNotMsgSender( + address operator, + uint16 split + ) public filterFuzzedAddressInputs(operator) { + cheats.assume(operator != address(0) && operator != address(this)); + split = uint16(bound(split, 0, ONE_HUNDRED_IN_BIPS)); + + cheats.expectRevert("RewardsCoordinator.setOperatorPISplit: caller is not the operator"); + rewardsCoordinator.setOperatorPISplit(operator, split); + } + + // Revert when split is greater than 100% + function testFuzz_Revert_WhenSplitGreaterThan100( + address operator, + uint16 split + ) public filterFuzzedAddressInputs(operator) { + cheats.assume(operator != address(0)); + split = uint16(bound(split, ONE_HUNDRED_IN_BIPS + 1, type(uint16).max)); + + cheats.prank(operator); + cheats.expectRevert("RewardsCoordinator.setOperatorPISplit: split must be <= 10000 bips"); + rewardsCoordinator.setOperatorPISplit(operator, split); + } + + function testFuzz_setOperatorAVSSplit(address operator, uint16 split) public filterFuzzedAddressInputs(operator) { + cheats.assume(operator != address(0)); + split = uint16(bound(split, 0, ONE_HUNDRED_IN_BIPS)); + uint32 activatedAt = uint32(block.timestamp) + activationDelay; + uint16 oldSplit = rewardsCoordinator.getOperatorPISplit(operator); + + cheats.expectEmit(true, true, true, true, address(rewardsCoordinator)); + emit OperatorPISplitBipsSet(operator, operator, activatedAt, oldSplit, split); + cheats.prank(operator); + rewardsCoordinator.setOperatorPISplit(operator, split); + + assertEq(oldSplit, rewardsCoordinator.getOperatorPISplit(operator), "Incorrect Operator split"); + cheats.warp(activatedAt); + assertEq(split, rewardsCoordinator.getOperatorPISplit(operator), "Incorrect Operator split"); + } + + // Testing that the split has been initialized for the first time. + function testFuzz_setOperatorAVSSplitFirstTime( + address operator, + uint16 split + ) public filterFuzzedAddressInputs(operator) { + cheats.assume(operator != address(0)); + split = uint16(bound(split, 0, ONE_HUNDRED_IN_BIPS)); + uint32 activatedAt = uint32(block.timestamp) + activationDelay; + uint16 oldSplit = rewardsCoordinator.getOperatorPISplit(operator); + assertEq(oldSplit, defaultSplitBips, "Operator split is not Default split before Initialization"); + + cheats.expectEmit(true, true, true, true, address(rewardsCoordinator)); + emit OperatorPISplitBipsSet(operator, operator, activatedAt, oldSplit, split); + cheats.prank(operator); + rewardsCoordinator.setOperatorPISplit(operator, split); + + assertEq(oldSplit, rewardsCoordinator.getOperatorPISplit(operator), "Incorrect Operator split"); + cheats.warp(activatedAt); + assertEq(split, rewardsCoordinator.getOperatorPISplit(operator), "Incorrect Operator split"); + } + + // Testing the split setting for a second time prior to the earlier activation. + function testFuzz_setOperatorAVSSplitSecondTimeBeforePriorActivation( + address operator, + uint16 firstSplit, + uint16 secondSplit, + uint32 warpTime + ) public filterFuzzedAddressInputs(operator) { + cheats.assume(operator != address(0)); + firstSplit = uint16(bound(firstSplit, 0, ONE_HUNDRED_IN_BIPS)); + secondSplit = uint16(bound(secondSplit, 0, ONE_HUNDRED_IN_BIPS)); + warpTime = uint32(bound(warpTime, uint32(block.timestamp), uint32(block.timestamp) + activationDelay - 1)); + uint16 oldSplit = rewardsCoordinator.getOperatorPISplit(operator); + + // Setting First Split + cheats.prank(operator); + rewardsCoordinator.setOperatorPISplit(operator, firstSplit); + // Warping to time before activation of First split + cheats.warp(warpTime); + uint32 activatedAt = uint32(block.timestamp) + activationDelay; + + // Setting Second Split + cheats.expectEmit(true, true, true, true, address(rewardsCoordinator)); + emit OperatorPISplitBipsSet(operator, operator, activatedAt, oldSplit, secondSplit); + cheats.prank(operator); + rewardsCoordinator.setOperatorPISplit(operator, secondSplit); + + assertEq(oldSplit, rewardsCoordinator.getOperatorPISplit(operator), "Incorrect Operator split"); + cheats.warp(activatedAt); + assertEq(secondSplit, rewardsCoordinator.getOperatorPISplit(operator), "Incorrect Operator split"); + } + + // Testing the split setting for a second time after earlier activation. + function testFuzz_setOperatorAVSSplitSecondTimeAfterPriorActivation( + address operator, + uint16 firstSplit, + uint16 secondSplit, + uint32 warpTime + ) public filterFuzzedAddressInputs(operator) { + cheats.assume(operator != address(0)); + firstSplit = uint16(bound(firstSplit, 0, ONE_HUNDRED_IN_BIPS)); + secondSplit = uint16(bound(secondSplit, 0, ONE_HUNDRED_IN_BIPS)); + warpTime = uint32( + bound(warpTime, uint32(block.timestamp) + activationDelay, type(uint32).max - activationDelay) + ); + + // Setting First Split + cheats.prank(operator); + rewardsCoordinator.setOperatorPISplit(operator, firstSplit); + // Warping to time after activation of First split + cheats.warp(warpTime); + uint32 activatedAt = uint32(block.timestamp) + activationDelay; + + // Setting Second Split + cheats.expectEmit(true, true, true, true, address(rewardsCoordinator)); + emit OperatorPISplitBipsSet(operator, operator, activatedAt, firstSplit, secondSplit); + cheats.prank(operator); + rewardsCoordinator.setOperatorPISplit(operator, secondSplit); + + assertEq(firstSplit, rewardsCoordinator.getOperatorPISplit(operator), "Incorrect Operator split"); + cheats.warp(activatedAt); + assertEq(secondSplit, rewardsCoordinator.getOperatorPISplit(operator), "Incorrect Operator split"); + } +} + contract RewardsCoordinatorUnitTests_createAVSRewardsSubmission is RewardsCoordinatorUnitTests { // Revert when paused function test_Revert_WhenPaused() public { @@ -393,7 +691,7 @@ contract RewardsCoordinatorUnitTests_createAVSRewardsSubmission is RewardsCoordi // Revert from reentrancy function test_Revert_WhenReentrancy(uint256 amount) public { - amount = bound(amount, 1, 1e38-1); + amount = bound(amount, 1, 1e38 - 1); Reenterer reenterer = new Reenterer(); reenterer.prepareReturnData(abi.encode(amount)); @@ -403,7 +701,9 @@ contract RewardsCoordinatorUnitTests_createAVSRewardsSubmission is RewardsCoordi _deployMockRewardTokens(address(this), 1); - IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[](1); + IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[]( + 1 + ); rewardsSubmissions[0] = IRewardsCoordinator.RewardsSubmission({ strategiesAndMultipliers: defaultStrategyAndMultipliers, token: IERC20(address(reenterer)), @@ -412,7 +712,10 @@ contract RewardsCoordinatorUnitTests_createAVSRewardsSubmission is RewardsCoordi duration: 0 }); - bytes memory calldataToUse = abi.encodeWithSelector(RewardsCoordinator.createAVSRewardsSubmission.selector, rewardsSubmissions); + bytes memory calldataToUse = abi.encodeWithSelector( + RewardsCoordinator.createAVSRewardsSubmission.selector, + rewardsSubmissions + ); reenterer.prepare(targetToUse, msgValueToUse, calldataToUse, bytes("ReentrancyGuard: reentrant call")); cheats.expectRevert(); @@ -444,7 +747,9 @@ contract RewardsCoordinatorUnitTests_createAVSRewardsSubmission is RewardsCoordi startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); // 2. Create rewards submission input param - IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[](1); + IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[]( + 1 + ); IRewardsCoordinator.StrategyAndMultiplier[] memory emptyStratsAndMultipliers; rewardsSubmissions[0] = IRewardsCoordinator.RewardsSubmission({ strategiesAndMultipliers: emptyStratsAndMultipliers, @@ -456,7 +761,7 @@ contract RewardsCoordinatorUnitTests_createAVSRewardsSubmission is RewardsCoordi // 3. call createAVSRewardsSubmission() with expected revert cheats.prank(avs); - cheats.expectRevert("RewardsCoordinator._validateRewardsSubmission: no strategies set"); + cheats.expectRevert("RewardsCoordinator._validateCommonRewardsSubmission: no strategies set"); rewardsCoordinator.createAVSRewardsSubmission(rewardsSubmissions); } @@ -482,7 +787,9 @@ contract RewardsCoordinatorUnitTests_createAVSRewardsSubmission is RewardsCoordi startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); // 2. Create rewards submission input param - IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[](1); + IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[]( + 1 + ); rewardsSubmissions[0] = IRewardsCoordinator.RewardsSubmission({ strategiesAndMultipliers: defaultStrategyAndMultipliers, token: rewardToken, @@ -518,7 +825,9 @@ contract RewardsCoordinatorUnitTests_createAVSRewardsSubmission is RewardsCoordi startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); // 2. Create rewards submission input param - IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[](1); + IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[]( + 1 + ); IRewardsCoordinator.StrategyAndMultiplier[] memory dupStratsAndMultipliers = new IRewardsCoordinator.StrategyAndMultiplier[](2); dupStratsAndMultipliers[0] = defaultStrategyAndMultipliers[0]; @@ -534,7 +843,7 @@ contract RewardsCoordinatorUnitTests_createAVSRewardsSubmission is RewardsCoordi // 3. call createAVSRewardsSubmission() with expected revert cheats.prank(avs); cheats.expectRevert( - "RewardsCoordinator._validateRewardsSubmission: strategies must be in ascending order to handle duplicates" + "RewardsCoordinator._validateCommonRewardsSubmission: strategies must be in ascending order to handle duplicates" ); rewardsCoordinator.createAVSRewardsSubmission(rewardsSubmissions); } @@ -563,7 +872,9 @@ contract RewardsCoordinatorUnitTests_createAVSRewardsSubmission is RewardsCoordi startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); // 2. Create rewards submission input param - IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[](1); + IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[]( + 1 + ); rewardsSubmissions[0] = IRewardsCoordinator.RewardsSubmission({ strategiesAndMultipliers: defaultStrategyAndMultipliers, token: rewardToken, @@ -574,7 +885,9 @@ contract RewardsCoordinatorUnitTests_createAVSRewardsSubmission is RewardsCoordi // 3. call createAVSRewardsSubmission() with expected revert cheats.prank(avs); - cheats.expectRevert("RewardsCoordinator._validateRewardsSubmission: duration exceeds MAX_REWARDS_DURATION"); + cheats.expectRevert( + "RewardsCoordinator._validateCommonRewardsSubmission: duration exceeds MAX_REWARDS_DURATION" + ); rewardsCoordinator.createAVSRewardsSubmission(rewardsSubmissions); } @@ -603,7 +916,9 @@ contract RewardsCoordinatorUnitTests_createAVSRewardsSubmission is RewardsCoordi startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); // 2. Create rewards submission input param - IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[](1); + IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[]( + 1 + ); rewardsSubmissions[0] = IRewardsCoordinator.RewardsSubmission({ strategiesAndMultipliers: defaultStrategyAndMultipliers, token: rewardToken, @@ -615,7 +930,7 @@ contract RewardsCoordinatorUnitTests_createAVSRewardsSubmission is RewardsCoordi // 3. call createAVSRewardsSubmission() with expected revert cheats.prank(avs); cheats.expectRevert( - "RewardsCoordinator._validateRewardsSubmission: duration must be a multiple of CALCULATION_INTERVAL_SECONDS" + "RewardsCoordinator._validateCommonRewardsSubmission: duration must be a multiple of CALCULATION_INTERVAL_SECONDS" ); rewardsCoordinator.createAVSRewardsSubmission(rewardsSubmissions); } @@ -649,7 +964,9 @@ contract RewardsCoordinatorUnitTests_createAVSRewardsSubmission is RewardsCoordi startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); // 2. Create rewards submission input param - IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[](1); + IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[]( + 1 + ); rewardsSubmissions[0] = IRewardsCoordinator.RewardsSubmission({ strategiesAndMultipliers: defaultStrategyAndMultipliers, token: rewardToken, @@ -660,7 +977,7 @@ contract RewardsCoordinatorUnitTests_createAVSRewardsSubmission is RewardsCoordi // 3. call createAVSRewardsSubmission() with expected revert cheats.prank(avs); - cheats.expectRevert("RewardsCoordinator._validateRewardsSubmission: startTimestamp too far in the past"); + cheats.expectRevert("RewardsCoordinator._validateCommonRewardsSubmission: startTimestamp too far in the past"); rewardsCoordinator.createAVSRewardsSubmission(rewardsSubmissions); } @@ -687,7 +1004,9 @@ contract RewardsCoordinatorUnitTests_createAVSRewardsSubmission is RewardsCoordi startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); // 2. Create rewards submission input param - IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[](1); + IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[]( + 1 + ); rewardsSubmissions[0] = IRewardsCoordinator.RewardsSubmission({ strategiesAndMultipliers: defaultStrategyAndMultipliers, token: rewardToken, @@ -727,7 +1046,9 @@ contract RewardsCoordinatorUnitTests_createAVSRewardsSubmission is RewardsCoordi startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); // 2. Create rewards submission input param - IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[](1); + IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[]( + 1 + ); defaultStrategyAndMultipliers[0].strategy = IStrategy(address(999)); rewardsSubmissions[0] = IRewardsCoordinator.RewardsSubmission({ strategiesAndMultipliers: defaultStrategyAndMultipliers, @@ -739,7 +1060,7 @@ contract RewardsCoordinatorUnitTests_createAVSRewardsSubmission is RewardsCoordi // 3. call createAVSRewardsSubmission() with expected event emitted cheats.prank(avs); - cheats.expectRevert("RewardsCoordinator._validateRewardsSubmission: invalid strategy considered"); + cheats.expectRevert("RewardsCoordinator._validateCommonRewardsSubmission: invalid strategy considered"); rewardsCoordinator.createAVSRewardsSubmission(rewardsSubmissions); } @@ -774,7 +1095,9 @@ contract RewardsCoordinatorUnitTests_createAVSRewardsSubmission is RewardsCoordi startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); // 2. Create rewards submission input param - IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[](1); + IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[]( + 1 + ); rewardsSubmissions[0] = IRewardsCoordinator.RewardsSubmission({ strategiesAndMultipliers: defaultStrategyAndMultipliers, token: rewardToken, @@ -797,7 +1120,10 @@ contract RewardsCoordinatorUnitTests_createAVSRewardsSubmission is RewardsCoordi rewardsCoordinator.createAVSRewardsSubmission(rewardsSubmissions); cheats.stopPrank(); - assertTrue(rewardsCoordinator.isAVSRewardsSubmissionHash(avs, rewardsSubmissionHash), "rewards submission hash not submitted"); + assertTrue( + rewardsCoordinator.isAVSRewardsSubmissionHash(avs, rewardsSubmissionHash), + "rewards submission hash not submitted" + ); assertEq(currSubmissionNonce + 1, rewardsCoordinator.submissionNonce(avs), "submission nonce not incremented"); assertEq( avsBalanceBefore - amount, @@ -826,7 +1152,9 @@ contract RewardsCoordinatorUnitTests_createAVSRewardsSubmission is RewardsCoordi cheats.assume(param.avs != address(0)); cheats.prank(rewardsCoordinator.owner()); - IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[](numSubmissions); + IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[]( + numSubmissions + ); bytes32[] memory rewardsSubmissionHashes = new bytes32[](numSubmissions); uint256 startSubmissionNonce = rewardsCoordinator.submissionNonce(param.avs); _deployMockRewardTokens(param.avs, numSubmissions); @@ -865,9 +1193,16 @@ contract RewardsCoordinatorUnitTests_createAVSRewardsSubmission is RewardsCoordi rewardsSubmissions[i] = rewardsSubmission; // 3. expected event emitted for this rewardsSubmission - rewardsSubmissionHashes[i] = keccak256(abi.encode(param.avs, startSubmissionNonce + i, rewardsSubmissions[i])); + rewardsSubmissionHashes[i] = keccak256( + abi.encode(param.avs, startSubmissionNonce + i, rewardsSubmissions[i]) + ); cheats.expectEmit(true, true, true, true, address(rewardsCoordinator)); - emit AVSRewardsSubmissionCreated(param.avs, startSubmissionNonce + i, rewardsSubmissionHashes[i], rewardsSubmissions[i]); + emit AVSRewardsSubmissionCreated( + param.avs, + startSubmissionNonce + i, + rewardsSubmissionHashes[i], + rewardsSubmissions[i] + ); } // 4. call createAVSRewardsSubmission() @@ -922,7 +1257,9 @@ contract RewardsCoordinatorUnitTests_createRewardsForAllSubmission is RewardsCoo _deployMockRewardTokens(address(this), 1); - IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[](1); + IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[]( + 1 + ); rewardsSubmissions[0] = IRewardsCoordinator.RewardsSubmission({ strategiesAndMultipliers: defaultStrategyAndMultipliers, token: IERC20(address(reenterer)), @@ -931,7 +1268,10 @@ contract RewardsCoordinatorUnitTests_createRewardsForAllSubmission is RewardsCoo duration: 0 }); - bytes memory calldataToUse = abi.encodeWithSelector(RewardsCoordinator.createAVSRewardsSubmission.selector, rewardsSubmissions); + bytes memory calldataToUse = abi.encodeWithSelector( + RewardsCoordinator.createAVSRewardsSubmission.selector, + rewardsSubmissions + ); reenterer.prepare(targetToUse, msgValueToUse, calldataToUse, bytes("ReentrancyGuard: reentrant call")); cheats.prank(rewardsForAllSubmitter); @@ -956,7 +1296,11 @@ contract RewardsCoordinatorUnitTests_createRewardsForAllSubmission is RewardsCoo * - rewards submission hash being set in storage * - token balance before and after of RewardsForAllSubmitter and rewardsCoordinator */ - function testFuzz_createRewardsForAllSubmission_SingleSubmission(uint256 startTimestamp, uint256 duration, uint256 amount) public { + function testFuzz_createRewardsForAllSubmission_SingleSubmission( + uint256 startTimestamp, + uint256 duration, + uint256 amount + ) public { cheats.prank(rewardsCoordinator.owner()); // 1. Bound fuzz inputs to valid ranges and amounts @@ -979,7 +1323,9 @@ contract RewardsCoordinatorUnitTests_createRewardsForAllSubmission is RewardsCoo startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); // 2. Create rewards submission input param - IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[](1); + IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[]( + 1 + ); rewardsSubmissions[0] = IRewardsCoordinator.RewardsSubmission({ strategiesAndMultipliers: defaultStrategyAndMultipliers, token: rewardToken, @@ -995,10 +1341,17 @@ contract RewardsCoordinatorUnitTests_createRewardsForAllSubmission is RewardsCoo cheats.startPrank(rewardsForAllSubmitter); rewardToken.approve(address(rewardsCoordinator), amount); uint256 currSubmissionNonce = rewardsCoordinator.submissionNonce(rewardsForAllSubmitter); - bytes32 rewardsSubmissionHash = keccak256(abi.encode(rewardsForAllSubmitter, currSubmissionNonce, rewardsSubmissions[0])); + bytes32 rewardsSubmissionHash = keccak256( + abi.encode(rewardsForAllSubmitter, currSubmissionNonce, rewardsSubmissions[0]) + ); cheats.expectEmit(true, true, true, true, address(rewardsCoordinator)); - emit RewardsSubmissionForAllCreated(rewardsForAllSubmitter, currSubmissionNonce, rewardsSubmissionHash, rewardsSubmissions[0]); + emit RewardsSubmissionForAllCreated( + rewardsForAllSubmitter, + currSubmissionNonce, + rewardsSubmissionHash, + rewardsSubmissions[0] + ); rewardsCoordinator.createRewardsForAllSubmission(rewardsSubmissions); cheats.stopPrank(); @@ -1030,11 +1383,16 @@ contract RewardsCoordinatorUnitTests_createRewardsForAllSubmission is RewardsCoo * - rewards submission hash being set in storage * - token balances before and after of createRewardsForAllSubmission submitter and rewardsCoordinator */ - function testFuzz_createRewardsForAllSubmission_MultipleSubmissions(FuzzAVSRewardsSubmission memory param, uint256 numSubmissions) public { + function testFuzz_createRewardsForAllSubmission_MultipleSubmissions( + FuzzAVSRewardsSubmission memory param, + uint256 numSubmissions + ) public { cheats.assume(2 <= numSubmissions && numSubmissions <= 10); cheats.prank(rewardsCoordinator.owner()); - IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[](numSubmissions); + IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[]( + numSubmissions + ); bytes32[] memory rewardsSubmissionHashes = new bytes32[](numSubmissions); uint256 startSubmissionNonce = rewardsCoordinator.submissionNonce(rewardsForAllSubmitter); _deployMockRewardTokens(rewardsForAllSubmitter, numSubmissions); @@ -1073,7 +1431,9 @@ contract RewardsCoordinatorUnitTests_createRewardsForAllSubmission is RewardsCoo rewardsSubmissions[i] = rewardsSubmission; // 3. expected event emitted for this rewardsSubmission - rewardsSubmissionHashes[i] = keccak256(abi.encode(rewardsForAllSubmitter, startSubmissionNonce + i, rewardsSubmissions[i])); + rewardsSubmissionHashes[i] = keccak256( + abi.encode(rewardsForAllSubmitter, startSubmissionNonce + i, rewardsSubmissions[i]) + ); cheats.expectEmit(true, true, true, true, address(rewardsCoordinator)); emit RewardsSubmissionForAllCreated( rewardsForAllSubmitter, @@ -1135,7 +1495,9 @@ contract RewardsCoordinatorUnitTests_createRewardsForAllEarners is RewardsCoordi _deployMockRewardTokens(address(this), 1); - IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[](1); + IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[]( + 1 + ); rewardsSubmissions[0] = IRewardsCoordinator.RewardsSubmission({ strategiesAndMultipliers: defaultStrategyAndMultipliers, token: IERC20(address(reenterer)), @@ -1144,7 +1506,10 @@ contract RewardsCoordinatorUnitTests_createRewardsForAllEarners is RewardsCoordi duration: 0 }); - bytes memory calldataToUse = abi.encodeWithSelector(RewardsCoordinator.createAVSRewardsSubmission.selector, rewardsSubmissions); + bytes memory calldataToUse = abi.encodeWithSelector( + RewardsCoordinator.createAVSRewardsSubmission.selector, + rewardsSubmissions + ); reenterer.prepare(targetToUse, msgValueToUse, calldataToUse, bytes("ReentrancyGuard: reentrant call")); cheats.prank(rewardsForAllSubmitter); @@ -1169,7 +1534,11 @@ contract RewardsCoordinatorUnitTests_createRewardsForAllEarners is RewardsCoordi * - rewards submission hash being set in storage * - token balance before and after of RewardsForAllSubmitter and rewardsCoordinator */ - function testFuzz_createRewardsForAllSubmission_SingleSubmission(uint256 startTimestamp, uint256 duration, uint256 amount) public { + function testFuzz_createRewardsForAllSubmission_SingleSubmission( + uint256 startTimestamp, + uint256 duration, + uint256 amount + ) public { cheats.prank(rewardsCoordinator.owner()); // 1. Bound fuzz inputs to valid ranges and amounts @@ -1192,7 +1561,9 @@ contract RewardsCoordinatorUnitTests_createRewardsForAllEarners is RewardsCoordi startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); // 2. Create rewards submission input param - IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[](1); + IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[]( + 1 + ); rewardsSubmissions[0] = IRewardsCoordinator.RewardsSubmission({ strategiesAndMultipliers: defaultStrategyAndMultipliers, token: rewardToken, @@ -1208,10 +1579,17 @@ contract RewardsCoordinatorUnitTests_createRewardsForAllEarners is RewardsCoordi cheats.startPrank(rewardsForAllSubmitter); rewardToken.approve(address(rewardsCoordinator), amount); uint256 currSubmissionNonce = rewardsCoordinator.submissionNonce(rewardsForAllSubmitter); - bytes32 rewardsSubmissionHash = keccak256(abi.encode(rewardsForAllSubmitter, currSubmissionNonce, rewardsSubmissions[0])); + bytes32 rewardsSubmissionHash = keccak256( + abi.encode(rewardsForAllSubmitter, currSubmissionNonce, rewardsSubmissions[0]) + ); cheats.expectEmit(true, true, true, true, address(rewardsCoordinator)); - emit RewardsSubmissionForAllEarnersCreated(rewardsForAllSubmitter, currSubmissionNonce, rewardsSubmissionHash, rewardsSubmissions[0]); + emit RewardsSubmissionForAllEarnersCreated( + rewardsForAllSubmitter, + currSubmissionNonce, + rewardsSubmissionHash, + rewardsSubmissions[0] + ); rewardsCoordinator.createRewardsForAllEarners(rewardsSubmissions); cheats.stopPrank(); @@ -1243,11 +1621,16 @@ contract RewardsCoordinatorUnitTests_createRewardsForAllEarners is RewardsCoordi * - rewards submission hash being set in storage * - token balances before and after of createRewardsForAllSubmission submitter and rewardsCoordinator */ - function testFuzz_createRewardsForAllSubmission_MultipleSubmissions(FuzzAVSRewardsSubmission memory param, uint256 numSubmissions) public { + function testFuzz_createRewardsForAllSubmission_MultipleSubmissions( + FuzzAVSRewardsSubmission memory param, + uint256 numSubmissions + ) public { cheats.assume(2 <= numSubmissions && numSubmissions <= 10); cheats.prank(rewardsCoordinator.owner()); - IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[](numSubmissions); + IRewardsCoordinator.RewardsSubmission[] memory rewardsSubmissions = new IRewardsCoordinator.RewardsSubmission[]( + numSubmissions + ); bytes32[] memory rewardsSubmissionHashes = new bytes32[](numSubmissions); uint256 startSubmissionNonce = rewardsCoordinator.submissionNonce(rewardsForAllSubmitter); _deployMockRewardTokens(rewardsForAllSubmitter, numSubmissions); @@ -1286,7 +1669,9 @@ contract RewardsCoordinatorUnitTests_createRewardsForAllEarners is RewardsCoordi rewardsSubmissions[i] = rewardsSubmission; // 3. expected event emitted for this rewardsSubmission - rewardsSubmissionHashes[i] = keccak256(abi.encode(rewardsForAllSubmitter, startSubmissionNonce + i, rewardsSubmissions[i])); + rewardsSubmissionHashes[i] = keccak256( + abi.encode(rewardsForAllSubmitter, startSubmissionNonce + i, rewardsSubmissions[i]) + ); cheats.expectEmit(true, true, true, true, address(rewardsCoordinator)); emit RewardsSubmissionForAllEarnersCreated( rewardsForAllSubmitter, @@ -1309,7 +1694,10 @@ contract RewardsCoordinatorUnitTests_createRewardsForAllEarners is RewardsCoordi for (uint256 i = 0; i < numSubmissions; ++i) { assertTrue( - rewardsCoordinator.isRewardsSubmissionForAllEarnersHash(rewardsForAllSubmitter, rewardsSubmissionHashes[i]), + rewardsCoordinator.isRewardsSubmissionForAllEarnersHash( + rewardsForAllSubmitter, + rewardsSubmissionHashes[i] + ), "rewards submission hash not submitted" ); assertEq( @@ -1326,109 +1714,951 @@ contract RewardsCoordinatorUnitTests_createRewardsForAllEarners is RewardsCoordi } } -contract RewardsCoordinatorUnitTests_submitRoot is RewardsCoordinatorUnitTests { - // only callable by rewardsUpdater - function testFuzz_Revert_WhenNotRewardsUpdater( - address invalidRewardsUpdater - ) public filterFuzzedAddressInputs(invalidRewardsUpdater) { - cheats.prank(invalidRewardsUpdater); - - cheats.expectRevert("RewardsCoordinator: caller is not the rewardsUpdater"); - rewardsCoordinator.submitRoot(bytes32(0), 0); - } - - function test_Revert_WhenSubmitRootPaused() public { - cheats.prank(pauser); - rewardsCoordinator.pause(2 ** PAUSED_SUBMIT_ROOTS); - - cheats.expectRevert("Pausable: index is paused"); - rewardsCoordinator.submitRoot(bytes32(0), 0); +contract RewardsCoordinatorUnitTests_createOperatorDirectedAVSRewardsSubmission is RewardsCoordinatorUnitTests { + // used for stack too deep + struct FuzzOperatorDirectedAVSRewardsSubmission { + address avs; + uint256 startTimestamp; + uint256 duration; } - /// @notice submits root with correct values and adds to root storage array - /// - checks activatedAt has added activationDelay - function testFuzz_submitRoot(bytes32 root, uint32 rewardsCalculationEndTimestamp) public { - // fuzz avoiding overflows and valid activatedAt values - cheats.assume(rewardsCoordinator.currRewardsCalculationEndTimestamp() < rewardsCalculationEndTimestamp); - cheats.assume(rewardsCalculationEndTimestamp < block.timestamp); + IRewardsCoordinator.OperatorReward[] defaultOperatorRewards; - uint32 expectedRootIndex = uint32(rewardsCoordinator.getDistributionRootsLength()); - uint32 activatedAt = uint32(block.timestamp) + rewardsCoordinator.activationDelay(); + function setUp() public virtual override { + RewardsCoordinatorUnitTests.setUp(); - cheats.expectEmit(true, true, true, true, address(rewardsCoordinator)); - emit DistributionRootSubmitted(expectedRootIndex, root, rewardsCalculationEndTimestamp, activatedAt); - cheats.prank(rewardsUpdater); - rewardsCoordinator.submitRoot(root, rewardsCalculationEndTimestamp); + address[] memory operators = new address[](3); + operators[0] = makeAddr("operator1"); + operators[1] = makeAddr("operator2"); + operators[2] = makeAddr("operator3"); + operators = _sortAddressArrayAsc(operators); - IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex(expectedRootIndex); + defaultOperatorRewards.push(IRewardsCoordinator.OperatorReward(operators[0], 1e18)); + defaultOperatorRewards.push(IRewardsCoordinator.OperatorReward(operators[1], 2e18)); + defaultOperatorRewards.push(IRewardsCoordinator.OperatorReward(operators[2], 3e18)); - assertEq( - expectedRootIndex, - rewardsCoordinator.getDistributionRootsLength() - 1, - "root not added to roots array" - ); - assertEq( - root, - rewardsCoordinator.getCurrentDistributionRoot().root, - "getCurrentDistributionRoot view function failed" - ); - assertEq( - root, - rewardsCoordinator.getDistributionRootAtIndex(expectedRootIndex).root, - "getDistributionRootAtIndex view function failed" - ); - assertEq(activatedAt, distributionRoot.activatedAt, "activatedAt not correct"); - assertEq(root, distributionRoot.root, "root not set"); - assertEq( - rewardsCalculationEndTimestamp, - distributionRoot.rewardsCalculationEndTimestamp, - "rewardsCalculationEndTimestamp not set" - ); - assertEq( - rewardsCoordinator.currRewardsCalculationEndTimestamp(), - rewardsCalculationEndTimestamp, - "currRewardsCalculationEndTimestamp not set" - ); + // Set the timestamp to when Rewards v2 will realisticly go out (i.e 6 months) + cheats.warp(GENESIS_REWARDS_TIMESTAMP + 168 days); } - /// @notice Submits multiple roots and checks root index from hash is correct - function testFuzz_getRootIndexFromHash(bytes32 root, uint16 numRoots, uint256 index) public { - numRoots = uint16(bound(numRoots, 1, 100)); - index = bound(index, 0, uint256(numRoots - 1)); - - bytes32[] memory roots = new bytes32[](numRoots); - cheats.startPrank(rewardsUpdater); - for (uint16 i = 0; i < numRoots; ++i) { - roots[i] = keccak256(abi.encodePacked(root, i)); - - uint32 activationDelay = uint32(block.timestamp) + rewardsCoordinator.activationDelay(); - rewardsCoordinator.submitRoot(roots[i], uint32(block.timestamp - 1)); - cheats.warp(activationDelay); + /// @dev Sort to ensure that the array is in ascending order for addresses + function _sortAddressArrayAsc(address[] memory arr) internal pure returns (address[] memory) { + uint256 l = arr.length; + for (uint256 i = 0; i < l; i++) { + for (uint256 j = i + 1; j < l; j++) { + if (arr[i] > arr[j]) { + address temp = arr[i]; + arr[i] = arr[j]; + arr[j] = temp; + } + } } - cheats.stopPrank(); + return arr; + } - assertEq(index, rewardsCoordinator.getRootIndexFromHash(roots[index]), "root index not found"); + function _getTotalRewardsAmount( + IRewardsCoordinator.OperatorReward[] memory operatorRewards + ) internal pure returns (uint256) { + uint256 totalAmount = 0; + for (uint256 i = 0; i < operatorRewards.length; ++i) { + totalAmount += operatorRewards[i].amount; + } + return totalAmount; } -} -/// @notice Tests for sets of JSON data with different distribution roots -contract RewardsCoordinatorUnitTests_processClaim is RewardsCoordinatorUnitTests { - using stdStorage for StdStorage; + // Revert when paused + function test_Revert_WhenPaused() public { + cheats.prank(pauser); + rewardsCoordinator.pause(2 ** PAUSED_OPERATOR_DIRECTED_AVS_REWARDS_SUBMISSION); - /// @notice earner address used for proofs - address earner = 0xF2288D736d27C1584Ebf7be5f52f9E4d47251AeE; + cheats.expectRevert("Pausable: index is paused"); + IRewardsCoordinator.OperatorDirectedRewardsSubmission[] memory operatorDirectedRewardsSubmissions; + rewardsCoordinator.createOperatorDirectedAVSRewardsSubmission( + address(this), + operatorDirectedRewardsSubmissions + ); + } - /// @notice mock token bytecode - bytes mockTokenBytecode; + // Revert from reentrancy + function testFuzz_Revert_WhenReentrancy(uint256 startTimestamp, uint256 duration) public { + // 1. Bound fuzz inputs to valid ranges and amounts + duration = bound(duration, 0, MAX_REWARDS_DURATION); + duration = duration - (duration % CALCULATION_INTERVAL_SECONDS); + startTimestamp = bound( + startTimestamp, + uint256(_maxTimestamp(GENESIS_REWARDS_TIMESTAMP, uint32(block.timestamp) - MAX_RETROACTIVE_LENGTH)) + + CALCULATION_INTERVAL_SECONDS - + 1, + block.timestamp - duration - 1 + ); + startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); - uint32 prevRootCalculationEndTimestamp; + // 2. Deploy Reenterer + Reenterer reenterer = new Reenterer(); - // Temp storage for managing stack in _parseProofData - bytes32 merkleRoot; - uint32 earnerIndex; - bytes earnerTreeProof; - address proofEarner; - bytes32 earnerTokenRoot; + // 2. Create operator directed rewards submission input param + IRewardsCoordinator.OperatorDirectedRewardsSubmission[] + memory operatorDirectedRewardsSubmissions = new IRewardsCoordinator.OperatorDirectedRewardsSubmission[](1); + operatorDirectedRewardsSubmissions[0] = IRewardsCoordinator.OperatorDirectedRewardsSubmission({ + strategiesAndMultipliers: defaultStrategyAndMultipliers, + token: IERC20(address(reenterer)), + operatorRewards: defaultOperatorRewards, + startTimestamp: uint32(startTimestamp), + duration: uint32(duration), + description: "" + }); + + address targetToUse = address(rewardsCoordinator); + uint256 msgValueToUse = 0; + bytes memory calldataToUse = abi.encodeWithSelector( + RewardsCoordinator.createOperatorDirectedAVSRewardsSubmission.selector, + address(reenterer), + operatorDirectedRewardsSubmissions + ); + reenterer.prepare(targetToUse, msgValueToUse, calldataToUse); + + cheats.prank(address(reenterer)); + cheats.expectRevert("ReentrancyGuard: reentrant call"); + rewardsCoordinator.createOperatorDirectedAVSRewardsSubmission( + address(reenterer), + operatorDirectedRewardsSubmissions + ); + } + + // Revert when avs is not msg.sender + function testFuzz_Revert_WhenAVSIsNotMsgSender( + address avs, + uint256 startTimestamp, + uint256 duration + ) public filterFuzzedAddressInputs(avs) { + cheats.assume(avs != address(0) && avs != address(this)); + cheats.prank(rewardsCoordinator.owner()); + + // 1. Bound fuzz inputs to valid ranges and amounts + IERC20 rewardToken = new ERC20PresetFixedSupply("dog wif hat", "MOCK1", mockTokenInitialSupply, avs); + duration = bound(duration, 0, MAX_REWARDS_DURATION); + duration = duration - (duration % CALCULATION_INTERVAL_SECONDS); + startTimestamp = bound( + startTimestamp, + uint256(_maxTimestamp(GENESIS_REWARDS_TIMESTAMP, uint32(block.timestamp) - MAX_RETROACTIVE_LENGTH)) + + CALCULATION_INTERVAL_SECONDS - + 1, + block.timestamp - duration - 1 + ); + startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); + + // 2. Create operator directed rewards submission input param + IRewardsCoordinator.OperatorDirectedRewardsSubmission[] + memory operatorDirectedRewardsSubmissions = new IRewardsCoordinator.OperatorDirectedRewardsSubmission[](1); + operatorDirectedRewardsSubmissions[0] = IRewardsCoordinator.OperatorDirectedRewardsSubmission({ + strategiesAndMultipliers: defaultStrategyAndMultipliers, + token: rewardToken, + operatorRewards: defaultOperatorRewards, + startTimestamp: uint32(startTimestamp), + duration: uint32(duration), + description: "" + }); + + // 3. call createOperatorDirectedAVSRewardsSubmission() with expected revert + cheats.expectRevert("RewardsCoordinator.createOperatorDirectedAVSRewardsSubmission: caller is not the AVS"); + rewardsCoordinator.createOperatorDirectedAVSRewardsSubmission(avs, operatorDirectedRewardsSubmissions); + } + + // Revert with 0 length strats and multipliers + function testFuzz_Revert_WhenEmptyStratsAndMultipliers( + address avs, + uint256 startTimestamp, + uint256 duration + ) public filterFuzzedAddressInputs(avs) { + cheats.assume(avs != address(0)); + cheats.prank(rewardsCoordinator.owner()); + + // 1. Bound fuzz inputs to valid ranges and amounts + IERC20 rewardToken = new ERC20PresetFixedSupply("dog wif hat", "MOCK1", mockTokenInitialSupply, avs); + duration = bound(duration, 0, MAX_REWARDS_DURATION); + duration = duration - (duration % CALCULATION_INTERVAL_SECONDS); + startTimestamp = bound( + startTimestamp, + uint256(_maxTimestamp(GENESIS_REWARDS_TIMESTAMP, uint32(block.timestamp) - MAX_RETROACTIVE_LENGTH)) + + CALCULATION_INTERVAL_SECONDS - + 1, + block.timestamp - duration - 1 + ); + startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); + + // 2. Create operator directed rewards submission input param + IRewardsCoordinator.OperatorDirectedRewardsSubmission[] + memory operatorDirectedRewardsSubmissions = new IRewardsCoordinator.OperatorDirectedRewardsSubmission[](1); + IRewardsCoordinator.StrategyAndMultiplier[] memory emptyStratsAndMultipliers; + operatorDirectedRewardsSubmissions[0] = IRewardsCoordinator.OperatorDirectedRewardsSubmission({ + strategiesAndMultipliers: emptyStratsAndMultipliers, + token: rewardToken, + operatorRewards: defaultOperatorRewards, + startTimestamp: uint32(startTimestamp), + duration: uint32(duration), + description: "" + }); + + // 3. call createOperatorDirectedAVSRewardsSubmission() with expected revert + cheats.prank(avs); + cheats.expectRevert("RewardsCoordinator._validateCommonRewardsSubmission: no strategies set"); + rewardsCoordinator.createOperatorDirectedAVSRewardsSubmission(avs, operatorDirectedRewardsSubmissions); + } + + // Revert with 0 length operator rewards + function testFuzz_Revert_WhenEmptyOperatorRewards( + address avs, + uint256 startTimestamp, + uint256 duration + ) public filterFuzzedAddressInputs(avs) { + cheats.assume(avs != address(0)); + cheats.prank(rewardsCoordinator.owner()); + + // 1. Bound fuzz inputs to valid ranges and amounts + IERC20 rewardToken = new ERC20PresetFixedSupply("dog wif hat", "MOCK1", mockTokenInitialSupply, avs); + duration = bound(duration, 0, MAX_REWARDS_DURATION); + duration = duration - (duration % CALCULATION_INTERVAL_SECONDS); + startTimestamp = bound( + startTimestamp, + uint256(_maxTimestamp(GENESIS_REWARDS_TIMESTAMP, uint32(block.timestamp) - MAX_RETROACTIVE_LENGTH)) + + CALCULATION_INTERVAL_SECONDS - + 1, + block.timestamp - duration - 1 + ); + startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); + + // 2. Create operator directed rewards submission input param + IRewardsCoordinator.OperatorDirectedRewardsSubmission[] + memory operatorDirectedRewardsSubmissions = new IRewardsCoordinator.OperatorDirectedRewardsSubmission[](1); + IRewardsCoordinator.OperatorReward[] memory emptyOperatorRewards; + operatorDirectedRewardsSubmissions[0] = IRewardsCoordinator.OperatorDirectedRewardsSubmission({ + strategiesAndMultipliers: defaultStrategyAndMultipliers, + token: rewardToken, + operatorRewards: emptyOperatorRewards, + startTimestamp: uint32(startTimestamp), + duration: uint32(duration), + description: "" + }); + + // 3. call createOperatorDirectedAVSRewardsSubmission() with expected revert + cheats.prank(avs); + cheats.expectRevert("RewardsCoordinator._validateOperatorDirectedRewardsSubmission: no operators rewarded"); + rewardsCoordinator.createOperatorDirectedAVSRewardsSubmission(avs, operatorDirectedRewardsSubmissions); + } + + // Revert when operator is zero address + function testFuzz_Revert_WhenOperatorIsZeroAddress( + address avs, + uint256 startTimestamp, + uint256 duration + ) public filterFuzzedAddressInputs(avs) { + cheats.assume(avs != address(0)); + cheats.prank(rewardsCoordinator.owner()); + + // 1. Bound fuzz inputs to valid ranges and amounts + IERC20 rewardToken = new ERC20PresetFixedSupply("dog wif hat", "MOCK1", mockTokenInitialSupply, avs); + duration = bound(duration, 0, MAX_REWARDS_DURATION); + duration = duration - (duration % CALCULATION_INTERVAL_SECONDS); + startTimestamp = bound( + startTimestamp, + uint256(_maxTimestamp(GENESIS_REWARDS_TIMESTAMP, uint32(block.timestamp) - MAX_RETROACTIVE_LENGTH)) + + CALCULATION_INTERVAL_SECONDS - + 1, + block.timestamp - duration - 1 + ); + startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); + + // 2. Create operator directed rewards submission input param + IRewardsCoordinator.OperatorDirectedRewardsSubmission[] + memory operatorDirectedRewardsSubmissions = new IRewardsCoordinator.OperatorDirectedRewardsSubmission[](1); + defaultOperatorRewards[0].operator = address(0); + operatorDirectedRewardsSubmissions[0] = IRewardsCoordinator.OperatorDirectedRewardsSubmission({ + strategiesAndMultipliers: defaultStrategyAndMultipliers, + token: rewardToken, + operatorRewards: defaultOperatorRewards, + startTimestamp: uint32(startTimestamp), + duration: uint32(duration), + description: "" + }); + + // 3. call createOperatorDirectedAVSRewardsSubmission() with expected revert + cheats.prank(avs); + cheats.expectRevert( + "RewardsCoordinator._validateOperatorDirectedRewardsSubmission: operator cannot be 0 address" + ); + rewardsCoordinator.createOperatorDirectedAVSRewardsSubmission(avs, operatorDirectedRewardsSubmissions); + } + + // Revert when duplicate operators + function testFuzz_Revert_WhenDuplicateOperators( + address avs, + uint256 startTimestamp, + uint256 duration + ) public filterFuzzedAddressInputs(avs) { + cheats.assume(avs != address(0)); + cheats.prank(rewardsCoordinator.owner()); + + // 1. Bound fuzz inputs to valid ranges and amounts + IERC20 rewardToken = new ERC20PresetFixedSupply("dog wif hat", "MOCK1", mockTokenInitialSupply, avs); + duration = bound(duration, 0, MAX_REWARDS_DURATION); + duration = duration - (duration % CALCULATION_INTERVAL_SECONDS); + startTimestamp = bound( + startTimestamp, + uint256(_maxTimestamp(GENESIS_REWARDS_TIMESTAMP, uint32(block.timestamp) - MAX_RETROACTIVE_LENGTH)) + + CALCULATION_INTERVAL_SECONDS - + 1, + block.timestamp - duration - 1 + ); + startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); + + // 2. Create operator directed rewards submission input param + IRewardsCoordinator.OperatorDirectedRewardsSubmission[] + memory operatorDirectedRewardsSubmissions = new IRewardsCoordinator.OperatorDirectedRewardsSubmission[](1); + IRewardsCoordinator.OperatorReward[] memory dupOperatorRewards = new IRewardsCoordinator.OperatorReward[](2); + dupOperatorRewards[0] = defaultOperatorRewards[0]; + dupOperatorRewards[1] = defaultOperatorRewards[0]; + operatorDirectedRewardsSubmissions[0] = IRewardsCoordinator.OperatorDirectedRewardsSubmission({ + strategiesAndMultipliers: defaultStrategyAndMultipliers, + token: rewardToken, + operatorRewards: dupOperatorRewards, + startTimestamp: uint32(startTimestamp), + duration: uint32(duration), + description: "" + }); + + // 3. call createOperatorDirectedAVSRewardsSubmission() with expected revert + cheats.prank(avs); + cheats.expectRevert( + "RewardsCoordinator._validateOperatorDirectedRewardsSubmission: operators must be in ascending order to handle duplicates" + ); + rewardsCoordinator.createOperatorDirectedAVSRewardsSubmission(avs, operatorDirectedRewardsSubmissions); + } + + // Revert when operator amount is zero + function testFuzz_Revert_WhenOperatorAmountIsZero( + address avs, + uint256 startTimestamp, + uint256 duration + ) public filterFuzzedAddressInputs(avs) { + cheats.assume(avs != address(0)); + cheats.prank(rewardsCoordinator.owner()); + + // 1. Bound fuzz inputs to valid ranges and amounts + IERC20 rewardToken = new ERC20PresetFixedSupply("dog wif hat", "MOCK1", mockTokenInitialSupply, avs); + duration = bound(duration, 0, MAX_REWARDS_DURATION); + duration = duration - (duration % CALCULATION_INTERVAL_SECONDS); + startTimestamp = bound( + startTimestamp, + uint256(_maxTimestamp(GENESIS_REWARDS_TIMESTAMP, uint32(block.timestamp) - MAX_RETROACTIVE_LENGTH)) + + CALCULATION_INTERVAL_SECONDS - + 1, + block.timestamp - duration - 1 + ); + startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); + + // 2. Create operator directed rewards submission input param + IRewardsCoordinator.OperatorDirectedRewardsSubmission[] + memory operatorDirectedRewardsSubmissions = new IRewardsCoordinator.OperatorDirectedRewardsSubmission[](1); + defaultOperatorRewards[0].amount = 0; + operatorDirectedRewardsSubmissions[0] = IRewardsCoordinator.OperatorDirectedRewardsSubmission({ + strategiesAndMultipliers: defaultStrategyAndMultipliers, + token: rewardToken, + operatorRewards: defaultOperatorRewards, + startTimestamp: uint32(startTimestamp), + duration: uint32(duration), + description: "" + }); + + // 3. call createOperatorDirectedAVSRewardsSubmission() with expected revert + cheats.prank(avs); + cheats.expectRevert( + "RewardsCoordinator._validateOperatorDirectedRewardsSubmission: operator reward amount cannot be 0" + ); + rewardsCoordinator.createOperatorDirectedAVSRewardsSubmission(avs, operatorDirectedRewardsSubmissions); + } + + // Revert with exceeding max duration + function testFuzz_Revert_WhenExceedingMaxDuration( + address avs, + uint256 startTimestamp, + uint256 duration + ) public filterFuzzedAddressInputs(avs) { + cheats.assume(avs != address(0)); + cheats.prank(rewardsCoordinator.owner()); + + // 1. Bound fuzz inputs to valid ranges and amounts + IERC20 rewardToken = new ERC20PresetFixedSupply("dog wif hat", "MOCK1", mockTokenInitialSupply, avs); + duration = bound(duration, MAX_REWARDS_DURATION + 1, type(uint32).max); + startTimestamp = bound( + startTimestamp, + uint256(_maxTimestamp(GENESIS_REWARDS_TIMESTAMP, uint32(block.timestamp) - MAX_RETROACTIVE_LENGTH)) + + CALCULATION_INTERVAL_SECONDS - + 1, + block.timestamp + ); + startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); + + // 2. Create operator directed rewards submission input param + IRewardsCoordinator.OperatorDirectedRewardsSubmission[] + memory operatorDirectedRewardsSubmissions = new IRewardsCoordinator.OperatorDirectedRewardsSubmission[](1); + operatorDirectedRewardsSubmissions[0] = IRewardsCoordinator.OperatorDirectedRewardsSubmission({ + strategiesAndMultipliers: defaultStrategyAndMultipliers, + token: rewardToken, + operatorRewards: defaultOperatorRewards, + startTimestamp: uint32(startTimestamp), + duration: uint32(duration), + description: "" + }); + + // 3. call createOperatorDirectedAVSRewardsSubmission() with expected revert + cheats.prank(avs); + cheats.expectRevert( + "RewardsCoordinator._validateCommonRewardsSubmission: duration exceeds MAX_REWARDS_DURATION" + ); + rewardsCoordinator.createOperatorDirectedAVSRewardsSubmission(avs, operatorDirectedRewardsSubmissions); + } + + // Revert with invalid interval seconds + function testFuzz_Revert_WhenInvalidIntervalSeconds( + address avs, + uint256 startTimestamp, + uint256 duration + ) public filterFuzzedAddressInputs(avs) { + cheats.assume(avs != address(0)); + cheats.prank(rewardsCoordinator.owner()); + + // 1. Bound fuzz inputs to valid ranges and amounts + IERC20 rewardToken = new ERC20PresetFixedSupply("dog wif hat", "MOCK1", mockTokenInitialSupply, avs); + duration = bound(duration, 0, MAX_REWARDS_DURATION); + cheats.assume(duration % CALCULATION_INTERVAL_SECONDS != 0); + startTimestamp = bound( + startTimestamp, + uint256(_maxTimestamp(GENESIS_REWARDS_TIMESTAMP, uint32(block.timestamp) - MAX_RETROACTIVE_LENGTH)) + + CALCULATION_INTERVAL_SECONDS - + 1, + block.timestamp - duration - 1 + ); + startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); + + // 2. Create operator directed rewards submission input param + IRewardsCoordinator.OperatorDirectedRewardsSubmission[] + memory operatorDirectedRewardsSubmissions = new IRewardsCoordinator.OperatorDirectedRewardsSubmission[](1); + operatorDirectedRewardsSubmissions[0] = IRewardsCoordinator.OperatorDirectedRewardsSubmission({ + strategiesAndMultipliers: defaultStrategyAndMultipliers, + token: rewardToken, + operatorRewards: defaultOperatorRewards, + startTimestamp: uint32(startTimestamp), + duration: uint32(duration), + description: "" + }); + + // 3. call createOperatorDirectedAVSRewardsSubmission() with expected revert + cheats.prank(avs); + cheats.expectRevert( + "RewardsCoordinator._validateCommonRewardsSubmission: duration must be a multiple of CALCULATION_INTERVAL_SECONDS" + ); + rewardsCoordinator.createOperatorDirectedAVSRewardsSubmission(avs, operatorDirectedRewardsSubmissions); + } + + // Revert with invalid interval start timestamp + function testFuzz_Revert_WhenInvalidIntervalStartTimestamp( + address avs, + uint256 startTimestamp, + uint256 duration + ) public filterFuzzedAddressInputs(avs) { + cheats.assume(avs != address(0)); + cheats.prank(rewardsCoordinator.owner()); + + // 1. Bound fuzz inputs to valid ranges and amounts + IERC20 rewardToken = new ERC20PresetFixedSupply("dog wif hat", "MOCK1", mockTokenInitialSupply, avs); + duration = bound(duration, 0, MAX_REWARDS_DURATION); + duration = duration - (duration % CALCULATION_INTERVAL_SECONDS); + startTimestamp = bound( + startTimestamp, + uint256(_maxTimestamp(GENESIS_REWARDS_TIMESTAMP, uint32(block.timestamp) - MAX_RETROACTIVE_LENGTH)) + + CALCULATION_INTERVAL_SECONDS - + 1, + block.timestamp - duration - 1 + ); + cheats.assume(startTimestamp % CALCULATION_INTERVAL_SECONDS != 0); + + // 2. Create operator directed rewards submission input param + IRewardsCoordinator.OperatorDirectedRewardsSubmission[] + memory operatorDirectedRewardsSubmissions = new IRewardsCoordinator.OperatorDirectedRewardsSubmission[](1); + operatorDirectedRewardsSubmissions[0] = IRewardsCoordinator.OperatorDirectedRewardsSubmission({ + strategiesAndMultipliers: defaultStrategyAndMultipliers, + token: rewardToken, + operatorRewards: defaultOperatorRewards, + startTimestamp: uint32(startTimestamp), + duration: uint32(duration), + description: "" + }); + + // 3. call createOperatorDirectedAVSRewardsSubmission() with expected revert + cheats.prank(avs); + cheats.expectRevert( + "RewardsCoordinator._validateCommonRewardsSubmission: startTimestamp must be a multiple of CALCULATION_INTERVAL_SECONDS" + ); + rewardsCoordinator.createOperatorDirectedAVSRewardsSubmission(avs, operatorDirectedRewardsSubmissions); + } + + // Revert with retroactive rewards enabled and set too far in past + // - either before genesis rewards timestamp + // - before max retroactive length + function testFuzz_Revert_WhenRewardsSubmissionTooStale( + address avs, + uint256 startTimestamp, + uint256 duration + ) public filterFuzzedAddressInputs(avs) { + cheats.assume(avs != address(0)); + cheats.prank(rewardsCoordinator.owner()); + + // 1. Bound fuzz inputs to valid ranges and amounts + IERC20 rewardToken = new ERC20PresetFixedSupply("dog wif hat", "MOCK1", mockTokenInitialSupply, avs); + duration = bound(duration, 0, MAX_REWARDS_DURATION); + duration = duration - (duration % CALCULATION_INTERVAL_SECONDS); + startTimestamp = bound(startTimestamp, 0, uint32(block.timestamp) - MAX_RETROACTIVE_LENGTH - 1); + startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); + + // 2. Create operator directed rewards submission input param + IRewardsCoordinator.OperatorDirectedRewardsSubmission[] + memory operatorDirectedRewardsSubmissions = new IRewardsCoordinator.OperatorDirectedRewardsSubmission[](1); + operatorDirectedRewardsSubmissions[0] = IRewardsCoordinator.OperatorDirectedRewardsSubmission({ + strategiesAndMultipliers: defaultStrategyAndMultipliers, + token: rewardToken, + operatorRewards: defaultOperatorRewards, + startTimestamp: uint32(startTimestamp), + duration: uint32(duration), + description: "" + }); + + // 3. call createOperatorDirectedAVSRewardsSubmission() with expected revert + cheats.prank(avs); + cheats.expectRevert("RewardsCoordinator._validateCommonRewardsSubmission: startTimestamp too far in the past"); + rewardsCoordinator.createOperatorDirectedAVSRewardsSubmission(avs, operatorDirectedRewardsSubmissions); + } + + // Revert when not retroactive + function testFuzz_Revert_WhenRewardsSubmissionNotRetroactive( + address avs, + uint256 startTimestamp, + uint256 duration + ) public filterFuzzedAddressInputs(avs) { + cheats.assume(avs != address(0)); + cheats.prank(rewardsCoordinator.owner()); + + // 1. Bound fuzz inputs to valid ranges and amounts + IERC20 rewardToken = new ERC20PresetFixedSupply("dog wif hat", "MOCK1", mockTokenInitialSupply, avs); + duration = bound(duration, 0, MAX_REWARDS_DURATION); + duration = duration - (duration % CALCULATION_INTERVAL_SECONDS); + startTimestamp = bound( + startTimestamp, + block.timestamp - duration + CALCULATION_INTERVAL_SECONDS, + type(uint32).max - duration + ); + startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); + + // 2. Create operator directed rewards submission input param + IRewardsCoordinator.OperatorDirectedRewardsSubmission[] + memory operatorDirectedRewardsSubmissions = new IRewardsCoordinator.OperatorDirectedRewardsSubmission[](1); + operatorDirectedRewardsSubmissions[0] = IRewardsCoordinator.OperatorDirectedRewardsSubmission({ + strategiesAndMultipliers: defaultStrategyAndMultipliers, + token: rewardToken, + operatorRewards: defaultOperatorRewards, + startTimestamp: uint32(startTimestamp), + duration: uint32(duration), + description: "" + }); + + // 3. call createOperatorDirectedAVSRewardsSubmission() with expected revert + cheats.prank(avs); + cheats.expectRevert( + "RewardsCoordinator._validateOperatorDirectedRewardsSubmission: operator-directed rewards submission is not retroactive" + ); + rewardsCoordinator.createOperatorDirectedAVSRewardsSubmission(avs, operatorDirectedRewardsSubmissions); + } + + // Revert with non whitelisted strategy + function testFuzz_Revert_WhenInvalidStrategy( + address avs, + uint256 startTimestamp, + uint256 duration + ) public filterFuzzedAddressInputs(avs) { + cheats.assume(avs != address(0)); + cheats.prank(rewardsCoordinator.owner()); + + // 1. Bound fuzz inputs to valid ranges and amounts + IERC20 rewardToken = new ERC20PresetFixedSupply("dog wif hat", "MOCK1", mockTokenInitialSupply, avs); + duration = bound(duration, 0, MAX_REWARDS_DURATION); + duration = duration - (duration % CALCULATION_INTERVAL_SECONDS); + startTimestamp = bound( + startTimestamp, + uint256(_maxTimestamp(GENESIS_REWARDS_TIMESTAMP, uint32(block.timestamp) - MAX_RETROACTIVE_LENGTH)) + + CALCULATION_INTERVAL_SECONDS - + 1, + block.timestamp - duration - 1 + ); + startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); + + // 2. Create operator directed rewards submission input param + IRewardsCoordinator.OperatorDirectedRewardsSubmission[] + memory operatorDirectedRewardsSubmissions = new IRewardsCoordinator.OperatorDirectedRewardsSubmission[](1); + defaultStrategyAndMultipliers[0].strategy = IStrategy(address(999)); + operatorDirectedRewardsSubmissions[0] = IRewardsCoordinator.OperatorDirectedRewardsSubmission({ + strategiesAndMultipliers: defaultStrategyAndMultipliers, + token: rewardToken, + operatorRewards: defaultOperatorRewards, + startTimestamp: uint32(startTimestamp), + duration: uint32(duration), + description: "" + }); + + // 3. call createOperatorDirectedAVSRewardsSubmission() with expected revert + cheats.prank(avs); + cheats.expectRevert("RewardsCoordinator._validateCommonRewardsSubmission: invalid strategy considered"); + rewardsCoordinator.createOperatorDirectedAVSRewardsSubmission(avs, operatorDirectedRewardsSubmissions); + } + + // Revert when duplicate strategies + function testFuzz_Revert_WhenDuplicateStrategies( + address avs, + uint256 startTimestamp, + uint256 duration + ) public filterFuzzedAddressInputs(avs) { + cheats.assume(avs != address(0)); + cheats.prank(rewardsCoordinator.owner()); + + // 1. Bound fuzz inputs to valid ranges and amounts + IERC20 rewardToken = new ERC20PresetFixedSupply("dog wif hat", "MOCK1", mockTokenInitialSupply, avs); + duration = bound(duration, 0, MAX_REWARDS_DURATION); + duration = duration - (duration % CALCULATION_INTERVAL_SECONDS); + startTimestamp = bound( + startTimestamp, + uint256(_maxTimestamp(GENESIS_REWARDS_TIMESTAMP, uint32(block.timestamp) - MAX_RETROACTIVE_LENGTH)) + + CALCULATION_INTERVAL_SECONDS - + 1, + block.timestamp - duration - 1 + ); + startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); + + // 2. Create operator directed rewards submission input param + IRewardsCoordinator.OperatorDirectedRewardsSubmission[] + memory operatorDirectedRewardsSubmissions = new IRewardsCoordinator.OperatorDirectedRewardsSubmission[](1); + IRewardsCoordinator.StrategyAndMultiplier[] + memory dupStratsAndMultipliers = new IRewardsCoordinator.StrategyAndMultiplier[](2); + dupStratsAndMultipliers[0] = defaultStrategyAndMultipliers[0]; + dupStratsAndMultipliers[1] = defaultStrategyAndMultipliers[0]; + operatorDirectedRewardsSubmissions[0] = IRewardsCoordinator.OperatorDirectedRewardsSubmission({ + strategiesAndMultipliers: dupStratsAndMultipliers, + token: rewardToken, + operatorRewards: defaultOperatorRewards, + startTimestamp: uint32(startTimestamp), + duration: uint32(duration), + description: "" + }); + + // 3. call createOperatorDirectedAVSRewardsSubmission() with expected revert + cheats.prank(avs); + cheats.expectRevert( + "RewardsCoordinator._validateCommonRewardsSubmission: strategies must be in ascending order to handle duplicates" + ); + rewardsCoordinator.createOperatorDirectedAVSRewardsSubmission(avs, operatorDirectedRewardsSubmissions); + } + + /** + * @notice test a single rewards submission asserting for the following + * - correct event emitted + * - submission nonce incrementation by 1, and rewards submission hash being set in storage. + * - rewards submission hash being set in storage + * - token balance before and after of avs and rewardsCoordinator + */ + function testFuzz_createOperatorDirectedAVSRewardsSubmission_SingleSubmission( + address avs, + uint256 startTimestamp, + uint256 duration + ) public filterFuzzedAddressInputs(avs) { + cheats.assume(avs != address(0)); + cheats.prank(rewardsCoordinator.owner()); + + // 1. Bound fuzz inputs to valid ranges and amounts + IERC20 rewardToken = new ERC20PresetFixedSupply("dog wif hat", "MOCK1", mockTokenInitialSupply, avs); + duration = bound(duration, 0, MAX_REWARDS_DURATION); + duration = duration - (duration % CALCULATION_INTERVAL_SECONDS); + startTimestamp = bound( + startTimestamp, + uint256(_maxTimestamp(GENESIS_REWARDS_TIMESTAMP, uint32(block.timestamp) - MAX_RETROACTIVE_LENGTH)) + + CALCULATION_INTERVAL_SECONDS - + 1, + block.timestamp - duration - 1 + ); + startTimestamp = startTimestamp - (startTimestamp % CALCULATION_INTERVAL_SECONDS); + + // 2. Create operator directed rewards submission input param + IRewardsCoordinator.OperatorDirectedRewardsSubmission[] + memory operatorDirectedRewardsSubmissions = new IRewardsCoordinator.OperatorDirectedRewardsSubmission[](1); + operatorDirectedRewardsSubmissions[0] = IRewardsCoordinator.OperatorDirectedRewardsSubmission({ + strategiesAndMultipliers: defaultStrategyAndMultipliers, + token: rewardToken, + operatorRewards: defaultOperatorRewards, + startTimestamp: uint32(startTimestamp), + duration: uint32(duration), + description: "" + }); + + // 3. call createOperatorDirectedAVSRewardsSubmission() with expected event emitted + uint256 avsBalanceBefore = rewardToken.balanceOf(avs); + uint256 rewardsCoordinatorBalanceBefore = rewardToken.balanceOf(address(rewardsCoordinator)); + + cheats.startPrank(avs); + uint256 amount = _getTotalRewardsAmount(defaultOperatorRewards); + rewardToken.approve(address(rewardsCoordinator), amount); + uint256 currSubmissionNonce = rewardsCoordinator.submissionNonce(avs); + bytes32 rewardsSubmissionHash = keccak256( + abi.encode(avs, currSubmissionNonce, operatorDirectedRewardsSubmissions[0]) + ); + cheats.expectEmit(true, true, true, true, address(rewardsCoordinator)); + emit OperatorDirectedAVSRewardsSubmissionCreated( + avs, + avs, + rewardsSubmissionHash, + currSubmissionNonce, + operatorDirectedRewardsSubmissions[0] + ); + rewardsCoordinator.createOperatorDirectedAVSRewardsSubmission(avs, operatorDirectedRewardsSubmissions); + cheats.stopPrank(); + + assertTrue( + rewardsCoordinator.isOperatorDirectedAVSRewardsSubmissionHash(avs, rewardsSubmissionHash), + "rewards submission hash not submitted" + ); + assertEq(currSubmissionNonce + 1, rewardsCoordinator.submissionNonce(avs), "submission nonce not incremented"); + assertEq( + avsBalanceBefore - amount, + rewardToken.balanceOf(avs), + "AVS balance not decremented by amount of rewards submission" + ); + assertEq( + rewardsCoordinatorBalanceBefore + amount, + rewardToken.balanceOf(address(rewardsCoordinator)), + "RewardsCoordinator balance not incremented by amount of rewards submission" + ); + } + + /** + * @notice test a multiple rewards submission asserting for the following + * - correct event emitted + * - submission nonce incrementation by 1, and rewards submission hash being set in storage. + * - rewards submission hash being set in storage + * - token balance before and after of avs and rewardsCoordinator + */ + function testFuzz_createOperatorDirectedAVSRewardsSubmission_MultipleSubmissions( + FuzzOperatorDirectedAVSRewardsSubmission memory param, + uint256 numSubmissions + ) public filterFuzzedAddressInputs(param.avs) { + cheats.assume(2 <= numSubmissions && numSubmissions <= 10); + cheats.assume(param.avs != address(0)); + cheats.prank(rewardsCoordinator.owner()); + + IRewardsCoordinator.OperatorDirectedRewardsSubmission[] + memory rewardsSubmissions = new IRewardsCoordinator.OperatorDirectedRewardsSubmission[](numSubmissions); + bytes32[] memory rewardsSubmissionHashes = new bytes32[](numSubmissions); + uint256 startSubmissionNonce = rewardsCoordinator.submissionNonce(param.avs); + _deployMockRewardTokens(param.avs, numSubmissions); + + uint256[] memory avsBalancesBefore = _getBalanceForTokens(rewardTokens, param.avs); + uint256[] memory rewardsCoordinatorBalancesBefore = _getBalanceForTokens( + rewardTokens, + address(rewardsCoordinator) + ); + uint256[] memory amounts = new uint256[](numSubmissions); + + // Create multiple rewards submissions and their expected event + for (uint256 i = 0; i < numSubmissions; ++i) { + // 1. Bound fuzz inputs to valid ranges and amounts using randSeed for each + amounts[i] = _getTotalRewardsAmount(defaultOperatorRewards); + param.duration = bound(param.duration, 0, MAX_REWARDS_DURATION); + param.duration = param.duration - (param.duration % CALCULATION_INTERVAL_SECONDS); + param.startTimestamp = bound( + param.startTimestamp + i, + uint256(_maxTimestamp(GENESIS_REWARDS_TIMESTAMP, uint32(block.timestamp) - MAX_RETROACTIVE_LENGTH)) + + CALCULATION_INTERVAL_SECONDS - + 1, + block.timestamp + uint256(MAX_FUTURE_LENGTH) + ); + param.startTimestamp = param.startTimestamp - (param.startTimestamp % CALCULATION_INTERVAL_SECONDS); + + param.duration = bound(param.duration, 0, MAX_REWARDS_DURATION); + param.duration = param.duration - (param.duration % CALCULATION_INTERVAL_SECONDS); + param.startTimestamp = bound( + param.startTimestamp, + uint256(_maxTimestamp(GENESIS_REWARDS_TIMESTAMP, uint32(block.timestamp) - MAX_RETROACTIVE_LENGTH)) + + CALCULATION_INTERVAL_SECONDS - + 1, + block.timestamp - param.duration - 1 + ); + param.startTimestamp = param.startTimestamp - (param.startTimestamp % CALCULATION_INTERVAL_SECONDS); + + // 2. Create rewards submission input param + IRewardsCoordinator.OperatorDirectedRewardsSubmission memory rewardsSubmission = IRewardsCoordinator + .OperatorDirectedRewardsSubmission({ + strategiesAndMultipliers: defaultStrategyAndMultipliers, + token: rewardTokens[i], + operatorRewards: defaultOperatorRewards, + startTimestamp: uint32(param.startTimestamp), + duration: uint32(param.duration), + description: "" + }); + rewardsSubmissions[i] = rewardsSubmission; + + // 3. expected event emitted for this rewardsSubmission + rewardsSubmissionHashes[i] = keccak256( + abi.encode(param.avs, startSubmissionNonce + i, rewardsSubmissions[i]) + ); + cheats.expectEmit(true, true, true, true, address(rewardsCoordinator)); + emit OperatorDirectedAVSRewardsSubmissionCreated( + param.avs, + param.avs, + rewardsSubmissionHashes[i], + startSubmissionNonce + i, + rewardsSubmissions[i] + ); + } + + // 4. call createAVSRewardsSubmission() + cheats.prank(param.avs); + rewardsCoordinator.createOperatorDirectedAVSRewardsSubmission(param.avs, rewardsSubmissions); + + // 5. Check for submissionNonce() and rewardsSubmissionHashes being set + assertEq( + startSubmissionNonce + numSubmissions, + rewardsCoordinator.submissionNonce(param.avs), + "submission nonce not incremented properly" + ); + + for (uint256 i = 0; i < numSubmissions; ++i) { + assertTrue( + rewardsCoordinator.isOperatorDirectedAVSRewardsSubmissionHash(param.avs, rewardsSubmissionHashes[i]), + "rewards submission hash not submitted" + ); + assertEq( + avsBalancesBefore[i] - amounts[i], + rewardTokens[i].balanceOf(param.avs), + "AVS balance not decremented by amount of rewards submission" + ); + assertEq( + rewardsCoordinatorBalancesBefore[i] + amounts[i], + rewardTokens[i].balanceOf(address(rewardsCoordinator)), + "RewardsCoordinator balance not incremented by amount of rewards submission" + ); + } + } +} + +contract RewardsCoordinatorUnitTests_submitRoot is RewardsCoordinatorUnitTests { + // only callable by rewardsUpdater + function testFuzz_Revert_WhenNotRewardsUpdater( + address invalidRewardsUpdater + ) public filterFuzzedAddressInputs(invalidRewardsUpdater) { + cheats.prank(invalidRewardsUpdater); + + cheats.expectRevert("RewardsCoordinator: caller is not the rewardsUpdater"); + rewardsCoordinator.submitRoot(bytes32(0), 0); + } + + function test_Revert_WhenSubmitRootPaused() public { + cheats.prank(pauser); + rewardsCoordinator.pause(2 ** PAUSED_SUBMIT_ROOTS); + + cheats.expectRevert("Pausable: index is paused"); + rewardsCoordinator.submitRoot(bytes32(0), 0); + } + + /// @notice submits root with correct values and adds to root storage array + /// - checks activatedAt has added activationDelay + function testFuzz_submitRoot(bytes32 root, uint32 rewardsCalculationEndTimestamp) public { + // fuzz avoiding overflows and valid activatedAt values + cheats.assume(rewardsCoordinator.currRewardsCalculationEndTimestamp() < rewardsCalculationEndTimestamp); + cheats.assume(rewardsCalculationEndTimestamp < block.timestamp); + + uint32 expectedRootIndex = uint32(rewardsCoordinator.getDistributionRootsLength()); + uint32 activatedAt = uint32(block.timestamp) + rewardsCoordinator.activationDelay(); + + cheats.expectEmit(true, true, true, true, address(rewardsCoordinator)); + emit DistributionRootSubmitted(expectedRootIndex, root, rewardsCalculationEndTimestamp, activatedAt); + cheats.prank(rewardsUpdater); + rewardsCoordinator.submitRoot(root, rewardsCalculationEndTimestamp); + + IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex( + expectedRootIndex + ); + + assertEq( + expectedRootIndex, + rewardsCoordinator.getDistributionRootsLength() - 1, + "root not added to roots array" + ); + assertEq( + root, + rewardsCoordinator.getCurrentDistributionRoot().root, + "getCurrentDistributionRoot view function failed" + ); + assertEq( + root, + rewardsCoordinator.getDistributionRootAtIndex(expectedRootIndex).root, + "getDistributionRootAtIndex view function failed" + ); + assertEq(activatedAt, distributionRoot.activatedAt, "activatedAt not correct"); + assertEq(root, distributionRoot.root, "root not set"); + assertEq( + rewardsCalculationEndTimestamp, + distributionRoot.rewardsCalculationEndTimestamp, + "rewardsCalculationEndTimestamp not set" + ); + assertEq( + rewardsCoordinator.currRewardsCalculationEndTimestamp(), + rewardsCalculationEndTimestamp, + "currRewardsCalculationEndTimestamp not set" + ); + } + + /// @notice Submits multiple roots and checks root index from hash is correct + function testFuzz_getRootIndexFromHash(bytes32 root, uint16 numRoots, uint256 index) public { + numRoots = uint16(bound(numRoots, 1, 100)); + index = bound(index, 0, uint256(numRoots - 1)); + + bytes32[] memory roots = new bytes32[](numRoots); + cheats.startPrank(rewardsUpdater); + for (uint16 i = 0; i < numRoots; ++i) { + roots[i] = keccak256(abi.encodePacked(root, i)); + + uint32 activationDelay = uint32(block.timestamp) + rewardsCoordinator.activationDelay(); + rewardsCoordinator.submitRoot(roots[i], uint32(block.timestamp - 1)); + cheats.warp(activationDelay); + } + cheats.stopPrank(); + + assertEq(index, rewardsCoordinator.getRootIndexFromHash(roots[index]), "root index not found"); + } +} + +/// @notice Tests for sets of JSON data with different distribution roots +contract RewardsCoordinatorUnitTests_processClaim is RewardsCoordinatorUnitTests { + using stdStorage for StdStorage; + + /// @notice earner address used for proofs + address earner = 0xF2288D736d27C1584Ebf7be5f52f9E4d47251AeE; + + /// @notice mock token bytecode + bytes mockTokenBytecode; + + uint32 prevRootCalculationEndTimestamp; + + // Temp storage for managing stack in _parseProofData + bytes32 merkleRoot; + uint32 earnerIndex; + bytes earnerTreeProof; + address proofEarner; + bytes32 earnerTokenRoot; function setUp() public virtual override { RewardsCoordinatorUnitTests.setUp(); @@ -1438,6 +2668,60 @@ contract RewardsCoordinatorUnitTests_processClaim is RewardsCoordinatorUnitTests mockTokenBytecode = address(mockToken).code; } + /// @notice Claim against latest submitted root, rootIndex 3 using batch claim. + /// Limit fuzz runs to speed up tests since these require reading from JSON + /// forge-config: default.fuzz.runs = 10 + function testFuzz_processClaims_LatestRoot( + bool setClaimerFor, + address claimerFor + ) public filterFuzzedAddressInputs(claimerFor) { + // if setClaimerFor is true, set the earners claimer to the fuzzed address + address claimer; + if (setClaimerFor) { + cheats.prank(earner); + rewardsCoordinator.setClaimerFor(claimerFor); + claimer = claimerFor; + } else { + claimer = earner; + } + + // Parse all 3 claim proofs for distributionRoots 0,1,2 respectively + IRewardsCoordinator.RewardsMerkleClaim[] memory claims = _parseAllProofs(); + IRewardsCoordinator.RewardsMerkleClaim memory claim = claims[2]; + + uint32 rootIndex = claim.rootIndex; + IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex( + rootIndex + ); + cheats.warp(distributionRoot.activatedAt); + + // Claim against root and check balances before/after, and check it matches the difference between + // cumulative claimed and earned. + cheats.startPrank(claimer); + assertTrue(rewardsCoordinator.checkClaim(claim), "RewardsCoordinator.checkClaim: claim not valid"); + + uint256[] memory totalClaimedBefore = _getCumulativeClaimed(earner, claim); + uint256[] memory earnings = _getCumulativeEarnings(claim); + uint256[] memory tokenBalancesBefore = _getClaimTokenBalances(claimer, claim); + + _assertRewardsClaimedEvents(distributionRoot.root, claim, claimer); + IRewardsCoordinator.RewardsMerkleClaim[] memory batchClaim = new IRewardsCoordinator.RewardsMerkleClaim[](1); + batchClaim[0] = claim; + rewardsCoordinator.processClaims(batchClaim, claimer); + + uint256[] memory tokenBalancesAfter = _getClaimTokenBalances(claimer, claim); + + for (uint256 i = 0; i < totalClaimedBefore.length; ++i) { + assertEq( + earnings[i] - totalClaimedBefore[i], + tokenBalancesAfter[i] - tokenBalancesBefore[i], + "Token balance not incremented by earnings amount" + ); + } + + cheats.stopPrank(); + } + /// @notice Claim against latest submitted root, rootIndex 3 /// Limit fuzz runs to speed up tests since these require reading from JSON /// forge-config: default.fuzz.runs = 10 @@ -1460,7 +2744,9 @@ contract RewardsCoordinatorUnitTests_processClaim is RewardsCoordinatorUnitTests IRewardsCoordinator.RewardsMerkleClaim memory claim = claims[2]; uint32 rootIndex = claim.rootIndex; - IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex(rootIndex); + IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex( + rootIndex + ); cheats.warp(distributionRoot.activatedAt); // Claim against root and check balances before/after, and check it matches the difference between @@ -1509,7 +2795,9 @@ contract RewardsCoordinatorUnitTests_processClaim is RewardsCoordinatorUnitTests IRewardsCoordinator.RewardsMerkleClaim memory claim = claims[0]; uint32 rootIndex = claim.rootIndex; - IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex(rootIndex); + IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex( + rootIndex + ); cheats.warp(distributionRoot.activatedAt); // Claim against root and check balances before/after, and check it matches the difference between @@ -1560,7 +2848,8 @@ contract RewardsCoordinatorUnitTests_processClaim is RewardsCoordinatorUnitTests // 1. Claim against first root { uint32 rootIndex = claim.rootIndex; - IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex(rootIndex); + IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator + .getDistributionRootAtIndex(rootIndex); cheats.warp(distributionRoot.activatedAt); // Claim against root and check balances before/after, and check it matches the difference between @@ -1592,7 +2881,8 @@ contract RewardsCoordinatorUnitTests_processClaim is RewardsCoordinatorUnitTests claim = claims[1]; { uint32 rootIndex = claim.rootIndex; - IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex(rootIndex); + IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator + .getDistributionRootAtIndex(rootIndex); cheats.warp(distributionRoot.activatedAt); // Claim against root and check balances before/after, and check it matches the difference between @@ -1624,7 +2914,8 @@ contract RewardsCoordinatorUnitTests_processClaim is RewardsCoordinatorUnitTests claim = claims[2]; { uint32 rootIndex = claim.rootIndex; - IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex(rootIndex); + IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator + .getDistributionRootAtIndex(rootIndex); cheats.warp(distributionRoot.activatedAt); // Claim against root and check balances before/after, and check it matches the difference between @@ -1672,10 +2963,12 @@ contract RewardsCoordinatorUnitTests_processClaim is RewardsCoordinatorUnitTests cheats.startPrank(rewardsUpdater); rewardsCoordinator.submitRoot(root, 1); uint32 rootIndex = 0; - IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex(rootIndex); + IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex( + rootIndex + ); rewardsCoordinator.disableRoot(rootIndex); cheats.stopPrank(); - + cheats.warp(distributionRoot.activatedAt); cheats.startPrank(claimer); @@ -1709,7 +3002,8 @@ contract RewardsCoordinatorUnitTests_processClaim is RewardsCoordinatorUnitTests // 1. Claim against first root { uint32 rootIndex = claim.rootIndex; - IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex(rootIndex); + IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator + .getDistributionRootAtIndex(rootIndex); cheats.warp(distributionRoot.activatedAt); // Claim against root and check balances before/after, and check it matches the difference between @@ -1740,7 +3034,8 @@ contract RewardsCoordinatorUnitTests_processClaim is RewardsCoordinatorUnitTests // 2. Claim against first root again, expect a revert { uint32 rootIndex = claim.rootIndex; - IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex(rootIndex); + IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator + .getDistributionRootAtIndex(rootIndex); cheats.warp(distributionRoot.activatedAt); // Claim against root and check balances before/after, and check it matches the difference between @@ -1778,7 +3073,9 @@ contract RewardsCoordinatorUnitTests_processClaim is RewardsCoordinatorUnitTests IRewardsCoordinator.RewardsMerkleClaim memory claim = claims[2]; uint32 rootIndex = claim.rootIndex; - IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex(rootIndex); + IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex( + rootIndex + ); cheats.warp(distributionRoot.activatedAt); // Modify Earnings @@ -1819,7 +3116,9 @@ contract RewardsCoordinatorUnitTests_processClaim is RewardsCoordinatorUnitTests IRewardsCoordinator.RewardsMerkleClaim memory claim = claims[2]; uint32 rootIndex = claim.rootIndex; - IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex(rootIndex); + IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex( + rootIndex + ); cheats.warp(distributionRoot.activatedAt); // Modify Earner @@ -1858,7 +3157,9 @@ contract RewardsCoordinatorUnitTests_processClaim is RewardsCoordinatorUnitTests IRewardsCoordinator.RewardsMerkleClaim memory claim = claims[2]; uint32 rootIndex = claim.rootIndex; - IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex(rootIndex); + IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex( + rootIndex + ); cheats.warp(distributionRoot.activatedAt); assertTrue(rewardsCoordinator.checkClaim(claim), "RewardsCoordinator.checkClaim: claim not valid"); @@ -1899,7 +3200,9 @@ contract RewardsCoordinatorUnitTests_processClaim is RewardsCoordinatorUnitTests IRewardsCoordinator.RewardsMerkleClaim memory claim = claims[2]; uint32 rootIndex = claim.rootIndex; - IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex(rootIndex); + IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex( + rootIndex + ); cheats.warp(distributionRoot.activatedAt); assertTrue(rewardsCoordinator.checkClaim(claim), "RewardsCoordinator.checkClaim: claim not valid"); @@ -1937,7 +3240,9 @@ contract RewardsCoordinatorUnitTests_processClaim is RewardsCoordinatorUnitTests IRewardsCoordinator.RewardsMerkleClaim memory claim = claims[2]; uint32 rootIndex = claim.rootIndex; - IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex(rootIndex); + IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex( + rootIndex + ); cheats.warp(distributionRoot.activatedAt); assertTrue(rewardsCoordinator.checkClaim(claim), "RewardsCoordinator.checkClaim: claim not valid"); @@ -1977,7 +3282,8 @@ contract RewardsCoordinatorUnitTests_processClaim is RewardsCoordinatorUnitTests // 1. Claim against first root where earner tree is full tree and earner and token index is last index of that tree height { uint32 rootIndex = claim.rootIndex; - IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex(rootIndex); + IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator + .getDistributionRootAtIndex(rootIndex); cheats.warp(distributionRoot.activatedAt); // Claim against root and check balances before/after, and check it matches the difference between @@ -2042,7 +3348,8 @@ contract RewardsCoordinatorUnitTests_processClaim is RewardsCoordinatorUnitTests // 1. Claim against first root where earner tree is full tree and earner and token index is last index of that tree height { uint32 rootIndex = claim.rootIndex; - IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex(rootIndex); + IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator + .getDistributionRootAtIndex(rootIndex); cheats.warp(distributionRoot.activatedAt); // Claim against root and check balances before/after, and check it matches the difference between @@ -2055,16 +3362,8 @@ contract RewardsCoordinatorUnitTests_processClaim is RewardsCoordinatorUnitTests uint256[] memory tokenBalancesBefore = _getClaimTokenBalances(claimer, claim); // Single tokenLeaf in earner's subtree, should be 0 index - assertEq( - claim.tokenIndices[0], - 0, - "TokenIndex should be 0" - ); - assertEq( - claim.tokenTreeProofs[0].length, - 0, - "TokenTreeProof should be empty" - ); + assertEq(claim.tokenIndices[0], 0, "TokenIndex should be 0"); + assertEq(claim.tokenTreeProofs[0].length, 0, "TokenTreeProof should be empty"); _assertRewardsClaimedEvents(distributionRoot.root, claim, claimer); rewardsCoordinator.processClaim(claim, claimer); @@ -2107,7 +3406,8 @@ contract RewardsCoordinatorUnitTests_processClaim is RewardsCoordinatorUnitTests // 1. Claim against first root where earner tree is full tree and earner and token index is last index of that tree height { uint32 rootIndex = claim.rootIndex; - IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator.getDistributionRootAtIndex(rootIndex); + IRewardsCoordinator.DistributionRoot memory distributionRoot = rewardsCoordinator + .getDistributionRootAtIndex(rootIndex); cheats.warp(distributionRoot.activatedAt); // Claim against root and check balances before/after, and check it matches the difference between @@ -2120,16 +3420,8 @@ contract RewardsCoordinatorUnitTests_processClaim is RewardsCoordinatorUnitTests uint256[] memory tokenBalancesBefore = _getClaimTokenBalances(claimer, claim); // Earner Leaf in merkle tree, should be 0 index - assertEq( - claim.earnerIndex, - 0, - "EarnerIndex should be 0" - ); - assertEq( - claim.earnerTreeProof.length, - 0, - "EarnerTreeProof should be empty" - ); + assertEq(claim.earnerIndex, 0, "EarnerIndex should be 0"); + assertEq(claim.earnerTreeProof.length, 0, "EarnerTreeProof should be empty"); _assertRewardsClaimedEvents(distributionRoot.root, claim, claimer); rewardsCoordinator.processClaim(claim, claimer); @@ -2230,15 +3522,25 @@ contract RewardsCoordinatorUnitTests_processClaim is RewardsCoordinatorUnitTests return claims; } - function _parseAllProofsMaxEarnerAndLeafIndices() internal virtual returns (IRewardsCoordinator.RewardsMerkleClaim[] memory) { + function _parseAllProofsMaxEarnerAndLeafIndices() + internal + virtual + returns (IRewardsCoordinator.RewardsMerkleClaim[] memory) + { IRewardsCoordinator.RewardsMerkleClaim[] memory claims = new IRewardsCoordinator.RewardsMerkleClaim[](1); - claims[0] = _parseProofData("src/test/test-data/rewardsCoordinator/processClaimProofs_MaxEarnerAndLeafIndices.json"); + claims[0] = _parseProofData( + "src/test/test-data/rewardsCoordinator/processClaimProofs_MaxEarnerAndLeafIndices.json" + ); return claims; } - function _parseAllProofsSingleTokenLeaf() internal virtual returns (IRewardsCoordinator.RewardsMerkleClaim[] memory) { + function _parseAllProofsSingleTokenLeaf() + internal + virtual + returns (IRewardsCoordinator.RewardsMerkleClaim[] memory) + { IRewardsCoordinator.RewardsMerkleClaim[] memory claims = new IRewardsCoordinator.RewardsMerkleClaim[](1); claims[0] = _parseProofData("src/test/test-data/rewardsCoordinator/processClaimProofs_SingleTokenLeaf.json"); @@ -2246,7 +3548,11 @@ contract RewardsCoordinatorUnitTests_processClaim is RewardsCoordinatorUnitTests return claims; } - function _parseAllProofsSingleEarnerLeaf() internal virtual returns (IRewardsCoordinator.RewardsMerkleClaim[] memory) { + function _parseAllProofsSingleEarnerLeaf() + internal + virtual + returns (IRewardsCoordinator.RewardsMerkleClaim[] memory) + { IRewardsCoordinator.RewardsMerkleClaim[] memory claims = new IRewardsCoordinator.RewardsMerkleClaim[](1); claims[0] = _parseProofData("src/test/test-data/rewardsCoordinator/processClaimProofs_SingleEarnerLeaf.json");