ERC-1155
Overview
Max Total Supply
344
Holders
160
Market
Volume (24H)
N/A
Min Price (24H)
N/A
Max Price (24H)
N/A
Other Info
Token Contract
Loading...
Loading
Loading...
Loading
Loading...
Loading
# | Exchange | Pair | Price | 24H Volume | % Volume |
---|
Contract Source Code Verified (Exact Match)
Contract Name:
NomadPass
Compiler Version
v0.8.9+commit.e5eed63a
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT pragma solidity ^0.8.9; import "@openzeppelin/contracts/token/ERC1155/ERC1155.sol"; import "@openzeppelin/contracts/access/AccessControl.sol"; import "@openzeppelin/contracts/security/Pausable.sol"; import "@openzeppelin/contracts/token/ERC1155/extensions/ERC1155Burnable.sol"; import "@openzeppelin/contracts/token/ERC1155/extensions/ERC1155Supply.sol"; import "@openzeppelin/contracts/utils/cryptography/draft-EIP712.sol"; import "@openzeppelin/contracts/utils/cryptography/ECDSA.sol"; import "@openzeppelin/contracts/utils/Counters.sol"; import "hardhat/console.sol"; // ███╗ ██╗ ██████╗ ███╗ ███╗ █████╗ ██████╗ ██████╗ ██╗ ██╗ ██╗██████╗ ███╗ ███╗██╗███╗ ██╗████████╗ ██████╗ █████╗ ███████╗███████╗██████╗ ██████╗ ██████╗ ████████╗ // ████╗ ██║██╔═══██╗████╗ ████║██╔══██╗██╔══██╗ ██╔══██╗██║ ██║ ██║██╔══██╗ ████╗ ████║██║████╗ ██║╚══██╔══╝ ██╔══██╗██╔══██╗██╔════╝██╔════╝██╔══██╗██╔═══██╗██╔══██╗╚══██╔══╝ // ██╔██╗ ██║██║ ██║██╔████╔██║███████║██║ ██║ ██████╔╝██║ ██║ ██║██║ ██║ ██╔████╔██║██║██╔██╗ ██║ ██║ ██████╔╝███████║███████╗███████╗██████╔╝██║ ██║██████╔╝ ██║ // ██║╚██╗██║██║ ██║██║╚██╔╝██║██╔══██║██║ ██║ ██╔══██╗██║ ╚██╗ ██╔╝██║ ██║ ██║╚██╔╝██║██║██║╚██╗██║ ██║ ██╔═══╝ ██╔══██║╚════██║╚════██║██╔═══╝ ██║ ██║██╔══██╗ ██║ // ██║ ╚████║╚██████╔╝██║ ╚═╝ ██║██║ ██║██████╔╝ ██████╔╝███████╗╚████╔╝ ██████╔╝ ██║ ╚═╝ ██║██║██║ ╚████║ ██║ ██║ ██║ ██║███████║███████║██║ ╚██████╔╝██║ ██║ ██║ // ╚═╝ ╚═══╝ ╚═════╝ ╚═╝ ╚═╝╚═╝ ╚═╝╚═════╝ ╚═════╝ ╚══════╝ ╚═══╝ ╚═════╝ ╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝ ╚═╝ ╚═╝ ╚═╝ ╚═╝╚══════╝╚══════╝╚═╝ ╚═════╝ ╚═╝ ╚═╝ ╚═╝ // Author @tiempor3al // A big thank you to all the people that made this project possible: // Marisol Hernández // Deisy Ignacio // Eduardo Zarate // Ximena Pérez // Mario Ramos // Joel Romero // Ken Sánchez // Mariana Tamayo // Marte Baquerizo // James Richardson // Jordan Rothstein // Ali Ossayran // Katie Brooks // Mason Mullins // @isabellegorilla // @heromachine_eth // @the_water_way // @metamanjro // @joso8181 // @Beanstamatic // @volecule // @thebmsbrand // @letsbefriends // @punkactual // @jdt_lol // @calvinhoenes // and many more.... // Special thanks to @bitcoinski for all the help and tips // // The NomadBLVD mint pass is non-refundable and will be redeemed for the Nomad BLVD NFT Art contract NomadPass is ERC1155, AccessControl, Pausable, ERC1155Burnable, ERC1155Supply, EIP712 { bytes32 public constant OPERATOR_ROLE = keccak256("OPERATOR_ROLE"); bytes32 public constant SIGNER_ROLE = keccak256("SIGNER_ROLE"); bytes32 public constant WITHDRAWER_ROLE = keccak256("WITHDRAWER_ROLE"); using Counters for Counters.Counter; Counters.Counter private _passCounter; struct Pass { uint256 maxItems; uint256 maxPerWallet; uint256 maxPerTransaction; uint256 price; uint256 open; uint256 close; address redeemContract; } mapping(uint256 => Pass) private _passes; mapping(bytes32 => address) private _redeemedPasses; string private _contractURI; //Events event DatesChanged(uint256[] ids, uint256[] open, uint256[] close); event RedeemedPass(bytes32 hash, address account); event MaxPerWalletChanged(uint256[] ids, uint256[] maxPerWallet); event MaxPerTransactionChanged(uint256[] ids, uint256[] maxPerTransaction); event PricesChanged(uint256[] ids, uint256[] prices); event MaxItemsChanged(uint256[] ids, uint256[] maxItems); event RedeemContractAddressChanged( uint256[] ids, address[] redeemContracts ); event UriChanged(string newUri); /// @dev We setup the roles and the name for the Smart Contract constructor(string memory newContractName) ERC1155("") EIP712(newContractName, "1.0.0") { _setupRole(DEFAULT_ADMIN_ROLE, msg.sender); _setupRole(OPERATOR_ROLE, msg.sender); _setupRole(WITHDRAWER_ROLE, msg.sender); _setupRole(SIGNER_ROLE, msg.sender); } /// @dev Setup method /// @param numPasses The number of passes to setup /// @param maxItems An array containing the maximum of passes, // for example if we defined numPasses = 2, and we want 2500 and 5000 maxItems, this array should be [2500, 5000] /// @param maxPerWallet An array containing the maximum allowed passes per wallet /// @param maxPerTransaction An array containing the maximum allowed passes per transaction /// @param prices An array containing the prices for the passes /// @param open An array containing timestamp values indicating when the sale is open for each pass /// @param close An array containing timestamp values indicating when the sale is closed for each pass. function setup( uint256 numPasses, uint256[] memory maxItems, uint256[] memory maxPerWallet, uint256[] memory maxPerTransaction, uint256[] memory prices, uint256[] memory open, uint256[] memory close ) external onlyRole(OPERATOR_ROLE) { require(numPasses > 0, "INVALID_NUMBER_TOKENS"); require(maxItems.length == numPasses, "INVALID_MAX_ITEMS_SIZE"); require(maxPerWallet.length == numPasses, "INVALID_MAX_WALLET_SIZE"); require( maxPerTransaction.length == numPasses, "INVALID_MAX_TRANSACTION_SIZE" ); require(prices.length == numPasses, "INVALID_PRICES_SIZE"); require(open.length == numPasses, "INVALID_OPEN_SIZE"); require(close.length == numPasses, "INVALID_CLOSE_SIZE"); for (uint256 i = 0; i < numPasses; i++) { require(maxItems[i] > 0, "INVALID_MAX_ITEM"); require(open[i] <= close[i], "INVALID_DATES"); Pass storage pass = _passes[_passCounter.current()]; pass.maxItems = maxItems[i]; pass.maxPerTransaction = maxPerTransaction[i]; pass.maxPerWallet = maxPerWallet[i]; pass.price = prices[i]; pass.open = open[i]; pass.close = close[i]; _passCounter.increment(); } } ///@dev Remove a hash from the redeemedPasses mapping. Should be used only if something goes wrong function deleteHash(bytes32 hash) external onlyRole(OPERATOR_ROLE) { delete _redeemedPasses[hash]; } ///@dev Sets the contract URI for OpenSea ///@param newContractURI The new URI for the contract function setContractURI(string memory newContractURI) external onlyRole(OPERATOR_ROLE) { _contractURI = newContractURI; } ///Returns the contract URI for OpenSea function contractURI() public view returns (string memory) { return _contractURI; } ///Returns the current pass counter function getCounter() external view returns (uint256) { return _passCounter.current(); } //Returns the price for passId function getPrice(uint256 passId) public view returns (uint256) { Pass storage pass = _passes[passId]; require(pass.maxItems > 0, "TOKEN_ID_NOT_EXIST"); return pass.price; } //Returns the maxItems for passId function getMaxItems(uint256 passId) public view returns (uint256) { Pass storage pass = _passes[passId]; require(pass.maxItems > 0, "TOKEN_ID_NOT_EXIST"); return pass.maxItems; } //Returns the open date for passId function getOpen(uint256 passId) public view returns (uint256) { Pass storage pass = _passes[passId]; require(pass.maxItems > 0, "TOKEN_ID_NOT_EXIST"); return pass.open; } //Returns the close date for passId function getClose(uint256 passId) public view returns (uint256) { Pass storage pass = _passes[passId]; require(pass.maxItems > 0, "TOKEN_ID_NOT_EXIST"); return pass.close; } //Returns the maxPerWallet for passId function getMaxPerWallet(uint256 passId) public view returns (uint256) { Pass storage pass = _passes[passId]; require(pass.maxItems > 0, "TOKEN_ID_NOT_EXIST"); return pass.maxPerWallet; } //Returns the maxPerTransaction for passId function getMaxPerTransaction(uint256 passId) public view returns (uint256) { Pass storage pass = _passes[passId]; require(pass.maxItems > 0, "TOKEN_ID_NOT_EXIST"); return pass.maxPerTransaction; } //Returns the redeemContract for passId function getRedeemContract(uint256 passId) public view returns (address) { Pass storage pass = _passes[passId]; require(pass.maxItems > 0, "TOKEN_ID_NOT_EXIST"); return pass.redeemContract; } //Returns the redeemContract for passId function resetPass(uint256 passId) external onlyRole(OPERATOR_ROLE) { delete (_passes[passId]); } ///@dev Resets the internal counter to newIndex function resetCounter(uint256 newIndex) external onlyRole(OPERATOR_ROLE) { _passCounter.reset(); for (uint256 i = 0; i < newIndex; i++) { _passCounter.increment(); } } /// @dev Pause the contract if anything weird happens function pause() public onlyRole(OPERATOR_ROLE) { _pause(); } /// @dev Unpause the contarct function unpause() public onlyRole(OPERATOR_ROLE) { _unpause(); } /// @dev After doing the setup, this method can be used to modify the sale dates. /// This dates are used in the mintPass method /// @param ids The ids of the passes /// @param open An array containing timestamp values indicating when the sale is open for each pass /// @param close An array containing timestamp values indicating when the sale is closed for each pass function setDates( uint256[] memory ids, uint256[] memory open, uint256[] memory close ) external onlyRole(OPERATOR_ROLE) { require(ids.length > 0, "INVALID_TOKENS_SIZE"); require(open.length == ids.length, "INVALID_OPEN_SIZE"); require(close.length == ids.length, "INVALID_CLOSE_SIZE"); for (uint256 i = 0; i < ids.length; i++) { require(open[i] <= close[i], "INVALID_DATES"); Pass storage pass = _passes[ids[i]]; require(pass.maxItems > 0, "TOKEN_ID_NOT_EXIST"); pass.open = open[i]; pass.close = close[i]; } emit DatesChanged(ids, open, close); } /// @dev After doing the setup, this method can be used to modify the maximum passes per wallet /// @param ids The ids of the passes /// @param maxPerWallet An array containing the maximum allowed passes per wallet. function setMaxPerWallet( uint256[] memory ids, uint256[] memory maxPerWallet ) external onlyRole(OPERATOR_ROLE) { require(ids.length > 0, "INVALID_TOKENS_SIZE"); require(maxPerWallet.length == ids.length, "INVALID_MAX_WALLET_SIZE"); for (uint256 i = 0; i < ids.length; i++) { Pass storage pass = _passes[ids[i]]; require(pass.maxItems > 0, "TOKEN_ID_NOT_EXIST"); pass.maxPerWallet = maxPerWallet[i]; } emit MaxPerWalletChanged(ids, maxPerWallet); } /// @dev After doing the setup, this method can be used to modify the maximum passes per transaction /// @param ids The ids of the passes /// @param maxPerTransaction An array containing the maximum allowed passes per transaction. function setMaxPerTransaction( uint256[] memory ids, uint256[] memory maxPerTransaction ) external onlyRole(OPERATOR_ROLE) { require(ids.length > 0, "INVALID_TOKENS_SIZE"); require( maxPerTransaction.length == ids.length, "INVALID_MAX_TRANSACTION_SIZE" ); for (uint256 i = 0; i < ids.length; i++) { Pass storage pass = _passes[ids[i]]; require(pass.maxItems > 0, "TOKEN_ID_NOT_EXIST"); pass.maxPerTransaction = maxPerTransaction[i]; } emit MaxPerTransactionChanged(ids, maxPerTransaction); } /// @dev After doing the setup, this method can be used to modify the redeem contract address for each pass. /// @param ids The ids of the passes /// @param redeemContracts The addresses for each redeem contract function setRedeemContracts( uint256[] memory ids, address[] memory redeemContracts ) external onlyRole(OPERATOR_ROLE) { require(ids.length > 0, "INVALID_TOKENS_SIZE"); require( redeemContracts.length == ids.length, "INVALID_REDEEM_CONTRACTS_SIZE" ); for (uint256 i = 0; i < ids.length; i++) { Pass storage pass = _passes[ids[i]]; require(pass.maxItems > 0, "TOKEN_ID_NOT_EXIST"); pass.redeemContract = redeemContracts[i]; } emit RedeemContractAddressChanged(ids, redeemContracts); } /// @dev After doing the setup, this method can be used to modify the redeem price of each pass. /// The prices are used in the redeemPass method /// @param ids The ids of the passes /// @param prices The prices of the passes function setPrices(uint256[] memory ids, uint256[] memory prices) external onlyRole(OPERATOR_ROLE) { require(ids.length > 0, "INVALID_TOKENS_SIZE"); require(prices.length == ids.length, "INVALID_PRICES_SIZE"); for (uint256 i = 0; i < ids.length; i++) { Pass storage pass = _passes[ids[i]]; require(pass.maxItems > 0, "TOKEN_ID_NOT_EXIST"); pass.price = prices[i]; } emit PricesChanged(ids, prices); } /// @dev After doing the setup, this method can be used to modify the maximum items for a pass /// @param ids The ids of the passes /// @param maxItems The maximum number of items function setMaxItems(uint256[] memory ids, uint256[] memory maxItems) external onlyRole(OPERATOR_ROLE) { require(ids.length > 0, "INVALID_TOKENS_SIZE"); require(maxItems.length == ids.length, "INVALID_MAX_ITEMS_SIZE"); for (uint256 i = 0; i < ids.length; i++) { require(maxItems[i] > 0, "INVALID_MAX_ITEM"); Pass storage pass = _passes[ids[i]]; require(pass.maxItems > 0, "TOKEN_ID_NOT_EXIST"); pass.maxItems = maxItems[i]; } emit MaxItemsChanged(ids, maxItems); } /// @dev This method can be used to modify the uri for the passes /// @param newUri The uri to be used, it should contain the {id} string. /// See: https://eips.ethereum.org/EIPS/eip-1155#metadata-extensions function setURI(string memory newUri) external onlyRole(OPERATOR_ROLE) { _setURI(newUri); emit UriChanged(newUri); } /// @dev This method can be used to mint a pass using a signature. /// The main advantage of a signature over a Merkle Tree is that // there is no need to update the root if the whitelist changes. /// @param passId The id of the pass /// @param amount The amount of passes to mint /// @param nonce A value that should be unique per parameter combination. It helps the prevention of double minting /// @param signature The signature for the operation, it is generated off-chain. /// See: https://github.com/OpenZeppelin/workshops/tree/master/06-nft-merkle-drop function mintPass( uint256 passId, uint256 amount, uint256 nonce, bytes calldata signature ) external payable { require(!paused(), "CONTRACT_PAUSED"); Pass storage pass = _passes[passId]; require(pass.maxItems > 0, "TOKEN_ID_NOT_EXIST"); bytes32 hash = _hash(msg.sender, passId, amount, nonce); require(_verify(hash, signature), "INVALID_SIGNATURE"); require(_redeemedPasses[hash] == address(0), "TOKEN_ALREADY_REDEEMED"); require(block.timestamp >= pass.open, "INVALID_OPEN_DATE"); require(block.timestamp <= pass.close, "INVALID_CLOSE_DATE"); if (pass.maxPerTransaction > 0) { require( amount <= pass.maxPerTransaction, "INVALID_MAX_PER_TRANSACTION" ); } if (pass.maxPerWallet > 0) { uint256 balance = balanceOf(msg.sender, passId); require( (balance + amount) <= pass.maxPerWallet, "INVALID_MAX_PER_WALLET" ); } if (pass.price > 0) { require(msg.value >= (pass.price * amount), "VALUE_BELOW_PRICE"); } require( (totalSupply(passId) + amount) <= pass.maxItems, "PURCHASE_EXCEED_MAX_ITEMS" ); _mint(msg.sender, passId, amount, ""); _redeemedPasses[hash] = msg.sender; emit RedeemedPass(hash, msg.sender); } function burnFromRedeemedToken( address account, uint256 id, uint256 amount ) external { require(!paused(), "CONTRACT_PAUSED"); Pass storage pass = _passes[id]; require(pass.maxItems > 0, "TOKEN_ID_NOT_EXIST"); require(pass.redeemContract != address(0), "INVALID_CONTRACT_ADDRESS"); require(msg.sender == pass.redeemContract, "INVALID_SENDER_ADDRESS"); _burn(account, id, amount); } function mint( address account, uint256 tokenId, uint256 amount, bytes memory data ) external onlyRole(OPERATOR_ROLE) { require(!paused(), "CONTRACT_PAUSED"); Pass storage pass = _passes[tokenId]; require(pass.maxItems > 0, "TOKEN_ID_NOT_EXIST"); require( (totalSupply(tokenId) + amount) <= pass.maxItems, "PURCHASE_EXCEED_MAX_ITEMS" ); _mint(account, tokenId, amount, data); } function mintBatch( address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) external onlyRole(OPERATOR_ROLE) { require(!paused(), "CONTRACT_PAUSED"); _mintBatch(to, ids, amounts, data); } function _burn( address account, uint256 id, uint256 amount ) internal override(ERC1155, ERC1155Supply) { super._burn(account, id, amount); } function _burnBatch( address account, uint256[] memory ids, uint256[] memory amounts ) internal override(ERC1155, ERC1155Supply) { super._burnBatch(account, ids, amounts); } function _mint( address account, uint256 id, uint256 amount, bytes memory data ) internal override(ERC1155, ERC1155Supply) { super._mint(account, id, amount, data); } function _mintBatch( address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) internal override(ERC1155, ERC1155Supply) { super._mintBatch(to, ids, amounts, data); } function _beforeTokenTransfer( address operator, address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) internal override(ERC1155) whenNotPaused { super._beforeTokenTransfer(operator, from, to, ids, amounts, data); } function supportsInterface(bytes4 interfaceId) public view override(ERC1155, AccessControl) returns (bool) { return super.supportsInterface(interfaceId); } function withdraw(uint256 amount, address payable to) external onlyRole(WITHDRAWER_ROLE) { uint256 balance = address(this).balance; require(balance > 0, "BALANCE_ZERO"); require(balance >= amount, "AMOUNT_GT_BALANCE"); // solhint-disable-next-line (bool sent, ) = to.call{value: amount}(""); require(sent, "WITHDRAW_FAILED"); } function _hash( address account, uint256 tokenId, uint256 amount, uint256 nonce ) internal view returns (bytes32) { return _hashTypedDataV4( keccak256( abi.encode( keccak256( "NFT(address account,uint256 tokenId,uint256 amount,uint256 nonce)" ), account, tokenId, amount, nonce ) ) ); } function _verify(bytes32 digest, bytes memory signature) internal view returns (bool) { return hasRole(SIGNER_ROLE, ECDSA.recover(digest, signature)); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./IERC1155.sol"; import "./IERC1155Receiver.sol"; import "./extensions/IERC1155MetadataURI.sol"; import "../../utils/Address.sol"; import "../../utils/Context.sol"; import "../../utils/introspection/ERC165.sol"; /** * @dev Implementation of the basic standard multi-token. * See https://eips.ethereum.org/EIPS/eip-1155 * Originally based on code by Enjin: https://github.com/enjin/erc-1155 * * _Available since v3.1._ */ contract ERC1155 is Context, ERC165, IERC1155, IERC1155MetadataURI { using Address for address; // Mapping from token ID to account balances mapping(uint256 => mapping(address => uint256)) private _balances; // Mapping from account to operator approvals mapping(address => mapping(address => bool)) private _operatorApprovals; // Used as the URI for all token types by relying on ID substitution, e.g. https://token-cdn-domain/{id}.json string private _uri; /** * @dev See {_setURI}. */ constructor(string memory uri_) { _setURI(uri_); } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { return interfaceId == type(IERC1155).interfaceId || interfaceId == type(IERC1155MetadataURI).interfaceId || super.supportsInterface(interfaceId); } /** * @dev See {IERC1155MetadataURI-uri}. * * This implementation returns the same URI for *all* token types. It relies * on the token type ID substitution mechanism * https://eips.ethereum.org/EIPS/eip-1155#metadata[defined in the EIP]. * * Clients calling this function must replace the `\{id\}` substring with the * actual token type ID. */ function uri(uint256) public view virtual override returns (string memory) { return _uri; } /** * @dev See {IERC1155-balanceOf}. * * Requirements: * * - `account` cannot be the zero address. */ function balanceOf(address account, uint256 id) public view virtual override returns (uint256) { require(account != address(0), "ERC1155: balance query for the zero address"); return _balances[id][account]; } /** * @dev See {IERC1155-balanceOfBatch}. * * Requirements: * * - `accounts` and `ids` must have the same length. */ function balanceOfBatch(address[] memory accounts, uint256[] memory ids) public view virtual override returns (uint256[] memory) { require(accounts.length == ids.length, "ERC1155: accounts and ids length mismatch"); uint256[] memory batchBalances = new uint256[](accounts.length); for (uint256 i = 0; i < accounts.length; ++i) { batchBalances[i] = balanceOf(accounts[i], ids[i]); } return batchBalances; } /** * @dev See {IERC1155-setApprovalForAll}. */ function setApprovalForAll(address operator, bool approved) public virtual override { require(_msgSender() != operator, "ERC1155: setting approval status for self"); _operatorApprovals[_msgSender()][operator] = approved; emit ApprovalForAll(_msgSender(), operator, approved); } /** * @dev See {IERC1155-isApprovedForAll}. */ function isApprovedForAll(address account, address operator) public view virtual override returns (bool) { return _operatorApprovals[account][operator]; } /** * @dev See {IERC1155-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 id, uint256 amount, bytes memory data ) public virtual override { require( from == _msgSender() || isApprovedForAll(from, _msgSender()), "ERC1155: caller is not owner nor approved" ); _safeTransferFrom(from, to, id, amount, data); } /** * @dev See {IERC1155-safeBatchTransferFrom}. */ function safeBatchTransferFrom( address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) public virtual override { require( from == _msgSender() || isApprovedForAll(from, _msgSender()), "ERC1155: transfer caller is not owner nor approved" ); _safeBatchTransferFrom(from, to, ids, amounts, data); } /** * @dev Transfers `amount` tokens of token type `id` from `from` to `to`. * * Emits a {TransferSingle} event. * * Requirements: * * - `to` cannot be the zero address. * - `from` must have a balance of tokens of type `id` of at least `amount`. * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155Received} and return the * acceptance magic value. */ function _safeTransferFrom( address from, address to, uint256 id, uint256 amount, bytes memory data ) internal virtual { require(to != address(0), "ERC1155: transfer to the zero address"); address operator = _msgSender(); _beforeTokenTransfer(operator, from, to, _asSingletonArray(id), _asSingletonArray(amount), data); uint256 fromBalance = _balances[id][from]; require(fromBalance >= amount, "ERC1155: insufficient balance for transfer"); unchecked { _balances[id][from] = fromBalance - amount; } _balances[id][to] += amount; emit TransferSingle(operator, from, to, id, amount); _doSafeTransferAcceptanceCheck(operator, from, to, id, amount, data); } /** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {_safeTransferFrom}. * * Emits a {TransferBatch} event. * * Requirements: * * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155BatchReceived} and return the * acceptance magic value. */ function _safeBatchTransferFrom( address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) internal virtual { require(ids.length == amounts.length, "ERC1155: ids and amounts length mismatch"); require(to != address(0), "ERC1155: transfer to the zero address"); address operator = _msgSender(); _beforeTokenTransfer(operator, from, to, ids, amounts, data); for (uint256 i = 0; i < ids.length; ++i) { uint256 id = ids[i]; uint256 amount = amounts[i]; uint256 fromBalance = _balances[id][from]; require(fromBalance >= amount, "ERC1155: insufficient balance for transfer"); unchecked { _balances[id][from] = fromBalance - amount; } _balances[id][to] += amount; } emit TransferBatch(operator, from, to, ids, amounts); _doSafeBatchTransferAcceptanceCheck(operator, from, to, ids, amounts, data); } /** * @dev Sets a new URI for all token types, by relying on the token type ID * substitution mechanism * https://eips.ethereum.org/EIPS/eip-1155#metadata[defined in the EIP]. * * By this mechanism, any occurrence of the `\{id\}` substring in either the * URI or any of the amounts in the JSON file at said URI will be replaced by * clients with the token type ID. * * For example, the `https://token-cdn-domain/\{id\}.json` URI would be * interpreted by clients as * `https://token-cdn-domain/000000000000000000000000000000000000000000000000000000000004cce0.json` * for token type ID 0x4cce0. * * See {uri}. * * Because these URIs cannot be meaningfully represented by the {URI} event, * this function emits no events. */ function _setURI(string memory newuri) internal virtual { _uri = newuri; } /** * @dev Creates `amount` tokens of token type `id`, and assigns them to `account`. * * Emits a {TransferSingle} event. * * Requirements: * * - `account` cannot be the zero address. * - If `account` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155Received} and return the * acceptance magic value. */ function _mint( address account, uint256 id, uint256 amount, bytes memory data ) internal virtual { require(account != address(0), "ERC1155: mint to the zero address"); address operator = _msgSender(); _beforeTokenTransfer(operator, address(0), account, _asSingletonArray(id), _asSingletonArray(amount), data); _balances[id][account] += amount; emit TransferSingle(operator, address(0), account, id, amount); _doSafeTransferAcceptanceCheck(operator, address(0), account, id, amount, data); } /** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {_mint}. * * Requirements: * * - `ids` and `amounts` must have the same length. * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155BatchReceived} and return the * acceptance magic value. */ function _mintBatch( address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) internal virtual { require(to != address(0), "ERC1155: mint to the zero address"); require(ids.length == amounts.length, "ERC1155: ids and amounts length mismatch"); address operator = _msgSender(); _beforeTokenTransfer(operator, address(0), to, ids, amounts, data); for (uint256 i = 0; i < ids.length; i++) { _balances[ids[i]][to] += amounts[i]; } emit TransferBatch(operator, address(0), to, ids, amounts); _doSafeBatchTransferAcceptanceCheck(operator, address(0), to, ids, amounts, data); } /** * @dev Destroys `amount` tokens of token type `id` from `account` * * Requirements: * * - `account` cannot be the zero address. * - `account` must have at least `amount` tokens of token type `id`. */ function _burn( address account, uint256 id, uint256 amount ) internal virtual { require(account != address(0), "ERC1155: burn from the zero address"); address operator = _msgSender(); _beforeTokenTransfer(operator, account, address(0), _asSingletonArray(id), _asSingletonArray(amount), ""); uint256 accountBalance = _balances[id][account]; require(accountBalance >= amount, "ERC1155: burn amount exceeds balance"); unchecked { _balances[id][account] = accountBalance - amount; } emit TransferSingle(operator, account, address(0), id, amount); } /** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {_burn}. * * Requirements: * * - `ids` and `amounts` must have the same length. */ function _burnBatch( address account, uint256[] memory ids, uint256[] memory amounts ) internal virtual { require(account != address(0), "ERC1155: burn from the zero address"); require(ids.length == amounts.length, "ERC1155: ids and amounts length mismatch"); address operator = _msgSender(); _beforeTokenTransfer(operator, account, address(0), ids, amounts, ""); for (uint256 i = 0; i < ids.length; i++) { uint256 id = ids[i]; uint256 amount = amounts[i]; uint256 accountBalance = _balances[id][account]; require(accountBalance >= amount, "ERC1155: burn amount exceeds balance"); unchecked { _balances[id][account] = accountBalance - amount; } } emit TransferBatch(operator, account, address(0), ids, amounts); } /** * @dev Hook that is called before any token transfer. This includes minting * and burning, as well as batched variants. * * The same hook is called on both single and batched variants. For single * transfers, the length of the `id` and `amount` arrays will be 1. * * Calling conditions (for each `id` and `amount` pair): * * - When `from` and `to` are both non-zero, `amount` of ``from``'s tokens * of token type `id` will be transferred to `to`. * - When `from` is zero, `amount` tokens of token type `id` will be minted * for `to`. * - when `to` is zero, `amount` of ``from``'s tokens of token type `id` * will be burned. * - `from` and `to` are never both zero. * - `ids` and `amounts` have the same, non-zero length. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _beforeTokenTransfer( address operator, address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) internal virtual {} function _doSafeTransferAcceptanceCheck( address operator, address from, address to, uint256 id, uint256 amount, bytes memory data ) private { if (to.isContract()) { try IERC1155Receiver(to).onERC1155Received(operator, from, id, amount, data) returns (bytes4 response) { if (response != IERC1155Receiver.onERC1155Received.selector) { revert("ERC1155: ERC1155Receiver rejected tokens"); } } catch Error(string memory reason) { revert(reason); } catch { revert("ERC1155: transfer to non ERC1155Receiver implementer"); } } } function _doSafeBatchTransferAcceptanceCheck( address operator, address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) private { if (to.isContract()) { try IERC1155Receiver(to).onERC1155BatchReceived(operator, from, ids, amounts, data) returns ( bytes4 response ) { if (response != IERC1155Receiver.onERC1155BatchReceived.selector) { revert("ERC1155: ERC1155Receiver rejected tokens"); } } catch Error(string memory reason) { revert(reason); } catch { revert("ERC1155: transfer to non ERC1155Receiver implementer"); } } } function _asSingletonArray(uint256 element) private pure returns (uint256[] memory) { uint256[] memory array = new uint256[](1); array[0] = element; return array; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./IAccessControl.sol"; import "../utils/Context.sol"; import "../utils/Strings.sol"; import "../utils/introspection/ERC165.sol"; /** * @dev Contract module that allows children to implement role-based access * control mechanisms. This is a lightweight version that doesn't allow enumerating role * members except through off-chain means by accessing the contract event logs. Some * applications may benefit from on-chain enumerability, for those cases see * {AccessControlEnumerable}. * * Roles are referred to by their `bytes32` identifier. These should be exposed * in the external API and be unique. The best way to achieve this is by * using `public constant` hash digests: * * ``` * bytes32 public constant MY_ROLE = keccak256("MY_ROLE"); * ``` * * Roles can be used to represent a set of permissions. To restrict access to a * function call, use {hasRole}: * * ``` * function foo() public { * require(hasRole(MY_ROLE, msg.sender)); * ... * } * ``` * * Roles can be granted and revoked dynamically via the {grantRole} and * {revokeRole} functions. Each role has an associated admin role, and only * accounts that have a role's admin role can call {grantRole} and {revokeRole}. * * By default, the admin role for all roles is `DEFAULT_ADMIN_ROLE`, which means * that only accounts with this role will be able to grant or revoke other * roles. More complex role relationships can be created by using * {_setRoleAdmin}. * * WARNING: The `DEFAULT_ADMIN_ROLE` is also its own admin: it has permission to * grant and revoke this role. Extra precautions should be taken to secure * accounts that have been granted it. */ abstract contract AccessControl is Context, IAccessControl, ERC165 { struct RoleData { mapping(address => bool) members; bytes32 adminRole; } mapping(bytes32 => RoleData) private _roles; bytes32 public constant DEFAULT_ADMIN_ROLE = 0x00; /** * @dev Modifier that checks that an account has a specific role. Reverts * with a standardized message including the required role. * * The format of the revert reason is given by the following regular expression: * * /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/ * * _Available since v4.1._ */ modifier onlyRole(bytes32 role) { _checkRole(role, _msgSender()); _; } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IAccessControl).interfaceId || super.supportsInterface(interfaceId); } /** * @dev Returns `true` if `account` has been granted `role`. */ function hasRole(bytes32 role, address account) public view override returns (bool) { return _roles[role].members[account]; } /** * @dev Revert with a standard message if `account` is missing `role`. * * The format of the revert reason is given by the following regular expression: * * /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/ */ function _checkRole(bytes32 role, address account) internal view { if (!hasRole(role, account)) { revert( string( abi.encodePacked( "AccessControl: account ", Strings.toHexString(uint160(account), 20), " is missing role ", Strings.toHexString(uint256(role), 32) ) ) ); } } /** * @dev Returns the admin role that controls `role`. See {grantRole} and * {revokeRole}. * * To change a role's admin, use {_setRoleAdmin}. */ function getRoleAdmin(bytes32 role) public view override returns (bytes32) { return _roles[role].adminRole; } /** * @dev Grants `role` to `account`. * * If `account` had not been already granted `role`, emits a {RoleGranted} * event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function grantRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) { _grantRole(role, account); } /** * @dev Revokes `role` from `account`. * * If `account` had been granted `role`, emits a {RoleRevoked} event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function revokeRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) { _revokeRole(role, account); } /** * @dev Revokes `role` from the calling account. * * Roles are often managed via {grantRole} and {revokeRole}: this function's * purpose is to provide a mechanism for accounts to lose their privileges * if they are compromised (such as when a trusted device is misplaced). * * If the calling account had been granted `role`, emits a {RoleRevoked} * event. * * Requirements: * * - the caller must be `account`. */ function renounceRole(bytes32 role, address account) public virtual override { require(account == _msgSender(), "AccessControl: can only renounce roles for self"); _revokeRole(role, account); } /** * @dev Grants `role` to `account`. * * If `account` had not been already granted `role`, emits a {RoleGranted} * event. Note that unlike {grantRole}, this function doesn't perform any * checks on the calling account. * * [WARNING] * ==== * This function should only be called from the constructor when setting * up the initial roles for the system. * * Using this function in any other way is effectively circumventing the admin * system imposed by {AccessControl}. * ==== */ function _setupRole(bytes32 role, address account) internal virtual { _grantRole(role, account); } /** * @dev Sets `adminRole` as ``role``'s admin role. * * Emits a {RoleAdminChanged} event. */ function _setRoleAdmin(bytes32 role, bytes32 adminRole) internal virtual { bytes32 previousAdminRole = getRoleAdmin(role); _roles[role].adminRole = adminRole; emit RoleAdminChanged(role, previousAdminRole, adminRole); } function _grantRole(bytes32 role, address account) private { if (!hasRole(role, account)) { _roles[role].members[account] = true; emit RoleGranted(role, account, _msgSender()); } } function _revokeRole(bytes32 role, address account) private { if (hasRole(role, account)) { _roles[role].members[account] = false; emit RoleRevoked(role, account, _msgSender()); } } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../utils/Context.sol"; /** * @dev Contract module which allows children to implement an emergency stop * mechanism that can be triggered by an authorized account. * * This module is used through inheritance. It will make available the * modifiers `whenNotPaused` and `whenPaused`, which can be applied to * the functions of your contract. Note that they will not be pausable by * simply including this module, only once the modifiers are put in place. */ abstract contract Pausable is Context { /** * @dev Emitted when the pause is triggered by `account`. */ event Paused(address account); /** * @dev Emitted when the pause is lifted by `account`. */ event Unpaused(address account); bool private _paused; /** * @dev Initializes the contract in unpaused state. */ constructor() { _paused = false; } /** * @dev Returns true if the contract is paused, and false otherwise. */ function paused() public view virtual returns (bool) { return _paused; } /** * @dev Modifier to make a function callable only when the contract is not paused. * * Requirements: * * - The contract must not be paused. */ modifier whenNotPaused() { require(!paused(), "Pausable: paused"); _; } /** * @dev Modifier to make a function callable only when the contract is paused. * * Requirements: * * - The contract must be paused. */ modifier whenPaused() { require(paused(), "Pausable: not paused"); _; } /** * @dev Triggers stopped state. * * Requirements: * * - The contract must not be paused. */ function _pause() internal virtual whenNotPaused { _paused = true; emit Paused(_msgSender()); } /** * @dev Returns to normal state. * * Requirements: * * - The contract must be paused. */ function _unpause() internal virtual whenPaused { _paused = false; emit Unpaused(_msgSender()); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../ERC1155.sol"; /** * @dev Extension of {ERC1155} that allows token holders to destroy both their * own tokens and those that they have been approved to use. * * _Available since v3.1._ */ abstract contract ERC1155Burnable is ERC1155 { function burn( address account, uint256 id, uint256 value ) public virtual { require( account == _msgSender() || isApprovedForAll(account, _msgSender()), "ERC1155: caller is not owner nor approved" ); _burn(account, id, value); } function burnBatch( address account, uint256[] memory ids, uint256[] memory values ) public virtual { require( account == _msgSender() || isApprovedForAll(account, _msgSender()), "ERC1155: caller is not owner nor approved" ); _burnBatch(account, ids, values); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../ERC1155.sol"; /** * @dev Extension of ERC1155 that adds tracking of total supply per id. * * Useful for scenarios where Fungible and Non-fungible tokens have to be * clearly identified. Note: While a totalSupply of 1 might mean the * corresponding is an NFT, there is no guarantees that no other token with the * same id are not going to be minted. */ abstract contract ERC1155Supply is ERC1155 { mapping(uint256 => uint256) private _totalSupply; /** * @dev Total amount of tokens in with a given id. */ function totalSupply(uint256 id) public view virtual returns (uint256) { return _totalSupply[id]; } /** * @dev Indicates weither any token exist with a given id, or not. */ function exists(uint256 id) public view virtual returns (bool) { return ERC1155Supply.totalSupply(id) > 0; } /** * @dev See {ERC1155-_mint}. */ function _mint( address account, uint256 id, uint256 amount, bytes memory data ) internal virtual override { super._mint(account, id, amount, data); _totalSupply[id] += amount; } /** * @dev See {ERC1155-_mintBatch}. */ function _mintBatch( address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) internal virtual override { super._mintBatch(to, ids, amounts, data); for (uint256 i = 0; i < ids.length; ++i) { _totalSupply[ids[i]] += amounts[i]; } } /** * @dev See {ERC1155-_burn}. */ function _burn( address account, uint256 id, uint256 amount ) internal virtual override { super._burn(account, id, amount); _totalSupply[id] -= amount; } /** * @dev See {ERC1155-_burnBatch}. */ function _burnBatch( address account, uint256[] memory ids, uint256[] memory amounts ) internal virtual override { super._burnBatch(account, ids, amounts); for (uint256 i = 0; i < ids.length; ++i) { _totalSupply[ids[i]] -= amounts[i]; } } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./ECDSA.sol"; /** * @dev https://eips.ethereum.org/EIPS/eip-712[EIP 712] is a standard for hashing and signing of typed structured data. * * The encoding specified in the EIP is very generic, and such a generic implementation in Solidity is not feasible, * thus this contract does not implement the encoding itself. Protocols need to implement the type-specific encoding * they need in their contracts using a combination of `abi.encode` and `keccak256`. * * This contract implements the EIP 712 domain separator ({_domainSeparatorV4}) that is used as part of the encoding * scheme, and the final step of the encoding to obtain the message digest that is then signed via ECDSA * ({_hashTypedDataV4}). * * The implementation of the domain separator was designed to be as efficient as possible while still properly updating * the chain id to protect against replay attacks on an eventual fork of the chain. * * NOTE: This contract implements the version of the encoding known as "v4", as implemented by the JSON RPC method * https://docs.metamask.io/guide/signing-data.html[`eth_signTypedDataV4` in MetaMask]. * * _Available since v3.4._ */ abstract contract EIP712 { /* solhint-disable var-name-mixedcase */ // Cache the domain separator as an immutable value, but also store the chain id that it corresponds to, in order to // invalidate the cached domain separator if the chain id changes. bytes32 private immutable _CACHED_DOMAIN_SEPARATOR; uint256 private immutable _CACHED_CHAIN_ID; bytes32 private immutable _HASHED_NAME; bytes32 private immutable _HASHED_VERSION; bytes32 private immutable _TYPE_HASH; /* solhint-enable var-name-mixedcase */ /** * @dev Initializes the domain separator and parameter caches. * * The meaning of `name` and `version` is specified in * https://eips.ethereum.org/EIPS/eip-712#definition-of-domainseparator[EIP 712]: * * - `name`: the user readable name of the signing domain, i.e. the name of the DApp or the protocol. * - `version`: the current major version of the signing domain. * * NOTE: These parameters cannot be changed except through a xref:learn::upgrading-smart-contracts.adoc[smart * contract upgrade]. */ constructor(string memory name, string memory version) { bytes32 hashedName = keccak256(bytes(name)); bytes32 hashedVersion = keccak256(bytes(version)); bytes32 typeHash = keccak256( "EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)" ); _HASHED_NAME = hashedName; _HASHED_VERSION = hashedVersion; _CACHED_CHAIN_ID = block.chainid; _CACHED_DOMAIN_SEPARATOR = _buildDomainSeparator(typeHash, hashedName, hashedVersion); _TYPE_HASH = typeHash; } /** * @dev Returns the domain separator for the current chain. */ function _domainSeparatorV4() internal view returns (bytes32) { if (block.chainid == _CACHED_CHAIN_ID) { return _CACHED_DOMAIN_SEPARATOR; } else { return _buildDomainSeparator(_TYPE_HASH, _HASHED_NAME, _HASHED_VERSION); } } function _buildDomainSeparator( bytes32 typeHash, bytes32 nameHash, bytes32 versionHash ) private view returns (bytes32) { return keccak256(abi.encode(typeHash, nameHash, versionHash, block.chainid, address(this))); } /** * @dev Given an already https://eips.ethereum.org/EIPS/eip-712#definition-of-hashstruct[hashed struct], this * function returns the hash of the fully encoded EIP712 message for this domain. * * This hash can be used together with {ECDSA-recover} to obtain the signer of a message. For example: * * ```solidity * bytes32 digest = _hashTypedDataV4(keccak256(abi.encode( * keccak256("Mail(address to,string contents)"), * mailTo, * keccak256(bytes(mailContents)) * ))); * address signer = ECDSA.recover(digest, signature); * ``` */ function _hashTypedDataV4(bytes32 structHash) internal view virtual returns (bytes32) { return ECDSA.toTypedDataHash(_domainSeparatorV4(), structHash); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Elliptic Curve Digital Signature Algorithm (ECDSA) operations. * * These functions can be used to verify that a message was signed by the holder * of the private keys of a given address. */ library ECDSA { enum RecoverError { NoError, InvalidSignature, InvalidSignatureLength, InvalidSignatureS, InvalidSignatureV } function _throwError(RecoverError error) private pure { if (error == RecoverError.NoError) { return; // no error: do nothing } else if (error == RecoverError.InvalidSignature) { revert("ECDSA: invalid signature"); } else if (error == RecoverError.InvalidSignatureLength) { revert("ECDSA: invalid signature length"); } else if (error == RecoverError.InvalidSignatureS) { revert("ECDSA: invalid signature 's' value"); } else if (error == RecoverError.InvalidSignatureV) { revert("ECDSA: invalid signature 'v' value"); } } /** * @dev Returns the address that signed a hashed message (`hash`) with * `signature` or error string. This address can then be used for verification purposes. * * The `ecrecover` EVM opcode allows for malleable (non-unique) signatures: * this function rejects them by requiring the `s` value to be in the lower * half order, and the `v` value to be either 27 or 28. * * IMPORTANT: `hash` _must_ be the result of a hash operation for the * verification to be secure: it is possible to craft signatures that * recover to arbitrary addresses for non-hashed data. A safe way to ensure * this is by receiving a hash of the original message (which may otherwise * be too long), and then calling {toEthSignedMessageHash} on it. * * Documentation for signature generation: * - with https://web3js.readthedocs.io/en/v1.3.4/web3-eth-accounts.html#sign[Web3.js] * - with https://docs.ethers.io/v5/api/signer/#Signer-signMessage[ethers] * * _Available since v4.3._ */ function tryRecover(bytes32 hash, bytes memory signature) internal pure returns (address, RecoverError) { // Check the signature length // - case 65: r,s,v signature (standard) // - case 64: r,vs signature (cf https://eips.ethereum.org/EIPS/eip-2098) _Available since v4.1._ if (signature.length == 65) { bytes32 r; bytes32 s; uint8 v; // ecrecover takes the signature parameters, and the only way to get them // currently is to use assembly. assembly { r := mload(add(signature, 0x20)) s := mload(add(signature, 0x40)) v := byte(0, mload(add(signature, 0x60))) } return tryRecover(hash, v, r, s); } else if (signature.length == 64) { bytes32 r; bytes32 vs; // ecrecover takes the signature parameters, and the only way to get them // currently is to use assembly. assembly { r := mload(add(signature, 0x20)) vs := mload(add(signature, 0x40)) } return tryRecover(hash, r, vs); } else { return (address(0), RecoverError.InvalidSignatureLength); } } /** * @dev Returns the address that signed a hashed message (`hash`) with * `signature`. This address can then be used for verification purposes. * * The `ecrecover` EVM opcode allows for malleable (non-unique) signatures: * this function rejects them by requiring the `s` value to be in the lower * half order, and the `v` value to be either 27 or 28. * * IMPORTANT: `hash` _must_ be the result of a hash operation for the * verification to be secure: it is possible to craft signatures that * recover to arbitrary addresses for non-hashed data. A safe way to ensure * this is by receiving a hash of the original message (which may otherwise * be too long), and then calling {toEthSignedMessageHash} on it. */ function recover(bytes32 hash, bytes memory signature) internal pure returns (address) { (address recovered, RecoverError error) = tryRecover(hash, signature); _throwError(error); return recovered; } /** * @dev Overload of {ECDSA-tryRecover} that receives the `r` and `vs` short-signature fields separately. * * See https://eips.ethereum.org/EIPS/eip-2098[EIP-2098 short signatures] * * _Available since v4.3._ */ function tryRecover( bytes32 hash, bytes32 r, bytes32 vs ) internal pure returns (address, RecoverError) { bytes32 s; uint8 v; assembly { s := and(vs, 0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff) v := add(shr(255, vs), 27) } return tryRecover(hash, v, r, s); } /** * @dev Overload of {ECDSA-recover} that receives the `r and `vs` short-signature fields separately. * * _Available since v4.2._ */ function recover( bytes32 hash, bytes32 r, bytes32 vs ) internal pure returns (address) { (address recovered, RecoverError error) = tryRecover(hash, r, vs); _throwError(error); return recovered; } /** * @dev Overload of {ECDSA-tryRecover} that receives the `v`, * `r` and `s` signature fields separately. * * _Available since v4.3._ */ function tryRecover( bytes32 hash, uint8 v, bytes32 r, bytes32 s ) internal pure returns (address, RecoverError) { // EIP-2 still allows signature malleability for ecrecover(). Remove this possibility and make the signature // unique. Appendix F in the Ethereum Yellow paper (https://ethereum.github.io/yellowpaper/paper.pdf), defines // the valid range for s in (301): 0 < s < secp256k1n ÷ 2 + 1, and for v in (302): v ∈ {27, 28}. Most // signatures from current libraries generate a unique signature with an s-value in the lower half order. // // If your library generates malleable signatures, such as s-values in the upper range, calculate a new s-value // with 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141 - s1 and flip v from 27 to 28 or // vice versa. If your library also generates signatures with 0/1 for v instead 27/28, add 27 to v to accept // these malleable signatures as well. if (uint256(s) > 0x7FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF5D576E7357A4501DDFE92F46681B20A0) { return (address(0), RecoverError.InvalidSignatureS); } if (v != 27 && v != 28) { return (address(0), RecoverError.InvalidSignatureV); } // If the signature is valid (and not malleable), return the signer address address signer = ecrecover(hash, v, r, s); if (signer == address(0)) { return (address(0), RecoverError.InvalidSignature); } return (signer, RecoverError.NoError); } /** * @dev Overload of {ECDSA-recover} that receives the `v`, * `r` and `s` signature fields separately. */ function recover( bytes32 hash, uint8 v, bytes32 r, bytes32 s ) internal pure returns (address) { (address recovered, RecoverError error) = tryRecover(hash, v, r, s); _throwError(error); return recovered; } /** * @dev Returns an Ethereum Signed Message, created from a `hash`. This * produces hash corresponding to the one signed with the * https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`] * JSON-RPC method as part of EIP-191. * * See {recover}. */ function toEthSignedMessageHash(bytes32 hash) internal pure returns (bytes32) { // 32 is the length in bytes of hash, // enforced by the type signature above return keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n32", hash)); } /** * @dev Returns an Ethereum Signed Typed Data, created from a * `domainSeparator` and a `structHash`. This produces hash corresponding * to the one signed with the * https://eips.ethereum.org/EIPS/eip-712[`eth_signTypedData`] * JSON-RPC method as part of EIP-712. * * See {recover}. */ function toTypedDataHash(bytes32 domainSeparator, bytes32 structHash) internal pure returns (bytes32) { return keccak256(abi.encodePacked("\x19\x01", domainSeparator, structHash)); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @title Counters * @author Matt Condon (@shrugs) * @dev Provides counters that can only be incremented, decremented or reset. This can be used e.g. to track the number * of elements in a mapping, issuing ERC721 ids, or counting request ids. * * Include with `using Counters for Counters.Counter;` */ library Counters { struct Counter { // This variable should never be directly accessed by users of the library: interactions must be restricted to // the library's function. As of Solidity v0.5.2, this cannot be enforced, though there is a proposal to add // this feature: see https://github.com/ethereum/solidity/issues/4637 uint256 _value; // default: 0 } function current(Counter storage counter) internal view returns (uint256) { return counter._value; } function increment(Counter storage counter) internal { unchecked { counter._value += 1; } } function decrement(Counter storage counter) internal { uint256 value = counter._value; require(value > 0, "Counter: decrement overflow"); unchecked { counter._value = value - 1; } } function reset(Counter storage counter) internal { counter._value = 0; } }
// SPDX-License-Identifier: MIT pragma solidity >= 0.4.22 <0.9.0; library console { address constant CONSOLE_ADDRESS = address(0x000000000000000000636F6e736F6c652e6c6f67); function _sendLogPayload(bytes memory payload) private view { uint256 payloadLength = payload.length; address consoleAddress = CONSOLE_ADDRESS; assembly { let payloadStart := add(payload, 32) let r := staticcall(gas(), consoleAddress, payloadStart, payloadLength, 0, 0) } } function log() internal view { _sendLogPayload(abi.encodeWithSignature("log()")); } function logInt(int p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(int)", p0)); } function logUint(uint p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint)", p0)); } function logString(string memory p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(string)", p0)); } function logBool(bool p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool)", p0)); } function logAddress(address p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(address)", p0)); } function logBytes(bytes memory p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes)", p0)); } function logBytes1(bytes1 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes1)", p0)); } function logBytes2(bytes2 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes2)", p0)); } function logBytes3(bytes3 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes3)", p0)); } function logBytes4(bytes4 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes4)", p0)); } function logBytes5(bytes5 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes5)", p0)); } function logBytes6(bytes6 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes6)", p0)); } function logBytes7(bytes7 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes7)", p0)); } function logBytes8(bytes8 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes8)", p0)); } function logBytes9(bytes9 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes9)", p0)); } function logBytes10(bytes10 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes10)", p0)); } function logBytes11(bytes11 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes11)", p0)); } function logBytes12(bytes12 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes12)", p0)); } function logBytes13(bytes13 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes13)", p0)); } function logBytes14(bytes14 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes14)", p0)); } function logBytes15(bytes15 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes15)", p0)); } function logBytes16(bytes16 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes16)", p0)); } function logBytes17(bytes17 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes17)", p0)); } function logBytes18(bytes18 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes18)", p0)); } function logBytes19(bytes19 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes19)", p0)); } function logBytes20(bytes20 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes20)", p0)); } function logBytes21(bytes21 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes21)", p0)); } function logBytes22(bytes22 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes22)", p0)); } function logBytes23(bytes23 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes23)", p0)); } function logBytes24(bytes24 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes24)", p0)); } function logBytes25(bytes25 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes25)", p0)); } function logBytes26(bytes26 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes26)", p0)); } function logBytes27(bytes27 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes27)", p0)); } function logBytes28(bytes28 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes28)", p0)); } function logBytes29(bytes29 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes29)", p0)); } function logBytes30(bytes30 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes30)", p0)); } function logBytes31(bytes31 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes31)", p0)); } function logBytes32(bytes32 p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bytes32)", p0)); } function log(uint p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint)", p0)); } function log(string memory p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(string)", p0)); } function log(bool p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool)", p0)); } function log(address p0) internal view { _sendLogPayload(abi.encodeWithSignature("log(address)", p0)); } function log(uint p0, uint p1) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,uint)", p0, p1)); } function log(uint p0, string memory p1) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,string)", p0, p1)); } function log(uint p0, bool p1) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,bool)", p0, p1)); } function log(uint p0, address p1) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,address)", p0, p1)); } function log(string memory p0, uint p1) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,uint)", p0, p1)); } function log(string memory p0, string memory p1) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,string)", p0, p1)); } function log(string memory p0, bool p1) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,bool)", p0, p1)); } function log(string memory p0, address p1) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,address)", p0, p1)); } function log(bool p0, uint p1) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,uint)", p0, p1)); } function log(bool p0, string memory p1) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,string)", p0, p1)); } function log(bool p0, bool p1) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,bool)", p0, p1)); } function log(bool p0, address p1) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,address)", p0, p1)); } function log(address p0, uint p1) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,uint)", p0, p1)); } function log(address p0, string memory p1) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,string)", p0, p1)); } function log(address p0, bool p1) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,bool)", p0, p1)); } function log(address p0, address p1) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,address)", p0, p1)); } function log(uint p0, uint p1, uint p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,uint,uint)", p0, p1, p2)); } function log(uint p0, uint p1, string memory p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,uint,string)", p0, p1, p2)); } function log(uint p0, uint p1, bool p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,uint,bool)", p0, p1, p2)); } function log(uint p0, uint p1, address p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,uint,address)", p0, p1, p2)); } function log(uint p0, string memory p1, uint p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,string,uint)", p0, p1, p2)); } function log(uint p0, string memory p1, string memory p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,string,string)", p0, p1, p2)); } function log(uint p0, string memory p1, bool p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,string,bool)", p0, p1, p2)); } function log(uint p0, string memory p1, address p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,string,address)", p0, p1, p2)); } function log(uint p0, bool p1, uint p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,bool,uint)", p0, p1, p2)); } function log(uint p0, bool p1, string memory p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,bool,string)", p0, p1, p2)); } function log(uint p0, bool p1, bool p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,bool,bool)", p0, p1, p2)); } function log(uint p0, bool p1, address p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,bool,address)", p0, p1, p2)); } function log(uint p0, address p1, uint p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,address,uint)", p0, p1, p2)); } function log(uint p0, address p1, string memory p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,address,string)", p0, p1, p2)); } function log(uint p0, address p1, bool p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,address,bool)", p0, p1, p2)); } function log(uint p0, address p1, address p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,address,address)", p0, p1, p2)); } function log(string memory p0, uint p1, uint p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,uint,uint)", p0, p1, p2)); } function log(string memory p0, uint p1, string memory p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,uint,string)", p0, p1, p2)); } function log(string memory p0, uint p1, bool p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,uint,bool)", p0, p1, p2)); } function log(string memory p0, uint p1, address p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,uint,address)", p0, p1, p2)); } function log(string memory p0, string memory p1, uint p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,string,uint)", p0, p1, p2)); } function log(string memory p0, string memory p1, string memory p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,string,string)", p0, p1, p2)); } function log(string memory p0, string memory p1, bool p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,string,bool)", p0, p1, p2)); } function log(string memory p0, string memory p1, address p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,string,address)", p0, p1, p2)); } function log(string memory p0, bool p1, uint p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,bool,uint)", p0, p1, p2)); } function log(string memory p0, bool p1, string memory p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,bool,string)", p0, p1, p2)); } function log(string memory p0, bool p1, bool p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,bool,bool)", p0, p1, p2)); } function log(string memory p0, bool p1, address p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,bool,address)", p0, p1, p2)); } function log(string memory p0, address p1, uint p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,address,uint)", p0, p1, p2)); } function log(string memory p0, address p1, string memory p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,address,string)", p0, p1, p2)); } function log(string memory p0, address p1, bool p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,address,bool)", p0, p1, p2)); } function log(string memory p0, address p1, address p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,address,address)", p0, p1, p2)); } function log(bool p0, uint p1, uint p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,uint,uint)", p0, p1, p2)); } function log(bool p0, uint p1, string memory p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,uint,string)", p0, p1, p2)); } function log(bool p0, uint p1, bool p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,uint,bool)", p0, p1, p2)); } function log(bool p0, uint p1, address p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,uint,address)", p0, p1, p2)); } function log(bool p0, string memory p1, uint p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,string,uint)", p0, p1, p2)); } function log(bool p0, string memory p1, string memory p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,string,string)", p0, p1, p2)); } function log(bool p0, string memory p1, bool p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,string,bool)", p0, p1, p2)); } function log(bool p0, string memory p1, address p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,string,address)", p0, p1, p2)); } function log(bool p0, bool p1, uint p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,bool,uint)", p0, p1, p2)); } function log(bool p0, bool p1, string memory p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,bool,string)", p0, p1, p2)); } function log(bool p0, bool p1, bool p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,bool,bool)", p0, p1, p2)); } function log(bool p0, bool p1, address p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,bool,address)", p0, p1, p2)); } function log(bool p0, address p1, uint p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,address,uint)", p0, p1, p2)); } function log(bool p0, address p1, string memory p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,address,string)", p0, p1, p2)); } function log(bool p0, address p1, bool p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,address,bool)", p0, p1, p2)); } function log(bool p0, address p1, address p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,address,address)", p0, p1, p2)); } function log(address p0, uint p1, uint p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,uint,uint)", p0, p1, p2)); } function log(address p0, uint p1, string memory p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,uint,string)", p0, p1, p2)); } function log(address p0, uint p1, bool p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,uint,bool)", p0, p1, p2)); } function log(address p0, uint p1, address p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,uint,address)", p0, p1, p2)); } function log(address p0, string memory p1, uint p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,string,uint)", p0, p1, p2)); } function log(address p0, string memory p1, string memory p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,string,string)", p0, p1, p2)); } function log(address p0, string memory p1, bool p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,string,bool)", p0, p1, p2)); } function log(address p0, string memory p1, address p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,string,address)", p0, p1, p2)); } function log(address p0, bool p1, uint p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,bool,uint)", p0, p1, p2)); } function log(address p0, bool p1, string memory p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,bool,string)", p0, p1, p2)); } function log(address p0, bool p1, bool p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,bool,bool)", p0, p1, p2)); } function log(address p0, bool p1, address p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,bool,address)", p0, p1, p2)); } function log(address p0, address p1, uint p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,address,uint)", p0, p1, p2)); } function log(address p0, address p1, string memory p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,address,string)", p0, p1, p2)); } function log(address p0, address p1, bool p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,address,bool)", p0, p1, p2)); } function log(address p0, address p1, address p2) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,address,address)", p0, p1, p2)); } function log(uint p0, uint p1, uint p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,uint,uint,uint)", p0, p1, p2, p3)); } function log(uint p0, uint p1, uint p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,uint,uint,string)", p0, p1, p2, p3)); } function log(uint p0, uint p1, uint p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,uint,uint,bool)", p0, p1, p2, p3)); } function log(uint p0, uint p1, uint p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,uint,uint,address)", p0, p1, p2, p3)); } function log(uint p0, uint p1, string memory p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,uint,string,uint)", p0, p1, p2, p3)); } function log(uint p0, uint p1, string memory p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,uint,string,string)", p0, p1, p2, p3)); } function log(uint p0, uint p1, string memory p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,uint,string,bool)", p0, p1, p2, p3)); } function log(uint p0, uint p1, string memory p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,uint,string,address)", p0, p1, p2, p3)); } function log(uint p0, uint p1, bool p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,uint,bool,uint)", p0, p1, p2, p3)); } function log(uint p0, uint p1, bool p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,uint,bool,string)", p0, p1, p2, p3)); } function log(uint p0, uint p1, bool p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,uint,bool,bool)", p0, p1, p2, p3)); } function log(uint p0, uint p1, bool p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,uint,bool,address)", p0, p1, p2, p3)); } function log(uint p0, uint p1, address p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,uint,address,uint)", p0, p1, p2, p3)); } function log(uint p0, uint p1, address p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,uint,address,string)", p0, p1, p2, p3)); } function log(uint p0, uint p1, address p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,uint,address,bool)", p0, p1, p2, p3)); } function log(uint p0, uint p1, address p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,uint,address,address)", p0, p1, p2, p3)); } function log(uint p0, string memory p1, uint p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,string,uint,uint)", p0, p1, p2, p3)); } function log(uint p0, string memory p1, uint p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,string,uint,string)", p0, p1, p2, p3)); } function log(uint p0, string memory p1, uint p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,string,uint,bool)", p0, p1, p2, p3)); } function log(uint p0, string memory p1, uint p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,string,uint,address)", p0, p1, p2, p3)); } function log(uint p0, string memory p1, string memory p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,string,string,uint)", p0, p1, p2, p3)); } function log(uint p0, string memory p1, string memory p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,string,string,string)", p0, p1, p2, p3)); } function log(uint p0, string memory p1, string memory p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,string,string,bool)", p0, p1, p2, p3)); } function log(uint p0, string memory p1, string memory p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,string,string,address)", p0, p1, p2, p3)); } function log(uint p0, string memory p1, bool p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,string,bool,uint)", p0, p1, p2, p3)); } function log(uint p0, string memory p1, bool p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,string,bool,string)", p0, p1, p2, p3)); } function log(uint p0, string memory p1, bool p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,string,bool,bool)", p0, p1, p2, p3)); } function log(uint p0, string memory p1, bool p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,string,bool,address)", p0, p1, p2, p3)); } function log(uint p0, string memory p1, address p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,string,address,uint)", p0, p1, p2, p3)); } function log(uint p0, string memory p1, address p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,string,address,string)", p0, p1, p2, p3)); } function log(uint p0, string memory p1, address p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,string,address,bool)", p0, p1, p2, p3)); } function log(uint p0, string memory p1, address p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,string,address,address)", p0, p1, p2, p3)); } function log(uint p0, bool p1, uint p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,bool,uint,uint)", p0, p1, p2, p3)); } function log(uint p0, bool p1, uint p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,bool,uint,string)", p0, p1, p2, p3)); } function log(uint p0, bool p1, uint p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,bool,uint,bool)", p0, p1, p2, p3)); } function log(uint p0, bool p1, uint p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,bool,uint,address)", p0, p1, p2, p3)); } function log(uint p0, bool p1, string memory p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,bool,string,uint)", p0, p1, p2, p3)); } function log(uint p0, bool p1, string memory p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,bool,string,string)", p0, p1, p2, p3)); } function log(uint p0, bool p1, string memory p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,bool,string,bool)", p0, p1, p2, p3)); } function log(uint p0, bool p1, string memory p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,bool,string,address)", p0, p1, p2, p3)); } function log(uint p0, bool p1, bool p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,bool,bool,uint)", p0, p1, p2, p3)); } function log(uint p0, bool p1, bool p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,bool,bool,string)", p0, p1, p2, p3)); } function log(uint p0, bool p1, bool p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,bool,bool,bool)", p0, p1, p2, p3)); } function log(uint p0, bool p1, bool p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,bool,bool,address)", p0, p1, p2, p3)); } function log(uint p0, bool p1, address p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,bool,address,uint)", p0, p1, p2, p3)); } function log(uint p0, bool p1, address p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,bool,address,string)", p0, p1, p2, p3)); } function log(uint p0, bool p1, address p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,bool,address,bool)", p0, p1, p2, p3)); } function log(uint p0, bool p1, address p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,bool,address,address)", p0, p1, p2, p3)); } function log(uint p0, address p1, uint p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,address,uint,uint)", p0, p1, p2, p3)); } function log(uint p0, address p1, uint p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,address,uint,string)", p0, p1, p2, p3)); } function log(uint p0, address p1, uint p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,address,uint,bool)", p0, p1, p2, p3)); } function log(uint p0, address p1, uint p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,address,uint,address)", p0, p1, p2, p3)); } function log(uint p0, address p1, string memory p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,address,string,uint)", p0, p1, p2, p3)); } function log(uint p0, address p1, string memory p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,address,string,string)", p0, p1, p2, p3)); } function log(uint p0, address p1, string memory p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,address,string,bool)", p0, p1, p2, p3)); } function log(uint p0, address p1, string memory p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,address,string,address)", p0, p1, p2, p3)); } function log(uint p0, address p1, bool p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,address,bool,uint)", p0, p1, p2, p3)); } function log(uint p0, address p1, bool p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,address,bool,string)", p0, p1, p2, p3)); } function log(uint p0, address p1, bool p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,address,bool,bool)", p0, p1, p2, p3)); } function log(uint p0, address p1, bool p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,address,bool,address)", p0, p1, p2, p3)); } function log(uint p0, address p1, address p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,address,address,uint)", p0, p1, p2, p3)); } function log(uint p0, address p1, address p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,address,address,string)", p0, p1, p2, p3)); } function log(uint p0, address p1, address p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,address,address,bool)", p0, p1, p2, p3)); } function log(uint p0, address p1, address p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(uint,address,address,address)", p0, p1, p2, p3)); } function log(string memory p0, uint p1, uint p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,uint,uint,uint)", p0, p1, p2, p3)); } function log(string memory p0, uint p1, uint p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,uint,uint,string)", p0, p1, p2, p3)); } function log(string memory p0, uint p1, uint p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,uint,uint,bool)", p0, p1, p2, p3)); } function log(string memory p0, uint p1, uint p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,uint,uint,address)", p0, p1, p2, p3)); } function log(string memory p0, uint p1, string memory p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,uint,string,uint)", p0, p1, p2, p3)); } function log(string memory p0, uint p1, string memory p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,uint,string,string)", p0, p1, p2, p3)); } function log(string memory p0, uint p1, string memory p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,uint,string,bool)", p0, p1, p2, p3)); } function log(string memory p0, uint p1, string memory p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,uint,string,address)", p0, p1, p2, p3)); } function log(string memory p0, uint p1, bool p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,uint,bool,uint)", p0, p1, p2, p3)); } function log(string memory p0, uint p1, bool p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,uint,bool,string)", p0, p1, p2, p3)); } function log(string memory p0, uint p1, bool p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,uint,bool,bool)", p0, p1, p2, p3)); } function log(string memory p0, uint p1, bool p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,uint,bool,address)", p0, p1, p2, p3)); } function log(string memory p0, uint p1, address p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,uint,address,uint)", p0, p1, p2, p3)); } function log(string memory p0, uint p1, address p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,uint,address,string)", p0, p1, p2, p3)); } function log(string memory p0, uint p1, address p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,uint,address,bool)", p0, p1, p2, p3)); } function log(string memory p0, uint p1, address p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,uint,address,address)", p0, p1, p2, p3)); } function log(string memory p0, string memory p1, uint p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,string,uint,uint)", p0, p1, p2, p3)); } function log(string memory p0, string memory p1, uint p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,string,uint,string)", p0, p1, p2, p3)); } function log(string memory p0, string memory p1, uint p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,string,uint,bool)", p0, p1, p2, p3)); } function log(string memory p0, string memory p1, uint p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,string,uint,address)", p0, p1, p2, p3)); } function log(string memory p0, string memory p1, string memory p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,string,string,uint)", p0, p1, p2, p3)); } function log(string memory p0, string memory p1, string memory p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,string,string,string)", p0, p1, p2, p3)); } function log(string memory p0, string memory p1, string memory p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,string,string,bool)", p0, p1, p2, p3)); } function log(string memory p0, string memory p1, string memory p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,string,string,address)", p0, p1, p2, p3)); } function log(string memory p0, string memory p1, bool p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,string,bool,uint)", p0, p1, p2, p3)); } function log(string memory p0, string memory p1, bool p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,string,bool,string)", p0, p1, p2, p3)); } function log(string memory p0, string memory p1, bool p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,string,bool,bool)", p0, p1, p2, p3)); } function log(string memory p0, string memory p1, bool p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,string,bool,address)", p0, p1, p2, p3)); } function log(string memory p0, string memory p1, address p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,string,address,uint)", p0, p1, p2, p3)); } function log(string memory p0, string memory p1, address p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,string,address,string)", p0, p1, p2, p3)); } function log(string memory p0, string memory p1, address p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,string,address,bool)", p0, p1, p2, p3)); } function log(string memory p0, string memory p1, address p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,string,address,address)", p0, p1, p2, p3)); } function log(string memory p0, bool p1, uint p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,bool,uint,uint)", p0, p1, p2, p3)); } function log(string memory p0, bool p1, uint p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,bool,uint,string)", p0, p1, p2, p3)); } function log(string memory p0, bool p1, uint p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,bool,uint,bool)", p0, p1, p2, p3)); } function log(string memory p0, bool p1, uint p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,bool,uint,address)", p0, p1, p2, p3)); } function log(string memory p0, bool p1, string memory p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,bool,string,uint)", p0, p1, p2, p3)); } function log(string memory p0, bool p1, string memory p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,bool,string,string)", p0, p1, p2, p3)); } function log(string memory p0, bool p1, string memory p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,bool,string,bool)", p0, p1, p2, p3)); } function log(string memory p0, bool p1, string memory p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,bool,string,address)", p0, p1, p2, p3)); } function log(string memory p0, bool p1, bool p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,bool,bool,uint)", p0, p1, p2, p3)); } function log(string memory p0, bool p1, bool p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,bool,bool,string)", p0, p1, p2, p3)); } function log(string memory p0, bool p1, bool p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,bool,bool,bool)", p0, p1, p2, p3)); } function log(string memory p0, bool p1, bool p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,bool,bool,address)", p0, p1, p2, p3)); } function log(string memory p0, bool p1, address p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,bool,address,uint)", p0, p1, p2, p3)); } function log(string memory p0, bool p1, address p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,bool,address,string)", p0, p1, p2, p3)); } function log(string memory p0, bool p1, address p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,bool,address,bool)", p0, p1, p2, p3)); } function log(string memory p0, bool p1, address p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,bool,address,address)", p0, p1, p2, p3)); } function log(string memory p0, address p1, uint p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,address,uint,uint)", p0, p1, p2, p3)); } function log(string memory p0, address p1, uint p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,address,uint,string)", p0, p1, p2, p3)); } function log(string memory p0, address p1, uint p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,address,uint,bool)", p0, p1, p2, p3)); } function log(string memory p0, address p1, uint p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,address,uint,address)", p0, p1, p2, p3)); } function log(string memory p0, address p1, string memory p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,address,string,uint)", p0, p1, p2, p3)); } function log(string memory p0, address p1, string memory p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,address,string,string)", p0, p1, p2, p3)); } function log(string memory p0, address p1, string memory p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,address,string,bool)", p0, p1, p2, p3)); } function log(string memory p0, address p1, string memory p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,address,string,address)", p0, p1, p2, p3)); } function log(string memory p0, address p1, bool p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,address,bool,uint)", p0, p1, p2, p3)); } function log(string memory p0, address p1, bool p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,address,bool,string)", p0, p1, p2, p3)); } function log(string memory p0, address p1, bool p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,address,bool,bool)", p0, p1, p2, p3)); } function log(string memory p0, address p1, bool p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,address,bool,address)", p0, p1, p2, p3)); } function log(string memory p0, address p1, address p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,address,address,uint)", p0, p1, p2, p3)); } function log(string memory p0, address p1, address p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,address,address,string)", p0, p1, p2, p3)); } function log(string memory p0, address p1, address p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,address,address,bool)", p0, p1, p2, p3)); } function log(string memory p0, address p1, address p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(string,address,address,address)", p0, p1, p2, p3)); } function log(bool p0, uint p1, uint p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,uint,uint,uint)", p0, p1, p2, p3)); } function log(bool p0, uint p1, uint p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,uint,uint,string)", p0, p1, p2, p3)); } function log(bool p0, uint p1, uint p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,uint,uint,bool)", p0, p1, p2, p3)); } function log(bool p0, uint p1, uint p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,uint,uint,address)", p0, p1, p2, p3)); } function log(bool p0, uint p1, string memory p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,uint,string,uint)", p0, p1, p2, p3)); } function log(bool p0, uint p1, string memory p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,uint,string,string)", p0, p1, p2, p3)); } function log(bool p0, uint p1, string memory p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,uint,string,bool)", p0, p1, p2, p3)); } function log(bool p0, uint p1, string memory p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,uint,string,address)", p0, p1, p2, p3)); } function log(bool p0, uint p1, bool p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,uint,bool,uint)", p0, p1, p2, p3)); } function log(bool p0, uint p1, bool p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,uint,bool,string)", p0, p1, p2, p3)); } function log(bool p0, uint p1, bool p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,uint,bool,bool)", p0, p1, p2, p3)); } function log(bool p0, uint p1, bool p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,uint,bool,address)", p0, p1, p2, p3)); } function log(bool p0, uint p1, address p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,uint,address,uint)", p0, p1, p2, p3)); } function log(bool p0, uint p1, address p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,uint,address,string)", p0, p1, p2, p3)); } function log(bool p0, uint p1, address p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,uint,address,bool)", p0, p1, p2, p3)); } function log(bool p0, uint p1, address p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,uint,address,address)", p0, p1, p2, p3)); } function log(bool p0, string memory p1, uint p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,string,uint,uint)", p0, p1, p2, p3)); } function log(bool p0, string memory p1, uint p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,string,uint,string)", p0, p1, p2, p3)); } function log(bool p0, string memory p1, uint p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,string,uint,bool)", p0, p1, p2, p3)); } function log(bool p0, string memory p1, uint p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,string,uint,address)", p0, p1, p2, p3)); } function log(bool p0, string memory p1, string memory p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,string,string,uint)", p0, p1, p2, p3)); } function log(bool p0, string memory p1, string memory p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,string,string,string)", p0, p1, p2, p3)); } function log(bool p0, string memory p1, string memory p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,string,string,bool)", p0, p1, p2, p3)); } function log(bool p0, string memory p1, string memory p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,string,string,address)", p0, p1, p2, p3)); } function log(bool p0, string memory p1, bool p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,string,bool,uint)", p0, p1, p2, p3)); } function log(bool p0, string memory p1, bool p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,string,bool,string)", p0, p1, p2, p3)); } function log(bool p0, string memory p1, bool p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,string,bool,bool)", p0, p1, p2, p3)); } function log(bool p0, string memory p1, bool p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,string,bool,address)", p0, p1, p2, p3)); } function log(bool p0, string memory p1, address p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,string,address,uint)", p0, p1, p2, p3)); } function log(bool p0, string memory p1, address p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,string,address,string)", p0, p1, p2, p3)); } function log(bool p0, string memory p1, address p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,string,address,bool)", p0, p1, p2, p3)); } function log(bool p0, string memory p1, address p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,string,address,address)", p0, p1, p2, p3)); } function log(bool p0, bool p1, uint p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,bool,uint,uint)", p0, p1, p2, p3)); } function log(bool p0, bool p1, uint p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,bool,uint,string)", p0, p1, p2, p3)); } function log(bool p0, bool p1, uint p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,bool,uint,bool)", p0, p1, p2, p3)); } function log(bool p0, bool p1, uint p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,bool,uint,address)", p0, p1, p2, p3)); } function log(bool p0, bool p1, string memory p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,bool,string,uint)", p0, p1, p2, p3)); } function log(bool p0, bool p1, string memory p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,bool,string,string)", p0, p1, p2, p3)); } function log(bool p0, bool p1, string memory p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,bool,string,bool)", p0, p1, p2, p3)); } function log(bool p0, bool p1, string memory p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,bool,string,address)", p0, p1, p2, p3)); } function log(bool p0, bool p1, bool p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,bool,bool,uint)", p0, p1, p2, p3)); } function log(bool p0, bool p1, bool p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,bool,bool,string)", p0, p1, p2, p3)); } function log(bool p0, bool p1, bool p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,bool,bool,bool)", p0, p1, p2, p3)); } function log(bool p0, bool p1, bool p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,bool,bool,address)", p0, p1, p2, p3)); } function log(bool p0, bool p1, address p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,bool,address,uint)", p0, p1, p2, p3)); } function log(bool p0, bool p1, address p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,bool,address,string)", p0, p1, p2, p3)); } function log(bool p0, bool p1, address p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,bool,address,bool)", p0, p1, p2, p3)); } function log(bool p0, bool p1, address p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,bool,address,address)", p0, p1, p2, p3)); } function log(bool p0, address p1, uint p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,address,uint,uint)", p0, p1, p2, p3)); } function log(bool p0, address p1, uint p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,address,uint,string)", p0, p1, p2, p3)); } function log(bool p0, address p1, uint p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,address,uint,bool)", p0, p1, p2, p3)); } function log(bool p0, address p1, uint p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,address,uint,address)", p0, p1, p2, p3)); } function log(bool p0, address p1, string memory p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,address,string,uint)", p0, p1, p2, p3)); } function log(bool p0, address p1, string memory p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,address,string,string)", p0, p1, p2, p3)); } function log(bool p0, address p1, string memory p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,address,string,bool)", p0, p1, p2, p3)); } function log(bool p0, address p1, string memory p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,address,string,address)", p0, p1, p2, p3)); } function log(bool p0, address p1, bool p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,address,bool,uint)", p0, p1, p2, p3)); } function log(bool p0, address p1, bool p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,address,bool,string)", p0, p1, p2, p3)); } function log(bool p0, address p1, bool p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,address,bool,bool)", p0, p1, p2, p3)); } function log(bool p0, address p1, bool p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,address,bool,address)", p0, p1, p2, p3)); } function log(bool p0, address p1, address p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,address,address,uint)", p0, p1, p2, p3)); } function log(bool p0, address p1, address p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,address,address,string)", p0, p1, p2, p3)); } function log(bool p0, address p1, address p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,address,address,bool)", p0, p1, p2, p3)); } function log(bool p0, address p1, address p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(bool,address,address,address)", p0, p1, p2, p3)); } function log(address p0, uint p1, uint p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,uint,uint,uint)", p0, p1, p2, p3)); } function log(address p0, uint p1, uint p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,uint,uint,string)", p0, p1, p2, p3)); } function log(address p0, uint p1, uint p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,uint,uint,bool)", p0, p1, p2, p3)); } function log(address p0, uint p1, uint p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,uint,uint,address)", p0, p1, p2, p3)); } function log(address p0, uint p1, string memory p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,uint,string,uint)", p0, p1, p2, p3)); } function log(address p0, uint p1, string memory p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,uint,string,string)", p0, p1, p2, p3)); } function log(address p0, uint p1, string memory p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,uint,string,bool)", p0, p1, p2, p3)); } function log(address p0, uint p1, string memory p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,uint,string,address)", p0, p1, p2, p3)); } function log(address p0, uint p1, bool p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,uint,bool,uint)", p0, p1, p2, p3)); } function log(address p0, uint p1, bool p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,uint,bool,string)", p0, p1, p2, p3)); } function log(address p0, uint p1, bool p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,uint,bool,bool)", p0, p1, p2, p3)); } function log(address p0, uint p1, bool p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,uint,bool,address)", p0, p1, p2, p3)); } function log(address p0, uint p1, address p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,uint,address,uint)", p0, p1, p2, p3)); } function log(address p0, uint p1, address p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,uint,address,string)", p0, p1, p2, p3)); } function log(address p0, uint p1, address p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,uint,address,bool)", p0, p1, p2, p3)); } function log(address p0, uint p1, address p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,uint,address,address)", p0, p1, p2, p3)); } function log(address p0, string memory p1, uint p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,string,uint,uint)", p0, p1, p2, p3)); } function log(address p0, string memory p1, uint p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,string,uint,string)", p0, p1, p2, p3)); } function log(address p0, string memory p1, uint p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,string,uint,bool)", p0, p1, p2, p3)); } function log(address p0, string memory p1, uint p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,string,uint,address)", p0, p1, p2, p3)); } function log(address p0, string memory p1, string memory p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,string,string,uint)", p0, p1, p2, p3)); } function log(address p0, string memory p1, string memory p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,string,string,string)", p0, p1, p2, p3)); } function log(address p0, string memory p1, string memory p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,string,string,bool)", p0, p1, p2, p3)); } function log(address p0, string memory p1, string memory p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,string,string,address)", p0, p1, p2, p3)); } function log(address p0, string memory p1, bool p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,string,bool,uint)", p0, p1, p2, p3)); } function log(address p0, string memory p1, bool p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,string,bool,string)", p0, p1, p2, p3)); } function log(address p0, string memory p1, bool p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,string,bool,bool)", p0, p1, p2, p3)); } function log(address p0, string memory p1, bool p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,string,bool,address)", p0, p1, p2, p3)); } function log(address p0, string memory p1, address p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,string,address,uint)", p0, p1, p2, p3)); } function log(address p0, string memory p1, address p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,string,address,string)", p0, p1, p2, p3)); } function log(address p0, string memory p1, address p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,string,address,bool)", p0, p1, p2, p3)); } function log(address p0, string memory p1, address p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,string,address,address)", p0, p1, p2, p3)); } function log(address p0, bool p1, uint p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,bool,uint,uint)", p0, p1, p2, p3)); } function log(address p0, bool p1, uint p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,bool,uint,string)", p0, p1, p2, p3)); } function log(address p0, bool p1, uint p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,bool,uint,bool)", p0, p1, p2, p3)); } function log(address p0, bool p1, uint p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,bool,uint,address)", p0, p1, p2, p3)); } function log(address p0, bool p1, string memory p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,bool,string,uint)", p0, p1, p2, p3)); } function log(address p0, bool p1, string memory p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,bool,string,string)", p0, p1, p2, p3)); } function log(address p0, bool p1, string memory p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,bool,string,bool)", p0, p1, p2, p3)); } function log(address p0, bool p1, string memory p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,bool,string,address)", p0, p1, p2, p3)); } function log(address p0, bool p1, bool p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,bool,bool,uint)", p0, p1, p2, p3)); } function log(address p0, bool p1, bool p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,bool,bool,string)", p0, p1, p2, p3)); } function log(address p0, bool p1, bool p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,bool,bool,bool)", p0, p1, p2, p3)); } function log(address p0, bool p1, bool p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,bool,bool,address)", p0, p1, p2, p3)); } function log(address p0, bool p1, address p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,bool,address,uint)", p0, p1, p2, p3)); } function log(address p0, bool p1, address p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,bool,address,string)", p0, p1, p2, p3)); } function log(address p0, bool p1, address p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,bool,address,bool)", p0, p1, p2, p3)); } function log(address p0, bool p1, address p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,bool,address,address)", p0, p1, p2, p3)); } function log(address p0, address p1, uint p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,address,uint,uint)", p0, p1, p2, p3)); } function log(address p0, address p1, uint p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,address,uint,string)", p0, p1, p2, p3)); } function log(address p0, address p1, uint p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,address,uint,bool)", p0, p1, p2, p3)); } function log(address p0, address p1, uint p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,address,uint,address)", p0, p1, p2, p3)); } function log(address p0, address p1, string memory p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,address,string,uint)", p0, p1, p2, p3)); } function log(address p0, address p1, string memory p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,address,string,string)", p0, p1, p2, p3)); } function log(address p0, address p1, string memory p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,address,string,bool)", p0, p1, p2, p3)); } function log(address p0, address p1, string memory p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,address,string,address)", p0, p1, p2, p3)); } function log(address p0, address p1, bool p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,address,bool,uint)", p0, p1, p2, p3)); } function log(address p0, address p1, bool p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,address,bool,string)", p0, p1, p2, p3)); } function log(address p0, address p1, bool p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,address,bool,bool)", p0, p1, p2, p3)); } function log(address p0, address p1, bool p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,address,bool,address)", p0, p1, p2, p3)); } function log(address p0, address p1, address p2, uint p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,address,address,uint)", p0, p1, p2, p3)); } function log(address p0, address p1, address p2, string memory p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,address,address,string)", p0, p1, p2, p3)); } function log(address p0, address p1, address p2, bool p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,address,address,bool)", p0, p1, p2, p3)); } function log(address p0, address p1, address p2, address p3) internal view { _sendLogPayload(abi.encodeWithSignature("log(address,address,address,address)", p0, p1, p2, p3)); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../../utils/introspection/IERC165.sol"; /** * @dev Required interface of an ERC1155 compliant contract, as defined in the * https://eips.ethereum.org/EIPS/eip-1155[EIP]. * * _Available since v3.1._ */ interface IERC1155 is IERC165 { /** * @dev Emitted when `value` tokens of token type `id` are transferred from `from` to `to` by `operator`. */ event TransferSingle(address indexed operator, address indexed from, address indexed to, uint256 id, uint256 value); /** * @dev Equivalent to multiple {TransferSingle} events, where `operator`, `from` and `to` are the same for all * transfers. */ event TransferBatch( address indexed operator, address indexed from, address indexed to, uint256[] ids, uint256[] values ); /** * @dev Emitted when `account` grants or revokes permission to `operator` to transfer their tokens, according to * `approved`. */ event ApprovalForAll(address indexed account, address indexed operator, bool approved); /** * @dev Emitted when the URI for token type `id` changes to `value`, if it is a non-programmatic URI. * * If an {URI} event was emitted for `id`, the standard * https://eips.ethereum.org/EIPS/eip-1155#metadata-extensions[guarantees] that `value` will equal the value * returned by {IERC1155MetadataURI-uri}. */ event URI(string value, uint256 indexed id); /** * @dev Returns the amount of tokens of token type `id` owned by `account`. * * Requirements: * * - `account` cannot be the zero address. */ function balanceOf(address account, uint256 id) external view returns (uint256); /** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {balanceOf}. * * Requirements: * * - `accounts` and `ids` must have the same length. */ function balanceOfBatch(address[] calldata accounts, uint256[] calldata ids) external view returns (uint256[] memory); /** * @dev Grants or revokes permission to `operator` to transfer the caller's tokens, according to `approved`, * * Emits an {ApprovalForAll} event. * * Requirements: * * - `operator` cannot be the caller. */ function setApprovalForAll(address operator, bool approved) external; /** * @dev Returns true if `operator` is approved to transfer ``account``'s tokens. * * See {setApprovalForAll}. */ function isApprovedForAll(address account, address operator) external view returns (bool); /** * @dev Transfers `amount` tokens of token type `id` from `from` to `to`. * * Emits a {TransferSingle} event. * * Requirements: * * - `to` cannot be the zero address. * - If the caller is not `from`, it must be have been approved to spend ``from``'s tokens via {setApprovalForAll}. * - `from` must have a balance of tokens of type `id` of at least `amount`. * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155Received} and return the * acceptance magic value. */ function safeTransferFrom( address from, address to, uint256 id, uint256 amount, bytes calldata data ) external; /** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {safeTransferFrom}. * * Emits a {TransferBatch} event. * * Requirements: * * - `ids` and `amounts` must have the same length. * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155BatchReceived} and return the * acceptance magic value. */ function safeBatchTransferFrom( address from, address to, uint256[] calldata ids, uint256[] calldata amounts, bytes calldata data ) external; }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../../utils/introspection/IERC165.sol"; /** * @dev _Available since v3.1._ */ interface IERC1155Receiver is IERC165 { /** @dev Handles the receipt of a single ERC1155 token type. This function is called at the end of a `safeTransferFrom` after the balance has been updated. To accept the transfer, this must return `bytes4(keccak256("onERC1155Received(address,address,uint256,uint256,bytes)"))` (i.e. 0xf23a6e61, or its own function selector). @param operator The address which initiated the transfer (i.e. msg.sender) @param from The address which previously owned the token @param id The ID of the token being transferred @param value The amount of tokens being transferred @param data Additional data with no specified format @return `bytes4(keccak256("onERC1155Received(address,address,uint256,uint256,bytes)"))` if transfer is allowed */ function onERC1155Received( address operator, address from, uint256 id, uint256 value, bytes calldata data ) external returns (bytes4); /** @dev Handles the receipt of a multiple ERC1155 token types. This function is called at the end of a `safeBatchTransferFrom` after the balances have been updated. To accept the transfer(s), this must return `bytes4(keccak256("onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)"))` (i.e. 0xbc197c81, or its own function selector). @param operator The address which initiated the batch transfer (i.e. msg.sender) @param from The address which previously owned the token @param ids An array containing ids of each token being transferred (order and length must match values array) @param values An array containing amounts of each token being transferred (order and length must match ids array) @param data Additional data with no specified format @return `bytes4(keccak256("onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)"))` if transfer is allowed */ function onERC1155BatchReceived( address operator, address from, uint256[] calldata ids, uint256[] calldata values, bytes calldata data ) external returns (bytes4); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../IERC1155.sol"; /** * @dev Interface of the optional ERC1155MetadataExtension interface, as defined * in the https://eips.ethereum.org/EIPS/eip-1155#metadata-extensions[EIP]. * * _Available since v3.1._ */ interface IERC1155MetadataURI is IERC1155 { /** * @dev Returns the URI for token type `id`. * * If the `\{id\}` substring is present in the URI, it must be replaced by * clients with the actual token type ID. */ function uri(uint256 id) external view returns (string memory); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @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 * ==== */ function isContract(address account) internal view returns (bool) { // This method relies on extcodesize, which returns 0 for contracts in // construction, since the code is only stored at the end of the // constructor execution. uint256 size; assembly { size := extcodesize(account) } return size > 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 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 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 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 pragma solidity ^0.8.0; /** * @dev External interface of AccessControl declared to support ERC165 detection. */ interface IAccessControl { /** * @dev Emitted when `newAdminRole` is set as ``role``'s admin role, replacing `previousAdminRole` * * `DEFAULT_ADMIN_ROLE` is the starting admin for all roles, despite * {RoleAdminChanged} not being emitted signaling this. * * _Available since v3.1._ */ event RoleAdminChanged(bytes32 indexed role, bytes32 indexed previousAdminRole, bytes32 indexed newAdminRole); /** * @dev Emitted when `account` is granted `role`. * * `sender` is the account that originated the contract call, an admin role * bearer except when using {AccessControl-_setupRole}. */ event RoleGranted(bytes32 indexed role, address indexed account, address indexed sender); /** * @dev Emitted when `account` is revoked `role`. * * `sender` is the account that originated the contract call: * - if using `revokeRole`, it is the admin role bearer * - if using `renounceRole`, it is the role bearer (i.e. `account`) */ event RoleRevoked(bytes32 indexed role, address indexed account, address indexed sender); /** * @dev Returns `true` if `account` has been granted `role`. */ function hasRole(bytes32 role, address account) external view returns (bool); /** * @dev Returns the admin role that controls `role`. See {grantRole} and * {revokeRole}. * * To change a role's admin, use {AccessControl-_setRoleAdmin}. */ function getRoleAdmin(bytes32 role) external view returns (bytes32); /** * @dev Grants `role` to `account`. * * If `account` had not been already granted `role`, emits a {RoleGranted} * event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function grantRole(bytes32 role, address account) external; /** * @dev Revokes `role` from `account`. * * If `account` had been granted `role`, emits a {RoleRevoked} event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function revokeRole(bytes32 role, address account) external; /** * @dev Revokes `role` from the calling account. * * Roles are often managed via {grantRole} and {revokeRole}: this function's * purpose is to provide a mechanism for accounts to lose their privileges * if they are compromised (such as when a trusted device is misplaced). * * If the calling account had been granted `role`, emits a {RoleRevoked} * event. * * Requirements: * * - the caller must be `account`. */ function renounceRole(bytes32 role, address account) external; }
// SPDX-License-Identifier: MIT 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); } }
{ "optimizer": { "enabled": true, "runs": 200 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"string","name":"newContractName","type":"string"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","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":false,"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"open","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"close","type":"uint256[]"}],"name":"DatesChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"maxItems","type":"uint256[]"}],"name":"MaxItemsChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"maxPerTransaction","type":"uint256[]"}],"name":"MaxPerTransactionChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"maxPerWallet","type":"uint256[]"}],"name":"MaxPerWalletChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"prices","type":"uint256[]"}],"name":"PricesChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"indexed":false,"internalType":"address[]","name":"redeemContracts","type":"address[]"}],"name":"RedeemContractAddressChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"hash","type":"bytes32"},{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"RedeemedPass","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"previousAdminRole","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"newAdminRole","type":"bytes32"}],"name":"RoleAdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleGranted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleRevoked","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"values","type":"uint256[]"}],"name":"TransferBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"TransferSingle","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"value","type":"string"},{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"URI","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"newUri","type":"string"}],"name":"UriChanged","type":"event"},{"inputs":[],"name":"DEFAULT_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"OPERATOR_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SIGNER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAWER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"accounts","type":"address[]"},{"internalType":"uint256[]","name":"ids","type":"uint256[]"}],"name":"balanceOfBatch","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"value","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"uint256[]","name":"values","type":"uint256[]"}],"name":"burnBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"burnFromRedeemedToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"contractURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"hash","type":"bytes32"}],"name":"deleteHash","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"exists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"passId","type":"uint256"}],"name":"getClose","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCounter","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"passId","type":"uint256"}],"name":"getMaxItems","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"passId","type":"uint256"}],"name":"getMaxPerTransaction","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"passId","type":"uint256"}],"name":"getMaxPerWallet","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"passId","type":"uint256"}],"name":"getOpen","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"passId","type":"uint256"}],"name":"getPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"passId","type":"uint256"}],"name":"getRedeemContract","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleAdmin","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"grantRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"hasRole","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"mintBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"passId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"uint256","name":"nonce","type":"uint256"},{"internalType":"bytes","name":"signature","type":"bytes"}],"name":"mintPass","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"renounceRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"newIndex","type":"uint256"}],"name":"resetCounter","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"passId","type":"uint256"}],"name":"resetPass","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"revokeRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeBatchTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"amount","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":"string","name":"newContractURI","type":"string"}],"name":"setContractURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"uint256[]","name":"open","type":"uint256[]"},{"internalType":"uint256[]","name":"close","type":"uint256[]"}],"name":"setDates","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"uint256[]","name":"maxItems","type":"uint256[]"}],"name":"setMaxItems","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"uint256[]","name":"maxPerTransaction","type":"uint256[]"}],"name":"setMaxPerTransaction","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"uint256[]","name":"maxPerWallet","type":"uint256[]"}],"name":"setMaxPerWallet","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"uint256[]","name":"prices","type":"uint256[]"}],"name":"setPrices","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"address[]","name":"redeemContracts","type":"address[]"}],"name":"setRedeemContracts","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"newUri","type":"string"}],"name":"setURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"numPasses","type":"uint256"},{"internalType":"uint256[]","name":"maxItems","type":"uint256[]"},{"internalType":"uint256[]","name":"maxPerWallet","type":"uint256[]"},{"internalType":"uint256[]","name":"maxPerTransaction","type":"uint256[]"},{"internalType":"uint256[]","name":"prices","type":"uint256[]"},{"internalType":"uint256[]","name":"open","type":"uint256[]"},{"internalType":"uint256[]","name":"close","type":"uint256[]"}],"name":"setup","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":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"uri","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"address payable","name":"to","type":"address"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]
Contract Creation Code
6101206040523480156200001257600080fd5b506040516200527d3803806200527d833981016040819052620000359162000323565b80604051806040016040528060058152602001640312e302e360dc1b815250604051806020016040528060008152506200007581620001a160201b60201c565b506004805460ff19169055815160209283012081519183019190912060c082815260e08290524660a0818152604080517f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f8189018190528183019790975260608101959095526080808601939093523085830152805180860390920182529390920190925280519301929092209091526101005262000116600033620001ba565b620001427f97667070c54ef182b0f5858b034beac1b6f3089aa2d3188bb1e8929f4fa9b92933620001ba565b6200016e7f10dac8c06a04bec0b551627dad28bc00d6516b0caacd1c7b345fcdb5211334e433620001ba565b6200019a7fe2f4eaae4a9751e85a3e4a7b9587827a877f29914755229b07a7b2da98285f7033620001ba565b506200043c565b8051620001b690600290602084019062000267565b5050565b60008281526003602090815260408083206001600160a01b0385168452909152902054620001b6908390839060ff16620001b65760008281526003602090815260408083206001600160a01b03851684529091529020805460ff19166001179055620002233390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b8280546200027590620003ff565b90600052602060002090601f016020900481019282620002995760008555620002e4565b82601f10620002b457805160ff1916838001178555620002e4565b82800160010185558215620002e4579182015b82811115620002e4578251825591602001919060010190620002c7565b50620002f2929150620002f6565b5090565b5b80821115620002f25760008155600101620002f7565b634e487b7160e01b600052604160045260246000fd5b600060208083850312156200033757600080fd5b82516001600160401b03808211156200034f57600080fd5b818501915085601f8301126200036457600080fd5b8151818111156200037957620003796200030d565b604051601f8201601f19908116603f01168101908382118183101715620003a457620003a46200030d565b816040528281528886848701011115620003bd57600080fd5b600093505b82841015620003e15784840186015181850187015292850192620003c2565b82841115620003f35760008684830101525b98975050505050505050565b600181811c908216806200041457607f821691505b602082108114156200043657634e487b7160e01b600052602260045260246000fd5b50919050565b60805160a05160c05160e05161010051614dfc62000481600039600061361d0152600061366c01526000613647015260006135cb015260006135f40152614dfc6000f3fe6080604052600436106102c75760003560e01c80637bb6892811610175578063bd85b039116100dc578063e7c8d22d11610095578063ed8a4a851161006f578063ed8a4a8514610914578063f242432a14610934578063f5298aca14610954578063f5b541a61461097457600080fd5b8063e7c8d22d14610896578063e8a3d485146108b6578063e985e9c5146108cb57600080fd5b8063bd85b039146107c9578063d05eaae0146107f6578063d0cd863f14610816578063d547741f14610836578063df7b742814610856578063e75722301461087657600080fd5b8063a1ebf35d1161012e578063a1ebf35d14610700578063a217fddf14610734578063a22cb46514610749578063b67797d614610769578063b72b3bfe14610789578063ba32e67e146107a957600080fd5b80637bb689281461062a5780638456cb591461066257806385f438c1146106775780638ada066e146106ab57806391d14854146106c0578063938e3d7b146106e057600080fd5b80632eb2c2d6116102345780634f558e79116101ed57806363f0bfce116101c757806363f0bfce146105aa5780636b20c454146105ca578063731133e9146105ea57806375321c4a1461060a57600080fd5b80634f558e79146105435780635c975abb146105725780636372f6fe1461058a57600080fd5b80632eb2c2d6146104815780632f2ff15d146104a157806336568abe146104c15780633f4ba83a146104e1578063448db696146104f65780634e1273f41461051657600080fd5b806313caf5511161028657806313caf551146103be5780631ed2b37e146103de5780631f7fdffa146103fe578063248a9ca31461041e57806327dafe5b1461044e5780632c3e9d9d1461046e57600080fd5b8062f714ce146102cc578062fdd58e146102ee57806301ffc9a71461032157806302fe53051461035157806303ceb77f146103715780630e89341c14610391575b600080fd5b3480156102d857600080fd5b506102ec6102e7366004613e08565b610996565b005b3480156102fa57600080fd5b5061030e610309366004613e38565b610ae3565b6040519081526020015b60405180910390f35b34801561032d57600080fd5b5061034161033c366004613e7a565b610b75565b6040519015158152602001610318565b34801561035d57600080fd5b506102ec61036c366004613f36565b610b86565b34801561037d57600080fd5b506102ec61038c36600461401a565b610be3565b34801561039d57600080fd5b506103b16103ac36600461407d565b610d93565b60405161031891906140ee565b3480156103ca57600080fd5b5061030e6103d936600461407d565b610e27565b3480156103ea57600080fd5b506102ec6103f936600461401a565b610e5d565b34801561040a57600080fd5b506102ec610419366004614121565b610faa565b34801561042a57600080fd5b5061030e61043936600461407d565b60009081526003602052604090206001015490565b34801561045a57600080fd5b506102ec61046936600461422a565b610ff2565b6102ec61047c366004614283565b611165565b34801561048d57600080fd5b506102ec61049c36600461430f565b611542565b3480156104ad57600080fd5b506102ec6104bc366004613e08565b6115d2565b3480156104cd57600080fd5b506102ec6104dc366004613e08565b6115fd565b3480156104ed57600080fd5b506102ec61167b565b34801561050257600080fd5b506102ec6105113660046143bc565b61169f565b34801561052257600080fd5b50610536610531366004614443565b6118d0565b60405161031891906144b4565b34801561054f57600080fd5b5061034161055e36600461407d565b600090815260056020526040902054151590565b34801561057e57600080fd5b5060045460ff16610341565b34801561059657600080fd5b5061030e6105a536600461407d565b6119f9565b3480156105b657600080fd5b506102ec6105c536600461407d565b611a2f565b3480156105d657600080fd5b506102ec6105e53660046144c7565b611a67565b3480156105f657600080fd5b506102ec610605366004614503565b611aaa565b34801561061657600080fd5b5061030e61062536600461407d565b611b8c565b34801561063657600080fd5b5061064a61064536600461407d565b611bc2565b6040516001600160a01b039091168152602001610318565b34801561066e57600080fd5b506102ec611c01565b34801561068357600080fd5b5061030e7f10dac8c06a04bec0b551627dad28bc00d6516b0caacd1c7b345fcdb5211334e481565b3480156106b757600080fd5b5061030e611c22565b3480156106cc57600080fd5b506103416106db366004613e08565b611c32565b3480156106ec57600080fd5b506102ec6106fb366004613f36565b611c5d565b34801561070c57600080fd5b5061030e7fe2f4eaae4a9751e85a3e4a7b9587827a877f29914755229b07a7b2da98285f7081565b34801561074057600080fd5b5061030e600081565b34801561075557600080fd5b506102ec610764366004614559565b611c89565b34801561077557600080fd5b506102ec61078436600461407d565b611d60565b34801561079557600080fd5b506102ec6107a436600461401a565b611da9565b3480156107b557600080fd5b506102ec6107c436600461407d565b611efc565b3480156107d557600080fd5b5061030e6107e436600461407d565b60009081526005602052604090205490565b34801561080257600080fd5b506102ec61081136600461401a565b611f5e565b34801561082257600080fd5b506102ec61083136600461458c565b6120a7565b34801561084257600080fd5b506102ec610851366004613e08565b6121b6565b34801561086257600080fd5b5061030e61087136600461407d565b6121dc565b34801561088257600080fd5b5061030e61089136600461407d565b61220f565b3480156108a257600080fd5b5061030e6108b136600461407d565b612245565b3480156108c257600080fd5b506103b161227b565b3480156108d757600080fd5b506103416108e63660046145c1565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205460ff1690565b34801561092057600080fd5b506102ec61092f3660046145ef565b61230d565b34801561094057600080fd5b506102ec61094f3660046146ee565b612710565b34801561096057600080fd5b506102ec61096f36600461458c565b612755565b34801561098057600080fd5b5061030e600080516020614da783398151915281565b7f10dac8c06a04bec0b551627dad28bc00d6516b0caacd1c7b345fcdb5211334e46109c18133612798565b4780610a035760405162461bcd60e51b815260206004820152600c60248201526b42414c414e43455f5a45524f60a01b60448201526064015b60405180910390fd5b83811015610a475760405162461bcd60e51b8152602060048201526011602482015270414d4f554e545f47545f42414c414e434560781b60448201526064016109fa565b6000836001600160a01b03168560405160006040518083038185875af1925050503d8060008114610a94576040519150601f19603f3d011682016040523d82523d6000602084013e610a99565b606091505b5050905080610adc5760405162461bcd60e51b815260206004820152600f60248201526e15d2551211149055d7d19052531151608a1b60448201526064016109fa565b5050505050565b60006001600160a01b038316610b4f5760405162461bcd60e51b815260206004820152602b60248201527f455243313135353a2062616c616e636520717565727920666f7220746865207a60448201526a65726f206164647265737360a81b60648201526084016109fa565b506000908152602081815260408083206001600160a01b03949094168352929052205490565b6000610b80826127fc565b92915050565b600080516020614da7833981519152610b9f8133612798565b610ba882612821565b7fb1bf12e17db588c31e8fb2afdd2b3bc1ed822d68c560856fcbc75ae303fc5d1482604051610bd791906140ee565b60405180910390a15050565b600080516020614da7833981519152610bfc8133612798565b6000835111610c1d5760405162461bcd60e51b81526004016109fa90614756565b8251825114610c675760405162461bcd60e51b8152602060048201526016602482015275494e56414c49445f4d41585f4954454d535f53495a4560501b60448201526064016109fa565b60005b8351811015610d54576000838281518110610c8757610c87614783565b602002602001015111610ccf5760405162461bcd60e51b815260206004820152601060248201526f494e56414c49445f4d41585f4954454d60801b60448201526064016109fa565b600060076000868481518110610ce757610ce7614783565b6020026020010151815260200190815260200160002090506000816000015411610d235760405162461bcd60e51b81526004016109fa90614799565b838281518110610d3557610d35614783565b6020908102919091010151905580610d4c816147db565b915050610c6a565b507f4402caae79d7b040a75c7d72c65fdd1be0cbe28590584456f0cbb49f2346f4e88383604051610d869291906147f6565b60405180910390a1505050565b606060028054610da29061481b565b80601f0160208091040260200160405190810160405280929190818152602001828054610dce9061481b565b8015610e1b5780601f10610df057610100808354040283529160200191610e1b565b820191906000526020600020905b815481529060010190602001808311610dfe57829003601f168201915b50505050509050919050565b60008181526007602052604081208054610e535760405162461bcd60e51b81526004016109fa90614799565b6005015492915050565b600080516020614da7833981519152610e768133612798565b6000835111610e975760405162461bcd60e51b81526004016109fa90614756565b8251825114610ee25760405162461bcd60e51b8152602060048201526017602482015276494e56414c49445f4d41585f57414c4c45545f53495a4560481b60448201526064016109fa565b60005b8351811015610f7857600060076000868481518110610f0657610f06614783565b6020026020010151815260200190815260200160002090506000816000015411610f425760405162461bcd60e51b81526004016109fa90614799565b838281518110610f5457610f54614783565b60200260200101518160010181905550508080610f70906147db565b915050610ee5565b507fb355828fc1c77f59b3e0f1ce2ade5407d2fac2a198475714987654ab2647c7ec8383604051610d869291906147f6565b600080516020614da7833981519152610fc38133612798565b60045460ff1615610fe65760405162461bcd60e51b81526004016109fa90614856565b610adc85858585612834565b600080516020614da783398151915261100b8133612798565b600083511161102c5760405162461bcd60e51b81526004016109fa90614756565b825182511461107d5760405162461bcd60e51b815260206004820152601d60248201527f494e56414c49445f52454445454d5f434f4e5452414354535f53495a4500000060448201526064016109fa565b60005b8351811015611133576000600760008684815181106110a1576110a1614783565b60200260200101518152602001908152602001600020905060008160000154116110dd5760405162461bcd60e51b81526004016109fa90614799565b8382815181106110ef576110ef614783565b60200260200101518160060160006101000a8154816001600160a01b0302191690836001600160a01b0316021790555050808061112b906147db565b915050611080565b507f7bd6be6cbe8904036ddacfaa6886ec26d27b698db8de720a6993590b58d971aa8383604051610d8692919061487f565b60045460ff16156111885760405162461bcd60e51b81526004016109fa90614856565b600085815260076020526040902080546111b45760405162461bcd60e51b81526004016109fa90614799565b60006111c233888888612840565b90506112048185858080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506128be92505050565b6112445760405162461bcd60e51b8152602060048201526011602482015270494e56414c49445f5349474e415455524560781b60448201526064016109fa565b6000818152600860205260409020546001600160a01b0316156112a25760405162461bcd60e51b81526020600482015260166024820152751513d2d15397d053149150511657d49151115153515160521b60448201526064016109fa565b81600401544210156112ea5760405162461bcd60e51b8152602060048201526011602482015270494e56414c49445f4f50454e5f4441544560781b60448201526064016109fa565b81600501544211156113335760405162461bcd60e51b8152602060048201526012602482015271494e56414c49445f434c4f53455f4441544560701b60448201526064016109fa565b6002820154156113915781600201548611156113915760405162461bcd60e51b815260206004820152601b60248201527f494e56414c49445f4d41585f5045525f5452414e53414354494f4e000000000060448201526064016109fa565b6001820154156114025760006113a73389610ae3565b60018401549091506113b988836148df565b11156114005760405162461bcd60e51b81526020600482015260166024820152751253959053125117d3505617d4115497d5d05313115560521b60448201526064016109fa565b505b60038201541561145f5785826003015461141c91906148f7565b34101561145f5760405162461bcd60e51b815260206004820152601160248201527056414c55455f42454c4f575f505249434560781b60448201526064016109fa565b815460008881526005602052604090205461147b9088906148df565b11156114c55760405162461bcd60e51b815260206004820152601960248201527850555243484153455f4558434545445f4d41585f4954454d5360381b60448201526064016109fa565b6114e0338888604051806020016040528060008152506128f5565b60008181526008602090815260409182902080546001600160a01b031916339081179091558251848152918201527f2310322c3f4ed401acfe8d97231f0f8ad43265f9da74d91004b8f625d0e2962a910160405180910390a150505050505050565b6001600160a01b03851633148061155e575061155e85336108e6565b6115c55760405162461bcd60e51b815260206004820152603260248201527f455243313135353a207472616e736665722063616c6c6572206973206e6f74206044820152711bdddb995c881b9bdc88185c1c1c9bdd995960721b60648201526084016109fa565b610adc8585858585612901565b6000828152600360205260409020600101546115ee8133612798565b6115f88383612aa3565b505050565b6001600160a01b038116331461166d5760405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201526e103937b632b9903337b91039b2b63360891b60648201526084016109fa565b6116778282612b29565b5050565b600080516020614da78339815191526116948133612798565b61169c612b90565b50565b600080516020614da78339815191526116b88133612798565b60008451116116d95760405162461bcd60e51b81526004016109fa90614756565b835183511461171e5760405162461bcd60e51b8152602060048201526011602482015270494e56414c49445f4f50454e5f53495a4560781b60448201526064016109fa565b83518251146117645760405162461bcd60e51b8152602060048201526012602482015271494e56414c49445f434c4f53455f53495a4560701b60448201526064016109fa565b60005b845181101561188e5782818151811061178257611782614783565b602002602001015184828151811061179c5761179c614783565b602002602001015111156117e25760405162461bcd60e51b815260206004820152600d60248201526c494e56414c49445f444154455360981b60448201526064016109fa565b6000600760008784815181106117fa576117fa614783565b60200260200101518152602001908152602001600020905060008160000154116118365760405162461bcd60e51b81526004016109fa90614799565b84828151811061184857611848614783565b6020026020010151816004018190555083828151811061186a5761186a614783565b60200260200101518160050181905550508080611886906147db565b915050611767565b507f396df38625537eac114c72dc57288ba26ee0169e7dd3889e273e40c3f0ab40cf8484846040516118c293929190614916565b60405180910390a150505050565b606081518351146119355760405162461bcd60e51b815260206004820152602960248201527f455243313135353a206163636f756e747320616e6420696473206c656e677468604482015268040dad2e6dac2e8c6d60bb1b60648201526084016109fa565b600083516001600160401b0381111561195057611950613e97565b604051908082528060200260200182016040528015611979578160200160208202803683370190505b50905060005b84518110156119f1576119c485828151811061199d5761199d614783565b60200260200101518583815181106119b7576119b7614783565b6020026020010151610ae3565b8282815181106119d6576119d6614783565b60209081029190910101526119ea816147db565b905061197f565b509392505050565b60008181526007602052604081208054611a255760405162461bcd60e51b81526004016109fa90614799565b6002015492915050565b600080516020614da7833981519152611a488133612798565b50600090815260086020526040902080546001600160a01b0319169055565b6001600160a01b038316331480611a835750611a8383336108e6565b611a9f5760405162461bcd60e51b81526004016109fa90614959565b6115f8838383612c23565b600080516020614da7833981519152611ac38133612798565b60045460ff1615611ae65760405162461bcd60e51b81526004016109fa90614856565b60008481526007602052604090208054611b125760405162461bcd60e51b81526004016109fa90614799565b8054600086815260056020526040902054611b2e9086906148df565b1115611b785760405162461bcd60e51b815260206004820152601960248201527850555243484153455f4558434545445f4d41585f4954454d5360381b60448201526064016109fa565b611b84868686866128f5565b505050505050565b60008181526007602052604081208054611bb85760405162461bcd60e51b81526004016109fa90614799565b6004015492915050565b60008181526007602052604081208054611bee5760405162461bcd60e51b81526004016109fa90614799565b600601546001600160a01b031692915050565b600080516020614da7833981519152611c1a8133612798565b61169c612c2e565b6000611c2d60065490565b905090565b60009182526003602090815260408084206001600160a01b0393909316845291905290205460ff1690565b600080516020614da7833981519152611c768133612798565b81516115f8906009906020850190613d5a565b336001600160a01b0383161415611cf45760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2073657474696e6720617070726f76616c20737461747573604482015268103337b91039b2b63360b91b60648201526084016109fa565b3360008181526001602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b600080516020614da7833981519152611d798133612798565b600060065560005b828110156115f857611d97600680546001019055565b80611da1816147db565b915050611d81565b600080516020614da7833981519152611dc28133612798565b6000835111611de35760405162461bcd60e51b81526004016109fa90614756565b8251825114611e345760405162461bcd60e51b815260206004820152601c60248201527f494e56414c49445f4d41585f5452414e53414354494f4e5f53495a450000000060448201526064016109fa565b60005b8351811015611eca57600060076000868481518110611e5857611e58614783565b6020026020010151815260200190815260200160002090506000816000015411611e945760405162461bcd60e51b81526004016109fa90614799565b838281518110611ea657611ea6614783565b60200260200101518160020181905550508080611ec2906147db565b915050611e37565b507f7e144fd6b36fcdb9448b08cb1dd907f43c49241caa48f7ee7eb69932074230268383604051610d869291906147f6565b600080516020614da7833981519152611f158133612798565b50600090815260076020526040812081815560018101829055600281018290556003810182905560048101829055600581019190915560060180546001600160a01b0319169055565b600080516020614da7833981519152611f778133612798565b6000835111611f985760405162461bcd60e51b81526004016109fa90614756565b8251825114611fdf5760405162461bcd60e51b8152602060048201526013602482015272494e56414c49445f5052494345535f53495a4560681b60448201526064016109fa565b60005b83518110156120755760006007600086848151811061200357612003614783565b602002602001015181526020019081526020016000209050600081600001541161203f5760405162461bcd60e51b81526004016109fa90614799565b83828151811061205157612051614783565b6020026020010151816003018190555050808061206d906147db565b915050611fe2565b507fbe192de9462d6c5663b4a1ca8035d8bb4c41a613f8842b02c1941bf1b52b10378383604051610d869291906147f6565b60045460ff16156120ca5760405162461bcd60e51b81526004016109fa90614856565b600082815260076020526040902080546120f65760405162461bcd60e51b81526004016109fa90614799565b60068101546001600160a01b03166121505760405162461bcd60e51b815260206004820152601860248201527f494e56414c49445f434f4e54524143545f41444452455353000000000000000060448201526064016109fa565b60068101546001600160a01b031633146121a55760405162461bcd60e51b8152602060048201526016602482015275494e56414c49445f53454e4445525f4144445245535360501b60448201526064016109fa565b6121b0848484612ca9565b50505050565b6000828152600360205260409020600101546121d28133612798565b6115f88383612b29565b600081815260076020526040812080546122085760405162461bcd60e51b81526004016109fa90614799565b5492915050565b6000818152600760205260408120805461223b5760405162461bcd60e51b81526004016109fa90614799565b6003015492915050565b600081815260076020526040812080546122715760405162461bcd60e51b81526004016109fa90614799565b6001015492915050565b60606009805461228a9061481b565b80601f01602080910402602001604051908101604052809291908181526020018280546122b69061481b565b80156123035780601f106122d857610100808354040283529160200191612303565b820191906000526020600020905b8154815290600101906020018083116122e657829003601f168201915b5050505050905090565b600080516020614da78339815191526123268133612798565b6000881161236e5760405162461bcd60e51b8152602060048201526015602482015274494e56414c49445f4e554d4245525f544f4b454e5360581b60448201526064016109fa565b878751146123b75760405162461bcd60e51b8152602060048201526016602482015275494e56414c49445f4d41585f4954454d535f53495a4560501b60448201526064016109fa565b878651146124015760405162461bcd60e51b8152602060048201526017602482015276494e56414c49445f4d41585f57414c4c45545f53495a4560481b60448201526064016109fa565b878551146124515760405162461bcd60e51b815260206004820152601c60248201527f494e56414c49445f4d41585f5452414e53414354494f4e5f53495a450000000060448201526064016109fa565b878451146124975760405162461bcd60e51b8152602060048201526013602482015272494e56414c49445f5052494345535f53495a4560681b60448201526064016109fa565b878351146124db5760405162461bcd60e51b8152602060048201526011602482015270494e56414c49445f4f50454e5f53495a4560781b60448201526064016109fa565b878251146125205760405162461bcd60e51b8152602060048201526012602482015271494e56414c49445f434c4f53455f53495a4560701b60448201526064016109fa565b60005b8881101561270557600088828151811061253f5761253f614783565b6020026020010151116125875760405162461bcd60e51b815260206004820152601060248201526f494e56414c49445f4d41585f4954454d60801b60448201526064016109fa565b82818151811061259957612599614783565b60200260200101518482815181106125b3576125b3614783565b602002602001015111156125f95760405162461bcd60e51b815260206004820152600d60248201526c494e56414c49445f444154455360981b60448201526064016109fa565b60006007600061260860065490565b8152602001908152602001600020905088828151811061262a5761262a614783565b6020026020010151816000018190555086828151811061264c5761264c614783565b6020026020010151816002018190555087828151811061266e5761266e614783565b6020026020010151816001018190555085828151811061269057612690614783565b602002602001015181600301819055508482815181106126b2576126b2614783565b602002602001015181600401819055508382815181106126d4576126d4614783565b602002602001015181600501819055506126f2600680546001019055565b50806126fd816147db565b915050612523565b505050505050505050565b6001600160a01b03851633148061272c575061272c85336108e6565b6127485760405162461bcd60e51b81526004016109fa90614959565b610adc8585858585612cb4565b6001600160a01b038316331480612771575061277183336108e6565b61278d5760405162461bcd60e51b81526004016109fa90614959565b6115f8838383612ca9565b6127a28282611c32565b611677576127ba816001600160a01b03166014612de0565b6127c5836020612de0565b6040516020016127d69291906149a2565b60408051601f198184030181529082905262461bcd60e51b82526109fa916004016140ee565b60006001600160e01b03198216637965db0b60e01b1480610b805750610b8082612f7b565b8051611677906002906020840190613d5a565b6121b084848484612fcb565b604080517f6c614e0727fa7406d276937059675ea43b8e8586c92a0aebc9ecfd2dc187237660208201526001600160a01b03861691810191909152606081018490526080810183905260a081018290526000906128b59060c0016040516020818303038152906040528051906020012061304e565b95945050505050565b60006128ee7fe2f4eaae4a9751e85a3e4a7b9587827a877f29914755229b07a7b2da98285f706106db858561309c565b9392505050565b6121b0848484846130b8565b81518351146129225760405162461bcd60e51b81526004016109fa90614a17565b6001600160a01b0384166129485760405162461bcd60e51b81526004016109fa90614a5f565b336129578187878787876130ed565b60005b8451811015612a3d57600085828151811061297757612977614783565b60200260200101519050600085838151811061299557612995614783565b602090810291909101810151600084815280835260408082206001600160a01b038e1683529093529190912054909150818110156129e55760405162461bcd60e51b81526004016109fa90614aa4565b6000838152602081815260408083206001600160a01b038e8116855292528083208585039055908b16825281208054849290612a229084906148df565b9250508190555050505080612a36906147db565b905061295a565b50846001600160a01b0316866001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8787604051612a8d9291906147f6565b60405180910390a4611b84818787878787613138565b612aad8282611c32565b6116775760008281526003602090815260408083206001600160a01b03851684529091529020805460ff19166001179055612ae53390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b612b338282611c32565b156116775760008281526003602090815260408083206001600160a01b0385168085529252808320805460ff1916905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b60045460ff16612bd95760405162461bcd60e51b815260206004820152601460248201527314185d5cd8589b194e881b9bdd081c185d5cd95960621b60448201526064016109fa565b6004805460ff191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b6040516001600160a01b03909116815260200160405180910390a1565b6115f88383836132a3565b60045460ff1615612c745760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b60448201526064016109fa565b6004805460ff191660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258612c063390565b6115f8838383613325565b6001600160a01b038416612cda5760405162461bcd60e51b81526004016109fa90614a5f565b33612cf9818787612cea88613358565b612cf388613358565b876130ed565b6000848152602081815260408083206001600160a01b038a16845290915290205483811015612d3a5760405162461bcd60e51b81526004016109fa90614aa4565b6000858152602081815260408083206001600160a01b038b8116855292528083208785039055908816825281208054869290612d779084906148df565b909155505060408051868152602081018690526001600160a01b03808916928a821692918616917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a4612dd78288888888886133a3565b50505050505050565b60606000612def8360026148f7565b612dfa9060026148df565b6001600160401b03811115612e1157612e11613e97565b6040519080825280601f01601f191660200182016040528015612e3b576020820181803683370190505b509050600360fc1b81600081518110612e5657612e56614783565b60200101906001600160f81b031916908160001a905350600f60fb1b81600181518110612e8557612e85614783565b60200101906001600160f81b031916908160001a9053506000612ea98460026148f7565b612eb49060016148df565b90505b6001811115612f2c576f181899199a1a9b1b9c1cb0b131b232b360811b85600f1660108110612ee857612ee8614783565b1a60f81b828281518110612efe57612efe614783565b60200101906001600160f81b031916908160001a90535060049490941c93612f2581614aee565b9050612eb7565b5083156128ee5760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e7460448201526064016109fa565b60006001600160e01b03198216636cdb3d1360e11b1480612fac57506001600160e01b031982166303a24d0760e21b145b80610b8057506301ffc9a760e01b6001600160e01b0319831614610b80565b612fd78484848461346d565b60005b8351811015610adc57828181518110612ff557612ff5614783565b60200260200101516005600086848151811061301357613013614783565b60200260200101518152602001908152602001600020600082825461303891906148df565b909155506130479050816147db565b9050612fda565b6000610b8061305b6135c7565b8360405161190160f01b6020820152602281018390526042810182905260009060620160405160208183030381529060405280519060200120905092915050565b60008060006130ab85856136bd565b915091506119f18161372d565b6130c4848484846138e8565b600083815260056020526040812080548492906130e29084906148df565b909155505050505050565b60045460ff16156131335760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b60448201526064016109fa565b611b84565b6001600160a01b0384163b15611b845760405163bc197c8160e01b81526001600160a01b0385169063bc197c819061317c9089908990889088908890600401614b05565b602060405180830381600087803b15801561319657600080fd5b505af19250505080156131c6575060408051601f3d908101601f191682019092526131c391810190614b63565b60015b613273576131d2614b80565b806308c379a0141561320c57506131e7614b9b565b806131f2575061320e565b8060405162461bcd60e51b81526004016109fa91906140ee565b505b60405162461bcd60e51b815260206004820152603460248201527f455243313135353a207472616e7366657220746f206e6f6e20455243313135356044820152732932b1b2b4bb32b91034b6b83632b6b2b73a32b960611b60648201526084016109fa565b6001600160e01b0319811663bc197c8160e01b14612dd75760405162461bcd60e51b81526004016109fa90614c24565b6132ae8383836139af565b60005b82518110156121b0578181815181106132cc576132cc614783565b6020026020010151600560008584815181106132ea576132ea614783565b60200260200101518152602001908152602001600020600082825461330f9190614c6c565b9091555061331e9050816147db565b90506132b1565b613330838383613b3d565b6000828152600560205260408120805483929061334e908490614c6c565b9091555050505050565b6040805160018082528183019092526060916000919060208083019080368337019050509050828160008151811061339257613392614783565b602090810291909101015292915050565b6001600160a01b0384163b15611b845760405163f23a6e6160e01b81526001600160a01b0385169063f23a6e61906133e79089908990889088908890600401614c83565b602060405180830381600087803b15801561340157600080fd5b505af1925050508015613431575060408051601f3d908101601f1916820190925261342e91810190614b63565b60015b61343d576131d2614b80565b6001600160e01b0319811663f23a6e6160e01b14612dd75760405162461bcd60e51b81526004016109fa90614c24565b6001600160a01b0384166134935760405162461bcd60e51b81526004016109fa90614cc8565b81518351146134b45760405162461bcd60e51b81526004016109fa90614a17565b336134c4816000878787876130ed565b60005b845181101561355f578381815181106134e2576134e2614783565b60200260200101516000808784815181106134ff576134ff614783565b602002602001015181526020019081526020016000206000886001600160a01b03166001600160a01b03168152602001908152602001600020600082825461354791906148df565b90915550819050613557816147db565b9150506134c7565b50846001600160a01b031660006001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb87876040516135b09291906147f6565b60405180910390a4610adc81600087878787613138565b60007f000000000000000000000000000000000000000000000000000000000000000046141561361657507f000000000000000000000000000000000000000000000000000000000000000090565b50604080517f00000000000000000000000000000000000000000000000000000000000000006020808301919091527f0000000000000000000000000000000000000000000000000000000000000000828401527f000000000000000000000000000000000000000000000000000000000000000060608301524660808301523060a0808401919091528351808403909101815260c0909201909252805191012090565b90565b6000808251604114156136f45760208301516040840151606085015160001a6136e887828585613c3e565b94509450505050613726565b82516040141561371e5760208301516040840151613713868383613d2b565b935093505050613726565b506000905060025b9250929050565b600081600481111561374157613741614d09565b141561374a5750565b600181600481111561375e5761375e614d09565b14156137ac5760405162461bcd60e51b815260206004820152601860248201527f45434453413a20696e76616c6964207369676e6174757265000000000000000060448201526064016109fa565b60028160048111156137c0576137c0614d09565b141561380e5760405162461bcd60e51b815260206004820152601f60248201527f45434453413a20696e76616c6964207369676e6174757265206c656e6774680060448201526064016109fa565b600381600481111561382257613822614d09565b141561387b5760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202773272076616c604482015261756560f01b60648201526084016109fa565b600481600481111561388f5761388f614d09565b141561169c5760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202776272076616c604482015261756560f01b60648201526084016109fa565b6001600160a01b03841661390e5760405162461bcd60e51b81526004016109fa90614cc8565b3361391f81600087612cea88613358565b6000848152602081815260408083206001600160a01b03891684529091528120805485929061394f9084906148df565b909155505060408051858152602081018590526001600160a01b0380881692600092918516917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a4610adc816000878787876133a3565b6001600160a01b0383166139d55760405162461bcd60e51b81526004016109fa90614d1f565b80518251146139f65760405162461bcd60e51b81526004016109fa90614a17565b6000339050613a19818560008686604051806020016040528060008152506130ed565b60005b8351811015613ade576000848281518110613a3957613a39614783565b602002602001015190506000848381518110613a5757613a57614783565b602090810291909101810151600084815280835260408082206001600160a01b038c168352909352919091205490915081811015613aa75760405162461bcd60e51b81526004016109fa90614d62565b6000928352602083815260408085206001600160a01b038b1686529091529092209103905580613ad6816147db565b915050613a1c565b5060006001600160a01b0316846001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8686604051613b2f9291906147f6565b60405180910390a450505050565b6001600160a01b038316613b635760405162461bcd60e51b81526004016109fa90614d1f565b33613b9281856000613b7487613358565b613b7d87613358565b604051806020016040528060008152506130ed565b6000838152602081815260408083206001600160a01b038816845290915290205482811015613bd35760405162461bcd60e51b81526004016109fa90614d62565b6000848152602081815260408083206001600160a01b03898116808652918452828520888703905582518981529384018890529092908616917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a45050505050565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0831115613c755750600090506003613d22565b8460ff16601b14158015613c8d57508460ff16601c14155b15613c9e5750600090506004613d22565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa158015613cf2573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116613d1b57600060019250925050613d22565b9150600090505b94509492505050565b6000806001600160ff1b03831660ff84901c601b01613d4c87828885613c3e565b935093505050935093915050565b828054613d669061481b565b90600052602060002090601f016020900481019282613d885760008555613dce565b82601f10613da157805160ff1916838001178555613dce565b82800160010185558215613dce579182015b82811115613dce578251825591602001919060010190613db3565b50613dda929150613dde565b5090565b5b80821115613dda5760008155600101613ddf565b6001600160a01b038116811461169c57600080fd5b60008060408385031215613e1b57600080fd5b823591506020830135613e2d81613df3565b809150509250929050565b60008060408385031215613e4b57600080fd5b8235613e5681613df3565b946020939093013593505050565b6001600160e01b03198116811461169c57600080fd5b600060208284031215613e8c57600080fd5b81356128ee81613e64565b634e487b7160e01b600052604160045260246000fd5b601f8201601f191681016001600160401b0381118282101715613ed257613ed2613e97565b6040525050565b60006001600160401b03831115613ef257613ef2613e97565b604051613f09601f8501601f191660200182613ead565b809150838152848484011115613f1e57600080fd5b83836020830137600060208583010152509392505050565b600060208284031215613f4857600080fd5b81356001600160401b03811115613f5e57600080fd5b8201601f81018413613f6f57600080fd5b613f7e84823560208401613ed9565b949350505050565b60006001600160401b03821115613f9f57613f9f613e97565b5060051b60200190565b600082601f830112613fba57600080fd5b81356020613fc782613f86565b604051613fd48282613ead565b83815260059390931b8501820192828101915086841115613ff457600080fd5b8286015b8481101561400f5780358352918301918301613ff8565b509695505050505050565b6000806040838503121561402d57600080fd5b82356001600160401b038082111561404457600080fd5b61405086838701613fa9565b9350602085013591508082111561406657600080fd5b5061407385828601613fa9565b9150509250929050565b60006020828403121561408f57600080fd5b5035919050565b60005b838110156140b1578181015183820152602001614099565b838111156121b05750506000910152565b600081518084526140da816020860160208601614096565b601f01601f19169290920160200192915050565b6020815260006128ee60208301846140c2565b600082601f83011261411257600080fd5b6128ee83833560208501613ed9565b6000806000806080858703121561413757600080fd5b843561414281613df3565b935060208501356001600160401b038082111561415e57600080fd5b61416a88838901613fa9565b9450604087013591508082111561418057600080fd5b61418c88838901613fa9565b935060608701359150808211156141a257600080fd5b506141af87828801614101565b91505092959194509250565b600082601f8301126141cc57600080fd5b813560206141d982613f86565b6040516141e68282613ead565b83815260059390931b850182019282810191508684111561420657600080fd5b8286015b8481101561400f57803561421d81613df3565b835291830191830161420a565b6000806040838503121561423d57600080fd5b82356001600160401b038082111561425457600080fd5b61426086838701613fa9565b9350602085013591508082111561427657600080fd5b50614073858286016141bb565b60008060008060006080868803121561429b57600080fd5b85359450602086013593506040860135925060608601356001600160401b03808211156142c757600080fd5b818801915088601f8301126142db57600080fd5b8135818111156142ea57600080fd5b8960208285010111156142fc57600080fd5b9699959850939650602001949392505050565b600080600080600060a0868803121561432757600080fd5b853561433281613df3565b9450602086013561434281613df3565b935060408601356001600160401b038082111561435e57600080fd5b61436a89838a01613fa9565b9450606088013591508082111561438057600080fd5b61438c89838a01613fa9565b935060808801359150808211156143a257600080fd5b506143af88828901614101565b9150509295509295909350565b6000806000606084860312156143d157600080fd5b83356001600160401b03808211156143e857600080fd5b6143f487838801613fa9565b9450602086013591508082111561440a57600080fd5b61441687838801613fa9565b9350604086013591508082111561442c57600080fd5b5061443986828701613fa9565b9150509250925092565b6000806040838503121561445657600080fd5b82356001600160401b038082111561446d57600080fd5b614050868387016141bb565b600081518084526020808501945080840160005b838110156144a95781518752958201959082019060010161448d565b509495945050505050565b6020815260006128ee6020830184614479565b6000806000606084860312156144dc57600080fd5b83356144e781613df3565b925060208401356001600160401b038082111561440a57600080fd5b6000806000806080858703121561451957600080fd5b843561452481613df3565b9350602085013592506040850135915060608501356001600160401b0381111561454d57600080fd5b6141af87828801614101565b6000806040838503121561456c57600080fd5b823561457781613df3565b915060208301358015158114613e2d57600080fd5b6000806000606084860312156145a157600080fd5b83356145ac81613df3565b95602085013595506040909401359392505050565b600080604083850312156145d457600080fd5b82356145df81613df3565b91506020830135613e2d81613df3565b600080600080600080600060e0888a03121561460a57600080fd5b8735965060208801356001600160401b038082111561462857600080fd5b6146348b838c01613fa9565b975060408a013591508082111561464a57600080fd5b6146568b838c01613fa9565b965060608a013591508082111561466c57600080fd5b6146788b838c01613fa9565b955060808a013591508082111561468e57600080fd5b61469a8b838c01613fa9565b945060a08a01359150808211156146b057600080fd5b6146bc8b838c01613fa9565b935060c08a01359150808211156146d257600080fd5b506146df8a828b01613fa9565b91505092959891949750929550565b600080600080600060a0868803121561470657600080fd5b853561471181613df3565b9450602086013561472181613df3565b9350604086013592506060860135915060808601356001600160401b0381111561474a57600080fd5b6143af88828901614101565b602080825260139082015272494e56414c49445f544f4b454e535f53495a4560681b604082015260600190565b634e487b7160e01b600052603260045260246000fd5b6020808252601290820152711513d2d15397d25117d393d517d1561254d560721b604082015260600190565b634e487b7160e01b600052601160045260246000fd5b60006000198214156147ef576147ef6147c5565b5060010190565b6040815260006148096040830185614479565b82810360208401526128b58185614479565b600181811c9082168061482f57607f821691505b6020821081141561485057634e487b7160e01b600052602260045260246000fd5b50919050565b6020808252600f908201526e10d3d395149050d517d4105554d151608a1b604082015260600190565b6040815260006148926040830185614479565b82810360208481019190915284518083528582019282019060005b818110156148d25784516001600160a01b0316835293830193918301916001016148ad565b5090979650505050505050565b600082198211156148f2576148f26147c5565b500190565b6000816000190483118215151615614911576149116147c5565b500290565b6060815260006149296060830186614479565b828103602084015261493b8186614479565b9050828103604084015261494f8185614479565b9695505050505050565b60208082526029908201527f455243313135353a2063616c6c6572206973206e6f74206f776e6572206e6f7260408201526808185c1c1c9bdd995960ba1b606082015260800190565b7f416363657373436f6e74726f6c3a206163636f756e74200000000000000000008152600083516149da816017850160208801614096565b7001034b99036b4b9b9b4b733903937b6329607d1b6017918401918201528351614a0b816028840160208801614096565b01602801949350505050565b60208082526028908201527f455243313135353a2069647320616e6420616d6f756e7473206c656e677468206040820152670dad2e6dac2e8c6d60c31b606082015260800190565b60208082526025908201527f455243313135353a207472616e7366657220746f20746865207a65726f206164604082015264647265737360d81b606082015260800190565b6020808252602a908201527f455243313135353a20696e73756666696369656e742062616c616e636520666f60408201526939103a3930b739b332b960b11b606082015260800190565b600081614afd57614afd6147c5565b506000190190565b6001600160a01b0386811682528516602082015260a060408201819052600090614b3190830186614479565b8281036060840152614b438186614479565b90508281036080840152614b5781856140c2565b98975050505050505050565b600060208284031215614b7557600080fd5b81516128ee81613e64565b600060033d11156136ba5760046000803e5060005160e01c90565b600060443d1015614ba95790565b6040516003193d81016004833e81513d6001600160401b038160248401118184111715614bd857505050505090565b8285019150815181811115614bf05750505050505090565b843d8701016020828501011115614c0a5750505050505090565b614c1960208286010187613ead565b509095945050505050565b60208082526028908201527f455243313135353a204552433131353552656365697665722072656a656374656040820152676420746f6b656e7360c01b606082015260800190565b600082821015614c7e57614c7e6147c5565b500390565b6001600160a01b03868116825285166020820152604081018490526060810183905260a060808201819052600090614cbd908301846140c2565b979650505050505050565b60208082526021908201527f455243313135353a206d696e7420746f20746865207a65726f206164647265736040820152607360f81b606082015260800190565b634e487b7160e01b600052602160045260246000fd5b60208082526023908201527f455243313135353a206275726e2066726f6d20746865207a65726f206164647260408201526265737360e81b606082015260800190565b60208082526024908201527f455243313135353a206275726e20616d6f756e7420657863656564732062616c604082015263616e636560e01b60608201526080019056fe97667070c54ef182b0f5858b034beac1b6f3089aa2d3188bb1e8929f4fa9b929a26469706673582212204472ea7035a7982c41c91a0c1fa6375d38c1d5f89e1f345cdbd3260bc39df60464736f6c63430008090033000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000094e6f6d6164506173730000000000000000000000000000000000000000000000
Deployed Bytecode
0x6080604052600436106102c75760003560e01c80637bb6892811610175578063bd85b039116100dc578063e7c8d22d11610095578063ed8a4a851161006f578063ed8a4a8514610914578063f242432a14610934578063f5298aca14610954578063f5b541a61461097457600080fd5b8063e7c8d22d14610896578063e8a3d485146108b6578063e985e9c5146108cb57600080fd5b8063bd85b039146107c9578063d05eaae0146107f6578063d0cd863f14610816578063d547741f14610836578063df7b742814610856578063e75722301461087657600080fd5b8063a1ebf35d1161012e578063a1ebf35d14610700578063a217fddf14610734578063a22cb46514610749578063b67797d614610769578063b72b3bfe14610789578063ba32e67e146107a957600080fd5b80637bb689281461062a5780638456cb591461066257806385f438c1146106775780638ada066e146106ab57806391d14854146106c0578063938e3d7b146106e057600080fd5b80632eb2c2d6116102345780634f558e79116101ed57806363f0bfce116101c757806363f0bfce146105aa5780636b20c454146105ca578063731133e9146105ea57806375321c4a1461060a57600080fd5b80634f558e79146105435780635c975abb146105725780636372f6fe1461058a57600080fd5b80632eb2c2d6146104815780632f2ff15d146104a157806336568abe146104c15780633f4ba83a146104e1578063448db696146104f65780634e1273f41461051657600080fd5b806313caf5511161028657806313caf551146103be5780631ed2b37e146103de5780631f7fdffa146103fe578063248a9ca31461041e57806327dafe5b1461044e5780632c3e9d9d1461046e57600080fd5b8062f714ce146102cc578062fdd58e146102ee57806301ffc9a71461032157806302fe53051461035157806303ceb77f146103715780630e89341c14610391575b600080fd5b3480156102d857600080fd5b506102ec6102e7366004613e08565b610996565b005b3480156102fa57600080fd5b5061030e610309366004613e38565b610ae3565b6040519081526020015b60405180910390f35b34801561032d57600080fd5b5061034161033c366004613e7a565b610b75565b6040519015158152602001610318565b34801561035d57600080fd5b506102ec61036c366004613f36565b610b86565b34801561037d57600080fd5b506102ec61038c36600461401a565b610be3565b34801561039d57600080fd5b506103b16103ac36600461407d565b610d93565b60405161031891906140ee565b3480156103ca57600080fd5b5061030e6103d936600461407d565b610e27565b3480156103ea57600080fd5b506102ec6103f936600461401a565b610e5d565b34801561040a57600080fd5b506102ec610419366004614121565b610faa565b34801561042a57600080fd5b5061030e61043936600461407d565b60009081526003602052604090206001015490565b34801561045a57600080fd5b506102ec61046936600461422a565b610ff2565b6102ec61047c366004614283565b611165565b34801561048d57600080fd5b506102ec61049c36600461430f565b611542565b3480156104ad57600080fd5b506102ec6104bc366004613e08565b6115d2565b3480156104cd57600080fd5b506102ec6104dc366004613e08565b6115fd565b3480156104ed57600080fd5b506102ec61167b565b34801561050257600080fd5b506102ec6105113660046143bc565b61169f565b34801561052257600080fd5b50610536610531366004614443565b6118d0565b60405161031891906144b4565b34801561054f57600080fd5b5061034161055e36600461407d565b600090815260056020526040902054151590565b34801561057e57600080fd5b5060045460ff16610341565b34801561059657600080fd5b5061030e6105a536600461407d565b6119f9565b3480156105b657600080fd5b506102ec6105c536600461407d565b611a2f565b3480156105d657600080fd5b506102ec6105e53660046144c7565b611a67565b3480156105f657600080fd5b506102ec610605366004614503565b611aaa565b34801561061657600080fd5b5061030e61062536600461407d565b611b8c565b34801561063657600080fd5b5061064a61064536600461407d565b611bc2565b6040516001600160a01b039091168152602001610318565b34801561066e57600080fd5b506102ec611c01565b34801561068357600080fd5b5061030e7f10dac8c06a04bec0b551627dad28bc00d6516b0caacd1c7b345fcdb5211334e481565b3480156106b757600080fd5b5061030e611c22565b3480156106cc57600080fd5b506103416106db366004613e08565b611c32565b3480156106ec57600080fd5b506102ec6106fb366004613f36565b611c5d565b34801561070c57600080fd5b5061030e7fe2f4eaae4a9751e85a3e4a7b9587827a877f29914755229b07a7b2da98285f7081565b34801561074057600080fd5b5061030e600081565b34801561075557600080fd5b506102ec610764366004614559565b611c89565b34801561077557600080fd5b506102ec61078436600461407d565b611d60565b34801561079557600080fd5b506102ec6107a436600461401a565b611da9565b3480156107b557600080fd5b506102ec6107c436600461407d565b611efc565b3480156107d557600080fd5b5061030e6107e436600461407d565b60009081526005602052604090205490565b34801561080257600080fd5b506102ec61081136600461401a565b611f5e565b34801561082257600080fd5b506102ec61083136600461458c565b6120a7565b34801561084257600080fd5b506102ec610851366004613e08565b6121b6565b34801561086257600080fd5b5061030e61087136600461407d565b6121dc565b34801561088257600080fd5b5061030e61089136600461407d565b61220f565b3480156108a257600080fd5b5061030e6108b136600461407d565b612245565b3480156108c257600080fd5b506103b161227b565b3480156108d757600080fd5b506103416108e63660046145c1565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205460ff1690565b34801561092057600080fd5b506102ec61092f3660046145ef565b61230d565b34801561094057600080fd5b506102ec61094f3660046146ee565b612710565b34801561096057600080fd5b506102ec61096f36600461458c565b612755565b34801561098057600080fd5b5061030e600080516020614da783398151915281565b7f10dac8c06a04bec0b551627dad28bc00d6516b0caacd1c7b345fcdb5211334e46109c18133612798565b4780610a035760405162461bcd60e51b815260206004820152600c60248201526b42414c414e43455f5a45524f60a01b60448201526064015b60405180910390fd5b83811015610a475760405162461bcd60e51b8152602060048201526011602482015270414d4f554e545f47545f42414c414e434560781b60448201526064016109fa565b6000836001600160a01b03168560405160006040518083038185875af1925050503d8060008114610a94576040519150601f19603f3d011682016040523d82523d6000602084013e610a99565b606091505b5050905080610adc5760405162461bcd60e51b815260206004820152600f60248201526e15d2551211149055d7d19052531151608a1b60448201526064016109fa565b5050505050565b60006001600160a01b038316610b4f5760405162461bcd60e51b815260206004820152602b60248201527f455243313135353a2062616c616e636520717565727920666f7220746865207a60448201526a65726f206164647265737360a81b60648201526084016109fa565b506000908152602081815260408083206001600160a01b03949094168352929052205490565b6000610b80826127fc565b92915050565b600080516020614da7833981519152610b9f8133612798565b610ba882612821565b7fb1bf12e17db588c31e8fb2afdd2b3bc1ed822d68c560856fcbc75ae303fc5d1482604051610bd791906140ee565b60405180910390a15050565b600080516020614da7833981519152610bfc8133612798565b6000835111610c1d5760405162461bcd60e51b81526004016109fa90614756565b8251825114610c675760405162461bcd60e51b8152602060048201526016602482015275494e56414c49445f4d41585f4954454d535f53495a4560501b60448201526064016109fa565b60005b8351811015610d54576000838281518110610c8757610c87614783565b602002602001015111610ccf5760405162461bcd60e51b815260206004820152601060248201526f494e56414c49445f4d41585f4954454d60801b60448201526064016109fa565b600060076000868481518110610ce757610ce7614783565b6020026020010151815260200190815260200160002090506000816000015411610d235760405162461bcd60e51b81526004016109fa90614799565b838281518110610d3557610d35614783565b6020908102919091010151905580610d4c816147db565b915050610c6a565b507f4402caae79d7b040a75c7d72c65fdd1be0cbe28590584456f0cbb49f2346f4e88383604051610d869291906147f6565b60405180910390a1505050565b606060028054610da29061481b565b80601f0160208091040260200160405190810160405280929190818152602001828054610dce9061481b565b8015610e1b5780601f10610df057610100808354040283529160200191610e1b565b820191906000526020600020905b815481529060010190602001808311610dfe57829003601f168201915b50505050509050919050565b60008181526007602052604081208054610e535760405162461bcd60e51b81526004016109fa90614799565b6005015492915050565b600080516020614da7833981519152610e768133612798565b6000835111610e975760405162461bcd60e51b81526004016109fa90614756565b8251825114610ee25760405162461bcd60e51b8152602060048201526017602482015276494e56414c49445f4d41585f57414c4c45545f53495a4560481b60448201526064016109fa565b60005b8351811015610f7857600060076000868481518110610f0657610f06614783565b6020026020010151815260200190815260200160002090506000816000015411610f425760405162461bcd60e51b81526004016109fa90614799565b838281518110610f5457610f54614783565b60200260200101518160010181905550508080610f70906147db565b915050610ee5565b507fb355828fc1c77f59b3e0f1ce2ade5407d2fac2a198475714987654ab2647c7ec8383604051610d869291906147f6565b600080516020614da7833981519152610fc38133612798565b60045460ff1615610fe65760405162461bcd60e51b81526004016109fa90614856565b610adc85858585612834565b600080516020614da783398151915261100b8133612798565b600083511161102c5760405162461bcd60e51b81526004016109fa90614756565b825182511461107d5760405162461bcd60e51b815260206004820152601d60248201527f494e56414c49445f52454445454d5f434f4e5452414354535f53495a4500000060448201526064016109fa565b60005b8351811015611133576000600760008684815181106110a1576110a1614783565b60200260200101518152602001908152602001600020905060008160000154116110dd5760405162461bcd60e51b81526004016109fa90614799565b8382815181106110ef576110ef614783565b60200260200101518160060160006101000a8154816001600160a01b0302191690836001600160a01b0316021790555050808061112b906147db565b915050611080565b507f7bd6be6cbe8904036ddacfaa6886ec26d27b698db8de720a6993590b58d971aa8383604051610d8692919061487f565b60045460ff16156111885760405162461bcd60e51b81526004016109fa90614856565b600085815260076020526040902080546111b45760405162461bcd60e51b81526004016109fa90614799565b60006111c233888888612840565b90506112048185858080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506128be92505050565b6112445760405162461bcd60e51b8152602060048201526011602482015270494e56414c49445f5349474e415455524560781b60448201526064016109fa565b6000818152600860205260409020546001600160a01b0316156112a25760405162461bcd60e51b81526020600482015260166024820152751513d2d15397d053149150511657d49151115153515160521b60448201526064016109fa565b81600401544210156112ea5760405162461bcd60e51b8152602060048201526011602482015270494e56414c49445f4f50454e5f4441544560781b60448201526064016109fa565b81600501544211156113335760405162461bcd60e51b8152602060048201526012602482015271494e56414c49445f434c4f53455f4441544560701b60448201526064016109fa565b6002820154156113915781600201548611156113915760405162461bcd60e51b815260206004820152601b60248201527f494e56414c49445f4d41585f5045525f5452414e53414354494f4e000000000060448201526064016109fa565b6001820154156114025760006113a73389610ae3565b60018401549091506113b988836148df565b11156114005760405162461bcd60e51b81526020600482015260166024820152751253959053125117d3505617d4115497d5d05313115560521b60448201526064016109fa565b505b60038201541561145f5785826003015461141c91906148f7565b34101561145f5760405162461bcd60e51b815260206004820152601160248201527056414c55455f42454c4f575f505249434560781b60448201526064016109fa565b815460008881526005602052604090205461147b9088906148df565b11156114c55760405162461bcd60e51b815260206004820152601960248201527850555243484153455f4558434545445f4d41585f4954454d5360381b60448201526064016109fa565b6114e0338888604051806020016040528060008152506128f5565b60008181526008602090815260409182902080546001600160a01b031916339081179091558251848152918201527f2310322c3f4ed401acfe8d97231f0f8ad43265f9da74d91004b8f625d0e2962a910160405180910390a150505050505050565b6001600160a01b03851633148061155e575061155e85336108e6565b6115c55760405162461bcd60e51b815260206004820152603260248201527f455243313135353a207472616e736665722063616c6c6572206973206e6f74206044820152711bdddb995c881b9bdc88185c1c1c9bdd995960721b60648201526084016109fa565b610adc8585858585612901565b6000828152600360205260409020600101546115ee8133612798565b6115f88383612aa3565b505050565b6001600160a01b038116331461166d5760405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201526e103937b632b9903337b91039b2b63360891b60648201526084016109fa565b6116778282612b29565b5050565b600080516020614da78339815191526116948133612798565b61169c612b90565b50565b600080516020614da78339815191526116b88133612798565b60008451116116d95760405162461bcd60e51b81526004016109fa90614756565b835183511461171e5760405162461bcd60e51b8152602060048201526011602482015270494e56414c49445f4f50454e5f53495a4560781b60448201526064016109fa565b83518251146117645760405162461bcd60e51b8152602060048201526012602482015271494e56414c49445f434c4f53455f53495a4560701b60448201526064016109fa565b60005b845181101561188e5782818151811061178257611782614783565b602002602001015184828151811061179c5761179c614783565b602002602001015111156117e25760405162461bcd60e51b815260206004820152600d60248201526c494e56414c49445f444154455360981b60448201526064016109fa565b6000600760008784815181106117fa576117fa614783565b60200260200101518152602001908152602001600020905060008160000154116118365760405162461bcd60e51b81526004016109fa90614799565b84828151811061184857611848614783565b6020026020010151816004018190555083828151811061186a5761186a614783565b60200260200101518160050181905550508080611886906147db565b915050611767565b507f396df38625537eac114c72dc57288ba26ee0169e7dd3889e273e40c3f0ab40cf8484846040516118c293929190614916565b60405180910390a150505050565b606081518351146119355760405162461bcd60e51b815260206004820152602960248201527f455243313135353a206163636f756e747320616e6420696473206c656e677468604482015268040dad2e6dac2e8c6d60bb1b60648201526084016109fa565b600083516001600160401b0381111561195057611950613e97565b604051908082528060200260200182016040528015611979578160200160208202803683370190505b50905060005b84518110156119f1576119c485828151811061199d5761199d614783565b60200260200101518583815181106119b7576119b7614783565b6020026020010151610ae3565b8282815181106119d6576119d6614783565b60209081029190910101526119ea816147db565b905061197f565b509392505050565b60008181526007602052604081208054611a255760405162461bcd60e51b81526004016109fa90614799565b6002015492915050565b600080516020614da7833981519152611a488133612798565b50600090815260086020526040902080546001600160a01b0319169055565b6001600160a01b038316331480611a835750611a8383336108e6565b611a9f5760405162461bcd60e51b81526004016109fa90614959565b6115f8838383612c23565b600080516020614da7833981519152611ac38133612798565b60045460ff1615611ae65760405162461bcd60e51b81526004016109fa90614856565b60008481526007602052604090208054611b125760405162461bcd60e51b81526004016109fa90614799565b8054600086815260056020526040902054611b2e9086906148df565b1115611b785760405162461bcd60e51b815260206004820152601960248201527850555243484153455f4558434545445f4d41585f4954454d5360381b60448201526064016109fa565b611b84868686866128f5565b505050505050565b60008181526007602052604081208054611bb85760405162461bcd60e51b81526004016109fa90614799565b6004015492915050565b60008181526007602052604081208054611bee5760405162461bcd60e51b81526004016109fa90614799565b600601546001600160a01b031692915050565b600080516020614da7833981519152611c1a8133612798565b61169c612c2e565b6000611c2d60065490565b905090565b60009182526003602090815260408084206001600160a01b0393909316845291905290205460ff1690565b600080516020614da7833981519152611c768133612798565b81516115f8906009906020850190613d5a565b336001600160a01b0383161415611cf45760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2073657474696e6720617070726f76616c20737461747573604482015268103337b91039b2b63360b91b60648201526084016109fa565b3360008181526001602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b600080516020614da7833981519152611d798133612798565b600060065560005b828110156115f857611d97600680546001019055565b80611da1816147db565b915050611d81565b600080516020614da7833981519152611dc28133612798565b6000835111611de35760405162461bcd60e51b81526004016109fa90614756565b8251825114611e345760405162461bcd60e51b815260206004820152601c60248201527f494e56414c49445f4d41585f5452414e53414354494f4e5f53495a450000000060448201526064016109fa565b60005b8351811015611eca57600060076000868481518110611e5857611e58614783565b6020026020010151815260200190815260200160002090506000816000015411611e945760405162461bcd60e51b81526004016109fa90614799565b838281518110611ea657611ea6614783565b60200260200101518160020181905550508080611ec2906147db565b915050611e37565b507f7e144fd6b36fcdb9448b08cb1dd907f43c49241caa48f7ee7eb69932074230268383604051610d869291906147f6565b600080516020614da7833981519152611f158133612798565b50600090815260076020526040812081815560018101829055600281018290556003810182905560048101829055600581019190915560060180546001600160a01b0319169055565b600080516020614da7833981519152611f778133612798565b6000835111611f985760405162461bcd60e51b81526004016109fa90614756565b8251825114611fdf5760405162461bcd60e51b8152602060048201526013602482015272494e56414c49445f5052494345535f53495a4560681b60448201526064016109fa565b60005b83518110156120755760006007600086848151811061200357612003614783565b602002602001015181526020019081526020016000209050600081600001541161203f5760405162461bcd60e51b81526004016109fa90614799565b83828151811061205157612051614783565b6020026020010151816003018190555050808061206d906147db565b915050611fe2565b507fbe192de9462d6c5663b4a1ca8035d8bb4c41a613f8842b02c1941bf1b52b10378383604051610d869291906147f6565b60045460ff16156120ca5760405162461bcd60e51b81526004016109fa90614856565b600082815260076020526040902080546120f65760405162461bcd60e51b81526004016109fa90614799565b60068101546001600160a01b03166121505760405162461bcd60e51b815260206004820152601860248201527f494e56414c49445f434f4e54524143545f41444452455353000000000000000060448201526064016109fa565b60068101546001600160a01b031633146121a55760405162461bcd60e51b8152602060048201526016602482015275494e56414c49445f53454e4445525f4144445245535360501b60448201526064016109fa565b6121b0848484612ca9565b50505050565b6000828152600360205260409020600101546121d28133612798565b6115f88383612b29565b600081815260076020526040812080546122085760405162461bcd60e51b81526004016109fa90614799565b5492915050565b6000818152600760205260408120805461223b5760405162461bcd60e51b81526004016109fa90614799565b6003015492915050565b600081815260076020526040812080546122715760405162461bcd60e51b81526004016109fa90614799565b6001015492915050565b60606009805461228a9061481b565b80601f01602080910402602001604051908101604052809291908181526020018280546122b69061481b565b80156123035780601f106122d857610100808354040283529160200191612303565b820191906000526020600020905b8154815290600101906020018083116122e657829003601f168201915b5050505050905090565b600080516020614da78339815191526123268133612798565b6000881161236e5760405162461bcd60e51b8152602060048201526015602482015274494e56414c49445f4e554d4245525f544f4b454e5360581b60448201526064016109fa565b878751146123b75760405162461bcd60e51b8152602060048201526016602482015275494e56414c49445f4d41585f4954454d535f53495a4560501b60448201526064016109fa565b878651146124015760405162461bcd60e51b8152602060048201526017602482015276494e56414c49445f4d41585f57414c4c45545f53495a4560481b60448201526064016109fa565b878551146124515760405162461bcd60e51b815260206004820152601c60248201527f494e56414c49445f4d41585f5452414e53414354494f4e5f53495a450000000060448201526064016109fa565b878451146124975760405162461bcd60e51b8152602060048201526013602482015272494e56414c49445f5052494345535f53495a4560681b60448201526064016109fa565b878351146124db5760405162461bcd60e51b8152602060048201526011602482015270494e56414c49445f4f50454e5f53495a4560781b60448201526064016109fa565b878251146125205760405162461bcd60e51b8152602060048201526012602482015271494e56414c49445f434c4f53455f53495a4560701b60448201526064016109fa565b60005b8881101561270557600088828151811061253f5761253f614783565b6020026020010151116125875760405162461bcd60e51b815260206004820152601060248201526f494e56414c49445f4d41585f4954454d60801b60448201526064016109fa565b82818151811061259957612599614783565b60200260200101518482815181106125b3576125b3614783565b602002602001015111156125f95760405162461bcd60e51b815260206004820152600d60248201526c494e56414c49445f444154455360981b60448201526064016109fa565b60006007600061260860065490565b8152602001908152602001600020905088828151811061262a5761262a614783565b6020026020010151816000018190555086828151811061264c5761264c614783565b6020026020010151816002018190555087828151811061266e5761266e614783565b6020026020010151816001018190555085828151811061269057612690614783565b602002602001015181600301819055508482815181106126b2576126b2614783565b602002602001015181600401819055508382815181106126d4576126d4614783565b602002602001015181600501819055506126f2600680546001019055565b50806126fd816147db565b915050612523565b505050505050505050565b6001600160a01b03851633148061272c575061272c85336108e6565b6127485760405162461bcd60e51b81526004016109fa90614959565b610adc8585858585612cb4565b6001600160a01b038316331480612771575061277183336108e6565b61278d5760405162461bcd60e51b81526004016109fa90614959565b6115f8838383612ca9565b6127a28282611c32565b611677576127ba816001600160a01b03166014612de0565b6127c5836020612de0565b6040516020016127d69291906149a2565b60408051601f198184030181529082905262461bcd60e51b82526109fa916004016140ee565b60006001600160e01b03198216637965db0b60e01b1480610b805750610b8082612f7b565b8051611677906002906020840190613d5a565b6121b084848484612fcb565b604080517f6c614e0727fa7406d276937059675ea43b8e8586c92a0aebc9ecfd2dc187237660208201526001600160a01b03861691810191909152606081018490526080810183905260a081018290526000906128b59060c0016040516020818303038152906040528051906020012061304e565b95945050505050565b60006128ee7fe2f4eaae4a9751e85a3e4a7b9587827a877f29914755229b07a7b2da98285f706106db858561309c565b9392505050565b6121b0848484846130b8565b81518351146129225760405162461bcd60e51b81526004016109fa90614a17565b6001600160a01b0384166129485760405162461bcd60e51b81526004016109fa90614a5f565b336129578187878787876130ed565b60005b8451811015612a3d57600085828151811061297757612977614783565b60200260200101519050600085838151811061299557612995614783565b602090810291909101810151600084815280835260408082206001600160a01b038e1683529093529190912054909150818110156129e55760405162461bcd60e51b81526004016109fa90614aa4565b6000838152602081815260408083206001600160a01b038e8116855292528083208585039055908b16825281208054849290612a229084906148df565b9250508190555050505080612a36906147db565b905061295a565b50846001600160a01b0316866001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8787604051612a8d9291906147f6565b60405180910390a4611b84818787878787613138565b612aad8282611c32565b6116775760008281526003602090815260408083206001600160a01b03851684529091529020805460ff19166001179055612ae53390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b612b338282611c32565b156116775760008281526003602090815260408083206001600160a01b0385168085529252808320805460ff1916905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b60045460ff16612bd95760405162461bcd60e51b815260206004820152601460248201527314185d5cd8589b194e881b9bdd081c185d5cd95960621b60448201526064016109fa565b6004805460ff191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b6040516001600160a01b03909116815260200160405180910390a1565b6115f88383836132a3565b60045460ff1615612c745760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b60448201526064016109fa565b6004805460ff191660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258612c063390565b6115f8838383613325565b6001600160a01b038416612cda5760405162461bcd60e51b81526004016109fa90614a5f565b33612cf9818787612cea88613358565b612cf388613358565b876130ed565b6000848152602081815260408083206001600160a01b038a16845290915290205483811015612d3a5760405162461bcd60e51b81526004016109fa90614aa4565b6000858152602081815260408083206001600160a01b038b8116855292528083208785039055908816825281208054869290612d779084906148df565b909155505060408051868152602081018690526001600160a01b03808916928a821692918616917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a4612dd78288888888886133a3565b50505050505050565b60606000612def8360026148f7565b612dfa9060026148df565b6001600160401b03811115612e1157612e11613e97565b6040519080825280601f01601f191660200182016040528015612e3b576020820181803683370190505b509050600360fc1b81600081518110612e5657612e56614783565b60200101906001600160f81b031916908160001a905350600f60fb1b81600181518110612e8557612e85614783565b60200101906001600160f81b031916908160001a9053506000612ea98460026148f7565b612eb49060016148df565b90505b6001811115612f2c576f181899199a1a9b1b9c1cb0b131b232b360811b85600f1660108110612ee857612ee8614783565b1a60f81b828281518110612efe57612efe614783565b60200101906001600160f81b031916908160001a90535060049490941c93612f2581614aee565b9050612eb7565b5083156128ee5760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e7460448201526064016109fa565b60006001600160e01b03198216636cdb3d1360e11b1480612fac57506001600160e01b031982166303a24d0760e21b145b80610b8057506301ffc9a760e01b6001600160e01b0319831614610b80565b612fd78484848461346d565b60005b8351811015610adc57828181518110612ff557612ff5614783565b60200260200101516005600086848151811061301357613013614783565b60200260200101518152602001908152602001600020600082825461303891906148df565b909155506130479050816147db565b9050612fda565b6000610b8061305b6135c7565b8360405161190160f01b6020820152602281018390526042810182905260009060620160405160208183030381529060405280519060200120905092915050565b60008060006130ab85856136bd565b915091506119f18161372d565b6130c4848484846138e8565b600083815260056020526040812080548492906130e29084906148df565b909155505050505050565b60045460ff16156131335760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b60448201526064016109fa565b611b84565b6001600160a01b0384163b15611b845760405163bc197c8160e01b81526001600160a01b0385169063bc197c819061317c9089908990889088908890600401614b05565b602060405180830381600087803b15801561319657600080fd5b505af19250505080156131c6575060408051601f3d908101601f191682019092526131c391810190614b63565b60015b613273576131d2614b80565b806308c379a0141561320c57506131e7614b9b565b806131f2575061320e565b8060405162461bcd60e51b81526004016109fa91906140ee565b505b60405162461bcd60e51b815260206004820152603460248201527f455243313135353a207472616e7366657220746f206e6f6e20455243313135356044820152732932b1b2b4bb32b91034b6b83632b6b2b73a32b960611b60648201526084016109fa565b6001600160e01b0319811663bc197c8160e01b14612dd75760405162461bcd60e51b81526004016109fa90614c24565b6132ae8383836139af565b60005b82518110156121b0578181815181106132cc576132cc614783565b6020026020010151600560008584815181106132ea576132ea614783565b60200260200101518152602001908152602001600020600082825461330f9190614c6c565b9091555061331e9050816147db565b90506132b1565b613330838383613b3d565b6000828152600560205260408120805483929061334e908490614c6c565b9091555050505050565b6040805160018082528183019092526060916000919060208083019080368337019050509050828160008151811061339257613392614783565b602090810291909101015292915050565b6001600160a01b0384163b15611b845760405163f23a6e6160e01b81526001600160a01b0385169063f23a6e61906133e79089908990889088908890600401614c83565b602060405180830381600087803b15801561340157600080fd5b505af1925050508015613431575060408051601f3d908101601f1916820190925261342e91810190614b63565b60015b61343d576131d2614b80565b6001600160e01b0319811663f23a6e6160e01b14612dd75760405162461bcd60e51b81526004016109fa90614c24565b6001600160a01b0384166134935760405162461bcd60e51b81526004016109fa90614cc8565b81518351146134b45760405162461bcd60e51b81526004016109fa90614a17565b336134c4816000878787876130ed565b60005b845181101561355f578381815181106134e2576134e2614783565b60200260200101516000808784815181106134ff576134ff614783565b602002602001015181526020019081526020016000206000886001600160a01b03166001600160a01b03168152602001908152602001600020600082825461354791906148df565b90915550819050613557816147db565b9150506134c7565b50846001600160a01b031660006001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb87876040516135b09291906147f6565b60405180910390a4610adc81600087878787613138565b60007f000000000000000000000000000000000000000000000000000000000000000146141561361657507fdcf2eca058de640b7b9094e2e70b2d5aa5d8dab11580b225d7c860ef923ca96f90565b50604080517f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f6020808301919091527fba0be682a18085340835a47fdaf38f886bb3159a7ea5d61943a11e1e024ee88f828401527f06c015bd22b4c69690933c1058878ebdfef31f9aaae40bbe86d8a09fe1b2972c60608301524660808301523060a0808401919091528351808403909101815260c0909201909252805191012090565b90565b6000808251604114156136f45760208301516040840151606085015160001a6136e887828585613c3e565b94509450505050613726565b82516040141561371e5760208301516040840151613713868383613d2b565b935093505050613726565b506000905060025b9250929050565b600081600481111561374157613741614d09565b141561374a5750565b600181600481111561375e5761375e614d09565b14156137ac5760405162461bcd60e51b815260206004820152601860248201527f45434453413a20696e76616c6964207369676e6174757265000000000000000060448201526064016109fa565b60028160048111156137c0576137c0614d09565b141561380e5760405162461bcd60e51b815260206004820152601f60248201527f45434453413a20696e76616c6964207369676e6174757265206c656e6774680060448201526064016109fa565b600381600481111561382257613822614d09565b141561387b5760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202773272076616c604482015261756560f01b60648201526084016109fa565b600481600481111561388f5761388f614d09565b141561169c5760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202776272076616c604482015261756560f01b60648201526084016109fa565b6001600160a01b03841661390e5760405162461bcd60e51b81526004016109fa90614cc8565b3361391f81600087612cea88613358565b6000848152602081815260408083206001600160a01b03891684529091528120805485929061394f9084906148df565b909155505060408051858152602081018590526001600160a01b0380881692600092918516917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a4610adc816000878787876133a3565b6001600160a01b0383166139d55760405162461bcd60e51b81526004016109fa90614d1f565b80518251146139f65760405162461bcd60e51b81526004016109fa90614a17565b6000339050613a19818560008686604051806020016040528060008152506130ed565b60005b8351811015613ade576000848281518110613a3957613a39614783565b602002602001015190506000848381518110613a5757613a57614783565b602090810291909101810151600084815280835260408082206001600160a01b038c168352909352919091205490915081811015613aa75760405162461bcd60e51b81526004016109fa90614d62565b6000928352602083815260408085206001600160a01b038b1686529091529092209103905580613ad6816147db565b915050613a1c565b5060006001600160a01b0316846001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8686604051613b2f9291906147f6565b60405180910390a450505050565b6001600160a01b038316613b635760405162461bcd60e51b81526004016109fa90614d1f565b33613b9281856000613b7487613358565b613b7d87613358565b604051806020016040528060008152506130ed565b6000838152602081815260408083206001600160a01b038816845290915290205482811015613bd35760405162461bcd60e51b81526004016109fa90614d62565b6000848152602081815260408083206001600160a01b03898116808652918452828520888703905582518981529384018890529092908616917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a45050505050565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0831115613c755750600090506003613d22565b8460ff16601b14158015613c8d57508460ff16601c14155b15613c9e5750600090506004613d22565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa158015613cf2573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116613d1b57600060019250925050613d22565b9150600090505b94509492505050565b6000806001600160ff1b03831660ff84901c601b01613d4c87828885613c3e565b935093505050935093915050565b828054613d669061481b565b90600052602060002090601f016020900481019282613d885760008555613dce565b82601f10613da157805160ff1916838001178555613dce565b82800160010185558215613dce579182015b82811115613dce578251825591602001919060010190613db3565b50613dda929150613dde565b5090565b5b80821115613dda5760008155600101613ddf565b6001600160a01b038116811461169c57600080fd5b60008060408385031215613e1b57600080fd5b823591506020830135613e2d81613df3565b809150509250929050565b60008060408385031215613e4b57600080fd5b8235613e5681613df3565b946020939093013593505050565b6001600160e01b03198116811461169c57600080fd5b600060208284031215613e8c57600080fd5b81356128ee81613e64565b634e487b7160e01b600052604160045260246000fd5b601f8201601f191681016001600160401b0381118282101715613ed257613ed2613e97565b6040525050565b60006001600160401b03831115613ef257613ef2613e97565b604051613f09601f8501601f191660200182613ead565b809150838152848484011115613f1e57600080fd5b83836020830137600060208583010152509392505050565b600060208284031215613f4857600080fd5b81356001600160401b03811115613f5e57600080fd5b8201601f81018413613f6f57600080fd5b613f7e84823560208401613ed9565b949350505050565b60006001600160401b03821115613f9f57613f9f613e97565b5060051b60200190565b600082601f830112613fba57600080fd5b81356020613fc782613f86565b604051613fd48282613ead565b83815260059390931b8501820192828101915086841115613ff457600080fd5b8286015b8481101561400f5780358352918301918301613ff8565b509695505050505050565b6000806040838503121561402d57600080fd5b82356001600160401b038082111561404457600080fd5b61405086838701613fa9565b9350602085013591508082111561406657600080fd5b5061407385828601613fa9565b9150509250929050565b60006020828403121561408f57600080fd5b5035919050565b60005b838110156140b1578181015183820152602001614099565b838111156121b05750506000910152565b600081518084526140da816020860160208601614096565b601f01601f19169290920160200192915050565b6020815260006128ee60208301846140c2565b600082601f83011261411257600080fd5b6128ee83833560208501613ed9565b6000806000806080858703121561413757600080fd5b843561414281613df3565b935060208501356001600160401b038082111561415e57600080fd5b61416a88838901613fa9565b9450604087013591508082111561418057600080fd5b61418c88838901613fa9565b935060608701359150808211156141a257600080fd5b506141af87828801614101565b91505092959194509250565b600082601f8301126141cc57600080fd5b813560206141d982613f86565b6040516141e68282613ead565b83815260059390931b850182019282810191508684111561420657600080fd5b8286015b8481101561400f57803561421d81613df3565b835291830191830161420a565b6000806040838503121561423d57600080fd5b82356001600160401b038082111561425457600080fd5b61426086838701613fa9565b9350602085013591508082111561427657600080fd5b50614073858286016141bb565b60008060008060006080868803121561429b57600080fd5b85359450602086013593506040860135925060608601356001600160401b03808211156142c757600080fd5b818801915088601f8301126142db57600080fd5b8135818111156142ea57600080fd5b8960208285010111156142fc57600080fd5b9699959850939650602001949392505050565b600080600080600060a0868803121561432757600080fd5b853561433281613df3565b9450602086013561434281613df3565b935060408601356001600160401b038082111561435e57600080fd5b61436a89838a01613fa9565b9450606088013591508082111561438057600080fd5b61438c89838a01613fa9565b935060808801359150808211156143a257600080fd5b506143af88828901614101565b9150509295509295909350565b6000806000606084860312156143d157600080fd5b83356001600160401b03808211156143e857600080fd5b6143f487838801613fa9565b9450602086013591508082111561440a57600080fd5b61441687838801613fa9565b9350604086013591508082111561442c57600080fd5b5061443986828701613fa9565b9150509250925092565b6000806040838503121561445657600080fd5b82356001600160401b038082111561446d57600080fd5b614050868387016141bb565b600081518084526020808501945080840160005b838110156144a95781518752958201959082019060010161448d565b509495945050505050565b6020815260006128ee6020830184614479565b6000806000606084860312156144dc57600080fd5b83356144e781613df3565b925060208401356001600160401b038082111561440a57600080fd5b6000806000806080858703121561451957600080fd5b843561452481613df3565b9350602085013592506040850135915060608501356001600160401b0381111561454d57600080fd5b6141af87828801614101565b6000806040838503121561456c57600080fd5b823561457781613df3565b915060208301358015158114613e2d57600080fd5b6000806000606084860312156145a157600080fd5b83356145ac81613df3565b95602085013595506040909401359392505050565b600080604083850312156145d457600080fd5b82356145df81613df3565b91506020830135613e2d81613df3565b600080600080600080600060e0888a03121561460a57600080fd5b8735965060208801356001600160401b038082111561462857600080fd5b6146348b838c01613fa9565b975060408a013591508082111561464a57600080fd5b6146568b838c01613fa9565b965060608a013591508082111561466c57600080fd5b6146788b838c01613fa9565b955060808a013591508082111561468e57600080fd5b61469a8b838c01613fa9565b945060a08a01359150808211156146b057600080fd5b6146bc8b838c01613fa9565b935060c08a01359150808211156146d257600080fd5b506146df8a828b01613fa9565b91505092959891949750929550565b600080600080600060a0868803121561470657600080fd5b853561471181613df3565b9450602086013561472181613df3565b9350604086013592506060860135915060808601356001600160401b0381111561474a57600080fd5b6143af88828901614101565b602080825260139082015272494e56414c49445f544f4b454e535f53495a4560681b604082015260600190565b634e487b7160e01b600052603260045260246000fd5b6020808252601290820152711513d2d15397d25117d393d517d1561254d560721b604082015260600190565b634e487b7160e01b600052601160045260246000fd5b60006000198214156147ef576147ef6147c5565b5060010190565b6040815260006148096040830185614479565b82810360208401526128b58185614479565b600181811c9082168061482f57607f821691505b6020821081141561485057634e487b7160e01b600052602260045260246000fd5b50919050565b6020808252600f908201526e10d3d395149050d517d4105554d151608a1b604082015260600190565b6040815260006148926040830185614479565b82810360208481019190915284518083528582019282019060005b818110156148d25784516001600160a01b0316835293830193918301916001016148ad565b5090979650505050505050565b600082198211156148f2576148f26147c5565b500190565b6000816000190483118215151615614911576149116147c5565b500290565b6060815260006149296060830186614479565b828103602084015261493b8186614479565b9050828103604084015261494f8185614479565b9695505050505050565b60208082526029908201527f455243313135353a2063616c6c6572206973206e6f74206f776e6572206e6f7260408201526808185c1c1c9bdd995960ba1b606082015260800190565b7f416363657373436f6e74726f6c3a206163636f756e74200000000000000000008152600083516149da816017850160208801614096565b7001034b99036b4b9b9b4b733903937b6329607d1b6017918401918201528351614a0b816028840160208801614096565b01602801949350505050565b60208082526028908201527f455243313135353a2069647320616e6420616d6f756e7473206c656e677468206040820152670dad2e6dac2e8c6d60c31b606082015260800190565b60208082526025908201527f455243313135353a207472616e7366657220746f20746865207a65726f206164604082015264647265737360d81b606082015260800190565b6020808252602a908201527f455243313135353a20696e73756666696369656e742062616c616e636520666f60408201526939103a3930b739b332b960b11b606082015260800190565b600081614afd57614afd6147c5565b506000190190565b6001600160a01b0386811682528516602082015260a060408201819052600090614b3190830186614479565b8281036060840152614b438186614479565b90508281036080840152614b5781856140c2565b98975050505050505050565b600060208284031215614b7557600080fd5b81516128ee81613e64565b600060033d11156136ba5760046000803e5060005160e01c90565b600060443d1015614ba95790565b6040516003193d81016004833e81513d6001600160401b038160248401118184111715614bd857505050505090565b8285019150815181811115614bf05750505050505090565b843d8701016020828501011115614c0a5750505050505090565b614c1960208286010187613ead565b509095945050505050565b60208082526028908201527f455243313135353a204552433131353552656365697665722072656a656374656040820152676420746f6b656e7360c01b606082015260800190565b600082821015614c7e57614c7e6147c5565b500390565b6001600160a01b03868116825285166020820152604081018490526060810183905260a060808201819052600090614cbd908301846140c2565b979650505050505050565b60208082526021908201527f455243313135353a206d696e7420746f20746865207a65726f206164647265736040820152607360f81b606082015260800190565b634e487b7160e01b600052602160045260246000fd5b60208082526023908201527f455243313135353a206275726e2066726f6d20746865207a65726f206164647260408201526265737360e81b606082015260800190565b60208082526024908201527f455243313135353a206275726e20616d6f756e7420657863656564732062616c604082015263616e636560e01b60608201526080019056fe97667070c54ef182b0f5858b034beac1b6f3089aa2d3188bb1e8929f4fa9b929a26469706673582212204472ea7035a7982c41c91a0c1fa6375d38c1d5f89e1f345cdbd3260bc39df60464736f6c63430008090033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000094e6f6d6164506173730000000000000000000000000000000000000000000000
-----Decoded View---------------
Arg [0] : newContractName (string): NomadPass
-----Encoded View---------------
3 Constructor Arguments found :
Arg [0] : 0000000000000000000000000000000000000000000000000000000000000020
Arg [1] : 0000000000000000000000000000000000000000000000000000000000000009
Arg [2] : 4e6f6d6164506173730000000000000000000000000000000000000000000000
Loading...
Loading
Loading...
Loading
[ 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.