솔리디티 API
Solidity-docgen으로 생성된 문서
Aura토큰
기본적으로 VoterProxy(Booster)의 "오퍼레이터"가 운영하는 발행 기능이 있는 ERC20입니다.
발행 일정은 스테이킹을 통해 획득한 CRV의 양에 따라 결정되며, 공급 곡선(절벽 등)에 따라 분배됩니다. 이는ConvexToken의 포크입니다.
operator
vecrvProxy
EMISSIONS_MAX_SUPPLY
INIT_MINT_AMOUNT
totalCliffs
reductionPerCliff
minter
minterMinted
Initialised
OperatorChanged
constructor
init
Initialise and mints initial supply of tokens.
updateOperator
This can be called if the operator of the voterProxy somehow changes.
mint
Mints AURA to a given user based on the BAL supply schedule.
minterMint
Allows minter to mint to a specific address
AuraBalRewardPool
Modifications from convex-platform/contracts/contracts/BaseRewardPool.sol: - Delayed start (tokens transferred then delay is enforced before notification) - One time duration of 14 days - Remove child reward contracts - Penalty on claim at 20%
rewardToken
stakingToken
duration
rewardManager
auraLocker
penaltyForwarder
pendingPenalty
startTime
periodFinish
rewardRate
lastUpdateTime
rewardPerTokenStored
_totalSupply
userRewardPerTokenPaid
rewards
_balances
RewardAdded
Staked
Withdrawn
RewardPaid
PenaltyForwarded
Rescued
constructor
Simple constructor
totalSupply
balanceOf
updateReward
lastTimeRewardApplicable
rewardPerToken
earned
stake
stakeAll
stakeFor
withdraw
getReward
Gives a staker their rewards
forwardPenalty
Forwards to the penalty forwarder for distro to Aura Lockers
rescueReward
Rescues the reward token provided it hasn't been initiated yet
setLocker
Updates the locker address
initialiseRewards
Called once to initialise the rewards based on balance of stakeToken
AuraClaimZap
Claim zap to bundle various reward claims
Claims from all pools, and stakes cvxCrv and CVX if wanted. v2: - change exchange to use curve pool - add getReward(address,token) type - add option to lock cvx - add option use all funds in wallet
crv
cvx
cvxCrv
crvDepositWrapper
cvxCrvRewards
locker
owner
Options
constructor
getName
setApprovals
Approve spending of: crv -> crvDepositor cvxCrv -> cvxCrvRewards cvx -> Locker
_checkOption
Use bitmask to check if option flag is set
claimRewards
Claim all the rewards
_claimExtras
Claim additional rewards from: - cvxCrvRewards - cvxLocker
AuraLocker
Effectively allows for rolling 16 week lockups of CVX, and provides balances available at each epoch (1 week). Also receives cvxCrv from CvxStakingProxy
and redistributes to depositors.
Invdividual and delegatee vote power lookups both use independent accounting mechanisms.
RewardData
UserData
EarnedData
Balances
LockedBalance
Epoch
DelegateeCheckpoint
rewardTokens
queuedRewards
newRewardRatio
rewardData
rewardDistributors
userData
rewardsDuration
lockDuration
lockedSupply
epochs
balances
userLocks
_delegates
_checkpointedVotes
delegateeUnlocks
blacklist
stakingToken
cvxCrv
denominator
cvxcrvStaking
kickRewardPerEpoch
kickRewardEpochDelay
isShutdown
_name
_symbol
_decimals
DelegateChanged
DelegateCheckpointed
Recovered
RewardPaid
Staked
Withdrawn
KickReward
RewardAdded
BlacklistModified
KickIncentiveSet
Shutdown
constructor
updateReward
notBlacklisted
modifyBlacklist
addReward
approveRewardDistributor
setKickIncentive
shutdown
recoverERC20
setApprovals
lock
_lock
getReward
getReward
getReward
checkpointEpoch
_checkpointEpoch
processExpiredLocks
kickExpiredLocks
emergencyWithdraw
_processExpiredLocks
delegate
Delegate votes from the sender to newDelegatee
.
_checkpointDelegate
delegates
Get the address account
is currently delegating to.
getVotes
Gets the current votes balance for account
checkpoints
Get the pos
-th checkpoint for account
.
numCheckpoints
Get number of checkpoints for account
.
getPastVotes
Retrieve the number of votes for account
at the end of blockNumber
.
getPastTotalSupply
Retrieve the totalSupply
at the end of timestamp
. Note, this value is the sum of all balances. It is but NOT the sum of all the delegated votes!
_checkpointsLookup
Lookup a value in a list of (sorted) checkpoints. Copied from oz/ERC20Votes.sol
balanceOf
balanceAtEpochOf
lockedBalances
totalSupply
totalSupplyAtEpoch
findEpochId
epochCount
decimals
name
symbol
claimableRewards
lastTimeRewardApplicable
rewardPerToken
_earned
_lastTimeRewardApplicable
_rewardPerToken
queueNewRewards
_notifyReward
AuraMerkleDrop
Forked from convex-platform/contracts/contracts/MerkleAirdrop.sol. Changes: - solc 0.8.11 & OpenZeppelin MerkleDrop - Delayed start w/ trigger - EndTime for withdrawal to treasuryDAO - Penalty on claim & AuraLocker lock (only if address(auraLocker) != 0) - Non custodial (cannot change root)
dao
merkleRoot
aura
auraLocker
penaltyForwarder
pendingPenalty
deployTime
startTime
expiryTime
hasClaimed
DaoSet
RootSet
StartedEarly
ExpiredWithdrawn
LockerSet
Claimed
PenaltyForwarded
Rescued
constructor
setDao
setRoot
startEarly
withdrawExpired
setLocker
rescueReward
claim
forwardPenalty
AuraMinter
Wraps the AuraToken minterMint function and protects from inflation until 3 years have passed.
Ownership initially owned by the DAO, but likely transferred to smart contract wrapper or additional value system at some stage as directed by token holders.
aura
Aura token
inflationProtectionTime
Timestamp upon which minting will be possible
constructor
mint
Mint function allows the owner of the contract to inflate AURA post protection time
AuraPenaltyForwarder
Receives a given token and forwards it on to a distribution contract.
distributor
token
distributionDelay
lastDistribution
Forwarded
DistributorChanged
constructor
During deployment approves the distributor to spend all tokens
forward
Forwards the complete balance of token in this contract to the distributor
setDistributor
Updates distributor address
AuraStakingProxy
Receives CRV from the Booster as overall reward, then distributes to vlCVX holders. Also acts as a depositor proxy to support deposit/withdrawals from the CVX staking contract.
From CVX: - receive tokens to stake - get current staked balance - withdraw staked tokens - send rewards back to owner(cvx locker) - register token types that can be distributed
crv
cvx
cvxCrv
keeper
crvDepositorWrapper
outputBps
denominator
rewards
owner
pendingOwner
callIncentive
RewardsDistributed
CallIncentiveChanged
constructor
setCrvDepositorWrapper
Set CrvDepositorWrapper
setKeeper
Set keeper
setPendingOwner
Set pending owner
applyPendingOwner
Apply pending owner
setCallIncentive
Set call incentive
setRewards
Set reward address
setApprovals
Approve crvDepositorWrapper to transfer contract CRV and rewards to transfer cvxCrv
rescueToken
Transfer stuck ERC20 tokens to _to
distribute
distribute
Collects cvxCRV rewards from cvxRewardPool, converts any CRV deposited directly from the booster, and then applies the rewards to the cvxLocker, rewarding the caller in the process.
_distribute
distributeOther
Allow generic token distribution in case a new reward is ever added
AuraVestedEscrow
Vests tokens over a given timeframe to an array of recipients. Allows locking of these tokens directly to staking contract.
Adaptations: - One time initialisation - Consolidation of fundAdmin/admin - Lock in AuraLocker by default - Start and end time
rewardToken
admin
funder
auraLocker
startTime
endTime
totalTime
initialised
totalLocked
totalClaimed
Funded
Cancelled
Claim
constructor
setAdmin
Change contract admin
setLocker
Change locker contract address
fund
Fund recipients with rewardTokens
cancel
Cancel recipients vesting rewardTokens
available
Available amount to claim
remaining
Total remaining vested amount
_totalVestedOf
Get total amount vested for this timestamp
claim
_claim
Claim reward token (Aura) and lock it.
Deposits $BAL into a BAL/WETH BPT. Hooks into TWAP to determine minOut.
Abstract contract for depositing BAL -> balBPT -> auraBAL via crvDepositor
BALANCER_VAULT
BAL
WETH
BALANCER_POOL_TOKEN
BAL_ETH_POOL_ID
constructor
_setApprovals
_getBptPrice
_getMinOut
_investBalToPool
BalLiquidityProvider
Provides initial liquidity to a Balancer pool on behalf of a given DAO
startToken
pairToken
minPairAmount
provider
dao
bVault
LiquidityProvided
MinPairAmountChanged
constructor
provideLiquidity
Provides liquidity on behalf of the dao, in a non-custodial manner. Has protections in place to ensure that no erroneous liquidity data gets added.
changeMinPairAmount
Allows the DAO to change the minimum amount of the pair token that must be added as liquidity
rescueToken
Rescues a given token from the contract. Only provider or DAO can call this function.
ChefForwarder
pid
briber
chef
constructor
setBriber
setPid
deposit
claim
ExtraRewardsDistributor
Allows anyone to distribute rewards to the AuraLocker at a given epoch.
auraLocker
canAddReward
rewardData
rewardEpochs
userClaims
WhitelistModified
RewardAdded
RewardPaid
RewardForfeited
constructor
Simple constructor
modifyWhitelist
addReward
Add a reward to the current epoch. can be called multiple times for the same reward token
addRewardToEpoch
Add reward token to a specific epoch
_addReward
Transfer reward tokens from sender to contract for vlCVX holders
Add reward token for specific epoch
getReward
Claim rewards for a specific token since the first epoch.
getReward
Claim rewards for a specific token at a specific epoch
_getReward
Claim rewards for a specific token at a specific epoch
forfeitRewards
Allow a user to set their claimed index forward without claiming rewards Because claims cycle through all periods that a specific reward was given there becomes a situation where, for example, a new user could lock 2 years from now and try to claim a token that was given out every week prior. This would result in a 2mil gas checkpoint.(about 20k gas * 52 weeks * 2 years)
claimableRewards
Get claimable rewards (rewardToken) for vlCVX holder
claimableRewardsAtEpoch
Get claimable rewards for a token at a specific epoch
_allClaimableRewards
Get all claimable rewards by looping through each epoch starting with the latest saved epoch the user last claimed from
_claimableRewards
Get claimable rewards for a token at a specific epoch
rewardEpochsCount
Simply gets the current epoch count for a given reward token
RewardPool
deposit
RewardPoolDepositWrapper
Peripheral contract that allows users to deposit into a Balancer pool and then stake their BPT into Aura in 1 tx. Flow: - rawToken.transferFrom(user, address(this)) - vault.deposit(rawToken), receive poolToken - poolToken.approve(rewardPool) - rewardPool.deposit(poolToken), converts to auraBPT and then deposits
bVault
constructor
depositSingle
Deposits a single raw token into a BPT before depositing in reward pool. Requires sender to approve this contract before calling.
Last updated