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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
VTO | VTO.sol | 0x02b66106c712ae79715f62be30a787cdfbcd79b2 | Solidity | ERC20Detailed | contract ERC20Detailed is IERC20 {
string private _name;
string private _symbol;
uint8 private _decimals;
constructor (string memory name, string memory symbol, uint8 decimals) public {
_name = name;
_symbol = symbol;
_decimals = decimals;
}
/**
* @retu... | name | function name() public view returns (string memory) {
return _name;
}
| /**
* @return the name of the token.
*/ | NatSpecMultiLine | v0.5.17+commit.d19bba13 | None | bzzr://b9179b633af1618d26883bc5623b55668f46bcbbd49aa5f18ea67376d9c5bced | {
"func_code_index": [
356,
444
]
} | 7,707 | ||
VTO | VTO.sol | 0x02b66106c712ae79715f62be30a787cdfbcd79b2 | Solidity | ERC20Detailed | contract ERC20Detailed is IERC20 {
string private _name;
string private _symbol;
uint8 private _decimals;
constructor (string memory name, string memory symbol, uint8 decimals) public {
_name = name;
_symbol = symbol;
_decimals = decimals;
}
/**
* @retu... | symbol | function symbol() public view returns (string memory) {
return _symbol;
}
| /**
* @return the symbol of the token.
*/ | NatSpecMultiLine | v0.5.17+commit.d19bba13 | None | bzzr://b9179b633af1618d26883bc5623b55668f46bcbbd49aa5f18ea67376d9c5bced | {
"func_code_index": [
506,
598
]
} | 7,708 | ||
VTO | VTO.sol | 0x02b66106c712ae79715f62be30a787cdfbcd79b2 | Solidity | ERC20Detailed | contract ERC20Detailed is IERC20 {
string private _name;
string private _symbol;
uint8 private _decimals;
constructor (string memory name, string memory symbol, uint8 decimals) public {
_name = name;
_symbol = symbol;
_decimals = decimals;
}
/**
* @retu... | decimals | function decimals() public view returns (uint8) {
return _decimals;
}
| /**
* @return the number of decimals of the token.
*/ | NatSpecMultiLine | v0.5.17+commit.d19bba13 | None | bzzr://b9179b633af1618d26883bc5623b55668f46bcbbd49aa5f18ea67376d9c5bced | {
"func_code_index": [
672,
760
]
} | 7,709 | ||
VTO | VTO.sol | 0x02b66106c712ae79715f62be30a787cdfbcd79b2 | Solidity | ERC20Burnable | contract ERC20Burnable is ERC20 {
/**
* @dev Burns a specific amount of tokens.
* @param value The amount of token to be burned.
*/
function burn(uint256 value) public {
_burn(msg.sender, value);
}
/**
* @dev Burns a specific amount of tokens from the target addres... | burn | function burn(uint256 value) public {
_burn(msg.sender, value);
}
| /**
* @dev Burns a specific amount of tokens.
* @param value The amount of token to be burned.
*/ | NatSpecMultiLine | v0.5.17+commit.d19bba13 | None | bzzr://b9179b633af1618d26883bc5623b55668f46bcbbd49aa5f18ea67376d9c5bced | {
"func_code_index": [
156,
240
]
} | 7,710 | ||
VTO | VTO.sol | 0x02b66106c712ae79715f62be30a787cdfbcd79b2 | Solidity | ERC20Burnable | contract ERC20Burnable is ERC20 {
/**
* @dev Burns a specific amount of tokens.
* @param value The amount of token to be burned.
*/
function burn(uint256 value) public {
_burn(msg.sender, value);
}
/**
* @dev Burns a specific amount of tokens from the target addres... | burnFrom | function burnFrom(address from, uint256 value) public {
_burnFrom(from, value);
}
| /**
* @dev Burns a specific amount of tokens from the target address and decrements allowance
* @param from address The address which you want to send tokens from
* @param value uint256 The amount of token to be burned
*/ | NatSpecMultiLine | v0.5.17+commit.d19bba13 | None | bzzr://b9179b633af1618d26883bc5623b55668f46bcbbd49aa5f18ea67376d9c5bced | {
"func_code_index": [
494,
594
]
} | 7,711 | ||
GLBToken | GLBToken.sol | 0xb9581a458bd0e135f534fcb7a23441c7dc097ddc | Solidity | ContractTokenERC20 | contract ContractTokenERC20 {
// Public variables of the token
string public name;
string public symbol;
uint8 public decimals = 18;
// 18 decimals is the strongly suggested default, avoid changing it
uint256 public totalSupply;
// This creates an array with all balances
mappin... | _transfer | function _transfer(address _from, address _to, uint _value) internal {
// Prevent transfer to 0x0 address. Use burn() instead
require(_to != address(0x0));
// Check if the sender has enough
require(balanceOf[_from] >= _value);
// Check for overflows
require(balanceOf[_to] + _value > balanc... | /**
* Internal transfer, only can be called by this contract
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | bzzr://5e8a4668b19de91d748a9b05d6529816456d7c53664c67e0d07dec4d4534508a | {
"func_code_index": [
1669,
2525
]
} | 7,712 | |||
GLBToken | GLBToken.sol | 0xb9581a458bd0e135f534fcb7a23441c7dc097ddc | Solidity | ContractTokenERC20 | contract ContractTokenERC20 {
// Public variables of the token
string public name;
string public symbol;
uint8 public decimals = 18;
// 18 decimals is the strongly suggested default, avoid changing it
uint256 public totalSupply;
// This creates an array with all balances
mappin... | transfer | function transfer(address _to, uint256 _value) public returns (bool success) {
_transfer(msg.sender, _to, _value);
return true;
}
| /**
* Transfer tokens
*
* Send `_value` tokens to `_to` from your account
*
* @param _to The address of the recipient
* @param _value the amount to send
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | bzzr://5e8a4668b19de91d748a9b05d6529816456d7c53664c67e0d07dec4d4534508a | {
"func_code_index": [
2731,
2888
]
} | 7,713 | |||
GLBToken | GLBToken.sol | 0xb9581a458bd0e135f534fcb7a23441c7dc097ddc | Solidity | ContractTokenERC20 | contract ContractTokenERC20 {
// Public variables of the token
string public name;
string public symbol;
uint8 public decimals = 18;
// 18 decimals is the strongly suggested default, avoid changing it
uint256 public totalSupply;
// This creates an array with all balances
mappin... | transferFrom | function transferFrom(address _from, address _to, uint256 _value) public returns (bool success) {
require(_value <= allowance[_from][msg.sender]); // Check allowance
allowance[_from][msg.sender] -= _value;
_transfer(_from, _to, _value);
return true;
}
| /**
* Transfer tokens from other address
*
* Send `_value` tokens to `_to` in behalf of `_from`
*
* @param _from The address of the sender
* @param _to The address of the recipient
* @param _value the amount to send
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | bzzr://5e8a4668b19de91d748a9b05d6529816456d7c53664c67e0d07dec4d4534508a | {
"func_code_index": [
3163,
3464
]
} | 7,714 | |||
GLBToken | GLBToken.sol | 0xb9581a458bd0e135f534fcb7a23441c7dc097ddc | Solidity | ContractTokenERC20 | contract ContractTokenERC20 {
// Public variables of the token
string public name;
string public symbol;
uint8 public decimals = 18;
// 18 decimals is the strongly suggested default, avoid changing it
uint256 public totalSupply;
// This creates an array with all balances
mappin... | approve | function approve(address _spender, uint256 _value) public
returns (bool success) {
allowance[msg.sender][_spender] = _value;
emit Approval(msg.sender, _spender, _value);
return true;
}
| /**
* Set allowance for other address
*
* Allows `_spender` to spend no more than `_value` tokens in your behalf
*
* @param _spender The address authorized to spend
* @param _value the max amount they can spend
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | bzzr://5e8a4668b19de91d748a9b05d6529816456d7c53664c67e0d07dec4d4534508a | {
"func_code_index": [
3728,
3958
]
} | 7,715 | |||
GLBToken | GLBToken.sol | 0xb9581a458bd0e135f534fcb7a23441c7dc097ddc | Solidity | ContractTokenERC20 | contract ContractTokenERC20 {
// Public variables of the token
string public name;
string public symbol;
uint8 public decimals = 18;
// 18 decimals is the strongly suggested default, avoid changing it
uint256 public totalSupply;
// This creates an array with all balances
mappin... | approveAndCall | function approveAndCall(address _spender, uint256 _value, bytes memory _extraData)
public
returns (bool success) {
tokenRecipient spender = tokenRecipient(_spender);
if (approve(_spender, _value)) {
spender.receiveApproval(msg.sender, _value, address(this), _extraData);
return true... | /**
* Set allowance for other address and notify
*
* Allows `_spender` to spend no more than `_value` tokens in your behalf, and then ping the contract about it
*
* @param _spender The address authorized to spend
* @param _value the max amount they can spend
* @param _extraData some extra information to s... | NatSpecMultiLine | v0.5.0+commit.1d4f565a | bzzr://5e8a4668b19de91d748a9b05d6529816456d7c53664c67e0d07dec4d4534508a | {
"func_code_index": [
4352,
4720
]
} | 7,716 | |||
GLBToken | GLBToken.sol | 0xb9581a458bd0e135f534fcb7a23441c7dc097ddc | Solidity | GLBToken | contract GLBToken is ContractOwned, ContractTokenERC20 {
uint256 public sellPrice;
uint256 public buyPrice;
mapping (address => bool) public frozenAccount;
/* This generates a public event on the blockchain that will notify clients */
event FrozenFunds(address target, bool frozen);
... | /******************************************/ | NatSpecMultiLine | _transfer | function _transfer(address _from, address _to, uint _value) internal {
require (_to != address(0x0)); // Prevent transfer to 0x0 address. Use burn() instead
require (balanceOf[_from] >= _value); // Check if the sender has enough
require (balanceOf[_to] + _value ... | /* Internal transfer, only can be called by this contract */ | Comment | v0.5.0+commit.1d4f565a | bzzr://5e8a4668b19de91d748a9b05d6529816456d7c53664c67e0d07dec4d4534508a | {
"func_code_index": [
669,
1484
]
} | 7,717 | |
GLBToken | GLBToken.sol | 0xb9581a458bd0e135f534fcb7a23441c7dc097ddc | Solidity | GLBToken | contract GLBToken is ContractOwned, ContractTokenERC20 {
uint256 public sellPrice;
uint256 public buyPrice;
mapping (address => bool) public frozenAccount;
/* This generates a public event on the blockchain that will notify clients */
event FrozenFunds(address target, bool frozen);
... | /******************************************/ | NatSpecMultiLine | mintToken | function mintToken(address target, uint256 mintedAmount) onlyOwner public {
balanceOf[target] += mintedAmount;
totalSupply += mintedAmount;
emit Transfer(address(0), address(this), mintedAmount);
emit Transfer(address(this), target, mintedAmount);
}
| /// @notice Create `mintedAmount` tokens and send it to `target`
/// @param target Address to receive the tokens
/// @param mintedAmount the amount of tokens it will receive | NatSpecSingleLine | v0.5.0+commit.1d4f565a | bzzr://5e8a4668b19de91d748a9b05d6529816456d7c53664c67e0d07dec4d4534508a | {
"func_code_index": [
1676,
1971
]
} | 7,718 | |
GLBToken | GLBToken.sol | 0xb9581a458bd0e135f534fcb7a23441c7dc097ddc | Solidity | GLBToken | contract GLBToken is ContractOwned, ContractTokenERC20 {
uint256 public sellPrice;
uint256 public buyPrice;
mapping (address => bool) public frozenAccount;
/* This generates a public event on the blockchain that will notify clients */
event FrozenFunds(address target, bool frozen);
... | /******************************************/ | NatSpecMultiLine | freezeAccount | function freezeAccount(address target, bool freeze) onlyOwner public {
frozenAccount[target] = freeze;
emit FrozenFunds(target, freeze);
}
| /// @notice `freeze? Prevent | Allow` `target` from sending & receiving tokens
/// @param target Address to be frozen
/// @param freeze either to freeze it or not | NatSpecSingleLine | v0.5.0+commit.1d4f565a | bzzr://5e8a4668b19de91d748a9b05d6529816456d7c53664c67e0d07dec4d4534508a | {
"func_code_index": [
2152,
2318
]
} | 7,719 | |
GLBToken | GLBToken.sol | 0xb9581a458bd0e135f534fcb7a23441c7dc097ddc | Solidity | GLBToken | contract GLBToken is ContractOwned, ContractTokenERC20 {
uint256 public sellPrice;
uint256 public buyPrice;
mapping (address => bool) public frozenAccount;
/* This generates a public event on the blockchain that will notify clients */
event FrozenFunds(address target, bool frozen);
... | /******************************************/ | NatSpecMultiLine | setPrices | function setPrices(uint256 newSellPrice, uint256 newBuyPrice) onlyOwner public {
sellPrice = newSellPrice;
buyPrice = newBuyPrice;
}
| /// @notice Allow users to buy tokens for `newBuyPrice` eth and sell tokens for `newSellPrice` eth
/// @param newSellPrice Price the users can sell to the contract
/// @param newBuyPrice Price users can buy from the contract | NatSpecSingleLine | v0.5.0+commit.1d4f565a | bzzr://5e8a4668b19de91d748a9b05d6529816456d7c53664c67e0d07dec4d4534508a | {
"func_code_index": [
2561,
2721
]
} | 7,720 | |
GLBToken | GLBToken.sol | 0xb9581a458bd0e135f534fcb7a23441c7dc097ddc | Solidity | GLBToken | contract GLBToken is ContractOwned, ContractTokenERC20 {
uint256 public sellPrice;
uint256 public buyPrice;
mapping (address => bool) public frozenAccount;
/* This generates a public event on the blockchain that will notify clients */
event FrozenFunds(address target, bool frozen);
... | /******************************************/ | NatSpecMultiLine | buy | function buy() payable public {
uint amount = msg.value / buyPrice; // calculates the amount
_transfer(address(this), msg.sender, amount); // makes the transfers
}
| /// @notice Buy tokens from contract by sending ether | NatSpecSingleLine | v0.5.0+commit.1d4f565a | bzzr://5e8a4668b19de91d748a9b05d6529816456d7c53664c67e0d07dec4d4534508a | {
"func_code_index": [
2783,
2996
]
} | 7,721 | |
GLBToken | GLBToken.sol | 0xb9581a458bd0e135f534fcb7a23441c7dc097ddc | Solidity | GLBToken | contract GLBToken is ContractOwned, ContractTokenERC20 {
uint256 public sellPrice;
uint256 public buyPrice;
mapping (address => bool) public frozenAccount;
/* This generates a public event on the blockchain that will notify clients */
event FrozenFunds(address target, bool frozen);
... | /******************************************/ | NatSpecMultiLine | sell | function sell(uint256 amount) public {
address myAddress = address(this);
require(myAddress.balance >= amount * sellPrice); // checks if the contract has enough ether to buy
_transfer(msg.sender, address(this), amount); // makes the transfers
msg.sender.transfer(amount * sellPrice); ... | /// @notice Sell `amount` tokens to contract
/// @param amount amount of tokens to be sold | NatSpecSingleLine | v0.5.0+commit.1d4f565a | bzzr://5e8a4668b19de91d748a9b05d6529816456d7c53664c67e0d07dec4d4534508a | {
"func_code_index": [
3100,
3538
]
} | 7,722 | |
ForefrontVesting | contracts/ForefrontVesting.sol | 0x95e26d3108ff64c5534fa64908c85e93bbb7e3ad | Solidity | ForefrontVesting | contract ForefrontVesting is Ownable {
using SafeERC20 for IERC20;
IERC20 public vestingToken;
address public treasury;
uint256 public startTimestamp;
uint256 public finishingTimestamp;
uint256 public globalForefrontVested;
/// @dev change according to program
uint256 public constant... | /// @title Forefront News Vesting Contract
/// @notice A contract used for the vesting entries of contributions made during the Treasury Diversification Round | NatSpecSingleLine | vest | function vest() public {
uint256 amountCanClaim = vestableAmount(msg.sender);
require(amountCanClaim > 0, "ForefrontVesting: no tokens are vestable");
entries[msg.sender].locked -= amountCanClaim;
entries[msg.sender].claimed += amountCanClaim;
globalForefrontVested -= amountCanClaim;
vestingTo... | /* Public Functions */ | Comment | v0.8.4+commit.c7e474f2 | {
"func_code_index": [
987,
1441
]
} | 7,723 | ||
ForefrontVesting | contracts/ForefrontVesting.sol | 0x95e26d3108ff64c5534fa64908c85e93bbb7e3ad | Solidity | ForefrontVesting | contract ForefrontVesting is Ownable {
using SafeERC20 for IERC20;
IERC20 public vestingToken;
address public treasury;
uint256 public startTimestamp;
uint256 public finishingTimestamp;
uint256 public globalForefrontVested;
/// @dev change according to program
uint256 public constant... | /// @title Forefront News Vesting Contract
/// @notice A contract used for the vesting entries of contributions made during the Treasury Diversification Round | NatSpecSingleLine | addEntries | function addEntries(address[] memory wallets, uint256[] memory allocations)
public
onlyOwner
returns (bool success)
{
for (uint256 i = 0; i < wallets.length; i++) {
if (addEntry(wallets[i], allocations[i])) {
success = true;
}
}
}
| /* Restricted Functions */ | Comment | v0.8.4+commit.c7e474f2 | {
"func_code_index": [
1475,
1797
]
} | 7,724 | ||
ForefrontVesting | contracts/ForefrontVesting.sol | 0x95e26d3108ff64c5534fa64908c85e93bbb7e3ad | Solidity | ForefrontVesting | contract ForefrontVesting is Ownable {
using SafeERC20 for IERC20;
IERC20 public vestingToken;
address public treasury;
uint256 public startTimestamp;
uint256 public finishingTimestamp;
uint256 public globalForefrontVested;
/// @dev change according to program
uint256 public constant... | /// @title Forefront News Vesting Contract
/// @notice A contract used for the vesting entries of contributions made during the Treasury Diversification Round | NatSpecSingleLine | vestableAmount | function vestableAmount(address wallet) public view returns (uint256) {
uint256 remainingAmount = entries[wallet].locked;
if (block.timestamp >= finishingTimestamp) {
return remainingAmount;
} else {
return
(remainingAmount * (block.timestamp - startTimestamp)) /
ves... | /* Views */ | Comment | v0.8.4+commit.c7e474f2 | {
"func_code_index": [
3193,
3572
]
} | 7,725 | ||
StableCoin | StableCoin.sol | 0xfa654d0702ffdae6fe30272639c83ec4cbfe6d7d | Solidity | SafeMath | library SafeMath {
/**
* @dev Multiplies two numbers, reverts on overflow.
*/
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... | /**
* @title SafeMath
*
*It's a Stable Coin having value as 1 CNYT = 1 YUAN (YUAN is a Chinese Currency)
*/ | 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-solidity/pull/522
if (a == 0) {
return 0;
}
uint256... | /**
* @dev Multiplies two numbers, reverts on overflow.
*/ | NatSpecMultiLine | v0.4.25+commit.59dbf8f1 | None | bzzr://e35191faeaf754c518bef8c1ba3b812474cd40b050752aa462c281006bd2ebf1 | {
"func_code_index": [
90,
486
]
} | 7,726 |
StableCoin | StableCoin.sol | 0xfa654d0702ffdae6fe30272639c83ec4cbfe6d7d | Solidity | SafeMath | library SafeMath {
/**
* @dev Multiplies two numbers, reverts on overflow.
*/
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... | /**
* @title SafeMath
*
*It's a Stable Coin having value as 1 CNYT = 1 YUAN (YUAN is a Chinese Currency)
*/ | NatSpecMultiLine | div | function div(uint256 a, uint256 b) internal pure returns (uint256) {
require(b > 0); // Solidity only automatically asserts when dividing by 0
uint256 c = a / b;
// assert(a == b * c + a % b); // There is no case in which this doesn't hold
return c;
}
| /**
* @dev Integer division of two numbers truncating the quotient, reverts on division by zero.
*/ | NatSpecMultiLine | v0.4.25+commit.59dbf8f1 | None | bzzr://e35191faeaf754c518bef8c1ba3b812474cd40b050752aa462c281006bd2ebf1 | {
"func_code_index": [
598,
877
]
} | 7,727 |
StableCoin | StableCoin.sol | 0xfa654d0702ffdae6fe30272639c83ec4cbfe6d7d | Solidity | SafeMath | library SafeMath {
/**
* @dev Multiplies two numbers, reverts on overflow.
*/
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... | /**
* @title SafeMath
*
*It's a Stable Coin having value as 1 CNYT = 1 YUAN (YUAN is a Chinese Currency)
*/ | NatSpecMultiLine | sub | function sub(uint256 a, uint256 b) internal pure returns (uint256) {
require(b <= a);
uint256 c = a - b;
return c;
}
| /**
* @dev Subtracts two numbers, reverts on overflow (i.e. if subtrahend is greater than minuend).
*/ | NatSpecMultiLine | v0.4.25+commit.59dbf8f1 | None | bzzr://e35191faeaf754c518bef8c1ba3b812474cd40b050752aa462c281006bd2ebf1 | {
"func_code_index": [
992,
1131
]
} | 7,728 |
StableCoin | StableCoin.sol | 0xfa654d0702ffdae6fe30272639c83ec4cbfe6d7d | Solidity | SafeMath | library SafeMath {
/**
* @dev Multiplies two numbers, reverts on overflow.
*/
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... | /**
* @title SafeMath
*
*It's a Stable Coin having value as 1 CNYT = 1 YUAN (YUAN is a Chinese Currency)
*/ | NatSpecMultiLine | add | function add(uint256 a, uint256 b) internal pure returns (uint256) {
uint256 c = a + b;
require(c >= a);
return c;
}
| /**
* @dev Adds two numbers, reverts on overflow.
*/ | NatSpecMultiLine | v0.4.25+commit.59dbf8f1 | None | bzzr://e35191faeaf754c518bef8c1ba3b812474cd40b050752aa462c281006bd2ebf1 | {
"func_code_index": [
1196,
1335
]
} | 7,729 |
StableCoin | StableCoin.sol | 0xfa654d0702ffdae6fe30272639c83ec4cbfe6d7d | Solidity | SafeMath | library SafeMath {
/**
* @dev Multiplies two numbers, reverts on overflow.
*/
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... | /**
* @title SafeMath
*
*It's a Stable Coin having value as 1 CNYT = 1 YUAN (YUAN is a Chinese Currency)
*/ | NatSpecMultiLine | mod | function mod(uint256 a, uint256 b) internal pure returns (uint256) {
require(b != 0);
return a % b;
}
| /**
* @dev Divides two numbers and returns the remainder (unsigned integer modulo),
* reverts when dividing by zero.
*/ | NatSpecMultiLine | v0.4.25+commit.59dbf8f1 | None | bzzr://e35191faeaf754c518bef8c1ba3b812474cd40b050752aa462c281006bd2ebf1 | {
"func_code_index": [
1470,
1587
]
} | 7,730 |
StableCoin | StableCoin.sol | 0xfa654d0702ffdae6fe30272639c83ec4cbfe6d7d | Solidity | StableCoin | contract StableCoin is IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowed;
uint256 private _totalSupply;
string private _name;
string private _symbol;
uint8 private _decimals;
constructor... | name | function name() public view returns(string) {
return _name;
}
| /**
* @return the name of the token.
*/ | NatSpecMultiLine | v0.4.25+commit.59dbf8f1 | None | bzzr://e35191faeaf754c518bef8c1ba3b812474cd40b050752aa462c281006bd2ebf1 | {
"func_code_index": [
683,
755
]
} | 7,731 | ||
StableCoin | StableCoin.sol | 0xfa654d0702ffdae6fe30272639c83ec4cbfe6d7d | Solidity | StableCoin | contract StableCoin is IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowed;
uint256 private _totalSupply;
string private _name;
string private _symbol;
uint8 private _decimals;
constructor... | symbol | function symbol() public view returns(string) {
return _symbol;
}
| /**
* @return the symbol of the token.
*/ | NatSpecMultiLine | v0.4.25+commit.59dbf8f1 | None | bzzr://e35191faeaf754c518bef8c1ba3b812474cd40b050752aa462c281006bd2ebf1 | {
"func_code_index": [
811,
887
]
} | 7,732 | ||
StableCoin | StableCoin.sol | 0xfa654d0702ffdae6fe30272639c83ec4cbfe6d7d | Solidity | StableCoin | contract StableCoin is IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowed;
uint256 private _totalSupply;
string private _name;
string private _symbol;
uint8 private _decimals;
constructor... | decimals | function decimals() public view returns(uint8) {
return _decimals;
}
| /**
* @return the number of decimals of the token.
*/ | NatSpecMultiLine | v0.4.25+commit.59dbf8f1 | None | bzzr://e35191faeaf754c518bef8c1ba3b812474cd40b050752aa462c281006bd2ebf1 | {
"func_code_index": [
955,
1034
]
} | 7,733 | ||
StableCoin | StableCoin.sol | 0xfa654d0702ffdae6fe30272639c83ec4cbfe6d7d | Solidity | StableCoin | contract StableCoin is IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowed;
uint256 private _totalSupply;
string private _name;
string private _symbol;
uint8 private _decimals;
constructor... | totalSupply | function totalSupply() public view returns (uint256) {
return _totalSupply;
}
| /**
* @dev Total number of tokens in existence
*/ | NatSpecMultiLine | v0.4.25+commit.59dbf8f1 | None | bzzr://e35191faeaf754c518bef8c1ba3b812474cd40b050752aa462c281006bd2ebf1 | {
"func_code_index": [
1096,
1184
]
} | 7,734 | ||
StableCoin | StableCoin.sol | 0xfa654d0702ffdae6fe30272639c83ec4cbfe6d7d | Solidity | StableCoin | contract StableCoin is IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowed;
uint256 private _totalSupply;
string private _name;
string private _symbol;
uint8 private _decimals;
constructor... | balanceOf | function balanceOf(address owner) public view returns (uint256) {
return _balances[owner];
}
| /**
* @dev Gets the balance of the specified address.
* @param owner The address to query the balance of.
* @return An uint256 representing the amount owned by the passed address.
*/ | NatSpecMultiLine | v0.4.25+commit.59dbf8f1 | None | bzzr://e35191faeaf754c518bef8c1ba3b812474cd40b050752aa462c281006bd2ebf1 | {
"func_code_index": [
1385,
1488
]
} | 7,735 | ||
StableCoin | StableCoin.sol | 0xfa654d0702ffdae6fe30272639c83ec4cbfe6d7d | Solidity | StableCoin | contract StableCoin is IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowed;
uint256 private _totalSupply;
string private _name;
string private _symbol;
uint8 private _decimals;
constructor... | allowance | function allowance(
address owner,
address spender
)
public
view
returns (uint256)
{
return _allowed[owner][spender];
}
| /**
* @dev Function to check the amount of tokens that an owner allowed to a spender.
* @param owner address The address which owns the funds.
* @param spender address The address which will spend the funds.
* @return A uint256 specifying the amount of tokens still available for the spender.
*/ | NatSpecMultiLine | v0.4.25+commit.59dbf8f1 | None | bzzr://e35191faeaf754c518bef8c1ba3b812474cd40b050752aa462c281006bd2ebf1 | {
"func_code_index": [
1810,
1972
]
} | 7,736 | ||
StableCoin | StableCoin.sol | 0xfa654d0702ffdae6fe30272639c83ec4cbfe6d7d | Solidity | StableCoin | contract StableCoin is IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowed;
uint256 private _totalSupply;
string private _name;
string private _symbol;
uint8 private _decimals;
constructor... | transfer | function transfer(address to, uint256 value) public returns (bool) {
_transfer(msg.sender, to, value);
return true;
}
| /**
* @dev Transfer token for a specified address
* @param to The address to transfer to.
* @param value The amount to be transferred.
*/ | NatSpecMultiLine | v0.4.25+commit.59dbf8f1 | None | bzzr://e35191faeaf754c518bef8c1ba3b812474cd40b050752aa462c281006bd2ebf1 | {
"func_code_index": [
2128,
2261
]
} | 7,737 | ||
StableCoin | StableCoin.sol | 0xfa654d0702ffdae6fe30272639c83ec4cbfe6d7d | Solidity | StableCoin | contract StableCoin is IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowed;
uint256 private _totalSupply;
string private _name;
string private _symbol;
uint8 private _decimals;
constructor... | approve | function approve(address spender, uint256 value) public returns (bool) {
require(spender != address(0));
_allowed[msg.sender][spender] = value;
emit Approval(msg.sender, spender, value);
return true;
}
| /**
* @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender.
* Beware that changing an allowance with this method brings the risk that someone may use both the old
* and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this
* race... | NatSpecMultiLine | v0.4.25+commit.59dbf8f1 | None | bzzr://e35191faeaf754c518bef8c1ba3b812474cd40b050752aa462c281006bd2ebf1 | {
"func_code_index": [
2885,
3114
]
} | 7,738 | ||
StableCoin | StableCoin.sol | 0xfa654d0702ffdae6fe30272639c83ec4cbfe6d7d | Solidity | StableCoin | contract StableCoin is IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowed;
uint256 private _totalSupply;
string private _name;
string private _symbol;
uint8 private _decimals;
constructor... | transferFrom | function transferFrom(
address from,
address to,
uint256 value
)
public
returns (bool)
{
require(value <= _allowed[from][msg.sender]);
_allowed[from][msg.sender] = _allowed[from][msg.sender].sub(value);
_transfer(from, to, value);
return true;
}
| /**
* @dev Transfer tokens from one address to another
* @param from address The address which you want to send tokens from
* @param to address The address which you want to transfer to
* @param value uint256 the amount of tokens to be transferred
*/ | NatSpecMultiLine | v0.4.25+commit.59dbf8f1 | None | bzzr://e35191faeaf754c518bef8c1ba3b812474cd40b050752aa462c281006bd2ebf1 | {
"func_code_index": [
3391,
3695
]
} | 7,739 | ||
StableCoin | StableCoin.sol | 0xfa654d0702ffdae6fe30272639c83ec4cbfe6d7d | Solidity | StableCoin | contract StableCoin is IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowed;
uint256 private _totalSupply;
string private _name;
string private _symbol;
uint8 private _decimals;
constructor... | increaseAllowance | function increaseAllowance(
address spender,
uint256 addedValue
)
public
returns (bool)
{
require(spender != address(0));
_allowed[msg.sender][spender] = (
_allowed[msg.sender][spender].add(addedValue));
emit Approval(msg.sender, spender, _allowed[msg.sender][spender]);
return true;
}
... | /**
* @dev Increase the amount of tokens that an owner allowed to a spender.
* approve should be called when allowed_[_spender] == 0. To increment
* allowed value is better to use this function to avoid 2 calls (and wait until
* the first transaction is mined)
* From MonolithDAO Token.sol
* @param spender T... | NatSpecMultiLine | v0.4.25+commit.59dbf8f1 | None | bzzr://e35191faeaf754c518bef8c1ba3b812474cd40b050752aa462c281006bd2ebf1 | {
"func_code_index": [
4154,
4500
]
} | 7,740 | ||
StableCoin | StableCoin.sol | 0xfa654d0702ffdae6fe30272639c83ec4cbfe6d7d | Solidity | StableCoin | contract StableCoin is IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowed;
uint256 private _totalSupply;
string private _name;
string private _symbol;
uint8 private _decimals;
constructor... | decreaseAllowance | function decreaseAllowance(
address spender,
uint256 subtractedValue
)
public
returns (bool)
{
require(spender != address(0));
_allowed[msg.sender][spender] = (
_allowed[msg.sender][spender].sub(subtractedValue));
emit Approval(msg.sender, spender, _allowed[msg.sender][spender]);
return... | /**
* @dev Decrease the amount of tokens that an owner allowed to a spender.
* approve should be called when allowed_[_spender] == 0. To decrement
* allowed value is better to use this function to avoid 2 calls (and wait until
* the first transaction is mined)
* From MonolithDAO Token.sol
* @param spender T... | NatSpecMultiLine | v0.4.25+commit.59dbf8f1 | None | bzzr://e35191faeaf754c518bef8c1ba3b812474cd40b050752aa462c281006bd2ebf1 | {
"func_code_index": [
4964,
5320
]
} | 7,741 | ||
StableCoin | StableCoin.sol | 0xfa654d0702ffdae6fe30272639c83ec4cbfe6d7d | Solidity | StableCoin | contract StableCoin is IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowed;
uint256 private _totalSupply;
string private _name;
string private _symbol;
uint8 private _decimals;
constructor... | _transfer | function _transfer(address from, address to, uint256 value) internal {
require(value <= _balances[from]);
require(to != address(0));
_balances[from] = _balances[from].sub(value);
_balances[to] = _balances[to].add(value);
emit Transfer(from, to, value);
}
| /**
* @dev Transfer token for a specified addresses
* @param from The address to transfer from.
* @param to The address to transfer to.
* @param value The amount to be transferred.
*/ | NatSpecMultiLine | v0.4.25+commit.59dbf8f1 | None | bzzr://e35191faeaf754c518bef8c1ba3b812474cd40b050752aa462c281006bd2ebf1 | {
"func_code_index": [
5525,
5812
]
} | 7,742 | ||
CredoIco | CredoIco.sol | 0xd6a81d7a8b4d1cc947138d9e4aca5d3cde33a170 | Solidity | SafeMath | contract SafeMath {
function assert(bool assertion) internal {
if (!assertion) {
throw;
}
} // assert no longer needed once solidity is on 0.4.10
function safeAdd(uint256 x, uint256 y) internal returns(uint256) {
uint256 z = x + y;
assert((z >= x) && ... | /////////////// | NatSpecSingleLine | safeAdd | function safeAdd(uint256 x, uint256 y) internal returns(uint256) {
uint256 z = x + y;
assert((z >= x) && (z >= y));
return z;
}
| // assert no longer needed once solidity is on 0.4.10 | LineComment | v0.4.8+commit.60cc1668 | bzzr://123314378ad61d631e9cbea23008e96bf47e26ec663339416a4e52d79d8d4499 | {
"func_code_index": [
197,
355
]
} | 7,743 | |
CredoIco | CredoIco.sol | 0xd6a81d7a8b4d1cc947138d9e4aca5d3cde33a170 | Solidity | CredoIco | contract CredoIco is StandardToken, SafeMath {
// Descriptive properties
string public constant name = "Credo ICO Token";
string public constant symbol = "CREDOICO";
uint256 public constant decimals = 18;
string public version = "1.0";
// Account for ether proceed.
address public et... | ///////////////////// | NatSpecSingleLine | CredoIco | function CredoIco(address _etherProceedsAccount, uint256 _fundingStartBlock, uint256 _fundingEndBlock)
{
isFinalized = false;
etherProceedsAccount = _etherProceedsAccount;
fundingStartBlock = _fundingStartBlock;
fundingEndBlock = _fundingEndBlock;
... | // constructor | LineComment | v0.4.8+commit.60cc1668 | bzzr://123314378ad61d631e9cbea23008e96bf47e26ec663339416a4e52d79d8d4499 | {
"func_code_index": [
996,
1388
]
} | 7,744 | |
SuperRocks | @openzeppelin/contracts/interfaces/IERC2981.sol | 0xf66bb6beebd5942d71e5e64e6008ef722f90a050 | Solidity | IERC2981 | interface IERC2981 is IERC165 {
/**
* @dev Called with the sale price to determine how much royalty is owed and to whom.
* @param tokenId - the NFT asset queried for royalty information
* @param salePrice - the sale price of the NFT asset specified by `tokenId`
* @return receiver - address of wh... | /**
* @dev Interface for the NFT Royalty Standard
*/ | NatSpecMultiLine | royaltyInfo | function royaltyInfo(uint256 tokenId, uint256 salePrice)
external
view
returns (address receiver, uint256 royaltyAmount);
| /**
* @dev Called with the sale price to determine how much royalty is owed and to whom.
* @param tokenId - the NFT asset queried for royalty information
* @param salePrice - the sale price of the NFT asset specified by `tokenId`
* @return receiver - address of who should be sent the royalty payment
* @return roya... | NatSpecMultiLine | v0.8.9+commit.e5eed63a | {
"func_code_index": [
439,
588
]
} | 7,745 | ||
BattleRoyaleNoPrize | contracts/BattleRoyaleNoPrize.sol | 0x29067696005279487ba66a46527087fb078286a6 | Solidity | BattleRoyaleNoPrize | contract BattleRoyaleNoPrize is ERC721URIStorage, Ownable {
using SafeERC20 for IERC20;
using Strings for uint256;
/// @notice Event emitted when contract is deployed.
event BattleRoyaleDeployed();
/// @notice Event emitted when owner withdrew the ETH.
event EthWithdrew(address receiver);
/// @notice E... | purchase | function purchase(uint256 _amount) external payable {
require(price > 0, "Token price is zero");
require(battleState == BATTLE_STATE.STANDBY, "Not ready to purchase tokens");
require(maxSupply > 0 && totalSupply < maxSupply, "All NFTs were sold out");
require(block.timestamp >= startingTime, "Not time to purcha... | /**
* @dev External function to purchase tokens.
* @param _amount Token amount to buy
*/ | NatSpecMultiLine | v0.8.6+commit.11564f7e | {
"func_code_index": [
3170,
4247
]
} | 7,746 | ||||
BattleRoyaleNoPrize | contracts/BattleRoyaleNoPrize.sol | 0x29067696005279487ba66a46527087fb078286a6 | Solidity | BattleRoyaleNoPrize | contract BattleRoyaleNoPrize is ERC721URIStorage, Ownable {
using SafeERC20 for IERC20;
using Strings for uint256;
/// @notice Event emitted when contract is deployed.
event BattleRoyaleDeployed();
/// @notice Event emitted when owner withdrew the ETH.
event EthWithdrew(address receiver);
/// @notice E... | setStartingTime | function setStartingTime(uint256 _newTime) external onlyOwner {
startingTime = _newTime;
emit StartingTimeSet(_newTime);
}
| /**
* @dev External function to set starting time. This function can be called only by owner.
*/ | NatSpecMultiLine | v0.8.6+commit.11564f7e | {
"func_code_index": [
4354,
4489
]
} | 7,747 | ||||
BattleRoyaleNoPrize | contracts/BattleRoyaleNoPrize.sol | 0x29067696005279487ba66a46527087fb078286a6 | Solidity | BattleRoyaleNoPrize | contract BattleRoyaleNoPrize is ERC721URIStorage, Ownable {
using SafeERC20 for IERC20;
using Strings for uint256;
/// @notice Event emitted when contract is deployed.
event BattleRoyaleDeployed();
/// @notice Event emitted when owner withdrew the ETH.
event EthWithdrew(address receiver);
/// @notice E... | startBattle | function startBattle() external onlyOwner {
require(bytes(prizeTokenURI).length > 0 && inPlay.length > 1, "Not enough tokens to play");
battleState = BATTLE_STATE.RUNNING;
emit BattleStarted(address(this), inPlay);
}
| /**
* @dev External function to start the battle. This function can be called only by owner.
*/ | NatSpecMultiLine | v0.8.6+commit.11564f7e | {
"func_code_index": [
4595,
4828
]
} | 7,748 | ||||
BattleRoyaleNoPrize | contracts/BattleRoyaleNoPrize.sol | 0x29067696005279487ba66a46527087fb078286a6 | Solidity | BattleRoyaleNoPrize | contract BattleRoyaleNoPrize is ERC721URIStorage, Ownable {
using SafeERC20 for IERC20;
using Strings for uint256;
/// @notice Event emitted when contract is deployed.
event BattleRoyaleDeployed();
/// @notice Event emitted when owner withdrew the ETH.
event EthWithdrew(address receiver);
/// @notice E... | endBattle | function endBattle(uint256 _winnerTokenId) external onlyOwner {
require(battleState == BATTLE_STATE.RUNNING, "Battle is not started");
battleState = BATTLE_STATE.ENDED;
string memory tokenURI = string(abi.encodePacked(baseURI, prizeTokenURI));
emit BattleEnded(address(this), _winnerTokenId, _winnerTokenId, to... | /**
* @dev External function to end the battle. This function can be called only by owner.
* @param _winnerTokenId Winner token Id in battle
*/ | NatSpecMultiLine | v0.8.6+commit.11564f7e | {
"func_code_index": [
4985,
5327
]
} | 7,749 | ||||
BattleRoyaleNoPrize | contracts/BattleRoyaleNoPrize.sol | 0x29067696005279487ba66a46527087fb078286a6 | Solidity | BattleRoyaleNoPrize | contract BattleRoyaleNoPrize is ERC721URIStorage, Ownable {
using SafeERC20 for IERC20;
using Strings for uint256;
/// @notice Event emitted when contract is deployed.
event BattleRoyaleDeployed();
/// @notice Event emitted when owner withdrew the ETH.
event EthWithdrew(address receiver);
/// @notice E... | setBaseURI | function setBaseURI(string memory _tokenURI) external onlyOwner {
baseURI = _tokenURI;
emit BaseURISet(baseURI);
}
| /**
* @dev External function to set the base token URI. This function can be called only by owner.
* @param _tokenURI New base token uri
*/ | NatSpecMultiLine | v0.8.6+commit.11564f7e | {
"func_code_index": [
5480,
5607
]
} | 7,750 | ||||
BattleRoyaleNoPrize | contracts/BattleRoyaleNoPrize.sol | 0x29067696005279487ba66a46527087fb078286a6 | Solidity | BattleRoyaleNoPrize | contract BattleRoyaleNoPrize is ERC721URIStorage, Ownable {
using SafeERC20 for IERC20;
using Strings for uint256;
/// @notice Event emitted when contract is deployed.
event BattleRoyaleDeployed();
/// @notice Event emitted when owner withdrew the ETH.
event EthWithdrew(address receiver);
/// @notice E... | setDefaultTokenURI | function setDefaultTokenURI(string memory _tokenURI) external onlyOwner {
defaultTokenURI = _tokenURI;
emit DefaultTokenURISet(defaultTokenURI);
}
| /**
* @dev External function to set the default token URI. This function can be called only by owner.
* @param _tokenURI New default token uri
*/ | NatSpecMultiLine | v0.8.6+commit.11564f7e | {
"func_code_index": [
5766,
5925
]
} | 7,751 | ||||
BattleRoyaleNoPrize | contracts/BattleRoyaleNoPrize.sol | 0x29067696005279487ba66a46527087fb078286a6 | Solidity | BattleRoyaleNoPrize | contract BattleRoyaleNoPrize is ERC721URIStorage, Ownable {
using SafeERC20 for IERC20;
using Strings for uint256;
/// @notice Event emitted when contract is deployed.
event BattleRoyaleDeployed();
/// @notice Event emitted when owner withdrew the ETH.
event EthWithdrew(address receiver);
/// @notice E... | setPrizeTokenURI | function setPrizeTokenURI(string memory _tokenURI) external onlyOwner {
prizeTokenURI = _tokenURI;
emit PrizeTokenURISet(prizeTokenURI);
}
| /**
* @dev External function to set the prize token URI. This function can be called only by owner.
* @param _tokenURI New prize token uri
*/ | NatSpecMultiLine | v0.8.6+commit.11564f7e | {
"func_code_index": [
6080,
6231
]
} | 7,752 | ||||
BattleRoyaleNoPrize | contracts/BattleRoyaleNoPrize.sol | 0x29067696005279487ba66a46527087fb078286a6 | Solidity | BattleRoyaleNoPrize | contract BattleRoyaleNoPrize is ERC721URIStorage, Ownable {
using SafeERC20 for IERC20;
using Strings for uint256;
/// @notice Event emitted when contract is deployed.
event BattleRoyaleDeployed();
/// @notice Event emitted when owner withdrew the ETH.
event EthWithdrew(address receiver);
/// @notice E... | setPrice | function setPrice(uint256 _price) external onlyOwner {
price = _price;
emit PriceSet(price);
}
| /**
* @dev External function to set the token price. This function can be called only by owner.
* @param _price New token price
*/ | NatSpecMultiLine | v0.8.6+commit.11564f7e | {
"func_code_index": [
6375,
6482
]
} | 7,753 | ||||
BattleRoyaleNoPrize | contracts/BattleRoyaleNoPrize.sol | 0x29067696005279487ba66a46527087fb078286a6 | Solidity | BattleRoyaleNoPrize | contract BattleRoyaleNoPrize is ERC721URIStorage, Ownable {
using SafeERC20 for IERC20;
using Strings for uint256;
/// @notice Event emitted when contract is deployed.
event BattleRoyaleDeployed();
/// @notice Event emitted when owner withdrew the ETH.
event EthWithdrew(address receiver);
/// @notice E... | setUnitsPerTransaction | function setUnitsPerTransaction(uint256 _unitsPerTransaction) external onlyOwner {
unitsPerTransaction = _unitsPerTransaction;
emit UnitsPerTransactionSet(unitsPerTransaction);
}
| /**
* @dev External function to set the limit of buyable token amounts. This function can be called only by owner.
* @param _unitsPerTransaction New purchasable token amounts per transaction
*/ | NatSpecMultiLine | v0.8.6+commit.11564f7e | {
"func_code_index": [
6689,
6880
]
} | 7,754 | ||||
BattleRoyaleNoPrize | contracts/BattleRoyaleNoPrize.sol | 0x29067696005279487ba66a46527087fb078286a6 | Solidity | BattleRoyaleNoPrize | contract BattleRoyaleNoPrize is ERC721URIStorage, Ownable {
using SafeERC20 for IERC20;
using Strings for uint256;
/// @notice Event emitted when contract is deployed.
event BattleRoyaleDeployed();
/// @notice Event emitted when owner withdrew the ETH.
event EthWithdrew(address receiver);
/// @notice E... | setMaxSupply | function setMaxSupply(uint256 _maxSupply) external onlyOwner {
maxSupply = _maxSupply;
emit MaxSupplySet(maxSupply);
}
| /**
* @dev External function to set max supply. This function can be called only by owner.
* @param _maxSupply New maximum token amounts
*/ | NatSpecMultiLine | v0.8.6+commit.11564f7e | {
"func_code_index": [
7033,
7164
]
} | 7,755 | ||||
BattleRoyaleNoPrize | contracts/BattleRoyaleNoPrize.sol | 0x29067696005279487ba66a46527087fb078286a6 | Solidity | BattleRoyaleNoPrize | contract BattleRoyaleNoPrize is ERC721URIStorage, Ownable {
using SafeERC20 for IERC20;
using Strings for uint256;
/// @notice Event emitted when contract is deployed.
event BattleRoyaleDeployed();
/// @notice Event emitted when owner withdrew the ETH.
event EthWithdrew(address receiver);
/// @notice E... | /**
* Fallback function to receive ETH
*/ | NatSpecMultiLine | v0.8.6+commit.11564f7e | {
"func_code_index": [
7216,
7247
]
} | 7,756 | ||||||
BattleRoyaleNoPrize | contracts/BattleRoyaleNoPrize.sol | 0x29067696005279487ba66a46527087fb078286a6 | Solidity | BattleRoyaleNoPrize | contract BattleRoyaleNoPrize is ERC721URIStorage, Ownable {
using SafeERC20 for IERC20;
using Strings for uint256;
/// @notice Event emitted when contract is deployed.
event BattleRoyaleDeployed();
/// @notice Event emitted when owner withdrew the ETH.
event EthWithdrew(address receiver);
/// @notice E... | withdrawETH | function withdrawETH(uint256 _amount) external onlyOwner {
uint256 balance = address(this).balance;
require(_amount <= balance, "Out of balance");
payable(msg.sender).transfer(_amount);
emit EthWithdrew(msg.sender);
}
| /**
* @dev External function to withdraw ETH in contract. This function can be called only by owner.
* @param _amount ETH amount
*/ | NatSpecMultiLine | v0.8.6+commit.11564f7e | {
"func_code_index": [
7392,
7631
]
} | 7,757 | ||||
BattleRoyaleNoPrize | contracts/BattleRoyaleNoPrize.sol | 0x29067696005279487ba66a46527087fb078286a6 | Solidity | BattleRoyaleNoPrize | contract BattleRoyaleNoPrize is ERC721URIStorage, Ownable {
using SafeERC20 for IERC20;
using Strings for uint256;
/// @notice Event emitted when contract is deployed.
event BattleRoyaleDeployed();
/// @notice Event emitted when owner withdrew the ETH.
event EthWithdrew(address receiver);
/// @notice E... | withdrawERC20Token | function withdrawERC20Token(address _tokenAddr, uint256 _amount) external onlyOwner {
IERC20 token = IERC20(_tokenAddr);
uint256 balance = token.balanceOf(address(this));
require(_amount <= balance, "Out of balance");
token.safeTransfer(msg.sender, _amount);
emit ERC20TokenWithdrew(msg.sender);
}
| /**
* @dev External function to withdraw ERC-20 tokens in contract. This function can be called only by owner.
* @param _tokenAddr Address of ERC-20 token
* @param _amount ERC-20 token amount
*/ | NatSpecMultiLine | v0.8.6+commit.11564f7e | {
"func_code_index": [
7842,
8166
]
} | 7,758 | ||||
BonumFinancialTokenPreSale | BonumFinancialTokenPreSale.sol | 0x4e9992c9b97873a39e264832972f29ce672ebaf1 | Solidity | Ownable | contract Ownable {
address public owner;
event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
/**
* @dev The Ownable constructor sets the original `owner` of the contract to the sender
* account.
*/
function Ownable() {
owner = msg.sender;
}
... | /**
* @title Ownable
* @dev The Ownable contract has an owner address, and provides basic authorization control
* functions, this simplifies the implementation of "user permissions".
*/ | NatSpecMultiLine | Ownable | function Ownable() {
owner = msg.sender;
}
| /**
* @dev The Ownable constructor sets the original `owner` of the contract to the sender
* account.
*/ | NatSpecMultiLine | v0.4.21+commit.dfe3193c | bzzr://4e58174758f1fe805c45bbaefd214f94ca5a520f1a027a7f7aaf069bb9971b53 | {
"func_code_index": [
261,
314
]
} | 7,759 | |
BonumFinancialTokenPreSale | BonumFinancialTokenPreSale.sol | 0x4e9992c9b97873a39e264832972f29ce672ebaf1 | Solidity | Ownable | contract Ownable {
address public owner;
event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
/**
* @dev The Ownable constructor sets the original `owner` of the contract to the sender
* account.
*/
function Ownable() {
owner = msg.sender;
}
... | /**
* @title Ownable
* @dev The Ownable contract has an owner address, and provides basic authorization control
* functions, this simplifies the implementation of "user permissions".
*/ | NatSpecMultiLine | transferOwnership | function transferOwnership(address newOwner) onlyOwner public {
require(newOwner != address(0));
OwnershipTransferred(owner, newOwner);
owner = newOwner;
}
| /**
* @dev Allows the current owner to transfer control of the contract to a newOwner.
* @param newOwner The address to transfer ownership to.
*/ | NatSpecMultiLine | v0.4.21+commit.dfe3193c | bzzr://4e58174758f1fe805c45bbaefd214f94ca5a520f1a027a7f7aaf069bb9971b53 | {
"func_code_index": [
637,
813
]
} | 7,760 | |
BonumFinancialTokenPreSale | BonumFinancialTokenPreSale.sol | 0x4e9992c9b97873a39e264832972f29ce672ebaf1 | Solidity | Pausable | contract Pausable is Ownable {
event Pause();
event Unpause();
bool public paused = false;
/**
* @dev Modifier to make a function callable only when the contract is not paused.
*/
modifier whenNotPaused() {
require(!paused);
_;
}
/**
* @dev Modifier to make a function ... | /**
* @title Pausable
* @dev Base contract which allows children to implement an emergency stop mechanism.
*/ | NatSpecMultiLine | pause | function pause() onlyOwner whenNotPaused public {
paused = true;
Pause();
}
| /**
* @dev called by the owner to pause, triggers stopped state
*/ | NatSpecMultiLine | v0.4.21+commit.dfe3193c | bzzr://4e58174758f1fe805c45bbaefd214f94ca5a520f1a027a7f7aaf069bb9971b53 | {
"func_code_index": [
513,
604
]
} | 7,761 | |
BonumFinancialTokenPreSale | BonumFinancialTokenPreSale.sol | 0x4e9992c9b97873a39e264832972f29ce672ebaf1 | Solidity | Pausable | contract Pausable is Ownable {
event Pause();
event Unpause();
bool public paused = false;
/**
* @dev Modifier to make a function callable only when the contract is not paused.
*/
modifier whenNotPaused() {
require(!paused);
_;
}
/**
* @dev Modifier to make a function ... | /**
* @title Pausable
* @dev Base contract which allows children to implement an emergency stop mechanism.
*/ | NatSpecMultiLine | unpause | function unpause() onlyOwner whenPaused public {
paused = false;
Unpause();
}
| /**
* @dev called by the owner to unpause, returns to normal state
*/ | NatSpecMultiLine | v0.4.21+commit.dfe3193c | bzzr://4e58174758f1fe805c45bbaefd214f94ca5a520f1a027a7f7aaf069bb9971b53 | {
"func_code_index": [
688,
781
]
} | 7,762 | |
BonumFinancialTokenPreSale | BonumFinancialTokenPreSale.sol | 0x4e9992c9b97873a39e264832972f29ce672ebaf1 | Solidity | InvestorsList | contract InvestorsList is Ownable {
using SafeMath for uint;
/* Investor */
enum WhiteListStatus {Usual, WhiteList, PreWhiteList}
struct Investor {
bytes32 id;
uint tokensCount;
address walletForTokens;
WhiteListStatus whiteListStatus;
bool isVerif... | setInvestorId | function setInvestorId(address investorAddress, bytes32 id) external onlyOwner{
require(investorAddress != 0x0 && id != 0);
nativeInvestorsIds[investorAddress] = id;
}
| /*Manipulators' end*/ | Comment | v0.4.21+commit.dfe3193c | bzzr://4e58174758f1fe805c45bbaefd214f94ca5a520f1a027a7f7aaf069bb9971b53 | {
"func_code_index": [
919,
1114
]
} | 7,763 | |||
BonumFinancialTokenPreSale | BonumFinancialTokenPreSale.sol | 0x4e9992c9b97873a39e264832972f29ce672ebaf1 | Solidity | BonumFinancialTokenPreSale | contract BonumFinancialTokenPreSale is Pausable{
using SafeMath for uint;
string public constant name = "Bonum Financial Token PreSale";
uint public startDate;
uint public endDate;
uint public whiteListPreSaleDuration = 1 days;
function setWhiteListDuration(uint duration) external on... | otherCoinsPurchase | function otherCoinsPurchase(bytes32 id, uint amountInUsd) external whenNotPaused underCap activePreSale onlyOwner {
require(id.length > 0 && amountInUsd >= (uint(100).mul(fiatValueMultiplier)) && investors.isAllowedToBuy(id));
uint tokens = amountInUsd.mul(tokenDecimals).div(fiatValueMultiplier);
tok... | //usd * 10^6 | LineComment | v0.4.21+commit.dfe3193c | bzzr://4e58174758f1fe805c45bbaefd214f94ca5a520f1a027a7f7aaf069bb9971b53 | {
"func_code_index": [
3528,
4072
]
} | 7,764 | |||
Fliquidator | contracts/Flashloans/Flasher.sol | 0xe3a2df184c021b8cbdfe2e89f7d3f495473b2be0 | Solidity | Flasher | contract Flasher is
DyDxFlashloanBase,
IFlashLoanReceiver,
ICallee,
Ownable
{
using SafeMath for uint256;
using UniERC20 for IERC20;
IFujiAdmin private _fujiAdmin;
address public aave_lending_pool;
address public dydx_solo_margin;
receive() external payable {}
constructor() public {
aave... | setFujiAdmin | function setFujiAdmin(address _newFujiAdmin) public onlyOwner {
_fujiAdmin = IFujiAdmin(_newFujiAdmin);
}
| /**
* @dev Sets the fujiAdmin Address
* @param _newFujiAdmin: FujiAdmin Contract Address
*/ | NatSpecMultiLine | v0.6.12+commit.27d51765 | {
"func_code_index": [
952,
1065
]
} | 7,765 | ||||
Fliquidator | contracts/Flashloans/Flasher.sol | 0xe3a2df184c021b8cbdfe2e89f7d3f495473b2be0 | Solidity | Flasher | contract Flasher is
DyDxFlashloanBase,
IFlashLoanReceiver,
ICallee,
Ownable
{
using SafeMath for uint256;
using UniERC20 for IERC20;
IFujiAdmin private _fujiAdmin;
address public aave_lending_pool;
address public dydx_solo_margin;
receive() external payable {}
constructor() public {
aave... | initiateFlashloan | function initiateFlashloan(FlashLoan.Info memory info, uint8 _flashnum) public isAuthorized {
if(_flashnum==0) {
initiateAaveFlashLoan(info);
} else if(_flashnum==1) {
initiateDyDxFlashLoan(info);
}
}
| /**
* @dev Routing Function for Flashloan Provider
* @param info: struct information for flashLoan
* @param _flashnum: integer identifier of flashloan provider
*/ | NatSpecMultiLine | v0.6.12+commit.27d51765 | {
"func_code_index": [
1241,
1469
]
} | 7,766 | ||||
Fliquidator | contracts/Flashloans/Flasher.sol | 0xe3a2df184c021b8cbdfe2e89f7d3f495473b2be0 | Solidity | Flasher | contract Flasher is
DyDxFlashloanBase,
IFlashLoanReceiver,
ICallee,
Ownable
{
using SafeMath for uint256;
using UniERC20 for IERC20;
IFujiAdmin private _fujiAdmin;
address public aave_lending_pool;
address public dydx_solo_margin;
receive() external payable {}
constructor() public {
aave... | initiateDyDxFlashLoan | function initiateDyDxFlashLoan(
FlashLoan.Info memory info
) internal {
ISoloMargin solo = ISoloMargin(dydx_solo_margin);
// Get marketId from token address
uint256 marketId = _getMarketIdFromTokenAddress(solo, info.asset);
// 1. Withdraw $
// 2. Call callFunction(...)
// 3. Deposit back $
Actions.Ac... | /**
* @dev Initiates a DyDx flashloan.
* @param info: data to be passed between functions executing flashloan logic
*/ | NatSpecMultiLine | v0.6.12+commit.27d51765 | {
"func_code_index": [
1677,
2501
]
} | 7,767 | ||||
Fliquidator | contracts/Flashloans/Flasher.sol | 0xe3a2df184c021b8cbdfe2e89f7d3f495473b2be0 | Solidity | Flasher | contract Flasher is
DyDxFlashloanBase,
IFlashLoanReceiver,
ICallee,
Ownable
{
using SafeMath for uint256;
using UniERC20 for IERC20;
IFujiAdmin private _fujiAdmin;
address public aave_lending_pool;
address public dydx_solo_margin;
receive() external payable {}
constructor() public {
aave... | callFunction | function callFunction(
address sender,
Account.Info memory account,
bytes memory data
) external override isAuthorizedExternal {
sender;
account;
FlashLoan.Info memory info = abi.decode(data, (FlashLoan.Info));
//Estimate flashloan payback + premium fee of 2 wei,
uint amountOwing = info.amount.add(2);... | /**
* @dev Executes DyDx Flashloan, this operation is required
* and called by Solo when sending loaned amount
* @param sender: Not used
* @param account: Not used
*/ | NatSpecMultiLine | v0.6.12+commit.27d51765 | {
"func_code_index": [
2682,
3712
]
} | 7,768 | ||||
Fliquidator | contracts/Flashloans/Flasher.sol | 0xe3a2df184c021b8cbdfe2e89f7d3f495473b2be0 | Solidity | Flasher | contract Flasher is
DyDxFlashloanBase,
IFlashLoanReceiver,
ICallee,
Ownable
{
using SafeMath for uint256;
using UniERC20 for IERC20;
IFujiAdmin private _fujiAdmin;
address public aave_lending_pool;
address public dydx_solo_margin;
receive() external payable {}
constructor() public {
aave... | initiateAaveFlashLoan | function initiateAaveFlashLoan(
FlashLoan.Info memory info
) internal {
//Initialize Instance of Aave Lending Pool
ILendingPool aaveLp = ILendingPool(aave_lending_pool);
//Passing arguments to construct Aave flashloan -limited to 1 asset type for now.
address receiverAddress = address(this);
address[] mem... | /**
* @dev Initiates an Aave flashloan.
* @param info: data to be passed between functions executing flashloan logic
*/ | NatSpecMultiLine | v0.6.12+commit.27d51765 | {
"func_code_index": [
3922,
4811
]
} | 7,769 | ||||
Fliquidator | contracts/Flashloans/Flasher.sol | 0xe3a2df184c021b8cbdfe2e89f7d3f495473b2be0 | Solidity | Flasher | contract Flasher is
DyDxFlashloanBase,
IFlashLoanReceiver,
ICallee,
Ownable
{
using SafeMath for uint256;
using UniERC20 for IERC20;
IFujiAdmin private _fujiAdmin;
address public aave_lending_pool;
address public dydx_solo_margin;
receive() external payable {}
constructor() public {
aave... | executeOperation | function executeOperation(
address[] calldata assets,
uint256[] calldata amounts,
uint256[] calldata premiums,
address initiator,
bytes calldata params
) external override isAuthorizedExternal returns (bool) {
initiator;
FlashLoan.Info memory info = abi.decode(params, (FlashLoan.Info));
//Estimate fla... | /**
* @dev Executes Aave Flashloan, this operation is required
* and called by Aaveflashloan when sending loaned amount
*/ | NatSpecMultiLine | v0.6.12+commit.27d51765 | {
"func_code_index": [
4944,
6096
]
} | 7,770 | ||||
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | SafeMath | library SafeMath {
/**
* @dev Multiplies two numbers, throws on overflow.
*/
function mul(uint256 a, uint256 b) internal pure returns (uint256 c) {
// Gas optimization: this is cheaper than asserting 'a' not being zero, but the
// benefit is lost if 'b' is also tested.
if (a == 0) {
return 0;
}
c = a * ... | /**
* @title SafeMath
* @dev Math operations with safety checks that throw on error
*/ | NatSpecMultiLine | mul | function mul(uint256 a, uint256 b) internal pure returns (uint256 c) {
// Gas optimization: this is cheaper than asserting 'a' not being zero, but the
// benefit is lost if 'b' is also tested.
if (a == 0) {
return 0;
}
c = a * b;
assert(c / a == b);
return c;
}
| /**
* @dev Multiplies two numbers, throws on overflow.
*/ | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
83,
358
]
} | 7,771 |
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | SafeMath | library SafeMath {
/**
* @dev Multiplies two numbers, throws on overflow.
*/
function mul(uint256 a, uint256 b) internal pure returns (uint256 c) {
// Gas optimization: this is cheaper than asserting 'a' not being zero, but the
// benefit is lost if 'b' is also tested.
if (a == 0) {
return 0;
}
c = a * ... | /**
* @title SafeMath
* @dev Math operations with safety checks that throw on error
*/ | NatSpecMultiLine | div | function div(uint256 a, uint256 b) internal pure returns (uint256) {
// assert(b > 0); // Solidity automatically throws when dividing by 0
// uint256 c = a / b;
// assert(a == b * c + a % b); // There is no case in which this doesn't hold
return a / b;
}
| /**
* @dev Integer division of two numbers, truncating the quotient.
*/ | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
436,
696
]
} | 7,772 |
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | SafeMath | library SafeMath {
/**
* @dev Multiplies two numbers, throws on overflow.
*/
function mul(uint256 a, uint256 b) internal pure returns (uint256 c) {
// Gas optimization: this is cheaper than asserting 'a' not being zero, but the
// benefit is lost if 'b' is also tested.
if (a == 0) {
return 0;
}
c = a * ... | /**
* @title SafeMath
* @dev Math operations with safety checks that throw on error
*/ | NatSpecMultiLine | sub | function sub(uint256 a, uint256 b) internal pure returns (uint256) {
assert(b <= a);
return a - b;
}
| /**
* @dev Subtracts two numbers, throws on overflow (i.e. if subtrahend is greater than minuend).
*/ | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
804,
908
]
} | 7,773 |
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | SafeMath | library SafeMath {
/**
* @dev Multiplies two numbers, throws on overflow.
*/
function mul(uint256 a, uint256 b) internal pure returns (uint256 c) {
// Gas optimization: this is cheaper than asserting 'a' not being zero, but the
// benefit is lost if 'b' is also tested.
if (a == 0) {
return 0;
}
c = a * ... | /**
* @title SafeMath
* @dev Math operations with safety checks that throw on error
*/ | NatSpecMultiLine | add | function add(uint256 a, uint256 b) internal pure returns (uint256 c) {
c = a + b;
assert(c >= a);
return c;
}
| /**
* @dev Adds two numbers, throws on overflow.
*/ | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
966,
1080
]
} | 7,774 |
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | BasicToken | contract BasicToken is ERC20Basic {
using SafeMath for uint256;
mapping(address => uint256) balances;
uint256 totalSupply_;
/**
* @dev total number of tokens in existence
*/
function totalSupply() public view returns (uint256) {
return totalSupply_;
}
/**
* @dev transfer token for a specified address... | /**
* @title Basic token
* @dev Basic version of StandardToken, with no allowances.
*/ | NatSpecMultiLine | totalSupply | function totalSupply() public view returns (uint256) {
return totalSupply_;
}
| /**
* @dev total number of tokens in existence
*/ | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
187,
267
]
} | 7,775 |
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | BasicToken | contract BasicToken is ERC20Basic {
using SafeMath for uint256;
mapping(address => uint256) balances;
uint256 totalSupply_;
/**
* @dev total number of tokens in existence
*/
function totalSupply() public view returns (uint256) {
return totalSupply_;
}
/**
* @dev transfer token for a specified address... | /**
* @title Basic token
* @dev Basic version of StandardToken, with no allowances.
*/ | NatSpecMultiLine | transfer | function transfer(address _to, uint256 _value) public returns (bool) {
require(_to != address(0));
require(_value <= balances[msg.sender]);
balances[msg.sender] = balances[msg.sender].sub(_value);
balances[_to] = balances[_to].add(_value);
emit Transfer(msg.sender, _to, _value);
return true;
}
| /**
* @dev transfer token for a specified address
* @param _to The address to transfer to.
* @param _value The amount to be transferred.
*/ | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
415,
719
]
} | 7,776 |
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | BasicToken | contract BasicToken is ERC20Basic {
using SafeMath for uint256;
mapping(address => uint256) balances;
uint256 totalSupply_;
/**
* @dev total number of tokens in existence
*/
function totalSupply() public view returns (uint256) {
return totalSupply_;
}
/**
* @dev transfer token for a specified address... | /**
* @title Basic token
* @dev Basic version of StandardToken, with no allowances.
*/ | NatSpecMultiLine | balanceOf | function balanceOf(address _owner) public view returns (uint256) {
return balances[_owner];
}
| /**
* @dev Gets the balance of the specified address.
* @param _owner The address to query the the balance of.
* @return An uint256 representing the amount owned by the passed address.
*/ | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
915,
1011
]
} | 7,777 |
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | StandardToken | contract StandardToken is ERC20, BasicToken {
mapping (address => mapping (address => uint256)) internal allowed;
/**
* @dev Transfer tokens from one address to another
* @param _from address The address which you want to send tokens from
* @param _to address The address which you want to transfer to
* @par... | /**
* @title Standard ERC20 token
*
* @dev Implementation of the basic standard token.
* @dev https://github.com/ethereum/EIPs/issues/20
* @dev Based on code by FirstBlood: https://github.com/Firstbloodio/token/blob/master/smart_contract/FirstBloodToken.sol
*/ | NatSpecMultiLine | transferFrom | function transferFrom(
address _from,
address _to,
uint256 _value
)
public
returns (bool)
{
require(_to != address(0));
require(_value <= balances[_from]);
require(_value <= allowed[_from][msg.sender]);
balances[_from] = balances[_from].sub(_value);
balances[_to] = balances[_to].add(_value);
allowed[_fro... | /**
* @dev Transfer tokens from one address to another
* @param _from address The address which you want to send tokens from
* @param _to address The address which you want to transfer to
* @param _value uint256 the amount of tokens to be transferred
*/ | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
382,
812
]
} | 7,778 |
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | StandardToken | contract StandardToken is ERC20, BasicToken {
mapping (address => mapping (address => uint256)) internal allowed;
/**
* @dev Transfer tokens from one address to another
* @param _from address The address which you want to send tokens from
* @param _to address The address which you want to transfer to
* @par... | /**
* @title Standard ERC20 token
*
* @dev Implementation of the basic standard token.
* @dev https://github.com/ethereum/EIPs/issues/20
* @dev Based on code by FirstBlood: https://github.com/Firstbloodio/token/blob/master/smart_contract/FirstBloodToken.sol
*/ | NatSpecMultiLine | approve | function approve(address _spender, uint256 _value) public returns (bool) {
allowed[msg.sender][_spender] = _value;
emit Approval(msg.sender, _spender, _value);
return true;
}
| /**
* @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender.
* @param _spender The address which will spend the funds.
* @param _value The amount of tokens to be spent.
*/ | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
1034,
1213
]
} | 7,779 |
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | StandardToken | contract StandardToken is ERC20, BasicToken {
mapping (address => mapping (address => uint256)) internal allowed;
/**
* @dev Transfer tokens from one address to another
* @param _from address The address which you want to send tokens from
* @param _to address The address which you want to transfer to
* @par... | /**
* @title Standard ERC20 token
*
* @dev Implementation of the basic standard token.
* @dev https://github.com/ethereum/EIPs/issues/20
* @dev Based on code by FirstBlood: https://github.com/Firstbloodio/token/blob/master/smart_contract/FirstBloodToken.sol
*/ | NatSpecMultiLine | allowance | function allowance(
address _owner,
address _spender
)
public
view
returns (uint256)
{
return allowed[_owner][_spender];
}
| /**
* @dev Function to check the amount of tokens that an owner allowed to a spender.
* @param _owner address The address which owns the funds.
* @param _spender address The address which will spend the funds.
* @return A uint256 specifying the amount of tokens still available for the spender.
*/ | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
1520,
1652
]
} | 7,780 |
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | StandardToken | contract StandardToken is ERC20, BasicToken {
mapping (address => mapping (address => uint256)) internal allowed;
/**
* @dev Transfer tokens from one address to another
* @param _from address The address which you want to send tokens from
* @param _to address The address which you want to transfer to
* @par... | /**
* @title Standard ERC20 token
*
* @dev Implementation of the basic standard token.
* @dev https://github.com/ethereum/EIPs/issues/20
* @dev Based on code by FirstBlood: https://github.com/Firstbloodio/token/blob/master/smart_contract/FirstBloodToken.sol
*/ | NatSpecMultiLine | increaseApproval | function increaseApproval(
address _spender,
uint _addedValue
)
public
returns (bool)
{
allowed[msg.sender][_spender] = (
allowed[msg.sender][_spender].add(_addedValue));
emit Approval(msg.sender, _spender, allowed[msg.sender][_spender]);
return true;
}
| /**
* @dev Increase the amount of tokens that an owner allowed to a spender.
*
* approve should be called when allowed[_spender] == 0. To increment
* allowed value is better to use this function to avoid 2 calls (and wait until
* the first transaction is mined)
* From MonolithDAO Token.sol
* @param _spend... | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
2089,
2354
]
} | 7,781 |
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | StandardToken | contract StandardToken is ERC20, BasicToken {
mapping (address => mapping (address => uint256)) internal allowed;
/**
* @dev Transfer tokens from one address to another
* @param _from address The address which you want to send tokens from
* @param _to address The address which you want to transfer to
* @par... | /**
* @title Standard ERC20 token
*
* @dev Implementation of the basic standard token.
* @dev https://github.com/ethereum/EIPs/issues/20
* @dev Based on code by FirstBlood: https://github.com/Firstbloodio/token/blob/master/smart_contract/FirstBloodToken.sol
*/ | NatSpecMultiLine | decreaseApproval | function decreaseApproval(
address _spender,
uint _subtractedValue
)
public
returns (bool)
{
uint oldValue = allowed[msg.sender][_spender];
if (_subtractedValue > oldValue) {
allowed[msg.sender][_spender] = 0;
} else {
allowed[msg.sender][_spender] = oldValue.sub(_subtractedValue);
}
emit Approval(msg.send... | /**
* @dev Decrease the amount of tokens that an owner allowed to a spender.
*
* approve should be called when allowed[_spender] == 0. To decrement
* allowed value is better to use this function to avoid 2 calls (and wait until
* the first transaction is mined)
* From MonolithDAO Token.sol
* @param _spend... | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
2796,
3179
]
} | 7,782 |
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | Ownable | contract Ownable {
address public owner;
event OwnershipRenounced(address indexed previousOwner);
event OwnershipTransferred(
address indexed previousOwner,
address indexed newOwner
);
/**
* @dev The Ownable constructor sets the original `owner` of the contract to the sender
* account.
*/
constructor... | /**
* @title Ownable
* @dev The Ownable contract has an owner address, and provides basic authorization control
* functions, this simplifies the implementation of "user permissions".
*/ | NatSpecMultiLine | renounceOwnership | function renounceOwnership() public onlyOwner {
emit OwnershipRenounced(owner);
owner = address(0);
}
| /**
* @dev Allows the current owner to relinquish control of the contract.
*/ | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
575,
680
]
} | 7,783 |
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | Ownable | contract Ownable {
address public owner;
event OwnershipRenounced(address indexed previousOwner);
event OwnershipTransferred(
address indexed previousOwner,
address indexed newOwner
);
/**
* @dev The Ownable constructor sets the original `owner` of the contract to the sender
* account.
*/
constructor... | /**
* @title Ownable
* @dev The Ownable contract has an owner address, and provides basic authorization control
* functions, this simplifies the implementation of "user permissions".
*/ | NatSpecMultiLine | transferOwnership | function transferOwnership(address _newOwner) public onlyOwner {
_transferOwnership(_newOwner);
}
| /**
* @dev Allows the current owner to transfer control of the contract to a newOwner.
* @param _newOwner The address to transfer ownership to.
*/ | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
834,
934
]
} | 7,784 |
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | Ownable | contract Ownable {
address public owner;
event OwnershipRenounced(address indexed previousOwner);
event OwnershipTransferred(
address indexed previousOwner,
address indexed newOwner
);
/**
* @dev The Ownable constructor sets the original `owner` of the contract to the sender
* account.
*/
constructor... | /**
* @title Ownable
* @dev The Ownable contract has an owner address, and provides basic authorization control
* functions, this simplifies the implementation of "user permissions".
*/ | NatSpecMultiLine | _transferOwnership | function _transferOwnership(address _newOwner) internal {
require(_newOwner != address(0));
emit OwnershipTransferred(owner, _newOwner);
owner = _newOwner;
}
| /**
* @dev Transfers control of the contract to a newOwner.
* @param _newOwner The address to transfer ownership to.
*/ | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
1061,
1223
]
} | 7,785 |
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | MintableToken | contract MintableToken is StandardToken, Ownable {
event Mint(address indexed to, uint256 amount);
event MintFinished();
bool public mintingFinished = false;
modifier canMint() {
require(!mintingFinished);
_;
}
modifier hasMintPermission() {
require(msg.sender == owner);
_;
}
/**
* @dev Function ... | /**
* @title Mintable token
*/ | NatSpecMultiLine | mint | function mint(
address _to,
uint256 _amount
)
hasMintPermission
canMint
public
returns (bool)
{
totalSupply_ = totalSupply_.add(_amount);
balances[_to] = balances[_to].add(_amount);
emit Mint(_to, _amount);
emit Transfer(address(0), _to, _amount);
return true;
}
| /**
* @dev Function to mint tokens
* @param _to The address that will receive the minted tokens.
* @param _amount The amount of tokens to mint.
* @return A boolean that indicates if the operation was successful.
*/ | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
520,
797
]
} | 7,786 |
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | MintableToken | contract MintableToken is StandardToken, Ownable {
event Mint(address indexed to, uint256 amount);
event MintFinished();
bool public mintingFinished = false;
modifier canMint() {
require(!mintingFinished);
_;
}
modifier hasMintPermission() {
require(msg.sender == owner);
_;
}
/**
* @dev Function ... | /**
* @title Mintable token
*/ | NatSpecMultiLine | finishMinting | function finishMinting() onlyOwner canMint public returns (bool) {
mintingFinished = true;
emit MintFinished();
return true;
}
| /**
* @dev Function to stop minting new tokens.
* @return True if the operation was successful.
*/ | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
903,
1034
]
} | 7,787 |
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | FreezableToken | contract FreezableToken is StandardToken {
// freezing chains
mapping (bytes32 => uint64) internal chains;
// freezing amounts for each chain
mapping (bytes32 => uint) internal freezings;
// total freezing balance per address
mapping (address => uint) internal freezingBalance;
event Freezed(address indexed to,... | balanceOf | function balanceOf(address _owner) public view returns (uint256 balance) {
return super.balanceOf(_owner) + freezingBalance[_owner];
}
| /**
* @dev Gets the balance of the specified address include freezing tokens.
* @param _owner The address to query the the balance of.
* @return An uint256 representing the amount owned by the passed address.
*/ | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
624,
761
]
} | 7,788 | ||
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | FreezableToken | contract FreezableToken is StandardToken {
// freezing chains
mapping (bytes32 => uint64) internal chains;
// freezing amounts for each chain
mapping (bytes32 => uint) internal freezings;
// total freezing balance per address
mapping (address => uint) internal freezingBalance;
event Freezed(address indexed to,... | actualBalanceOf | function actualBalanceOf(address _owner) public view returns (uint256 balance) {
return super.balanceOf(_owner);
}
| /**
* @dev Gets the balance of the specified address without freezing tokens.
* @param _owner The address to query the the balance of.
* @return An uint256 representing the amount owned by the passed address.
*/ | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
981,
1098
]
} | 7,789 | ||
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | FreezableToken | contract FreezableToken is StandardToken {
// freezing chains
mapping (bytes32 => uint64) internal chains;
// freezing amounts for each chain
mapping (bytes32 => uint) internal freezings;
// total freezing balance per address
mapping (address => uint) internal freezingBalance;
event Freezed(address indexed to,... | freezingCount | function freezingCount(address _addr) public view returns (uint count) {
uint64 release = chains[toKey(_addr, 0)];
while (release != 0) {
count++;
release = chains[toKey(_addr, release)];
}
}
| /**
* @dev gets freezing count
* @param _addr Address of freeze tokens owner.
*/ | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
1308,
1506
]
} | 7,790 | ||
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | FreezableToken | contract FreezableToken is StandardToken {
// freezing chains
mapping (bytes32 => uint64) internal chains;
// freezing amounts for each chain
mapping (bytes32 => uint) internal freezings;
// total freezing balance per address
mapping (address => uint) internal freezingBalance;
event Freezed(address indexed to,... | getFreezing | function getFreezing(address _addr, uint _index) public view returns (uint64 _release, uint _balance) {
for (uint i = 0; i < _index + 1; i++) {
_release = chains[toKey(_addr, _release)];
if (_release == 0) {
return;
}
}
_balance = freezings[toKey(_addr, _release)];
}
| /**
* @dev gets freezing end date and freezing balance for the freezing portion specified by index.
* @param _addr Address of freeze tokens owner.
* @param _index Freezing portion index. It ordered by release date descending.
*/ | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
1743,
2019
]
} | 7,791 | ||
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | FreezableToken | contract FreezableToken is StandardToken {
// freezing chains
mapping (bytes32 => uint64) internal chains;
// freezing amounts for each chain
mapping (bytes32 => uint) internal freezings;
// total freezing balance per address
mapping (address => uint) internal freezingBalance;
event Freezed(address indexed to,... | freezeTo | function freezeTo(address _to, uint _amount, uint64 _until) public {
require(_to != address(0));
require(_amount <= balances[msg.sender]);
balances[msg.sender] = balances[msg.sender].sub(_amount);
bytes32 currentKey = toKey(_to, _until);
freezings[currentKey] = freezings[currentKey].add(_amount);
freezingBala... | /**
* @dev freeze your tokens to the specified address.
* Be careful, gas usage is not deterministic,
* and depends on how many freezes _to address already has.
* @param _to Address to which token will be freeze.
* @param _amount Amount of token to freeze.
* @param _until Release date, must be in future.
... | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
2339,
2811
]
} | 7,792 | ||
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | FreezableToken | contract FreezableToken is StandardToken {
// freezing chains
mapping (bytes32 => uint64) internal chains;
// freezing amounts for each chain
mapping (bytes32 => uint) internal freezings;
// total freezing balance per address
mapping (address => uint) internal freezingBalance;
event Freezed(address indexed to,... | releaseOnce | function releaseOnce() public {
bytes32 headKey = toKey(msg.sender, 0);
uint64 head = chains[headKey];
require(head != 0);
require(uint64(block.timestamp) > head);
bytes32 currentKey = toKey(msg.sender, head);
uint64 next = chains[currentKey];
uint amount = freezings[currentKey];
delete freezings[currentKey... | /**
* @dev release first available freezing tokens.
*/ | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
2872,
3477
]
} | 7,793 | ||
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | FreezableToken | contract FreezableToken is StandardToken {
// freezing chains
mapping (bytes32 => uint64) internal chains;
// freezing amounts for each chain
mapping (bytes32 => uint) internal freezings;
// total freezing balance per address
mapping (address => uint) internal freezingBalance;
event Freezed(address indexed to,... | releaseAll | function releaseAll() public returns (uint tokens) {
uint release;
uint balance;
(release, balance) = getFreezing(msg.sender, 0);
while (release != 0 && block.timestamp > release) {
releaseOnce();
tokens += balance;
(release, balance) = getFreezing(msg.sender, 0);
}
}
| /**
* @dev release all available for release freezing tokens. Gas usage is not deterministic!
* @return how many tokens was released
*/ | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
3620,
3898
]
} | 7,794 | ||
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | BurnableToken | contract BurnableToken is BasicToken {
event Burn(address indexed burner, uint256 value);
/**
* @dev Burns a specific amount of tokens.
* @param _value The amount of token to be burned.
*/
function burn(uint256 _value) public {
_burn(msg.sender, _value);
}
function _burn(address _who, uint256 _value) int... | /**
* @title Burnable Token
* @dev Token that can be irreversibly burned (destroyed).
*/ | NatSpecMultiLine | burn | function burn(uint256 _value) public {
_burn(msg.sender, _value);
}
| /**
* @dev Burns a specific amount of tokens.
* @param _value The amount of token to be burned.
*/ | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
199,
269
]
} | 7,795 |
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | Pausable | contract Pausable is Ownable {
event Pause();
event Unpause();
bool public paused = false;
/**
* @dev Modifier to make a function callable only when the contract is not paused.
*/
modifier whenNotPaused() {
require(!paused);
_;
}
/**
* @dev Modifier to make a function callable only when the contract... | /**
* @title Pausable
* @dev Base contract which allows children to implement an emergency stop mechanism.
*/ | NatSpecMultiLine | pause | function pause() onlyOwner whenNotPaused public {
paused = true;
emit Pause();
}
| /**
* @dev called by the owner to pause, triggers stopped state
*/ | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
459,
543
]
} | 7,796 |
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | Pausable | contract Pausable is Ownable {
event Pause();
event Unpause();
bool public paused = false;
/**
* @dev Modifier to make a function callable only when the contract is not paused.
*/
modifier whenNotPaused() {
require(!paused);
_;
}
/**
* @dev Modifier to make a function callable only when the contract... | /**
* @title Pausable
* @dev Base contract which allows children to implement an emergency stop mechanism.
*/ | NatSpecMultiLine | unpause | function unpause() onlyOwner whenPaused public {
paused = false;
emit Unpause();
}
| /**
* @dev called by the owner to unpause, returns to normal state
*/ | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
619,
705
]
} | 7,797 |
MedistockPayCoin | MedistockPayCoin.sol | 0x030f973bf5783cba771354f7e6f794f348c5f06c | Solidity | FreezableMintableToken | contract FreezableMintableToken is FreezableToken, MintableToken {
/**
* @dev Mint the specified amount of token to the specified address and freeze it until the specified date.
* Be careful, gas usage is not deterministic,
* and depends on how many freezes _to address already has.
* @param _to Address to which to... | mintAndFreeze | function mintAndFreeze(address _to, uint _amount, uint64 _until) public onlyOwner canMint returns (bool) {
totalSupply_ = totalSupply_.add(_amount);
bytes32 currentKey = toKey(_to, _until);
freezings[currentKey] = freezings[currentKey].add(_amount);
freezingBalance[_to] = freezingBalance[_to].add(_amount);
fre... | /**
* @dev Mint the specified amount of token to the specified address and freeze it until the specified date.
* Be careful, gas usage is not deterministic,
* and depends on how many freezes _to address already has.
* @param _to Address to which token will be freeze.
* @param _amount Amount of token to mint a... | NatSpecMultiLine | v0.4.26+commit.4563c3fc | MIT | bzzr://c7f22b1212324b47015fdfbcf83067298a9d8e1f685d6a6a5e0a9872521c7094 | {
"func_code_index": [
518,
978
]
} | 7,798 | ||
kanekiinu | kanekiinu.sol | 0xac720c675fba115ac6ac4c9dd67dc64a1d089d26 | 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.8.9+commit.e5eed63a | None | ipfs://6679f25f690c92432b307e316ce3662c35078a3b53ce19ddb13dc9845cfa37af | {
"func_code_index": [
92,
152
]
} | 7,799 |
kanekiinu | kanekiinu.sol | 0xac720c675fba115ac6ac4c9dd67dc64a1d089d26 | 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.8.9+commit.e5eed63a | None | ipfs://6679f25f690c92432b307e316ce3662c35078a3b53ce19ddb13dc9845cfa37af | {
"func_code_index": [
233,
306
]
} | 7,800 |
kanekiinu | kanekiinu.sol | 0xac720c675fba115ac6ac4c9dd67dc64a1d089d26 | 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.8.9+commit.e5eed63a | None | ipfs://6679f25f690c92432b307e316ce3662c35078a3b53ce19ddb13dc9845cfa37af | {
"func_code_index": [
524,
606
]
} | 7,801 |
kanekiinu | kanekiinu.sol | 0xac720c675fba115ac6ac4c9dd67dc64a1d089d26 | 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.8.9+commit.e5eed63a | None | ipfs://6679f25f690c92432b307e316ce3662c35078a3b53ce19ddb13dc9845cfa37af | {
"func_code_index": [
879,
967
]
} | 7,802 |
kanekiinu | kanekiinu.sol | 0xac720c675fba115ac6ac4c9dd67dc64a1d089d26 | 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.8.9+commit.e5eed63a | None | ipfs://6679f25f690c92432b307e316ce3662c35078a3b53ce19ddb13dc9845cfa37af | {
"func_code_index": [
1618,
1697
]
} | 7,803 |
kanekiinu | kanekiinu.sol | 0xac720c675fba115ac6ac4c9dd67dc64a1d089d26 | 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.8.9+commit.e5eed63a | None | ipfs://6679f25f690c92432b307e316ce3662c35078a3b53ce19ddb13dc9845cfa37af | {
"func_code_index": [
2002,
2104
]
} | 7,804 |
kanekiinu | kanekiinu.sol | 0xac720c675fba115ac6ac4c9dd67dc64a1d089d26 | Solidity | SafeMath | library SafeMath {
/**
* @dev Returns the addition of two unsigned integers, with an overflow flag.
*
* _Available since v3.4._
*/
function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) {
unchecked {
uint256 c = a + b;
if (c < a) retu... | /**
* @dev Wrappers over Solidity's arithmetic operations.
*
* NOTE: `SafeMath` is no longer needed starting with Solidity 0.8. The compiler
* now has built in overflow checking.
*/ | NatSpecMultiLine | tryAdd | function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) {
unchecked {
uint256 c = a + b;
if (c < a) return (false, 0);
return (true, c);
}
}
| /**
* @dev Returns the addition of two unsigned integers, with an overflow flag.
*
* _Available since v3.4._
*/ | NatSpecMultiLine | v0.8.9+commit.e5eed63a | None | ipfs://6679f25f690c92432b307e316ce3662c35078a3b53ce19ddb13dc9845cfa37af | {
"func_code_index": [
157,
384
]
} | 7,805 |
kanekiinu | kanekiinu.sol | 0xac720c675fba115ac6ac4c9dd67dc64a1d089d26 | Solidity | SafeMath | library SafeMath {
/**
* @dev Returns the addition of two unsigned integers, with an overflow flag.
*
* _Available since v3.4._
*/
function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) {
unchecked {
uint256 c = a + b;
if (c < a) retu... | /**
* @dev Wrappers over Solidity's arithmetic operations.
*
* NOTE: `SafeMath` is no longer needed starting with Solidity 0.8. The compiler
* now has built in overflow checking.
*/ | NatSpecMultiLine | trySub | function trySub(uint256 a, uint256 b) internal pure returns (bool, uint256) {
unchecked {
if (b > a) return (false, 0);
return (true, a - b);
}
}
| /**
* @dev Returns the substraction of two unsigned integers, with an overflow flag.
*
* _Available since v3.4._
*/ | NatSpecMultiLine | v0.8.9+commit.e5eed63a | None | ipfs://6679f25f690c92432b307e316ce3662c35078a3b53ce19ddb13dc9845cfa37af | {
"func_code_index": [
528,
727
]
} | 7,806 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.