View Source: contracts/core/Recoverable.sol
↗ Extends: ReentrancyGuard, IRecoverable ↘ Derived Contracts: AaveStrategy, BondPoolBase, CompoundStrategy, CoverBase, CoverReassurance, CoverStake, cxToken, cxTokenFactory, FakeRecoverable, Finalization, LiquidityEngine, NeptuneRouterV1, Policy, PolicyAdmin, Processor, ProtoBase, StakingPoolBase, VaultBase, VaultDelegateBase, VaultFactory, Witness
Recoverable
The recoverable contract enables "Recovery Agents" to recover Ether and ERC-20 tokens sent to this address. To learn more about our recovery policy, please refer to the following doc: https://docs.neptunemutual.com/usage/recovering-cryptocurrencies
Constants & Variables
contract IStore public s;
function (IStore store) internal nonpayable
Arguments
Name | Type | Description |
---|---|---|
store | IStore |
Source Code
constructor(IStore store) {
require(address(store) != address(0), "Invalid Store");
s = store;
}
Recover all Ether held by the contract. On success, no event is emitted because the recovery feature does not have any significance in the SDK or the UI.
function recoverEther(address sendTo) external nonpayable nonReentrant
Arguments
Name | Type | Description |
---|---|---|
sendTo | address |
Source Code
function recoverEther(address sendTo) external override nonReentrant {
s.mustNotBePaused();
AccessControlLibV1.mustBeRecoveryAgent(s);
BaseLibV1.recoverEtherInternal(sendTo);
}
Recover all ERC-20 compatible tokens sent to this address. On success, no event is emitted because the recovery feature does not have any significance in the SDK or the UI.
function recoverToken(address token, address sendTo) external nonpayable nonReentrant
Arguments
Name | Type | Description |
---|---|---|
token | address | ERC-20 The address of the token contract |
sendTo | address |
Source Code
function recoverToken(address token, address sendTo) external override nonReentrant {
s.mustNotBePaused();
AccessControlLibV1.mustBeRecoveryAgent(s);
BaseLibV1.recoverTokenInternal(token, sendTo);
}
- AaveStrategy
- AccessControl
- AccessControlLibV1
- Address
- BaseLibV1
- BokkyPooBahsDateTimeLibrary
- BondPool
- BondPoolBase
- BondPoolLibV1
- CompoundStrategy
- Context
- Cover
- CoverBase
- CoverLibV1
- CoverReassurance
- CoverStake
- CoverUtilV1
- cxToken
- cxTokenFactory
- cxTokenFactoryLibV1
- Delayable
- Destroyable
- ERC165
- ERC20
- FakeAaveLendingPool
- FakeCompoundDaiDelegator
- FakePriceOracle
- FakeRecoverable
- FakeStore
- FakeToken
- FakeUniswapPair
- FakeUniswapV2FactoryLike
- FakeUniswapV2PairLike
- FakeUniswapV2RouterLike
- FaultyAaveLendingPool
- FaultyCompoundDaiDelegator
- Finalization
- ForceEther
- Governance
- GovernanceUtilV1
- IAaveV2LendingPoolLike
- IAccessControl
- IBondPool
- IClaimsProcessor
- ICompoundERC20DelegatorLike
- ICover
- ICoverReassurance
- ICoverStake
- ICxToken
- ICxTokenFactory
- IERC165
- IERC20
- IERC20Detailed
- IERC20Metadata
- IERC3156FlashBorrower
- IERC3156FlashLender
- IFinalization
- IGovernance
- ILendingStrategy
- ILiquidityEngine
- IMember
- INeptuneRouterV1
- InvalidStrategy
- IPausable
- IPolicy
- IPolicyAdmin
- IPriceOracle
- IProtocol
- IRecoverable
- IReporter
- IResolution
- IResolvable
- IStakingPools
- IStore
- IStoreLike
- IUniswapV2FactoryLike
- IUniswapV2PairLike
- IUniswapV2RouterLike
- IUnstakable
- IVault
- IVaultDelegate
- IVaultFactory
- IWitness
- LiquidityEngine
- MaliciousToken
- MockAccessControlUser
- MockCoverUtilUser
- MockCxToken
- MockCxTokenPolicy
- MockCxTokenStore
- MockFlashBorrower
- MockLiquidityEngineUser
- MockProcessorStore
- MockProcessorStoreLib
- MockProtocol
- MockRegistryClient
- MockStore
- MockStoreKeyUtilUser
- MockValidationLibUser
- MockVault
- MockVaultLibUser
- NeptuneRouterV1
- NPM
- NpmDistributor
- NTransferUtilV2
- NTransferUtilV2Intermediate
- Ownable
- Pausable
- Policy
- PolicyAdmin
- PolicyHelperV1
- PoorMansERC20
- POT
- PriceLibV1
- Processor
- ProtoBase
- Protocol
- ProtoUtilV1
- Recoverable
- ReentrancyGuard
- RegistryLibV1
- Reporter
- Resolution
- Resolvable
- RoutineInvokerLibV1
- SafeERC20
- StakingPoolBase
- StakingPoolCoreLibV1
- StakingPoolInfo
- StakingPoolLibV1
- StakingPoolReward
- StakingPools
- Store
- StoreBase
- StoreKeyUtil
- StrategyLibV1
- Strings
- TimelockController
- Unstakable
- ValidationLibV1
- Vault
- VaultBase
- VaultDelegate
- VaultDelegateBase
- VaultDelegateWithFlashLoan
- VaultFactory
- VaultFactoryLibV1
- VaultLibV1
- VaultLiquidity
- VaultStrategy
- WithFlashLoan
- WithPausability
- WithRecovery
- Witness