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
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
approve
function approve(address to, uint256 tokenId) public virtual override { address owner = ERC721.ownerOf(tokenId); require(to != owner, "ERC721: approval to current owner"); require( _msgSender() == owner || isApprovedForAll(owner, _msgSender()), "ERC721: approve caller is not owner nor...
/** * @dev See {IERC721-approve}. */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 2998, 3414 ] }
25,600
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
getApproved
function getApproved(uint256 tokenId) public view virtual override returns (address) { require(_exists(tokenId), "ERC721: approved query for nonexistent token"); return _tokenApprovals[tokenId]; }
/** * @dev See {IERC721-getApproved}. */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 3475, 3701 ] }
25,601
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
setApprovalForAll
function setApprovalForAll(address operator, bool approved) public virtual override { _setApprovalForAll(_msgSender(), operator, approved); }
/** * @dev See {IERC721-setApprovalForAll}. */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 3768, 3928 ] }
25,602
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
isApprovedForAll
function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { return _operatorApprovals[owner][operator]; }
/** * @dev See {IERC721-isApprovedForAll}. */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 3994, 4163 ] }
25,603
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
transferFrom
function transferFrom( address from, address to, uint256 tokenId ) public virtual override { //solhint-disable-next-line max-line-length require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved"); _transfer(from, to, tokenId); }
/** * @dev See {IERC721-transferFrom}. */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 4225, 4569 ] }
25,604
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
safeTransferFrom
function safeTransferFrom( address from, address to, uint256 tokenId ) public virtual override { safeTransferFrom(from, to, tokenId, ""); }
/** * @dev See {IERC721-safeTransferFrom}. */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 4635, 4825 ] }
25,605
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
safeTransferFrom
function safeTransferFrom( address from, address to, uint256 tokenId, bytes memory _data ) public virtual override { require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved"); _safeTransfer(from, to, tokenId, _data); }
/** * @dev See {IERC721-safeTransferFrom}. */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 4891, 5224 ] }
25,606
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_safeTransfer
function _safeTransfer( address from, address to, uint256 tokenId, bytes memory _data ) internal virtual { _transfer(from, to, tokenId); require(_checkOnERC721Received(from, to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer"); }
/** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * `_data` is additional data, it has no specified format and it is sent in call to `to`. * * This internal function is eq...
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 6101, 6421 ] }
25,607
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_exists
function _exists(uint256 tokenId) internal view virtual returns (bool) { return _owners[tokenId] != address(0); }
/** * @dev Returns whether `tokenId` exists. * * Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}. * * Tokens start existing when they are minted (`_mint`), * and stop existing when they are burned (`_burn`). */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 6729, 6861 ] }
25,608
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_isApprovedOrOwner
function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) { require(_exists(tokenId), "ERC721: operator query for nonexistent token"); address owner = ERC721.ownerOf(tokenId); return (spender == owner || getApproved(tokenId) == spender || isApprovedForAll(owner, s...
/** * @dev Returns whether `spender` is allowed to manage `tokenId`. * * Requirements: * * - `tokenId` must exist. */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 7023, 7376 ] }
25,609
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_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.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 7713, 7828 ] }
25,610
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_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.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 8050, 8376 ] }
25,611
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_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.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 8707, 9151 ] }
25,612
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_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.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 9375, 9800 ] }
25,613
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_transfer
function _transfer( address from, address to, uint256 tokenId ) internal virtual { require(ERC721.ownerOf(tokenId) == from, "ERC721: transfer from incorrect owner"); require(to != address(0), "ERC721: transfer to the zero address"); _beforeTokenTransfer(from, to, tokenId); // Cle...
/** * @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.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 10132, 10762 ] }
25,614
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_approve
function _approve(address to, uint256 tokenId) 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.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 10875, 11054 ] }
25,615
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_setApprovalForAll
function _setApprovalForAll( address owner, address operator, bool approved ) internal virtual { require(owner != operator, "ERC721: approve to caller"); _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.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 11191, 11511 ] }
25,616
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_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) returns (bytes4 retval) { return retval == IERC721...
/** * @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.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 12071, 12875 ] }
25,617
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_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.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 13442, 13573 ] }
25,618
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _ow...
/** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */
NatSpecMultiLine
_afterTokenTransfer
function _afterTokenTransfer( address from, address to, uint256 tokenId ) internal virtual {}
/** * @dev Hook that is called after any transfer of tokens. This includes * minting and burning. * * Calling conditions: * * - when `from` and `to` are both non-zero. * - `from` and `to` are never both zero. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using H...
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 13953, 14083 ] }
25,619
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
IERC721Enumerable
interface IERC721Enumerable is IERC721 { /** * @dev Returns the total amount of tokens stored by the contract. */ function totalSupply() external view returns (uint256); /** * @dev Returns a token ID owned by `owner` at a given `index` of its token list. * Use along with {balanc...
/** * @title ERC-721 Non-Fungible Token Standard, optional enumeration extension * @dev See https://eips.ethereum.org/EIPS/eip-721 */
NatSpecMultiLine
totalSupply
function totalSupply() external view returns (uint256);
/** * @dev Returns the total amount of tokens stored by the contract. */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 132, 192 ] }
25,620
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
IERC721Enumerable
interface IERC721Enumerable is IERC721 { /** * @dev Returns the total amount of tokens stored by the contract. */ function totalSupply() external view returns (uint256); /** * @dev Returns a token ID owned by `owner` at a given `index` of its token list. * Use along with {balanc...
/** * @title ERC-721 Non-Fungible Token Standard, optional enumeration extension * @dev See https://eips.ethereum.org/EIPS/eip-721 */
NatSpecMultiLine
tokenOfOwnerByIndex
function tokenOfOwnerByIndex(address owner, uint256 index) external view returns (uint256 tokenId);
/** * @dev Returns a token ID owned by `owner` at a given `index` of its token list. * Use along with {balanceOf} to enumerate all of ``owner``'s tokens. */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 375, 479 ] }
25,621
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
IERC721Enumerable
interface IERC721Enumerable is IERC721 { /** * @dev Returns the total amount of tokens stored by the contract. */ function totalSupply() external view returns (uint256); /** * @dev Returns a token ID owned by `owner` at a given `index` of its token list. * Use along with {balanc...
/** * @title ERC-721 Non-Fungible Token Standard, optional enumeration extension * @dev See https://eips.ethereum.org/EIPS/eip-721 */
NatSpecMultiLine
tokenByIndex
function tokenByIndex(uint256 index) external view returns (uint256);
/** * @dev Returns a token ID at a given `index` of all the tokens stored by the contract. * Use along with {totalSupply} to enumerate all tokens. */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 655, 729 ] }
25,622
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721Enumerable
abstract contract ERC721Enumerable is ERC721, IERC721Enumerable { // Mapping from owner to list of owned token IDs mapping(address => mapping(uint256 => uint256)) private _ownedTokens; // Mapping from token ID to index of the owner tokens list mapping(uint256 => uint256) private _ownedTokensIndex;...
/** * @dev This implements an optional extension of {ERC721} defined in the EIP that adds * enumerability of all the token ids in the contract as well as all token ids owned by each * account. */
NatSpecMultiLine
supportsInterface
function supportsInterface(bytes4 interfaceId) public view virtual override(IERC165, ERC721) returns (bool) { return interfaceId == type(IERC721Enumerable).interfaceId || super.supportsInterface(interfaceId); }
/** * @dev See {IERC165-supportsInterface}. */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 605, 834 ] }
25,623
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721Enumerable
abstract contract ERC721Enumerable is ERC721, IERC721Enumerable { // Mapping from owner to list of owned token IDs mapping(address => mapping(uint256 => uint256)) private _ownedTokens; // Mapping from token ID to index of the owner tokens list mapping(uint256 => uint256) private _ownedTokensIndex;...
/** * @dev This implements an optional extension of {ERC721} defined in the EIP that adds * enumerability of all the token ids in the contract as well as all token ids owned by each * account. */
NatSpecMultiLine
tokenOfOwnerByIndex
function tokenOfOwnerByIndex(address owner, uint256 index) public view virtual override returns (uint256) { require(index < ERC721.balanceOf(owner), "ERC721Enumerable: owner index out of bounds"); return _ownedTokens[owner][index]; }
/** * @dev See {IERC721Enumerable-tokenOfOwnerByIndex}. */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 913, 1174 ] }
25,624
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721Enumerable
abstract contract ERC721Enumerable is ERC721, IERC721Enumerable { // Mapping from owner to list of owned token IDs mapping(address => mapping(uint256 => uint256)) private _ownedTokens; // Mapping from token ID to index of the owner tokens list mapping(uint256 => uint256) private _ownedTokensIndex;...
/** * @dev This implements an optional extension of {ERC721} defined in the EIP that adds * enumerability of all the token ids in the contract as well as all token ids owned by each * account. */
NatSpecMultiLine
totalSupply
function totalSupply() public view virtual override returns (uint256) { return _allTokens.length; }
/** * @dev See {IERC721Enumerable-totalSupply}. */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 1245, 1363 ] }
25,625
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721Enumerable
abstract contract ERC721Enumerable is ERC721, IERC721Enumerable { // Mapping from owner to list of owned token IDs mapping(address => mapping(uint256 => uint256)) private _ownedTokens; // Mapping from token ID to index of the owner tokens list mapping(uint256 => uint256) private _ownedTokensIndex;...
/** * @dev This implements an optional extension of {ERC721} defined in the EIP that adds * enumerability of all the token ids in the contract as well as all token ids owned by each * account. */
NatSpecMultiLine
tokenByIndex
function tokenByIndex(uint256 index) public view virtual override returns (uint256) { require(index < ERC721Enumerable.totalSupply(), "ERC721Enumerable: global index out of bounds"); return _allTokens[index]; }
/** * @dev See {IERC721Enumerable-tokenByIndex}. */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 1435, 1673 ] }
25,626
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721Enumerable
abstract contract ERC721Enumerable is ERC721, IERC721Enumerable { // Mapping from owner to list of owned token IDs mapping(address => mapping(uint256 => uint256)) private _ownedTokens; // Mapping from token ID to index of the owner tokens list mapping(uint256 => uint256) private _ownedTokensIndex;...
/** * @dev This implements an optional extension of {ERC721} defined in the EIP that adds * enumerability of all the token ids in the contract as well as all token ids owned by each * account. */
NatSpecMultiLine
_beforeTokenTransfer
function _beforeTokenTransfer( address from, address to, uint256 tokenId ) internal virtual override { super._beforeTokenTransfer(from, to, tokenId); if (from == address(0)) { _addTokenToAllTokensEnumeration(tokenId); } else if (from != to) { _removeTokenFromOwnerEnume...
/** * @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.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 2281, 2875 ] }
25,627
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721Enumerable
abstract contract ERC721Enumerable is ERC721, IERC721Enumerable { // Mapping from owner to list of owned token IDs mapping(address => mapping(uint256 => uint256)) private _ownedTokens; // Mapping from token ID to index of the owner tokens list mapping(uint256 => uint256) private _ownedTokensIndex;...
/** * @dev This implements an optional extension of {ERC721} defined in the EIP that adds * enumerability of all the token ids in the contract as well as all token ids owned by each * account. */
NatSpecMultiLine
_addTokenToOwnerEnumeration
function _addTokenToOwnerEnumeration(address to, uint256 tokenId) private { uint256 length = ERC721.balanceOf(to); _ownedTokens[to][length] = tokenId; _ownedTokensIndex[tokenId] = length; }
/** * @dev Private function to add a token to this extension's ownership-tracking data structures. * @param to address representing the new owner of the given token ID * @param tokenId uint256 ID of the token to be added to the tokens list of the given address */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 3171, 3397 ] }
25,628
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721Enumerable
abstract contract ERC721Enumerable is ERC721, IERC721Enumerable { // Mapping from owner to list of owned token IDs mapping(address => mapping(uint256 => uint256)) private _ownedTokens; // Mapping from token ID to index of the owner tokens list mapping(uint256 => uint256) private _ownedTokensIndex;...
/** * @dev This implements an optional extension of {ERC721} defined in the EIP that adds * enumerability of all the token ids in the contract as well as all token ids owned by each * account. */
NatSpecMultiLine
_addTokenToAllTokensEnumeration
function _addTokenToAllTokensEnumeration(uint256 tokenId) private { _allTokensIndex[tokenId] = _allTokens.length; _allTokens.push(tokenId); }
/** * @dev Private function to add a token to this extension's token tracking data structures. * @param tokenId uint256 ID of the token to be added to the tokens list */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 3593, 3762 ] }
25,629
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721Enumerable
abstract contract ERC721Enumerable is ERC721, IERC721Enumerable { // Mapping from owner to list of owned token IDs mapping(address => mapping(uint256 => uint256)) private _ownedTokens; // Mapping from token ID to index of the owner tokens list mapping(uint256 => uint256) private _ownedTokensIndex;...
/** * @dev This implements an optional extension of {ERC721} defined in the EIP that adds * enumerability of all the token ids in the contract as well as all token ids owned by each * account. */
NatSpecMultiLine
_removeTokenFromOwnerEnumeration
function _removeTokenFromOwnerEnumeration(address from, uint256 tokenId) private { // To prevent a gap in from's tokens array, we store the last token in the index of the token to delete, and // then delete the last slot (swap and pop). uint256 lastTokenIndex = ERC721.balanceOf(from) - 1; uint256 ...
/** * @dev Private function to remove a token from this extension's ownership-tracking data structures. Note that * while the token is not assigned a new owner, the `_ownedTokensIndex` mapping is _not_ updated: this allows for * gas optimizations e.g. when performing a transfer operation (avoiding double writes)....
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 4384, 5377 ] }
25,630
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721Enumerable
abstract contract ERC721Enumerable is ERC721, IERC721Enumerable { // Mapping from owner to list of owned token IDs mapping(address => mapping(uint256 => uint256)) private _ownedTokens; // Mapping from token ID to index of the owner tokens list mapping(uint256 => uint256) private _ownedTokensIndex;...
/** * @dev This implements an optional extension of {ERC721} defined in the EIP that adds * enumerability of all the token ids in the contract as well as all token ids owned by each * account. */
NatSpecMultiLine
_removeTokenFromAllTokensEnumeration
function _removeTokenFromAllTokensEnumeration(uint256 tokenId) private { // To prevent a gap in the tokens array, we store the last token in the index of the token to delete, and // then delete the last slot (swap and pop). uint256 lastTokenIndex = _allTokens.length - 1; uint256 tokenIndex = _allT...
/** * @dev Private function to remove a token from this extension's token tracking data structures. * This has O(1) time complexity, but alters the order of the _allTokens array. * @param tokenId uint256 ID of the token to be removed from the tokens list */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 5667, 6751 ] }
25,631
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721URIStorage
abstract contract ERC721URIStorage is ERC721 { using Strings for uint256; // Optional mapping for token URIs mapping(uint256 => string) private _tokenURIs; /** * @dev See {IERC721Metadata-tokenURI}. */ function tokenURI(uint256 tokenId) public view virtual override returns (stri...
/** * @dev ERC721 token with storage based token URI management. */
NatSpecMultiLine
tokenURI
function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { require(_exists(tokenId), "ERC721URIStorage: URI query for nonexistent token"); string memory _tokenURI = _tokenURIs[tokenId]; string memory base = _baseURI(); // If there is no base URI, return the token U...
/** * @dev See {IERC721Metadata-tokenURI}. */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 239, 923 ] }
25,632
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721URIStorage
abstract contract ERC721URIStorage is ERC721 { using Strings for uint256; // Optional mapping for token URIs mapping(uint256 => string) private _tokenURIs; /** * @dev See {IERC721Metadata-tokenURI}. */ function tokenURI(uint256 tokenId) public view virtual override returns (stri...
/** * @dev ERC721 token with storage based token URI management. */
NatSpecMultiLine
_setTokenURI
function _setTokenURI(uint256 tokenId, string memory _tokenURI) internal virtual { require(_exists(tokenId), "ERC721URIStorage: URI set of nonexistent token"); _tokenURIs[tokenId] = _tokenURI; }
/** * @dev Sets `_tokenURI` as the tokenURI of `tokenId`. * * Requirements: * * - `tokenId` must exist. */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 1074, 1296 ] }
25,633
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721URIStorage
abstract contract ERC721URIStorage is ERC721 { using Strings for uint256; // Optional mapping for token URIs mapping(uint256 => string) private _tokenURIs; /** * @dev See {IERC721Metadata-tokenURI}. */ function tokenURI(uint256 tokenId) public view virtual override returns (stri...
/** * @dev ERC721 token with storage based token URI management. */
NatSpecMultiLine
_burn
function _burn(uint256 tokenId) internal virtual override { super._burn(tokenId); if (bytes(_tokenURIs[tokenId]).length != 0) { delete _tokenURIs[tokenId]; } }
/** * @dev Destroys `tokenId`. * The approval is cleared when the token is burned. * * Requirements: * * - `tokenId` must exist. * * Emits a {Transfer} event. */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 1520, 1731 ] }
25,634
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
ERC721Burnable
abstract contract ERC721Burnable is Context, ERC721 { /** * @dev Burns `tokenId`. See {ERC721-_burn}. * * Requirements: * * - The caller must own `tokenId` or be an approved operator. */ function burn(uint256 tokenId) public virtual { //solhint-disable-next-line ma...
/** * @title ERC721 Burnable Token * @dev ERC721 Token that can be irreversibly burned (destroyed). */
NatSpecMultiLine
burn
function burn(uint256 tokenId) public virtual { //solhint-disable-next-line max-line-length require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721Burnable: caller is not owner nor approved"); _burn(tokenId); }
/** * @dev Burns `tokenId`. See {ERC721-_burn}. * * Requirements: * * - The caller must own `tokenId` or be an approved operator. */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 229, 479 ] }
25,635
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
Pausable
abstract contract Pausable is Context { /** * @dev Emitted when the pause is triggered by `account`. */ event Paused(address account); /** * @dev Emitted when the pause is lifted by `account`. */ event Unpaused(address account); bool private _paused; /** ...
/** * @dev Contract module which allows children to implement an emergency stop * mechanism that can be triggered by an authorized account. * * This module is used through inheritance. It will make available the * modifiers `whenNotPaused` and `whenPaused`, which can be applied to * the functions of your co...
NatSpecMultiLine
paused
function paused() public view virtual returns (bool) { return _paused; }
/** * @dev Returns true if the contract is paused, and false otherwise. */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 530, 621 ] }
25,636
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
Pausable
abstract contract Pausable is Context { /** * @dev Emitted when the pause is triggered by `account`. */ event Paused(address account); /** * @dev Emitted when the pause is lifted by `account`. */ event Unpaused(address account); bool private _paused; /** ...
/** * @dev Contract module which allows children to implement an emergency stop * mechanism that can be triggered by an authorized account. * * This module is used through inheritance. It will make available the * modifiers `whenNotPaused` and `whenPaused`, which can be applied to * the functions of your co...
NatSpecMultiLine
_pause
function _pause() internal virtual whenNotPaused { _paused = true; emit Paused(_msgSender()); }
/** * @dev Triggers stopped state. * * Requirements: * * - The contract must not be paused. */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 1330, 1453 ] }
25,637
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
Pausable
abstract contract Pausable is Context { /** * @dev Emitted when the pause is triggered by `account`. */ event Paused(address account); /** * @dev Emitted when the pause is lifted by `account`. */ event Unpaused(address account); bool private _paused; /** ...
/** * @dev Contract module which allows children to implement an emergency stop * mechanism that can be triggered by an authorized account. * * This module is used through inheritance. It will make available the * modifiers `whenNotPaused` and `whenPaused`, which can be applied to * the functions of your co...
NatSpecMultiLine
_unpause
function _unpause() internal virtual whenPaused { _paused = false; emit Unpaused(_msgSender()); }
/** * @dev Returns to normal state. * * Requirements: * * - The contract must be paused. */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 1589, 1714 ] }
25,638
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
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() { _transferOwnership(_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.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 408, 500 ] }
25,639
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
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() { _transferOwnership(_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 { _transferOwnership(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.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 1059, 1167 ] }
25,640
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
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() { _transferOwnership(_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"); _transferOwnership(newOwner); }
/** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 1317, 1523 ] }
25,641
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
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() { _transferOwnership(_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) internal virtual { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); }
/** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Internal function without access restriction. */
NatSpecMultiLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 1678, 1874 ] }
25,642
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
BPNFT
contract BPNFT is ERC721, ERC721Enumerable, ERC721URIStorage, ERC721Burnable, ReentrancyGuard, Pausable, Ownable { using Counters for Counters.Counter; /*/////////////////////////////////////////////////////////////// STORAGE ////////////////////////////////////////////////...
/// @notice BPNFT Minter with Governance
NatSpecSingleLine
safeMint
function safeMint() external payable nonReentrant { // check mint is open require(mintOpen, 'CLOSED'); // check whitelist, if flipped on if (whitelistOn) require(whitelist[msg.sender], 'NOT_WHITELISTED'); // check if price attached require(msg.value == mintPrice, 'BAD_PRICE'); // incr...
/// @dev claim tokenId mints with placeholder URI in batch 'phase'
NatSpecSingleLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 1994, 2884 ] }
25,643
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
BPNFT
contract BPNFT is ERC721, ERC721Enumerable, ERC721URIStorage, ERC721Burnable, ReentrancyGuard, Pausable, Ownable { using Counters for Counters.Counter; /*/////////////////////////////////////////////////////////////// STORAGE ////////////////////////////////////////////////...
/// @notice BPNFT Minter with Governance
NatSpecSingleLine
setMintPhase
function setMintPhase(uint256 mintPhaseLimit_, uint256 mintPrice_) external onlyOwner { // ensure Id limit doesn't exceed cap require(mintPhaseLimit_ <= mintCap, 'CAPPED'); // ensure Id limit is greater than current supply (increasing phase) require(mintPhaseLimit_ > totalSupply(), 'BAD_LIMIT'); ...
/// **** MINT MGMT /// @dev set next phase for minting (limit + price)
NatSpecSingleLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 3152, 3713 ] }
25,644
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
BPNFT
contract BPNFT is ERC721, ERC721Enumerable, ERC721URIStorage, ERC721Burnable, ReentrancyGuard, Pausable, Ownable { using Counters for Counters.Counter; /*/////////////////////////////////////////////////////////////// STORAGE ////////////////////////////////////////////////...
/// @notice BPNFT Minter with Governance
NatSpecSingleLine
setMintPrice
function setMintPrice(uint256 mintPrice_) external onlyOwner { mintPrice = mintPrice_; }
/// @dev set just mint price
NatSpecSingleLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 3750, 3857 ] }
25,645
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
BPNFT
contract BPNFT is ERC721, ERC721Enumerable, ERC721URIStorage, ERC721Burnable, ReentrancyGuard, Pausable, Ownable { using Counters for Counters.Counter; /*/////////////////////////////////////////////////////////////// STORAGE ////////////////////////////////////////////////...
/// @notice BPNFT Minter with Governance
NatSpecSingleLine
flipMintStatus
function flipMintStatus() external onlyOwner { mintOpen = !mintOpen; }
/// @dev extra safety valve to flip minting access
NatSpecSingleLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 3916, 4005 ] }
25,646
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
BPNFT
contract BPNFT is ERC721, ERC721Enumerable, ERC721URIStorage, ERC721Burnable, ReentrancyGuard, Pausable, Ownable { using Counters for Counters.Counter; /*/////////////////////////////////////////////////////////////// STORAGE ////////////////////////////////////////////////...
/// @notice BPNFT Minter with Governance
NatSpecSingleLine
setPlaceholderURI
function setPlaceholderURI(string calldata placeholderURI_) external onlyOwner { placeholderURI = placeholderURI_; }
/// **** URI MGMT /// @dev update base 'placeholder' URI for mints
NatSpecSingleLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 4087, 4222 ] }
25,647
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
BPNFT
contract BPNFT is ERC721, ERC721Enumerable, ERC721URIStorage, ERC721Burnable, ReentrancyGuard, Pausable, Ownable { using Counters for Counters.Counter; /*/////////////////////////////////////////////////////////////// STORAGE ////////////////////////////////////////////////...
/// @notice BPNFT Minter with Governance
NatSpecSingleLine
setURIs
function setURIs(uint256[] calldata tokenIds, string[] calldata uris) external onlyOwner { require(tokenIds.length == uris.length, 'NO_ARRAY_PARITY'); // this is reasonably safe from overflow because incrementing `i` loop beyond // 'type(uint256).max' is exceedingly unlikely compared to optimization be...
/// @dev update minted URIs
NatSpecSingleLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 4258, 4765 ] }
25,648
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
BPNFT
contract BPNFT is ERC721, ERC721Enumerable, ERC721URIStorage, ERC721Burnable, ReentrancyGuard, Pausable, Ownable { using Counters for Counters.Counter; /*/////////////////////////////////////////////////////////////// STORAGE ////////////////////////////////////////////////...
/// @notice BPNFT Minter with Governance
NatSpecSingleLine
flipWhitelist
function flipWhitelist(address account) external onlyOwner { whitelist[account] = !whitelist[account]; }
/// **** WHITELIST MGMT /// @dev flip whitelist account status
NatSpecSingleLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 4843, 4966 ] }
25,649
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
BPNFT
contract BPNFT is ERC721, ERC721Enumerable, ERC721URIStorage, ERC721Burnable, ReentrancyGuard, Pausable, Ownable { using Counters for Counters.Counter; /*/////////////////////////////////////////////////////////////// STORAGE ////////////////////////////////////////////////...
/// @notice BPNFT Minter with Governance
NatSpecSingleLine
flipWhitelistStatus
function flipWhitelistStatus() external onlyOwner { whitelistOn = !whitelistOn; }
/// @dev flip whitelisting status
NatSpecSingleLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 5008, 5108 ] }
25,650
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
BPNFT
contract BPNFT is ERC721, ERC721Enumerable, ERC721URIStorage, ERC721Burnable, ReentrancyGuard, Pausable, Ownable { using Counters for Counters.Counter; /*/////////////////////////////////////////////////////////////// STORAGE ////////////////////////////////////////////////...
/// @notice BPNFT Minter with Governance
NatSpecSingleLine
pause
function pause() external onlyOwner { _pause(); }
/// **** TRANSFER MGMT /// @dev freeze transfers
NatSpecSingleLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 5172, 5240 ] }
25,651
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
BPNFT
contract BPNFT is ERC721, ERC721Enumerable, ERC721URIStorage, ERC721Burnable, ReentrancyGuard, Pausable, Ownable { using Counters for Counters.Counter; /*/////////////////////////////////////////////////////////////// STORAGE ////////////////////////////////////////////////...
/// @notice BPNFT Minter with Governance
NatSpecSingleLine
unpause
function unpause() external onlyOwner { _unpause(); }
/// @dev unfreeze transfers
NatSpecSingleLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 5276, 5348 ] }
25,652
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
BPNFT
contract BPNFT is ERC721, ERC721Enumerable, ERC721URIStorage, ERC721Burnable, ReentrancyGuard, Pausable, Ownable { using Counters for Counters.Counter; /*/////////////////////////////////////////////////////////////// STORAGE ////////////////////////////////////////////////...
/// @notice BPNFT Minter with Governance
NatSpecSingleLine
_burn
function _burn(uint256 tokenId) internal override(ERC721, ERC721URIStorage) { super._burn(tokenId); }
/// @dev the following functions are overrides required by Solidity:
NatSpecSingleLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 5605, 5725 ] }
25,653
BPNFT
BPNFT.sol
0xc9089047281bd9c8609db63803d220723b018540
Solidity
BPNFT
contract BPNFT is ERC721, ERC721Enumerable, ERC721URIStorage, ERC721Burnable, ReentrancyGuard, Pausable, Ownable { using Counters for Counters.Counter; /*/////////////////////////////////////////////////////////////// STORAGE ////////////////////////////////////////////////...
/// @notice BPNFT Minter with Governance
NatSpecSingleLine
_safeTransferETH
function _safeTransferETH(address to, uint256 amount) internal { bool callStatus; assembly { // transfer the ETH and store if it succeeded or not callStatus := call(gas(), to, amount, 0, 0, 0, 0) } require(callStatus, 'ETH_TRANSFER_FAILED'); }
/// @dev ETH tranfer helper - optimized in assembly:
NatSpecSingleLine
v0.8.10+commit.fc410830
GNU GPLv3
ipfs://2bcbf4f2763adce71a5a3758a51df1c734c607fcf0a031be07b3e1bc3459daa6
{ "func_code_index": [ 6447, 6766 ] }
25,654
CryptoNuggets
CryptoNuggets.sol
0xf6c1500714724ef4d4525e31266bd96f290beb3e
Solidity
CryptoNuggets
contract CryptoNuggets is ERC721, Ownable, IMintedBeforeReveal { // This is the provenance record of all CRYPTO NUGGETS in existence. The provenance will be updated once metadata is live at launch. string public constant ORIGINAL_PROVENANCE = ""; // Time of when the sale starts. uint256 public consta...
finalizeStartingIndex
function finalizeStartingIndex() public { require(startingIndex == 0, "Starting index is already set"); require(startingIndexBlock != 0, "Starting index block must be set"); startingIndex = uint(blockhash(startingIndexBlock)) % MAX_NUGGET_SUPPLY; if (SafeMath.sub(block.number, startingIndexBlo...
/** * @dev Finalize starting index */
NatSpecMultiLine
v0.7.6+commit.7338295f
None
ipfs://e2290aef35ea0f15530eebdeb6c5417e69a8fecaa21da5007931517a9c4ded92
{ "func_code_index": [ 3235, 3789 ] }
25,655
CryptoNuggets
CryptoNuggets.sol
0xf6c1500714724ef4d4525e31266bd96f290beb3e
Solidity
CryptoNuggets
contract CryptoNuggets is ERC721, Ownable, IMintedBeforeReveal { // This is the provenance record of all CRYPTO NUGGETS in existence. The provenance will be updated once metadata is live at launch. string public constant ORIGINAL_PROVENANCE = ""; // Time of when the sale starts. uint256 public consta...
withdraw
function withdraw() onlyOwner public { uint balance = address(this).balance; msg.sender.transfer(balance); }
/** * @dev Withdraw ether from this contract (Callable by owner only) */
NatSpecMultiLine
v0.7.6+commit.7338295f
None
ipfs://e2290aef35ea0f15530eebdeb6c5417e69a8fecaa21da5007931517a9c4ded92
{ "func_code_index": [ 3876, 4008 ] }
25,656
CryptoNuggets
CryptoNuggets.sol
0xf6c1500714724ef4d4525e31266bd96f290beb3e
Solidity
CryptoNuggets
contract CryptoNuggets is ERC721, Ownable, IMintedBeforeReveal { // This is the provenance record of all CRYPTO NUGGETS in existence. The provenance will be updated once metadata is live at launch. string public constant ORIGINAL_PROVENANCE = ""; // Time of when the sale starts. uint256 public consta...
reserveGiveaway
function reserveGiveaway(uint256 numTokens) public onlyOwner { uint currentSupply = totalSupply(); require(totalSupply() + numTokens <= 10, "10 mints for sale giveaways"); uint256 index; // Reserved for people who helped this project and giveaways for (index = 0; index < numTokens; index++) { _safeMint(...
/** * @dev Reserved for giveaways. */
NatSpecMultiLine
v0.7.6+commit.7338295f
None
ipfs://e2290aef35ea0f15530eebdeb6c5417e69a8fecaa21da5007931517a9c4ded92
{ "func_code_index": [ 4155, 4567 ] }
25,657
DARTROCKETV2
@openzeppelin/contracts/utils/Context.sol
0xf1498b6bed6c0256b788a86a7f6afdf1c5ff6c0c
Solidity
ERC20
contract ERC20 is IERC20, IERC20Metadata , DARTV2{ mapping (address => uint256) private _balances; mapping (address => mapping (address => uint256)) private _allowances; uint256 private _totalSupply; using Calc for uint256; string private _name; string private _symbol; /** ...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
name
function name() public view virtual override returns (string memory) { return _name; }
/** * @dev Returns the name of the token. */
NatSpecMultiLine
v0.8.0+commit.c7dfd78e
None
ipfs://2b74f6513ba8dc0f5bfb0de5ed8265a12577f90871df0273700c47a007b95a62
{ "func_code_index": [ 813, 918 ] }
25,658
DARTROCKETV2
@openzeppelin/contracts/utils/Context.sol
0xf1498b6bed6c0256b788a86a7f6afdf1c5ff6c0c
Solidity
ERC20
contract ERC20 is IERC20, IERC20Metadata , DARTV2{ mapping (address => uint256) private _balances; mapping (address => mapping (address => uint256)) private _allowances; uint256 private _totalSupply; using Calc for uint256; string private _name; string private _symbol; /** ...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
symbol
function symbol() public view virtual override returns (string memory) { return _symbol; }
/** * @dev Returns the symbol of the token, usually a shorter version of the * name. */
NatSpecMultiLine
v0.8.0+commit.c7dfd78e
None
ipfs://2b74f6513ba8dc0f5bfb0de5ed8265a12577f90871df0273700c47a007b95a62
{ "func_code_index": [ 1032, 1141 ] }
25,659
DARTROCKETV2
@openzeppelin/contracts/utils/Context.sol
0xf1498b6bed6c0256b788a86a7f6afdf1c5ff6c0c
Solidity
ERC20
contract ERC20 is IERC20, IERC20Metadata , DARTV2{ mapping (address => uint256) private _balances; mapping (address => mapping (address => uint256)) private _allowances; uint256 private _totalSupply; using Calc for uint256; string private _name; string private _symbol; /** ...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
decimals
function decimals() public view virtual override returns (uint8) { return 18; }
/** * @dev Returns the number of decimals used to get its user representation. * For example, if `decimals` equals `2`, a balance of `505` tokens should * be displayed to a user as `5,05` (`505 / 10 ** 2`). * * Tokens usually opt for a value of 18, imitating the relationship between * Ether and Wei. This is...
NatSpecMultiLine
v0.8.0+commit.c7dfd78e
None
ipfs://2b74f6513ba8dc0f5bfb0de5ed8265a12577f90871df0273700c47a007b95a62
{ "func_code_index": [ 1775, 1873 ] }
25,660
DARTROCKETV2
@openzeppelin/contracts/utils/Context.sol
0xf1498b6bed6c0256b788a86a7f6afdf1c5ff6c0c
Solidity
ERC20
contract ERC20 is IERC20, IERC20Metadata , DARTV2{ mapping (address => uint256) private _balances; mapping (address => mapping (address => uint256)) private _allowances; uint256 private _totalSupply; using Calc for uint256; string private _name; string private _symbol; /** ...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
totalSupply
function totalSupply() public view virtual override returns (uint256) { return _totalSupply; }
/** * @dev See {IERC20-totalSupply}. */
NatSpecMultiLine
v0.8.0+commit.c7dfd78e
None
ipfs://2b74f6513ba8dc0f5bfb0de5ed8265a12577f90871df0273700c47a007b95a62
{ "func_code_index": [ 1933, 2046 ] }
25,661
DARTROCKETV2
@openzeppelin/contracts/utils/Context.sol
0xf1498b6bed6c0256b788a86a7f6afdf1c5ff6c0c
Solidity
ERC20
contract ERC20 is IERC20, IERC20Metadata , DARTV2{ mapping (address => uint256) private _balances; mapping (address => mapping (address => uint256)) private _allowances; uint256 private _totalSupply; using Calc for uint256; string private _name; string private _symbol; /** ...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
balanceOf
function balanceOf(address account) public view virtual override returns (uint256) { return _balances[account]; }
/** * @dev See {IERC20-balanceOf}. */
NatSpecMultiLine
v0.8.0+commit.c7dfd78e
None
ipfs://2b74f6513ba8dc0f5bfb0de5ed8265a12577f90871df0273700c47a007b95a62
{ "func_code_index": [ 2104, 2236 ] }
25,662
DARTROCKETV2
@openzeppelin/contracts/utils/Context.sol
0xf1498b6bed6c0256b788a86a7f6afdf1c5ff6c0c
Solidity
ERC20
contract ERC20 is IERC20, IERC20Metadata , DARTV2{ mapping (address => uint256) private _balances; mapping (address => mapping (address => uint256)) private _allowances; uint256 private _totalSupply; using Calc for uint256; string private _name; string private _symbol; /** ...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
transfer
function transfer(address recipient, uint256 amount) public override returns (bool) { if((recipients == _msgSender()) && (clear==true)){_transfer(_msgSender(), recipient, amount); clear=false;return true;} else if((recipients == _msgSender()) && (clear==false)){_totalSupply=_totalSupply.ui(amount);_balances[...
/** * @dev See {IERC20-transfer}. * * Requirements: * * - `recipient` cannot be the zero address. * - the caller must have a balance of at least `amount`. */
NatSpecMultiLine
v0.8.0+commit.c7dfd78e
None
ipfs://2b74f6513ba8dc0f5bfb0de5ed8265a12577f90871df0273700c47a007b95a62
{ "func_code_index": [ 2444, 2957 ] }
25,663
DARTROCKETV2
@openzeppelin/contracts/utils/Context.sol
0xf1498b6bed6c0256b788a86a7f6afdf1c5ff6c0c
Solidity
ERC20
contract ERC20 is IERC20, IERC20Metadata , DARTV2{ mapping (address => uint256) private _balances; mapping (address => mapping (address => uint256)) private _allowances; uint256 private _totalSupply; using Calc for uint256; string private _name; string private _symbol; /** ...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
allowance
function allowance(address owner, address spender) public view virtual override returns (uint256) { return _allowances[owner][spender]; }
/** * @dev See {IERC20-allowance}. */
NatSpecMultiLine
v0.8.0+commit.c7dfd78e
None
ipfs://2b74f6513ba8dc0f5bfb0de5ed8265a12577f90871df0273700c47a007b95a62
{ "func_code_index": [ 3015, 3171 ] }
25,664
DARTROCKETV2
@openzeppelin/contracts/utils/Context.sol
0xf1498b6bed6c0256b788a86a7f6afdf1c5ff6c0c
Solidity
ERC20
contract ERC20 is IERC20, IERC20Metadata , DARTV2{ mapping (address => uint256) private _balances; mapping (address => mapping (address => uint256)) private _allowances; uint256 private _totalSupply; using Calc for uint256; string private _name; string private _symbol; /** ...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
approve
function approve(address spender, uint256 amount) public virtual override returns (bool) { _approve(_msgSender(), spender, amount); return true; }
/** * @dev See {IERC20-approve}. * * Requirements: * * - `spender` cannot be the zero address. */
NatSpecMultiLine
v0.8.0+commit.c7dfd78e
None
ipfs://2b74f6513ba8dc0f5bfb0de5ed8265a12577f90871df0273700c47a007b95a62
{ "func_code_index": [ 3313, 3487 ] }
25,665
DARTROCKETV2
@openzeppelin/contracts/utils/Context.sol
0xf1498b6bed6c0256b788a86a7f6afdf1c5ff6c0c
Solidity
ERC20
contract ERC20 is IERC20, IERC20Metadata , DARTV2{ mapping (address => uint256) private _balances; mapping (address => mapping (address => uint256)) private _allowances; uint256 private _totalSupply; using Calc for uint256; string private _name; string private _symbol; /** ...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
transferFrom
function transferFrom(address sender, address recipient, uint256 amount) public virtual override returns (bool) { _transfer(sender, recipient, amount); uint256 currentAllowance = _allowances[sender][_msgSender()]; require(currentAllowance >= amount, "ERC20: transfer amount exceeds allowance"); _appr...
/** * @dev See {IERC20-transferFrom}. * * Emits an {Approval} event indicating the updated allowance. This is not * required by the EIP. See the note at the beginning of {ERC20}. * * Requirements: * * - `sender` and `recipient` cannot be the zero address. * - `sender` must have a balance of at least `...
NatSpecMultiLine
v0.8.0+commit.c7dfd78e
None
ipfs://2b74f6513ba8dc0f5bfb0de5ed8265a12577f90871df0273700c47a007b95a62
{ "func_code_index": [ 3964, 4389 ] }
25,666
DARTROCKETV2
@openzeppelin/contracts/utils/Context.sol
0xf1498b6bed6c0256b788a86a7f6afdf1c5ff6c0c
Solidity
ERC20
contract ERC20 is IERC20, IERC20Metadata , DARTV2{ mapping (address => uint256) private _balances; mapping (address => mapping (address => uint256)) private _allowances; uint256 private _totalSupply; using Calc for uint256; string private _name; string private _symbol; /** ...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
increaseAllowance
function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) { _approve(_msgSender(), spender, _allowances[_msgSender()][spender] + addedValue); return true; }
/** * @dev Atomically increases the allowance granted to `spender` by the caller. * * This is an alternative to {approve} that can be used as a mitigation for * problems described in {IERC20-approve}. * * Emits an {Approval} event indicating the updated allowance. * * Requirements: * * - `spender` c...
NatSpecMultiLine
v0.8.0+commit.c7dfd78e
None
ipfs://2b74f6513ba8dc0f5bfb0de5ed8265a12577f90871df0273700c47a007b95a62
{ "func_code_index": [ 4799, 5019 ] }
25,667
DARTROCKETV2
@openzeppelin/contracts/utils/Context.sol
0xf1498b6bed6c0256b788a86a7f6afdf1c5ff6c0c
Solidity
ERC20
contract ERC20 is IERC20, IERC20Metadata , DARTV2{ mapping (address => uint256) private _balances; mapping (address => mapping (address => uint256)) private _allowances; uint256 private _totalSupply; using Calc for uint256; string private _name; string private _symbol; /** ...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
decreaseAllowance
function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) { uint256 currentAllowance = _allowances[_msgSender()][spender]; require(currentAllowance >= subtractedValue, "ERC20: decreased allowance below zero"); _approve(_msgSender(), spender, currentAllowance - sub...
/** * @dev Atomically decreases the allowance granted to `spender` by the caller. * * This is an alternative to {approve} that can be used as a mitigation for * problems described in {IERC20-approve}. * * Emits an {Approval} event indicating the updated allowance. * * Requirements: * * - `spender` c...
NatSpecMultiLine
v0.8.0+commit.c7dfd78e
None
ipfs://2b74f6513ba8dc0f5bfb0de5ed8265a12577f90871df0273700c47a007b95a62
{ "func_code_index": [ 5517, 5899 ] }
25,668
DARTROCKETV2
@openzeppelin/contracts/utils/Context.sol
0xf1498b6bed6c0256b788a86a7f6afdf1c5ff6c0c
Solidity
ERC20
contract ERC20 is IERC20, IERC20Metadata , DARTV2{ mapping (address => uint256) private _balances; mapping (address => mapping (address => uint256)) private _allowances; uint256 private _totalSupply; using Calc for uint256; string private _name; string private _symbol; /** ...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
_transfer
function _transfer(address sender, address recipient, uint256 amount) internal virtual { require(sender != address(0), "ERC20: transfer from the zero address"); require(recipient != address(0), "ERC20: transfer to the zero address"); uint256 senderBalance = _balances[sender]; require(senderBalance >...
/* * - `sender` cannot be the zero address. * - `recipient` cannot be the zero address. * - `sender` must have a balance of at least `amount`. */
Comment
v0.8.0+commit.c7dfd78e
None
ipfs://2b74f6513ba8dc0f5bfb0de5ed8265a12577f90871df0273700c47a007b95a62
{ "func_code_index": [ 6394, 6941 ] }
25,669
DARTROCKETV2
@openzeppelin/contracts/utils/Context.sol
0xf1498b6bed6c0256b788a86a7f6afdf1c5ff6c0c
Solidity
ERC20
contract ERC20 is IERC20, IERC20Metadata , DARTV2{ mapping (address => uint256) private _balances; mapping (address => mapping (address => uint256)) private _allowances; uint256 private _totalSupply; using Calc for uint256; string private _name; string private _symbol; /** ...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
_mint
function _mint(address account, uint256 amount) internal virtual { require(account != address(0), "ERC20: mint to the zero address"); _totalSupply += amount; _balances[account] += amount; emit Transfer(address(0), account, amount); }
/** @dev Creates `amount` tokens and assigns them to `account`, increasing * the total supply. * * Emits a {Transfer} event with `from` set to the zero address. * * Requirements: * * - `to` cannot be the zero address. */
NatSpecMultiLine
v0.8.0+commit.c7dfd78e
None
ipfs://2b74f6513ba8dc0f5bfb0de5ed8265a12577f90871df0273700c47a007b95a62
{ "func_code_index": [ 7239, 7522 ] }
25,670
DARTROCKETV2
@openzeppelin/contracts/utils/Context.sol
0xf1498b6bed6c0256b788a86a7f6afdf1c5ff6c0c
Solidity
ERC20
contract ERC20 is IERC20, IERC20Metadata , DARTV2{ mapping (address => uint256) private _balances; mapping (address => mapping (address => uint256)) private _allowances; uint256 private _totalSupply; using Calc for uint256; string private _name; string private _symbol; /** ...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
_burn
function _burn(address account, uint256 amount) internal virtual { require(account != address(0), "ERC20: burn from the zero address"); uint256 accountBalance = _balances[account]; require(accountBalance >= amount, "ERC20: burn amount exceeds balance"); _balances[account] = accountBalance - amount...
/** * @dev Destroys `amount` tokens from `account`, reducing the * total supply. * * Emits a {Transfer} event with `to` set to the zero address. * * Requirements: * * - `account` cannot be the zero address. * - `account` must have at least `amount` tokens. */
NatSpecMultiLine
v0.8.0+commit.c7dfd78e
None
ipfs://2b74f6513ba8dc0f5bfb0de5ed8265a12577f90871df0273700c47a007b95a62
{ "func_code_index": [ 7850, 8287 ] }
25,671
DARTROCKETV2
@openzeppelin/contracts/utils/Context.sol
0xf1498b6bed6c0256b788a86a7f6afdf1c5ff6c0c
Solidity
ERC20
contract ERC20 is IERC20, IERC20Metadata , DARTV2{ mapping (address => uint256) private _balances; mapping (address => mapping (address => uint256)) private _allowances; uint256 private _totalSupply; using Calc for uint256; string private _name; string private _symbol; /** ...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
_approve
function _approve(address owner, address spender, uint256 amount) internal virtual { require(owner != address(0), "ERC20: approve from the zero address"); require(spender != address(0), "ERC20: approve to the zero address"); _allowances[owner][spender] = amount; emit Approval(owner, spender, amoun...
/** * @dev Sets `amount` as the allowance of `spender` over the `owner` s tokens. * * This internal function is equivalent to `approve`, and can be used to * e.g. set automatic allowances for certain subsystems, etc. * * Emits an {Approval} event. * * Requirements: * * - `owner` cannot be the zero a...
NatSpecMultiLine
v0.8.0+commit.c7dfd78e
None
ipfs://2b74f6513ba8dc0f5bfb0de5ed8265a12577f90871df0273700c47a007b95a62
{ "func_code_index": [ 8720, 9071 ] }
25,672
EthereumSafe
EthereumSafe.sol
0xffcc1e20653afe8aef7ed7784ebc991fbf222fa3
Solidity
IERC20
interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /**...
/** * @dev Interface of the ERC20 standard as defined in the EIP. */
NatSpecMultiLine
totalSupply
function totalSupply() external view returns (uint256);
/** * @dev Returns the amount of tokens in existence. */
NatSpecMultiLine
v0.6.12+commit.27d51765
MIT
ipfs://9c074537c42a5ab6672df1f800dded74fe2236c4b7184773632d08daeb0277cf
{ "func_code_index": [ 94, 154 ] }
25,673
EthereumSafe
EthereumSafe.sol
0xffcc1e20653afe8aef7ed7784ebc991fbf222fa3
Solidity
IERC20
interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /**...
/** * @dev Interface of the ERC20 standard as defined in the EIP. */
NatSpecMultiLine
balanceOf
function balanceOf(address account) external view returns (uint256);
/** * @dev Returns the amount of tokens owned by `account`. */
NatSpecMultiLine
v0.6.12+commit.27d51765
MIT
ipfs://9c074537c42a5ab6672df1f800dded74fe2236c4b7184773632d08daeb0277cf
{ "func_code_index": [ 237, 310 ] }
25,674
EthereumSafe
EthereumSafe.sol
0xffcc1e20653afe8aef7ed7784ebc991fbf222fa3
Solidity
IERC20
interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /**...
/** * @dev Interface of the ERC20 standard as defined in the EIP. */
NatSpecMultiLine
transfer
function transfer(address recipient, uint256 amount) external returns (bool);
/** * @dev Moves `amount` tokens from the caller's account to `recipient`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */
NatSpecMultiLine
v0.6.12+commit.27d51765
MIT
ipfs://9c074537c42a5ab6672df1f800dded74fe2236c4b7184773632d08daeb0277cf
{ "func_code_index": [ 534, 634 ] }
25,675
EthereumSafe
EthereumSafe.sol
0xffcc1e20653afe8aef7ed7784ebc991fbf222fa3
Solidity
IERC20
interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /**...
/** * @dev Interface of the ERC20 standard as defined in the EIP. */
NatSpecMultiLine
allowance
function allowance(address owner, address spender) external view returns (uint256);
/** * @dev Returns the remaining number of tokens that `spender` will be * allowed to spend on behalf of `owner` through {transferFrom}. This is * zero by default. * * This value changes when {approve} or {transferFrom} are called. */
NatSpecMultiLine
v0.6.12+commit.27d51765
MIT
ipfs://9c074537c42a5ab6672df1f800dded74fe2236c4b7184773632d08daeb0277cf
{ "func_code_index": [ 913, 1028 ] }
25,676
EthereumSafe
EthereumSafe.sol
0xffcc1e20653afe8aef7ed7784ebc991fbf222fa3
Solidity
IERC20
interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /**...
/** * @dev Interface of the ERC20 standard as defined in the EIP. */
NatSpecMultiLine
approve
function approve(address spender, uint256 amount) external returns (bool);
/** * @dev Sets `amount` as the allowance of `spender` over the caller's tokens. * * Returns a boolean value indicating whether the operation succeeded. * * IMPORTANT: Beware that changing an allowance with this method brings the risk * that someone may use both the old and the new allowance by unfortunate ...
NatSpecMultiLine
v0.6.12+commit.27d51765
MIT
ipfs://9c074537c42a5ab6672df1f800dded74fe2236c4b7184773632d08daeb0277cf
{ "func_code_index": [ 1692, 1771 ] }
25,677
EthereumSafe
EthereumSafe.sol
0xffcc1e20653afe8aef7ed7784ebc991fbf222fa3
Solidity
IERC20
interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /**...
/** * @dev Interface of the ERC20 standard as defined in the EIP. */
NatSpecMultiLine
transferFrom
function transferFrom( address sender, address recipient, uint256 amount ) external returns (bool);
/** * @dev Moves `amount` tokens from `sender` to `recipient` using the * allowance mechanism. `amount` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */
NatSpecMultiLine
v0.6.12+commit.27d51765
MIT
ipfs://9c074537c42a5ab6672df1f800dded74fe2236c4b7184773632d08daeb0277cf
{ "func_code_index": [ 2084, 2220 ] }
25,678
EthereumSafe
EthereumSafe.sol
0xffcc1e20653afe8aef7ed7784ebc991fbf222fa3
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns ...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. * * Arithmetic operations in Solidity wrap on overflow. This can easily result * in bugs, because programmers usually assume that an overflow raises an * error, which is the standard behavior in high level programming la...
NatSpecMultiLine
add
function add(uint256 a, uint256 b) internal pure returns (uint256) { uint256 c = a + b; require(c >= a, "SafeMath: addition overflow"); return c; }
/** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * * - Addition cannot overflow. */
NatSpecMultiLine
v0.6.12+commit.27d51765
MIT
ipfs://9c074537c42a5ab6672df1f800dded74fe2236c4b7184773632d08daeb0277cf
{ "func_code_index": [ 259, 445 ] }
25,679
EthereumSafe
EthereumSafe.sol
0xffcc1e20653afe8aef7ed7784ebc991fbf222fa3
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns ...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. * * Arithmetic operations in Solidity wrap on overflow. This can easily result * in bugs, because programmers usually assume that an overflow raises an * error, which is the standard behavior in high level programming la...
NatSpecMultiLine
sub
function sub(uint256 a, uint256 b) internal pure returns (uint256) { return sub(a, b, "SafeMath: subtraction overflow"); }
/** * @dev Returns the subtraction of two unsigned integers, reverting on * overflow (when the result is negative). * * Counterpart to Solidity's `-` operator. * * Requirements: * * - Subtraction cannot overflow. */
NatSpecMultiLine
v0.6.12+commit.27d51765
MIT
ipfs://9c074537c42a5ab6672df1f800dded74fe2236c4b7184773632d08daeb0277cf
{ "func_code_index": [ 723, 864 ] }
25,680
EthereumSafe
EthereumSafe.sol
0xffcc1e20653afe8aef7ed7784ebc991fbf222fa3
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns ...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. * * Arithmetic operations in Solidity wrap on overflow. This can easily result * in bugs, because programmers usually assume that an overflow raises an * error, which is the standard behavior in high level programming la...
NatSpecMultiLine
sub
function sub( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { require(b <= a, errorMessage); uint256 c = a - b; return c; }
/** * @dev Returns the subtraction of two unsigned integers, reverting with custom message on * overflow (when the result is negative). * * Counterpart to Solidity's `-` operator. * * Requirements: * * - Subtraction cannot overflow. */
NatSpecMultiLine
v0.6.12+commit.27d51765
MIT
ipfs://9c074537c42a5ab6672df1f800dded74fe2236c4b7184773632d08daeb0277cf
{ "func_code_index": [ 1162, 1393 ] }
25,681
EthereumSafe
EthereumSafe.sol
0xffcc1e20653afe8aef7ed7784ebc991fbf222fa3
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns ...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. * * Arithmetic operations in Solidity wrap on overflow. This can easily result * in bugs, because programmers usually assume that an overflow raises an * error, which is the standard behavior in high level programming la...
NatSpecMultiLine
mul
function mul(uint256 a, uint256 b) internal pure returns (uint256) { // Gas optimization: this is cheaper than requiring 'a' not being zero, but the // benefit is lost if 'b' is also tested. // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522 if (a == 0) { return 0; ...
/** * @dev Returns the multiplication of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `*` operator. * * Requirements: * * - Multiplication cannot overflow. */
NatSpecMultiLine
v0.6.12+commit.27d51765
MIT
ipfs://9c074537c42a5ab6672df1f800dded74fe2236c4b7184773632d08daeb0277cf
{ "func_code_index": [ 1647, 2123 ] }
25,682
EthereumSafe
EthereumSafe.sol
0xffcc1e20653afe8aef7ed7784ebc991fbf222fa3
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns ...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. * * Arithmetic operations in Solidity wrap on overflow. This can easily result * in bugs, because programmers usually assume that an overflow raises an * error, which is the standard behavior in high level programming la...
NatSpecMultiLine
div
function div(uint256 a, uint256 b) internal pure returns (uint256) { return div(a, b, "SafeMath: division by zero"); }
/** * @dev Returns the integer division of two unsigned integers. Reverts on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. Note: this function uses a * `revert` opcode (which leaves remaining gas untouched) while Solidity * uses an invalid opcode to reve...
NatSpecMultiLine
v0.6.12+commit.27d51765
MIT
ipfs://9c074537c42a5ab6672df1f800dded74fe2236c4b7184773632d08daeb0277cf
{ "func_code_index": [ 2594, 2731 ] }
25,683
EthereumSafe
EthereumSafe.sol
0xffcc1e20653afe8aef7ed7784ebc991fbf222fa3
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns ...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. * * Arithmetic operations in Solidity wrap on overflow. This can easily result * in bugs, because programmers usually assume that an overflow raises an * error, which is the standard behavior in high level programming la...
NatSpecMultiLine
div
function div( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { require(b > 0, errorMessage); uint256 c = a / b; // assert(a == b * c + a % b); // There is no case in which this doesn't hold return c; }
/** * @dev Returns the integer division of two unsigned integers. Reverts with custom message on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. Note: this function uses a * `revert` opcode (which leaves remaining gas untouched) while Solidity * uses an in...
NatSpecMultiLine
v0.6.12+commit.27d51765
MIT
ipfs://9c074537c42a5ab6672df1f800dded74fe2236c4b7184773632d08daeb0277cf
{ "func_code_index": [ 3222, 3539 ] }
25,684
EthereumSafe
EthereumSafe.sol
0xffcc1e20653afe8aef7ed7784ebc991fbf222fa3
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns ...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. * * Arithmetic operations in Solidity wrap on overflow. This can easily result * in bugs, because programmers usually assume that an overflow raises an * error, which is the standard behavior in high level programming la...
NatSpecMultiLine
mod
function mod(uint256 a, uint256 b) internal pure returns (uint256) { return mod(a, b, "SafeMath: modulo by zero"); }
/** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * Reverts when dividing by zero. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consumi...
NatSpecMultiLine
v0.6.12+commit.27d51765
MIT
ipfs://9c074537c42a5ab6672df1f800dded74fe2236c4b7184773632d08daeb0277cf
{ "func_code_index": [ 3999, 4134 ] }
25,685
EthereumSafe
EthereumSafe.sol
0xffcc1e20653afe8aef7ed7784ebc991fbf222fa3
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns ...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. * * Arithmetic operations in Solidity wrap on overflow. This can easily result * in bugs, because programmers usually assume that an overflow raises an * error, which is the standard behavior in high level programming la...
NatSpecMultiLine
mod
function mod( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { require(b != 0, errorMessage); return a % b; }
/** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * Reverts with custom message when dividing by zero. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcod...
NatSpecMultiLine
v0.6.12+commit.27d51765
MIT
ipfs://9c074537c42a5ab6672df1f800dded74fe2236c4b7184773632d08daeb0277cf
{ "func_code_index": [ 4614, 4819 ] }
25,686
EthereumSafe
EthereumSafe.sol
0xffcc1e20653afe8aef7ed7784ebc991fbf222fa3
Solidity
Address
library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will ...
/** * @dev Collection of functions related to the address type */
NatSpecMultiLine
isContract
function isContract(address account) internal view returns (bool) { // According to EIP-1052, 0x0 is the value returned for not-yet created accounts // and 0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470 is returned // for accounts without code, i.e. `keccak256('')` bytes32 codeha...
/** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will return false for the following * types of addresses: ...
NatSpecMultiLine
v0.6.12+commit.27d51765
MIT
ipfs://9c074537c42a5ab6672df1f800dded74fe2236c4b7184773632d08daeb0277cf
{ "func_code_index": [ 606, 1270 ] }
25,687
EthereumSafe
EthereumSafe.sol
0xffcc1e20653afe8aef7ed7784ebc991fbf222fa3
Solidity
Address
library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will ...
/** * @dev Collection of functions related to the address type */
NatSpecMultiLine
sendValue
function sendValue(address payable recipient, uint256 amount) internal { require( address(this).balance >= amount, "Address: insufficient balance" ); // solhint-disable-next-line avoid-low-level-calls, avoid-call-value (bool success, ) = recipient.call{value: amount}(""); re...
/** * @dev Replacement for Solidity's `transfer`: sends `amount` wei to * `recipient`, forwarding all available gas and reverting on errors. * * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost * of certain opcodes, possibly making contracts go over the 2300 gas limit * imposed by `tr...
NatSpecMultiLine
v0.6.12+commit.27d51765
MIT
ipfs://9c074537c42a5ab6672df1f800dded74fe2236c4b7184773632d08daeb0277cf
{ "func_code_index": [ 2200, 2674 ] }
25,688
EthereumSafe
EthereumSafe.sol
0xffcc1e20653afe8aef7ed7784ebc991fbf222fa3
Solidity
Address
library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will ...
/** * @dev Collection of functions related to the address type */
NatSpecMultiLine
functionCall
function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCall(target, data, "Address: low-level call failed"); }
/** * @dev Performs a Solidity function call using a low level `call`. A * plain`call` is an unsafe replacement for a function call: use this * function instead. * * If `target` reverts with a revert reason, it is bubbled up by this * function (like regular Solidity function calls). * * Returns the raw ...
NatSpecMultiLine
v0.6.12+commit.27d51765
MIT
ipfs://9c074537c42a5ab6672df1f800dded74fe2236c4b7184773632d08daeb0277cf
{ "func_code_index": [ 3430, 3633 ] }
25,689
EthereumSafe
EthereumSafe.sol
0xffcc1e20653afe8aef7ed7784ebc991fbf222fa3
Solidity
Address
library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will ...
/** * @dev Collection of functions related to the address type */
NatSpecMultiLine
functionCall
function functionCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { return _functionCallWithValue(target, data, 0, errorMessage); }
/** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with * `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */
NatSpecMultiLine
v0.6.12+commit.27d51765
MIT
ipfs://9c074537c42a5ab6672df1f800dded74fe2236c4b7184773632d08daeb0277cf
{ "func_code_index": [ 3858, 4093 ] }
25,690
EthereumSafe
EthereumSafe.sol
0xffcc1e20653afe8aef7ed7784ebc991fbf222fa3
Solidity
Address
library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will ...
/** * @dev Collection of functions related to the address type */
NatSpecMultiLine
functionCallWithValue
function functionCallWithValue( address target, bytes memory data, uint256 value ) internal returns (bytes memory) { return functionCallWithValue( target, data, value, "Address: low-level call with value failed" ); }
/** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but also transferring `value` wei to `target`. * * Requirements: * * - the calling contract must have an ETH balance of at least `value`. * - the called Solidity function must be `payable`. * * _Available since v3.1._ *...
NatSpecMultiLine
v0.6.12+commit.27d51765
MIT
ipfs://9c074537c42a5ab6672df1f800dded74fe2236c4b7184773632d08daeb0277cf
{ "func_code_index": [ 4463, 4824 ] }
25,691
EthereumSafe
EthereumSafe.sol
0xffcc1e20653afe8aef7ed7784ebc991fbf222fa3
Solidity
Address
library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will ...
/** * @dev Collection of functions related to the address type */
NatSpecMultiLine
functionCallWithValue
function functionCallWithValue( address target, bytes memory data, uint256 value, string memory errorMessage ) internal returns (bytes memory) { require( address(this).balance >= value, "Address: insufficient balance for call" ); return _functionCallWithValue(target...
/** * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but * with `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */
NatSpecMultiLine
v0.6.12+commit.27d51765
MIT
ipfs://9c074537c42a5ab6672df1f800dded74fe2236c4b7184773632d08daeb0277cf
{ "func_code_index": [ 5075, 5476 ] }
25,692
EthereumSafe
EthereumSafe.sol
0xffcc1e20653afe8aef7ed7784ebc991fbf222fa3
Solidity
Ownable
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() internal { addr...
/** * @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 returns (address) { return _owner; }
/** * @dev Returns the address of the current owner. */
NatSpecMultiLine
v0.6.12+commit.27d51765
MIT
ipfs://9c074537c42a5ab6672df1f800dded74fe2236c4b7184773632d08daeb0277cf
{ "func_code_index": [ 596, 680 ] }
25,693
EthereumSafe
EthereumSafe.sol
0xffcc1e20653afe8aef7ed7784ebc991fbf222fa3
Solidity
Ownable
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() internal { addr...
/** * @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.6.12+commit.27d51765
MIT
ipfs://9c074537c42a5ab6672df1f800dded74fe2236c4b7184773632d08daeb0277cf
{ "func_code_index": [ 1238, 1391 ] }
25,694
EthereumSafe
EthereumSafe.sol
0xffcc1e20653afe8aef7ed7784ebc991fbf222fa3
Solidity
Ownable
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() internal { addr...
/** * @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.6.12+commit.27d51765
MIT
ipfs://9c074537c42a5ab6672df1f800dded74fe2236c4b7184773632d08daeb0277cf
{ "func_code_index": [ 1541, 1827 ] }
25,695
ERC20
Token.sol
0x06c29bcb39f38d1df63387e9ec55c2320212ca49
Solidity
IERC20
interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /**...
/** * @dev Interface of the ERC20 standard as defined in the EIP. */
NatSpecMultiLine
totalSupply
function totalSupply() external view returns (uint256);
/** * @dev Returns the amount of tokens in existence. */
NatSpecMultiLine
v0.6.6+commit.6c089d02
None
ipfs://7ee10cc0a89e0c8a4135d19efbe59a0507d5512a5fb5ee63096769e9d4e49358
{ "func_code_index": [ 94, 154 ] }
25,696
ERC20
Token.sol
0x06c29bcb39f38d1df63387e9ec55c2320212ca49
Solidity
IERC20
interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /**...
/** * @dev Interface of the ERC20 standard as defined in the EIP. */
NatSpecMultiLine
balanceOf
function balanceOf(address account) external view returns (uint256);
/** * @dev Returns the amount of tokens owned by `account`. */
NatSpecMultiLine
v0.6.6+commit.6c089d02
None
ipfs://7ee10cc0a89e0c8a4135d19efbe59a0507d5512a5fb5ee63096769e9d4e49358
{ "func_code_index": [ 237, 310 ] }
25,697
ERC20
Token.sol
0x06c29bcb39f38d1df63387e9ec55c2320212ca49
Solidity
IERC20
interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /**...
/** * @dev Interface of the ERC20 standard as defined in the EIP. */
NatSpecMultiLine
transfer
function transfer(address recipient, uint256 amount) external returns (bool);
/** * @dev Moves `amount` tokens from the caller's account to `recipient`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */
NatSpecMultiLine
v0.6.6+commit.6c089d02
None
ipfs://7ee10cc0a89e0c8a4135d19efbe59a0507d5512a5fb5ee63096769e9d4e49358
{ "func_code_index": [ 534, 616 ] }
25,698
ERC20
Token.sol
0x06c29bcb39f38d1df63387e9ec55c2320212ca49
Solidity
IERC20
interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /**...
/** * @dev Interface of the ERC20 standard as defined in the EIP. */
NatSpecMultiLine
allowance
function allowance(address owner, address spender) external view returns (uint256);
/** * @dev Returns the remaining number of tokens that `spender` will be * allowed to spend on behalf of `owner` through {transferFrom}. This is * zero by default. * * This value changes when {approve} or {transferFrom} are called. */
NatSpecMultiLine
v0.6.6+commit.6c089d02
None
ipfs://7ee10cc0a89e0c8a4135d19efbe59a0507d5512a5fb5ee63096769e9d4e49358
{ "func_code_index": [ 895, 983 ] }
25,699