ERC-1155
Overview
Max Total Supply
500
Holders
415
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 Name:
GenesisToken
Compiler Version
v0.8.9+commit.e5eed63a
Optimization Enabled:
Yes with 500 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT // Sources flattened with hardhat v2.8.3 https://hardhat.org // File @openzeppelin/contracts/utils/introspection/[email protected] 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); } // File @openzeppelin/contracts/token/ERC1155/[email protected] // OpenZeppelin Contracts v4.4.1 (token/ERC1155/IERC1155.sol) pragma solidity ^0.8.0; /** * @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; } // File @openzeppelin/contracts/token/ERC1155/[email protected] // OpenZeppelin Contracts v4.4.1 (token/ERC1155/IERC1155Receiver.sol) pragma solidity ^0.8.0; /** * @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); } // File @openzeppelin/contracts/token/ERC1155/extensions/[email protected] // OpenZeppelin Contracts v4.4.1 (token/ERC1155/extensions/IERC1155MetadataURI.sol) pragma solidity ^0.8.0; /** * @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); } // File @openzeppelin/contracts/utils/[email protected] // OpenZeppelin Contracts v4.4.1 (utils/Address.sol) 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); } } } } // File @openzeppelin/contracts/utils/[email protected] // OpenZeppelin Contracts v4.4.1 (utils/Context.sol) pragma solidity ^0.8.0; /** * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with meta-transactions the account sending and * paying for execution may not be the actual sender (as far as an application * is concerned). * * This contract is only required for intermediate, library-like contracts. */ abstract contract Context { function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } } // File @openzeppelin/contracts/utils/introspection/[email protected] // OpenZeppelin Contracts v4.4.1 (utils/introspection/ERC165.sol) pragma solidity ^0.8.0; /** * @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; } } // File @openzeppelin/contracts/token/ERC1155/[email protected] // OpenZeppelin Contracts v4.4.1 (token/ERC1155/ERC1155.sol) pragma solidity ^0.8.0; /** * @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 { _setApprovalForAll(_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 `to`. * * Emits a {TransferSingle} event. * * Requirements: * * - `to` cannot be the zero address. * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155Received} and return the * acceptance magic value. */ function _mint( address to, uint256 id, uint256 amount, bytes memory data ) internal virtual { require(to != address(0), "ERC1155: mint to the zero address"); address operator = _msgSender(); _beforeTokenTransfer(operator, address(0), to, _asSingletonArray(id), _asSingletonArray(amount), data); _balances[id][to] += amount; emit TransferSingle(operator, address(0), to, id, amount); _doSafeTransferAcceptanceCheck(operator, address(0), to, 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 `from` * * Requirements: * * - `from` cannot be the zero address. * - `from` must have at least `amount` tokens of token type `id`. */ function _burn( address from, uint256 id, uint256 amount ) internal virtual { require(from != address(0), "ERC1155: burn from the zero address"); address operator = _msgSender(); _beforeTokenTransfer(operator, from, address(0), _asSingletonArray(id), _asSingletonArray(amount), ""); uint256 fromBalance = _balances[id][from]; require(fromBalance >= amount, "ERC1155: burn amount exceeds balance"); unchecked { _balances[id][from] = fromBalance - amount; } emit TransferSingle(operator, from, 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 from, uint256[] memory ids, uint256[] memory amounts ) internal virtual { require(from != address(0), "ERC1155: burn from the zero address"); require(ids.length == amounts.length, "ERC1155: ids and amounts length mismatch"); address operator = _msgSender(); _beforeTokenTransfer(operator, from, address(0), ids, amounts, ""); 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: burn amount exceeds balance"); unchecked { _balances[id][from] = fromBalance - amount; } } emit TransferBatch(operator, from, address(0), ids, amounts); } /** * @dev Approve `operator` to operate on all of `owner` tokens * * Emits a {ApprovalForAll} event. */ function _setApprovalForAll( address owner, address operator, bool approved ) internal virtual { require(owner != operator, "ERC1155: setting approval status for self"); _operatorApprovals[owner][operator] = approved; emit ApprovalForAll(owner, operator, approved); } /** * @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; } } // File @openzeppelin/contracts/access/[email protected] // OpenZeppelin Contracts v4.4.1 (access/IAccessControl.sol) 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; } // File @openzeppelin/contracts/utils/[email protected] // OpenZeppelin Contracts v4.4.1 (utils/Strings.sol) pragma solidity ^0.8.0; /** * @dev String operations. */ library Strings { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { // Inspired by OraclizeAPI's implementation - MIT licence // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol if (value == 0) { return "0"; } uint256 temp = value; uint256 digits; while (temp != 0) { digits++; temp /= 10; } bytes memory buffer = new bytes(digits); while (value != 0) { digits -= 1; buffer[digits] = bytes1(uint8(48 + uint256(value % 10))); value /= 10; } return string(buffer); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */ function toHexString(uint256 value) internal pure returns (string memory) { if (value == 0) { return "0x00"; } uint256 temp = value; uint256 length = 0; while (temp != 0) { length++; temp >>= 8; } return toHexString(value, length); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. */ function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { bytes memory buffer = new bytes(2 * length + 2); buffer[0] = "0"; buffer[1] = "x"; for (uint256 i = 2 * length + 1; i > 1; --i) { buffer[i] = _HEX_SYMBOLS[value & 0xf]; value >>= 4; } require(value == 0, "Strings: hex length insufficient"); return string(buffer); } } // File @openzeppelin/contracts/access/[email protected] // OpenZeppelin Contracts v4.4.1 (access/AccessControl.sol) pragma solidity ^0.8.0; /** * @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 revoked `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}. * ==== * * NOTE: This function is deprecated in favor of {_grantRole}. */ 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); } /** * @dev Grants `role` to `account`. * * Internal function without access restriction. */ function _grantRole(bytes32 role, address account) internal virtual { if (!hasRole(role, account)) { _roles[role].members[account] = true; emit RoleGranted(role, account, _msgSender()); } } /** * @dev Revokes `role` from `account`. * * Internal function without access restriction. */ function _revokeRole(bytes32 role, address account) internal virtual { if (hasRole(role, account)) { _roles[role].members[account] = false; emit RoleRevoked(role, account, _msgSender()); } } } // File @openzeppelin/contracts/security/[email protected] // OpenZeppelin Contracts v4.4.1 (security/Pausable.sol) pragma solidity ^0.8.0; /** * @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()); } } // File @openzeppelin/contracts/token/ERC1155/extensions/[email protected] // OpenZeppelin Contracts v4.4.1 (token/ERC1155/extensions/ERC1155Burnable.sol) pragma solidity ^0.8.0; /** * @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); } } // File @openzeppelin/contracts/token/ERC1155/extensions/[email protected] // OpenZeppelin Contracts v4.4.1 (token/ERC1155/extensions/ERC1155Supply.sol) pragma solidity ^0.8.0; /** * @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 whether 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-_beforeTokenTransfer}. */ function _beforeTokenTransfer( address operator, address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) internal virtual override { super._beforeTokenTransfer(operator, from, to, ids, amounts, data); if (from == address(0)) { for (uint256 i = 0; i < ids.length; ++i) { _totalSupply[ids[i]] += amounts[i]; } } if (to == address(0)) { for (uint256 i = 0; i < ids.length; ++i) { _totalSupply[ids[i]] -= amounts[i]; } } } } // File @openzeppelin/contracts/utils/cryptography/[email protected] // OpenZeppelin Contracts v4.4.1 (utils/cryptography/ECDSA.sol) 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 Message, created from `s`. 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(bytes memory s) internal pure returns (bytes32) { return keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n", Strings.toString(s.length), s)); } /** * @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)); } } // File @openzeppelin/contracts/utils/cryptography/[email protected] // OpenZeppelin Contracts v4.4.1 (utils/cryptography/draft-EIP712.sol) pragma solidity ^0.8.0; /** * @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; address private immutable _CACHED_THIS; 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); _CACHED_THIS = address(this); _TYPE_HASH = typeHash; } /** * @dev Returns the domain separator for the current chain. */ function _domainSeparatorV4() internal view returns (bytes32) { if (address(this) == _CACHED_THIS && 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); } } // File @openzeppelin/contracts/utils/[email protected] // OpenZeppelin Contracts v4.4.1 (utils/Counters.sol) 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; } } // File hardhat/[email protected] 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)); } } // File contracts/GenesisTokenBackup.sol pragma solidity ^0.8.9; contract GenesisToken is ERC1155, AccessControl, Pausable, ERC1155Burnable, EIP712, ERC1155Supply { 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); constructor(string memory newContractName) ERC1155("") EIP712(newContractName, "1.0.0") { _grantRole(DEFAULT_ADMIN_ROLE, msg.sender); _grantRole(OPERATOR_ROLE, msg.sender); _grantRole(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; } function getBalance() public view returns(uint256){ return address(this).balance; } //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 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 _mint( address account, uint256 id, uint256 amount, bytes memory data ) internal override(ERC1155) { super._mint(account, id, amount, data); } function _beforeTokenTransfer(address operator, address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data) internal whenNotPaused override(ERC1155, ERC1155Supply) { super._beforeTokenTransfer(operator, from, to, ids, amounts, data); } function supportsInterface(bytes4 interfaceId) public view override(ERC1155, AccessControl) returns (bool) { return super.supportsInterface(interfaceId); } 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)); } function withdraw() external onlyRole(WITHDRAWER_ROLE) { uint256 balance = address(this).balance; require(balance > 0, "BALANCE_ZERO"); // solhint-disable-next-line (bool sent, ) = payable(msg.sender).call{value: balance}(""); require(sent, "WITHDRAW_FAILED"); } }
{ "optimizer": { "enabled": true, "runs": 500 }, "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":[],"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":[],"name":"getBalance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"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":[],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]
Contract Creation Code
6101406040523480156200001257600080fd5b5060405162005772380380620057728339810160408190526200003591620002f4565b80604051806040016040528060058152602001640312e302e360dc1b8152506040518060200160405280600081525062000075816200017b60201b60201c565b506004805460ff19169055815160209283012081519183019190912060e08290526101008190524660a0818152604080517f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f818801819052818301969096526060810194909452608080850193909352308483018190528151808603909301835260c094850190915281519190950120905291909152610120526200011c60003362000194565b620001487f97667070c54ef182b0f5858b034beac1b6f3089aa2d3188bb1e8929f4fa9b9293362000194565b620001747fe2f4eaae4a9751e85a3e4a7b9587827a877f29914755229b07a7b2da98285f703362000194565b506200040d565b80516200019090600290602084019062000238565b5050565b60008281526003602090815260408083206001600160a01b038516845290915290205460ff16620001905760008281526003602090815260408083206001600160a01b03851684529091529020805460ff19166001179055620001f43390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b8280546200024690620003d0565b90600052602060002090601f0160209004810192826200026a5760008555620002b5565b82601f106200028557805160ff1916838001178555620002b5565b82800160010185558215620002b5579182015b82811115620002b557825182559160200191906001019062000298565b50620002c3929150620002c7565b5090565b5b80821115620002c35760008155600101620002c8565b634e487b7160e01b600052604160045260246000fd5b600060208083850312156200030857600080fd5b82516001600160401b03808211156200032057600080fd5b818501915085601f8301126200033557600080fd5b8151818111156200034a576200034a620002de565b604051601f8201601f19908116603f01168101908382118183101715620003755762000375620002de565b8160405282815288868487010111156200038e57600080fd5b600093505b82841015620003b2578484018601518185018701529285019262000393565b82841115620003c45760008684830101525b98975050505050505050565b600181811c90821680620003e557607f821691505b602082108114156200040757634e487b7160e01b600052602260045260246000fd5b50919050565b60805160a05160c05160e05161010051610120516153156200045d600039600061411701526000614166015260006141410152600061409a015260006140c4015260006140ee01526153156000f3fe6080604052600436106103285760003560e01c806375321c4a116101a5578063ba32e67e116100ec578063e7c8d22d11610095578063ed8a4a851161006f578063ed8a4a8514610983578063f242432a146109a3578063f5298aca146109c3578063f5b541a6146109e357600080fd5b8063e7c8d22d14610905578063e8a3d48514610925578063e985e9c51461093a57600080fd5b8063d547741f116100c6578063d547741f146108a5578063df7b7428146108c5578063e7572230146108e557600080fd5b8063ba32e67e14610838578063bd85b03914610858578063d05eaae01461088557600080fd5b8063938e3d7b1161014e578063a22cb46511610128578063a22cb465146107d8578063b67797d6146107f8578063b72b3bfe1461081857600080fd5b8063938e3d7b1461076f578063a1ebf35d1461078f578063a217fddf146107c357600080fd5b806385f438c11161017f57806385f438c1146106e05780638ada066e1461071457806391d148541461072957600080fd5b806375321c4a146106735780637bb68928146106935780638456cb59146106cb57600080fd5b80632eb2c2d6116102745780634e1273f41161021d5780636372f6fe116101f75780636372f6fe146105f357806363f0bfce146106135780636b20c45414610633578063731133e91461065357600080fd5b80634e1273f41461057f5780634f558e79146105ac5780635c975abb146105db57600080fd5b80633ccfd60b1161024e5780633ccfd60b146105355780633f4ba83a1461054a578063448db6961461055f57600080fd5b80632eb2c2d6146104d55780632f2ff15d146104f557806336568abe1461051557600080fd5b806313caf551116102d6578063248a9ca3116102b0578063248a9ca31461047257806327dafe5b146104a25780632c3e9d9d146104c257600080fd5b806313caf551146104125780631ed2b37e146104325780631f7fdffa1461045257600080fd5b806303ceb77f1161030757806303ceb77f146103b25780630e89341c146103d257806312065fe0146103ff57600080fd5b8062fdd58e1461032d57806301ffc9a71461036057806302fe530514610390575b600080fd5b34801561033957600080fd5b5061034d6103483660046145cc565b610a05565b6040519081526020015b60405180910390f35b34801561036c57600080fd5b5061038061037b36600461460c565b610a9c565b6040519015158152602001610357565b34801561039c57600080fd5b506103b06103ab3660046146ca565b610aad565b005b3480156103be57600080fd5b506103b06103cd3660046147b0565b610b0a565b3480156103de57600080fd5b506103f26103ed366004614814565b610d0c565b6040516103579190614885565b34801561040b57600080fd5b504761034d565b34801561041e57600080fd5b5061034d61042d366004614814565b610da0565b34801561043e57600080fd5b506103b061044d3660046147b0565b610dfb565b34801561045e57600080fd5b506103b061046d3660046148b8565b610f99565b34801561047e57600080fd5b5061034d61048d366004614814565b60009081526003602052604090206001015490565b3480156104ae57600080fd5b506103b06104bd3660046149be565b61100a565b6103b06104d0366004614a18565b6111c8565b3480156104e157600080fd5b506103b06104f0366004614aa5565b61162d565b34801561050157600080fd5b506103b0610510366004614b4f565b6116c8565b34801561052157600080fd5b506103b0610530366004614b4f565b6116f3565b34801561054157600080fd5b506103b061177f565b34801561055657600080fd5b506103b061187f565b34801561056b57600080fd5b506103b061057a366004614b7b565b6118a3565b34801561058b57600080fd5b5061059f61059a366004614c03565b611b1f565b6040516103579190614c75565b3480156105b857600080fd5b506103806105c7366004614814565b600090815260056020526040902054151590565b3480156105e757600080fd5b5060045460ff16610380565b3480156105ff57600080fd5b5061034d61060e366004614814565b611c49565b34801561061f57600080fd5b506103b061062e366004614814565b611ca4565b34801561063f57600080fd5b506103b061064e366004614c88565b611cdc565b34801561065f57600080fd5b506103b061066e366004614cc3565b611d61565b34801561067f57600080fd5b5061034d61068e366004614814565b611e8e565b34801561069f57600080fd5b506106b36106ae366004614814565b611ee9565b6040516001600160a01b039091168152602001610357565b3480156106d757600080fd5b506103b0611f4d565b3480156106ec57600080fd5b5061034d7f10dac8c06a04bec0b551627dad28bc00d6516b0caacd1c7b345fcdb5211334e481565b34801561072057600080fd5b5061034d611f6e565b34801561073557600080fd5b50610380610744366004614b4f565b60009182526003602090815260408084206001600160a01b0393909316845291905290205460ff1690565b34801561077b57600080fd5b506103b061078a3660046146ca565b611f7e565b34801561079b57600080fd5b5061034d7fe2f4eaae4a9751e85a3e4a7b9587827a877f29914755229b07a7b2da98285f7081565b3480156107cf57600080fd5b5061034d600081565b3480156107e457600080fd5b506103b06107f3366004614d18565b611faa565b34801561080457600080fd5b506103b0610813366004614814565b611fb5565b34801561082457600080fd5b506103b06108333660046147b0565b611ffe565b34801561084457600080fd5b506103b0610853366004614814565b61219c565b34801561086457600080fd5b5061034d610873366004614814565b60009081526005602052604090205490565b34801561089157600080fd5b506103b06108a03660046147b0565b6121fe565b3480156108b157600080fd5b506103b06108c0366004614b4f565b612392565b3480156108d157600080fd5b5061034d6108e0366004614814565b6123b8565b3480156108f157600080fd5b5061034d610900366004614814565b612410565b34801561091157600080fd5b5061034d610920366004614814565b61246b565b34801561093157600080fd5b506103f26124c6565b34801561094657600080fd5b50610380610955366004614d54565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205460ff1690565b34801561098f57600080fd5b506103b061099e366004614d7e565b612558565b3480156109af57600080fd5b506103b06109be366004614e7e565b612970565b3480156109cf57600080fd5b506103b06109de366004614ee3565b6129f7565b3480156109ef57600080fd5b5061034d6000805160206152c083398151915281565b60006001600160a01b038316610a765760405162461bcd60e51b815260206004820152602b60248201527f455243313135353a2062616c616e636520717565727920666f7220746865207a60448201526a65726f206164647265737360a81b60648201526084015b60405180910390fd5b506000908152602081815260408083206001600160a01b03949094168352929052205490565b6000610aa782612a7c565b92915050565b6000805160206152c0833981519152610ac68133612aa1565b610acf82612b21565b7fb1bf12e17db588c31e8fb2afdd2b3bc1ed822d68c560856fcbc75ae303fc5d1482604051610afe9190614885565b60405180910390a15050565b6000805160206152c0833981519152610b238133612aa1565b6000835111610b6a5760405162461bcd60e51b8152602060048201526013602482015272494e56414c49445f544f4b454e535f53495a4560681b6044820152606401610a6d565b8251825114610bbb5760405162461bcd60e51b815260206004820152601660248201527f494e56414c49445f4d41585f4954454d535f53495a45000000000000000000006044820152606401610a6d565b60005b8351811015610ccd576000838281518110610bdb57610bdb614f16565b602002602001015111610c235760405162461bcd60e51b815260206004820152601060248201526f494e56414c49445f4d41585f4954454d60801b6044820152606401610a6d565b600060076000868481518110610c3b57610c3b614f16565b6020026020010151815260200190815260200160002090506000816000015411610c9c5760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b838281518110610cae57610cae614f16565b6020908102919091010151905580610cc581614f42565b915050610bbe565b507f4402caae79d7b040a75c7d72c65fdd1be0cbe28590584456f0cbb49f2346f4e88383604051610cff929190614f5d565b60405180910390a1505050565b606060028054610d1b90614f82565b80601f0160208091040260200160405190810160405280929190818152602001828054610d4790614f82565b8015610d945780601f10610d6957610100808354040283529160200191610d94565b820191906000526020600020905b815481529060010190602001808311610d7757829003601f168201915b50505050509050919050565b60008181526007602052604081208054610df15760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b6005015492915050565b6000805160206152c0833981519152610e148133612aa1565b6000835111610e5b5760405162461bcd60e51b8152602060048201526013602482015272494e56414c49445f544f4b454e535f53495a4560681b6044820152606401610a6d565b8251825114610eac5760405162461bcd60e51b815260206004820152601760248201527f494e56414c49445f4d41585f57414c4c45545f53495a450000000000000000006044820152606401610a6d565b60005b8351811015610f6757600060076000868481518110610ed057610ed0614f16565b6020026020010151815260200190815260200160002090506000816000015411610f315760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b838281518110610f4357610f43614f16565b60200260200101518160010181905550508080610f5f90614f42565b915050610eaf565b507fb355828fc1c77f59b3e0f1ce2ade5407d2fac2a198475714987654ab2647c7ec8383604051610cff929190614f5d565b6000805160206152c0833981519152610fb28133612aa1565b60045460ff1615610ff75760405162461bcd60e51b815260206004820152600f60248201526e10d3d395149050d517d4105554d151608a1b6044820152606401610a6d565b61100385858585612b34565b5050505050565b6000805160206152c08339815191526110238133612aa1565b600083511161106a5760405162461bcd60e51b8152602060048201526013602482015272494e56414c49445f544f4b454e535f53495a4560681b6044820152606401610a6d565b82518251146110bb5760405162461bcd60e51b815260206004820152601d60248201527f494e56414c49445f52454445454d5f434f4e5452414354535f53495a450000006044820152606401610a6d565b60005b8351811015611196576000600760008684815181106110df576110df614f16565b60200260200101518152602001908152602001600020905060008160000154116111405760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b83828151811061115257611152614f16565b60200260200101518160060160006101000a8154816001600160a01b0302191690836001600160a01b0316021790555050808061118e90614f42565b9150506110be565b507f7bd6be6cbe8904036ddacfaa6886ec26d27b698db8de720a6993590b58d971aa8383604051610cff929190614fbd565b60045460ff161561120d5760405162461bcd60e51b815260206004820152600f60248201526e10d3d395149050d517d4105554d151608a1b6044820152606401610a6d565b6000858152600760205260409020805461125e5760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b600061126c33888888612d09565b90506112ae8185858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250612d8792505050565b6112fa5760405162461bcd60e51b815260206004820152601160248201527f494e56414c49445f5349474e41545552450000000000000000000000000000006044820152606401610a6d565b6000818152600860205260409020546001600160a01b03161561135f5760405162461bcd60e51b815260206004820152601660248201527f544f4b454e5f414c52454144595f52454445454d4544000000000000000000006044820152606401610a6d565b81600401544210156113b35760405162461bcd60e51b815260206004820152601160248201527f494e56414c49445f4f50454e5f444154450000000000000000000000000000006044820152606401610a6d565b81600501544211156114075760405162461bcd60e51b815260206004820152601260248201527f494e56414c49445f434c4f53455f4441544500000000000000000000000000006044820152606401610a6d565b6002820154156114655781600201548611156114655760405162461bcd60e51b815260206004820152601b60248201527f494e56414c49445f4d41585f5045525f5452414e53414354494f4e00000000006044820152606401610a6d565b6001820154156114dd57600061147b3389610a05565b600184015490915061148d888361501d565b11156114db5760405162461bcd60e51b815260206004820152601660248201527f494e56414c49445f4d41585f5045525f57414c4c4554000000000000000000006044820152606401610a6d565b505b600382015415611546578582600301546114f79190615035565b3410156115465760405162461bcd60e51b815260206004820152601160248201527f56414c55455f42454c4f575f50524943450000000000000000000000000000006044820152606401610a6d565b815460008881526005602052604090205461156290889061501d565b11156115b05760405162461bcd60e51b815260206004820152601960248201527f50555243484153455f4558434545445f4d41585f4954454d53000000000000006044820152606401610a6d565b6115cb33888860405180602001604052806000815250612dbe565b60008181526008602090815260409182902080546001600160a01b031916339081179091558251848152918201527f2310322c3f4ed401acfe8d97231f0f8ad43265f9da74d91004b8f625d0e2962a910160405180910390a150505050505050565b6001600160a01b03851633148061164957506116498533610955565b6116bb5760405162461bcd60e51b815260206004820152603260248201527f455243313135353a207472616e736665722063616c6c6572206973206e6f742060448201527f6f776e6572206e6f7220617070726f76656400000000000000000000000000006064820152608401610a6d565b6110038585858585612dd0565b6000828152600360205260409020600101546116e48133612aa1565b6116ee8383613034565b505050565b6001600160a01b03811633146117715760405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201527f20726f6c657320666f722073656c6600000000000000000000000000000000006064820152608401610a6d565b61177b82826130d6565b5050565b7f10dac8c06a04bec0b551627dad28bc00d6516b0caacd1c7b345fcdb5211334e46117aa8133612aa1565b47806117e75760405162461bcd60e51b815260206004820152600c60248201526b42414c414e43455f5a45524f60a01b6044820152606401610a6d565b604051600090339083908381818185875af1925050503d8060008114611829576040519150601f19603f3d011682016040523d82523d6000602084013e61182e565b606091505b50509050806116ee5760405162461bcd60e51b815260206004820152600f60248201527f57495448445241575f4641494c454400000000000000000000000000000000006044820152606401610a6d565b6000805160206152c08339815191526118988133612aa1565b6118a0613159565b50565b6000805160206152c08339815191526118bc8133612aa1565b60008451116119035760405162461bcd60e51b8152602060048201526013602482015272494e56414c49445f544f4b454e535f53495a4560681b6044820152606401610a6d565b83518351146119485760405162461bcd60e51b8152602060048201526011602482015270494e56414c49445f4f50454e5f53495a4560781b6044820152606401610a6d565b835182511461198e5760405162461bcd60e51b8152602060048201526012602482015271494e56414c49445f434c4f53455f53495a4560701b6044820152606401610a6d565b60005b8451811015611add578281815181106119ac576119ac614f16565b60200260200101518482815181106119c6576119c6614f16565b60200260200101511115611a0c5760405162461bcd60e51b815260206004820152600d60248201526c494e56414c49445f444154455360981b6044820152606401610a6d565b600060076000878481518110611a2457611a24614f16565b6020026020010151815260200190815260200160002090506000816000015411611a855760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b848281518110611a9757611a97614f16565b60200260200101518160040181905550838281518110611ab957611ab9614f16565b60200260200101518160050181905550508080611ad590614f42565b915050611991565b507f396df38625537eac114c72dc57288ba26ee0169e7dd3889e273e40c3f0ab40cf848484604051611b1193929190615054565b60405180910390a150505050565b60608151835114611b845760405162461bcd60e51b815260206004820152602960248201527f455243313135353a206163636f756e747320616e6420696473206c656e677468604482015268040dad2e6dac2e8c6d60bb1b6064820152608401610a6d565b6000835167ffffffffffffffff811115611ba057611ba0614629565b604051908082528060200260200182016040528015611bc9578160200160208202803683370190505b50905060005b8451811015611c4157611c14858281518110611bed57611bed614f16565b6020026020010151858381518110611c0757611c07614f16565b6020026020010151610a05565b828281518110611c2657611c26614f16565b6020908102919091010152611c3a81614f42565b9050611bcf565b509392505050565b60008181526007602052604081208054611c9a5760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b6002015492915050565b6000805160206152c0833981519152611cbd8133612aa1565b50600090815260086020526040902080546001600160a01b0319169055565b6001600160a01b038316331480611cf85750611cf88333610955565b611d565760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2063616c6c6572206973206e6f74206f776e6572206e6f7260448201526808185c1c1c9bdd995960ba1b6064820152608401610a6d565b6116ee8383836131f5565b6000805160206152c0833981519152611d7a8133612aa1565b60045460ff1615611dbf5760405162461bcd60e51b815260206004820152600f60248201526e10d3d395149050d517d4105554d151608a1b6044820152606401610a6d565b60008481526007602052604090208054611e105760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b8054600086815260056020526040902054611e2c90869061501d565b1115611e7a5760405162461bcd60e51b815260206004820152601960248201527f50555243484153455f4558434545445f4d41585f4954454d53000000000000006044820152606401610a6d565b611e8686868686612dbe565b505050505050565b60008181526007602052604081208054611edf5760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b6004015492915050565b60008181526007602052604081208054611f3a5760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b600601546001600160a01b031692915050565b6000805160206152c0833981519152611f668133612aa1565b6118a061343c565b6000611f7960065490565b905090565b6000805160206152c0833981519152611f978133612aa1565b81516116ee906009906020850190614517565b61177b3383836134b7565b6000805160206152c0833981519152611fce8133612aa1565b600060065560005b828110156116ee57611fec600680546001019055565b80611ff681614f42565b915050611fd6565b6000805160206152c08339815191526120178133612aa1565b600083511161205e5760405162461bcd60e51b8152602060048201526013602482015272494e56414c49445f544f4b454e535f53495a4560681b6044820152606401610a6d565b82518251146120af5760405162461bcd60e51b815260206004820152601c60248201527f494e56414c49445f4d41585f5452414e53414354494f4e5f53495a45000000006044820152606401610a6d565b60005b835181101561216a576000600760008684815181106120d3576120d3614f16565b60200260200101518152602001908152602001600020905060008160000154116121345760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b83828151811061214657612146614f16565b6020026020010151816002018190555050808061216290614f42565b9150506120b2565b507f7e144fd6b36fcdb9448b08cb1dd907f43c49241caa48f7ee7eb69932074230268383604051610cff929190614f5d565b6000805160206152c08339815191526121b58133612aa1565b50600090815260076020526040812081815560018101829055600281018290556003810182905560048101829055600581019190915560060180546001600160a01b0319169055565b6000805160206152c08339815191526122178133612aa1565b600083511161225e5760405162461bcd60e51b8152602060048201526013602482015272494e56414c49445f544f4b454e535f53495a4560681b6044820152606401610a6d565b82518251146122a55760405162461bcd60e51b8152602060048201526013602482015272494e56414c49445f5052494345535f53495a4560681b6044820152606401610a6d565b60005b8351811015612360576000600760008684815181106122c9576122c9614f16565b602002602001015181526020019081526020016000209050600081600001541161232a5760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b83828151811061233c5761233c614f16565b6020026020010151816003018190555050808061235890614f42565b9150506122a8565b507fbe192de9462d6c5663b4a1ca8035d8bb4c41a613f8842b02c1941bf1b52b10378383604051610cff929190614f5d565b6000828152600360205260409020600101546123ae8133612aa1565b6116ee83836130d6565b600081815260076020526040812080546124095760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b5492915050565b600081815260076020526040812080546124615760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b6003015492915050565b600081815260076020526040812080546124bc5760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b6001015492915050565b6060600980546124d590614f82565b80601f016020809104026020016040519081016040528092919081815260200182805461250190614f82565b801561254e5780601f106125235761010080835404028352916020019161254e565b820191906000526020600020905b81548152906001019060200180831161253157829003601f168201915b5050505050905090565b6000805160206152c08339815191526125718133612aa1565b600088116125c15760405162461bcd60e51b815260206004820152601560248201527f494e56414c49445f4e554d4245525f544f4b454e5300000000000000000000006044820152606401610a6d565b878751146126115760405162461bcd60e51b815260206004820152601660248201527f494e56414c49445f4d41585f4954454d535f53495a45000000000000000000006044820152606401610a6d565b878651146126615760405162461bcd60e51b815260206004820152601760248201527f494e56414c49445f4d41585f57414c4c45545f53495a450000000000000000006044820152606401610a6d565b878551146126b15760405162461bcd60e51b815260206004820152601c60248201527f494e56414c49445f4d41585f5452414e53414354494f4e5f53495a45000000006044820152606401610a6d565b878451146126f75760405162461bcd60e51b8152602060048201526013602482015272494e56414c49445f5052494345535f53495a4560681b6044820152606401610a6d565b8783511461273b5760405162461bcd60e51b8152602060048201526011602482015270494e56414c49445f4f50454e5f53495a4560781b6044820152606401610a6d565b878251146127805760405162461bcd60e51b8152602060048201526012602482015271494e56414c49445f434c4f53455f53495a4560701b6044820152606401610a6d565b60005b8881101561296557600088828151811061279f5761279f614f16565b6020026020010151116127e75760405162461bcd60e51b815260206004820152601060248201526f494e56414c49445f4d41585f4954454d60801b6044820152606401610a6d565b8281815181106127f9576127f9614f16565b602002602001015184828151811061281357612813614f16565b602002602001015111156128595760405162461bcd60e51b815260206004820152600d60248201526c494e56414c49445f444154455360981b6044820152606401610a6d565b60006007600061286860065490565b8152602001908152602001600020905088828151811061288a5761288a614f16565b602002602001015181600001819055508682815181106128ac576128ac614f16565b602002602001015181600201819055508782815181106128ce576128ce614f16565b602002602001015181600101819055508582815181106128f0576128f0614f16565b6020026020010151816003018190555084828151811061291257612912614f16565b6020026020010151816004018190555083828151811061293457612934614f16565b60200260200101518160050181905550612952600680546001019055565b508061295d81614f42565b915050612783565b505050505050505050565b6001600160a01b03851633148061298c575061298c8533610955565b6129ea5760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2063616c6c6572206973206e6f74206f776e6572206e6f7260448201526808185c1c1c9bdd995960ba1b6064820152608401610a6d565b6110038585858585613598565b6001600160a01b038316331480612a135750612a138333610955565b612a715760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2063616c6c6572206973206e6f74206f776e6572206e6f7260448201526808185c1c1c9bdd995960ba1b6064820152608401610a6d565b6116ee838383613745565b60006001600160e01b03198216637965db0b60e01b1480610aa75750610aa7826138be565b60008281526003602090815260408083206001600160a01b038516845290915290205460ff1661177b57612adf816001600160a01b0316601461390e565b612aea83602061390e565b604051602001612afb929190615097565b60408051601f198184030181529082905262461bcd60e51b8252610a6d91600401614885565b805161177b906002906020840190614517565b6001600160a01b038416612b945760405162461bcd60e51b815260206004820152602160248201527f455243313135353a206d696e7420746f20746865207a65726f206164647265736044820152607360f81b6064820152608401610a6d565b8151835114612bf65760405162461bcd60e51b815260206004820152602860248201527f455243313135353a2069647320616e6420616d6f756e7473206c656e677468206044820152670dad2e6dac2e8c6d60c31b6064820152608401610a6d565b33612c0681600087878787613ab7565b60005b8451811015612ca157838181518110612c2457612c24614f16565b6020026020010151600080878481518110612c4157612c41614f16565b602002602001015181526020019081526020016000206000886001600160a01b03166001600160a01b031681526020019081526020016000206000828254612c89919061501d565b90915550819050612c9981614f42565b915050612c09565b50846001600160a01b031660006001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8787604051612cf2929190614f5d565b60405180910390a461100381600087878787613b0b565b604080517f6c614e0727fa7406d276937059675ea43b8e8586c92a0aebc9ecfd2dc187237660208201526001600160a01b03861691810191909152606081018490526080810183905260a08101829052600090612d7e9060c00160405160208183030381529060405280519060200120613cc0565b95945050505050565b6000612db77fe2f4eaae4a9751e85a3e4a7b9587827a877f29914755229b07a7b2da98285f706107448585613d0e565b9392505050565b612dca84848484613d2a565b50505050565b8151835114612e325760405162461bcd60e51b815260206004820152602860248201527f455243313135353a2069647320616e6420616d6f756e7473206c656e677468206044820152670dad2e6dac2e8c6d60c31b6064820152608401610a6d565b6001600160a01b038416612e965760405162461bcd60e51b815260206004820152602560248201527f455243313135353a207472616e7366657220746f20746865207a65726f206164604482015264647265737360d81b6064820152608401610a6d565b33612ea5818787878787613ab7565b60005b8451811015612fce576000858281518110612ec557612ec5614f16565b602002602001015190506000858381518110612ee357612ee3614f16565b602090810291909101810151600084815280835260408082206001600160a01b038e168352909352919091205490915081811015612f765760405162461bcd60e51b815260206004820152602a60248201527f455243313135353a20696e73756666696369656e742062616c616e636520666f60448201526939103a3930b739b332b960b11b6064820152608401610a6d565b6000838152602081815260408083206001600160a01b038e8116855292528083208585039055908b16825281208054849290612fb390849061501d565b9250508190555050505080612fc790614f42565b9050612ea8565b50846001600160a01b0316866001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb878760405161301e929190614f5d565b60405180910390a4611e86818787878787613b0b565b60008281526003602090815260408083206001600160a01b038516845290915290205460ff1661177b5760008281526003602090815260408083206001600160a01b03851684529091529020805460ff191660011790556130923390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b60008281526003602090815260408083206001600160a01b038516845290915290205460ff161561177b5760008281526003602090815260408083206001600160a01b0385168085529252808320805460ff1916905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b60045460ff166131ab5760405162461bcd60e51b815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610a6d565b6004805460ff191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b6040516001600160a01b03909116815260200160405180910390a1565b6001600160a01b0383166132575760405162461bcd60e51b815260206004820152602360248201527f455243313135353a206275726e2066726f6d20746865207a65726f206164647260448201526265737360e81b6064820152608401610a6d565b80518251146132b95760405162461bcd60e51b815260206004820152602860248201527f455243313135353a2069647320616e6420616d6f756e7473206c656e677468206044820152670dad2e6dac2e8c6d60c31b6064820152608401610a6d565b60003390506132dc81856000868660405180602001604052806000815250613ab7565b60005b83518110156133dd5760008482815181106132fc576132fc614f16565b60200260200101519050600084838151811061331a5761331a614f16565b602090810291909101810151600084815280835260408082206001600160a01b038c1683529093529190912054909150818110156133a65760405162461bcd60e51b8152602060048201526024808201527f455243313135353a206275726e20616d6f756e7420657863656564732062616c604482015263616e636560e01b6064820152608401610a6d565b6000928352602083815260408085206001600160a01b038b16865290915290922091039055806133d581614f42565b9150506132df565b5060006001600160a01b0316846001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb868660405161342e929190614f5d565b60405180910390a450505050565b60045460ff16156134825760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b6044820152606401610a6d565b6004805460ff191660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586131d83390565b816001600160a01b0316836001600160a01b0316141561352b5760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2073657474696e6720617070726f76616c20737461747573604482015268103337b91039b2b63360b91b6064820152608401610a6d565b6001600160a01b03838116600081815260016020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6001600160a01b0384166135fc5760405162461bcd60e51b815260206004820152602560248201527f455243313135353a207472616e7366657220746f20746865207a65726f206164604482015264647265737360d81b6064820152608401610a6d565b3361361b81878761360c88613e2b565b61361588613e2b565b87613ab7565b6000848152602081815260408083206001600160a01b038a1684529091529020548381101561369f5760405162461bcd60e51b815260206004820152602a60248201527f455243313135353a20696e73756666696369656e742062616c616e636520666f60448201526939103a3930b739b332b960b11b6064820152608401610a6d565b6000858152602081815260408083206001600160a01b038b81168552925280832087850390559088168252812080548692906136dc90849061501d565b909155505060408051868152602081018690526001600160a01b03808916928a821692918616917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a461373c828888888888613e76565b50505050505050565b6001600160a01b0383166137a75760405162461bcd60e51b815260206004820152602360248201527f455243313135353a206275726e2066726f6d20746865207a65726f206164647260448201526265737360e81b6064820152608401610a6d565b336137d6818560006137b887613e2b565b6137c187613e2b565b60405180602001604052806000815250613ab7565b6000838152602081815260408083206001600160a01b0388168452909152902054828110156138535760405162461bcd60e51b8152602060048201526024808201527f455243313135353a206275726e20616d6f756e7420657863656564732062616c604482015263616e636560e01b6064820152608401610a6d565b6000848152602081815260408083206001600160a01b03898116808652918452828520888703905582518981529384018890529092908616917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a45050505050565b60006001600160e01b03198216636cdb3d1360e11b14806138ef57506001600160e01b031982166303a24d0760e21b145b80610aa757506301ffc9a760e01b6001600160e01b0319831614610aa7565b6060600061391d836002615035565b61392890600261501d565b67ffffffffffffffff81111561394057613940614629565b6040519080825280601f01601f19166020018201604052801561396a576020820181803683370190505b509050600360fc1b8160008151811061398557613985614f16565b60200101906001600160f81b031916908160001a905350600f60fb1b816001815181106139b4576139b4614f16565b60200101906001600160f81b031916908160001a90535060006139d8846002615035565b6139e390600161501d565b90505b6001811115613a68577f303132333435363738396162636465660000000000000000000000000000000085600f1660108110613a2457613a24614f16565b1a60f81b828281518110613a3a57613a3a614f16565b60200101906001600160f81b031916908160001a90535060049490941c93613a6181615118565b90506139e6565b508315612db75760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401610a6d565b60045460ff1615613afd5760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b6044820152606401610a6d565b611e86868686868686613f81565b6001600160a01b0384163b15611e865760405163bc197c8160e01b81526001600160a01b0385169063bc197c8190613b4f908990899088908890889060040161512f565b602060405180830381600087803b158015613b6957600080fd5b505af1925050508015613b99575060408051601f3d908101601f19168201909252613b969181019061518d565b60015b613c4f57613ba56151aa565b806308c379a01415613bdf5750613bba6151c5565b80613bc55750613be1565b8060405162461bcd60e51b8152600401610a6d9190614885565b505b60405162461bcd60e51b815260206004820152603460248201527f455243313135353a207472616e7366657220746f206e6f6e204552433131353560448201527f526563656976657220696d706c656d656e7465720000000000000000000000006064820152608401610a6d565b6001600160e01b0319811663bc197c8160e01b1461373c5760405162461bcd60e51b815260206004820152602860248201527f455243313135353a204552433131353552656365697665722072656a656374656044820152676420746f6b656e7360c01b6064820152608401610a6d565b6000610aa7613ccd61408d565b8360405161190160f01b6020820152602281018390526042810182905260009060620160405160208183030381529060405280519060200120905092915050565b6000806000613d1d85856141b7565b91509150611c4181614227565b6001600160a01b038416613d8a5760405162461bcd60e51b815260206004820152602160248201527f455243313135353a206d696e7420746f20746865207a65726f206164647265736044820152607360f81b6064820152608401610a6d565b33613d9b8160008761360c88613e2b565b6000848152602081815260408083206001600160a01b038916845290915281208054859290613dcb90849061501d565b909155505060408051858152602081018590526001600160a01b0380881692600092918516917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a461100381600087878787613e76565b60408051600180825281830190925260609160009190602080830190803683370190505090508281600081518110613e6557613e65614f16565b602090810291909101015292915050565b6001600160a01b0384163b15611e865760405163f23a6e6160e01b81526001600160a01b0385169063f23a6e6190613eba908990899088908890889060040161524f565b602060405180830381600087803b158015613ed457600080fd5b505af1925050508015613f04575060408051601f3d908101601f19168201909252613f019181019061518d565b60015b613f1057613ba56151aa565b6001600160e01b0319811663f23a6e6160e01b1461373c5760405162461bcd60e51b815260206004820152602860248201527f455243313135353a204552433131353552656365697665722072656a656374656044820152676420746f6b656e7360c01b6064820152608401610a6d565b6001600160a01b0385166140085760005b835181101561400657828181518110613fad57613fad614f16565b602002602001015160056000868481518110613fcb57613fcb614f16565b602002602001015181526020019081526020016000206000828254613ff0919061501d565b90915550613fff905081614f42565b9050613f92565b505b6001600160a01b038416611e865760005b835181101561373c5782818151811061403457614034614f16565b60200260200101516005600086848151811061405257614052614f16565b6020026020010151815260200190815260200160002060008282546140779190615292565b90915550614086905081614f42565b9050614019565b6000306001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000161480156140e657507f000000000000000000000000000000000000000000000000000000000000000046145b1561411057507f000000000000000000000000000000000000000000000000000000000000000090565b50604080517f00000000000000000000000000000000000000000000000000000000000000006020808301919091527f0000000000000000000000000000000000000000000000000000000000000000828401527f000000000000000000000000000000000000000000000000000000000000000060608301524660808301523060a0808401919091528351808403909101815260c0909201909252805191012090565b90565b6000808251604114156141ee5760208301516040840151606085015160001a6141e2878285856143e2565b94509450505050614220565b825160401415614218576020830151604084015161420d8683836144cf565b935093505050614220565b506000905060025b9250929050565b600081600481111561423b5761423b6152a9565b14156142445750565b6001816004811115614258576142586152a9565b14156142a65760405162461bcd60e51b815260206004820152601860248201527f45434453413a20696e76616c6964207369676e617475726500000000000000006044820152606401610a6d565b60028160048111156142ba576142ba6152a9565b14156143085760405162461bcd60e51b815260206004820152601f60248201527f45434453413a20696e76616c6964207369676e6174757265206c656e677468006044820152606401610a6d565b600381600481111561431c5761431c6152a9565b14156143755760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202773272076616c604482015261756560f01b6064820152608401610a6d565b6004816004811115614389576143896152a9565b14156118a05760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202776272076616c604482015261756560f01b6064820152608401610a6d565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a083111561441957506000905060036144c6565b8460ff16601b1415801561443157508460ff16601c14155b1561444257506000905060046144c6565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa158015614496573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381166144bf576000600192509250506144c6565b9150600090505b94509492505050565b6000807f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff831660ff84901c601b01614509878288856143e2565b935093505050935093915050565b82805461452390614f82565b90600052602060002090601f016020900481019282614545576000855561458b565b82601f1061455e57805160ff191683800117855561458b565b8280016001018555821561458b579182015b8281111561458b578251825591602001919060010190614570565b5061459792915061459b565b5090565b5b80821115614597576000815560010161459c565b80356001600160a01b03811681146145c757600080fd5b919050565b600080604083850312156145df57600080fd5b6145e8836145b0565b946020939093013593505050565b6001600160e01b0319811681146118a057600080fd5b60006020828403121561461e57600080fd5b8135612db7816145f6565b634e487b7160e01b600052604160045260246000fd5b601f8201601f1916810167ffffffffffffffff8111828210171561466557614665614629565b6040525050565b600067ffffffffffffffff83111561468657614686614629565b60405161469d601f8501601f19166020018261463f565b8091508381528484840111156146b257600080fd5b83836020830137600060208583010152509392505050565b6000602082840312156146dc57600080fd5b813567ffffffffffffffff8111156146f357600080fd5b8201601f8101841361470457600080fd5b6147138482356020840161466c565b949350505050565b600067ffffffffffffffff82111561473557614735614629565b5060051b60200190565b600082601f83011261475057600080fd5b8135602061475d8261471b565b60405161476a828261463f565b83815260059390931b850182019282810191508684111561478a57600080fd5b8286015b848110156147a5578035835291830191830161478e565b509695505050505050565b600080604083850312156147c357600080fd5b823567ffffffffffffffff808211156147db57600080fd5b6147e78683870161473f565b935060208501359150808211156147fd57600080fd5b5061480a8582860161473f565b9150509250929050565b60006020828403121561482657600080fd5b5035919050565b60005b83811015614848578181015183820152602001614830565b83811115612dca5750506000910152565b6000815180845261487181602086016020860161482d565b601f01601f19169290920160200192915050565b602081526000612db76020830184614859565b600082601f8301126148a957600080fd5b612db78383356020850161466c565b600080600080608085870312156148ce57600080fd5b6148d7856145b0565b9350602085013567ffffffffffffffff808211156148f457600080fd5b6149008883890161473f565b9450604087013591508082111561491657600080fd5b6149228883890161473f565b9350606087013591508082111561493857600080fd5b5061494587828801614898565b91505092959194509250565b600082601f83011261496257600080fd5b8135602061496f8261471b565b60405161497c828261463f565b83815260059390931b850182019282810191508684111561499c57600080fd5b8286015b848110156147a5576149b1816145b0565b83529183019183016149a0565b600080604083850312156149d157600080fd5b823567ffffffffffffffff808211156149e957600080fd5b6149f58683870161473f565b93506020850135915080821115614a0b57600080fd5b5061480a85828601614951565b600080600080600060808688031215614a3057600080fd5b853594506020860135935060408601359250606086013567ffffffffffffffff80821115614a5d57600080fd5b818801915088601f830112614a7157600080fd5b813581811115614a8057600080fd5b896020828501011115614a9257600080fd5b9699959850939650602001949392505050565b600080600080600060a08688031215614abd57600080fd5b614ac6866145b0565b9450614ad4602087016145b0565b9350604086013567ffffffffffffffff80821115614af157600080fd5b614afd89838a0161473f565b94506060880135915080821115614b1357600080fd5b614b1f89838a0161473f565b93506080880135915080821115614b3557600080fd5b50614b4288828901614898565b9150509295509295909350565b60008060408385031215614b6257600080fd5b82359150614b72602084016145b0565b90509250929050565b600080600060608486031215614b9057600080fd5b833567ffffffffffffffff80821115614ba857600080fd5b614bb48783880161473f565b94506020860135915080821115614bca57600080fd5b614bd68783880161473f565b93506040860135915080821115614bec57600080fd5b50614bf98682870161473f565b9150509250925092565b60008060408385031215614c1657600080fd5b823567ffffffffffffffff80821115614c2e57600080fd5b6147e786838701614951565b600081518084526020808501945080840160005b83811015614c6a57815187529582019590820190600101614c4e565b509495945050505050565b602081526000612db76020830184614c3a565b600080600060608486031215614c9d57600080fd5b614ca6846145b0565b9250602084013567ffffffffffffffff80821115614bca57600080fd5b60008060008060808587031215614cd957600080fd5b614ce2856145b0565b93506020850135925060408501359150606085013567ffffffffffffffff811115614d0c57600080fd5b61494587828801614898565b60008060408385031215614d2b57600080fd5b614d34836145b0565b915060208301358015158114614d4957600080fd5b809150509250929050565b60008060408385031215614d6757600080fd5b614d70836145b0565b9150614b72602084016145b0565b600080600080600080600060e0888a031215614d9957600080fd5b87359650602088013567ffffffffffffffff80821115614db857600080fd5b614dc48b838c0161473f565b975060408a0135915080821115614dda57600080fd5b614de68b838c0161473f565b965060608a0135915080821115614dfc57600080fd5b614e088b838c0161473f565b955060808a0135915080821115614e1e57600080fd5b614e2a8b838c0161473f565b945060a08a0135915080821115614e4057600080fd5b614e4c8b838c0161473f565b935060c08a0135915080821115614e6257600080fd5b50614e6f8a828b0161473f565b91505092959891949750929550565b600080600080600060a08688031215614e9657600080fd5b614e9f866145b0565b9450614ead602087016145b0565b93506040860135925060608601359150608086013567ffffffffffffffff811115614ed757600080fd5b614b4288828901614898565b600080600060608486031215614ef857600080fd5b614f01846145b0565b95602085013595506040909401359392505050565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b6000600019821415614f5657614f56614f2c565b5060010190565b604081526000614f706040830185614c3a565b8281036020840152612d7e8185614c3a565b600181811c90821680614f9657607f821691505b60208210811415614fb757634e487b7160e01b600052602260045260246000fd5b50919050565b604081526000614fd06040830185614c3a565b82810360208481019190915284518083528582019282019060005b818110156150105784516001600160a01b031683529383019391830191600101614feb565b5090979650505050505050565b6000821982111561503057615030614f2c565b500190565b600081600019048311821515161561504f5761504f614f2c565b500290565b6060815260006150676060830186614c3a565b82810360208401526150798186614c3a565b9050828103604084015261508d8185614c3a565b9695505050505050565b7f416363657373436f6e74726f6c3a206163636f756e74200000000000000000008152600083516150cf81601785016020880161482d565b7f206973206d697373696e6720726f6c6520000000000000000000000000000000601791840191820152835161510c81602884016020880161482d565b01602801949350505050565b60008161512757615127614f2c565b506000190190565b60006001600160a01b03808816835280871660208401525060a0604083015261515b60a0830186614c3a565b828103606084015261516d8186614c3a565b905082810360808401526151818185614859565b98975050505050505050565b60006020828403121561519f57600080fd5b8151612db7816145f6565b600060033d11156141b45760046000803e5060005160e01c90565b600060443d10156151d35790565b6040516003193d81016004833e81513d67ffffffffffffffff816024840111818411171561520357505050505090565b828501915081518181111561521b5750505050505090565b843d87010160208285010111156152355750505050505090565b6152446020828601018761463f565b509095945050505050565b60006001600160a01b03808816835280871660208401525084604083015283606083015260a0608083015261528760a0830184614859565b979650505050505050565b6000828210156152a4576152a4614f2c565b500390565b634e487b7160e01b600052602160045260246000fdfe97667070c54ef182b0f5858b034beac1b6f3089aa2d3188bb1e8929f4fa9b929a2646970667358221220960d1c2a65cc861c38938c4bd55734c4c3759bce8e03f5076efc2ddddb38606f64736f6c634300080900330000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000c47656e65736973546f6b656e0000000000000000000000000000000000000000
Deployed Bytecode
0x6080604052600436106103285760003560e01c806375321c4a116101a5578063ba32e67e116100ec578063e7c8d22d11610095578063ed8a4a851161006f578063ed8a4a8514610983578063f242432a146109a3578063f5298aca146109c3578063f5b541a6146109e357600080fd5b8063e7c8d22d14610905578063e8a3d48514610925578063e985e9c51461093a57600080fd5b8063d547741f116100c6578063d547741f146108a5578063df7b7428146108c5578063e7572230146108e557600080fd5b8063ba32e67e14610838578063bd85b03914610858578063d05eaae01461088557600080fd5b8063938e3d7b1161014e578063a22cb46511610128578063a22cb465146107d8578063b67797d6146107f8578063b72b3bfe1461081857600080fd5b8063938e3d7b1461076f578063a1ebf35d1461078f578063a217fddf146107c357600080fd5b806385f438c11161017f57806385f438c1146106e05780638ada066e1461071457806391d148541461072957600080fd5b806375321c4a146106735780637bb68928146106935780638456cb59146106cb57600080fd5b80632eb2c2d6116102745780634e1273f41161021d5780636372f6fe116101f75780636372f6fe146105f357806363f0bfce146106135780636b20c45414610633578063731133e91461065357600080fd5b80634e1273f41461057f5780634f558e79146105ac5780635c975abb146105db57600080fd5b80633ccfd60b1161024e5780633ccfd60b146105355780633f4ba83a1461054a578063448db6961461055f57600080fd5b80632eb2c2d6146104d55780632f2ff15d146104f557806336568abe1461051557600080fd5b806313caf551116102d6578063248a9ca3116102b0578063248a9ca31461047257806327dafe5b146104a25780632c3e9d9d146104c257600080fd5b806313caf551146104125780631ed2b37e146104325780631f7fdffa1461045257600080fd5b806303ceb77f1161030757806303ceb77f146103b25780630e89341c146103d257806312065fe0146103ff57600080fd5b8062fdd58e1461032d57806301ffc9a71461036057806302fe530514610390575b600080fd5b34801561033957600080fd5b5061034d6103483660046145cc565b610a05565b6040519081526020015b60405180910390f35b34801561036c57600080fd5b5061038061037b36600461460c565b610a9c565b6040519015158152602001610357565b34801561039c57600080fd5b506103b06103ab3660046146ca565b610aad565b005b3480156103be57600080fd5b506103b06103cd3660046147b0565b610b0a565b3480156103de57600080fd5b506103f26103ed366004614814565b610d0c565b6040516103579190614885565b34801561040b57600080fd5b504761034d565b34801561041e57600080fd5b5061034d61042d366004614814565b610da0565b34801561043e57600080fd5b506103b061044d3660046147b0565b610dfb565b34801561045e57600080fd5b506103b061046d3660046148b8565b610f99565b34801561047e57600080fd5b5061034d61048d366004614814565b60009081526003602052604090206001015490565b3480156104ae57600080fd5b506103b06104bd3660046149be565b61100a565b6103b06104d0366004614a18565b6111c8565b3480156104e157600080fd5b506103b06104f0366004614aa5565b61162d565b34801561050157600080fd5b506103b0610510366004614b4f565b6116c8565b34801561052157600080fd5b506103b0610530366004614b4f565b6116f3565b34801561054157600080fd5b506103b061177f565b34801561055657600080fd5b506103b061187f565b34801561056b57600080fd5b506103b061057a366004614b7b565b6118a3565b34801561058b57600080fd5b5061059f61059a366004614c03565b611b1f565b6040516103579190614c75565b3480156105b857600080fd5b506103806105c7366004614814565b600090815260056020526040902054151590565b3480156105e757600080fd5b5060045460ff16610380565b3480156105ff57600080fd5b5061034d61060e366004614814565b611c49565b34801561061f57600080fd5b506103b061062e366004614814565b611ca4565b34801561063f57600080fd5b506103b061064e366004614c88565b611cdc565b34801561065f57600080fd5b506103b061066e366004614cc3565b611d61565b34801561067f57600080fd5b5061034d61068e366004614814565b611e8e565b34801561069f57600080fd5b506106b36106ae366004614814565b611ee9565b6040516001600160a01b039091168152602001610357565b3480156106d757600080fd5b506103b0611f4d565b3480156106ec57600080fd5b5061034d7f10dac8c06a04bec0b551627dad28bc00d6516b0caacd1c7b345fcdb5211334e481565b34801561072057600080fd5b5061034d611f6e565b34801561073557600080fd5b50610380610744366004614b4f565b60009182526003602090815260408084206001600160a01b0393909316845291905290205460ff1690565b34801561077b57600080fd5b506103b061078a3660046146ca565b611f7e565b34801561079b57600080fd5b5061034d7fe2f4eaae4a9751e85a3e4a7b9587827a877f29914755229b07a7b2da98285f7081565b3480156107cf57600080fd5b5061034d600081565b3480156107e457600080fd5b506103b06107f3366004614d18565b611faa565b34801561080457600080fd5b506103b0610813366004614814565b611fb5565b34801561082457600080fd5b506103b06108333660046147b0565b611ffe565b34801561084457600080fd5b506103b0610853366004614814565b61219c565b34801561086457600080fd5b5061034d610873366004614814565b60009081526005602052604090205490565b34801561089157600080fd5b506103b06108a03660046147b0565b6121fe565b3480156108b157600080fd5b506103b06108c0366004614b4f565b612392565b3480156108d157600080fd5b5061034d6108e0366004614814565b6123b8565b3480156108f157600080fd5b5061034d610900366004614814565b612410565b34801561091157600080fd5b5061034d610920366004614814565b61246b565b34801561093157600080fd5b506103f26124c6565b34801561094657600080fd5b50610380610955366004614d54565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205460ff1690565b34801561098f57600080fd5b506103b061099e366004614d7e565b612558565b3480156109af57600080fd5b506103b06109be366004614e7e565b612970565b3480156109cf57600080fd5b506103b06109de366004614ee3565b6129f7565b3480156109ef57600080fd5b5061034d6000805160206152c083398151915281565b60006001600160a01b038316610a765760405162461bcd60e51b815260206004820152602b60248201527f455243313135353a2062616c616e636520717565727920666f7220746865207a60448201526a65726f206164647265737360a81b60648201526084015b60405180910390fd5b506000908152602081815260408083206001600160a01b03949094168352929052205490565b6000610aa782612a7c565b92915050565b6000805160206152c0833981519152610ac68133612aa1565b610acf82612b21565b7fb1bf12e17db588c31e8fb2afdd2b3bc1ed822d68c560856fcbc75ae303fc5d1482604051610afe9190614885565b60405180910390a15050565b6000805160206152c0833981519152610b238133612aa1565b6000835111610b6a5760405162461bcd60e51b8152602060048201526013602482015272494e56414c49445f544f4b454e535f53495a4560681b6044820152606401610a6d565b8251825114610bbb5760405162461bcd60e51b815260206004820152601660248201527f494e56414c49445f4d41585f4954454d535f53495a45000000000000000000006044820152606401610a6d565b60005b8351811015610ccd576000838281518110610bdb57610bdb614f16565b602002602001015111610c235760405162461bcd60e51b815260206004820152601060248201526f494e56414c49445f4d41585f4954454d60801b6044820152606401610a6d565b600060076000868481518110610c3b57610c3b614f16565b6020026020010151815260200190815260200160002090506000816000015411610c9c5760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b838281518110610cae57610cae614f16565b6020908102919091010151905580610cc581614f42565b915050610bbe565b507f4402caae79d7b040a75c7d72c65fdd1be0cbe28590584456f0cbb49f2346f4e88383604051610cff929190614f5d565b60405180910390a1505050565b606060028054610d1b90614f82565b80601f0160208091040260200160405190810160405280929190818152602001828054610d4790614f82565b8015610d945780601f10610d6957610100808354040283529160200191610d94565b820191906000526020600020905b815481529060010190602001808311610d7757829003601f168201915b50505050509050919050565b60008181526007602052604081208054610df15760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b6005015492915050565b6000805160206152c0833981519152610e148133612aa1565b6000835111610e5b5760405162461bcd60e51b8152602060048201526013602482015272494e56414c49445f544f4b454e535f53495a4560681b6044820152606401610a6d565b8251825114610eac5760405162461bcd60e51b815260206004820152601760248201527f494e56414c49445f4d41585f57414c4c45545f53495a450000000000000000006044820152606401610a6d565b60005b8351811015610f6757600060076000868481518110610ed057610ed0614f16565b6020026020010151815260200190815260200160002090506000816000015411610f315760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b838281518110610f4357610f43614f16565b60200260200101518160010181905550508080610f5f90614f42565b915050610eaf565b507fb355828fc1c77f59b3e0f1ce2ade5407d2fac2a198475714987654ab2647c7ec8383604051610cff929190614f5d565b6000805160206152c0833981519152610fb28133612aa1565b60045460ff1615610ff75760405162461bcd60e51b815260206004820152600f60248201526e10d3d395149050d517d4105554d151608a1b6044820152606401610a6d565b61100385858585612b34565b5050505050565b6000805160206152c08339815191526110238133612aa1565b600083511161106a5760405162461bcd60e51b8152602060048201526013602482015272494e56414c49445f544f4b454e535f53495a4560681b6044820152606401610a6d565b82518251146110bb5760405162461bcd60e51b815260206004820152601d60248201527f494e56414c49445f52454445454d5f434f4e5452414354535f53495a450000006044820152606401610a6d565b60005b8351811015611196576000600760008684815181106110df576110df614f16565b60200260200101518152602001908152602001600020905060008160000154116111405760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b83828151811061115257611152614f16565b60200260200101518160060160006101000a8154816001600160a01b0302191690836001600160a01b0316021790555050808061118e90614f42565b9150506110be565b507f7bd6be6cbe8904036ddacfaa6886ec26d27b698db8de720a6993590b58d971aa8383604051610cff929190614fbd565b60045460ff161561120d5760405162461bcd60e51b815260206004820152600f60248201526e10d3d395149050d517d4105554d151608a1b6044820152606401610a6d565b6000858152600760205260409020805461125e5760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b600061126c33888888612d09565b90506112ae8185858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250612d8792505050565b6112fa5760405162461bcd60e51b815260206004820152601160248201527f494e56414c49445f5349474e41545552450000000000000000000000000000006044820152606401610a6d565b6000818152600860205260409020546001600160a01b03161561135f5760405162461bcd60e51b815260206004820152601660248201527f544f4b454e5f414c52454144595f52454445454d4544000000000000000000006044820152606401610a6d565b81600401544210156113b35760405162461bcd60e51b815260206004820152601160248201527f494e56414c49445f4f50454e5f444154450000000000000000000000000000006044820152606401610a6d565b81600501544211156114075760405162461bcd60e51b815260206004820152601260248201527f494e56414c49445f434c4f53455f4441544500000000000000000000000000006044820152606401610a6d565b6002820154156114655781600201548611156114655760405162461bcd60e51b815260206004820152601b60248201527f494e56414c49445f4d41585f5045525f5452414e53414354494f4e00000000006044820152606401610a6d565b6001820154156114dd57600061147b3389610a05565b600184015490915061148d888361501d565b11156114db5760405162461bcd60e51b815260206004820152601660248201527f494e56414c49445f4d41585f5045525f57414c4c4554000000000000000000006044820152606401610a6d565b505b600382015415611546578582600301546114f79190615035565b3410156115465760405162461bcd60e51b815260206004820152601160248201527f56414c55455f42454c4f575f50524943450000000000000000000000000000006044820152606401610a6d565b815460008881526005602052604090205461156290889061501d565b11156115b05760405162461bcd60e51b815260206004820152601960248201527f50555243484153455f4558434545445f4d41585f4954454d53000000000000006044820152606401610a6d565b6115cb33888860405180602001604052806000815250612dbe565b60008181526008602090815260409182902080546001600160a01b031916339081179091558251848152918201527f2310322c3f4ed401acfe8d97231f0f8ad43265f9da74d91004b8f625d0e2962a910160405180910390a150505050505050565b6001600160a01b03851633148061164957506116498533610955565b6116bb5760405162461bcd60e51b815260206004820152603260248201527f455243313135353a207472616e736665722063616c6c6572206973206e6f742060448201527f6f776e6572206e6f7220617070726f76656400000000000000000000000000006064820152608401610a6d565b6110038585858585612dd0565b6000828152600360205260409020600101546116e48133612aa1565b6116ee8383613034565b505050565b6001600160a01b03811633146117715760405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201527f20726f6c657320666f722073656c6600000000000000000000000000000000006064820152608401610a6d565b61177b82826130d6565b5050565b7f10dac8c06a04bec0b551627dad28bc00d6516b0caacd1c7b345fcdb5211334e46117aa8133612aa1565b47806117e75760405162461bcd60e51b815260206004820152600c60248201526b42414c414e43455f5a45524f60a01b6044820152606401610a6d565b604051600090339083908381818185875af1925050503d8060008114611829576040519150601f19603f3d011682016040523d82523d6000602084013e61182e565b606091505b50509050806116ee5760405162461bcd60e51b815260206004820152600f60248201527f57495448445241575f4641494c454400000000000000000000000000000000006044820152606401610a6d565b6000805160206152c08339815191526118988133612aa1565b6118a0613159565b50565b6000805160206152c08339815191526118bc8133612aa1565b60008451116119035760405162461bcd60e51b8152602060048201526013602482015272494e56414c49445f544f4b454e535f53495a4560681b6044820152606401610a6d565b83518351146119485760405162461bcd60e51b8152602060048201526011602482015270494e56414c49445f4f50454e5f53495a4560781b6044820152606401610a6d565b835182511461198e5760405162461bcd60e51b8152602060048201526012602482015271494e56414c49445f434c4f53455f53495a4560701b6044820152606401610a6d565b60005b8451811015611add578281815181106119ac576119ac614f16565b60200260200101518482815181106119c6576119c6614f16565b60200260200101511115611a0c5760405162461bcd60e51b815260206004820152600d60248201526c494e56414c49445f444154455360981b6044820152606401610a6d565b600060076000878481518110611a2457611a24614f16565b6020026020010151815260200190815260200160002090506000816000015411611a855760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b848281518110611a9757611a97614f16565b60200260200101518160040181905550838281518110611ab957611ab9614f16565b60200260200101518160050181905550508080611ad590614f42565b915050611991565b507f396df38625537eac114c72dc57288ba26ee0169e7dd3889e273e40c3f0ab40cf848484604051611b1193929190615054565b60405180910390a150505050565b60608151835114611b845760405162461bcd60e51b815260206004820152602960248201527f455243313135353a206163636f756e747320616e6420696473206c656e677468604482015268040dad2e6dac2e8c6d60bb1b6064820152608401610a6d565b6000835167ffffffffffffffff811115611ba057611ba0614629565b604051908082528060200260200182016040528015611bc9578160200160208202803683370190505b50905060005b8451811015611c4157611c14858281518110611bed57611bed614f16565b6020026020010151858381518110611c0757611c07614f16565b6020026020010151610a05565b828281518110611c2657611c26614f16565b6020908102919091010152611c3a81614f42565b9050611bcf565b509392505050565b60008181526007602052604081208054611c9a5760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b6002015492915050565b6000805160206152c0833981519152611cbd8133612aa1565b50600090815260086020526040902080546001600160a01b0319169055565b6001600160a01b038316331480611cf85750611cf88333610955565b611d565760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2063616c6c6572206973206e6f74206f776e6572206e6f7260448201526808185c1c1c9bdd995960ba1b6064820152608401610a6d565b6116ee8383836131f5565b6000805160206152c0833981519152611d7a8133612aa1565b60045460ff1615611dbf5760405162461bcd60e51b815260206004820152600f60248201526e10d3d395149050d517d4105554d151608a1b6044820152606401610a6d565b60008481526007602052604090208054611e105760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b8054600086815260056020526040902054611e2c90869061501d565b1115611e7a5760405162461bcd60e51b815260206004820152601960248201527f50555243484153455f4558434545445f4d41585f4954454d53000000000000006044820152606401610a6d565b611e8686868686612dbe565b505050505050565b60008181526007602052604081208054611edf5760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b6004015492915050565b60008181526007602052604081208054611f3a5760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b600601546001600160a01b031692915050565b6000805160206152c0833981519152611f668133612aa1565b6118a061343c565b6000611f7960065490565b905090565b6000805160206152c0833981519152611f978133612aa1565b81516116ee906009906020850190614517565b61177b3383836134b7565b6000805160206152c0833981519152611fce8133612aa1565b600060065560005b828110156116ee57611fec600680546001019055565b80611ff681614f42565b915050611fd6565b6000805160206152c08339815191526120178133612aa1565b600083511161205e5760405162461bcd60e51b8152602060048201526013602482015272494e56414c49445f544f4b454e535f53495a4560681b6044820152606401610a6d565b82518251146120af5760405162461bcd60e51b815260206004820152601c60248201527f494e56414c49445f4d41585f5452414e53414354494f4e5f53495a45000000006044820152606401610a6d565b60005b835181101561216a576000600760008684815181106120d3576120d3614f16565b60200260200101518152602001908152602001600020905060008160000154116121345760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b83828151811061214657612146614f16565b6020026020010151816002018190555050808061216290614f42565b9150506120b2565b507f7e144fd6b36fcdb9448b08cb1dd907f43c49241caa48f7ee7eb69932074230268383604051610cff929190614f5d565b6000805160206152c08339815191526121b58133612aa1565b50600090815260076020526040812081815560018101829055600281018290556003810182905560048101829055600581019190915560060180546001600160a01b0319169055565b6000805160206152c08339815191526122178133612aa1565b600083511161225e5760405162461bcd60e51b8152602060048201526013602482015272494e56414c49445f544f4b454e535f53495a4560681b6044820152606401610a6d565b82518251146122a55760405162461bcd60e51b8152602060048201526013602482015272494e56414c49445f5052494345535f53495a4560681b6044820152606401610a6d565b60005b8351811015612360576000600760008684815181106122c9576122c9614f16565b602002602001015181526020019081526020016000209050600081600001541161232a5760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b83828151811061233c5761233c614f16565b6020026020010151816003018190555050808061235890614f42565b9150506122a8565b507fbe192de9462d6c5663b4a1ca8035d8bb4c41a613f8842b02c1941bf1b52b10378383604051610cff929190614f5d565b6000828152600360205260409020600101546123ae8133612aa1565b6116ee83836130d6565b600081815260076020526040812080546124095760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b5492915050565b600081815260076020526040812080546124615760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b6003015492915050565b600081815260076020526040812080546124bc5760405162461bcd60e51b81526020600482015260126024820152711513d2d15397d25117d393d517d1561254d560721b6044820152606401610a6d565b6001015492915050565b6060600980546124d590614f82565b80601f016020809104026020016040519081016040528092919081815260200182805461250190614f82565b801561254e5780601f106125235761010080835404028352916020019161254e565b820191906000526020600020905b81548152906001019060200180831161253157829003601f168201915b5050505050905090565b6000805160206152c08339815191526125718133612aa1565b600088116125c15760405162461bcd60e51b815260206004820152601560248201527f494e56414c49445f4e554d4245525f544f4b454e5300000000000000000000006044820152606401610a6d565b878751146126115760405162461bcd60e51b815260206004820152601660248201527f494e56414c49445f4d41585f4954454d535f53495a45000000000000000000006044820152606401610a6d565b878651146126615760405162461bcd60e51b815260206004820152601760248201527f494e56414c49445f4d41585f57414c4c45545f53495a450000000000000000006044820152606401610a6d565b878551146126b15760405162461bcd60e51b815260206004820152601c60248201527f494e56414c49445f4d41585f5452414e53414354494f4e5f53495a45000000006044820152606401610a6d565b878451146126f75760405162461bcd60e51b8152602060048201526013602482015272494e56414c49445f5052494345535f53495a4560681b6044820152606401610a6d565b8783511461273b5760405162461bcd60e51b8152602060048201526011602482015270494e56414c49445f4f50454e5f53495a4560781b6044820152606401610a6d565b878251146127805760405162461bcd60e51b8152602060048201526012602482015271494e56414c49445f434c4f53455f53495a4560701b6044820152606401610a6d565b60005b8881101561296557600088828151811061279f5761279f614f16565b6020026020010151116127e75760405162461bcd60e51b815260206004820152601060248201526f494e56414c49445f4d41585f4954454d60801b6044820152606401610a6d565b8281815181106127f9576127f9614f16565b602002602001015184828151811061281357612813614f16565b602002602001015111156128595760405162461bcd60e51b815260206004820152600d60248201526c494e56414c49445f444154455360981b6044820152606401610a6d565b60006007600061286860065490565b8152602001908152602001600020905088828151811061288a5761288a614f16565b602002602001015181600001819055508682815181106128ac576128ac614f16565b602002602001015181600201819055508782815181106128ce576128ce614f16565b602002602001015181600101819055508582815181106128f0576128f0614f16565b6020026020010151816003018190555084828151811061291257612912614f16565b6020026020010151816004018190555083828151811061293457612934614f16565b60200260200101518160050181905550612952600680546001019055565b508061295d81614f42565b915050612783565b505050505050505050565b6001600160a01b03851633148061298c575061298c8533610955565b6129ea5760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2063616c6c6572206973206e6f74206f776e6572206e6f7260448201526808185c1c1c9bdd995960ba1b6064820152608401610a6d565b6110038585858585613598565b6001600160a01b038316331480612a135750612a138333610955565b612a715760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2063616c6c6572206973206e6f74206f776e6572206e6f7260448201526808185c1c1c9bdd995960ba1b6064820152608401610a6d565b6116ee838383613745565b60006001600160e01b03198216637965db0b60e01b1480610aa75750610aa7826138be565b60008281526003602090815260408083206001600160a01b038516845290915290205460ff1661177b57612adf816001600160a01b0316601461390e565b612aea83602061390e565b604051602001612afb929190615097565b60408051601f198184030181529082905262461bcd60e51b8252610a6d91600401614885565b805161177b906002906020840190614517565b6001600160a01b038416612b945760405162461bcd60e51b815260206004820152602160248201527f455243313135353a206d696e7420746f20746865207a65726f206164647265736044820152607360f81b6064820152608401610a6d565b8151835114612bf65760405162461bcd60e51b815260206004820152602860248201527f455243313135353a2069647320616e6420616d6f756e7473206c656e677468206044820152670dad2e6dac2e8c6d60c31b6064820152608401610a6d565b33612c0681600087878787613ab7565b60005b8451811015612ca157838181518110612c2457612c24614f16565b6020026020010151600080878481518110612c4157612c41614f16565b602002602001015181526020019081526020016000206000886001600160a01b03166001600160a01b031681526020019081526020016000206000828254612c89919061501d565b90915550819050612c9981614f42565b915050612c09565b50846001600160a01b031660006001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8787604051612cf2929190614f5d565b60405180910390a461100381600087878787613b0b565b604080517f6c614e0727fa7406d276937059675ea43b8e8586c92a0aebc9ecfd2dc187237660208201526001600160a01b03861691810191909152606081018490526080810183905260a08101829052600090612d7e9060c00160405160208183030381529060405280519060200120613cc0565b95945050505050565b6000612db77fe2f4eaae4a9751e85a3e4a7b9587827a877f29914755229b07a7b2da98285f706107448585613d0e565b9392505050565b612dca84848484613d2a565b50505050565b8151835114612e325760405162461bcd60e51b815260206004820152602860248201527f455243313135353a2069647320616e6420616d6f756e7473206c656e677468206044820152670dad2e6dac2e8c6d60c31b6064820152608401610a6d565b6001600160a01b038416612e965760405162461bcd60e51b815260206004820152602560248201527f455243313135353a207472616e7366657220746f20746865207a65726f206164604482015264647265737360d81b6064820152608401610a6d565b33612ea5818787878787613ab7565b60005b8451811015612fce576000858281518110612ec557612ec5614f16565b602002602001015190506000858381518110612ee357612ee3614f16565b602090810291909101810151600084815280835260408082206001600160a01b038e168352909352919091205490915081811015612f765760405162461bcd60e51b815260206004820152602a60248201527f455243313135353a20696e73756666696369656e742062616c616e636520666f60448201526939103a3930b739b332b960b11b6064820152608401610a6d565b6000838152602081815260408083206001600160a01b038e8116855292528083208585039055908b16825281208054849290612fb390849061501d565b9250508190555050505080612fc790614f42565b9050612ea8565b50846001600160a01b0316866001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb878760405161301e929190614f5d565b60405180910390a4611e86818787878787613b0b565b60008281526003602090815260408083206001600160a01b038516845290915290205460ff1661177b5760008281526003602090815260408083206001600160a01b03851684529091529020805460ff191660011790556130923390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b60008281526003602090815260408083206001600160a01b038516845290915290205460ff161561177b5760008281526003602090815260408083206001600160a01b0385168085529252808320805460ff1916905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b60045460ff166131ab5760405162461bcd60e51b815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610a6d565b6004805460ff191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b6040516001600160a01b03909116815260200160405180910390a1565b6001600160a01b0383166132575760405162461bcd60e51b815260206004820152602360248201527f455243313135353a206275726e2066726f6d20746865207a65726f206164647260448201526265737360e81b6064820152608401610a6d565b80518251146132b95760405162461bcd60e51b815260206004820152602860248201527f455243313135353a2069647320616e6420616d6f756e7473206c656e677468206044820152670dad2e6dac2e8c6d60c31b6064820152608401610a6d565b60003390506132dc81856000868660405180602001604052806000815250613ab7565b60005b83518110156133dd5760008482815181106132fc576132fc614f16565b60200260200101519050600084838151811061331a5761331a614f16565b602090810291909101810151600084815280835260408082206001600160a01b038c1683529093529190912054909150818110156133a65760405162461bcd60e51b8152602060048201526024808201527f455243313135353a206275726e20616d6f756e7420657863656564732062616c604482015263616e636560e01b6064820152608401610a6d565b6000928352602083815260408085206001600160a01b038b16865290915290922091039055806133d581614f42565b9150506132df565b5060006001600160a01b0316846001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb868660405161342e929190614f5d565b60405180910390a450505050565b60045460ff16156134825760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b6044820152606401610a6d565b6004805460ff191660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586131d83390565b816001600160a01b0316836001600160a01b0316141561352b5760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2073657474696e6720617070726f76616c20737461747573604482015268103337b91039b2b63360b91b6064820152608401610a6d565b6001600160a01b03838116600081815260016020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6001600160a01b0384166135fc5760405162461bcd60e51b815260206004820152602560248201527f455243313135353a207472616e7366657220746f20746865207a65726f206164604482015264647265737360d81b6064820152608401610a6d565b3361361b81878761360c88613e2b565b61361588613e2b565b87613ab7565b6000848152602081815260408083206001600160a01b038a1684529091529020548381101561369f5760405162461bcd60e51b815260206004820152602a60248201527f455243313135353a20696e73756666696369656e742062616c616e636520666f60448201526939103a3930b739b332b960b11b6064820152608401610a6d565b6000858152602081815260408083206001600160a01b038b81168552925280832087850390559088168252812080548692906136dc90849061501d565b909155505060408051868152602081018690526001600160a01b03808916928a821692918616917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a461373c828888888888613e76565b50505050505050565b6001600160a01b0383166137a75760405162461bcd60e51b815260206004820152602360248201527f455243313135353a206275726e2066726f6d20746865207a65726f206164647260448201526265737360e81b6064820152608401610a6d565b336137d6818560006137b887613e2b565b6137c187613e2b565b60405180602001604052806000815250613ab7565b6000838152602081815260408083206001600160a01b0388168452909152902054828110156138535760405162461bcd60e51b8152602060048201526024808201527f455243313135353a206275726e20616d6f756e7420657863656564732062616c604482015263616e636560e01b6064820152608401610a6d565b6000848152602081815260408083206001600160a01b03898116808652918452828520888703905582518981529384018890529092908616917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a45050505050565b60006001600160e01b03198216636cdb3d1360e11b14806138ef57506001600160e01b031982166303a24d0760e21b145b80610aa757506301ffc9a760e01b6001600160e01b0319831614610aa7565b6060600061391d836002615035565b61392890600261501d565b67ffffffffffffffff81111561394057613940614629565b6040519080825280601f01601f19166020018201604052801561396a576020820181803683370190505b509050600360fc1b8160008151811061398557613985614f16565b60200101906001600160f81b031916908160001a905350600f60fb1b816001815181106139b4576139b4614f16565b60200101906001600160f81b031916908160001a90535060006139d8846002615035565b6139e390600161501d565b90505b6001811115613a68577f303132333435363738396162636465660000000000000000000000000000000085600f1660108110613a2457613a24614f16565b1a60f81b828281518110613a3a57613a3a614f16565b60200101906001600160f81b031916908160001a90535060049490941c93613a6181615118565b90506139e6565b508315612db75760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401610a6d565b60045460ff1615613afd5760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b6044820152606401610a6d565b611e86868686868686613f81565b6001600160a01b0384163b15611e865760405163bc197c8160e01b81526001600160a01b0385169063bc197c8190613b4f908990899088908890889060040161512f565b602060405180830381600087803b158015613b6957600080fd5b505af1925050508015613b99575060408051601f3d908101601f19168201909252613b969181019061518d565b60015b613c4f57613ba56151aa565b806308c379a01415613bdf5750613bba6151c5565b80613bc55750613be1565b8060405162461bcd60e51b8152600401610a6d9190614885565b505b60405162461bcd60e51b815260206004820152603460248201527f455243313135353a207472616e7366657220746f206e6f6e204552433131353560448201527f526563656976657220696d706c656d656e7465720000000000000000000000006064820152608401610a6d565b6001600160e01b0319811663bc197c8160e01b1461373c5760405162461bcd60e51b815260206004820152602860248201527f455243313135353a204552433131353552656365697665722072656a656374656044820152676420746f6b656e7360c01b6064820152608401610a6d565b6000610aa7613ccd61408d565b8360405161190160f01b6020820152602281018390526042810182905260009060620160405160208183030381529060405280519060200120905092915050565b6000806000613d1d85856141b7565b91509150611c4181614227565b6001600160a01b038416613d8a5760405162461bcd60e51b815260206004820152602160248201527f455243313135353a206d696e7420746f20746865207a65726f206164647265736044820152607360f81b6064820152608401610a6d565b33613d9b8160008761360c88613e2b565b6000848152602081815260408083206001600160a01b038916845290915281208054859290613dcb90849061501d565b909155505060408051858152602081018590526001600160a01b0380881692600092918516917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a461100381600087878787613e76565b60408051600180825281830190925260609160009190602080830190803683370190505090508281600081518110613e6557613e65614f16565b602090810291909101015292915050565b6001600160a01b0384163b15611e865760405163f23a6e6160e01b81526001600160a01b0385169063f23a6e6190613eba908990899088908890889060040161524f565b602060405180830381600087803b158015613ed457600080fd5b505af1925050508015613f04575060408051601f3d908101601f19168201909252613f019181019061518d565b60015b613f1057613ba56151aa565b6001600160e01b0319811663f23a6e6160e01b1461373c5760405162461bcd60e51b815260206004820152602860248201527f455243313135353a204552433131353552656365697665722072656a656374656044820152676420746f6b656e7360c01b6064820152608401610a6d565b6001600160a01b0385166140085760005b835181101561400657828181518110613fad57613fad614f16565b602002602001015160056000868481518110613fcb57613fcb614f16565b602002602001015181526020019081526020016000206000828254613ff0919061501d565b90915550613fff905081614f42565b9050613f92565b505b6001600160a01b038416611e865760005b835181101561373c5782818151811061403457614034614f16565b60200260200101516005600086848151811061405257614052614f16565b6020026020010151815260200190815260200160002060008282546140779190615292565b90915550614086905081614f42565b9050614019565b6000306001600160a01b037f000000000000000000000000f5985c3917f857b197168f91324cb7b7d762b219161480156140e657507f000000000000000000000000000000000000000000000000000000000000000146145b1561411057507fa25ceb78c470fe112bbc1102f71ac6e9aca5ddc339a4d86ac441ba487ea40b9190565b50604080517f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f6020808301919091527fe393c914532dff6c2abbc09c7b874a40b79024d6c0eee5436453e5e53ac2a23d828401527f06c015bd22b4c69690933c1058878ebdfef31f9aaae40bbe86d8a09fe1b2972c60608301524660808301523060a0808401919091528351808403909101815260c0909201909252805191012090565b90565b6000808251604114156141ee5760208301516040840151606085015160001a6141e2878285856143e2565b94509450505050614220565b825160401415614218576020830151604084015161420d8683836144cf565b935093505050614220565b506000905060025b9250929050565b600081600481111561423b5761423b6152a9565b14156142445750565b6001816004811115614258576142586152a9565b14156142a65760405162461bcd60e51b815260206004820152601860248201527f45434453413a20696e76616c6964207369676e617475726500000000000000006044820152606401610a6d565b60028160048111156142ba576142ba6152a9565b14156143085760405162461bcd60e51b815260206004820152601f60248201527f45434453413a20696e76616c6964207369676e6174757265206c656e677468006044820152606401610a6d565b600381600481111561431c5761431c6152a9565b14156143755760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202773272076616c604482015261756560f01b6064820152608401610a6d565b6004816004811115614389576143896152a9565b14156118a05760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202776272076616c604482015261756560f01b6064820152608401610a6d565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a083111561441957506000905060036144c6565b8460ff16601b1415801561443157508460ff16601c14155b1561444257506000905060046144c6565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa158015614496573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381166144bf576000600192509250506144c6565b9150600090505b94509492505050565b6000807f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff831660ff84901c601b01614509878288856143e2565b935093505050935093915050565b82805461452390614f82565b90600052602060002090601f016020900481019282614545576000855561458b565b82601f1061455e57805160ff191683800117855561458b565b8280016001018555821561458b579182015b8281111561458b578251825591602001919060010190614570565b5061459792915061459b565b5090565b5b80821115614597576000815560010161459c565b80356001600160a01b03811681146145c757600080fd5b919050565b600080604083850312156145df57600080fd5b6145e8836145b0565b946020939093013593505050565b6001600160e01b0319811681146118a057600080fd5b60006020828403121561461e57600080fd5b8135612db7816145f6565b634e487b7160e01b600052604160045260246000fd5b601f8201601f1916810167ffffffffffffffff8111828210171561466557614665614629565b6040525050565b600067ffffffffffffffff83111561468657614686614629565b60405161469d601f8501601f19166020018261463f565b8091508381528484840111156146b257600080fd5b83836020830137600060208583010152509392505050565b6000602082840312156146dc57600080fd5b813567ffffffffffffffff8111156146f357600080fd5b8201601f8101841361470457600080fd5b6147138482356020840161466c565b949350505050565b600067ffffffffffffffff82111561473557614735614629565b5060051b60200190565b600082601f83011261475057600080fd5b8135602061475d8261471b565b60405161476a828261463f565b83815260059390931b850182019282810191508684111561478a57600080fd5b8286015b848110156147a5578035835291830191830161478e565b509695505050505050565b600080604083850312156147c357600080fd5b823567ffffffffffffffff808211156147db57600080fd5b6147e78683870161473f565b935060208501359150808211156147fd57600080fd5b5061480a8582860161473f565b9150509250929050565b60006020828403121561482657600080fd5b5035919050565b60005b83811015614848578181015183820152602001614830565b83811115612dca5750506000910152565b6000815180845261487181602086016020860161482d565b601f01601f19169290920160200192915050565b602081526000612db76020830184614859565b600082601f8301126148a957600080fd5b612db78383356020850161466c565b600080600080608085870312156148ce57600080fd5b6148d7856145b0565b9350602085013567ffffffffffffffff808211156148f457600080fd5b6149008883890161473f565b9450604087013591508082111561491657600080fd5b6149228883890161473f565b9350606087013591508082111561493857600080fd5b5061494587828801614898565b91505092959194509250565b600082601f83011261496257600080fd5b8135602061496f8261471b565b60405161497c828261463f565b83815260059390931b850182019282810191508684111561499c57600080fd5b8286015b848110156147a5576149b1816145b0565b83529183019183016149a0565b600080604083850312156149d157600080fd5b823567ffffffffffffffff808211156149e957600080fd5b6149f58683870161473f565b93506020850135915080821115614a0b57600080fd5b5061480a85828601614951565b600080600080600060808688031215614a3057600080fd5b853594506020860135935060408601359250606086013567ffffffffffffffff80821115614a5d57600080fd5b818801915088601f830112614a7157600080fd5b813581811115614a8057600080fd5b896020828501011115614a9257600080fd5b9699959850939650602001949392505050565b600080600080600060a08688031215614abd57600080fd5b614ac6866145b0565b9450614ad4602087016145b0565b9350604086013567ffffffffffffffff80821115614af157600080fd5b614afd89838a0161473f565b94506060880135915080821115614b1357600080fd5b614b1f89838a0161473f565b93506080880135915080821115614b3557600080fd5b50614b4288828901614898565b9150509295509295909350565b60008060408385031215614b6257600080fd5b82359150614b72602084016145b0565b90509250929050565b600080600060608486031215614b9057600080fd5b833567ffffffffffffffff80821115614ba857600080fd5b614bb48783880161473f565b94506020860135915080821115614bca57600080fd5b614bd68783880161473f565b93506040860135915080821115614bec57600080fd5b50614bf98682870161473f565b9150509250925092565b60008060408385031215614c1657600080fd5b823567ffffffffffffffff80821115614c2e57600080fd5b6147e786838701614951565b600081518084526020808501945080840160005b83811015614c6a57815187529582019590820190600101614c4e565b509495945050505050565b602081526000612db76020830184614c3a565b600080600060608486031215614c9d57600080fd5b614ca6846145b0565b9250602084013567ffffffffffffffff80821115614bca57600080fd5b60008060008060808587031215614cd957600080fd5b614ce2856145b0565b93506020850135925060408501359150606085013567ffffffffffffffff811115614d0c57600080fd5b61494587828801614898565b60008060408385031215614d2b57600080fd5b614d34836145b0565b915060208301358015158114614d4957600080fd5b809150509250929050565b60008060408385031215614d6757600080fd5b614d70836145b0565b9150614b72602084016145b0565b600080600080600080600060e0888a031215614d9957600080fd5b87359650602088013567ffffffffffffffff80821115614db857600080fd5b614dc48b838c0161473f565b975060408a0135915080821115614dda57600080fd5b614de68b838c0161473f565b965060608a0135915080821115614dfc57600080fd5b614e088b838c0161473f565b955060808a0135915080821115614e1e57600080fd5b614e2a8b838c0161473f565b945060a08a0135915080821115614e4057600080fd5b614e4c8b838c0161473f565b935060c08a0135915080821115614e6257600080fd5b50614e6f8a828b0161473f565b91505092959891949750929550565b600080600080600060a08688031215614e9657600080fd5b614e9f866145b0565b9450614ead602087016145b0565b93506040860135925060608601359150608086013567ffffffffffffffff811115614ed757600080fd5b614b4288828901614898565b600080600060608486031215614ef857600080fd5b614f01846145b0565b95602085013595506040909401359392505050565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b6000600019821415614f5657614f56614f2c565b5060010190565b604081526000614f706040830185614c3a565b8281036020840152612d7e8185614c3a565b600181811c90821680614f9657607f821691505b60208210811415614fb757634e487b7160e01b600052602260045260246000fd5b50919050565b604081526000614fd06040830185614c3a565b82810360208481019190915284518083528582019282019060005b818110156150105784516001600160a01b031683529383019391830191600101614feb565b5090979650505050505050565b6000821982111561503057615030614f2c565b500190565b600081600019048311821515161561504f5761504f614f2c565b500290565b6060815260006150676060830186614c3a565b82810360208401526150798186614c3a565b9050828103604084015261508d8185614c3a565b9695505050505050565b7f416363657373436f6e74726f6c3a206163636f756e74200000000000000000008152600083516150cf81601785016020880161482d565b7f206973206d697373696e6720726f6c6520000000000000000000000000000000601791840191820152835161510c81602884016020880161482d565b01602801949350505050565b60008161512757615127614f2c565b506000190190565b60006001600160a01b03808816835280871660208401525060a0604083015261515b60a0830186614c3a565b828103606084015261516d8186614c3a565b905082810360808401526151818185614859565b98975050505050505050565b60006020828403121561519f57600080fd5b8151612db7816145f6565b600060033d11156141b45760046000803e5060005160e01c90565b600060443d10156151d35790565b6040516003193d81016004833e81513d67ffffffffffffffff816024840111818411171561520357505050505090565b828501915081518181111561521b5750505050505090565b843d87010160208285010111156152355750505050505090565b6152446020828601018761463f565b509095945050505050565b60006001600160a01b03808816835280871660208401525084604083015283606083015260a0608083015261528760a0830184614859565b979650505050505050565b6000828210156152a4576152a4614f2c565b500390565b634e487b7160e01b600052602160045260246000fdfe97667070c54ef182b0f5858b034beac1b6f3089aa2d3188bb1e8929f4fa9b929a2646970667358221220960d1c2a65cc861c38938c4bd55734c4c3759bce8e03f5076efc2ddddb38606f64736f6c63430008090033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
0000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000c47656e65736973546f6b656e0000000000000000000000000000000000000000
-----Decoded View---------------
Arg [0] : newContractName (string): GenesisToken
-----Encoded View---------------
3 Constructor Arguments found :
Arg [0] : 0000000000000000000000000000000000000000000000000000000000000020
Arg [1] : 000000000000000000000000000000000000000000000000000000000000000c
Arg [2] : 47656e65736973546f6b656e0000000000000000000000000000000000000000
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.