0 txs
7 calls
constructor
constructor((address evc, address balanceTracker, address permit2, bool isHarvestCoolDownCheckOn) _integrationsParams)
functions
EVC
viewfunction EVC() view returns (address)
getStrategy
viewfunction getStrategy(address _strategy) view returns (tuple)
totalAllocationPoints
viewfunction totalAllocationPoints() view returns (uint256)
addStrategy
nonpayablefunction addStrategy(address _strategy, uint256 _allocationPoints)
adjustAllocationPoints
nonpayablefunction adjustAllocationPoints(address _strategy, uint256 _newPoints)
removeStrategy
nonpayablefunction removeStrategy(address _strategy)
setStrategyCap
nonpayablefunction setStrategyCap(address _strategy, uint16 _cap)
toggleStrategyEmergencyStatus
nonpayablefunction toggleStrategyEmergencyStatus(address _strategy)
events
AddStrategy
event AddStrategy(address indexed strategy, uint256 allocationPoints)
AdjustAllocationPoints
event AdjustAllocationPoints(address indexed strategy, uint256 oldPoints, uint256 newPoints)
DeductLoss
event DeductLoss(uint256 socializedAmount)
Gulp
event Gulp(uint256 interestLeft, uint256 interestSmearEnd)
InterestUpdated
event InterestUpdated(uint256 interestAccrued, uint256 interestLeft)
RemoveStrategy
event RemoveStrategy(address indexed strategy)
SetStrategyCap
event SetStrategyCap(address indexed strategy, uint256 cap)
ToggleStrategyEmergencyStatus
event ToggleStrategyEmergencyStatus(address indexed strategy, bool isSetToEmergency)
errors
CanNotRemoveCashReserve
error CanNotRemoveCashReserve()
CanNotRemoveStrategyWithAllocatedAmount
error CanNotRemoveStrategyWithAllocatedAmount()
CanNotToggleStrategyEmergencyStatus
error CanNotToggleStrategyEmergencyStatus()
ControllerDisabled
error ControllerDisabled()
EmptyError
error EmptyError()
EVC_InvalidAddress
error EVC_InvalidAddress()
InactiveStrategy
error InactiveStrategy()
InvalidAllocationPoints
error InvalidAllocationPoints()
InvalidStrategyAsset
error InvalidStrategyAsset()
MaxStrategiesExceeded
error MaxStrategiesExceeded()
NoCapOnCashReserveStrategy
error NoCapOnCashReserveStrategy()
NotAuthorized
error NotAuthorized()
Reentrancy
error Reentrancy()
SafeCastOverflowedUintDowncast
error SafeCastOverflowedUintDowncast(uint8 bits, uint256 value)
StrategyAlreadyExist
error StrategyAlreadyExist()
StrategyCapExceedMax
error StrategyCapExceedMax()
StrategyShouldBeActive
error StrategyShouldBeActive()
ViewReentrancy
error ViewReentrancy()
creation bytecode
0x610100604052348015610010575f5ffd5b50604051611d08380380611d0883398101604081905261002f916100a5565b805181906001600160a01b03811661005a57604051638133abd160e01b815260040160405180910390fd5b6001600160a01b039081166080526020820151811660a05260408201511660c05260600151151560e05250610133565b80516001600160a01b03811681146100a0575f5ffd5b919050565b5f60808284031280156100b6575f5ffd5b50604051608081016001600160401b03811182821017156100e557634e487b7160e01b5f52604160045260245ffd5b6040526100f18361008a565b81526100ff6020840161008a565b60208201526101106040840161008a565b604082015260608301518015158114610127575f5ffd5b60608201529392505050565b60805160a05160c05160e051611b9e61016a5f395f50505f50505f50505f818160d1015281816115d801526116130152611b9e5ff3fe608060405234801561000f575f5ffd5b5060043610610085575f3560e01c8063c9411e2211610058578063c9411e2214610100578063d51988d014610113578063e7f3fbde14610126578063f8806a131461013c575f5ffd5b80631671fcad14610089578063175188e81461009e57806355c00f24146100b1578063a70354a1146100c4575b5f5ffd5b61009c610097366004611890565b61015c565b005b61009c6100ac3660046118ba565b610383565b61009c6100bf3660046118ba565b610633565b6040516001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001681526020015b60405180910390f35b61009c61010e366004611890565b610a43565b61009c6101213660046118dc565b610da5565b61012e610f02565b6040519081526020016100f7565b61014f61014a3660046118ba565b610f25565b6040516100f7919061192d565b610164611018565b6001600160a01b0382165f9081527f557a0cdd38e5249281b5bc89e23dd8e4f8f0223d657d77792700289d81047f0460209081526040808320815160808101835281546001600160781b0381168252600160781b81046001600160601b031694820194909452600160d81b840461ffff16928101929092525f516020611b295f395f51905f5293926060830190600160e81b900460ff16600281111561020c5761020c611919565b600281111561021d5761021d611919565b905250905060018160600151600281111561023a5761023a611919565b146102585760405163c7f5bd2f60e01b815260040160405180910390fd5b6001600160a01b03841661028657825f0361028657604051636b671e7360e01b815260040160405180910390fd5b61028f8361107a565b6001600160a01b0385165f908152600484016020908152604090912080547fffffffffff000000000000000000000000ffffffffffffffffffffffffffffff16600160781b6001600160601b039485160217905582015160028401549116906102f99085906119a4565b61030391906119bd565b6002830155602081810151604080516001600160601b0390921682529181018590526001600160a01b038616917f129792c4d263f75b0ef004e93ec5229320369629124b41f3eec03a02759bbf9f91015b60405180910390a250505f516020611b495f395f51905f5280546001600160f81b0316600160f81b1790555050565b61038b611018565b6001600160a01b0381166103b2576040516302ca274360e01b815260040160405180910390fd5b6001600160a01b0381165f9081527f557a0cdd38e5249281b5bc89e23dd8e4f8f0223d657d77792700289d81047f046020526040902080545f516020611b295f395f51905f529190600190600160e81b900460ff16600281111561041857610418611919565b146104365760405163c7f5bd2f60e01b815260040160405180910390fd5b80546001600160781b03161561045f57604051637872ae7760e11b815260040160405180910390fd5b610471602061046c6110b6565b6110c4565b8054600283018054600160781b9092046001600160601b0316915f906104989084906119bd565b909155505080547fffff000000000000000000000000000000ffffffffffffffffffffffffffffff16815560058201545f906104d6906001906119bd565b90505f5b8181101561059457846001600160a01b0316846005018281548110610501576105016119d0565b5f918252602090912001546001600160a01b03160361058c5783600501828154811061052f5761052f6119d0565b5f918252602090912001546005850180546001600160a01b03909216918390811061055c5761055c6119d0565b905f5260205f20015f6101000a8154816001600160a01b0302191690836001600160a01b03160217905550610594565b6001016104da565b50826005018054806105a8576105a86119e4565b5f8281526020812082015f19908101805473ffffffffffffffffffffffffffffffffffffffff191690559091019091556040516001600160a01b038616917fd3281a40d50ae838fe77dc627744037b8f0fc6a5711d66119a9b670c5cde41af91a250505f516020611b495f395f51905f5280546001600160f81b0316600160f81b1790555050565b50565b61063b611018565b6001600160a01b03811661066257604051637875a26b60e01b815260040160405180910390fd5b6001600160a01b0381165f9081527f557a0cdd38e5249281b5bc89e23dd8e4f8f0223d657d77792700289d81047f0460209081526040808320815160808101835281546001600160781b0381168252600160781b81046001600160601b031694820194909452600160d81b840461ffff16928101929092525f516020611b295f395f51905f5293926060830190600160e81b900460ff16600281111561070a5761070a611919565b600281111561071b5761071b611919565b90525090505f8160600151600281111561073757610737611919565b0361075557604051630631bc2160e51b815260040160405180910390fd5b61075d6111c6565b60018160600151600281111561077557610775611919565b03610847576001600160a01b0383165f9081526004830160205260409020805460ff60e81b1916600160e91b17905580516107b8906001600160781b03166112be565b80602001516001600160601b0316826002015f8282546107d891906119bd565b92505081905550805f01516001600160781b0316826001015f8282546107fe91906119bd565b9091555050604051600181526001600160a01b038416907f5df9037c93820d4f5f312e595e476c0e70a88241240712300aa71f990c36e6d89060200160405180910390a2610a15565b6040516370a0823160e01b81523060048201525f906001600160a01b038516906370a0823190602401602060405180830381865afa15801561088b573d5f5f3e3d5ffd5b505050506040513d601f19601f820116820180604052508101906108af91906119f8565b60405163266d6a8360e11b8152600481018290529091505f906001600160a01b03861690634cdad50690602401602060405180830381865afa1580156108f7573d5f5f3e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061091b91906119f8565b6001600160a01b0386165f9081526004860160205260409020805460ff60e81b1916600160e81b179055905061095081611361565b6001600160a01b0386165f9081526004860160209081526040822080546effffffffffffffffffffffffffffff19166001600160781b039490941693909317909255908401516002860180546001600160601b039092169290916109b59084906119a4565b9250508190555080846001015f8282546109cf91906119a4565b90915550506040515f81526001600160a01b038616907f5df9037c93820d4f5f312e595e476c0e70a88241240712300aa71f990c36e6d89060200160405180910390a250505b610a1d611394565b50505f516020611b495f395f51905f5280546001600160f81b0316600160f81b17905550565b610a4b611018565b7f557a0cdd38e5249281b5bc89e23dd8e4f8f0223d657d77792700289d81047f05545f516020611b295f395f51905f5290600a11610a9c576040516301a1443960e31b815260040160405180910390fd5b5f6001600160a01b0384165f908152600483016020526040902054600160e81b900460ff166002811115610ad257610ad2611919565b14610af05760405163634f694f60e11b815260040160405180910390fd5b7f0773e532dfede91f04b12a73d3d2acd361424f41f76b4fb79f090161e36b4e00546001600160a01b03166001600160a01b0316836001600160a01b03166338d52e0f6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610b60573d5f5f3e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610b849190611a0f565b6001600160a01b031614610bab5760405163e76673ef60e01b815260040160405180910390fd5b815f03610bcb57604051636b671e7360e01b815260040160405180910390fd5b610bd8601061046c6110b6565b60405180608001604052805f6001600160781b03168152602001610bfb8461107a565b6001600160601b031681525f6020820152604001600190526001600160a01b0384165f90815260048301602090815260409182902083518154928501519385015161ffff16600160d81b0261ffff60d81b196001600160601b03909516600160781b027fffffffffff0000000000000000000000000000000000000000000000000000009094166001600160781b03909216919091179290921792831682178155606084015190929091839160ff60e81b199091167fffff000000ffffffffffffffffffffffffffffffffffffffffffffffffffffff90911617600160e81b836002811115610cec57610cec611919565b021790555090505081816002015f828254610d0791906119a4565b90915550506005810180546001810182555f91825260209182902001805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b03861690811790915560405184815290917fad5c211a0d035244e85dedad8dff9545aa6a4c7670f7d8ce5a2b41360bfbe0be910160405180910390a2505f516020611b495f395f51905f5280546001600160f81b0316600160f81b1790555050565b610dad611018565b6001600160a01b0382165f9081527f557a0cdd38e5249281b5bc89e23dd8e4f8f0223d657d77792700289d81047f0460205260409020545f516020611b295f395f51905f5290600190600160e81b900460ff166002811115610e1157610e11611919565b14610e2f5760405163c7f5bd2f60e01b815260040160405180910390fd5b6001600160a01b038316610e5657604051633065768d60e01b815260040160405180910390fd5b8161ffff811615610e95576001600160781b03610e7661ffff8316611537565b1115610e95576040516326c0750560e11b815260040160405180910390fd5b6001600160a01b0384165f81815260048401602052604090819020805461ffff8516600160d81b0261ffff60d81b19909116179055517f489bcb5a7761098f08c51bf90cc7753f2dc54e9539ff9f3b9030ea7e5b86b27d9061035490869061ffff91909116815260200190565b5f610f0b611564565b5f5f516020611b295f395f51905f525b6002015491505090565b610f4c604080516080810182525f8082526020820181905291810182905290606082015290565b610f54611564565b6001600160a01b0382165f9081527f557a0cdd38e5249281b5bc89e23dd8e4f8f0223d657d77792700289d81047f046020908152604091829020825160808101845281546001600160781b0381168252600160781b81046001600160601b031693820193909352600160d81b830461ffff16938101939093525f516020611b295f395f51905f5292916060830190600160e81b900460ff166002811115610ffd57610ffd611919565b600281111561100e5761100e611919565b9052509392505050565b5f516020611b495f395f51905f52545f516020611b295f395f51905f529060ff600160f81b90910416600119016110625760405163558a1e0360e11b815260040160405180910390fd5b60060180546001600160f81b0316600160f91b179055565b5f6001600160601b038211156110b2576040516306dfcc6560e41b815260606004820152602481018390526044015b60405180910390fd5b5090565b5f6110bf6115cc565b905090565b7f557a0cdd38e5249281b5bc89e23dd8e4f8f0223d657d77792700289d81047f08545f516020611b295f395f51905f52906001600160a01b0381169074010000000000000000000000000000000000000000900463ffffffff818116918616165f03611131575050505050565b5f5f836001600160a01b03165f368860405160200161115293929190611a2a565b60408051601f198184030181529082905261116c91611a50565b5f604051808303815f865af19150503d805f81146111a5576040519150601f19603f3d011682016040523d82523d5f602084013e6111aa565b606091505b5091509150816111bd576111bd8161168c565b50505050505050565b5f516020611b495f395f51905f52545f516020611b295f395f51905f5290600160501b90046001600160a81b03165f6111fe826116b4565b905080156112b9576112108183611a66565b6006840180547fff000000000000000000000000000000000000000000ffffffffff000000000016600160501b6001600160a81b0384160264ffffffffff1916174264ffffffffff161790558354909250819084905f906112729084906119a4565b9091555050604080518281526001600160a81b03841660208201527f46ba83b1bb5d30bf76865a9c4d50e868ef6092e32e9dbca33926fe6d81c1a129910160405180910390a15b505050565b5f516020611b295f395f51905f5280545f816112d861177e565b6112e291906119bd565b6006840180547fff000000000000000000000000000000000000000000ffffffffffffffffffff16905590508084111561135b57928390039261132584836119bd565b83556040518481527fd923720a22e30955bb06e5d1b0849b32f5dfc178055a3416b2fd317659eda5a39060200160405180910390a15b50505050565b5f6001600160781b038211156110b2576040516306dfcc6560e41b815260786004820152602481018390526044016110a9565b61139c6111c6565b5f516020611b495f395f51905f52545f516020611b295f395f51905f5280549091600160501b90046001600160a81b0316905f9082906113da61177e565b6113e491906119bd565b6113ee91906119bd565b9050805f036113fc57505050565b5f61140e836001600160a81b03611a66565b6001600160a81b0316905080821115611425578091505b6008840154600160e81b900462ffffff166114408385611a85565b60068601805464ffffffffff19164264ffffffffff81169190911790915590945061146c9082906119a4565b6006860180547fff0000000000000000000000000000000000000000000000000000ffffffffff166501000000000064ffffffffff93909316929092027fff000000000000000000000000000000000000000000ffffffffffffffffffff1691909117600160501b6001600160a81b038716021790557fe435ccc388e2041f0f453c668f3437d28221b3fd0b446dbfae9c66d4a7b380a18461150e83426119a4565b604080516001600160a81b03909316835260208301919091520160405180910390a15050505050565b5f61ffff821680820361154d57505f1992915050565b6064603f8216600a0a600683901c02049392505050565b5f516020611b495f395f51905f52545f516020611b295f395f51905f529060ff600160f81b90910416600119016106305760088101546001600160a01b03163314806115af57503330145b61063057604051630622e97b60e51b815260040160405180910390fd5b5f336001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016810361168757604051630c281d0f60e11b81525f60048201527f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316906318503a1e906024016040805180830381865afa15801561165f573d5f5f3e3d5ffd5b505050506040513d601f19601f820116820180604052508101906116839190611aa4565b5090505b919050565b80511561169b57805181602001fd5b604051634f3d7def60e01b815260040160405180910390fd5b5f6116bd611854565b5f036116ca57505f919050565b5f516020611b495f395f51905f52545f516020611b295f395f51905f529065010000000000900464ffffffffff1642811161170e575050506001600160a81b031690565b600682015464ffffffffff1642810361172b57505f949350505050565b5f6117368284611ad5565b64ffffffffff1690505f8264ffffffffff164261175391906119bd565b905081611769826001600160a81b038a16611af2565b6117739190611b09565b979650505050505050565b7f557a0cdd38e5249281b5bc89e23dd8e4f8f0223d657d77792700289d81047f01547f0773e532dfede91f04b12a73d3d2acd361424f41f76b4fb79f090161e36b4e00545f915f516020611b295f395f51905f52916001600160a01b03166040516370a0823160e01b81523060048201526001600160a01b0391909116906370a0823190602401602060405180830381865afa158015611820573d5f5f3e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061184491906119f8565b61184e91906119a4565b91505090565b5f807f52c63247e1f47db19d5ce0460030c497f067ca4cebf71ba98eeadabe20bace00610f1b565b6001600160a01b0381168114610630575f5ffd5b5f5f604083850312156118a1575f5ffd5b82356118ac8161187c565b946020939093013593505050565b5f602082840312156118ca575f5ffd5b81356118d58161187c565b9392505050565b5f5f604083850312156118ed575f5ffd5b82356118f88161187c565b9150602083013561ffff8116811461190e575f5ffd5b809150509250929050565b634e487b7160e01b5f52602160045260245ffd5b5f6080820190506001600160781b0383511682526001600160601b03602084015116602083015261ffff604084015116604083015260608301516003811061198357634e487b7160e01b5f52602160045260245ffd5b8060608401525092915050565b634e487b7160e01b5f52601160045260245ffd5b808201808211156119b7576119b7611990565b92915050565b818103818111156119b7576119b7611990565b634e487b7160e01b5f52603260045260245ffd5b634e487b7160e01b5f52603160045260245ffd5b5f60208284031215611a08575f5ffd5b5051919050565b5f60208284031215611a1f575f5ffd5b81516118d58161187c565b8284823760609190911b6bffffffffffffffffffffffff19169101908152601401919050565b5f82518060208501845e5f920191825250919050565b6001600160a81b0382811682821603908111156119b7576119b7611990565b6001600160a81b0381811683821601908111156119b7576119b7611990565b5f5f60408385031215611ab5575f5ffd5b8251611ac08161187c565b6020840151909250801515811461190e575f5ffd5b64ffffffffff82811682821603908111156119b7576119b7611990565b80820281158282048414176119b7576119b7611990565b5f82611b2357634e487b7160e01b5f52601260045260245ffd5b50049056fe557a0cdd38e5249281b5bc89e23dd8e4f8f0223d657d77792700289d81047f00557a0cdd38e5249281b5bc89e23dd8e4f8f0223d657d77792700289d81047f06a2646970667358221220cf76ba43e1f956091ddbb2a100f819783020820a2c0516b9dc7c1cf476afcb7f64736f6c634300081b00330000000000000000000000000c9a3dd6b8f28529d72d7f9ce918d493519ee3830000000000000000000000000d52d06ceb8dcdeeb40cfd9f17489b350dd7f8a3000000000000000000000000000000000022d473030f116ddee9f6b43ac78ba30000000000000000000000000000000000000000000000000000000000000001