Verified contractPartial
Vault
Address0x3360b3f2b9ff8726be4ca2aaf88c4bb3722e3f12
- Balance
1.986 ETH
- Transactions
207
- Compiler
solc 0.4.14
- Same code
166 more contracts
Details
- Compiler
- solc 0.4.14+commit.c2215d46
- Language
- solidity
- Optimization
- Yes, 200 runs
- License
- Not stated
- Match
- Partialcreation code: no, runtime code: yes
- Verified on Sourcify
- Created in block
- 4,227,282
- Creation transaction
- 0x75584fc525…48a6109466
Vault.sol
// Submitted by EthereumHistory (ethereumhistory.com)
pragma solidity ^0.4.13;
contract Token {
function transfer(address _to, uint256 _amount) returns (bool success);
}
contract Controlled {
address public controller;
function Controlled() { controller = msg.sender; }
modifier onlyController { require(msg.sender == controller); _; }
function changeController(address _newController) onlyController {
controller = _newController;
}
}
contract Vault is Controlled {
address wallet;
event LogTransfer(address _to, uint256 _amount, address _token);
event LogTransferFailure(address _to, uint256 _amount, address _token);
event LogCollection(address _to, uint256 _amount);
event LogCollectionFailure(address _to, uint256 _amount);
function Vault(address _wallet) { wallet = _wallet; }
function () payable { }
function doTransfer(address _token, uint256 _amount) onlyController {
if (Token(_token).transfer(wallet, _amount)) {
LogTransfer(wallet, _amount, _token);
} else {
LogTransferFailure(wallet, _amount, _token);
}
}
function collect(uint256 _amount) onlyController {
if (wallet.send(_amount)) {
LogCollection(wallet, _amount);
} else {
LogCollectionFailure(wallet, _amount);
}
}
}
Compiler settingsShow
{
"optimizer": {
"runs": 200,
"enabled": true
}
}Source code and metadata: Sourcify.
The source code belongs to the authors of the contract.