-
Notifications
You must be signed in to change notification settings - Fork 57
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #5 from aave/feat/other-features
Implement stake with permit/claim and restake/claim on behalf
- Loading branch information
Showing
11 changed files
with
2,333 additions
and
635 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
// SPDX-License-Identifier: agpl-3.0 | ||
pragma solidity 0.7.5; | ||
|
||
import {IERC20} from './IERC20.sol'; | ||
|
||
interface IERC20WithPermit is IERC20 { | ||
function permit( | ||
address owner, | ||
address spender, | ||
uint256 value, | ||
uint256 deadline, | ||
uint8 v, | ||
bytes32 r, | ||
bytes32 s | ||
) external; | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
// SPDX-License-Identifier: agpl-3.0 | ||
pragma solidity 0.7.5; | ||
|
||
import {IStakedToken} from './IStakedToken.sol'; | ||
|
||
interface IStakedTokenV3 is IStakedToken { | ||
function exchangeRate() external view returns (uint256); | ||
|
||
function getCooldownPaused() external view returns (bool); | ||
|
||
function setCooldownPause(bool paused) external; | ||
|
||
function slash(address destination, uint256 amount) external; | ||
|
||
function getMaxSlashablePercentage() external view returns (uint256); | ||
|
||
function setMaxSlashablePercentage(uint256 percentage) external; | ||
|
||
function stakeWithPermit( | ||
address from, | ||
address to, | ||
uint256 amount, | ||
uint256 deadline, | ||
uint8 v, | ||
bytes32 r, | ||
bytes32 s | ||
) external; | ||
|
||
function claimRewardsOnBehalf( | ||
address from, | ||
address to, | ||
uint256 amount | ||
) external; | ||
|
||
function redeemOnBehalf( | ||
address from, | ||
address to, | ||
uint256 amount | ||
) external; | ||
|
||
function claimRewardsAndStake(address to, uint256 amount) external; | ||
|
||
function claimRewardsAndRedeem( | ||
address to, | ||
uint256 claimAmount, | ||
uint256 redeemAmount | ||
) external; | ||
|
||
function claimRewardsAndStakeOnBehalf( | ||
address from, | ||
address to, | ||
uint256 amount | ||
) external; | ||
|
||
function claimRewardsAndRedeemOnBehalf( | ||
address from, | ||
address to, | ||
uint256 claimAmount, | ||
uint256 redeemAmount | ||
) external; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.