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
PPTokenCrowdsale
PPTokenCrowdsale.sol
0x0746c91dd2d0d657b41f4411bd5535608755278f
Solidity
Crowdsale
contract Crowdsale { using SafeMath for uint256; // The token being sold PPToken public token; // Address where funds are collected address public wallet; // How many token units a buyer gets per wei uint256 public rate; // Amount of wei raised uint256 public weiRaised; /** *...
//-----------------------------------------
LineComment
_getTokenAmount
function _getTokenAmount(uint256 _weiAmount) internal returns (uint256) { uint256 tokens = _weiAmount.mul(rate); return tokens; }
/** * @dev Override to extend the way in which ether is converted to tokens. * @param _weiAmount Value in wei to be converted into tokens * @return Number of tokens that can be purchased with the specified _weiAmount */
NatSpecMultiLine
v0.4.21+commit.dfe3193c
bzzr://c70a7d4c7f89cb64759335d8b61cf47abf42d28682d7a2a4fb7a0a808b4083be
{ "func_code_index": [ 4361, 4513 ] }
24,700
PPTokenCrowdsale
PPTokenCrowdsale.sol
0x0746c91dd2d0d657b41f4411bd5535608755278f
Solidity
Crowdsale
contract Crowdsale { using SafeMath for uint256; // The token being sold PPToken public token; // Address where funds are collected address public wallet; // How many token units a buyer gets per wei uint256 public rate; // Amount of wei raised uint256 public weiRaised; /** *...
//-----------------------------------------
LineComment
_forwardFunds
function _forwardFunds() internal { wallet.transfer(msg.value); }
/** * @dev Determines how ETH is stored/forwarded on purchases. */
NatSpecMultiLine
v0.4.21+commit.dfe3193c
bzzr://c70a7d4c7f89cb64759335d8b61cf47abf42d28682d7a2a4fb7a0a808b4083be
{ "func_code_index": [ 4592, 4668 ] }
24,701
PPTokenCrowdsale
PPTokenCrowdsale.sol
0x0746c91dd2d0d657b41f4411bd5535608755278f
Solidity
AllowanceCrowdsale
contract AllowanceCrowdsale is Crowdsale { using SafeMath for uint256; address public tokenWallet; /** * @dev Constructor, takes token wallet address. * @param _tokenWallet Address holding the tokens, which has approved allowance to the crowdsale */ function AllowanceCrowdsale(address _toke...
AllowanceCrowdsale
function AllowanceCrowdsale(address _tokenWallet) public { require(_tokenWallet != address(0)); tokenWallet = _tokenWallet; }
/** * @dev Constructor, takes token wallet address. * @param _tokenWallet Address holding the tokens, which has approved allowance to the crowdsale */
NatSpecMultiLine
v0.4.21+commit.dfe3193c
bzzr://c70a7d4c7f89cb64759335d8b61cf47abf42d28682d7a2a4fb7a0a808b4083be
{ "func_code_index": [ 277, 418 ] }
24,702
PPTokenCrowdsale
PPTokenCrowdsale.sol
0x0746c91dd2d0d657b41f4411bd5535608755278f
Solidity
AllowanceCrowdsale
contract AllowanceCrowdsale is Crowdsale { using SafeMath for uint256; address public tokenWallet; /** * @dev Constructor, takes token wallet address. * @param _tokenWallet Address holding the tokens, which has approved allowance to the crowdsale */ function AllowanceCrowdsale(address _toke...
remainingTokens
function remainingTokens() public view returns (uint256) { return token.balanceOf(tokenWallet); }
/** * @dev Checks the amount of tokens left in the allowance. * @return Amount of tokens left in the allowance */
NatSpecMultiLine
v0.4.21+commit.dfe3193c
bzzr://c70a7d4c7f89cb64759335d8b61cf47abf42d28682d7a2a4fb7a0a808b4083be
{ "func_code_index": [ 550, 658 ] }
24,703
PPTokenCrowdsale
PPTokenCrowdsale.sol
0x0746c91dd2d0d657b41f4411bd5535608755278f
Solidity
AllowanceCrowdsale
contract AllowanceCrowdsale is Crowdsale { using SafeMath for uint256; address public tokenWallet; /** * @dev Constructor, takes token wallet address. * @param _tokenWallet Address holding the tokens, which has approved allowance to the crowdsale */ function AllowanceCrowdsale(address _toke...
_deliverTokens
function _deliverTokens(address _beneficiary, uint256 _tokenAmount) internal { token.saleTokens(_beneficiary, _tokenAmount); }
/** * @dev Overrides parent behavior by transferring tokens from wallet. * @param _beneficiary Token purchaser * @param _tokenAmount Amount of tokens purchased */
NatSpecMultiLine
v0.4.21+commit.dfe3193c
bzzr://c70a7d4c7f89cb64759335d8b61cf47abf42d28682d7a2a4fb7a0a808b4083be
{ "func_code_index": [ 843, 980 ] }
24,704
PPTokenCrowdsale
PPTokenCrowdsale.sol
0x0746c91dd2d0d657b41f4411bd5535608755278f
Solidity
CappedCrowdsale
contract CappedCrowdsale is Crowdsale { using SafeMath for uint256; uint256 public cap; /** * @dev Constructor, takes maximum amount of wei accepted in the crowdsale. * @param _cap Max amount of wei to be contributed */ function CappedCrowdsale(uint256 _cap) public { require(_cap > ...
CappedCrowdsale
function CappedCrowdsale(uint256 _cap) public { require(_cap > 0); cap = _cap; }
/** * @dev Constructor, takes maximum amount of wei accepted in the crowdsale. * @param _cap Max amount of wei to be contributed */
NatSpecMultiLine
v0.4.21+commit.dfe3193c
bzzr://c70a7d4c7f89cb64759335d8b61cf47abf42d28682d7a2a4fb7a0a808b4083be
{ "func_code_index": [ 250, 346 ] }
24,705
PPTokenCrowdsale
PPTokenCrowdsale.sol
0x0746c91dd2d0d657b41f4411bd5535608755278f
Solidity
CappedCrowdsale
contract CappedCrowdsale is Crowdsale { using SafeMath for uint256; uint256 public cap; /** * @dev Constructor, takes maximum amount of wei accepted in the crowdsale. * @param _cap Max amount of wei to be contributed */ function CappedCrowdsale(uint256 _cap) public { require(_cap > ...
capReached
function capReached() public view returns (bool) { return weiRaised >= cap; }
/** * @dev Checks whether the cap has been reached. * @return Whether the cap was reached */
NatSpecMultiLine
v0.4.21+commit.dfe3193c
bzzr://c70a7d4c7f89cb64759335d8b61cf47abf42d28682d7a2a4fb7a0a808b4083be
{ "func_code_index": [ 458, 546 ] }
24,706
PPTokenCrowdsale
PPTokenCrowdsale.sol
0x0746c91dd2d0d657b41f4411bd5535608755278f
Solidity
CappedCrowdsale
contract CappedCrowdsale is Crowdsale { using SafeMath for uint256; uint256 public cap; /** * @dev Constructor, takes maximum amount of wei accepted in the crowdsale. * @param _cap Max amount of wei to be contributed */ function CappedCrowdsale(uint256 _cap) public { require(_cap > ...
_preValidatePurchase
function _preValidatePurchase(address _beneficiary, uint256 _weiAmount) internal { super._preValidatePurchase(_beneficiary, _weiAmount); require(_beneficiary != address(0)); require(_weiAmount != 0); //require(!capReached()); require(weiRaised.add(_weiAmount) <= cap); }
/** * @dev Extend parent behavior requiring purchase to respect the funding cap. * @param _beneficiary Token purchaser * @param _weiAmount Amount of wei contributed */
NatSpecMultiLine
v0.4.21+commit.dfe3193c
bzzr://c70a7d4c7f89cb64759335d8b61cf47abf42d28682d7a2a4fb7a0a808b4083be
{ "func_code_index": [ 736, 1037 ] }
24,707
PPTokenCrowdsale
PPTokenCrowdsale.sol
0x0746c91dd2d0d657b41f4411bd5535608755278f
Solidity
TimedCrowdsale
contract TimedCrowdsale is Crowdsale { using SafeMath for uint256; uint256 public openingTime; uint256 public closingTime; /** * @dev Reverts if not in crowdsale time range. */ modifier onlyWhileOpen { require(now >= openingTime && now <= closingTime); _; } /** * @dev C...
TimedCrowdsale
function TimedCrowdsale(uint256 _openingTime, uint256 _closingTime) public { require(_openingTime >= now); require(_closingTime >= _openingTime); openingTime = _openingTime; closingTime = _closingTime; }
/** * @dev Constructor, takes crowdsale opening and closing times. * @param _openingTime Crowdsale opening time * @param _closingTime Crowdsale closing time */
NatSpecMultiLine
v0.4.21+commit.dfe3193c
bzzr://c70a7d4c7f89cb64759335d8b61cf47abf42d28682d7a2a4fb7a0a808b4083be
{ "func_code_index": [ 481, 712 ] }
24,708
PPTokenCrowdsale
PPTokenCrowdsale.sol
0x0746c91dd2d0d657b41f4411bd5535608755278f
Solidity
TimedCrowdsale
contract TimedCrowdsale is Crowdsale { using SafeMath for uint256; uint256 public openingTime; uint256 public closingTime; /** * @dev Reverts if not in crowdsale time range. */ modifier onlyWhileOpen { require(now >= openingTime && now <= closingTime); _; } /** * @dev C...
hasClosed
function hasClosed() public view returns (bool) { return now > closingTime; }
/** * @dev Checks whether the period in which the crowdsale is open has already elapsed. * @return Whether crowdsale period has elapsed */
NatSpecMultiLine
v0.4.21+commit.dfe3193c
bzzr://c70a7d4c7f89cb64759335d8b61cf47abf42d28682d7a2a4fb7a0a808b4083be
{ "func_code_index": [ 869, 957 ] }
24,709
PPTokenCrowdsale
PPTokenCrowdsale.sol
0x0746c91dd2d0d657b41f4411bd5535608755278f
Solidity
TimedCrowdsale
contract TimedCrowdsale is Crowdsale { using SafeMath for uint256; uint256 public openingTime; uint256 public closingTime; /** * @dev Reverts if not in crowdsale time range. */ modifier onlyWhileOpen { require(now >= openingTime && now <= closingTime); _; } /** * @dev C...
_preValidatePurchase
function _preValidatePurchase(address _beneficiary, uint256 _weiAmount) internal onlyWhileOpen { super._preValidatePurchase(_beneficiary, _weiAmount); }
/** * @dev Extend parent behavior requiring to be within contributing period * @param _beneficiary Token purchaser * @param _weiAmount Amount of wei contributed */
NatSpecMultiLine
v0.4.21+commit.dfe3193c
bzzr://c70a7d4c7f89cb64759335d8b61cf47abf42d28682d7a2a4fb7a0a808b4083be
{ "func_code_index": [ 1145, 1308 ] }
24,710
PPTokenCrowdsale
PPTokenCrowdsale.sol
0x0746c91dd2d0d657b41f4411bd5535608755278f
Solidity
FinalizableCrowdsale
contract FinalizableCrowdsale is TimedCrowdsale, Ownable { using SafeMath for uint256; bool public isFinalized = false; event Finalized(); /** * @dev Must be called after crowdsale ends, to do some extra finalization * work. Calls the contract's finalization function. */ function finali...
finalize
function finalize() onlyOwner public { require(!isFinalized); require(hasClosed()); finalization(); emit Finalized(); isFinalized = true; }
/** * @dev Must be called after crowdsale ends, to do some extra finalization * work. Calls the contract's finalization function. */
NatSpecMultiLine
v0.4.21+commit.dfe3193c
bzzr://c70a7d4c7f89cb64759335d8b61cf47abf42d28682d7a2a4fb7a0a808b4083be
{ "func_code_index": [ 303, 477 ] }
24,711
PPTokenCrowdsale
PPTokenCrowdsale.sol
0x0746c91dd2d0d657b41f4411bd5535608755278f
Solidity
FinalizableCrowdsale
contract FinalizableCrowdsale is TimedCrowdsale, Ownable { using SafeMath for uint256; bool public isFinalized = false; event Finalized(); /** * @dev Must be called after crowdsale ends, to do some extra finalization * work. Calls the contract's finalization function. */ function finali...
finalization
function finalization() internal { }
/** * @dev Can be overridden to add finalization logic. The overriding function * should call super.finalization() to ensure the chain of finalization is * executed entirely. */
NatSpecMultiLine
v0.4.21+commit.dfe3193c
bzzr://c70a7d4c7f89cb64759335d8b61cf47abf42d28682d7a2a4fb7a0a808b4083be
{ "func_code_index": [ 677, 730 ] }
24,712
PPTokenCrowdsale
PPTokenCrowdsale.sol
0x0746c91dd2d0d657b41f4411bd5535608755278f
Solidity
RefundVault
contract RefundVault is Ownable { using SafeMath for uint256; enum State { Active, Refunding, Closed } mapping (address => uint256) public deposited; address public wallet; State public state; event Closed(); event RefundsEnabled(); event Refunded(address indexed beneficiary, uint256 weiAm...
RefundVault
function RefundVault(address _wallet) public { require(_wallet != address(0)); wallet = _wallet; state = State.Active; }
/** * @param _wallet Vault address */
NatSpecMultiLine
v0.4.21+commit.dfe3193c
bzzr://c70a7d4c7f89cb64759335d8b61cf47abf42d28682d7a2a4fb7a0a808b4083be
{ "func_code_index": [ 379, 520 ] }
24,713
PPTokenCrowdsale
PPTokenCrowdsale.sol
0x0746c91dd2d0d657b41f4411bd5535608755278f
Solidity
RefundVault
contract RefundVault is Ownable { using SafeMath for uint256; enum State { Active, Refunding, Closed } mapping (address => uint256) public deposited; address public wallet; State public state; event Closed(); event RefundsEnabled(); event Refunded(address indexed beneficiary, uint256 weiAm...
deposit
function deposit(address investor) onlyOwner public payable { require(state == State.Active); deposited[investor] = deposited[investor].add(msg.value); }
/** * @param investor Investor address */
NatSpecMultiLine
v0.4.21+commit.dfe3193c
bzzr://c70a7d4c7f89cb64759335d8b61cf47abf42d28682d7a2a4fb7a0a808b4083be
{ "func_code_index": [ 576, 745 ] }
24,714
PPTokenCrowdsale
PPTokenCrowdsale.sol
0x0746c91dd2d0d657b41f4411bd5535608755278f
Solidity
RefundVault
contract RefundVault is Ownable { using SafeMath for uint256; enum State { Active, Refunding, Closed } mapping (address => uint256) public deposited; address public wallet; State public state; event Closed(); event RefundsEnabled(); event Refunded(address indexed beneficiary, uint256 weiAm...
refund
function refund(address investor) public { require(state == State.Refunding); uint256 depositedValue = deposited[investor]; deposited[investor] = 0; investor.transfer(depositedValue); emit Refunded(investor, depositedValue); }
/** * @param investor Investor address */
NatSpecMultiLine
v0.4.21+commit.dfe3193c
bzzr://c70a7d4c7f89cb64759335d8b61cf47abf42d28682d7a2a4fb7a0a808b4083be
{ "func_code_index": [ 1389, 1646 ] }
24,715
PPTokenCrowdsale
PPTokenCrowdsale.sol
0x0746c91dd2d0d657b41f4411bd5535608755278f
Solidity
RefundableCrowdsale
contract RefundableCrowdsale is StagebleCrowdsale { using SafeMath for uint256; // minimum amount of funds to be raised in weis uint256 public goal; // refund vault used to hold funds while crowdsale is running RefundVault public vault; address advWallet; uint256 advPercent; bool advIsCa...
RefundableCrowdsale
function RefundableCrowdsale(uint256 _goal, uint256 _advPercent) public { require(_goal > 0); vault = new RefundVault(wallet); goal = _goal; advPercent = _advPercent; }
/** * @dev Constructor, creates RefundVault. * @param _goal Funding goal */
NatSpecMultiLine
v0.4.21+commit.dfe3193c
bzzr://c70a7d4c7f89cb64759335d8b61cf47abf42d28682d7a2a4fb7a0a808b4083be
{ "func_code_index": [ 427, 621 ] }
24,716
PPTokenCrowdsale
PPTokenCrowdsale.sol
0x0746c91dd2d0d657b41f4411bd5535608755278f
Solidity
RefundableCrowdsale
contract RefundableCrowdsale is StagebleCrowdsale { using SafeMath for uint256; // minimum amount of funds to be raised in weis uint256 public goal; // refund vault used to hold funds while crowdsale is running RefundVault public vault; address advWallet; uint256 advPercent; bool advIsCa...
claimRefund
function claimRefund() public { require(isFinalized); require(!goalReached()); vault.refund(msg.sender); }
/** * @dev Investors can claim refunds here if crowdsale is unsuccessful */
NatSpecMultiLine
v0.4.21+commit.dfe3193c
bzzr://c70a7d4c7f89cb64759335d8b61cf47abf42d28682d7a2a4fb7a0a808b4083be
{ "func_code_index": [ 711, 840 ] }
24,717
PPTokenCrowdsale
PPTokenCrowdsale.sol
0x0746c91dd2d0d657b41f4411bd5535608755278f
Solidity
RefundableCrowdsale
contract RefundableCrowdsale is StagebleCrowdsale { using SafeMath for uint256; // minimum amount of funds to be raised in weis uint256 public goal; // refund vault used to hold funds while crowdsale is running RefundVault public vault; address advWallet; uint256 advPercent; bool advIsCa...
goalReached
function goalReached() public view returns (bool) { return weiRaised >= goal; }
/** * @dev Checks whether funding goal was reached. * @return Whether funding goal was reached */
NatSpecMultiLine
v0.4.21+commit.dfe3193c
bzzr://c70a7d4c7f89cb64759335d8b61cf47abf42d28682d7a2a4fb7a0a808b4083be
{ "func_code_index": [ 957, 1047 ] }
24,718
PPTokenCrowdsale
PPTokenCrowdsale.sol
0x0746c91dd2d0d657b41f4411bd5535608755278f
Solidity
RefundableCrowdsale
contract RefundableCrowdsale is StagebleCrowdsale { using SafeMath for uint256; // minimum amount of funds to be raised in weis uint256 public goal; // refund vault used to hold funds while crowdsale is running RefundVault public vault; address advWallet; uint256 advPercent; bool advIsCa...
finalization
function finalization() internal { if (goalReached()) { vault.close(); } else { vault.enableRefunds(); } super.finalization(); }
/** * @dev vault finalization task, called when owner calls finalize() */
NatSpecMultiLine
v0.4.21+commit.dfe3193c
bzzr://c70a7d4c7f89cb64759335d8b61cf47abf42d28682d7a2a4fb7a0a808b4083be
{ "func_code_index": [ 1135, 1307 ] }
24,719
PPTokenCrowdsale
PPTokenCrowdsale.sol
0x0746c91dd2d0d657b41f4411bd5535608755278f
Solidity
RefundableCrowdsale
contract RefundableCrowdsale is StagebleCrowdsale { using SafeMath for uint256; // minimum amount of funds to be raised in weis uint256 public goal; // refund vault used to hold funds while crowdsale is running RefundVault public vault; address advWallet; uint256 advPercent; bool advIsCa...
_forwardFunds
function _forwardFunds() internal { vault.deposit.value(msg.value)(msg.sender); if(!advIsCalc &&_getInStageIndex () > 0 && goalReached() && advWallet != address(0)) { //Send ETH to advisor, after to stage 1 uint256 advAmount = 0; advIsCalc = true; advAmount = weiRaised.mul(advPercen...
/** * @dev Overrides Crowdsale fund forwarding, sending funds to vault. */
NatSpecMultiLine
v0.4.21+commit.dfe3193c
bzzr://c70a7d4c7f89cb64759335d8b61cf47abf42d28682d7a2a4fb7a0a808b4083be
{ "func_code_index": [ 1396, 1810 ] }
24,720
BoringDAO
contracts\BoringDAO.sol
0xe3547ba476907cebe554ab2a1c9f64378fb14f3b
Solidity
BoringDAO
contract BoringDAO is AccessControl, IBoringDAO, Pausable { using SafeDecimalMath for uint256; using SafeMath for uint256; uint256 public amountByMint; bytes32 public constant TRUSTEE_ROLE = "TRUSTEE_ROLE"; bytes32 public constant LIQUIDATION_ROLE = "LIQUIDATION_ROLE"; bytes32 public c...
/** @notice The BoringDAO contract is the entrance to the entire system, providing the functions of pledge BOR, redeem BOR, mint bBTC, and destroy bBTC */
NatSpecMultiLine
pledge
function pledge(bytes32 _tunnelKey, uint256 _amount) public override whenNotPaused whenContractExist(_tunnelKey) { require( borERC20().allowance(msg.sender, address(this)) >= _amount, "not allow enough bor" ); borERC20().transferFrom( msg.sender, ...
/** @notice tunnelKey is byte32("symbol"), eg. bytes32("BTC") */
NatSpecMultiLine
v0.6.12+commit.27d51765
MIT
ipfs://f850227c909763eb34ccf8bce677fd704a359da6ecfcab8d2687941342610f58
{ "func_code_index": [ 3854, 4353 ] }
24,721
BoringDAO
contracts\BoringDAO.sol
0xe3547ba476907cebe554ab2a1c9f64378fb14f3b
Solidity
BoringDAO
contract BoringDAO is AccessControl, IBoringDAO, Pausable { using SafeDecimalMath for uint256; using SafeMath for uint256; uint256 public amountByMint; bytes32 public constant TRUSTEE_ROLE = "TRUSTEE_ROLE"; bytes32 public constant LIQUIDATION_ROLE = "LIQUIDATION_ROLE"; bytes32 public c...
/** @notice The BoringDAO contract is the entrance to the entire system, providing the functions of pledge BOR, redeem BOR, mint bBTC, and destroy bBTC */
NatSpecMultiLine
redeem
function redeem(bytes32 _tunnelKey, uint256 _amount) public override whenNotPaused whenContractExist(_tunnelKey) { tunnel(_tunnelKey).redeem(msg.sender, _amount); }
/** @notice redeem bor from tunnel */
NatSpecMultiLine
v0.6.12+commit.27d51765
MIT
ipfs://f850227c909763eb34ccf8bce677fd704a359da6ecfcab8d2687941342610f58
{ "func_code_index": [ 4410, 4634 ] }
24,722
BoringDAO
contracts\BoringDAO.sol
0xe3547ba476907cebe554ab2a1c9f64378fb14f3b
Solidity
BoringDAO
contract BoringDAO is AccessControl, IBoringDAO, Pausable { using SafeDecimalMath for uint256; using SafeMath for uint256; uint256 public amountByMint; bytes32 public constant TRUSTEE_ROLE = "TRUSTEE_ROLE"; bytes32 public constant LIQUIDATION_ROLE = "LIQUIDATION_ROLE"; bytes32 public c...
/** @notice The BoringDAO contract is the entrance to the entire system, providing the functions of pledge BOR, redeem BOR, mint bBTC, and destroy bBTC */
NatSpecMultiLine
approveMint
function approveMint( bytes32 _tunnelKey, string memory _txid, uint256 _amount, address to, string memory assetAddress ) public override whenNotPaused whenTunnelNotPause(_tunnelKey) onlyTrustee { if(to == address(0)) { if (approveFlag[_txid] == false) { approveFlag[_...
/** @notice trustee will call the function to approve mint bToken @param _txid the transaction id of bitcoin @param _amount the amount to mint, 1BTC = 1bBTC = 1*10**18 weibBTC @param to mint to the address */
NatSpecMultiLine
v0.6.12+commit.27d51765
MIT
ipfs://f850227c909763eb34ccf8bce677fd704a359da6ecfcab8d2687941342610f58
{ "func_code_index": [ 5186, 6927 ] }
24,723
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
supportsInterface
function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { return interfaceId == type(IERC721).interfaceId || interfaceId == type(IERC721Metadata).interfaceId || super.supportsInterface(interfaceId); }
/** * @dev See {IERC165-supportsInterface}. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 1524, 1852 ] }
24,724
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
balanceOf
function balanceOf(address owner) public view virtual override returns (uint256) { require( owner != address(0), "ERC721: balance query for the zero address" ); return _balances[owner]; }
/** * @dev See {IERC721-balanceOf}. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 1911, 2191 ] }
24,725
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
ownerOf
function ownerOf(uint256 tokenId) public view virtual override returns (address) { address owner = _owners[tokenId]; require( owner != address(0), "ERC721: owner query for nonexistent token" ); return owner; }
/** * @dev See {IERC721-ownerOf}. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 2248, 2559 ] }
24,726
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
name
function name() public view virtual override returns (string memory) { return _name; }
/** * @dev See {IERC721Metadata-name}. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 2621, 2726 ] }
24,727
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
symbol
function symbol() public view virtual override returns (string memory) { return _symbol; }
/** * @dev See {IERC721Metadata-symbol}. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 2790, 2899 ] }
24,728
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
tokenURI
function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { require( _exists(tokenId), "ERC721Metadata: URI query for nonexistent token" ); string memory baseURI = _baseURI(); return bytes(baseURI).length > 0 ? string(abi.encodePacked...
/** * @dev See {IERC721Metadata-tokenURI}. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 2965, 3398 ] }
24,729
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_baseURI
function _baseURI() internal view virtual returns (string memory) { return ""; }
/** * @dev Base URI for computing {tokenURI}. Empty by default, can be overriden * in child contracts. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 3530, 3629 ] }
24,730
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
approve
function approve(address to, uint256 tokenId) public virtual override { address owner = ERC721.ownerOf(tokenId); require(to != owner, "ERC721: approval to current owner"); require( _msgSender() == owner || ERC721.isApprovedForAll(owner, _msgSender()), "ERC721: approve caller ...
/** * @dev See {IERC721-approve}. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 3686, 4122 ] }
24,731
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
getApproved
function getApproved(uint256 tokenId) public view virtual override returns (address) { require( _exists(tokenId), "ERC721: approved query for nonexistent token" ); return _tokenApprovals[tokenId]; }
/** * @dev See {IERC721-getApproved}. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 4183, 4476 ] }
24,732
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
setApprovalForAll
function setApprovalForAll(address operator, bool approved) public virtual override { require(operator != _msgSender(), "ERC721: approve to caller"); _operatorApprovals[_msgSender()][operator] = approved; emit ApprovalForAll(_msgSender(), operator, approved); }
/** * @dev See {IERC721-setApprovalForAll}. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 4543, 4863 ] }
24,733
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
isApprovedForAll
function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { return _operatorApprovals[owner][operator]; }
/** * @dev See {IERC721-isApprovedForAll}. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 4929, 5128 ] }
24,734
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
transferFrom
function transferFrom( address from, address to, uint256 tokenId ) public virtual override { //solhint-disable-next-line max-line-length require( _isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved" ); _transfer(from, to, ...
/** * @dev See {IERC721-transferFrom}. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 5190, 5571 ] }
24,735
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
safeTransferFrom
function safeTransferFrom( address from, address to, uint256 tokenId ) public virtual override { safeTransferFrom(from, to, tokenId, ""); }
/** * @dev See {IERC721-safeTransferFrom}. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 5637, 5827 ] }
24,736
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
safeTransferFrom
function safeTransferFrom( address from, address to, uint256 tokenId, bytes memory _data ) public virtual override { require( _isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved" ); _safeTransfer(from, to, tokenId, _data); ...
/** * @dev See {IERC721-safeTransferFrom}. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 5893, 6263 ] }
24,737
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_safeTransfer
function _safeTransfer( address from, address to, uint256 tokenId, bytes memory _data ) internal virtual { _transfer(from, to, tokenId); require( _checkOnERC721Received(from, to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer" ); }
/** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * `_data` is additional data, it has no specified format and it is sent in call to `to`. * * This internal function is eq...
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 7140, 7497 ] }
24,738
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_exists
function _exists(uint256 tokenId) internal view virtual returns (bool) { return _owners[tokenId] != address(0); }
/** * @dev Returns whether `tokenId` exists. * * Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}. * * Tokens start existing when they are minted (`_mint`), * and stop existing when they are burned (`_burn`). */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 7805, 7937 ] }
24,739
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_isApprovedOrOwner
function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) { require( _exists(tokenId), "ERC721: operator query for nonexistent token" ); address owner = ERC721.ownerOf(tokenId); return (spender == owner || getApproved(tokenId) == s...
/** * @dev Returns whether `spender` is allowed to manage `tokenId`. * * Requirements: * * - `tokenId` must exist. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 8099, 8539 ] }
24,740
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_safeMint
function _safeMint(address to, uint256 tokenId) internal virtual { _safeMint(to, tokenId, ""); }
/** * @dev Safely mints `tokenId` and transfers it to `to`. * * Requirements: * * - `tokenId` must not exist. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 8876, 8991 ] }
24,741
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_safeMint
function _safeMint( address to, uint256 tokenId, bytes memory _data ) internal virtual { _mint(to, tokenId); require( _checkOnERC721Received(address(0), to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer" ); }
/** * @dev Same as {xref-ERC721-_safeMint-address-uint256-}[`_safeMint`], with an additional `data` parameter which is * forwarded in {IERC721Receiver-onERC721Received} to contract recipients. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 9213, 9539 ] }
24,742
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_mint
function _mint(address to, uint256 tokenId) internal virtual { require(to != address(0), "ERC721: mint to the zero address"); require(!_exists(tokenId), "ERC721: token already minted"); _beforeTokenTransfer(address(0), to, tokenId); _balances[to] += 1; _owners[tokenId] = to; emit Tra...
/** * @dev Mints `tokenId` and transfers it to `to`. * * WARNING: Usage of this method is discouraged, use {_safeMint} whenever possible * * Requirements: * * - `tokenId` must not exist. * - `to` cannot be the zero address. * * Emits a {Transfer} event. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 9870, 10257 ] }
24,743
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_burn
function _burn(uint256 tokenId) internal virtual { address owner = ERC721.ownerOf(tokenId); _beforeTokenTransfer(owner, address(0), tokenId); // Clear approvals _approve(address(0), tokenId); _balances[owner] -= 1; delete _owners[tokenId]; emit Transfer(owner, address(0), toke...
/** * @dev Destroys `tokenId`. * The approval is cleared when the token is burned. * * Requirements: * * - `tokenId` must exist. * * Emits a {Transfer} event. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 11013, 11378 ] }
24,744
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_transfer
function _transfer( address from, address to, uint256 tokenId ) internal virtual { require( ERC721.ownerOf(tokenId) == from, "ERC721: transfer of token that is not own" ); require(to != address(0), "ERC721: transfer to the zero address"); _beforeTokenTransfer(from...
/** * @dev Transfers `tokenId` from `from` to `to`. * As opposed to {transferFrom}, this imposes no restrictions on msg.sender. * * Requirements: * * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * * Emits a {Transfer} event. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 11710, 12330 ] }
24,745
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_approve
function _approve(address to, uint256 tokenId) internal virtual { _tokenApprovals[tokenId] = to; emit Approval(ERC721.ownerOf(tokenId), to, tokenId); }
/** * @dev Approve `to` to operate on `tokenId` * * Emits a {Approval} event. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 12443, 12622 ] }
24,746
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_checkOnERC721Received
function _checkOnERC721Received( address from, address to, uint256 tokenId, bytes memory _data ) private returns (bool) { if (to.isContract()) { try IERC721Receiver(to).onERC721Received( _msgSender(), from, tokenId, _data ...
/** * @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target address. * The call is not executed if the target address is not a contract. * * @param from address representing the previous owner of the given token ID * @param to target address that will receive the tokens * @param to...
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 13182, 14212 ] }
24,747
PreCubeCoin
contracts/ERC721.sol
0x26a65227be0973f455945d7f89a7a539b059bf78
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, Ownable { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) in...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_beforeTokenTransfer
function _beforeTokenTransfer( address from, address to, uint256 tokenId ) internal virtual {}
/** * @dev Hook that is called before any token transfer. This includes minting * and burning. * * Calling conditions: * * - When `from` and `to` are both non-zero, ``from``'s `tokenId` will be * transferred to `to`. * - When `from` is zero, `tokenId` will be minted for `to`. * - When `to` is zero, ``...
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://134ad9259b7e3fb9b5582c316e706337f649f1d3bff6dd6ac5a664e77c90b0cd
{ "func_code_index": [ 14820, 14951 ] }
24,748
TheFloridaManNFT
@openzeppelin/contracts/access/Ownable.sol
0xf3df37a985abf378a7072f411139fb428c08a813
Solidity
Ownable
abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor() { _setOwner(_msgSender()); ...
/** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. ...
NatSpecMultiLine
owner
function owner() public view virtual returns (address) { return _owner; }
/** * @dev Returns the address of the current owner. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
MIT
ipfs://21fc04c22e4e9662f75f65ceb47fc5627a3bdf3b9c0a607cac80c998457f95ff
{ "func_code_index": [ 399, 491 ] }
24,749
TheFloridaManNFT
@openzeppelin/contracts/access/Ownable.sol
0xf3df37a985abf378a7072f411139fb428c08a813
Solidity
Ownable
abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor() { _setOwner(_msgSender()); ...
/** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. ...
NatSpecMultiLine
renounceOwnership
function renounceOwnership() public virtual onlyOwner { _setOwner(address(0)); }
/** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
MIT
ipfs://21fc04c22e4e9662f75f65ceb47fc5627a3bdf3b9c0a607cac80c998457f95ff
{ "func_code_index": [ 1050, 1149 ] }
24,750
TheFloridaManNFT
@openzeppelin/contracts/access/Ownable.sol
0xf3df37a985abf378a7072f411139fb428c08a813
Solidity
Ownable
abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor() { _setOwner(_msgSender()); ...
/** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. ...
NatSpecMultiLine
transferOwnership
function transferOwnership(address newOwner) public virtual onlyOwner { require(newOwner != address(0), "Ownable: new owner is the zero address"); _setOwner(newOwner); }
/** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */
NatSpecMultiLine
v0.8.7+commit.e28d00a7
MIT
ipfs://21fc04c22e4e9662f75f65ceb47fc5627a3bdf3b9c0a607cac80c998457f95ff
{ "func_code_index": [ 1299, 1496 ] }
24,751
TheFloridaManNFT
@openzeppelin/contracts/access/Ownable.sol
0xf3df37a985abf378a7072f411139fb428c08a813
Solidity
TheFloridaManNFT
contract TheFloridaManNFT is ERC721Enumerable, Ownable { using Strings for uint256; string baseURI; string public baseExtension = ".json"; uint256 public cost = 0.09 ether; uint256 public maxSupply = 5000; uint256 public maxMintAmount = 5; bool public paused = false; bool public revealed = fal...
_baseURI
function _baseURI() internal view virtual override returns (string memory) { return baseURI; }
// internal
LineComment
v0.8.7+commit.e28d00a7
MIT
ipfs://21fc04c22e4e9662f75f65ceb47fc5627a3bdf3b9c0a607cac80c998457f95ff
{ "func_code_index": [ 630, 735 ] }
24,752
TheFloridaManNFT
@openzeppelin/contracts/access/Ownable.sol
0xf3df37a985abf378a7072f411139fb428c08a813
Solidity
TheFloridaManNFT
contract TheFloridaManNFT is ERC721Enumerable, Ownable { using Strings for uint256; string baseURI; string public baseExtension = ".json"; uint256 public cost = 0.09 ether; uint256 public maxSupply = 5000; uint256 public maxMintAmount = 5; bool public paused = false; bool public revealed = fal...
mint
function mint(uint256 _mintAmount) public payable { uint256 supply = totalSupply(); require(!paused); require(_mintAmount > 0); require(_mintAmount <= maxMintAmount); require(supply + _mintAmount <= maxSupply); if (msg.sender != owner()) { require(msg.value >= cost * _mintAmount); } for...
// public
LineComment
v0.8.7+commit.e28d00a7
MIT
ipfs://21fc04c22e4e9662f75f65ceb47fc5627a3bdf3b9c0a607cac80c998457f95ff
{ "func_code_index": [ 751, 1187 ] }
24,753
TheFloridaManNFT
@openzeppelin/contracts/access/Ownable.sol
0xf3df37a985abf378a7072f411139fb428c08a813
Solidity
TheFloridaManNFT
contract TheFloridaManNFT is ERC721Enumerable, Ownable { using Strings for uint256; string baseURI; string public baseExtension = ".json"; uint256 public cost = 0.09 ether; uint256 public maxSupply = 5000; uint256 public maxMintAmount = 5; bool public paused = false; bool public revealed = fal...
reveal
function reveal() public onlyOwner { revealed = true; }
//only owner
LineComment
v0.8.7+commit.e28d00a7
MIT
ipfs://21fc04c22e4e9662f75f65ceb47fc5627a3bdf3b9c0a607cac80c998457f95ff
{ "func_code_index": [ 2063, 2131 ] }
24,754
Congress
Congress.sol
0xd60a7176ea2f52e730f97f10769cea5f26028bef
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. // See: https://git...
/** * @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. // See: https://github.com/OpenZeppelin/openzeppelin-solidity/pull/522 if (_a == 0) { return 0; } c ...
/** * @dev Multiplies two numbers, throws on overflow. */
NatSpecMultiLine
v0.4.25+commit.59dbf8f1
bzzr://801b98dc0e27a65710d87ad6a1eda23825e519861d1a244bbfac479c38856536
{ "func_code_index": [ 89, 483 ] }
24,755
Congress
Congress.sol
0xd60a7176ea2f52e730f97f10769cea5f26028bef
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. // See: https://git...
/** * @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.25+commit.59dbf8f1
bzzr://801b98dc0e27a65710d87ad6a1eda23825e519861d1a244bbfac479c38856536
{ "func_code_index": [ 567, 858 ] }
24,756
Congress
Congress.sol
0xd60a7176ea2f52e730f97f10769cea5f26028bef
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. // See: https://git...
/** * @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.25+commit.59dbf8f1
bzzr://801b98dc0e27a65710d87ad6a1eda23825e519861d1a244bbfac479c38856536
{ "func_code_index": [ 972, 1094 ] }
24,757
Congress
Congress.sol
0xd60a7176ea2f52e730f97f10769cea5f26028bef
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. // See: https://git...
/** * @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.25+commit.59dbf8f1
bzzr://801b98dc0e27a65710d87ad6a1eda23825e519861d1a244bbfac479c38856536
{ "func_code_index": [ 1158, 1293 ] }
24,758
Congress
Congress.sol
0xd60a7176ea2f52e730f97f10769cea5f26028bef
Solidity
Congress
contract Congress { using SafeMath for uint256; // the number of active voters uint public voters; // given address is the voter or not mapping(address => bool) public voter; // Each proposal is stored in mapping by its hash (hash of mint arguments) mapping(bytes32 => MintProposal) public mintP...
/** * @title Congress contract * @dev The Congress contract allows to execute certain actions (token minting in this case) via majority of votes. * In contrast to traditional Ownable pattern, Congress protects the managed contract (token) against unfair behaviour * of minority (for example, a single founder hav...
NatSpecMultiLine
isMajority
function isMajority(uint256 votes) public view returns (bool) { return (votes >= voters.div(2).add(1)); }
/** * @dev Determine does the given number of votes make majority of voters. * @return true if given number is majority */
NatSpecMultiLine
v0.4.25+commit.59dbf8f1
bzzr://801b98dc0e27a65710d87ad6a1eda23825e519861d1a244bbfac479c38856536
{ "func_code_index": [ 2258, 2374 ] }
24,759
Congress
Congress.sol
0xd60a7176ea2f52e730f97f10769cea5f26028bef
Solidity
Congress
contract Congress { using SafeMath for uint256; // the number of active voters uint public voters; // given address is the voter or not mapping(address => bool) public voter; // Each proposal is stored in mapping by its hash (hash of mint arguments) mapping(bytes32 => MintProposal) public mintP...
/** * @title Congress contract * @dev The Congress contract allows to execute certain actions (token minting in this case) via majority of votes. * In contrast to traditional Ownable pattern, Congress protects the managed contract (token) against unfair behaviour * of minority (for example, a single founder hav...
NatSpecMultiLine
getTotalTrust
function getTotalTrust(address subject) public view returns (uint256) { return (trustRegistry[subject].totalTrust); }
/** * @dev Determine how many voters trust given address * @param subject The address of trustee * @return the number of trusted votes */
NatSpecMultiLine
v0.4.25+commit.59dbf8f1
bzzr://801b98dc0e27a65710d87ad6a1eda23825e519861d1a244bbfac479c38856536
{ "func_code_index": [ 2534, 2662 ] }
24,760
Congress
Congress.sol
0xd60a7176ea2f52e730f97f10769cea5f26028bef
Solidity
Congress
contract Congress { using SafeMath for uint256; // the number of active voters uint public voters; // given address is the voter or not mapping(address => bool) public voter; // Each proposal is stored in mapping by its hash (hash of mint arguments) mapping(bytes32 => MintProposal) public mintP...
/** * @title Congress contract * @dev The Congress contract allows to execute certain actions (token minting in this case) via majority of votes. * In contrast to traditional Ownable pattern, Congress protects the managed contract (token) against unfair behaviour * of minority (for example, a single founder hav...
NatSpecMultiLine
trust
function trust(address _subject) public onlyVoters { require(msg.sender != _subject); require(token != MintableTokenStub(0)); if (!trustRegistry[_subject].trustedBy[msg.sender]) { trustRegistry[_subject].trustedBy[msg.sender] = true; trustRegistry[_subject].totalTrust = trustRegistry[_subject].totalT...
/** * @dev Set the trust claim (msg.sender trusts subject) * @param _subject The trusted address */
NatSpecMultiLine
v0.4.25+commit.59dbf8f1
bzzr://801b98dc0e27a65710d87ad6a1eda23825e519861d1a244bbfac479c38856536
{ "func_code_index": [ 2780, 3404 ] }
24,761
Congress
Congress.sol
0xd60a7176ea2f52e730f97f10769cea5f26028bef
Solidity
Congress
contract Congress { using SafeMath for uint256; // the number of active voters uint public voters; // given address is the voter or not mapping(address => bool) public voter; // Each proposal is stored in mapping by its hash (hash of mint arguments) mapping(bytes32 => MintProposal) public mintP...
/** * @title Congress contract * @dev The Congress contract allows to execute certain actions (token minting in this case) via majority of votes. * In contrast to traditional Ownable pattern, Congress protects the managed contract (token) against unfair behaviour * of minority (for example, a single founder hav...
NatSpecMultiLine
untrust
function untrust(address _subject) public onlyVoters { require(token != MintableTokenStub(0)); if (trustRegistry[_subject].trustedBy[msg.sender]) { trustRegistry[_subject].trustedBy[msg.sender] = false; trustRegistry[_subject].totalTrust = trustRegistry[_subject].totalTrust.sub(1); emit TrustUnset(...
/** * @dev Unset the trust claim (msg.sender now reclaims trust from subject) * @param _subject The address of trustee to revoke trust */
NatSpecMultiLine
v0.4.25+commit.59dbf8f1
bzzr://801b98dc0e27a65710d87ad6a1eda23825e519861d1a244bbfac479c38856536
{ "func_code_index": [ 3560, 4177 ] }
24,762
Congress
Congress.sol
0xd60a7176ea2f52e730f97f10769cea5f26028bef
Solidity
Congress
contract Congress { using SafeMath for uint256; // the number of active voters uint public voters; // given address is the voter or not mapping(address => bool) public voter; // Each proposal is stored in mapping by its hash (hash of mint arguments) mapping(bytes32 => MintProposal) public mintP...
/** * @title Congress contract * @dev The Congress contract allows to execute certain actions (token minting in this case) via majority of votes. * In contrast to traditional Ownable pattern, Congress protects the managed contract (token) against unfair behaviour * of minority (for example, a single founder hav...
NatSpecMultiLine
setToken
function setToken( MintableTokenStub _token ) public onlyVoters { require(_token != MintableTokenStub(0)); require(token == MintableTokenStub(0)); token = _token; emit TokenSet(msg.sender, token); }
/** * @dev Token and its governance should be locked to each other. Congress should be set as minter in token * @param _token The address of governed token */
NatSpecMultiLine
v0.4.25+commit.59dbf8f1
bzzr://801b98dc0e27a65710d87ad6a1eda23825e519861d1a244bbfac479c38856536
{ "func_code_index": [ 4354, 4595 ] }
24,763
Congress
Congress.sol
0xd60a7176ea2f52e730f97f10769cea5f26028bef
Solidity
Congress
contract Congress { using SafeMath for uint256; // the number of active voters uint public voters; // given address is the voter or not mapping(address => bool) public voter; // Each proposal is stored in mapping by its hash (hash of mint arguments) mapping(bytes32 => MintProposal) public mintP...
/** * @title Congress contract * @dev The Congress contract allows to execute certain actions (token minting in this case) via majority of votes. * In contrast to traditional Ownable pattern, Congress protects the managed contract (token) against unfair behaviour * of minority (for example, a single founder hav...
NatSpecMultiLine
mint
function mint( address to, uint256 amount, string batchCode ) public onlyVoters returns (bool) { bytes32 proposalHash = keccak256(abi.encodePacked(to, amount, batchCode)); assert(!mintProposal[proposalHash].executed); if (!mintProposal[proposalHash].voted[msg.sender]) { if (mintProposal[prop...
/** * @dev Proxy function to vote and mint tokens * @param to The address that will receive the minted tokens. * @param amount The amount of tokens to mint. * @param batchCode The detailed information on a batch. * @return A boolean that indicates if the operation was successful. */
NatSpecMultiLine
v0.4.25+commit.59dbf8f1
bzzr://801b98dc0e27a65710d87ad6a1eda23825e519861d1a244bbfac479c38856536
{ "func_code_index": [ 4903, 5875 ] }
24,764
INCRToken
INCRToken.sol
0x38b31fd1cfdad00cb348610e16700e07bebaaf6f
Solidity
SafeMath
library SafeMath { /** * @dev Subtracts two numbers, throws on overflow (i.e. if subtrahend is greater than minuend). */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { assert(b <= a); return a - b; } /** * @dev Adds two numbers, throws on overflow. */ funct...
/** * @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.23+commit.124ca40d
None
bzzr://4ce50b344b9585a42aa5eb1e101287046846a6a1ec13b56bc2ab919a03cdeca6
{ "func_code_index": [ 133, 249 ] }
24,765
INCRToken
INCRToken.sol
0x38b31fd1cfdad00cb348610e16700e07bebaaf6f
Solidity
SafeMath
library SafeMath { /** * @dev Subtracts two numbers, throws on overflow (i.e. if subtrahend is greater than minuend). */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { assert(b <= a); return a - b; } /** * @dev Adds two numbers, throws on overflow. */ funct...
/** * @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.23+commit.124ca40d
None
bzzr://4ce50b344b9585a42aa5eb1e101287046846a6a1ec13b56bc2ab919a03cdeca6
{ "func_code_index": [ 313, 443 ] }
24,766
INCRToken
INCRToken.sol
0x38b31fd1cfdad00cb348610e16700e07bebaaf6f
Solidity
BasicToken
contract BasicToken is ERC20Basic { using SafeMath for uint256; mapping(address => uint256) internal balances; uint256 internal totalSupply_; /** * @dev total number of tokens in existence */ function totalSupply() public view returns (uint256) { return totalSupply_; } /** * @...
/** * @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.23+commit.124ca40d
None
bzzr://4ce50b344b9585a42aa5eb1e101287046846a6a1ec13b56bc2ab919a03cdeca6
{ "func_code_index": [ 217, 305 ] }
24,767
INCRToken
INCRToken.sol
0x38b31fd1cfdad00cb348610e16700e07bebaaf6f
Solidity
BasicToken
contract BasicToken is ERC20Basic { using SafeMath for uint256; mapping(address => uint256) internal balances; uint256 internal totalSupply_; /** * @dev total number of tokens in existence */ function totalSupply() public view returns (uint256) { return totalSupply_; } /** * @...
/** * @title Basic token * @dev Basic version of StandardToken, with no allowances. */
NatSpecMultiLine
transfer
function transfer(address _to, uint256 _value) public returns (bool) { 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.23+commit.124ca40d
None
bzzr://4ce50b344b9585a42aa5eb1e101287046846a6a1ec13b56bc2ab919a03cdeca6
{ "func_code_index": [ 463, 762 ] }
24,768
INCRToken
INCRToken.sol
0x38b31fd1cfdad00cb348610e16700e07bebaaf6f
Solidity
BasicToken
contract BasicToken is ERC20Basic { using SafeMath for uint256; mapping(address => uint256) internal balances; uint256 internal totalSupply_; /** * @dev total number of tokens in existence */ function totalSupply() public view returns (uint256) { return totalSupply_; } /** * @...
/** * @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.23+commit.124ca40d
None
bzzr://4ce50b344b9585a42aa5eb1e101287046846a6a1ec13b56bc2ab919a03cdeca6
{ "func_code_index": [ 968, 1072 ] }
24,769
INCRToken
INCRToken.sol
0x38b31fd1cfdad00cb348610e16700e07bebaaf6f
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 transf...
/** * @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(_value <= balances[_from]); require(_value <= allowed[_from][msg.sender]); balances[_from] = balances[_from].sub(_value); balances[_to] = balances[_to].add(_value); allowed[_from][msg.sender] = 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 * @param _value uint256 the amount of tokens to be transferred */
NatSpecMultiLine
v0.4.23+commit.124ca40d
None
bzzr://4ce50b344b9585a42aa5eb1e101287046846a6a1ec13b56bc2ab919a03cdeca6
{ "func_code_index": [ 401, 827 ] }
24,770
INCRToken
INCRToken.sol
0x38b31fd1cfdad00cb348610e16700e07bebaaf6f
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 transf...
/** * @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.23+commit.124ca40d
None
bzzr://4ce50b344b9585a42aa5eb1e101287046846a6a1ec13b56bc2ab919a03cdeca6
{ "func_code_index": [ 1063, 1258 ] }
24,771
INCRToken
INCRToken.sol
0x38b31fd1cfdad00cb348610e16700e07bebaaf6f
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 transf...
/** * @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.23+commit.124ca40d
None
bzzr://4ce50b344b9585a42aa5eb1e101287046846a6a1ec13b56bc2ab919a03cdeca6
{ "func_code_index": [ 1582, 1715 ] }
24,772
XRPN_ERC20
XRPN_ERC20.sol
0xe6d8995334884d716ba15c03acbdd586647ae5bb
Solidity
XRPN_ERC20
contract XRPN_ERC20 { // 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 mapping (addre...
_transfer
function _transfer(address _from, address _to, uint _value) internal { // Prevent transfer to 0x0 address. Use burn() instead require(_to != 0x0); // Check if the sender has enough require(balanceOf[_from] >= _value); // Check for overflows require(balanceOf[_to] + _value >= balanceOf[_to]...
/** * Internal transfer, only can be called by this contract */
NatSpecMultiLine
v0.4.26+commit.4563c3fc
bzzr://c9b6001842235027133a68c6e9a05c0264dda010ef3eb6fbf6a669fd29d0ee8c
{ "func_code_index": [ 1637, 2485 ] }
24,773
XRPN_ERC20
XRPN_ERC20.sol
0xe6d8995334884d716ba15c03acbdd586647ae5bb
Solidity
XRPN_ERC20
contract XRPN_ERC20 { // 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 mapping (addre...
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.4.26+commit.4563c3fc
bzzr://c9b6001842235027133a68c6e9a05c0264dda010ef3eb6fbf6a669fd29d0ee8c
{ "func_code_index": [ 2691, 2848 ] }
24,774
XRPN_ERC20
XRPN_ERC20.sol
0xe6d8995334884d716ba15c03acbdd586647ae5bb
Solidity
XRPN_ERC20
contract XRPN_ERC20 { // 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 mapping (addre...
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` on 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.4.26+commit.4563c3fc
bzzr://c9b6001842235027133a68c6e9a05c0264dda010ef3eb6fbf6a669fd29d0ee8c
{ "func_code_index": [ 3123, 3424 ] }
24,775
XRPN_ERC20
XRPN_ERC20.sol
0xe6d8995334884d716ba15c03acbdd586647ae5bb
Solidity
XRPN_ERC20
contract XRPN_ERC20 { // 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 mapping (addre...
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 on your behalf * * @param _spender The address authorized to spend * @param _value the max amount they can spend */
NatSpecMultiLine
v0.4.26+commit.4563c3fc
bzzr://c9b6001842235027133a68c6e9a05c0264dda010ef3eb6fbf6a669fd29d0ee8c
{ "func_code_index": [ 3688, 3918 ] }
24,776
XRPN_ERC20
XRPN_ERC20.sol
0xe6d8995334884d716ba15c03acbdd586647ae5bb
Solidity
XRPN_ERC20
contract XRPN_ERC20 { // 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 mapping (addre...
approveAndCall
function approveAndCall(address _spender, uint256 _value, bytes _extraData) public returns (bool success) { tokenRecipient spender = tokenRecipient(_spender); if (approve(_spender, _value)) { spender.receiveApproval(msg.sender, _value, this, _extraData); return true; } }
/** * Set allowance for other address and notify * * Allows `_spender` to spend no more than `_value` tokens on 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.4.26+commit.4563c3fc
bzzr://c9b6001842235027133a68c6e9a05c0264dda010ef3eb6fbf6a669fd29d0ee8c
{ "func_code_index": [ 4312, 4664 ] }
24,777
XRPN_ERC20
XRPN_ERC20.sol
0xe6d8995334884d716ba15c03acbdd586647ae5bb
Solidity
XRPN_ERC20
contract XRPN_ERC20 { // 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 mapping (addre...
burn
function burn(uint256 _value) public returns (bool success) { require(balanceOf[msg.sender] >= _value); // Check if the sender has enough balanceOf[msg.sender] -= _value; // Subtract from the sender totalSupply -= _value; // Updates totalSupply emit Burn(msg.sender,...
/** * Destroy tokens * * Remove `_value` tokens from the system irreversibly * * @param _value the amount of money to burn */
NatSpecMultiLine
v0.4.26+commit.4563c3fc
bzzr://c9b6001842235027133a68c6e9a05c0264dda010ef3eb6fbf6a669fd29d0ee8c
{ "func_code_index": [ 4834, 5213 ] }
24,778
XRPN_ERC20
XRPN_ERC20.sol
0xe6d8995334884d716ba15c03acbdd586647ae5bb
Solidity
XRPN_ERC20
contract XRPN_ERC20 { // 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 mapping (addre...
burnFrom
function burnFrom(address _from, uint256 _value) public returns (bool success) { require(balanceOf[_from] >= _value); // Check if the targeted balance is enough require(_value <= allowance[_from][msg.sender]); // Check allowance balanceOf[_from] -= _value; // Sub...
/** * Destroy tokens from other account * * Remove `_value` tokens from the system irreversibly on behalf of `_from`. * * @param _from the address of the sender * @param _value the amount of money to burn */
NatSpecMultiLine
v0.4.26+commit.4563c3fc
bzzr://c9b6001842235027133a68c6e9a05c0264dda010ef3eb6fbf6a669fd29d0ee8c
{ "func_code_index": [ 5471, 6087 ] }
24,779
BYOBToken
@openzeppelin/contracts/access/Ownable.sol
0xf4c4c94070a571be425d2a998b4bbf4a5a8ba5f3
Solidity
Ownable
abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor () { address msgSender = _msgSend...
/** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. ...
NatSpecMultiLine
owner
function owner() public view virtual returns (address) { return _owner; }
/** * @dev Returns the address of the current owner. */
NatSpecMultiLine
v0.8.0+commit.c7dfd78e
Unlicense
ipfs://7bb919d1b61f03c3f1b88f396d1bd3c76aa3e09aef413222fbfd631f5e504aab
{ "func_code_index": [ 497, 589 ] }
24,780
BYOBToken
@openzeppelin/contracts/access/Ownable.sol
0xf4c4c94070a571be425d2a998b4bbf4a5a8ba5f3
Solidity
Ownable
abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor () { address msgSender = _msgSend...
/** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. ...
NatSpecMultiLine
renounceOwnership
function renounceOwnership() public virtual onlyOwner { emit OwnershipTransferred(_owner, address(0)); _owner = address(0); }
/** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */
NatSpecMultiLine
v0.8.0+commit.c7dfd78e
Unlicense
ipfs://7bb919d1b61f03c3f1b88f396d1bd3c76aa3e09aef413222fbfd631f5e504aab
{ "func_code_index": [ 1148, 1301 ] }
24,781
BYOBToken
@openzeppelin/contracts/access/Ownable.sol
0xf4c4c94070a571be425d2a998b4bbf4a5a8ba5f3
Solidity
Ownable
abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor () { address msgSender = _msgSend...
/** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. ...
NatSpecMultiLine
transferOwnership
function transferOwnership(address newOwner) public virtual onlyOwner { require(newOwner != address(0), "Ownable: new owner is the zero address"); emit OwnershipTransferred(_owner, newOwner); _owner = newOwner; }
/** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */
NatSpecMultiLine
v0.8.0+commit.c7dfd78e
Unlicense
ipfs://7bb919d1b61f03c3f1b88f396d1bd3c76aa3e09aef413222fbfd631f5e504aab
{ "func_code_index": [ 1451, 1700 ] }
24,782
NFTArtGenPresale
@openzeppelin/contracts/token/ERC1155/ERC1155.sol
0xce6b30c9ddbfe895bea6f6910673f4a70ac22951
Solidity
ERC1155
contract ERC1155 is Context, ERC165, IERC1155, IERC1155MetadataURI { using Address for address; // Mapping from token ID to account balances mapping(uint256 => mapping(address => uint256)) private _balances; // Mapping from account to operator approvals mapping(address => mapping(address =>...
/** * @dev Implementation of the basic standard multi-token. * See https://eips.ethereum.org/EIPS/eip-1155 * Originally based on code by Enjin: https://github.com/enjin/erc-1155 * * _Available since v3.1._ */
NatSpecMultiLine
supportsInterface
function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { return interfaceId == type(IERC1155).interfaceId || interfaceId == type(IERC1155MetadataURI).interfaceId || super.supportsInterface(interfaceId); }
/** * @dev See {IERC165-supportsInterface}. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://f487e606c495603b45eddf5b72ccee7a2973f63c7b6613caa8a7e0d3b89bf8ec
{ "func_code_index": [ 684, 999 ] }
24,783
NFTArtGenPresale
@openzeppelin/contracts/token/ERC1155/ERC1155.sol
0xce6b30c9ddbfe895bea6f6910673f4a70ac22951
Solidity
ERC1155
contract ERC1155 is Context, ERC165, IERC1155, IERC1155MetadataURI { using Address for address; // Mapping from token ID to account balances mapping(uint256 => mapping(address => uint256)) private _balances; // Mapping from account to operator approvals mapping(address => mapping(address =>...
/** * @dev Implementation of the basic standard multi-token. * See https://eips.ethereum.org/EIPS/eip-1155 * Originally based on code by Enjin: https://github.com/enjin/erc-1155 * * _Available since v3.1._ */
NatSpecMultiLine
uri
function uri(uint256) public view virtual override returns (string memory) { return _uri; }
/** * @dev See {IERC1155MetadataURI-uri}. * * This implementation returns the same URI for *all* token types. It relies * on the token type ID substitution mechanism * https://eips.ethereum.org/EIPS/eip-1155#metadata[defined in the EIP]. * * Clients calling this function must replace the `\{id\}` substrin...
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://f487e606c495603b45eddf5b72ccee7a2973f63c7b6613caa8a7e0d3b89bf8ec
{ "func_code_index": [ 1405, 1515 ] }
24,784
NFTArtGenPresale
@openzeppelin/contracts/token/ERC1155/ERC1155.sol
0xce6b30c9ddbfe895bea6f6910673f4a70ac22951
Solidity
ERC1155
contract ERC1155 is Context, ERC165, IERC1155, IERC1155MetadataURI { using Address for address; // Mapping from token ID to account balances mapping(uint256 => mapping(address => uint256)) private _balances; // Mapping from account to operator approvals mapping(address => mapping(address =>...
/** * @dev Implementation of the basic standard multi-token. * See https://eips.ethereum.org/EIPS/eip-1155 * Originally based on code by Enjin: https://github.com/enjin/erc-1155 * * _Available since v3.1._ */
NatSpecMultiLine
balanceOf
function balanceOf(address account, uint256 id) public view virtual override returns (uint256) { require(account != address(0), "ERC1155: balance query for the zero address"); return _balances[id][account]; }
/** * @dev See {IERC1155-balanceOf}. * * Requirements: * * - `account` cannot be the zero address. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://f487e606c495603b45eddf5b72ccee7a2973f63c7b6613caa8a7e0d3b89bf8ec
{ "func_code_index": [ 1661, 1897 ] }
24,785
NFTArtGenPresale
@openzeppelin/contracts/token/ERC1155/ERC1155.sol
0xce6b30c9ddbfe895bea6f6910673f4a70ac22951
Solidity
ERC1155
contract ERC1155 is Context, ERC165, IERC1155, IERC1155MetadataURI { using Address for address; // Mapping from token ID to account balances mapping(uint256 => mapping(address => uint256)) private _balances; // Mapping from account to operator approvals mapping(address => mapping(address =>...
/** * @dev Implementation of the basic standard multi-token. * See https://eips.ethereum.org/EIPS/eip-1155 * Originally based on code by Enjin: https://github.com/enjin/erc-1155 * * _Available since v3.1._ */
NatSpecMultiLine
balanceOfBatch
function balanceOfBatch(address[] memory accounts, uint256[] memory ids) public view virtual override returns (uint256[] memory) { require(accounts.length == ids.length, "ERC1155: accounts and ids length mismatch"); uint256[] memory batchBalances = new uint256[](accounts.length); ...
/** * @dev See {IERC1155-balanceOfBatch}. * * Requirements: * * - `accounts` and `ids` must have the same length. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://f487e606c495603b45eddf5b72ccee7a2973f63c7b6613caa8a7e0d3b89bf8ec
{ "func_code_index": [ 2058, 2587 ] }
24,786
NFTArtGenPresale
@openzeppelin/contracts/token/ERC1155/ERC1155.sol
0xce6b30c9ddbfe895bea6f6910673f4a70ac22951
Solidity
ERC1155
contract ERC1155 is Context, ERC165, IERC1155, IERC1155MetadataURI { using Address for address; // Mapping from token ID to account balances mapping(uint256 => mapping(address => uint256)) private _balances; // Mapping from account to operator approvals mapping(address => mapping(address =>...
/** * @dev Implementation of the basic standard multi-token. * See https://eips.ethereum.org/EIPS/eip-1155 * Originally based on code by Enjin: https://github.com/enjin/erc-1155 * * _Available since v3.1._ */
NatSpecMultiLine
setApprovalForAll
function setApprovalForAll(address operator, bool approved) public virtual override { _setApprovalForAll(_msgSender(), operator, approved); }
/** * @dev See {IERC1155-setApprovalForAll}. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://f487e606c495603b45eddf5b72ccee7a2973f63c7b6613caa8a7e0d3b89bf8ec
{ "func_code_index": [ 2655, 2815 ] }
24,787
NFTArtGenPresale
@openzeppelin/contracts/token/ERC1155/ERC1155.sol
0xce6b30c9ddbfe895bea6f6910673f4a70ac22951
Solidity
ERC1155
contract ERC1155 is Context, ERC165, IERC1155, IERC1155MetadataURI { using Address for address; // Mapping from token ID to account balances mapping(uint256 => mapping(address => uint256)) private _balances; // Mapping from account to operator approvals mapping(address => mapping(address =>...
/** * @dev Implementation of the basic standard multi-token. * See https://eips.ethereum.org/EIPS/eip-1155 * Originally based on code by Enjin: https://github.com/enjin/erc-1155 * * _Available since v3.1._ */
NatSpecMultiLine
isApprovedForAll
function isApprovedForAll(address account, address operator) public view virtual override returns (bool) { return _operatorApprovals[account][operator]; }
/** * @dev See {IERC1155-isApprovedForAll}. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://f487e606c495603b45eddf5b72ccee7a2973f63c7b6613caa8a7e0d3b89bf8ec
{ "func_code_index": [ 2882, 3055 ] }
24,788
NFTArtGenPresale
@openzeppelin/contracts/token/ERC1155/ERC1155.sol
0xce6b30c9ddbfe895bea6f6910673f4a70ac22951
Solidity
ERC1155
contract ERC1155 is Context, ERC165, IERC1155, IERC1155MetadataURI { using Address for address; // Mapping from token ID to account balances mapping(uint256 => mapping(address => uint256)) private _balances; // Mapping from account to operator approvals mapping(address => mapping(address =>...
/** * @dev Implementation of the basic standard multi-token. * See https://eips.ethereum.org/EIPS/eip-1155 * Originally based on code by Enjin: https://github.com/enjin/erc-1155 * * _Available since v3.1._ */
NatSpecMultiLine
safeTransferFrom
function safeTransferFrom( address from, address to, uint256 id, uint256 amount, bytes memory data ) public virtual override { require( from == _msgSender() || isApprovedForAll(from, _msgSender()), "ERC1155: caller is not owner nor approved" ); _safeTransferFro...
/** * @dev See {IERC1155-safeTransferFrom}. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://f487e606c495603b45eddf5b72ccee7a2973f63c7b6613caa8a7e0d3b89bf8ec
{ "func_code_index": [ 3122, 3528 ] }
24,789
NFTArtGenPresale
@openzeppelin/contracts/token/ERC1155/ERC1155.sol
0xce6b30c9ddbfe895bea6f6910673f4a70ac22951
Solidity
ERC1155
contract ERC1155 is Context, ERC165, IERC1155, IERC1155MetadataURI { using Address for address; // Mapping from token ID to account balances mapping(uint256 => mapping(address => uint256)) private _balances; // Mapping from account to operator approvals mapping(address => mapping(address =>...
/** * @dev Implementation of the basic standard multi-token. * See https://eips.ethereum.org/EIPS/eip-1155 * Originally based on code by Enjin: https://github.com/enjin/erc-1155 * * _Available since v3.1._ */
NatSpecMultiLine
safeBatchTransferFrom
function safeBatchTransferFrom( address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) public virtual override { require( from == _msgSender() || isApprovedForAll(from, _msgSender()), "ERC1155: transfer caller is not owner nor appro...
/** * @dev See {IERC1155-safeBatchTransferFrom}. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://f487e606c495603b45eddf5b72ccee7a2973f63c7b6613caa8a7e0d3b89bf8ec
{ "func_code_index": [ 3600, 4047 ] }
24,790
NFTArtGenPresale
@openzeppelin/contracts/token/ERC1155/ERC1155.sol
0xce6b30c9ddbfe895bea6f6910673f4a70ac22951
Solidity
ERC1155
contract ERC1155 is Context, ERC165, IERC1155, IERC1155MetadataURI { using Address for address; // Mapping from token ID to account balances mapping(uint256 => mapping(address => uint256)) private _balances; // Mapping from account to operator approvals mapping(address => mapping(address =>...
/** * @dev Implementation of the basic standard multi-token. * See https://eips.ethereum.org/EIPS/eip-1155 * Originally based on code by Enjin: https://github.com/enjin/erc-1155 * * _Available since v3.1._ */
NatSpecMultiLine
_safeTransferFrom
function _safeTransferFrom( address from, address to, uint256 id, uint256 amount, bytes memory data ) internal virtual { require(to != address(0), "ERC1155: transfer to the zero address"); address operator = _msgSender(); _beforeTokenTransfer(operator, from, to, _asSingleton...
/** * @dev Transfers `amount` tokens of token type `id` from `from` to `to`. * * Emits a {TransferSingle} event. * * Requirements: * * - `to` cannot be the zero address. * - `from` must have a balance of tokens of type `id` of at least `amount`. * - If `to` refers to a smart contract, it must implemen...
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://f487e606c495603b45eddf5b72ccee7a2973f63c7b6613caa8a7e0d3b89bf8ec
{ "func_code_index": [ 4506, 5331 ] }
24,791
NFTArtGenPresale
@openzeppelin/contracts/token/ERC1155/ERC1155.sol
0xce6b30c9ddbfe895bea6f6910673f4a70ac22951
Solidity
ERC1155
contract ERC1155 is Context, ERC165, IERC1155, IERC1155MetadataURI { using Address for address; // Mapping from token ID to account balances mapping(uint256 => mapping(address => uint256)) private _balances; // Mapping from account to operator approvals mapping(address => mapping(address =>...
/** * @dev Implementation of the basic standard multi-token. * See https://eips.ethereum.org/EIPS/eip-1155 * Originally based on code by Enjin: https://github.com/enjin/erc-1155 * * _Available since v3.1._ */
NatSpecMultiLine
_safeBatchTransferFrom
function _safeBatchTransferFrom( address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) internal virtual { require(ids.length == amounts.length, "ERC1155: ids and amounts length mismatch"); require(to != address(0), "ERC1155: transfer to the zer...
/** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {_safeTransferFrom}. * * Emits a {TransferBatch} event. * * Requirements: * * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155BatchReceived} and return the * acceptance magic value. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://f487e606c495603b45eddf5b72ccee7a2973f63c7b6613caa8a7e0d3b89bf8ec
{ "func_code_index": [ 5684, 6763 ] }
24,792
NFTArtGenPresale
@openzeppelin/contracts/token/ERC1155/ERC1155.sol
0xce6b30c9ddbfe895bea6f6910673f4a70ac22951
Solidity
ERC1155
contract ERC1155 is Context, ERC165, IERC1155, IERC1155MetadataURI { using Address for address; // Mapping from token ID to account balances mapping(uint256 => mapping(address => uint256)) private _balances; // Mapping from account to operator approvals mapping(address => mapping(address =>...
/** * @dev Implementation of the basic standard multi-token. * See https://eips.ethereum.org/EIPS/eip-1155 * Originally based on code by Enjin: https://github.com/enjin/erc-1155 * * _Available since v3.1._ */
NatSpecMultiLine
_setURI
function _setURI(string memory newuri) internal virtual { _uri = newuri; }
/** * @dev Sets a new URI for all token types, by relying on the token type ID * substitution mechanism * https://eips.ethereum.org/EIPS/eip-1155#metadata[defined in the EIP]. * * By this mechanism, any occurrence of the `\{id\}` substring in either the * URI or any of the amounts in the JSON file at said U...
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://f487e606c495603b45eddf5b72ccee7a2973f63c7b6613caa8a7e0d3b89bf8ec
{ "func_code_index": [ 7602, 7695 ] }
24,793
NFTArtGenPresale
@openzeppelin/contracts/token/ERC1155/ERC1155.sol
0xce6b30c9ddbfe895bea6f6910673f4a70ac22951
Solidity
ERC1155
contract ERC1155 is Context, ERC165, IERC1155, IERC1155MetadataURI { using Address for address; // Mapping from token ID to account balances mapping(uint256 => mapping(address => uint256)) private _balances; // Mapping from account to operator approvals mapping(address => mapping(address =>...
/** * @dev Implementation of the basic standard multi-token. * See https://eips.ethereum.org/EIPS/eip-1155 * Originally based on code by Enjin: https://github.com/enjin/erc-1155 * * _Available since v3.1._ */
NatSpecMultiLine
_mint
function _mint( address to, uint256 id, uint256 amount, bytes memory data ) internal virtual { require(to != address(0), "ERC1155: mint to the zero address"); address operator = _msgSender(); _beforeTokenTransfer(operator, address(0), to, _asSingletonArray(id), _asSingletonArray(...
/** * @dev Creates `amount` tokens of token type `id`, and assigns them to `to`. * * Emits a {TransferSingle} event. * * Requirements: * * - `to` cannot be the zero address. * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155Received} and return the * acceptance magic...
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://f487e606c495603b45eddf5b72ccee7a2973f63c7b6613caa8a7e0d3b89bf8ec
{ "func_code_index": [ 8076, 8650 ] }
24,794
NFTArtGenPresale
@openzeppelin/contracts/token/ERC1155/ERC1155.sol
0xce6b30c9ddbfe895bea6f6910673f4a70ac22951
Solidity
ERC1155
contract ERC1155 is Context, ERC165, IERC1155, IERC1155MetadataURI { using Address for address; // Mapping from token ID to account balances mapping(uint256 => mapping(address => uint256)) private _balances; // Mapping from account to operator approvals mapping(address => mapping(address =>...
/** * @dev Implementation of the basic standard multi-token. * See https://eips.ethereum.org/EIPS/eip-1155 * Originally based on code by Enjin: https://github.com/enjin/erc-1155 * * _Available since v3.1._ */
NatSpecMultiLine
_mintBatch
function _mintBatch( address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) internal virtual { require(to != address(0), "ERC1155: mint to the zero address"); require(ids.length == amounts.length, "ERC1155: ids and amounts length mismatch"); address operato...
/** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {_mint}. * * Requirements: * * - `ids` and `amounts` must have the same length. * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155BatchReceived} and return the * acceptance magic value. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://f487e606c495603b45eddf5b72ccee7a2973f63c7b6613caa8a7e0d3b89bf8ec
{ "func_code_index": [ 9001, 9741 ] }
24,795
NFTArtGenPresale
@openzeppelin/contracts/token/ERC1155/ERC1155.sol
0xce6b30c9ddbfe895bea6f6910673f4a70ac22951
Solidity
ERC1155
contract ERC1155 is Context, ERC165, IERC1155, IERC1155MetadataURI { using Address for address; // Mapping from token ID to account balances mapping(uint256 => mapping(address => uint256)) private _balances; // Mapping from account to operator approvals mapping(address => mapping(address =>...
/** * @dev Implementation of the basic standard multi-token. * See https://eips.ethereum.org/EIPS/eip-1155 * Originally based on code by Enjin: https://github.com/enjin/erc-1155 * * _Available since v3.1._ */
NatSpecMultiLine
_burn
function _burn( address from, uint256 id, uint256 amount ) internal virtual { require(from != address(0), "ERC1155: burn from the zero address"); address operator = _msgSender(); _beforeTokenTransfer(operator, from, address(0), _asSingletonArray(id), _asSingletonArray(amount), ""); ...
/** * @dev Destroys `amount` tokens of token type `id` from `from` * * Requirements: * * - `from` cannot be the zero address. * - `from` must have at least `amount` tokens of token type `id`. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://f487e606c495603b45eddf5b72ccee7a2973f63c7b6613caa8a7e0d3b89bf8ec
{ "func_code_index": [ 9986, 10639 ] }
24,796
NFTArtGenPresale
@openzeppelin/contracts/token/ERC1155/ERC1155.sol
0xce6b30c9ddbfe895bea6f6910673f4a70ac22951
Solidity
ERC1155
contract ERC1155 is Context, ERC165, IERC1155, IERC1155MetadataURI { using Address for address; // Mapping from token ID to account balances mapping(uint256 => mapping(address => uint256)) private _balances; // Mapping from account to operator approvals mapping(address => mapping(address =>...
/** * @dev Implementation of the basic standard multi-token. * See https://eips.ethereum.org/EIPS/eip-1155 * Originally based on code by Enjin: https://github.com/enjin/erc-1155 * * _Available since v3.1._ */
NatSpecMultiLine
_burnBatch
function _burnBatch( address from, uint256[] memory ids, uint256[] memory amounts ) internal virtual { require(from != address(0), "ERC1155: burn from the zero address"); require(ids.length == amounts.length, "ERC1155: ids and amounts length mismatch"); address operator = _msgSender(); ...
/** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {_burn}. * * Requirements: * * - `ids` and `amounts` must have the same length. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://f487e606c495603b45eddf5b72ccee7a2973f63c7b6613caa8a7e0d3b89bf8ec
{ "func_code_index": [ 10837, 11733 ] }
24,797
NFTArtGenPresale
@openzeppelin/contracts/token/ERC1155/ERC1155.sol
0xce6b30c9ddbfe895bea6f6910673f4a70ac22951
Solidity
ERC1155
contract ERC1155 is Context, ERC165, IERC1155, IERC1155MetadataURI { using Address for address; // Mapping from token ID to account balances mapping(uint256 => mapping(address => uint256)) private _balances; // Mapping from account to operator approvals mapping(address => mapping(address =>...
/** * @dev Implementation of the basic standard multi-token. * See https://eips.ethereum.org/EIPS/eip-1155 * Originally based on code by Enjin: https://github.com/enjin/erc-1155 * * _Available since v3.1._ */
NatSpecMultiLine
_setApprovalForAll
function _setApprovalForAll( address owner, address operator, bool approved ) internal virtual { require(owner != operator, "ERC1155: setting approval status for self"); _operatorApprovals[owner][operator] = approved; emit ApprovalForAll(owner, operator, approved); }
/** * @dev Approve `operator` to operate on all of `owner` tokens * * Emits a {ApprovalForAll} event. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://f487e606c495603b45eddf5b72ccee7a2973f63c7b6613caa8a7e0d3b89bf8ec
{ "func_code_index": [ 11870, 12206 ] }
24,798
NFTArtGenPresale
@openzeppelin/contracts/token/ERC1155/ERC1155.sol
0xce6b30c9ddbfe895bea6f6910673f4a70ac22951
Solidity
ERC1155
contract ERC1155 is Context, ERC165, IERC1155, IERC1155MetadataURI { using Address for address; // Mapping from token ID to account balances mapping(uint256 => mapping(address => uint256)) private _balances; // Mapping from account to operator approvals mapping(address => mapping(address =>...
/** * @dev Implementation of the basic standard multi-token. * See https://eips.ethereum.org/EIPS/eip-1155 * Originally based on code by Enjin: https://github.com/enjin/erc-1155 * * _Available since v3.1._ */
NatSpecMultiLine
_beforeTokenTransfer
function _beforeTokenTransfer( address operator, address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) internal virtual {}
/** * @dev Hook that is called before any token transfer. This includes minting * and burning, as well as batched variants. * * The same hook is called on both single and batched variants. For single * transfers, the length of the `id` and `amount` arrays will be 1. * * Calling conditions (for each `id` a...
NatSpecMultiLine
v0.8.4+commit.c7e474f2
None
ipfs://f487e606c495603b45eddf5b72ccee7a2973f63c7b6613caa8a7e0d3b89bf8ec
{ "func_code_index": [ 13157, 13383 ] }
24,799