Token
sLabsArt (ART)
ERC-721
Overview
Max Total Supply
1,147 ART
Holders
45
Market
Onchain Market Cap
$0.00
Circulating Supply Market Cap
-
Other Info
Token Contract
Balance
1 ARTLoading...
Loading
Loading...
Loading
Loading...
Loading
Contract Name:
UserMintableCollection
Compiler Version
v0.8.11+commit.d7f03943
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: None pragma solidity 0.8.11; import "@openzeppelin/contracts/token/ERC721/extensions/ERC721URIStorage.sol"; import "@openzeppelin/contracts/utils/structs/EnumerableSet.sol"; import "@openzeppelin/contracts/metatx/ERC2771Context.sol"; import "./Interfaces/IERC2981.sol"; import "./utils/UserMintableCollectionWhitelist.sol"; abstract contract ERC2981 is IERC2981, ERC165 { struct RoyaltyInfo { address receiver; uint96 royaltyFraction; } mapping(uint256 => RoyaltyInfo) private _tokenRoyaltyInfo; uint256 public maxRoyalty; //events event RoyaltyInfoSet( uint256 tokenId, address receiver, uint96 feeNumerator ); event RoyaltyInfoReset(uint256 tokenId); function supportsInterface(bytes4 interfaceId) public view virtual override(IERC165, ERC165) returns (bool) { return interfaceId == type(IERC2981).interfaceId || super.supportsInterface(interfaceId); } /** * @dev Return token royality info. * @dev reciver royalty reciver address */ function royaltyInfo(uint256 _tokenId, uint256 _salePrice) external view virtual override returns (address, uint256) { RoyaltyInfo memory royalty = _tokenRoyaltyInfo[_tokenId]; uint256 royaltyAmount = (_salePrice * royalty.royaltyFraction) / _feeDenominator(); return (royalty.receiver, royaltyAmount); } function _feeDenominator() internal pure virtual returns (uint96) { return 10000; } function _setTokenRoyalty( uint256 tokenId, address receiver, uint96 feeNumerator ) internal virtual { require( feeNumerator <= maxRoyalty, "UserMintableCollection ERC2981: royality must be less than max limit" ); require( feeNumerator <= _feeDenominator(), "UserMintableCollection ERC2981: royalty fee will exceed salePrice" ); require( receiver != address(0), "UserMintableCollection ERC2981: Invalid parameters" ); _tokenRoyaltyInfo[tokenId] = RoyaltyInfo(receiver, feeNumerator); emit RoyaltyInfoSet(tokenId, receiver, feeNumerator); } //after meeting they need to set up function _resetTokenRoyalty(uint256 tokenId) internal virtual { delete _tokenRoyaltyInfo[tokenId]; emit RoyaltyInfoReset(tokenId); } } contract UserMintableCollection is ERC2771Context, ERC721URIStorage, ERC2981, Whitelist { using Address for address; using Strings for uint256; using EnumerableSet for EnumerableSet.UintSet; uint256 public totalSupply; /** * @dev Mapping from holder address to their (enumerable) set of owned tokens. */ mapping(address => EnumerableSet.UintSet) private _holderTokens; address public forwarder; uint256 public counter = 0; /** * @dev Mapping from token to initial owner. */ mapping(uint256 => address) public initialOwner; //events event RoyalityLimitChanged( address _owner, uint256 _oldLimit, uint256 _newLimit ); /** * @dev Sets base URI and initial royalty fees. */ constructor( string memory _name, string memory _symbol, address trustedForwarder ) ERC721(_name, _symbol) ERC2771Context(trustedForwarder) { require( trustedForwarder != address(0), "UserMintableCollection: address must be valid" ); forwarder = trustedForwarder; maxRoyalty = 1000; } /** *@dev modifer to check only owner and forwarder contract */ modifier onlyValidAddress() { require( msg.sender == forwarder || _msgSender() == owner(), "UserMintableCollection: only owner can call this function" ); _; } /** *@dev modifer to check only initial owner can set royality */ modifier onlyInitialOwner(uint256 _tokenId) { require( initialOwner[_tokenId] == _msgSender(), "UserMintableCollection: only initial owner can set the royality" ); _; } /** * @dev returns true if the contract supports the interface with entered bytecode. * @dev 0x2a55205a to test eip 2981 */ function supportsInterface(bytes4 interfaceId) public view override(ERC721, ERC2981) returns (bool) { return super.supportsInterface(interfaceId); } /** * @dev Sets the royalty info for any token. */ function setRoyaltyforToken( uint256 _tokenId, address _receiver, uint96 _feeNumerator ) external onlyInitialOwner(_tokenId) { _setTokenRoyalty(_tokenId, _receiver, _feeNumerator); } /** * @dev Deletes the royalty info for any token. */ function resetTokenRoyalty(uint256 _tokenId) external onlyInitialOwner(_tokenId) { _resetTokenRoyalty(_tokenId); } /** * @dev change the royality limit. */ function changeLimitOfRoyality(uint256 _limit) external onlyOwner { require( _limit <= _feeDenominator(), "UserMintableCollection: royalty must be less than equal to 100%" ); uint256 _oldLimit = maxRoyalty; require( _limit != _oldLimit, "UserMintableCollection: limit must be different" ); maxRoyalty = _limit; emit RoyalityLimitChanged(_msgSender(), _oldLimit, _limit); } /** * @dev Mints single token. * @param _to mint token to address * @param _tokenURI metadata URI * @param _feeNumerator royality percentage (this must be less than max limit) */ function mint( address _to, string memory _tokenURI, uint96 _feeNumerator ) external onlyValidAddress returns (uint256 tokenId) { require( _to != address(0), "UserMintableCollection: _to address not valid" ); require( bytes(_tokenURI).length > 0, "UserMintableCollection: Token URI is not valid" ); counter++; tokenId = counter; totalSupply = totalSupply + 1; _holderTokens[_to].add(tokenId); _safeMint(_to, tokenId); _setTokenURI(tokenId, _tokenURI); if (_feeNumerator != 0) { _setTokenRoyalty(tokenId, _to, _feeNumerator); } initialOwner[tokenId] = _to; } /** *@dev owner can change forwerder address */ function changeForwarder(address _newOwner) external onlyOwner { forwarder = _newOwner; } /** * @dev Burns token of entered token id. */ function burn(uint256 _tokenId) external { require( _isApprovedOrOwner(_msgSender(), _tokenId), "UserMintableCollection: burn caller is not owner nor approved" ); address tokenOwner = ownerOf(_tokenId); _holderTokens[tokenOwner].remove(_tokenId); delete initialOwner[_tokenId]; _burn(_tokenId); } /** * @dev disable approve. */ function approve(address to, uint256 tokenId) public override { if (to.isContract()) { require( whitelisted(to), "UserMintableCollection: Only whitelist is allowed" ); } super.approve(to, tokenId); } /** * @dev disable owner to set approve for those operator not in whitelist. */ function setApprovalForAll(address operator, bool approved) public override { if (operator.isContract()) { require( whitelisted(operator), "UserMintableCollection: Only whitelist is allowed" ); } super.setApprovalForAll(operator, approved); } /** * @dev Transfers token from 'from' address to 'to' address. */ function transferFrom( address from, address to, uint256 tokenId ) public override { require( _isApprovedOrOwner(_msgSender(), tokenId), "UserMintableCollection: transfer caller is not owner nor approved" ); _holderTokens[from].remove(tokenId); _holderTokens[to].add(tokenId); _transfer(from, to, tokenId); } /** * @dev Safe transfers token from 'from' address to 'to' address. */ function safeTransferFrom( address from, address to, uint256 tokenId ) public override { safeTransferFrom(from, to, tokenId, ""); } /** * @dev Safe transfers token from 'from' address to 'to' address. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes memory _data ) public override { require( _isApprovedOrOwner(_msgSender(), tokenId), "UserMintableCollection: transfer caller is not owner nor approved" ); _holderTokens[from].remove(tokenId); _holderTokens[to].add(tokenId); _safeTransfer(from, to, tokenId, _data); } function _msgSender() internal view override(Context, ERC2771Context) returns (address sender) { sender = ERC2771Context._msgSender(); } function _msgData() internal view override(Context, ERC2771Context) returns (bytes memory) { return ERC2771Context._msgData(); } /** * @dev Returns the token id from the array of tokens owned by the argument address present at the argument index. */ function tokenOfOwnerByIndex(address _address, uint256 _index) external view returns (uint256) { return _holderTokens[_address].at(_index); } /** * @dev Returns an array of tokens owned by the argument address. */ function getTokens(address _address) external view returns (uint256[] memory) { return _holderTokens[_address].values(); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC721/extensions/ERC721URIStorage.sol) pragma solidity ^0.8.0; import "../ERC721.sol"; /** * @dev ERC721 token with storage based token URI management. */ 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 (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 URI. if (bytes(base).length == 0) { return _tokenURI; } // If both are set, concatenate the baseURI and tokenURI (via abi.encodePacked). if (bytes(_tokenURI).length > 0) { return string(abi.encodePacked(base, _tokenURI)); } return super.tokenURI(tokenId); } /** * @dev Sets `_tokenURI` as the tokenURI of `tokenId`. * * Requirements: * * - `tokenId` must exist. */ function _setTokenURI(uint256 tokenId, string memory _tokenURI) internal virtual { require(_exists(tokenId), "ERC721URIStorage: URI set of nonexistent token"); _tokenURIs[tokenId] = _tokenURI; } /** * @dev Destroys `tokenId`. * The approval is cleared when the token is burned. * * Requirements: * * - `tokenId` must exist. * * Emits a {Transfer} event. */ function _burn(uint256 tokenId) internal virtual override { super._burn(tokenId); if (bytes(_tokenURIs[tokenId]).length != 0) { delete _tokenURIs[tokenId]; } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/structs/EnumerableSet.sol) pragma solidity ^0.8.0; /** * @dev Library for managing * https://en.wikipedia.org/wiki/Set_(abstract_data_type)[sets] of primitive * types. * * Sets have the following properties: * * - Elements are added, removed, and checked for existence in constant time * (O(1)). * - Elements are enumerated in O(n). No guarantees are made on the ordering. * * ``` * contract Example { * // Add the library methods * using EnumerableSet for EnumerableSet.AddressSet; * * // Declare a set state variable * EnumerableSet.AddressSet private mySet; * } * ``` * * As of v3.3.0, sets of type `bytes32` (`Bytes32Set`), `address` (`AddressSet`) * and `uint256` (`UintSet`) are supported. */ library EnumerableSet { // To implement this library for multiple types with as little code // repetition as possible, we write it in terms of a generic Set type with // bytes32 values. // The Set implementation uses private functions, and user-facing // implementations (such as AddressSet) are just wrappers around the // underlying Set. // This means that we can only create new EnumerableSets for types that fit // in bytes32. struct Set { // Storage of set values bytes32[] _values; // Position of the value in the `values` array, plus 1 because index 0 // means a value is not in the set. mapping(bytes32 => uint256) _indexes; } /** * @dev Add a value to a set. O(1). * * Returns true if the value was added to the set, that is if it was not * already present. */ function _add(Set storage set, bytes32 value) private returns (bool) { if (!_contains(set, value)) { set._values.push(value); // The value is stored at length-1, but we add 1 to all indexes // and use 0 as a sentinel value set._indexes[value] = set._values.length; return true; } else { return false; } } /** * @dev Removes a value from a set. O(1). * * Returns true if the value was removed from the set, that is if it was * present. */ function _remove(Set storage set, bytes32 value) private returns (bool) { // We read and store the value's index to prevent multiple reads from the same storage slot uint256 valueIndex = set._indexes[value]; if (valueIndex != 0) { // Equivalent to contains(set, value) // To delete an element from the _values array in O(1), we swap the element to delete with the last one in // the array, and then remove the last element (sometimes called as 'swap and pop'). // This modifies the order of the array, as noted in {at}. uint256 toDeleteIndex = valueIndex - 1; uint256 lastIndex = set._values.length - 1; if (lastIndex != toDeleteIndex) { bytes32 lastvalue = set._values[lastIndex]; // Move the last value to the index where the value to delete is set._values[toDeleteIndex] = lastvalue; // Update the index for the moved value set._indexes[lastvalue] = valueIndex; // Replace lastvalue's index to valueIndex } // Delete the slot where the moved value was stored set._values.pop(); // Delete the index for the deleted slot delete set._indexes[value]; return true; } else { return false; } } /** * @dev Returns true if the value is in the set. O(1). */ function _contains(Set storage set, bytes32 value) private view returns (bool) { return set._indexes[value] != 0; } /** * @dev Returns the number of values on the set. O(1). */ function _length(Set storage set) private view returns (uint256) { return set._values.length; } /** * @dev Returns the value stored at position `index` in the set. O(1). * * Note that there are no guarantees on the ordering of values inside the * array, and it may change when more values are added or removed. * * Requirements: * * - `index` must be strictly less than {length}. */ function _at(Set storage set, uint256 index) private view returns (bytes32) { return set._values[index]; } /** * @dev Return the entire set in an array * * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that * this function has an unbounded cost, and using it as part of a state-changing function may render the function * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. */ function _values(Set storage set) private view returns (bytes32[] memory) { return set._values; } // Bytes32Set struct Bytes32Set { Set _inner; } /** * @dev Add a value to a set. O(1). * * Returns true if the value was added to the set, that is if it was not * already present. */ function add(Bytes32Set storage set, bytes32 value) internal returns (bool) { return _add(set._inner, value); } /** * @dev Removes a value from a set. O(1). * * Returns true if the value was removed from the set, that is if it was * present. */ function remove(Bytes32Set storage set, bytes32 value) internal returns (bool) { return _remove(set._inner, value); } /** * @dev Returns true if the value is in the set. O(1). */ function contains(Bytes32Set storage set, bytes32 value) internal view returns (bool) { return _contains(set._inner, value); } /** * @dev Returns the number of values in the set. O(1). */ function length(Bytes32Set storage set) internal view returns (uint256) { return _length(set._inner); } /** * @dev Returns the value stored at position `index` in the set. O(1). * * Note that there are no guarantees on the ordering of values inside the * array, and it may change when more values are added or removed. * * Requirements: * * - `index` must be strictly less than {length}. */ function at(Bytes32Set storage set, uint256 index) internal view returns (bytes32) { return _at(set._inner, index); } /** * @dev Return the entire set in an array * * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that * this function has an unbounded cost, and using it as part of a state-changing function may render the function * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. */ function values(Bytes32Set storage set) internal view returns (bytes32[] memory) { return _values(set._inner); } // AddressSet struct AddressSet { Set _inner; } /** * @dev Add a value to a set. O(1). * * Returns true if the value was added to the set, that is if it was not * already present. */ function add(AddressSet storage set, address value) internal returns (bool) { return _add(set._inner, bytes32(uint256(uint160(value)))); } /** * @dev Removes a value from a set. O(1). * * Returns true if the value was removed from the set, that is if it was * present. */ function remove(AddressSet storage set, address value) internal returns (bool) { return _remove(set._inner, bytes32(uint256(uint160(value)))); } /** * @dev Returns true if the value is in the set. O(1). */ function contains(AddressSet storage set, address value) internal view returns (bool) { return _contains(set._inner, bytes32(uint256(uint160(value)))); } /** * @dev Returns the number of values in the set. O(1). */ function length(AddressSet storage set) internal view returns (uint256) { return _length(set._inner); } /** * @dev Returns the value stored at position `index` in the set. O(1). * * Note that there are no guarantees on the ordering of values inside the * array, and it may change when more values are added or removed. * * Requirements: * * - `index` must be strictly less than {length}. */ function at(AddressSet storage set, uint256 index) internal view returns (address) { return address(uint160(uint256(_at(set._inner, index)))); } /** * @dev Return the entire set in an array * * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that * this function has an unbounded cost, and using it as part of a state-changing function may render the function * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. */ function values(AddressSet storage set) internal view returns (address[] memory) { bytes32[] memory store = _values(set._inner); address[] memory result; assembly { result := store } return result; } // UintSet struct UintSet { Set _inner; } /** * @dev Add a value to a set. O(1). * * Returns true if the value was added to the set, that is if it was not * already present. */ function add(UintSet storage set, uint256 value) internal returns (bool) { return _add(set._inner, bytes32(value)); } /** * @dev Removes a value from a set. O(1). * * Returns true if the value was removed from the set, that is if it was * present. */ function remove(UintSet storage set, uint256 value) internal returns (bool) { return _remove(set._inner, bytes32(value)); } /** * @dev Returns true if the value is in the set. O(1). */ function contains(UintSet storage set, uint256 value) internal view returns (bool) { return _contains(set._inner, bytes32(value)); } /** * @dev Returns the number of values on the set. O(1). */ function length(UintSet storage set) internal view returns (uint256) { return _length(set._inner); } /** * @dev Returns the value stored at position `index` in the set. O(1). * * Note that there are no guarantees on the ordering of values inside the * array, and it may change when more values are added or removed. * * Requirements: * * - `index` must be strictly less than {length}. */ function at(UintSet storage set, uint256 index) internal view returns (uint256) { return uint256(_at(set._inner, index)); } /** * @dev Return the entire set in an array * * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that * this function has an unbounded cost, and using it as part of a state-changing function may render the function * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. */ function values(UintSet storage set) internal view returns (uint256[] memory) { bytes32[] memory store = _values(set._inner); uint256[] memory result; assembly { result := store } return result; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.5.0) (metatx/ERC2771Context.sol) pragma solidity ^0.8.9; import "../utils/Context.sol"; /** * @dev Context variant with ERC2771 support. */ abstract contract ERC2771Context is Context { /// @custom:oz-upgrades-unsafe-allow state-variable-immutable address private immutable _trustedForwarder; /// @custom:oz-upgrades-unsafe-allow constructor constructor(address trustedForwarder) { _trustedForwarder = trustedForwarder; } function isTrustedForwarder(address forwarder) public view virtual returns (bool) { return forwarder == _trustedForwarder; } function _msgSender() internal view virtual override returns (address sender) { if (isTrustedForwarder(msg.sender)) { // The assembly code is more direct than the Solidity version using `abi.decode`. assembly { sender := shr(96, calldataload(sub(calldatasize(), 20))) } } else { return super._msgSender(); } } function _msgData() internal view virtual override returns (bytes calldata) { if (isTrustedForwarder(msg.sender)) { return msg.data[:msg.data.length - 20]; } else { return super._msgData(); } } }
// SPDX-License-Identifier: None pragma solidity 0.8.11; import "@openzeppelin/contracts/utils/introspection/IERC165.sol"; /// /// @dev Interface for the NFT Royalty Standard /// interface IERC2981 is IERC165 { /// ERC165 bytes to add to interface array - set in parent contract /// implementing this standard /// /// bytes4(keccak256("royaltyInfo(uint256,uint256)")) == 0x2a55205a /// bytes4 private constant _INTERFACE_ID_ERC2981 = 0x2a55205a; /// _registerInterface(_INTERFACE_ID_ERC2981); /// @notice Called with the sale price to determine how much royalty // is owed and to whom. /// @param _tokenId - the NFT asset queried for royalty information /// @param _salePrice - the sale price of the NFT asset specified by _tokenId /// @return receiver - address of who should be sent the royalty payment /// @return royaltyAmount - the royalty payment amount for _salePrice function royaltyInfo(uint256 _tokenId, uint256 _salePrice) external view returns (address receiver, uint256 royaltyAmount); }
// SPDX-License-Identifier: None pragma solidity 0.8.11; import "@openzeppelin/contracts/access/Ownable.sol"; contract Whitelist is Ownable { mapping(address => bool) private whitelistedMap; event Whitelisted(address indexed account, bool isWhitelisted); /** * @dev Whitelist MarketPlace address and any contract address to approve. */ function addAddress(address _address) external onlyOwner { require( whitelistedMap[_address] != true, "UserMintableCollection WhiteList: address already whitelisted" ); whitelistedMap[_address] = true; emit Whitelisted(_address, true); } /** * @dev remove from Whitelist. */ function removeAddress(address _address) external onlyOwner { require( whitelistedMap[_address] != false, "UserMintableCollection WhiteList: address already removed" ); whitelistedMap[_address] = false; emit Whitelisted(_address, false); } /** * @dev check whitelisted or not. */ function whitelisted(address _address) public view returns (bool) { return whitelistedMap[_address]; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.5.0) (token/ERC721/ERC721.sol) pragma solidity ^0.8.0; import "./IERC721.sol"; import "./IERC721Receiver.sol"; import "./extensions/IERC721Metadata.sol"; import "../../utils/Address.sol"; import "../../utils/Context.sol"; import "../../utils/Strings.sol"; import "../../utils/introspection/ERC165.sol"; /** * @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}. */ 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 _owners; // Mapping owner address to token count mapping(address => uint256) private _balances; // Mapping from token ID to approved address mapping(uint256 => address) private _tokenApprovals; // Mapping from owner to operator approvals mapping(address => mapping(address => bool)) private _operatorApprovals; /** * @dev Initializes the contract by setting a `name` and a `symbol` to the token collection. */ constructor(string memory name_, string memory symbol_) { _name = name_; _symbol = symbol_; } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { return interfaceId == type(IERC721).interfaceId || interfaceId == type(IERC721Metadata).interfaceId || super.supportsInterface(interfaceId); } /** * @dev See {IERC721-balanceOf}. */ function balanceOf(address owner) public view virtual override returns (uint256) { require(owner != address(0), "ERC721: balance query for the zero address"); return _balances[owner]; } /** * @dev See {IERC721-ownerOf}. */ function ownerOf(uint256 tokenId) public view virtual override returns (address) { address owner = _owners[tokenId]; require(owner != address(0), "ERC721: owner query for nonexistent token"); return owner; } /** * @dev See {IERC721Metadata-name}. */ function name() public view virtual override returns (string memory) { return _name; } /** * @dev See {IERC721Metadata-symbol}. */ function symbol() public view virtual override returns (string memory) { return _symbol; } /** * @dev See {IERC721Metadata-tokenURI}. */ function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { require(_exists(tokenId), "ERC721Metadata: URI query for nonexistent token"); string memory baseURI = _baseURI(); return bytes(baseURI).length > 0 ? string(abi.encodePacked(baseURI, tokenId.toString())) : ""; } /** * @dev Base URI for computing {tokenURI}. If set, the resulting URI for each * token will be the concatenation of the `baseURI` and the `tokenId`. Empty * by default, can be overriden in child contracts. */ function _baseURI() internal view virtual returns (string memory) { return ""; } /** * @dev See {IERC721-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 approved for all" ); _approve(to, tokenId); } /** * @dev See {IERC721-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-setApprovalForAll}. */ function setApprovalForAll(address operator, bool approved) public virtual override { _setApprovalForAll(_msgSender(), operator, approved); } /** * @dev See {IERC721-isApprovedForAll}. */ function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { return _operatorApprovals[owner][operator]; } /** * @dev See {IERC721-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-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 tokenId ) public virtual override { safeTransferFrom(from, to, tokenId, ""); } /** * @dev See {IERC721-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 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 equivalent to {safeTransferFrom}, and can be used to e.g. * implement alternative mechanisms to perform token transfer, such as signature-based. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ 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 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`). */ function _exists(uint256 tokenId) internal view virtual returns (bool) { return _owners[tokenId] != address(0); } /** * @dev Returns whether `spender` is allowed to manage `tokenId`. * * Requirements: * * - `tokenId` must exist. */ 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, spender)); } /** * @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. */ function _safeMint(address to, uint256 tokenId) internal virtual { _safeMint(to, tokenId, ""); } /** * @dev Same as {xref-ERC721-_safeMint-address-uint256-}[`_safeMint`], with an additional `data` parameter which is * forwarded in {IERC721Receiver-onERC721Received} to contract recipients. */ 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 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. */ 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 Transfer(address(0), to, tokenId); _afterTokenTransfer(address(0), to, tokenId); } /** * @dev Destroys `tokenId`. * The approval is cleared when the token is burned. * * Requirements: * * - `tokenId` must exist. * * Emits a {Transfer} event. */ 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), tokenId); _afterTokenTransfer(owner, address(0), tokenId); } /** * @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. */ 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); // Clear approvals from the previous owner _approve(address(0), tokenId); _balances[from] -= 1; _balances[to] += 1; _owners[tokenId] = to; emit Transfer(from, to, tokenId); _afterTokenTransfer(from, to, tokenId); } /** * @dev Approve `to` to operate on `tokenId` * * Emits a {Approval} event. */ function _approve(address to, uint256 tokenId) internal virtual { _tokenApprovals[tokenId] = to; emit Approval(ERC721.ownerOf(tokenId), to, tokenId); } /** * @dev Approve `operator` to operate on all of `owner` tokens * * Emits a {ApprovalForAll} event. */ 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 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 tokenId uint256 ID of the token to be transferred * @param _data bytes optional data to send along with the call * @return bool whether the call correctly returned the expected magic value */ 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 == IERC721Receiver.onERC721Received.selector; } catch (bytes memory reason) { if (reason.length == 0) { revert("ERC721: transfer to non ERC721Receiver implementer"); } else { assembly { revert(add(32, reason), mload(reason)) } } } } else { return true; } } /** * @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, ``from``'s `tokenId` will be burned. * - `from` and `to` are never both zero. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _beforeTokenTransfer( 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 Hooks]. */ function _afterTokenTransfer( address from, address to, uint256 tokenId ) internal virtual {} }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC721/IERC721.sol) pragma solidity ^0.8.0; import "../../utils/introspection/IERC165.sol"; /** * @dev Required interface of an ERC721 compliant contract. */ interface IERC721 is IERC165 { /** * @dev Emitted when `tokenId` token is transferred from `from` to `to`. */ event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token. */ event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets. */ event ApprovalForAll(address indexed owner, address indexed operator, bool approved); /** * @dev Returns the number of tokens in ``owner``'s account. */ function balanceOf(address owner) external view returns (uint256 balance); /** * @dev Returns the owner of the `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function ownerOf(uint256 tokenId) external view returns (address owner); /** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be have been allowed to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Transfers `tokenId` token from `from` to `to`. * * WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * * Emits a {Transfer} event. */ function transferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Gives permission to `to` to transfer `tokenId` token to another account. * The approval is cleared when the token is transferred. * * Only a single account can be approved at a time, so approving the zero address clears previous approvals. * * Requirements: * * - The caller must own the token or be an approved operator. * - `tokenId` must exist. * * Emits an {Approval} event. */ function approve(address to, uint256 tokenId) external; /** * @dev Returns the account approved for `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function getApproved(uint256 tokenId) external view returns (address operator); /** * @dev Approve or remove `operator` as an operator for the caller. * Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller. * * Requirements: * * - The `operator` cannot be the caller. * * Emits an {ApprovalForAll} event. */ function setApprovalForAll(address operator, bool _approved) external; /** * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`. * * See {setApprovalForAll} */ function isApprovedForAll(address owner, address operator) external view returns (bool); /** * @dev Safely transfers `tokenId` token from `from` to `to`. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes calldata data ) external; }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC721/IERC721Receiver.sol) pragma solidity ^0.8.0; /** * @title ERC721 token receiver interface * @dev Interface for any contract that wants to support safeTransfers * from ERC721 asset contracts. */ interface IERC721Receiver { /** * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom} * by `operator` from `from`, this function is called. * * It must return its Solidity selector to confirm the token transfer. * If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted. * * The selector can be obtained in Solidity with `IERC721.onERC721Received.selector`. */ function onERC721Received( address operator, address from, uint256 tokenId, bytes calldata data ) external returns (bytes4); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC721/extensions/IERC721Metadata.sol) pragma solidity ^0.8.0; import "../IERC721.sol"; /** * @title ERC-721 Non-Fungible Token Standard, optional metadata extension * @dev See https://eips.ethereum.org/EIPS/eip-721 */ interface IERC721Metadata is IERC721 { /** * @dev Returns the token collection name. */ function name() external view returns (string memory); /** * @dev Returns the token collection symbol. */ function symbol() external view returns (string memory); /** * @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token. */ function tokenURI(uint256 tokenId) external view returns (string memory); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.5.0) (utils/Address.sol) pragma solidity ^0.8.1; /** * @dev Collection of functions related to the address type */ 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 return false for the following * types of addresses: * * - an externally-owned account * - a contract in construction * - an address where a contract will be created * - an address where a contract lived, but was destroyed * ==== * * [IMPORTANT] * ==== * You shouldn't rely on `isContract` to protect against flash loan attacks! * * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract * constructor. * ==== */ function isContract(address account) internal view returns (bool) { // This method relies on extcodesize/address.code.length, which returns 0 // for contracts in construction, since the code is only stored at the end // of the constructor execution. return account.code.length > 0; } /** * @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 `transfer`, making them unable to receive funds via * `transfer`. {sendValue} removes this limitation. * * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more]. * * IMPORTANT: because control is transferred to `recipient`, care must be * taken to not create reentrancy vulnerabilities. Consider using * {ReentrancyGuard} or the * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. */ function sendValue(address payable recipient, uint256 amount) internal { require(address(this).balance >= amount, "Address: insufficient balance"); (bool success, ) = recipient.call{value: amount}(""); require(success, "Address: unable to send value, recipient may have reverted"); } /** * @dev 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 returned data. To convert to the expected return value, * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`]. * * Requirements: * * - `target` must be a contract. * - calling `target` with `data` must not revert. * * _Available since v3.1._ */ function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCall(target, data, "Address: low-level call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with * `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ 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 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._ */ 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-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but * with `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value, string memory errorMessage ) internal returns (bytes memory) { require(address(this).balance >= value, "Address: insufficient balance for call"); require(isContract(target), "Address: call to non-contract"); (bool success, bytes memory returndata) = target.call{value: value}(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { return functionStaticCall(target, data, "Address: low-level static call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall( address target, bytes memory data, string memory errorMessage ) internal view returns (bytes memory) { require(isContract(target), "Address: static call to non-contract"); (bool success, bytes memory returndata) = target.staticcall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { return functionDelegateCall(target, data, "Address: low-level delegate call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { require(isContract(target), "Address: delegate call to non-contract"); (bool success, bytes memory returndata) = target.delegatecall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the * revert reason using the provided one. * * _Available since v4.3._ */ function verifyCallResult( bool success, bytes memory returndata, string memory errorMessage ) internal pure returns (bytes memory) { if (success) { return returndata; } else { // Look for revert reason and bubble it up if present if (returndata.length > 0) { // The easiest way to bubble the revert reason is using memory via assembly assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert(errorMessage); } } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Context.sol) pragma solidity ^0.8.0; /** * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with meta-transactions the account sending and * paying for execution may not be the actual sender (as far as an application * is concerned). * * This contract is only required for intermediate, library-like contracts. */ abstract contract Context { function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Strings.sol) pragma solidity ^0.8.0; /** * @dev String operations. */ library Strings { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { // Inspired by OraclizeAPI's implementation - MIT licence // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol if (value == 0) { return "0"; } uint256 temp = value; uint256 digits; while (temp != 0) { digits++; temp /= 10; } bytes memory buffer = new bytes(digits); while (value != 0) { digits -= 1; buffer[digits] = bytes1(uint8(48 + uint256(value % 10))); value /= 10; } return string(buffer); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */ function toHexString(uint256 value) internal pure returns (string memory) { if (value == 0) { return "0x00"; } uint256 temp = value; uint256 length = 0; while (temp != 0) { length++; temp >>= 8; } return toHexString(value, length); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. */ function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { bytes memory buffer = new bytes(2 * length + 2); buffer[0] = "0"; buffer[1] = "x"; for (uint256 i = 2 * length + 1; i > 1; --i) { buffer[i] = _HEX_SYMBOLS[value & 0xf]; value >>= 4; } require(value == 0, "Strings: hex length insufficient"); return string(buffer); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/introspection/ERC165.sol) pragma solidity ^0.8.0; import "./IERC165.sol"; /** * @dev Implementation of the {IERC165} interface. * * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check * for the additional interface id that will be supported. For example: * * ```solidity * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { * return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId); * } * ``` * * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation. */ abstract contract ERC165 is IERC165 { /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IERC165).interfaceId; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol) pragma solidity ^0.8.0; /** * @dev Interface of the ERC165 standard, as defined in the * https://eips.ethereum.org/EIPS/eip-165[EIP]. * * Implementers can declare support of contract interfaces, which can then be * queried by others ({ERC165Checker}). * * For an implementation, see {ERC165}. */ interface IERC165 { /** * @dev Returns true if this contract implements the interface defined by * `interfaceId`. See the corresponding * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section] * to learn more about how these ids are created. * * This function call must use less than 30 000 gas. */ function supportsInterface(bytes4 interfaceId) external view returns (bool); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (access/Ownable.sol) pragma solidity ^0.8.0; import "../utils/Context.sol"; /** * @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}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ 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 Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { require(owner() == _msgSender(), "Ownable: caller is not the owner"); _; } /** * @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. */ function renounceOwnership() public virtual onlyOwner { _transferOwnership(address(0)); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ 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`). * Internal function without access restriction. */ function _transferOwnership(address newOwner) internal virtual { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
{ "optimizer": { "enabled": true, "runs": 200 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "libraries": {} }
[{"inputs":[{"internalType":"string","name":"_name","type":"string"},{"internalType":"string","name":"_symbol","type":"string"},{"internalType":"address","name":"trustedForwarder","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_owner","type":"address"},{"indexed":false,"internalType":"uint256","name":"_oldLimit","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_newLimit","type":"uint256"}],"name":"RoyalityLimitChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"RoyaltyInfoReset","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint96","name":"feeNumerator","type":"uint96"}],"name":"RoyaltyInfoSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"bool","name":"isWhitelisted","type":"bool"}],"name":"Whitelisted","type":"event"},{"inputs":[{"internalType":"address","name":"_address","type":"address"}],"name":"addAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_newOwner","type":"address"}],"name":"changeForwarder","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_limit","type":"uint256"}],"name":"changeLimitOfRoyality","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"counter","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"forwarder","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_address","type":"address"}],"name":"getTokens","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"initialOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"forwarder","type":"address"}],"name":"isTrustedForwarder","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxRoyalty","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_to","type":"address"},{"internalType":"string","name":"_tokenURI","type":"string"},{"internalType":"uint96","name":"_feeNumerator","type":"uint96"}],"name":"mint","outputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_address","type":"address"}],"name":"removeAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"resetTokenRoyalty","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"},{"internalType":"uint256","name":"_salePrice","type":"uint256"}],"name":"royaltyInfo","outputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"_data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"},{"internalType":"address","name":"_receiver","type":"address"},{"internalType":"uint96","name":"_feeNumerator","type":"uint96"}],"name":"setRoyaltyforToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_address","type":"address"},{"internalType":"uint256","name":"_index","type":"uint256"}],"name":"tokenOfOwnerByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_address","type":"address"}],"name":"whitelisted","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"}]
Contract Creation Code
60a06040526000600e553480156200001657600080fd5b50604051620031733803806200317383398101604081905262000039916200034f565b6001600160a01b0381166080528251839083906200005f906000906020850190620001dc565b50805162000075906001906020840190620001dc565b505050620000926200008c6200013160201b60201c565b6200014d565b6001600160a01b038116620001035760405162461bcd60e51b815260206004820152602d60248201527f557365724d696e7461626c65436f6c6c656374696f6e3a20616464726573732060448201526c1b5d5cdd081899481d985b1a59609a1b606482015260840160405180910390fd5b600d80546001600160a01b0319166001600160a01b039290921691909117905550506103e860085562000419565b6000620001486200019f60201b620014761760201c565b905090565b600980546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6080516000906001600160a01b0316331415620001c3575060131936013560601c90565b62000148620001d860201b620014c01760201c565b3390565b828054620001ea90620003dc565b90600052602060002090601f0160209004810192826200020e576000855562000259565b82601f106200022957805160ff191683800117855562000259565b8280016001018555821562000259579182015b82811115620002595782518255916020019190600101906200023c565b50620002679291506200026b565b5090565b5b808211156200026757600081556001016200026c565b634e487b7160e01b600052604160045260246000fd5b600082601f830112620002aa57600080fd5b81516001600160401b0380821115620002c757620002c762000282565b604051601f8301601f19908116603f01168101908282118183101715620002f257620002f262000282565b816040528381526020925086838588010111156200030f57600080fd5b600091505b8382101562000333578582018301518183018401529082019062000314565b83821115620003455760008385830101525b9695505050505050565b6000806000606084860312156200036557600080fd5b83516001600160401b03808211156200037d57600080fd5b6200038b8783880162000298565b94506020860151915080821115620003a257600080fd5b50620003b18682870162000298565b604086015190935090506001600160a01b0381168114620003d157600080fd5b809150509250925092565b600181811c90821680620003f157607f821691505b602082108114156200041357634e487b7160e01b600052602260045260246000fd5b50919050565b608051612d376200043c600039600081816103c2015261147a0152612d376000f3fe608060405234801561001057600080fd5b50600436106102065760003560e01c806361bc221a1161011a5780638da5cb5b116100ad578063c87b56dd1161007c578063c87b56dd146104aa578063d936547e146104bd578063e985e9c5146104e9578063f2fde38b14610525578063f645d4f91461053857600080fd5b80638da5cb5b1461046b57806395d89b411461047c578063a22cb46514610484578063b88d4fde1461049757600080fd5b8063715018a6116100e9578063715018a61461042a5780637b17b7a814610432578063807e9bae146104455780638a616bc01461045857600080fd5b806361bc221a146103f25780636352211e146103fb578063674a12c71461040e57806370a082311461041757600080fd5b80632a55205a1161019d57806342842e0e1161016c57806342842e0e1461035957806342966c681461036c578063450efe211461037f5780634ba79dfe1461039f578063572b6c05146103b257600080fd5b80632a55205a146102ee5780632f745c591461032057806338eada1c14610333578063415a21871461034657600080fd5b80630fee7d2a116101d95780630fee7d2a1461028857806318160ddd1461029b578063207ce2fe146102b257806323b872dd146102db57600080fd5b806301ffc9a71461020b57806306fdde0314610233578063081812fc14610248578063095ea7b314610273575b600080fd5b61021e6102193660046125e1565b61054b565b60405190151581526020015b60405180910390f35b61023b61055c565b60405161022a9190612656565b61025b610256366004612669565b6105ee565b6040516001600160a01b03909116815260200161022a565b61028661028136600461269e565b61067b565b005b610286610296366004612669565b6106d1565b6102a4600b5481565b60405190815260200161022a565b61025b6102c0366004612669565b600f602052600090815260409020546001600160a01b031681565b6102866102e93660046126c8565b610857565b6103016102fc366004612704565b6108da565b604080516001600160a01b03909316835260208301919091520161022a565b6102a461032e36600461269e565b610940565b610286610341366004612726565b610969565b610286610354366004612726565b610aa4565b6102866103673660046126c8565b610b0f565b61028661037a366004612669565b610b2a565b61039261038d366004612726565b610bfd565b60405161022a9190612741565b6102866103ad366004612726565b610c21565b61021e6103c0366004612726565b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0390811691161490565b6102a4600e5481565b61025b610409366004612669565b610d47565b6102a460085481565b6102a4610425366004612726565b610dbe565b610286610e45565b6102a4610440366004612828565b610e9a565b61028661045336600461289a565b6110c7565b610286610466366004612669565b61111a565b6009546001600160a01b031661025b565b61023b611165565b6102866104923660046128cd565b611174565b6102866104a5366004612909565b6111c6565b61023b6104b8366004612669565b611245565b61021e6104cb366004612726565b6001600160a01b03166000908152600a602052604090205460ff1690565b61021e6104f7366004612985565b6001600160a01b03918216600090815260056020908152604080832093909416825291909152205460ff1690565b610286610533366004612726565b6113bc565b600d5461025b906001600160a01b031681565b6000610556826114c4565b92915050565b60606000805461056b906129b8565b80601f0160208091040260200160405190810160405280929190818152602001828054610597906129b8565b80156105e45780601f106105b9576101008083540402835291602001916105e4565b820191906000526020600020905b8154815290600101906020018083116105c757829003601f168201915b5050505050905090565b60006105f9826114e9565b61065f5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b60648201526084015b60405180910390fd5b506000908152600460205260409020546001600160a01b031690565b6001600160a01b0382163b156106c3576001600160a01b0382166000908152600a602052604090205460ff166106c35760405162461bcd60e51b8152600401610656906129f3565b6106cd8282611506565b5050565b6106d9611629565b6001600160a01b03166106f46009546001600160a01b031690565b6001600160a01b03161461071a5760405162461bcd60e51b815260040161065690612a44565b6127108111156107925760405162461bcd60e51b815260206004820152603f60248201527f557365724d696e7461626c65436f6c6c656374696f6e3a20726f79616c74792060448201527f6d757374206265206c657373207468616e20657175616c20746f2031303025006064820152608401610656565b600854818114156107fd5760405162461bcd60e51b815260206004820152602f60248201527f557365724d696e7461626c65436f6c6c656374696f6e3a206c696d6974206d7560448201526e1cdd08189948191a5999995c995b9d608a1b6064820152608401610656565b60088290557f24e9ac82874a292ce9f8cd8bab098623c61cf4c32301b7a050722aa0dd765e8561082b611629565b604080516001600160a01b03909216825260208201849052810184905260600160405180910390a15050565b610868610862611629565b82611633565b6108845760405162461bcd60e51b815260040161065690612a79565b6001600160a01b0383166000908152600c602052604090206108a69082611719565b506001600160a01b0382166000908152600c602052604090206108c99082611725565b506108d5838383611731565b505050565b60008281526007602090815260408083208151808301909252546001600160a01b0381168252600160a01b90046001600160601b031691810182905282918290612710906109289087612af6565b6109329190612b2b565b915196919550909350505050565b6001600160a01b0382166000908152600c6020526040812061096290836118cd565b9392505050565b610971611629565b6001600160a01b031661098c6009546001600160a01b031690565b6001600160a01b0316146109b25760405162461bcd60e51b815260040161065690612a44565b6001600160a01b0381166000908152600a602052604090205460ff16151560011415610a465760405162461bcd60e51b815260206004820152603d60248201527f557365724d696e7461626c65436f6c6c656374696f6e2057686974654c69737460448201527f3a206164647265737320616c72656164792077686974656c69737465640000006064820152608401610656565b6001600160a01b0381166000818152600a6020908152604091829020805460ff1916600190811790915591519182527fa54714518c5d275fdcd3d2a461e4858e4e8cb04fb93cd0bca9d6d34115f2644091015b60405180910390a250565b610aac611629565b6001600160a01b0316610ac76009546001600160a01b031690565b6001600160a01b031614610aed5760405162461bcd60e51b815260040161065690612a44565b600d80546001600160a01b0319166001600160a01b0392909216919091179055565b6108d5838383604051806020016040528060008152506111c6565b610b35610862611629565b610ba75760405162461bcd60e51b815260206004820152603d60248201527f557365724d696e7461626c65436f6c6c656374696f6e3a206275726e2063616c60448201527f6c6572206973206e6f74206f776e6572206e6f7220617070726f7665640000006064820152608401610656565b6000610bb282610d47565b6001600160a01b0381166000908152600c60205260409020909150610bd79083611719565b506000828152600f6020526040902080546001600160a01b03191690556106cd826118d9565b6001600160a01b0381166000908152600c6020526040902060609061055690611919565b610c29611629565b6001600160a01b0316610c446009546001600160a01b031690565b6001600160a01b031614610c6a5760405162461bcd60e51b815260040161065690612a44565b6001600160a01b0381166000908152600a602052604090205460ff16610cf85760405162461bcd60e51b815260206004820152603960248201527f557365724d696e7461626c65436f6c6c656374696f6e2057686974654c69737460448201527f3a206164647265737320616c72656164792072656d6f766564000000000000006064820152608401610656565b6001600160a01b0381166000818152600a60209081526040808320805460ff19169055519182527fa54714518c5d275fdcd3d2a461e4858e4e8cb04fb93cd0bca9d6d34115f264409101610a99565b6000818152600260205260408120546001600160a01b0316806105565760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b6064820152608401610656565b60006001600160a01b038216610e295760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b6064820152608401610656565b506001600160a01b031660009081526003602052604090205490565b610e4d611629565b6001600160a01b0316610e686009546001600160a01b031690565b6001600160a01b031614610e8e5760405162461bcd60e51b815260040161065690612a44565b610e986000611926565b565b600d546000906001600160a01b0316331480610ed057506009546001600160a01b0316610ec5611629565b6001600160a01b0316145b610f425760405162461bcd60e51b815260206004820152603960248201527f557365724d696e7461626c65436f6c6c656374696f6e3a206f6e6c79206f776e60448201527f65722063616e2063616c6c20746869732066756e6374696f6e000000000000006064820152608401610656565b6001600160a01b038416610fae5760405162461bcd60e51b815260206004820152602d60248201527f557365724d696e7461626c65436f6c6c656374696f6e3a205f746f206164647260448201526c195cdcc81b9bdd081d985b1a59609a1b6064820152608401610656565b60008351116110165760405162461bcd60e51b815260206004820152602e60248201527f557365724d696e7461626c65436f6c6c656374696f6e3a20546f6b656e20555260448201526d12481a5cc81b9bdd081d985b1a5960921b6064820152608401610656565b600e805490600061102683612b3f565b9190505550600e549050600b54600161103f9190612b5a565b600b556001600160a01b0384166000908152600c602052604090206110649082611725565b5061106f8482611978565b6110798184611992565b6001600160601b0382161561109357611093818584611a1d565b6000818152600f6020526040902080546001600160a01b0319166001600160a01b0395909516949094179093555090919050565b826110d0611629565b6000828152600f60205260409020546001600160a01b039081169116146111095760405162461bcd60e51b815260040161065690612b72565b611114848484611a1d565b50505050565b80611123611629565b6000828152600f60205260409020546001600160a01b0390811691161461115c5760405162461bcd60e51b815260040161065690612b72565b6106cd82611c35565b60606001805461056b906129b8565b6001600160a01b0382163b156111bc576001600160a01b0382166000908152600a602052604090205460ff166111bc5760405162461bcd60e51b8152600401610656906129f3565b6106cd8282611c83565b6111d76111d1611629565b83611633565b6111f35760405162461bcd60e51b815260040161065690612a79565b6001600160a01b0384166000908152600c602052604090206112159083611719565b506001600160a01b0383166000908152600c602052604090206112389083611725565b5061111484848484611c95565b6060611250826114e9565b6112b65760405162461bcd60e51b815260206004820152603160248201527f45524337323155524953746f726167653a2055524920717565727920666f72206044820152703737b732bc34b9ba32b73a103a37b5b2b760791b6064820152608401610656565b600082815260066020526040812080546112cf906129b8565b80601f01602080910402602001604051908101604052809291908181526020018280546112fb906129b8565b80156113485780601f1061131d57610100808354040283529160200191611348565b820191906000526020600020905b81548152906001019060200180831161132b57829003601f168201915b50505050509050600061136660408051602081019091526000815290565b9050805160001415611379575092915050565b8151156113ab578082604051602001611393929190612bcf565b60405160208183030381529060405292505050919050565b6113b484611cc8565b949350505050565b6113c4611629565b6001600160a01b03166113df6009546001600160a01b031690565b6001600160a01b0316146114055760405162461bcd60e51b815260040161065690612a44565b6001600160a01b03811661146a5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610656565b61147381611926565b50565b60007f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03163314156114b6575060131936013560601c90565b503390565b905090565b3390565b60006001600160e01b0319821663152a902d60e11b1480610556575061055682611d9f565b6000908152600260205260409020546001600160a01b0316151590565b600061151182610d47565b9050806001600160a01b0316836001600160a01b0316141561157f5760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b6064820152608401610656565b806001600160a01b0316611591611629565b6001600160a01b031614806115ad57506115ad816104f7611629565b61161f5760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610656565b6108d58383611def565b60006114bb611476565b600061163e826114e9565b61169f5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610656565b60006116aa83610d47565b9050806001600160a01b0316846001600160a01b031614806116e55750836001600160a01b03166116da846105ee565b6001600160a01b0316145b806113b457506001600160a01b0380821660009081526005602090815260408083209388168352929052205460ff166113b4565b60006109628383611e5d565b60006109628383611f50565b826001600160a01b031661174482610d47565b6001600160a01b0316146117a85760405162461bcd60e51b815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201526437bbb732b960d91b6064820152608401610656565b6001600160a01b03821661180a5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610656565b611815600082611def565b6001600160a01b038316600090815260036020526040812080546001929061183e908490612bfe565b90915550506001600160a01b038216600090815260036020526040812080546001929061186c908490612b5a565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b60006109628383611f9f565b6118e281611fc9565b600081815260066020526040902080546118fb906129b8565b159050611473576000818152600660205260408120611473916124f8565b6060600061096283612064565b600980546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6106cd8282604051806020016040528060008152506120c0565b61199b826114e9565b6119fe5760405162461bcd60e51b815260206004820152602e60248201527f45524337323155524953746f726167653a2055524920736574206f66206e6f6e60448201526d32bc34b9ba32b73a103a37b5b2b760911b6064820152608401610656565b600082815260066020908152604090912082516108d592840190612532565b600854816001600160601b03161115611aac5760405162461bcd60e51b8152602060048201526044602482018190527f557365724d696e7461626c65436f6c6c656374696f6e20455243323938313a20908201527f726f79616c697479206d757374206265206c657373207468616e206d6178206c6064820152631a5b5a5d60e21b608482015260a401610656565b6127106001600160601b0382161115611b375760405162461bcd60e51b815260206004820152604160248201527f557365724d696e7461626c65436f6c6c656374696f6e20455243323938313a2060448201527f726f79616c7479206665652077696c6c206578636565642073616c65507269636064820152606560f81b608482015260a401610656565b6001600160a01b038216611ba85760405162461bcd60e51b815260206004820152603260248201527f557365724d696e7461626c65436f6c6c656374696f6e20455243323938313a20604482015271496e76616c696420706172616d657465727360701b6064820152608401610656565b6040805180820182526001600160a01b038481168083526001600160601b03858116602080860182815260008b81526007835288902096519051909316600160a01b029290941691909117909355835187815291820152918201527fccc2012fd9a6d1b3ae1de212a90691024ce7a26eb0fb532f7ac40bde3f6053829060600160405180910390a1505050565b60008181526007602052604080822091909155517f6615769c4a3273fc9643523267ff990589c05dadc78fd87bc25d3ff76acbf6d290611c789083815260200190565b60405180910390a150565b6106cd611c8e611629565b83836120f3565b611ca0848484611731565b611cac848484846121c2565b6111145760405162461bcd60e51b815260040161065690612c15565b6060611cd3826114e9565b611d375760405162461bcd60e51b815260206004820152602f60248201527f4552433732314d657461646174613a2055524920717565727920666f72206e6f60448201526e3732bc34b9ba32b73a103a37b5b2b760891b6064820152608401610656565b6000611d4e60408051602081019091526000815290565b90506000815111611d6e5760405180602001604052806000815250610962565b80611d78846122c7565b604051602001611d89929190612bcf565b6040516020818303038152906040529392505050565b60006001600160e01b031982166380ac58cd60e01b1480611dd057506001600160e01b03198216635b5e139f60e01b145b8061055657506301ffc9a760e01b6001600160e01b0319831614610556565b600081815260046020526040902080546001600160a01b0319166001600160a01b0384169081179091558190611e2482610d47565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b60008181526001830160205260408120548015611f46576000611e81600183612bfe565b8554909150600090611e9590600190612bfe565b9050818114611efa576000866000018281548110611eb557611eb5612c67565b9060005260206000200154905080876000018481548110611ed857611ed8612c67565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080611f0b57611f0b612c7d565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610556565b6000915050610556565b6000818152600183016020526040812054611f9757508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610556565b506000610556565b6000826000018281548110611fb657611fb6612c67565b9060005260206000200154905092915050565b6000611fd482610d47565b9050611fe1600083611def565b6001600160a01b038116600090815260036020526040812080546001929061200a908490612bfe565b909155505060008281526002602052604080822080546001600160a01b0319169055518391906001600160a01b038416907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908390a45050565b6060816000018054806020026020016040519081016040528092919081815260200182805480156120b457602002820191906000526020600020905b8154815260200190600101908083116120a0575b50505050509050919050565b6120ca83836123c5565b6120d760008484846121c2565b6108d55760405162461bcd60e51b815260040161065690612c15565b816001600160a01b0316836001600160a01b031614156121555760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610656565b6001600160a01b03838116600081815260056020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b60006001600160a01b0384163b156122bc57836001600160a01b031663150b7a026121eb611629565b8786866040518563ffffffff1660e01b815260040161220d9493929190612c93565b6020604051808303816000875af1925050508015612248575060408051601f3d908101601f1916820190925261224591810190612cd0565b60015b6122a2573d808015612276576040519150601f19603f3d011682016040523d82523d6000602084013e61227b565b606091505b50805161229a5760405162461bcd60e51b815260040161065690612c15565b805181602001fd5b6001600160e01b031916630a85bd0160e11b1490506113b4565b506001949350505050565b6060816122eb5750506040805180820190915260018152600360fc1b602082015290565b8160005b811561231557806122ff81612b3f565b915061230e9050600a83612b2b565b91506122ef565b60008167ffffffffffffffff81111561233057612330612785565b6040519080825280601f01601f19166020018201604052801561235a576020820181803683370190505b5090505b84156113b45761236f600183612bfe565b915061237c600a86612ced565b612387906030612b5a565b60f81b81838151811061239c5761239c612c67565b60200101906001600160f81b031916908160001a9053506123be600a86612b2b565b945061235e565b6001600160a01b03821661241b5760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610656565b612424816114e9565b156124715760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610656565b6001600160a01b038216600090815260036020526040812080546001929061249a908490612b5a565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b508054612504906129b8565b6000825580601f10612514575050565b601f01602090049060005260206000209081019061147391906125b6565b82805461253e906129b8565b90600052602060002090601f01602090048101928261256057600085556125a6565b82601f1061257957805160ff19168380011785556125a6565b828001600101855582156125a6579182015b828111156125a657825182559160200191906001019061258b565b506125b29291506125b6565b5090565b5b808211156125b257600081556001016125b7565b6001600160e01b03198116811461147357600080fd5b6000602082840312156125f357600080fd5b8135610962816125cb565b60005b83811015612619578181015183820152602001612601565b838111156111145750506000910152565b600081518084526126428160208601602086016125fe565b601f01601f19169290920160200192915050565b602081526000610962602083018461262a565b60006020828403121561267b57600080fd5b5035919050565b80356001600160a01b038116811461269957600080fd5b919050565b600080604083850312156126b157600080fd5b6126ba83612682565b946020939093013593505050565b6000806000606084860312156126dd57600080fd5b6126e684612682565b92506126f460208501612682565b9150604084013590509250925092565b6000806040838503121561271757600080fd5b50508035926020909101359150565b60006020828403121561273857600080fd5b61096282612682565b6020808252825182820181905260009190848201906040850190845b818110156127795783518352928401929184019160010161275d565b50909695505050505050565b634e487b7160e01b600052604160045260246000fd5b600067ffffffffffffffff808411156127b6576127b6612785565b604051601f8501601f19908116603f011681019082821181831017156127de576127de612785565b816040528093508581528686860111156127f757600080fd5b858560208301376000602087830101525050509392505050565b80356001600160601b038116811461269957600080fd5b60008060006060848603121561283d57600080fd5b61284684612682565b9250602084013567ffffffffffffffff81111561286257600080fd5b8401601f8101861361287357600080fd5b6128828682356020840161279b565b92505061289160408501612811565b90509250925092565b6000806000606084860312156128af57600080fd5b833592506128bf60208501612682565b915061289160408501612811565b600080604083850312156128e057600080fd5b6128e983612682565b9150602083013580151581146128fe57600080fd5b809150509250929050565b6000806000806080858703121561291f57600080fd5b61292885612682565b935061293660208601612682565b925060408501359150606085013567ffffffffffffffff81111561295957600080fd5b8501601f8101871361296a57600080fd5b6129798782356020840161279b565b91505092959194509250565b6000806040838503121561299857600080fd5b6129a183612682565b91506129af60208401612682565b90509250929050565b600181811c908216806129cc57607f821691505b602082108114156129ed57634e487b7160e01b600052602260045260246000fd5b50919050565b60208082526031908201527f557365724d696e7461626c65436f6c6c656374696f6e3a204f6e6c79207768696040820152701d195b1a5cdd081a5cc8185b1b1bddd959607a1b606082015260800190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b60208082526041908201527f557365724d696e7461626c65436f6c6c656374696f6e3a207472616e7366657260408201527f2063616c6c6572206973206e6f74206f776e6572206e6f7220617070726f76656060820152601960fa1b608082015260a00190565b634e487b7160e01b600052601160045260246000fd5b6000816000190483118215151615612b1057612b10612ae0565b500290565b634e487b7160e01b600052601260045260246000fd5b600082612b3a57612b3a612b15565b500490565b6000600019821415612b5357612b53612ae0565b5060010190565b60008219821115612b6d57612b6d612ae0565b500190565b6020808252603f908201527f557365724d696e7461626c65436f6c6c656374696f6e3a206f6e6c7920696e6960408201527f7469616c206f776e65722063616e207365742074686520726f79616c69747900606082015260800190565b60008351612be18184602088016125fe565b835190830190612bf58183602088016125fe565b01949350505050565b600082821015612c1057612c10612ae0565b500390565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052603160045260246000fd5b6001600160a01b0385811682528416602082015260408101839052608060608201819052600090612cc69083018461262a565b9695505050505050565b600060208284031215612ce257600080fd5b8151610962816125cb565b600082612cfc57612cfc612b15565b50069056fea2646970667358221220e7737bb50de8cf2dec0ea6f4feb97e0b332e6960d64803d76ea029caf5de0a6064736f6c634300080b0033000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000003de6b7eea508d747a0fa14a3809cff3ced60f89c0000000000000000000000000000000000000000000000000000000000000008734c61627341727400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000034152540000000000000000000000000000000000000000000000000000000000
Deployed Bytecode
0x608060405234801561001057600080fd5b50600436106102065760003560e01c806361bc221a1161011a5780638da5cb5b116100ad578063c87b56dd1161007c578063c87b56dd146104aa578063d936547e146104bd578063e985e9c5146104e9578063f2fde38b14610525578063f645d4f91461053857600080fd5b80638da5cb5b1461046b57806395d89b411461047c578063a22cb46514610484578063b88d4fde1461049757600080fd5b8063715018a6116100e9578063715018a61461042a5780637b17b7a814610432578063807e9bae146104455780638a616bc01461045857600080fd5b806361bc221a146103f25780636352211e146103fb578063674a12c71461040e57806370a082311461041757600080fd5b80632a55205a1161019d57806342842e0e1161016c57806342842e0e1461035957806342966c681461036c578063450efe211461037f5780634ba79dfe1461039f578063572b6c05146103b257600080fd5b80632a55205a146102ee5780632f745c591461032057806338eada1c14610333578063415a21871461034657600080fd5b80630fee7d2a116101d95780630fee7d2a1461028857806318160ddd1461029b578063207ce2fe146102b257806323b872dd146102db57600080fd5b806301ffc9a71461020b57806306fdde0314610233578063081812fc14610248578063095ea7b314610273575b600080fd5b61021e6102193660046125e1565b61054b565b60405190151581526020015b60405180910390f35b61023b61055c565b60405161022a9190612656565b61025b610256366004612669565b6105ee565b6040516001600160a01b03909116815260200161022a565b61028661028136600461269e565b61067b565b005b610286610296366004612669565b6106d1565b6102a4600b5481565b60405190815260200161022a565b61025b6102c0366004612669565b600f602052600090815260409020546001600160a01b031681565b6102866102e93660046126c8565b610857565b6103016102fc366004612704565b6108da565b604080516001600160a01b03909316835260208301919091520161022a565b6102a461032e36600461269e565b610940565b610286610341366004612726565b610969565b610286610354366004612726565b610aa4565b6102866103673660046126c8565b610b0f565b61028661037a366004612669565b610b2a565b61039261038d366004612726565b610bfd565b60405161022a9190612741565b6102866103ad366004612726565b610c21565b61021e6103c0366004612726565b7f0000000000000000000000003de6b7eea508d747a0fa14a3809cff3ced60f89c6001600160a01b0390811691161490565b6102a4600e5481565b61025b610409366004612669565b610d47565b6102a460085481565b6102a4610425366004612726565b610dbe565b610286610e45565b6102a4610440366004612828565b610e9a565b61028661045336600461289a565b6110c7565b610286610466366004612669565b61111a565b6009546001600160a01b031661025b565b61023b611165565b6102866104923660046128cd565b611174565b6102866104a5366004612909565b6111c6565b61023b6104b8366004612669565b611245565b61021e6104cb366004612726565b6001600160a01b03166000908152600a602052604090205460ff1690565b61021e6104f7366004612985565b6001600160a01b03918216600090815260056020908152604080832093909416825291909152205460ff1690565b610286610533366004612726565b6113bc565b600d5461025b906001600160a01b031681565b6000610556826114c4565b92915050565b60606000805461056b906129b8565b80601f0160208091040260200160405190810160405280929190818152602001828054610597906129b8565b80156105e45780601f106105b9576101008083540402835291602001916105e4565b820191906000526020600020905b8154815290600101906020018083116105c757829003601f168201915b5050505050905090565b60006105f9826114e9565b61065f5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b60648201526084015b60405180910390fd5b506000908152600460205260409020546001600160a01b031690565b6001600160a01b0382163b156106c3576001600160a01b0382166000908152600a602052604090205460ff166106c35760405162461bcd60e51b8152600401610656906129f3565b6106cd8282611506565b5050565b6106d9611629565b6001600160a01b03166106f46009546001600160a01b031690565b6001600160a01b03161461071a5760405162461bcd60e51b815260040161065690612a44565b6127108111156107925760405162461bcd60e51b815260206004820152603f60248201527f557365724d696e7461626c65436f6c6c656374696f6e3a20726f79616c74792060448201527f6d757374206265206c657373207468616e20657175616c20746f2031303025006064820152608401610656565b600854818114156107fd5760405162461bcd60e51b815260206004820152602f60248201527f557365724d696e7461626c65436f6c6c656374696f6e3a206c696d6974206d7560448201526e1cdd08189948191a5999995c995b9d608a1b6064820152608401610656565b60088290557f24e9ac82874a292ce9f8cd8bab098623c61cf4c32301b7a050722aa0dd765e8561082b611629565b604080516001600160a01b03909216825260208201849052810184905260600160405180910390a15050565b610868610862611629565b82611633565b6108845760405162461bcd60e51b815260040161065690612a79565b6001600160a01b0383166000908152600c602052604090206108a69082611719565b506001600160a01b0382166000908152600c602052604090206108c99082611725565b506108d5838383611731565b505050565b60008281526007602090815260408083208151808301909252546001600160a01b0381168252600160a01b90046001600160601b031691810182905282918290612710906109289087612af6565b6109329190612b2b565b915196919550909350505050565b6001600160a01b0382166000908152600c6020526040812061096290836118cd565b9392505050565b610971611629565b6001600160a01b031661098c6009546001600160a01b031690565b6001600160a01b0316146109b25760405162461bcd60e51b815260040161065690612a44565b6001600160a01b0381166000908152600a602052604090205460ff16151560011415610a465760405162461bcd60e51b815260206004820152603d60248201527f557365724d696e7461626c65436f6c6c656374696f6e2057686974654c69737460448201527f3a206164647265737320616c72656164792077686974656c69737465640000006064820152608401610656565b6001600160a01b0381166000818152600a6020908152604091829020805460ff1916600190811790915591519182527fa54714518c5d275fdcd3d2a461e4858e4e8cb04fb93cd0bca9d6d34115f2644091015b60405180910390a250565b610aac611629565b6001600160a01b0316610ac76009546001600160a01b031690565b6001600160a01b031614610aed5760405162461bcd60e51b815260040161065690612a44565b600d80546001600160a01b0319166001600160a01b0392909216919091179055565b6108d5838383604051806020016040528060008152506111c6565b610b35610862611629565b610ba75760405162461bcd60e51b815260206004820152603d60248201527f557365724d696e7461626c65436f6c6c656374696f6e3a206275726e2063616c60448201527f6c6572206973206e6f74206f776e6572206e6f7220617070726f7665640000006064820152608401610656565b6000610bb282610d47565b6001600160a01b0381166000908152600c60205260409020909150610bd79083611719565b506000828152600f6020526040902080546001600160a01b03191690556106cd826118d9565b6001600160a01b0381166000908152600c6020526040902060609061055690611919565b610c29611629565b6001600160a01b0316610c446009546001600160a01b031690565b6001600160a01b031614610c6a5760405162461bcd60e51b815260040161065690612a44565b6001600160a01b0381166000908152600a602052604090205460ff16610cf85760405162461bcd60e51b815260206004820152603960248201527f557365724d696e7461626c65436f6c6c656374696f6e2057686974654c69737460448201527f3a206164647265737320616c72656164792072656d6f766564000000000000006064820152608401610656565b6001600160a01b0381166000818152600a60209081526040808320805460ff19169055519182527fa54714518c5d275fdcd3d2a461e4858e4e8cb04fb93cd0bca9d6d34115f264409101610a99565b6000818152600260205260408120546001600160a01b0316806105565760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b6064820152608401610656565b60006001600160a01b038216610e295760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b6064820152608401610656565b506001600160a01b031660009081526003602052604090205490565b610e4d611629565b6001600160a01b0316610e686009546001600160a01b031690565b6001600160a01b031614610e8e5760405162461bcd60e51b815260040161065690612a44565b610e986000611926565b565b600d546000906001600160a01b0316331480610ed057506009546001600160a01b0316610ec5611629565b6001600160a01b0316145b610f425760405162461bcd60e51b815260206004820152603960248201527f557365724d696e7461626c65436f6c6c656374696f6e3a206f6e6c79206f776e60448201527f65722063616e2063616c6c20746869732066756e6374696f6e000000000000006064820152608401610656565b6001600160a01b038416610fae5760405162461bcd60e51b815260206004820152602d60248201527f557365724d696e7461626c65436f6c6c656374696f6e3a205f746f206164647260448201526c195cdcc81b9bdd081d985b1a59609a1b6064820152608401610656565b60008351116110165760405162461bcd60e51b815260206004820152602e60248201527f557365724d696e7461626c65436f6c6c656374696f6e3a20546f6b656e20555260448201526d12481a5cc81b9bdd081d985b1a5960921b6064820152608401610656565b600e805490600061102683612b3f565b9190505550600e549050600b54600161103f9190612b5a565b600b556001600160a01b0384166000908152600c602052604090206110649082611725565b5061106f8482611978565b6110798184611992565b6001600160601b0382161561109357611093818584611a1d565b6000818152600f6020526040902080546001600160a01b0319166001600160a01b0395909516949094179093555090919050565b826110d0611629565b6000828152600f60205260409020546001600160a01b039081169116146111095760405162461bcd60e51b815260040161065690612b72565b611114848484611a1d565b50505050565b80611123611629565b6000828152600f60205260409020546001600160a01b0390811691161461115c5760405162461bcd60e51b815260040161065690612b72565b6106cd82611c35565b60606001805461056b906129b8565b6001600160a01b0382163b156111bc576001600160a01b0382166000908152600a602052604090205460ff166111bc5760405162461bcd60e51b8152600401610656906129f3565b6106cd8282611c83565b6111d76111d1611629565b83611633565b6111f35760405162461bcd60e51b815260040161065690612a79565b6001600160a01b0384166000908152600c602052604090206112159083611719565b506001600160a01b0383166000908152600c602052604090206112389083611725565b5061111484848484611c95565b6060611250826114e9565b6112b65760405162461bcd60e51b815260206004820152603160248201527f45524337323155524953746f726167653a2055524920717565727920666f72206044820152703737b732bc34b9ba32b73a103a37b5b2b760791b6064820152608401610656565b600082815260066020526040812080546112cf906129b8565b80601f01602080910402602001604051908101604052809291908181526020018280546112fb906129b8565b80156113485780601f1061131d57610100808354040283529160200191611348565b820191906000526020600020905b81548152906001019060200180831161132b57829003601f168201915b50505050509050600061136660408051602081019091526000815290565b9050805160001415611379575092915050565b8151156113ab578082604051602001611393929190612bcf565b60405160208183030381529060405292505050919050565b6113b484611cc8565b949350505050565b6113c4611629565b6001600160a01b03166113df6009546001600160a01b031690565b6001600160a01b0316146114055760405162461bcd60e51b815260040161065690612a44565b6001600160a01b03811661146a5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610656565b61147381611926565b50565b60007f0000000000000000000000003de6b7eea508d747a0fa14a3809cff3ced60f89c6001600160a01b03163314156114b6575060131936013560601c90565b503390565b905090565b3390565b60006001600160e01b0319821663152a902d60e11b1480610556575061055682611d9f565b6000908152600260205260409020546001600160a01b0316151590565b600061151182610d47565b9050806001600160a01b0316836001600160a01b0316141561157f5760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b6064820152608401610656565b806001600160a01b0316611591611629565b6001600160a01b031614806115ad57506115ad816104f7611629565b61161f5760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610656565b6108d58383611def565b60006114bb611476565b600061163e826114e9565b61169f5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610656565b60006116aa83610d47565b9050806001600160a01b0316846001600160a01b031614806116e55750836001600160a01b03166116da846105ee565b6001600160a01b0316145b806113b457506001600160a01b0380821660009081526005602090815260408083209388168352929052205460ff166113b4565b60006109628383611e5d565b60006109628383611f50565b826001600160a01b031661174482610d47565b6001600160a01b0316146117a85760405162461bcd60e51b815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201526437bbb732b960d91b6064820152608401610656565b6001600160a01b03821661180a5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610656565b611815600082611def565b6001600160a01b038316600090815260036020526040812080546001929061183e908490612bfe565b90915550506001600160a01b038216600090815260036020526040812080546001929061186c908490612b5a565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b60006109628383611f9f565b6118e281611fc9565b600081815260066020526040902080546118fb906129b8565b159050611473576000818152600660205260408120611473916124f8565b6060600061096283612064565b600980546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6106cd8282604051806020016040528060008152506120c0565b61199b826114e9565b6119fe5760405162461bcd60e51b815260206004820152602e60248201527f45524337323155524953746f726167653a2055524920736574206f66206e6f6e60448201526d32bc34b9ba32b73a103a37b5b2b760911b6064820152608401610656565b600082815260066020908152604090912082516108d592840190612532565b600854816001600160601b03161115611aac5760405162461bcd60e51b8152602060048201526044602482018190527f557365724d696e7461626c65436f6c6c656374696f6e20455243323938313a20908201527f726f79616c697479206d757374206265206c657373207468616e206d6178206c6064820152631a5b5a5d60e21b608482015260a401610656565b6127106001600160601b0382161115611b375760405162461bcd60e51b815260206004820152604160248201527f557365724d696e7461626c65436f6c6c656374696f6e20455243323938313a2060448201527f726f79616c7479206665652077696c6c206578636565642073616c65507269636064820152606560f81b608482015260a401610656565b6001600160a01b038216611ba85760405162461bcd60e51b815260206004820152603260248201527f557365724d696e7461626c65436f6c6c656374696f6e20455243323938313a20604482015271496e76616c696420706172616d657465727360701b6064820152608401610656565b6040805180820182526001600160a01b038481168083526001600160601b03858116602080860182815260008b81526007835288902096519051909316600160a01b029290941691909117909355835187815291820152918201527fccc2012fd9a6d1b3ae1de212a90691024ce7a26eb0fb532f7ac40bde3f6053829060600160405180910390a1505050565b60008181526007602052604080822091909155517f6615769c4a3273fc9643523267ff990589c05dadc78fd87bc25d3ff76acbf6d290611c789083815260200190565b60405180910390a150565b6106cd611c8e611629565b83836120f3565b611ca0848484611731565b611cac848484846121c2565b6111145760405162461bcd60e51b815260040161065690612c15565b6060611cd3826114e9565b611d375760405162461bcd60e51b815260206004820152602f60248201527f4552433732314d657461646174613a2055524920717565727920666f72206e6f60448201526e3732bc34b9ba32b73a103a37b5b2b760891b6064820152608401610656565b6000611d4e60408051602081019091526000815290565b90506000815111611d6e5760405180602001604052806000815250610962565b80611d78846122c7565b604051602001611d89929190612bcf565b6040516020818303038152906040529392505050565b60006001600160e01b031982166380ac58cd60e01b1480611dd057506001600160e01b03198216635b5e139f60e01b145b8061055657506301ffc9a760e01b6001600160e01b0319831614610556565b600081815260046020526040902080546001600160a01b0319166001600160a01b0384169081179091558190611e2482610d47565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b60008181526001830160205260408120548015611f46576000611e81600183612bfe565b8554909150600090611e9590600190612bfe565b9050818114611efa576000866000018281548110611eb557611eb5612c67565b9060005260206000200154905080876000018481548110611ed857611ed8612c67565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080611f0b57611f0b612c7d565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610556565b6000915050610556565b6000818152600183016020526040812054611f9757508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610556565b506000610556565b6000826000018281548110611fb657611fb6612c67565b9060005260206000200154905092915050565b6000611fd482610d47565b9050611fe1600083611def565b6001600160a01b038116600090815260036020526040812080546001929061200a908490612bfe565b909155505060008281526002602052604080822080546001600160a01b0319169055518391906001600160a01b038416907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908390a45050565b6060816000018054806020026020016040519081016040528092919081815260200182805480156120b457602002820191906000526020600020905b8154815260200190600101908083116120a0575b50505050509050919050565b6120ca83836123c5565b6120d760008484846121c2565b6108d55760405162461bcd60e51b815260040161065690612c15565b816001600160a01b0316836001600160a01b031614156121555760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610656565b6001600160a01b03838116600081815260056020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b60006001600160a01b0384163b156122bc57836001600160a01b031663150b7a026121eb611629565b8786866040518563ffffffff1660e01b815260040161220d9493929190612c93565b6020604051808303816000875af1925050508015612248575060408051601f3d908101601f1916820190925261224591810190612cd0565b60015b6122a2573d808015612276576040519150601f19603f3d011682016040523d82523d6000602084013e61227b565b606091505b50805161229a5760405162461bcd60e51b815260040161065690612c15565b805181602001fd5b6001600160e01b031916630a85bd0160e11b1490506113b4565b506001949350505050565b6060816122eb5750506040805180820190915260018152600360fc1b602082015290565b8160005b811561231557806122ff81612b3f565b915061230e9050600a83612b2b565b91506122ef565b60008167ffffffffffffffff81111561233057612330612785565b6040519080825280601f01601f19166020018201604052801561235a576020820181803683370190505b5090505b84156113b45761236f600183612bfe565b915061237c600a86612ced565b612387906030612b5a565b60f81b81838151811061239c5761239c612c67565b60200101906001600160f81b031916908160001a9053506123be600a86612b2b565b945061235e565b6001600160a01b03821661241b5760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610656565b612424816114e9565b156124715760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610656565b6001600160a01b038216600090815260036020526040812080546001929061249a908490612b5a565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b508054612504906129b8565b6000825580601f10612514575050565b601f01602090049060005260206000209081019061147391906125b6565b82805461253e906129b8565b90600052602060002090601f01602090048101928261256057600085556125a6565b82601f1061257957805160ff19168380011785556125a6565b828001600101855582156125a6579182015b828111156125a657825182559160200191906001019061258b565b506125b29291506125b6565b5090565b5b808211156125b257600081556001016125b7565b6001600160e01b03198116811461147357600080fd5b6000602082840312156125f357600080fd5b8135610962816125cb565b60005b83811015612619578181015183820152602001612601565b838111156111145750506000910152565b600081518084526126428160208601602086016125fe565b601f01601f19169290920160200192915050565b602081526000610962602083018461262a565b60006020828403121561267b57600080fd5b5035919050565b80356001600160a01b038116811461269957600080fd5b919050565b600080604083850312156126b157600080fd5b6126ba83612682565b946020939093013593505050565b6000806000606084860312156126dd57600080fd5b6126e684612682565b92506126f460208501612682565b9150604084013590509250925092565b6000806040838503121561271757600080fd5b50508035926020909101359150565b60006020828403121561273857600080fd5b61096282612682565b6020808252825182820181905260009190848201906040850190845b818110156127795783518352928401929184019160010161275d565b50909695505050505050565b634e487b7160e01b600052604160045260246000fd5b600067ffffffffffffffff808411156127b6576127b6612785565b604051601f8501601f19908116603f011681019082821181831017156127de576127de612785565b816040528093508581528686860111156127f757600080fd5b858560208301376000602087830101525050509392505050565b80356001600160601b038116811461269957600080fd5b60008060006060848603121561283d57600080fd5b61284684612682565b9250602084013567ffffffffffffffff81111561286257600080fd5b8401601f8101861361287357600080fd5b6128828682356020840161279b565b92505061289160408501612811565b90509250925092565b6000806000606084860312156128af57600080fd5b833592506128bf60208501612682565b915061289160408501612811565b600080604083850312156128e057600080fd5b6128e983612682565b9150602083013580151581146128fe57600080fd5b809150509250929050565b6000806000806080858703121561291f57600080fd5b61292885612682565b935061293660208601612682565b925060408501359150606085013567ffffffffffffffff81111561295957600080fd5b8501601f8101871361296a57600080fd5b6129798782356020840161279b565b91505092959194509250565b6000806040838503121561299857600080fd5b6129a183612682565b91506129af60208401612682565b90509250929050565b600181811c908216806129cc57607f821691505b602082108114156129ed57634e487b7160e01b600052602260045260246000fd5b50919050565b60208082526031908201527f557365724d696e7461626c65436f6c6c656374696f6e3a204f6e6c79207768696040820152701d195b1a5cdd081a5cc8185b1b1bddd959607a1b606082015260800190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b60208082526041908201527f557365724d696e7461626c65436f6c6c656374696f6e3a207472616e7366657260408201527f2063616c6c6572206973206e6f74206f776e6572206e6f7220617070726f76656060820152601960fa1b608082015260a00190565b634e487b7160e01b600052601160045260246000fd5b6000816000190483118215151615612b1057612b10612ae0565b500290565b634e487b7160e01b600052601260045260246000fd5b600082612b3a57612b3a612b15565b500490565b6000600019821415612b5357612b53612ae0565b5060010190565b60008219821115612b6d57612b6d612ae0565b500190565b6020808252603f908201527f557365724d696e7461626c65436f6c6c656374696f6e3a206f6e6c7920696e6960408201527f7469616c206f776e65722063616e207365742074686520726f79616c69747900606082015260800190565b60008351612be18184602088016125fe565b835190830190612bf58183602088016125fe565b01949350505050565b600082821015612c1057612c10612ae0565b500390565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052603160045260246000fd5b6001600160a01b0385811682528416602082015260408101839052608060608201819052600090612cc69083018461262a565b9695505050505050565b600060208284031215612ce257600080fd5b8151610962816125cb565b600082612cfc57612cfc612b15565b50069056fea2646970667358221220e7737bb50de8cf2dec0ea6f4feb97e0b332e6960d64803d76ea029caf5de0a6064736f6c634300080b0033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000003de6b7eea508d747a0fa14a3809cff3ced60f89c0000000000000000000000000000000000000000000000000000000000000008734c61627341727400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000034152540000000000000000000000000000000000000000000000000000000000
-----Decoded View---------------
Arg [0] : _name (string): sLabsArt
Arg [1] : _symbol (string): ART
Arg [2] : trustedForwarder (address): 0x3dE6B7eeA508d747A0FA14a3809cfF3ced60f89c
-----Encoded View---------------
7 Constructor Arguments found :
Arg [0] : 0000000000000000000000000000000000000000000000000000000000000060
Arg [1] : 00000000000000000000000000000000000000000000000000000000000000a0
Arg [2] : 0000000000000000000000003de6b7eea508d747a0fa14a3809cff3ced60f89c
Arg [3] : 0000000000000000000000000000000000000000000000000000000000000008
Arg [4] : 734c616273417274000000000000000000000000000000000000000000000000
Arg [5] : 0000000000000000000000000000000000000000000000000000000000000003
Arg [6] : 4152540000000000000000000000000000000000000000000000000000000000
[ Download: CSV Export ]
[ Download: CSV Export ]
A token is a representation of an on-chain or off-chain asset. The token page shows information such as price, total supply, holders, transfers and social links. Learn more about this page in our Knowledge Base.