contract_name
stringlengths
1
61
file_path
stringlengths
5
50.4k
contract_address
stringlengths
42
42
language
stringclasses
1 value
class_name
stringlengths
1
61
class_code
stringlengths
4
330k
class_documentation
stringlengths
0
29.1k
class_documentation_type
stringclasses
6 values
func_name
stringlengths
0
62
func_code
stringlengths
1
303k
func_documentation
stringlengths
2
14.9k
func_documentation_type
stringclasses
4 values
compiler_version
stringlengths
15
42
license_type
stringclasses
14 values
swarm_source
stringlengths
0
71
meta
dict
__index_level_0__
int64
0
60.4k
staking
contracts/staking.sol
0x904943e97a51a8260fd71187bc9d2c69feb8547f
Solidity
staking
contract staking is Ownable, ERC20 { using SafeMath for uint256; uint256 public currentRound = 0; uint24 public WEEK = 604800; uint256 public readyAt = 0; uint256 public deployTime = block.timestamp ; address public token_addr; SkyToken token_contract = SkyToken(token_addr); ...
deposit
function deposit(uint256 amount) external { token_contract.transferFrom(msg.sender, address(this), amount); _deposit(amount); roundDeposited[msg.sender] = currentRound; emit Deposit(msg.sender, amount); }
/** * @notice Deposits the `asset` into the contract and mint vault shares. * @param amount is the amount of `asset` to deposit */
NatSpecMultiLine
v0.8.3+commit.8d00100c
{ "func_code_index": [ 1434, 1688 ] }
26,000
staking
contracts/staking.sol
0x904943e97a51a8260fd71187bc9d2c69feb8547f
Solidity
staking
contract staking is Ownable, ERC20 { using SafeMath for uint256; uint256 public currentRound = 0; uint24 public WEEK = 604800; uint256 public readyAt = 0; uint256 public deployTime = block.timestamp ; address public token_addr; SkyToken token_contract = SkyToken(token_addr); ...
_deposit
function _deposit(uint256 amount) private { uint256 totalWithDepositedAmount = totalBalance(); // amount needs to be subtracted from totalBalance because it has already been // added to it from either IWETH.deposit and IERC20.safeTransferFrom uint256 total = totalWithDepositedAmount.sub(amount); ...
/** * @notice Mints the vault shares to the msg.sender * @param amount is the amount of `asset` deposited */
NatSpecMultiLine
v0.8.3+commit.8d00100c
{ "func_code_index": [ 1823, 2608 ] }
26,001
staking
contracts/staking.sol
0x904943e97a51a8260fd71187bc9d2c69feb8547f
Solidity
staking
contract staking is Ownable, ERC20 { using SafeMath for uint256; uint256 public currentRound = 0; uint24 public WEEK = 604800; uint256 public readyAt = 0; uint256 public deployTime = block.timestamp ; address public token_addr; SkyToken token_contract = SkyToken(token_addr); ...
withdraw
function withdraw(uint256 shares) public { uint256 withdrawAmount = getWithdrawAmount(shares, msg.sender); _burn(msg.sender, shares); token_contract.transfer(msg.sender, withdrawAmount); emit Withdraw(msg.sender, shares, withdrawAmount); }
/** * @notice Withdraws WETH from vault using vault shares * @param shares is the number of vault shares to be burned */
NatSpecMultiLine
v0.8.3+commit.8d00100c
{ "func_code_index": [ 2755, 3046 ] }
26,002
staking
contracts/staking.sol
0x904943e97a51a8260fd71187bc9d2c69feb8547f
Solidity
staking
contract staking is Ownable, ERC20 { using SafeMath for uint256; uint256 public currentRound = 0; uint24 public WEEK = 604800; uint256 public readyAt = 0; uint256 public deployTime = block.timestamp ; address public token_addr; SkyToken token_contract = SkyToken(token_addr); ...
getWithdrawAmount
function getWithdrawAmount(uint256 shares, address _addr) public view returns (uint256 amount) { uint256 PPS; //check if last user: cannot use shares, could be partial withdraw uint256 userShareBalance = balanceOf(_addr); if (userShareBalance == totalSupply()) { //last u...
/** * @dev Get withdraw amount of shares value * @param shares How many shares will be exchanged */
NatSpecMultiLine
v0.8.3+commit.8d00100c
{ "func_code_index": [ 3172, 3739 ] }
26,003
staking
contracts/staking.sol
0x904943e97a51a8260fd71187bc9d2c69feb8547f
Solidity
staking
contract staking is Ownable, ERC20 { using SafeMath for uint256; uint256 public currentRound = 0; uint24 public WEEK = 604800; uint256 public readyAt = 0; uint256 public deployTime = block.timestamp ; address public token_addr; SkyToken token_contract = SkyToken(token_addr); ...
getUserStartRound
function getUserStartRound(address _addr) public view returns (uint256 startRound) { startRound = roundDeposited[_addr]; }
/** * @dev Get round in which user started staking latest staking round */
NatSpecMultiLine
v0.8.3+commit.8d00100c
{ "func_code_index": [ 3834, 4007 ] }
26,004
staking
contracts/staking.sol
0x904943e97a51a8260fd71187bc9d2c69feb8547f
Solidity
staking
contract staking is Ownable, ERC20 { using SafeMath for uint256; uint256 public currentRound = 0; uint24 public WEEK = 604800; uint256 public readyAt = 0; uint256 public deployTime = block.timestamp ; address public token_addr; SkyToken token_contract = SkyToken(token_addr); ...
getMintAmount
function getMintAmount(uint timestamp) public view returns (uint256 amount) { if (timestamp < deployTime + 31557600) { amount = am1 ; } else { if (timestamp < deployTime + 63115200) { amount = am2 ; } else { if (timestamp < deployTime + 94672800) { ...
/** * @dev Get mint amount for roll() * @param timestamp current timestamp */
NatSpecMultiLine
v0.8.3+commit.8d00100c
{ "func_code_index": [ 4116, 4629 ] }
26,005
staking
contracts/staking.sol
0x904943e97a51a8260fd71187bc9d2c69feb8547f
Solidity
staking
contract staking is Ownable, ERC20 { using SafeMath for uint256; uint256 public currentRound = 0; uint24 public WEEK = 604800; uint256 public readyAt = 0; uint256 public deployTime = block.timestamp ; address public token_addr; SkyToken token_contract = SkyToken(token_addr); ...
changeMintAmounts
function changeMintAmounts(uint _am1, uint _am2, uint _am3, uint _am4) external onlyOwner { am1 = _am1 ; am2 = _am2 ; am3 = _am3 ; am4 = _am4 ; }
/** * @dev Change mint amounts for year 1, 2, 3 and >= 4 * @param _am1 Amount to mint per week in year 1 * @param _am2 Amount to mint per week in year 2 * @param _am3 Amount to mint per week in year 3 * @param _am4 Amount to mint per week in year 4 */
NatSpecMultiLine
v0.8.3+commit.8d00100c
{ "func_code_index": [ 4925, 5120 ] }
26,006
staking
contracts/staking.sol
0x904943e97a51a8260fd71187bc9d2c69feb8547f
Solidity
staking
contract staking is Ownable, ERC20 { using SafeMath for uint256; uint256 public currentRound = 0; uint24 public WEEK = 604800; uint256 public readyAt = 0; uint256 public deployTime = block.timestamp ; address public token_addr; SkyToken token_contract = SkyToken(token_addr); ...
roll
function roll() external onlyOwner { require(block.timestamp >= readyAt, "not ready to roll yet"); uint mintAmount = getMintAmount(block.timestamp)/52 ; token_contract.extMint(address(this), mintAmount); readyAt = block.timestamp.add(WEEK); currentRound = currentRound.add(1); ...
/* * @notice Rolls the vault's funds into a new short position. */
Comment
v0.8.3+commit.8d00100c
{ "func_code_index": [ 5207, 5701 ] }
26,007
staking
contracts/staking.sol
0x904943e97a51a8260fd71187bc9d2c69feb8547f
Solidity
staking
contract staking is Ownable, ERC20 { using SafeMath for uint256; uint256 public currentRound = 0; uint24 public WEEK = 604800; uint256 public readyAt = 0; uint256 public deployTime = block.timestamp ; address public token_addr; SkyToken token_contract = SkyToken(token_addr); ...
getPricePerShare
function getPricePerShare(uint256 round) public view returns (uint256 pps) { if (round == currentRound) { uint256 _assetBalance = assetBalance(); uint256 _shareSupply = totalSupply(); if (_shareSupply == 0) { pps = 1; } else { pps = (_assetBalance.mul...
/** * @dev Get pricePerShare of a certain round (multiplied with ppsMultiplier!) * @param round Round to get the pricePerShare */
NatSpecMultiLine
v0.8.3+commit.8d00100c
{ "func_code_index": [ 5857, 6342 ] }
26,008
staking
contracts/staking.sol
0x904943e97a51a8260fd71187bc9d2c69feb8547f
Solidity
staking
contract staking is Ownable, ERC20 { using SafeMath for uint256; uint256 public currentRound = 0; uint24 public WEEK = 604800; uint256 public readyAt = 0; uint256 public deployTime = block.timestamp ; address public token_addr; SkyToken token_contract = SkyToken(token_addr); ...
getUserAssetBalance
function getUserAssetBalance(address _addr) external view returns (uint256 balance) { uint256 userShareBalance = balanceOf(_addr); balance = getWithdrawAmount(userShareBalance, _addr); }
/** * @dev Get user asset balance using user share balance * @param _addr Address to get the user asset balance from */
NatSpecMultiLine
v0.8.3+commit.8d00100c
{ "func_code_index": [ 6488, 6734 ] }
26,009
staking
contracts/staking.sol
0x904943e97a51a8260fd71187bc9d2c69feb8547f
Solidity
staking
contract staking is Ownable, ERC20 { using SafeMath for uint256; uint256 public currentRound = 0; uint24 public WEEK = 604800; uint256 public readyAt = 0; uint256 public deployTime = block.timestamp ; address public token_addr; SkyToken token_contract = SkyToken(token_addr); ...
totalBalance
function totalBalance() public view returns (uint256) { return token_contract.balanceOf(address(this)); }
/** * @notice Returns the vault's total balance, including the amounts locked into a short position * @return total balance of the vault, including the amounts locked in third party protocols */
NatSpecMultiLine
v0.8.3+commit.8d00100c
{ "func_code_index": [ 6955, 7079 ] }
26,010
staking
contracts/staking.sol
0x904943e97a51a8260fd71187bc9d2c69feb8547f
Solidity
staking
contract staking is Ownable, ERC20 { using SafeMath for uint256; uint256 public currentRound = 0; uint24 public WEEK = 604800; uint256 public readyAt = 0; uint256 public deployTime = block.timestamp ; address public token_addr; SkyToken token_contract = SkyToken(token_addr); ...
assetBalance
function assetBalance() public view returns (uint256) { return token_contract.balanceOf(address(this)); }
/** * @notice Returns the asset balance on the vault. This balance is freely withdrawable by users. */
NatSpecMultiLine
v0.8.3+commit.8d00100c
{ "func_code_index": [ 7202, 7326 ] }
26,011
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { ...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. * * Arithmetic operations in Solidity wrap on overflow. This can easily result * in bugs, because programmers usually assume that an overflow raises an * error, which is the standard behavior in high level programming la...
NatSpecMultiLine
add
function add(uint256 a, uint256 b) internal pure returns (uint256) { uint256 c = a + b; require(c >= a, "SafeMath: addition overflow"); return c; }
/** * @dev Returns the addition of two unsigned integers, reverting on overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * - Addition cannot overflow. */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 243, 429 ] }
26,012
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { ...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. * * Arithmetic operations in Solidity wrap on overflow. This can easily result * in bugs, because programmers usually assume that an overflow raises an * error, which is the standard behavior in high level programming la...
NatSpecMultiLine
add
function add(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { uint256 c = a + b; require(c >= a, errorMessage); return c; }
/** * @dev Returns the addition of two unsigned integers, reverting with custom message on overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * - Addition cannot overflow. */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 675, 872 ] }
26,013
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { ...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. * * Arithmetic operations in Solidity wrap on overflow. This can easily result * in bugs, because programmers usually assume that an overflow raises an * error, which is the standard behavior in high level programming la...
NatSpecMultiLine
sub
function sub(uint256 a, uint256 b) internal pure returns (uint256) { return sub(a, b, "SafeMath: subtraction underflow"); }
/** * @dev Returns the subtraction of two unsigned integers, reverting on underflow (when the result is negative). * * Counterpart to Solidity's `-` operator. * * Requirements: * - Subtraction cannot underflow. */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 1136, 1278 ] }
26,014
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { ...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. * * Arithmetic operations in Solidity wrap on overflow. This can easily result * in bugs, because programmers usually assume that an overflow raises an * error, which is the standard behavior in high level programming la...
NatSpecMultiLine
sub
function sub(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { require(b <= a, errorMessage); uint256 c = a - b; return c; }
/** * @dev Returns the subtraction of two unsigned integers, reverting with custom message on underflow (when the result is negative). * * Counterpart to Solidity's `-` operator. * * Requirements: * - Subtraction cannot underflow. */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 1562, 1759 ] }
26,015
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { ...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. * * Arithmetic operations in Solidity wrap on overflow. This can easily result * in bugs, because programmers usually assume that an overflow raises an * error, which is the standard behavior in high level programming la...
NatSpecMultiLine
mul
function mul(uint256 a, uint256 b) internal pure returns (uint256) { // Gas optimization: this is cheaper than requiring 'a' not being zero, but the // benefit is lost if 'b' is also tested. // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522 if (a == 0) { return 0; ...
/** * @dev Returns the multiplication of two unsigned integers, reverting on overflow. * * Counterpart to Solidity's `*` operator. * * Requirements: * - Multiplication cannot overflow. */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 1997, 2473 ] }
26,016
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { ...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. * * Arithmetic operations in Solidity wrap on overflow. This can easily result * in bugs, because programmers usually assume that an overflow raises an * error, which is the standard behavior in high level programming la...
NatSpecMultiLine
mul
function mul(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { // Gas optimization: this is cheaper than requiring 'a' not being zero, but the // benefit is lost if 'b' is also tested. // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522 if (a == ...
/** * @dev Returns the multiplication of two unsigned integers, reverting on overflow. * * Counterpart to Solidity's `*` operator. * * Requirements: * - Multiplication cannot overflow. */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 2711, 3192 ] }
26,017
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { ...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. * * Arithmetic operations in Solidity wrap on overflow. This can easily result * in bugs, because programmers usually assume that an overflow raises an * error, which is the standard behavior in high level programming la...
NatSpecMultiLine
div
function div(uint256 a, uint256 b) internal pure returns (uint256) { return div(a, b, "SafeMath: division by zero"); }
/** * @dev Returns the integer division of two unsigned integers. * Reverts on division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. Note: this function uses a * `revert` opcode (which leaves remaining gas untouched) while Solidity * uses an invalid opcode to reve...
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 3655, 3792 ] }
26,018
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { ...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. * * Arithmetic operations in Solidity wrap on overflow. This can easily result * in bugs, because programmers usually assume that an overflow raises an * error, which is the standard behavior in high level programming la...
NatSpecMultiLine
div
function div(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { // Solidity only automatically asserts when dividing by 0 require(b > 0, errorMessage); uint256 c = a / b; // assert(a == b * c + a % b); // There is no case in which this doesn't hold return c; ...
/** * @dev Returns the integer division of two unsigned integers. * Reverts with custom message on division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. Note: this function uses a * `revert` opcode (which leaves remaining gas untouched) while Solidity * uses an in...
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 4275, 4625 ] }
26,019
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { ...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. * * Arithmetic operations in Solidity wrap on overflow. This can easily result * in bugs, because programmers usually assume that an overflow raises an * error, which is the standard behavior in high level programming la...
NatSpecMultiLine
mod
function mod(uint256 a, uint256 b) internal pure returns (uint256) { return mod(a, b, "SafeMath: modulo by zero"); }
/** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * Reverts when dividing by zero. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consumi...
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 5077, 5212 ] }
26,020
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { ...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. * * Arithmetic operations in Solidity wrap on overflow. This can easily result * in bugs, because programmers usually assume that an overflow raises an * error, which is the standard behavior in high level programming la...
NatSpecMultiLine
mod
function mod(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { require(b != 0, errorMessage); return a % b; }
/** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * Reverts with custom message when dividing by zero. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcod...
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 5684, 5855 ] }
26,021
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
IERC20
interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /**...
/** * @dev Interface of the ERC20 standard as defined in the EIP. */
NatSpecMultiLine
totalSupply
function totalSupply() external view returns (uint256);
/** * @dev Returns the amount of tokens in existence. */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 94, 154 ] }
26,022
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
IERC20
interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /**...
/** * @dev Interface of the ERC20 standard as defined in the EIP. */
NatSpecMultiLine
balanceOf
function balanceOf(address account) external view returns (uint256);
/** * @dev Returns the amount of tokens owned by `account`. */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 237, 310 ] }
26,023
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
IERC20
interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /**...
/** * @dev Interface of the ERC20 standard as defined in the EIP. */
NatSpecMultiLine
transfer
function transfer(address recipient, uint256 amount) external returns (bool);
/** * @dev Moves `amount` tokens from the caller's account to `recipient`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 534, 616 ] }
26,024
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
IERC20
interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /**...
/** * @dev Interface of the ERC20 standard as defined in the EIP. */
NatSpecMultiLine
allowance
function allowance(address owner, address spender) external view returns (uint256);
/** * @dev Returns the remaining number of tokens that `spender` will be * allowed to spend on behalf of `owner` through {transferFrom}. This is * zero by default. * * This value changes when {approve} or {transferFrom} are called. */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 895, 983 ] }
26,025
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
IERC20
interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /**...
/** * @dev Interface of the ERC20 standard as defined in the EIP. */
NatSpecMultiLine
approve
function approve(address spender, uint256 amount) external returns (bool);
/** * @dev Sets `amount` as the allowance of `spender` over the caller's tokens. * * Returns a boolean value indicating whether the operation succeeded. * * IMPORTANT: Beware that changing an allowance with this method brings the risk * that someone may use both the old and the new allowance by unfortunate ...
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 1647, 1726 ] }
26,026
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
IERC20
interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /**...
/** * @dev Interface of the ERC20 standard as defined in the EIP. */
NatSpecMultiLine
transferFrom
function transferFrom(address sender, address recipient, uint256 amount) external returns (bool);
/** * @dev Moves `amount` tokens from `sender` to `recipient` using the * allowance mechanism. `amount` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 2039, 2141 ] }
26,027
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
FuelToken
contract FuelToken { /// @notice EIP-20 token name for this token string public constant name = "PowerTrade Fuel Token"; /// @notice EIP-20 token symbol for this token string public constant symbol = "PTF"; /// @notice EIP-20 token decimals for this token uint8 public constant decimals...
// Copyright 2020 Compound Labs, Inc. // Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: // 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. // 2....
LineComment
allowance
function allowance(address account, address spender) external view returns (uint) { return allowances[account][spender]; }
/** * @notice Get the number of tokens `spender` is approved to spend on behalf of `account` * @param account The address of the account holding the funds * @param spender The address of the account spending the funds * @return The number of tokens approved */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 3516, 3657 ] }
26,028
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
FuelToken
contract FuelToken { /// @notice EIP-20 token name for this token string public constant name = "PowerTrade Fuel Token"; /// @notice EIP-20 token symbol for this token string public constant symbol = "PTF"; /// @notice EIP-20 token decimals for this token uint8 public constant decimals...
// Copyright 2020 Compound Labs, Inc. // Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: // 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. // 2....
LineComment
approve
function approve(address spender, uint rawAmount) external returns (bool) { uint96 amount; if (rawAmount == uint(-1)) { amount = uint96(-1); } else { amount = safe96(rawAmount, "FuelToken::approve: amount exceeds 96 bits"); } allowances[msg.sender][spender] = amount; ...
/** * @notice Approve `spender` to transfer up to `amount` from `src` * @dev This will overwrite the approval amount for `spender` * and is subject to issues noted [here](https://eips.ethereum.org/EIPS/eip-20#approve) * @param spender The address of the account which may transfer tokens * @param rawAmount Th...
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 4130, 4559 ] }
26,029
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
FuelToken
contract FuelToken { /// @notice EIP-20 token name for this token string public constant name = "PowerTrade Fuel Token"; /// @notice EIP-20 token symbol for this token string public constant symbol = "PTF"; /// @notice EIP-20 token decimals for this token uint8 public constant decimals...
// Copyright 2020 Compound Labs, Inc. // Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: // 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. // 2....
LineComment
balanceOf
function balanceOf(address account) external view returns (uint) { return balances[account]; }
/** * @notice Get the number of tokens held by the `account` * @param account The address of the account to get the balance of * @return The number of tokens held */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 4757, 4870 ] }
26,030
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
FuelToken
contract FuelToken { /// @notice EIP-20 token name for this token string public constant name = "PowerTrade Fuel Token"; /// @notice EIP-20 token symbol for this token string public constant symbol = "PTF"; /// @notice EIP-20 token decimals for this token uint8 public constant decimals...
// Copyright 2020 Compound Labs, Inc. // Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: // 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. // 2....
LineComment
mint
function mint(address dst, uint rawAmount) external onlyMinter { uint96 amount = safe96(rawAmount, "FuelToken::mint: amount exceeds 96 bits"); _mintTokens(dst, amount); }
/** * @notice Mint `amount` tokens to `dst` * @param dst The address of the destination account * @param rawAmount The number of tokens to mint * @notice only callable by minter */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 5089, 5287 ] }
26,031
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
FuelToken
contract FuelToken { /// @notice EIP-20 token name for this token string public constant name = "PowerTrade Fuel Token"; /// @notice EIP-20 token symbol for this token string public constant symbol = "PTF"; /// @notice EIP-20 token decimals for this token uint8 public constant decimals...
// Copyright 2020 Compound Labs, Inc. // Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: // 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. // 2....
LineComment
burn
function burn(uint rawAmount) external { uint96 amount = safe96(rawAmount, "FuelToken::burn: amount exceeds 96 bits"); _burnTokens(msg.sender, amount); }
/** * @notice Burn `amount` tokens * @param rawAmount The number of tokens to burn */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 5399, 5580 ] }
26,032
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
FuelToken
contract FuelToken { /// @notice EIP-20 token name for this token string public constant name = "PowerTrade Fuel Token"; /// @notice EIP-20 token symbol for this token string public constant symbol = "PTF"; /// @notice EIP-20 token decimals for this token uint8 public constant decimals...
// Copyright 2020 Compound Labs, Inc. // Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: // 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. // 2....
LineComment
changeMinter
function changeMinter(address account) external onlyMinter { minter = account; emit NewMinter(account); }
/** * @notice Change minter address to `account` * @param account The address of the new minter * @notice only callable by minter */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 5745, 5878 ] }
26,033
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
FuelToken
contract FuelToken { /// @notice EIP-20 token name for this token string public constant name = "PowerTrade Fuel Token"; /// @notice EIP-20 token symbol for this token string public constant symbol = "PTF"; /// @notice EIP-20 token decimals for this token uint8 public constant decimals...
// Copyright 2020 Compound Labs, Inc. // Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: // 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. // 2....
LineComment
transfer
function transfer(address dst, uint rawAmount) external returns (bool) { uint96 amount = safe96(rawAmount, "FuelToken::transfer: amount exceeds 96 bits"); _transferTokens(msg.sender, dst, amount); return true; }
/** * @notice Transfer `amount` tokens from `msg.sender` to `dst` * @param dst The address of the destination account * @param rawAmount The number of tokens to transfer * @return Whether or not the transfer succeeded */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 6137, 6385 ] }
26,034
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
FuelToken
contract FuelToken { /// @notice EIP-20 token name for this token string public constant name = "PowerTrade Fuel Token"; /// @notice EIP-20 token symbol for this token string public constant symbol = "PTF"; /// @notice EIP-20 token decimals for this token uint8 public constant decimals...
// Copyright 2020 Compound Labs, Inc. // Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: // 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. // 2....
LineComment
transferFrom
function transferFrom(address src, address dst, uint rawAmount) external returns (bool) { address spender = msg.sender; uint96 spenderAllowance = allowances[src][spender]; uint96 amount = safe96(rawAmount, "FuelToken::approve: amount exceeds 96 bits"); if (spender != src && spenderAllowance != uin...
/** * @notice Transfer `amount` tokens from `src` to `dst` * @param src The address of the source account * @param dst The address of the destination account * @param rawAmount The number of tokens to transfer * @return Whether or not the transfer succeeded */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 6690, 7377 ] }
26,035
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
FuelToken
contract FuelToken { /// @notice EIP-20 token name for this token string public constant name = "PowerTrade Fuel Token"; /// @notice EIP-20 token symbol for this token string public constant symbol = "PTF"; /// @notice EIP-20 token decimals for this token uint8 public constant decimals...
// Copyright 2020 Compound Labs, Inc. // Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: // 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. // 2....
LineComment
delegate
function delegate(address delegatee) public { return _delegate(msg.sender, delegatee); }
/** * @notice Delegate votes from `msg.sender` to `delegatee` * @param delegatee The address to delegate votes to */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 7520, 7627 ] }
26,036
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
FuelToken
contract FuelToken { /// @notice EIP-20 token name for this token string public constant name = "PowerTrade Fuel Token"; /// @notice EIP-20 token symbol for this token string public constant symbol = "PTF"; /// @notice EIP-20 token decimals for this token uint8 public constant decimals...
// Copyright 2020 Compound Labs, Inc. // Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: // 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. // 2....
LineComment
delegateBySig
function delegateBySig(address delegatee, uint nonce, uint expiry, uint8 v, bytes32 r, bytes32 s) public { bytes32 domainSeparator = keccak256(abi.encode(DOMAIN_TYPEHASH, keccak256(bytes(name)), getChainId(), address(this))); bytes32 structHash = keccak256(abi.encode(DELEGATION_TYPEHASH, delegatee, nonce, exp...
/** * @notice Delegates votes from signatory to `delegatee` * @param delegatee The address to delegate votes to * @param nonce The contract state required to match the signature * @param expiry The time at which to expire the signature * @param v The recovery byte of the signature * @param r Half of the ECD...
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 8056, 8865 ] }
26,037
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
FuelToken
contract FuelToken { /// @notice EIP-20 token name for this token string public constant name = "PowerTrade Fuel Token"; /// @notice EIP-20 token symbol for this token string public constant symbol = "PTF"; /// @notice EIP-20 token decimals for this token uint8 public constant decimals...
// Copyright 2020 Compound Labs, Inc. // Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: // 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. // 2....
LineComment
getCurrentVotes
function getCurrentVotes(address account) external view returns (uint96) { uint32 nCheckpoints = numCheckpoints[account]; return nCheckpoints > 0 ? checkpoints[account][nCheckpoints - 1].votes : 0; }
/** * @notice Gets the current votes balance for `account` * @param account The address to get votes balance * @return The number of current votes for `account` */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 9061, 9288 ] }
26,038
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
FuelToken
contract FuelToken { /// @notice EIP-20 token name for this token string public constant name = "PowerTrade Fuel Token"; /// @notice EIP-20 token symbol for this token string public constant symbol = "PTF"; /// @notice EIP-20 token decimals for this token uint8 public constant decimals...
// Copyright 2020 Compound Labs, Inc. // Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: // 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. // 2....
LineComment
getPriorVotes
function getPriorVotes(address account, uint blockNumber) public view returns (uint96) { require(blockNumber < block.number, "FuelToken::getPriorVotes: not yet determined"); uint32 nCheckpoints = numCheckpoints[account]; if (nCheckpoints == 0) { return 0; } // First check most rece...
/** * @notice Determine the prior number of votes for an account as of a block number * @dev Block number must be a finalized block or else this function will revert to prevent misinformation. * @param account The address of the account to check * @param blockNumber The block number to get the vote balance at ...
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 9714, 10942 ] }
26,039
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
VestingDepositAccount
contract VestingDepositAccount { /// @notice the controlling parent vesting contract address public controller; /// @notice beneficiary who tokens will be transferred to address public beneficiary; /// @notice ERC20 token that is vested (extended with a delegate function) FuelToken p...
/// @author BlockRocket
NatSpecSingleLine
init
function init(address _tokenAddress, address _controller, address _beneficiary) external { require(controller == address(0), "VestingDepositAccount::init: Contract already initialized"); token = FuelToken(_tokenAddress); controller = _controller; beneficiary = _beneficiary; // sets the benefi...
/** * @notice Using a minimal proxy contract pattern initialises the contract and sets delegation * @dev initialises the VestingDepositAccount (see https://eips.ethereum.org/EIPS/eip-1167) * @dev only controller */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 580, 1004 ] }
26,040
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
VestingDepositAccount
contract VestingDepositAccount { /// @notice the controlling parent vesting contract address public controller; /// @notice beneficiary who tokens will be transferred to address public beneficiary; /// @notice ERC20 token that is vested (extended with a delegate function) FuelToken p...
/// @author BlockRocket
NatSpecSingleLine
transferToBeneficiary
function transferToBeneficiary(uint256 _amount) external returns (bool) { require(msg.sender == controller, "VestingDepositAccount::transferToBeneficiary: Only controller"); return token.transfer(beneficiary, _amount); }
/** * @notice Transfer tokens vested in the VestingDepositAccount to the beneficiary * @param _amount amount of tokens (in wei) * @dev only controller */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 1190, 1438 ] }
26,041
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
VestingDepositAccount
contract VestingDepositAccount { /// @notice the controlling parent vesting contract address public controller; /// @notice beneficiary who tokens will be transferred to address public beneficiary; /// @notice ERC20 token that is vested (extended with a delegate function) FuelToken p...
/// @author BlockRocket
NatSpecSingleLine
switchBeneficiary
function switchBeneficiary(address _newBeneficiary) external { require(msg.sender == controller, "VestingDepositAccount::switchBeneficiary: Only controller"); beneficiary = _newBeneficiary; // sets the new beneficiary as the delegate on the token token.delegate(_newBeneficiary); }
/** * @notice Allows the beneficiary to be switched on the VestingDepositAccount and sets delegation * @param _newBeneficiary address to receive tokens once switched * @dev only controller */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 1662, 1991 ] }
26,042
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
VestingContract
contract VestingContract is CloneFactory, ReentrancyGuard { using SafeMath for uint256; /// @notice event emitted when a vesting schedule is created event ScheduleCreated(address indexed _beneficiary, uint256 indexed _amount); /// @notice event emitted when a successful drawn down of vesting tok...
/// @author BlockRocket
NatSpecSingleLine
createVestingSchedule
function createVestingSchedule(address _beneficiary, uint256 _amount) external returns (bool) { require(msg.sender == owner, "VestingContract::createVestingSchedule: Only Owner"); require(_beneficiary != address(0), "VestingContract::createVestingSchedule: Beneficiary cannot be empty"); require(_amount >...
/** * @notice Create a new vesting schedule * @notice A transfer is used to bring tokens into the VestingDepositAccount so pre-approval is required * @notice Delegation is set for the beneficiary on the token during schedule creation * @param _beneficiary beneficiary of the vested tokens * @param _amount amou...
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 3176, 4659 ] }
26,043
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
VestingContract
contract VestingContract is CloneFactory, ReentrancyGuard { using SafeMath for uint256; /// @notice event emitted when a vesting schedule is created event ScheduleCreated(address indexed _beneficiary, uint256 indexed _amount); /// @notice event emitted when a successful drawn down of vesting tok...
/// @author BlockRocket
NatSpecSingleLine
drawDown
function drawDown() nonReentrant external returns (bool) { return _drawDown(msg.sender); }
/** * @notice Draws down any vested tokens due * @dev Must be called directly by the beneficiary assigned the tokens in the schedule */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 4821, 4930 ] }
26,044
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
VestingContract
contract VestingContract is CloneFactory, ReentrancyGuard { using SafeMath for uint256; /// @notice event emitted when a vesting schedule is created event ScheduleCreated(address indexed _beneficiary, uint256 indexed _amount); /// @notice event emitted when a successful drawn down of vesting tok...
/// @author BlockRocket
NatSpecSingleLine
updateScheduleBeneficiary
function updateScheduleBeneficiary(address _currentBeneficiary, address _newBeneficiary) external { require(msg.sender == owner, "VestingContract::updateScheduleBeneficiary: Only owner"); // retrieve existing schedule Schedule memory schedule = vestingSchedule[_currentBeneficiary]; require( ...
/** * @notice Updates a schedule beneficiary * @notice Voids the old schedule and transfers remaining amount to new beneficiary via a new schedule * @dev Only owner * @param _currentBeneficiary beneficiary to be replaced * @param _newBeneficiary beneficiary to vest remaining tokens to */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 5263, 6351 ] }
26,045
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
VestingContract
contract VestingContract is CloneFactory, ReentrancyGuard { using SafeMath for uint256; /// @notice event emitted when a vesting schedule is created event ScheduleCreated(address indexed _beneficiary, uint256 indexed _amount); /// @notice event emitted when a successful drawn down of vesting tok...
/// @author BlockRocket
NatSpecSingleLine
transferOwnership
function transferOwnership(address _newOwner) external { require(msg.sender == owner, "VestingContract::transferOwnership: Only owner"); owner = _newOwner; }
/** * @notice Transfers ownership role * @notice Changes the owner of this contract to a new address * @dev Only owner * @param _newOwner beneficiary to vest remaining tokens to */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 6570, 6755 ] }
26,046
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
VestingContract
contract VestingContract is CloneFactory, ReentrancyGuard { using SafeMath for uint256; /// @notice event emitted when a vesting schedule is created event ScheduleCreated(address indexed _beneficiary, uint256 indexed _amount); /// @notice event emitted when a successful drawn down of vesting tok...
/// @author BlockRocket
NatSpecSingleLine
tokenBalance
function tokenBalance() external view returns (uint256 _tokenBalance) { return token.balanceOf(address(vestingSchedule[msg.sender].depositAccount)); }
/** * @notice Vested token balance for a beneficiary * @dev Must be called directly by the beneficiary assigned the tokens in the schedule * @return _tokenBalance total balance proxied via the ERC20 token */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 7015, 7184 ] }
26,047
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
VestingContract
contract VestingContract is CloneFactory, ReentrancyGuard { using SafeMath for uint256; /// @notice event emitted when a vesting schedule is created event ScheduleCreated(address indexed _beneficiary, uint256 indexed _amount); /// @notice event emitted when a successful drawn down of vesting tok...
/// @author BlockRocket
NatSpecSingleLine
vestingScheduleForBeneficiary
function vestingScheduleForBeneficiary(address _beneficiary) external view returns ( uint256 _amount, uint256 _totalDrawn, uint256 _lastDrawnAt, uint256 _drawDownRate, uint256 _remainingBalance, address _depositAccountAddress ) { Schedule memory schedule = vestingSchedule[_benefici...
/** * @notice Vesting schedule and associated data for a beneficiary * @dev Must be called directly by the beneficiary assigned the tokens in the schedule * @return _amount * @return _totalDrawn * @return _lastDrawnAt * @return _drawDownRate * @return _remainingBalance * @return _depositAccountAddress ...
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 7552, 8200 ] }
26,048
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
VestingContract
contract VestingContract is CloneFactory, ReentrancyGuard { using SafeMath for uint256; /// @notice event emitted when a vesting schedule is created event ScheduleCreated(address indexed _beneficiary, uint256 indexed _amount); /// @notice event emitted when a successful drawn down of vesting tok...
/// @author BlockRocket
NatSpecSingleLine
availableDrawDownAmount
function availableDrawDownAmount(address _beneficiary) external view returns (uint256 _amount) { return _availableDrawDownAmount(_beneficiary); }
/** * @notice Draw down amount currently available (based on the block timestamp) * @param _beneficiary beneficiary of the vested tokens * @return _amount tokens due from vesting schedule */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 8423, 8587 ] }
26,049
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
VestingContract
contract VestingContract is CloneFactory, ReentrancyGuard { using SafeMath for uint256; /// @notice event emitted when a vesting schedule is created event ScheduleCreated(address indexed _beneficiary, uint256 indexed _amount); /// @notice event emitted when a successful drawn down of vesting tok...
/// @author BlockRocket
NatSpecSingleLine
remainingBalance
function remainingBalance(address _beneficiary) external view returns (uint256 _remainingBalance) { Schedule memory schedule = vestingSchedule[_beneficiary]; return schedule.amount.sub(totalDrawn[_beneficiary]); }
/** * @notice Balance remaining in vesting schedule * @param _beneficiary beneficiary of the vested tokens * @return _remainingBalance tokens still due (and currently locked) from vesting schedule */
NatSpecMultiLine
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 8819, 9060 ] }
26,050
VestingContract
VestingContract.sol
0x63005b1be2bf27b3b563daf7781be46a1ff17d1e
Solidity
VestingContract
contract VestingContract is CloneFactory, ReentrancyGuard { using SafeMath for uint256; /// @notice event emitted when a vesting schedule is created event ScheduleCreated(address indexed _beneficiary, uint256 indexed _amount); /// @notice event emitted when a successful drawn down of vesting tok...
/// @author BlockRocket
NatSpecSingleLine
_drawDown
function _drawDown(address _beneficiary) internal returns (bool) { Schedule memory schedule = vestingSchedule[_beneficiary]; require(schedule.amount > 0, "VestingContract::_drawDown: There is no schedule currently in flight"); uint256 amount = _availableDrawDownAmount(_beneficiary); require(amount...
// Internal
LineComment
v0.5.16+commit.9c3226ce
None
bzzr://9ee624054ba96d4d69399f0bbd3f83d6969ec90ea7a244b2bd9b09180afb1dba
{ "func_code_index": [ 9082, 10228 ] }
26,051
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
IERC165
interface IERC165 { /** * @dev Returns true if this contract implements the interface defined by * `interfaceId`. See the corresponding * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section] * to learn more about how these ids are created. * * This f...
/** * @dev Interface of the ERC165 standard, as defined in the * https://eips.ethereum.org/EIPS/eip-165[EIP]. * * Implementers can declare support of contract interfaces, which can then be * queried by others ({ERC165Checker}). * * For an implementation, see {ERC165}. */
NatSpecMultiLine
supportsInterface
function supportsInterface(bytes4 interfaceId) external view returns (bool);
/** * @dev Returns true if this contract implements the interface defined by * `interfaceId`. See the corresponding * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section] * to learn more about how these ids are created. * * This function call must use less than 30 000 gas. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 374, 455 ] }
26,052
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
IERC721
interface IERC721 is IERC165 { /** * @dev Emitted when `tokenId` token is transferred from `from` to `to`. */ event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token. */ ...
/** * @dev Required interface of an ERC721 compliant contract. */
NatSpecMultiLine
balanceOf
function balanceOf(address owner) external view returns (uint256 balance);
/** * @dev Returns the number of tokens in ``owner``'s account. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 719, 798 ] }
26,053
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
IERC721
interface IERC721 is IERC165 { /** * @dev Emitted when `tokenId` token is transferred from `from` to `to`. */ event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token. */ ...
/** * @dev Required interface of an ERC721 compliant contract. */
NatSpecMultiLine
ownerOf
function ownerOf(uint256 tokenId) external view returns (address owner);
/** * @dev Returns the owner of the `tokenId` token. * * Requirements: * * - `tokenId` must exist. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 944, 1021 ] }
26,054
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
IERC721
interface IERC721 is IERC165 { /** * @dev Emitted when `tokenId` token is transferred from `from` to `to`. */ event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token. */ ...
/** * @dev Required interface of an ERC721 compliant contract. */
NatSpecMultiLine
safeTransferFrom
function safeTransferFrom( address from, address to, uint256 tokenId ) external;
/** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token mus...
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 1733, 1850 ] }
26,055
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
IERC721
interface IERC721 is IERC165 { /** * @dev Emitted when `tokenId` token is transferred from `from` to `to`. */ event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token. */ ...
/** * @dev Required interface of an ERC721 compliant contract. */
NatSpecMultiLine
transferFrom
function transferFrom( address from, address to, uint256 tokenId ) external;
/** * @dev Transfers `tokenId` token from `from` to `to`. * * WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * - If th...
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 2376, 2489 ] }
26,056
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
IERC721
interface IERC721 is IERC165 { /** * @dev Emitted when `tokenId` token is transferred from `from` to `to`. */ event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token. */ ...
/** * @dev Required interface of an ERC721 compliant contract. */
NatSpecMultiLine
approve
function approve(address to, uint256 tokenId) external;
/** * @dev Gives permission to `to` to transfer `tokenId` token to another account. * The approval is cleared when the token is transferred. * * Only a single account can be approved at a time, so approving the zero address clears previous approvals. * * Requirements: * * - The caller must own the token...
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 2962, 3022 ] }
26,057
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
IERC721
interface IERC721 is IERC165 { /** * @dev Emitted when `tokenId` token is transferred from `from` to `to`. */ event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token. */ ...
/** * @dev Required interface of an ERC721 compliant contract. */
NatSpecMultiLine
getApproved
function getApproved(uint256 tokenId) external view returns (address operator);
/** * @dev Returns the account approved for `tokenId` token. * * Requirements: * * - `tokenId` must exist. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 3176, 3260 ] }
26,058
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
IERC721
interface IERC721 is IERC165 { /** * @dev Emitted when `tokenId` token is transferred from `from` to `to`. */ event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token. */ ...
/** * @dev Required interface of an ERC721 compliant contract. */
NatSpecMultiLine
setApprovalForAll
function setApprovalForAll(address operator, bool _approved) external;
/** * @dev Approve or remove `operator` as an operator for the caller. * Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller. * * Requirements: * * - The `operator` cannot be the caller. * * Emits an {ApprovalForAll} event. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 3587, 3662 ] }
26,059
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
IERC721
interface IERC721 is IERC165 { /** * @dev Emitted when `tokenId` token is transferred from `from` to `to`. */ event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token. */ ...
/** * @dev Required interface of an ERC721 compliant contract. */
NatSpecMultiLine
isApprovedForAll
function isApprovedForAll(address owner, address operator) external view returns (bool);
/** * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`. * * See {setApprovalForAll} */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 3813, 3906 ] }
26,060
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
IERC721
interface IERC721 is IERC165 { /** * @dev Emitted when `tokenId` token is transferred from `from` to `to`. */ event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token. */ ...
/** * @dev Required interface of an ERC721 compliant contract. */
NatSpecMultiLine
safeTransferFrom
function safeTransferFrom( address from, address to, uint256 tokenId, bytes calldata data ) external;
/** * @dev Safely transfers `tokenId` token from `from` to `to`. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {appro...
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 4483, 4630 ] }
26,061
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
Strings
library Strings { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { // Inspired by OraclizeAPI's implementation - MIT ...
/** * @dev String operations. */
NatSpecMultiLine
toString
function toString(uint256 value) internal pure returns (string memory) { // Inspired by OraclizeAPI's implementation - MIT licence // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol if (value == 0) { return "0"; } uint256 ...
/** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 184, 912 ] }
26,062
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
Strings
library Strings { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { // Inspired by OraclizeAPI's implementation - MIT ...
/** * @dev String operations. */
NatSpecMultiLine
toHexString
function toHexString(uint256 value) internal pure returns (string memory) { if (value == 0) { return "0x00"; } uint256 temp = value; uint256 length = 0; while (temp != 0) { length++; temp >>= 8; } return toHexString(value, length); }
/** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 1017, 1362 ] }
26,063
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
Strings
library Strings { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { // Inspired by OraclizeAPI's implementation - MIT ...
/** * @dev String operations. */
NatSpecMultiLine
toHexString
function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { bytes memory buffer = new bytes(2 * length + 2); buffer[0] = "0"; buffer[1] = "x"; for (uint256 i = 2 * length + 1; i > 1; --i) { buffer[i] = _HEX_SYMBOLS[value & 0xf]; value >>= 4; } ...
/** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 1485, 1941 ] }
26,064
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
Ownable
abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor() { _setOwner(_msgSender()); ...
/** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. ...
NatSpecMultiLine
owner
function owner() public view virtual returns (address) { return _owner; }
/** * @dev Returns the address of the current owner. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 399, 491 ] }
26,065
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
Ownable
abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor() { _setOwner(_msgSender()); ...
/** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. ...
NatSpecMultiLine
renounceOwnership
function renounceOwnership() public virtual onlyOwner { _setOwner(address(0)); }
/** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 1050, 1149 ] }
26,066
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
Ownable
abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor() { _setOwner(_msgSender()); ...
/** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. ...
NatSpecMultiLine
transferOwnership
function transferOwnership(address newOwner) public virtual onlyOwner { require(newOwner != address(0), "Ownable: new owner is the zero address"); _setOwner(newOwner); }
/** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 1299, 1496 ] }
26,067
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
IERC721Receiver
interface IERC721Receiver { /** * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom} * by `operator` from `from`, this function is called. * * It must return its Solidity selector to confirm the token transfer. * If any other valu...
/** * @title ERC721 token receiver interface * @dev Interface for any contract that wants to support safeTransfers * from ERC721 asset contracts. */
NatSpecMultiLine
onERC721Received
function onERC721Received( address operator, address from, uint256 tokenId, bytes calldata data ) external returns (bytes4);
/** * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom} * by `operator` from `from`, this function is called. * * It must return its Solidity selector to confirm the token transfer. * If any other value is returned or the interface is not implemented by ...
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 528, 698 ] }
26,068
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
IERC721Metadata
interface IERC721Metadata is IERC721 { /** * @dev Returns the token collection name. */ function name() external view returns (string memory); /** * @dev Returns the token collection symbol. */ function symbol() external view returns (string memory); /** * @dev...
/** * @title ERC-721 Non-Fungible Token Standard, optional metadata extension * @dev See https://eips.ethereum.org/EIPS/eip-721 */
NatSpecMultiLine
name
function name() external view returns (string memory);
/** * @dev Returns the token collection name. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 106, 165 ] }
26,069
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
IERC721Metadata
interface IERC721Metadata is IERC721 { /** * @dev Returns the token collection name. */ function name() external view returns (string memory); /** * @dev Returns the token collection symbol. */ function symbol() external view returns (string memory); /** * @dev...
/** * @title ERC-721 Non-Fungible Token Standard, optional metadata extension * @dev See https://eips.ethereum.org/EIPS/eip-721 */
NatSpecMultiLine
symbol
function symbol() external view returns (string memory);
/** * @dev Returns the token collection symbol. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 236, 297 ] }
26,070
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
IERC721Metadata
interface IERC721Metadata is IERC721 { /** * @dev Returns the token collection name. */ function name() external view returns (string memory); /** * @dev Returns the token collection symbol. */ function symbol() external view returns (string memory); /** * @dev...
/** * @title ERC-721 Non-Fungible Token Standard, optional metadata extension * @dev See https://eips.ethereum.org/EIPS/eip-721 */
NatSpecMultiLine
tokenURI
function tokenURI(uint256 tokenId) external view returns (string memory);
/** * @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 398, 476 ] }
26,071
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
Address
library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will ...
/** * @dev Collection of functions related to the address type */
NatSpecMultiLine
isContract
function isContract(address account) internal view returns (bool) { // This method relies on extcodesize, which returns 0 for contracts in // construction, since the code is only stored at the end of the // constructor execution. uint256 size; assembly { size := extcodesize(account) ...
/** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will return false for the following * types of addresses: ...
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 606, 998 ] }
26,072
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
Address
library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will ...
/** * @dev Collection of functions related to the address type */
NatSpecMultiLine
sendValue
function sendValue(address payable recipient, uint256 amount) internal { require(address(this).balance >= amount, "Address: insufficient balance"); (bool success, ) = recipient.call{ value: amount }(""); require(success, "Address: unable to send value, recipient may have reverted"); }
/** * @dev Replacement for Solidity's `transfer`: sends `amount` wei to * `recipient`, forwarding all available gas and reverting on errors. * * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost * of certain opcodes, possibly making contracts go over the 2300 gas limit * imposed by `tr...
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 1928, 2252 ] }
26,073
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
Address
library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will ...
/** * @dev Collection of functions related to the address type */
NatSpecMultiLine
functionCall
function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCall(target, data, "Address: low-level call failed"); }
/** * @dev Performs a Solidity function call using a low level `call`. A * plain `call` is an unsafe replacement for a function call: use this * function instead. * * If `target` reverts with a revert reason, it is bubbled up by this * function (like regular Solidity function calls). * * Returns the raw...
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 3009, 3189 ] }
26,074
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
Address
library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will ...
/** * @dev Collection of functions related to the address type */
NatSpecMultiLine
functionCall
function functionCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { return functionCallWithValue(target, data, 0, errorMessage); }
/** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with * `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 3414, 3648 ] }
26,075
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
Address
library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will ...
/** * @dev Collection of functions related to the address type */
NatSpecMultiLine
functionCallWithValue
function functionCallWithValue( address target, bytes memory data, uint256 value ) internal returns (bytes memory) { return functionCallWithValue(target, data, value, "Address: low-level call with value failed"); }
/** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but also transferring `value` wei to `target`. * * Requirements: * * - the calling contract must have an ETH balance of at least `value`. * - the called Solidity function must be `payable`. * * _Available since v3.1._ *...
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 4018, 4283 ] }
26,076
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
Address
library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will ...
/** * @dev Collection of functions related to the address type */
NatSpecMultiLine
functionCallWithValue
function functionCallWithValue( address target, bytes memory data, uint256 value, string memory errorMessage ) internal returns (bytes memory) { require(address(this).balance >= value, "Address: insufficient balance for call"); require(isContract(target), "Address: call to non-contract");...
/** * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but * with `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 4534, 5052 ] }
26,077
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
Address
library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will ...
/** * @dev Collection of functions related to the address type */
NatSpecMultiLine
functionStaticCall
function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { return functionStaticCall(target, data, "Address: low-level static call failed"); }
/** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 5232, 5436 ] }
26,078
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
Address
library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will ...
/** * @dev Collection of functions related to the address type */
NatSpecMultiLine
functionStaticCall
function functionStaticCall( address target, bytes memory data, string memory errorMessage ) internal view returns (bytes memory) { require(isContract(target), "Address: static call to non-contract"); (bool success, bytes memory returndata) = target.staticcall(data); return _verifyCallR...
/** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 5623, 6024 ] }
26,079
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
Address
library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will ...
/** * @dev Collection of functions related to the address type */
NatSpecMultiLine
functionDelegateCall
function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { return functionDelegateCall(target, data, "Address: low-level delegate call failed"); }
/** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 6206, 6411 ] }
26,080
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
Address
library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will ...
/** * @dev Collection of functions related to the address type */
NatSpecMultiLine
functionDelegateCall
function functionDelegateCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { require(isContract(target), "Address: delegate call to non-contract"); (bool success, bytes memory returndata) = target.delegatecall(data); return _verifyCall...
/** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 6600, 7002 ] }
26,081
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
ERC165
abstract contract ERC165 is IERC165 { /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IERC165).interfaceId; } }
/** * @dev Implementation of the {IERC165} interface. * * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check * for the additional interface id that will be supported. For example: * * ```solidity * function supportsInterface(bytes4 interface...
NatSpecMultiLine
supportsInterface
function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IERC165).interfaceId; }
/** * @dev See {IERC165-supportsInterface}. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 103, 265 ] }
26,082
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
supportsInterface
function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { return interfaceId == type(IERC721).interfaceId || interfaceId == type(IERC721Metadata).interfaceId || super.supportsInterface(interfaceId); }
/** * @dev See {IERC165-supportsInterface}. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 971, 1281 ] }
26,083
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
balanceOf
function balanceOf(address owner) public view virtual override returns (uint256) { require(owner != address(0), "ERC721: balance query for the zero address"); return _balances[owner]; }
/** * @dev See {IERC721-balanceOf}. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 1340, 1553 ] }
26,084
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
ownerOf
function ownerOf(uint256 tokenId) public view virtual override returns (address) { address owner = _owners[tokenId]; require(owner != address(0), "ERC721: owner query for nonexistent token"); return owner; }
/** * @dev See {IERC721-ownerOf}. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 1610, 1854 ] }
26,085
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
name
function name() public view virtual override returns (string memory) { return _name; }
/** * @dev See {IERC721Metadata-name}. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 1916, 2021 ] }
26,086
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
symbol
function symbol() public view virtual override returns (string memory) { return _symbol; }
/** * @dev See {IERC721Metadata-symbol}. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 2085, 2194 ] }
26,087
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
tokenURI
function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { require(_exists(tokenId), "ERC721Metadata: URI query for nonexistent token"); string memory baseURI = _baseURI(); return bytes(baseURI).length > 0 ? string(abi.encodePacked(baseURI, tokenId.toString())) : ""; }
/** * @dev See {IERC721Metadata-tokenURI}. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 2260, 2599 ] }
26,088
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_baseURI
function _baseURI() internal view virtual returns (string memory) { return ""; }
/** * @dev Base URI for computing {tokenURI}. If set, the resulting URI for each * token will be the concatenation of the `baseURI` and the `tokenId`. Empty * by default, can be overriden in child contracts. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 2842, 2941 ] }
26,089
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
approve
function approve(address to, uint256 tokenId) public virtual override { address owner = ERC721.ownerOf(tokenId); require(to != owner, "ERC721: approval to current owner"); require( _msgSender() == owner || isApprovedForAll(owner, _msgSender()), "ERC721: approve caller is not owner nor...
/** * @dev See {IERC721-approve}. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 2998, 3414 ] }
26,090
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
getApproved
function getApproved(uint256 tokenId) public view virtual override returns (address) { require(_exists(tokenId), "ERC721: approved query for nonexistent token"); return _tokenApprovals[tokenId]; }
/** * @dev See {IERC721-getApproved}. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 3475, 3701 ] }
26,091
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
setApprovalForAll
function setApprovalForAll(address operator, bool approved) public virtual override { require(operator != _msgSender(), "ERC721: approve to caller"); _operatorApprovals[_msgSender()][operator] = approved; emit ApprovalForAll(_msgSender(), operator, approved); }
/** * @dev See {IERC721-setApprovalForAll}. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 3768, 4068 ] }
26,092
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
isApprovedForAll
function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { return _operatorApprovals[owner][operator]; }
/** * @dev See {IERC721-isApprovedForAll}. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 4134, 4303 ] }
26,093
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
transferFrom
function transferFrom( address from, address to, uint256 tokenId ) public virtual override { //solhint-disable-next-line max-line-length require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved"); _transfer(from, to, tokenId); }
/** * @dev See {IERC721-transferFrom}. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 4365, 4709 ] }
26,094
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
safeTransferFrom
function safeTransferFrom( address from, address to, uint256 tokenId ) public virtual override { safeTransferFrom(from, to, tokenId, ""); }
/** * @dev See {IERC721-safeTransferFrom}. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 4775, 4965 ] }
26,095
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
safeTransferFrom
function safeTransferFrom( address from, address to, uint256 tokenId, bytes memory _data ) public virtual override { require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved"); _safeTransfer(from, to, tokenId, _data); }
/** * @dev See {IERC721-safeTransferFrom}. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 5031, 5364 ] }
26,096
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_safeTransfer
function _safeTransfer( address from, address to, uint256 tokenId, bytes memory _data ) internal virtual { _transfer(from, to, tokenId); require(_checkOnERC721Received(from, to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer"); }
/** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * `_data` is additional data, it has no specified format and it is sent in call to `to`. * * This internal function is eq...
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 6241, 6561 ] }
26,097
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_exists
function _exists(uint256 tokenId) internal view virtual returns (bool) { return _owners[tokenId] != address(0); }
/** * @dev Returns whether `tokenId` exists. * * Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}. * * Tokens start existing when they are minted (`_mint`), * and stop existing when they are burned (`_burn`). */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 6869, 7001 ] }
26,098
LootIslands
LootIslands.sol
0x60c22337afb8ac5bab1580e385cc002e6b296384
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_isApprovedOrOwner
function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) { require(_exists(tokenId), "ERC721: operator query for nonexistent token"); address owner = ERC721.ownerOf(tokenId); return (spender == owner || getApproved(tokenId) == spender || isApprovedForAll(owner, s...
/** * @dev Returns whether `spender` is allowed to manage `tokenId`. * * Requirements: * * - `tokenId` must exist. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
Unlicense
ipfs://6d15b2b6636613e7ebd8fbaa78b87c64f127f34eabf0e55bd283e9a5f75cd6dd
{ "func_code_index": [ 7163, 7516 ] }
26,099