ETH Price: $2,493.37 (-0.44%)

Token

POL (POL)
 

Overview

Max Total Supply

707 POL

Holders

379

Market

Volume (24H)

N/A

Min Price (24H)

N/A

Max Price (24H)

N/A
Filtered by Token Holder
xidianuniversity.eth
Balance
0 POL
0x22a8d39ef6b62b76a8eb8f16116f57ac061a4c97
Loading...
Loading
Loading...
Loading
Loading...
Loading

Click here to update the token information / general information
# Exchange Pair Price  24H Volume % Volume

Contract Source Code Verified (Exact Match)

Contract Name:
POL

Compiler Version
v0.8.18+commit.87f61d96

Optimization Enabled:
No with 200 runs

Other Settings:
default evmVersion
File 1 of 1 : PolMintFlatten.sol
// 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/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/IERC165.sol)

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC165 standard, as defined in the
 * https://eips.ethereum.org/EIPS/eip-165[EIP].
 *
 * Implementers can declare support of contract interfaces, which can then be
 * queried by others ({ERC165Checker}).
 *
 * For an implementation, see {ERC165}.
 */
interface IERC165 {
    /**
     * @dev Returns true if this contract implements the interface defined by
     * `interfaceId`. See the corresponding
     * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section]
     * to learn more about how these ids are created.
     *
     * This function call must use less than 30 000 gas.
     */
    function supportsInterface(bytes4 interfaceId) external view returns (bool);
}


// 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/utils/math/[email protected]

// OpenZeppelin Contracts (last updated v4.8.0) (utils/math/Math.sol)

pragma solidity ^0.8.0;

/**
 * @dev Standard math utilities missing in the Solidity language.
 */
library Math {
    enum Rounding {
        Down, // Toward negative infinity
        Up, // Toward infinity
        Zero // Toward zero
    }

    /**
     * @dev Returns the largest of two numbers.
     */
    function max(uint256 a, uint256 b) internal pure returns (uint256) {
        return a > b ? a : b;
    }

    /**
     * @dev Returns the smallest of two numbers.
     */
    function min(uint256 a, uint256 b) internal pure returns (uint256) {
        return a < b ? a : b;
    }

    /**
     * @dev Returns the average of two numbers. The result is rounded towards
     * zero.
     */
    function average(uint256 a, uint256 b) internal pure returns (uint256) {
        // (a + b) / 2 can overflow.
        return (a & b) + (a ^ b) / 2;
    }

    /**
     * @dev Returns the ceiling of the division of two numbers.
     *
     * This differs from standard division with `/` in that it rounds up instead
     * of rounding down.
     */
    function ceilDiv(uint256 a, uint256 b) internal pure returns (uint256) {
        // (a + b - 1) / b can overflow on addition, so we distribute.
        return a == 0 ? 0 : (a - 1) / b + 1;
    }

    /**
     * @notice Calculates floor(x * y / denominator) with full precision. Throws if result overflows a uint256 or denominator == 0
     * @dev Original credit to Remco Bloemen under MIT license (https://xn--2-umb.com/21/muldiv)
     * with further edits by Uniswap Labs also under MIT license.
     */
    function mulDiv(
        uint256 x,
        uint256 y,
        uint256 denominator
    ) internal pure returns (uint256 result) {
        unchecked {
            // 512-bit multiply [prod1 prod0] = x * y. Compute the product mod 2^256 and mod 2^256 - 1, then use
            // use the Chinese Remainder Theorem to reconstruct the 512 bit result. The result is stored in two 256
            // variables such that product = prod1 * 2^256 + prod0.
            uint256 prod0; // Least significant 256 bits of the product
            uint256 prod1; // Most significant 256 bits of the product
            assembly {
                let mm := mulmod(x, y, not(0))
                prod0 := mul(x, y)
                prod1 := sub(sub(mm, prod0), lt(mm, prod0))
            }

            // Handle non-overflow cases, 256 by 256 division.
            if (prod1 == 0) {
                return prod0 / denominator;
            }

            // Make sure the result is less than 2^256. Also prevents denominator == 0.
            require(denominator > prod1);

            ///////////////////////////////////////////////
            // 512 by 256 division.
            ///////////////////////////////////////////////

            // Make division exact by subtracting the remainder from [prod1 prod0].
            uint256 remainder;
            assembly {
                // Compute remainder using mulmod.
                remainder := mulmod(x, y, denominator)

                // Subtract 256 bit number from 512 bit number.
                prod1 := sub(prod1, gt(remainder, prod0))
                prod0 := sub(prod0, remainder)
            }

            // Factor powers of two out of denominator and compute largest power of two divisor of denominator. Always >= 1.
            // See https://cs.stackexchange.com/q/138556/92363.

            // Does not overflow because the denominator cannot be zero at this stage in the function.
            uint256 twos = denominator & (~denominator + 1);
            assembly {
                // Divide denominator by twos.
                denominator := div(denominator, twos)

                // Divide [prod1 prod0] by twos.
                prod0 := div(prod0, twos)

                // Flip twos such that it is 2^256 / twos. If twos is zero, then it becomes one.
                twos := add(div(sub(0, twos), twos), 1)
            }

            // Shift in bits from prod1 into prod0.
            prod0 |= prod1 * twos;

            // Invert denominator mod 2^256. Now that denominator is an odd number, it has an inverse modulo 2^256 such
            // that denominator * inv = 1 mod 2^256. Compute the inverse by starting with a seed that is correct for
            // four bits. That is, denominator * inv = 1 mod 2^4.
            uint256 inverse = (3 * denominator) ^ 2;

            // Use the Newton-Raphson iteration to improve the precision. Thanks to Hensel's lifting lemma, this also works
            // in modular arithmetic, doubling the correct bits in each step.
            inverse *= 2 - denominator * inverse; // inverse mod 2^8
            inverse *= 2 - denominator * inverse; // inverse mod 2^16
            inverse *= 2 - denominator * inverse; // inverse mod 2^32
            inverse *= 2 - denominator * inverse; // inverse mod 2^64
            inverse *= 2 - denominator * inverse; // inverse mod 2^128
            inverse *= 2 - denominator * inverse; // inverse mod 2^256

            // Because the division is now exact we can divide by multiplying with the modular inverse of denominator.
            // This will give us the correct result modulo 2^256. Since the preconditions guarantee that the outcome is
            // less than 2^256, this is the final result. We don't need to compute the high bits of the result and prod1
            // is no longer required.
            result = prod0 * inverse;
            return result;
        }
    }

    /**
     * @notice Calculates x * y / denominator with full precision, following the selected rounding direction.
     */
    function mulDiv(
        uint256 x,
        uint256 y,
        uint256 denominator,
        Rounding rounding
    ) internal pure returns (uint256) {
        uint256 result = mulDiv(x, y, denominator);
        if (rounding == Rounding.Up && mulmod(x, y, denominator) > 0) {
            result += 1;
        }
        return result;
    }

    /**
     * @dev Returns the square root of a number. If the number is not a perfect square, the value is rounded down.
     *
     * Inspired by Henry S. Warren, Jr.'s "Hacker's Delight" (Chapter 11).
     */
    function sqrt(uint256 a) internal pure returns (uint256) {
        if (a == 0) {
            return 0;
        }

        // For our first guess, we get the biggest power of 2 which is smaller than the square root of the target.
        //
        // We know that the "msb" (most significant bit) of our target number `a` is a power of 2 such that we have
        // `msb(a) <= a < 2*msb(a)`. This value can be written `msb(a)=2**k` with `k=log2(a)`.
        //
        // This can be rewritten `2**log2(a) <= a < 2**(log2(a) + 1)`
        // → `sqrt(2**k) <= sqrt(a) < sqrt(2**(k+1))`
        // → `2**(k/2) <= sqrt(a) < 2**((k+1)/2) <= 2**(k/2 + 1)`
        //
        // Consequently, `2**(log2(a) / 2)` is a good first approximation of `sqrt(a)` with at least 1 correct bit.
        uint256 result = 1 << (log2(a) >> 1);

        // At this point `result` is an estimation with one bit of precision. We know the true value is a uint128,
        // since it is the square root of a uint256. Newton's method converges quadratically (precision doubles at
        // every iteration). We thus need at most 7 iteration to turn our partial result with one bit of precision
        // into the expected uint128 result.
        unchecked {
            result = (result + a / result) >> 1;
            result = (result + a / result) >> 1;
            result = (result + a / result) >> 1;
            result = (result + a / result) >> 1;
            result = (result + a / result) >> 1;
            result = (result + a / result) >> 1;
            result = (result + a / result) >> 1;
            return min(result, a / result);
        }
    }

    /**
     * @notice Calculates sqrt(a), following the selected rounding direction.
     */
    function sqrt(uint256 a, Rounding rounding) internal pure returns (uint256) {
        unchecked {
            uint256 result = sqrt(a);
            return result + (rounding == Rounding.Up && result * result < a ? 1 : 0);
        }
    }

    /**
     * @dev Return the log in base 2, rounded down, of a positive value.
     * Returns 0 if given 0.
     */
    function log2(uint256 value) internal pure returns (uint256) {
        uint256 result = 0;
        unchecked {
            if (value >> 128 > 0) {
                value >>= 128;
                result += 128;
            }
            if (value >> 64 > 0) {
                value >>= 64;
                result += 64;
            }
            if (value >> 32 > 0) {
                value >>= 32;
                result += 32;
            }
            if (value >> 16 > 0) {
                value >>= 16;
                result += 16;
            }
            if (value >> 8 > 0) {
                value >>= 8;
                result += 8;
            }
            if (value >> 4 > 0) {
                value >>= 4;
                result += 4;
            }
            if (value >> 2 > 0) {
                value >>= 2;
                result += 2;
            }
            if (value >> 1 > 0) {
                result += 1;
            }
        }
        return result;
    }

    /**
     * @dev Return the log in base 2, following the selected rounding direction, of a positive value.
     * Returns 0 if given 0.
     */
    function log2(uint256 value, Rounding rounding) internal pure returns (uint256) {
        unchecked {
            uint256 result = log2(value);
            return result + (rounding == Rounding.Up && 1 << result < value ? 1 : 0);
        }
    }

    /**
     * @dev Return the log in base 10, rounded down, of a positive value.
     * Returns 0 if given 0.
     */
    function log10(uint256 value) internal pure returns (uint256) {
        uint256 result = 0;
        unchecked {
            if (value >= 10**64) {
                value /= 10**64;
                result += 64;
            }
            if (value >= 10**32) {
                value /= 10**32;
                result += 32;
            }
            if (value >= 10**16) {
                value /= 10**16;
                result += 16;
            }
            if (value >= 10**8) {
                value /= 10**8;
                result += 8;
            }
            if (value >= 10**4) {
                value /= 10**4;
                result += 4;
            }
            if (value >= 10**2) {
                value /= 10**2;
                result += 2;
            }
            if (value >= 10**1) {
                result += 1;
            }
        }
        return result;
    }

    /**
     * @dev Return the log in base 10, following the selected rounding direction, of a positive value.
     * Returns 0 if given 0.
     */
    function log10(uint256 value, Rounding rounding) internal pure returns (uint256) {
        unchecked {
            uint256 result = log10(value);
            return result + (rounding == Rounding.Up && 10**result < value ? 1 : 0);
        }
    }

    /**
     * @dev Return the log in base 256, rounded down, of a positive value.
     * Returns 0 if given 0.
     *
     * Adding one to the result gives the number of pairs of hex symbols needed to represent `value` as a hex string.
     */
    function log256(uint256 value) internal pure returns (uint256) {
        uint256 result = 0;
        unchecked {
            if (value >> 128 > 0) {
                value >>= 128;
                result += 16;
            }
            if (value >> 64 > 0) {
                value >>= 64;
                result += 8;
            }
            if (value >> 32 > 0) {
                value >>= 32;
                result += 4;
            }
            if (value >> 16 > 0) {
                value >>= 16;
                result += 2;
            }
            if (value >> 8 > 0) {
                result += 1;
            }
        }
        return result;
    }

    /**
     * @dev Return the log in base 10, following the selected rounding direction, of a positive value.
     * Returns 0 if given 0.
     */
    function log256(uint256 value, Rounding rounding) internal pure returns (uint256) {
        unchecked {
            uint256 result = log256(value);
            return result + (rounding == Rounding.Up && 1 << (result * 8) < value ? 1 : 0);
        }
    }
}


// File @openzeppelin/contracts/utils/[email protected]

// OpenZeppelin Contracts (last updated v4.8.0) (utils/Strings.sol)

pragma solidity ^0.8.0;

/**
 * @dev String operations.
 */
library Strings {
    bytes16 private constant _SYMBOLS = "0123456789abcdef";
    uint8 private constant _ADDRESS_LENGTH = 20;

    /**
     * @dev Converts a `uint256` to its ASCII `string` decimal representation.
     */
    function toString(uint256 value) internal pure returns (string memory) {
        unchecked {
            uint256 length = Math.log10(value) + 1;
            string memory buffer = new string(length);
            uint256 ptr;
            /// @solidity memory-safe-assembly
            assembly {
                ptr := add(buffer, add(32, length))
            }
            while (true) {
                ptr--;
                /// @solidity memory-safe-assembly
                assembly {
                    mstore8(ptr, byte(mod(value, 10), _SYMBOLS))
                }
                value /= 10;
                if (value == 0) break;
            }
            return buffer;
        }
    }

    /**
     * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation.
     */
    function toHexString(uint256 value) internal pure returns (string memory) {
        unchecked {
            return toHexString(value, Math.log256(value) + 1);
        }
    }

    /**
     * @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] = _SYMBOLS[value & 0xf];
            value >>= 4;
        }
        require(value == 0, "Strings: hex length insufficient");
        return string(buffer);
    }

    /**
     * @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal representation.
     */
    function toHexString(address addr) internal pure returns (string memory) {
        return toHexString(uint256(uint160(addr)), _ADDRESS_LENGTH);
    }
}


// File @openzeppelin/contracts/access/[email protected]

// OpenZeppelin Contracts (last updated v4.8.0) (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);
        _;
    }

    /**
     * @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 virtual override returns (bool) {
        return _roles[role].members[account];
    }

    /**
     * @dev Revert with a standard message if `_msgSender()` is missing `role`.
     * Overriding this function changes the behavior of the {onlyRole} modifier.
     *
     * Format of the revert message is described in {_checkRole}.
     *
     * _Available since v4.6._
     */
    function _checkRole(bytes32 role) internal view virtual {
        _checkRole(role, _msgSender());
    }

    /**
     * @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 virtual {
        if (!hasRole(role, account)) {
            revert(
                string(
                    abi.encodePacked(
                        "AccessControl: account ",
                        Strings.toHexString(account),
                        " 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 virtual 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.
     *
     * May emit a {RoleGranted} event.
     */
    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.
     *
     * May emit a {RoleRevoked} event.
     */
    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`.
     *
     * May emit a {RoleRevoked} event.
     */
    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.
     *
     * May emit a {RoleGranted} event.
     *
     * [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.
     *
     * May emit a {RoleGranted} event.
     */
    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.
     *
     * May emit a {RoleRevoked} event.
     */
    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/access/[email protected]

// OpenZeppelin Contracts v4.4.1 (access/IAccessControlEnumerable.sol)

pragma solidity ^0.8.0;

/**
 * @dev External interface of AccessControlEnumerable declared to support ERC165 detection.
 */
interface IAccessControlEnumerable is IAccessControl {
    /**
     * @dev Returns one of the accounts that have `role`. `index` must be a
     * value between 0 and {getRoleMemberCount}, non-inclusive.
     *
     * Role bearers are not sorted in any particular way, and their ordering may
     * change at any point.
     *
     * WARNING: When using {getRoleMember} and {getRoleMemberCount}, make sure
     * you perform all queries on the same block. See the following
     * https://forum.openzeppelin.com/t/iterating-over-elements-on-enumerableset-in-openzeppelin-contracts/2296[forum post]
     * for more information.
     */
    function getRoleMember(bytes32 role, uint256 index) external view returns (address);

    /**
     * @dev Returns the number of accounts that have `role`. Can be used
     * together with {getRoleMember} to enumerate all bearers of a role.
     */
    function getRoleMemberCount(bytes32 role) external view returns (uint256);
}


// File @openzeppelin/contracts/utils/structs/[email protected]

// OpenZeppelin Contracts (last updated v4.8.0) (utils/structs/EnumerableSet.sol)
// This file was procedurally generated from scripts/generate/templates/EnumerableSet.js.

pragma solidity ^0.8.0;

/**
 * @dev Library for managing
 * https://en.wikipedia.org/wiki/Set_(abstract_data_type)[sets] of primitive
 * types.
 *
 * Sets have the following properties:
 *
 * - Elements are added, removed, and checked for existence in constant time
 * (O(1)).
 * - Elements are enumerated in O(n). No guarantees are made on the ordering.
 *
 * ```
 * contract Example {
 *     // Add the library methods
 *     using EnumerableSet for EnumerableSet.AddressSet;
 *
 *     // Declare a set state variable
 *     EnumerableSet.AddressSet private mySet;
 * }
 * ```
 *
 * As of v3.3.0, sets of type `bytes32` (`Bytes32Set`), `address` (`AddressSet`)
 * and `uint256` (`UintSet`) are supported.
 *
 * [WARNING]
 * ====
 * Trying to delete such a structure from storage will likely result in data corruption, rendering the structure
 * unusable.
 * See https://github.com/ethereum/solidity/pull/11843[ethereum/solidity#11843] for more info.
 *
 * In order to clean an EnumerableSet, you can either remove all elements one by one or create a fresh instance using an
 * array of EnumerableSet.
 * ====
 */
library EnumerableSet {
    // To implement this library for multiple types with as little code
    // repetition as possible, we write it in terms of a generic Set type with
    // bytes32 values.
    // The Set implementation uses private functions, and user-facing
    // implementations (such as AddressSet) are just wrappers around the
    // underlying Set.
    // This means that we can only create new EnumerableSets for types that fit
    // in bytes32.

    struct Set {
        // Storage of set values
        bytes32[] _values;
        // Position of the value in the `values` array, plus 1 because index 0
        // means a value is not in the set.
        mapping(bytes32 => uint256) _indexes;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function _add(Set storage set, bytes32 value) private returns (bool) {
        if (!_contains(set, value)) {
            set._values.push(value);
            // The value is stored at length-1, but we add 1 to all indexes
            // and use 0 as a sentinel value
            set._indexes[value] = set._values.length;
            return true;
        } else {
            return false;
        }
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function _remove(Set storage set, bytes32 value) private returns (bool) {
        // We read and store the value's index to prevent multiple reads from the same storage slot
        uint256 valueIndex = set._indexes[value];

        if (valueIndex != 0) {
            // Equivalent to contains(set, value)
            // To delete an element from the _values array in O(1), we swap the element to delete with the last one in
            // the array, and then remove the last element (sometimes called as 'swap and pop').
            // This modifies the order of the array, as noted in {at}.

            uint256 toDeleteIndex = valueIndex - 1;
            uint256 lastIndex = set._values.length - 1;

            if (lastIndex != toDeleteIndex) {
                bytes32 lastValue = set._values[lastIndex];

                // Move the last value to the index where the value to delete is
                set._values[toDeleteIndex] = lastValue;
                // Update the index for the moved value
                set._indexes[lastValue] = valueIndex; // Replace lastValue's index to valueIndex
            }

            // Delete the slot where the moved value was stored
            set._values.pop();

            // Delete the index for the deleted slot
            delete set._indexes[value];

            return true;
        } else {
            return false;
        }
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function _contains(Set storage set, bytes32 value) private view returns (bool) {
        return set._indexes[value] != 0;
    }

    /**
     * @dev Returns the number of values on the set. O(1).
     */
    function _length(Set storage set) private view returns (uint256) {
        return set._values.length;
    }

    /**
     * @dev Returns the value stored at position `index` in the set. O(1).
     *
     * Note that there are no guarantees on the ordering of values inside the
     * array, and it may change when more values are added or removed.
     *
     * Requirements:
     *
     * - `index` must be strictly less than {length}.
     */
    function _at(Set storage set, uint256 index) private view returns (bytes32) {
        return set._values[index];
    }

    /**
     * @dev Return the entire set in an array
     *
     * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
     * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
     * this function has an unbounded cost, and using it as part of a state-changing function may render the function
     * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
     */
    function _values(Set storage set) private view returns (bytes32[] memory) {
        return set._values;
    }

    // Bytes32Set

    struct Bytes32Set {
        Set _inner;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function add(Bytes32Set storage set, bytes32 value) internal returns (bool) {
        return _add(set._inner, value);
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function remove(Bytes32Set storage set, bytes32 value) internal returns (bool) {
        return _remove(set._inner, value);
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function contains(Bytes32Set storage set, bytes32 value) internal view returns (bool) {
        return _contains(set._inner, value);
    }

    /**
     * @dev Returns the number of values in the set. O(1).
     */
    function length(Bytes32Set storage set) internal view returns (uint256) {
        return _length(set._inner);
    }

    /**
     * @dev Returns the value stored at position `index` in the set. O(1).
     *
     * Note that there are no guarantees on the ordering of values inside the
     * array, and it may change when more values are added or removed.
     *
     * Requirements:
     *
     * - `index` must be strictly less than {length}.
     */
    function at(Bytes32Set storage set, uint256 index) internal view returns (bytes32) {
        return _at(set._inner, index);
    }

    /**
     * @dev Return the entire set in an array
     *
     * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
     * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
     * this function has an unbounded cost, and using it as part of a state-changing function may render the function
     * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
     */
    function values(Bytes32Set storage set) internal view returns (bytes32[] memory) {
        bytes32[] memory store = _values(set._inner);
        bytes32[] memory result;

        /// @solidity memory-safe-assembly
        assembly {
            result := store
        }

        return result;
    }

    // AddressSet

    struct AddressSet {
        Set _inner;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function add(AddressSet storage set, address value) internal returns (bool) {
        return _add(set._inner, bytes32(uint256(uint160(value))));
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function remove(AddressSet storage set, address value) internal returns (bool) {
        return _remove(set._inner, bytes32(uint256(uint160(value))));
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function contains(AddressSet storage set, address value) internal view returns (bool) {
        return _contains(set._inner, bytes32(uint256(uint160(value))));
    }

    /**
     * @dev Returns the number of values in the set. O(1).
     */
    function length(AddressSet storage set) internal view returns (uint256) {
        return _length(set._inner);
    }

    /**
     * @dev Returns the value stored at position `index` in the set. O(1).
     *
     * Note that there are no guarantees on the ordering of values inside the
     * array, and it may change when more values are added or removed.
     *
     * Requirements:
     *
     * - `index` must be strictly less than {length}.
     */
    function at(AddressSet storage set, uint256 index) internal view returns (address) {
        return address(uint160(uint256(_at(set._inner, index))));
    }

    /**
     * @dev Return the entire set in an array
     *
     * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
     * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
     * this function has an unbounded cost, and using it as part of a state-changing function may render the function
     * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
     */
    function values(AddressSet storage set) internal view returns (address[] memory) {
        bytes32[] memory store = _values(set._inner);
        address[] memory result;

        /// @solidity memory-safe-assembly
        assembly {
            result := store
        }

        return result;
    }

    // UintSet

    struct UintSet {
        Set _inner;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function add(UintSet storage set, uint256 value) internal returns (bool) {
        return _add(set._inner, bytes32(value));
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function remove(UintSet storage set, uint256 value) internal returns (bool) {
        return _remove(set._inner, bytes32(value));
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function contains(UintSet storage set, uint256 value) internal view returns (bool) {
        return _contains(set._inner, bytes32(value));
    }

    /**
     * @dev Returns the number of values in the set. O(1).
     */
    function length(UintSet storage set) internal view returns (uint256) {
        return _length(set._inner);
    }

    /**
     * @dev Returns the value stored at position `index` in the set. O(1).
     *
     * Note that there are no guarantees on the ordering of values inside the
     * array, and it may change when more values are added or removed.
     *
     * Requirements:
     *
     * - `index` must be strictly less than {length}.
     */
    function at(UintSet storage set, uint256 index) internal view returns (uint256) {
        return uint256(_at(set._inner, index));
    }

    /**
     * @dev Return the entire set in an array
     *
     * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
     * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
     * this function has an unbounded cost, and using it as part of a state-changing function may render the function
     * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
     */
    function values(UintSet storage set) internal view returns (uint256[] memory) {
        bytes32[] memory store = _values(set._inner);
        uint256[] memory result;

        /// @solidity memory-safe-assembly
        assembly {
            result := store
        }

        return result;
    }
}


// File @openzeppelin/contracts/access/[email protected]

// OpenZeppelin Contracts (last updated v4.5.0) (access/AccessControlEnumerable.sol)

pragma solidity ^0.8.0;



/**
 * @dev Extension of {AccessControl} that allows enumerating the members of each role.
 */
abstract contract AccessControlEnumerable is IAccessControlEnumerable, AccessControl {
    using EnumerableSet for EnumerableSet.AddressSet;

    mapping(bytes32 => EnumerableSet.AddressSet) private _roleMembers;

    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
        return interfaceId == type(IAccessControlEnumerable).interfaceId || super.supportsInterface(interfaceId);
    }

    /**
     * @dev Returns one of the accounts that have `role`. `index` must be a
     * value between 0 and {getRoleMemberCount}, non-inclusive.
     *
     * Role bearers are not sorted in any particular way, and their ordering may
     * change at any point.
     *
     * WARNING: When using {getRoleMember} and {getRoleMemberCount}, make sure
     * you perform all queries on the same block. See the following
     * https://forum.openzeppelin.com/t/iterating-over-elements-on-enumerableset-in-openzeppelin-contracts/2296[forum post]
     * for more information.
     */
    function getRoleMember(bytes32 role, uint256 index) public view virtual override returns (address) {
        return _roleMembers[role].at(index);
    }

    /**
     * @dev Returns the number of accounts that have `role`. Can be used
     * together with {getRoleMember} to enumerate all bearers of a role.
     */
    function getRoleMemberCount(bytes32 role) public view virtual override returns (uint256) {
        return _roleMembers[role].length();
    }

    /**
     * @dev Overload {_grantRole} to track enumerable memberships
     */
    function _grantRole(bytes32 role, address account) internal virtual override {
        super._grantRole(role, account);
        _roleMembers[role].add(account);
    }

    /**
     * @dev Overload {_revokeRole} to track enumerable memberships
     */
    function _revokeRole(bytes32 role, address account) internal virtual override {
        super._revokeRole(role, account);
        _roleMembers[role].remove(account);
    }
}


// File @openzeppelin/contracts/access/[email protected]

// OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol)

pragma solidity ^0.8.0;

/**
 * @dev Contract module which provides a basic access control mechanism, where
 * there is an account (an owner) that can be granted exclusive access to
 * specific functions.
 *
 * By default, the owner account will be the one that deploys the contract. This
 * can later be changed with {transferOwnership}.
 *
 * This module is used through inheritance. It will make available the modifier
 * `onlyOwner`, which can be applied to your functions to restrict their use to
 * the owner.
 */
abstract contract Ownable is Context {
    address private _owner;

    event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);

    /**
     * @dev Initializes the contract setting the deployer as the initial owner.
     */
    constructor() {
        _transferOwnership(_msgSender());
    }

    /**
     * @dev Throws if called by any account other than the owner.
     */
    modifier onlyOwner() {
        _checkOwner();
        _;
    }

    /**
     * @dev Returns the address of the current owner.
     */
    function owner() public view virtual returns (address) {
        return _owner;
    }

    /**
     * @dev Throws if the sender is not the owner.
     */
    function _checkOwner() internal view virtual {
        require(owner() == _msgSender(), "Ownable: caller is not the owner");
    }

    /**
     * @dev Leaves the contract without owner. It will not be possible to call
     * `onlyOwner` functions anymore. Can only be called by the current owner.
     *
     * NOTE: Renouncing ownership will leave the contract without an owner,
     * thereby removing any functionality that is only available to the owner.
     */
    function renounceOwnership() public virtual onlyOwner {
        _transferOwnership(address(0));
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Can only be called by the current owner.
     */
    function transferOwnership(address newOwner) public virtual onlyOwner {
        require(newOwner != address(0), "Ownable: new owner is the zero address");
        _transferOwnership(newOwner);
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Internal function without access restriction.
     */
    function _transferOwnership(address newOwner) internal virtual {
        address oldOwner = _owner;
        _owner = newOwner;
        emit OwnershipTransferred(oldOwner, newOwner);
    }
}


// File @openzeppelin/contracts/interfaces/[email protected]

// OpenZeppelin Contracts (last updated v4.6.0) (interfaces/IERC2981.sol)

pragma solidity ^0.8.0;

/**
 * @dev Interface for the NFT Royalty Standard.
 *
 * A standardized way to retrieve royalty payment information for non-fungible tokens (NFTs) to enable universal
 * support for royalty payments across all NFT marketplaces and ecosystem participants.
 *
 * _Available since v4.5._
 */
interface IERC2981 is IERC165 {
    /**
     * @dev Returns how much royalty is owed and to whom, based on a sale price that may be denominated in any unit of
     * exchange. The royalty amount is denominated and should be paid in that same unit of exchange.
     */
    function royaltyInfo(uint256 tokenId, uint256 salePrice)
        external
        view
        returns (address receiver, uint256 royaltyAmount);
}


// File @openzeppelin/contracts/security/[email protected]

// OpenZeppelin Contracts (last updated v4.7.0) (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 Modifier to make a function callable only when the contract is not paused.
     *
     * Requirements:
     *
     * - The contract must not be paused.
     */
    modifier whenNotPaused() {
        _requireNotPaused();
        _;
    }

    /**
     * @dev Modifier to make a function callable only when the contract is paused.
     *
     * Requirements:
     *
     * - The contract must be paused.
     */
    modifier whenPaused() {
        _requirePaused();
        _;
    }

    /**
     * @dev Returns true if the contract is paused, and false otherwise.
     */
    function paused() public view virtual returns (bool) {
        return _paused;
    }

    /**
     * @dev Throws if the contract is paused.
     */
    function _requireNotPaused() internal view virtual {
        require(!paused(), "Pausable: paused");
    }

    /**
     * @dev Throws if the contract is not paused.
     */
    function _requirePaused() internal view virtual {
        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/common/[email protected]

// OpenZeppelin Contracts (last updated v4.7.0) (token/common/ERC2981.sol)

pragma solidity ^0.8.0;


/**
 * @dev Implementation of the NFT Royalty Standard, a standardized way to retrieve royalty payment information.
 *
 * Royalty information can be specified globally for all token ids via {_setDefaultRoyalty}, and/or individually for
 * specific token ids via {_setTokenRoyalty}. The latter takes precedence over the first.
 *
 * Royalty is specified as a fraction of sale price. {_feeDenominator} is overridable but defaults to 10000, meaning the
 * fee is specified in basis points by default.
 *
 * IMPORTANT: ERC-2981 only specifies a way to signal royalty information and does not enforce its payment. See
 * https://eips.ethereum.org/EIPS/eip-2981#optional-royalty-payments[Rationale] in the EIP. Marketplaces are expected to
 * voluntarily pay royalties together with sales, but note that this standard is not yet widely supported.
 *
 * _Available since v4.5._
 */
abstract contract ERC2981 is IERC2981, ERC165 {
    struct RoyaltyInfo {
        address receiver;
        uint96 royaltyFraction;
    }

    RoyaltyInfo private _defaultRoyaltyInfo;
    mapping(uint256 => RoyaltyInfo) private _tokenRoyaltyInfo;

    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override(IERC165, ERC165) returns (bool) {
        return interfaceId == type(IERC2981).interfaceId || super.supportsInterface(interfaceId);
    }

    /**
     * @inheritdoc IERC2981
     */
    function royaltyInfo(uint256 _tokenId, uint256 _salePrice) public view virtual override returns (address, uint256) {
        RoyaltyInfo memory royalty = _tokenRoyaltyInfo[_tokenId];

        if (royalty.receiver == address(0)) {
            royalty = _defaultRoyaltyInfo;
        }

        uint256 royaltyAmount = (_salePrice * royalty.royaltyFraction) / _feeDenominator();

        return (royalty.receiver, royaltyAmount);
    }

    /**
     * @dev The denominator with which to interpret the fee set in {_setTokenRoyalty} and {_setDefaultRoyalty} as a
     * fraction of the sale price. Defaults to 10000 so fees are expressed in basis points, but may be customized by an
     * override.
     */
    function _feeDenominator() internal pure virtual returns (uint96) {
        return 10000;
    }

    /**
     * @dev Sets the royalty information that all ids in this contract will default to.
     *
     * Requirements:
     *
     * - `receiver` cannot be the zero address.
     * - `feeNumerator` cannot be greater than the fee denominator.
     */
    function _setDefaultRoyalty(address receiver, uint96 feeNumerator) internal virtual {
        require(feeNumerator <= _feeDenominator(), "ERC2981: royalty fee will exceed salePrice");
        require(receiver != address(0), "ERC2981: invalid receiver");

        _defaultRoyaltyInfo = RoyaltyInfo(receiver, feeNumerator);
    }

    /**
     * @dev Removes default royalty information.
     */
    function _deleteDefaultRoyalty() internal virtual {
        delete _defaultRoyaltyInfo;
    }

    /**
     * @dev Sets the royalty information for a specific token id, overriding the global default.
     *
     * Requirements:
     *
     * - `receiver` cannot be the zero address.
     * - `feeNumerator` cannot be greater than the fee denominator.
     */
    function _setTokenRoyalty(
        uint256 tokenId,
        address receiver,
        uint96 feeNumerator
    ) internal virtual {
        require(feeNumerator <= _feeDenominator(), "ERC2981: royalty fee will exceed salePrice");
        require(receiver != address(0), "ERC2981: Invalid parameters");

        _tokenRoyaltyInfo[tokenId] = RoyaltyInfo(receiver, feeNumerator);
    }

    /**
     * @dev Resets royalty information for the token id back to the global default.
     */
    function _resetTokenRoyalty(uint256 tokenId) internal virtual {
        delete _tokenRoyaltyInfo[tokenId];
    }
}


// File @openzeppelin/contracts/token/ERC721/[email protected]

// OpenZeppelin Contracts (last updated v4.8.0) (token/ERC721/IERC721.sol)

pragma solidity ^0.8.0;

/**
 * @dev Required interface of an ERC721 compliant contract.
 */
interface IERC721 is IERC165 {
    /**
     * @dev Emitted when `tokenId` token is transferred from `from` to `to`.
     */
    event Transfer(address indexed from, address indexed to, uint256 indexed tokenId);

    /**
     * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token.
     */
    event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId);

    /**
     * @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets.
     */
    event ApprovalForAll(address indexed owner, address indexed operator, bool approved);

    /**
     * @dev Returns the number of tokens in ``owner``'s account.
     */
    function balanceOf(address owner) external view returns (uint256 balance);

    /**
     * @dev Returns the owner of the `tokenId` token.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function ownerOf(uint256 tokenId) external view returns (address owner);

    /**
     * @dev Safely transfers `tokenId` token from `from` to `to`.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must exist and be owned by `from`.
     * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId,
        bytes calldata data
    ) external;

    /**
     * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients
     * are aware of the ERC721 protocol to prevent tokens from being forever locked.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must exist and be owned by `from`.
     * - If the caller is not `from`, it must have been allowed to move this token by either {approve} or {setApprovalForAll}.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) external;

    /**
     * @dev Transfers `tokenId` token from `from` to `to`.
     *
     * WARNING: Note that the caller is responsible to confirm that the recipient is capable of receiving ERC721
     * or else they may be permanently lost. Usage of {safeTransferFrom} prevents loss, though the caller must
     * understand this adds an external call which potentially creates a reentrancy vulnerability.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must be owned by `from`.
     * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
     *
     * Emits a {Transfer} event.
     */
    function transferFrom(
        address from,
        address to,
        uint256 tokenId
    ) external;

    /**
     * @dev Gives permission to `to` to transfer `tokenId` token to another account.
     * The approval is cleared when the token is transferred.
     *
     * Only a single account can be approved at a time, so approving the zero address clears previous approvals.
     *
     * Requirements:
     *
     * - The caller must own the token or be an approved operator.
     * - `tokenId` must exist.
     *
     * Emits an {Approval} event.
     */
    function approve(address to, uint256 tokenId) external;

    /**
     * @dev Approve or remove `operator` as an operator for the caller.
     * Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller.
     *
     * Requirements:
     *
     * - The `operator` cannot be the caller.
     *
     * Emits an {ApprovalForAll} event.
     */
    function setApprovalForAll(address operator, bool _approved) external;

    /**
     * @dev Returns the account approved for `tokenId` token.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function getApproved(uint256 tokenId) external view returns (address operator);

    /**
     * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`.
     *
     * See {setApprovalForAll}
     */
    function isApprovedForAll(address owner, address operator) external view returns (bool);
}


// File @openzeppelin/contracts/token/ERC721/extensions/[email protected]

// OpenZeppelin Contracts v4.4.1 (token/ERC721/extensions/IERC721Metadata.sol)

pragma solidity ^0.8.0;

/**
 * @title ERC-721 Non-Fungible Token Standard, optional metadata extension
 * @dev See https://eips.ethereum.org/EIPS/eip-721
 */
interface IERC721Metadata is IERC721 {
    /**
     * @dev Returns the token collection name.
     */
    function name() external view returns (string memory);

    /**
     * @dev Returns the token collection symbol.
     */
    function symbol() external view returns (string memory);

    /**
     * @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token.
     */
    function tokenURI(uint256 tokenId) external view returns (string memory);
}


// File @openzeppelin/contracts/token/ERC721/[email protected]

// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC721/IERC721Receiver.sol)

pragma solidity ^0.8.0;

/**
 * @title ERC721 token receiver interface
 * @dev Interface for any contract that wants to support safeTransfers
 * from ERC721 asset contracts.
 */
interface IERC721Receiver {
    /**
     * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom}
     * by `operator` from `from`, this function is called.
     *
     * It must return its Solidity selector to confirm the token transfer.
     * If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted.
     *
     * The selector can be obtained in Solidity with `IERC721Receiver.onERC721Received.selector`.
     */
    function onERC721Received(
        address operator,
        address from,
        uint256 tokenId,
        bytes calldata data
    ) external returns (bytes4);
}


// File @openzeppelin/contracts/utils/[email protected]

// OpenZeppelin Contracts (last updated v4.8.0) (utils/Address.sol)

pragma solidity ^0.8.1;

/**
 * @dev Collection of functions related to the address type
 */
library Address {
    /**
     * @dev Returns true if `account` is a contract.
     *
     * [IMPORTANT]
     * ====
     * It is unsafe to assume that an address for which this function returns
     * false is an externally-owned account (EOA) and not a contract.
     *
     * Among others, `isContract` will return false for the following
     * types of addresses:
     *
     *  - an externally-owned account
     *  - a contract in construction
     *  - an address where a contract will be created
     *  - an address where a contract lived, but was destroyed
     * ====
     *
     * [IMPORTANT]
     * ====
     * You shouldn't rely on `isContract` to protect against flash loan attacks!
     *
     * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets
     * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract
     * constructor.
     * ====
     */
    function isContract(address account) internal view returns (bool) {
        // This method relies on extcodesize/address.code.length, which returns 0
        // for contracts in construction, since the code is only stored at the end
        // of the constructor execution.

        return account.code.length > 0;
    }

    /**
     * @dev Replacement for Solidity's `transfer`: sends `amount` wei to
     * `recipient`, forwarding all available gas and reverting on errors.
     *
     * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost
     * of certain opcodes, possibly making contracts go over the 2300 gas limit
     * imposed by `transfer`, making them unable to receive funds via
     * `transfer`. {sendValue} removes this limitation.
     *
     * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].
     *
     * IMPORTANT: because control is transferred to `recipient`, care must be
     * taken to not create reentrancy vulnerabilities. Consider using
     * {ReentrancyGuard} or the
     * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].
     */
    function sendValue(address payable recipient, uint256 amount) internal {
        require(address(this).balance >= amount, "Address: insufficient balance");

        (bool success, ) = recipient.call{value: amount}("");
        require(success, "Address: unable to send value, recipient may have reverted");
    }

    /**
     * @dev Performs a Solidity function call using a low level `call`. A
     * plain `call` is an unsafe replacement for a function call: use this
     * function instead.
     *
     * If `target` reverts with a revert reason, it is bubbled up by this
     * function (like regular Solidity function calls).
     *
     * Returns the raw returned data. To convert to the expected return value,
     * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].
     *
     * Requirements:
     *
     * - `target` must be a contract.
     * - calling `target` with `data` must not revert.
     *
     * _Available since v3.1._
     */
    function functionCall(address target, bytes memory data) internal returns (bytes memory) {
        return functionCallWithValue(target, data, 0, "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");
        (bool success, bytes memory returndata) = target.call{value: value}(data);
        return verifyCallResultFromTarget(target, 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) {
        (bool success, bytes memory returndata) = target.staticcall(data);
        return verifyCallResultFromTarget(target, 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) {
        (bool success, bytes memory returndata) = target.delegatecall(data);
        return verifyCallResultFromTarget(target, success, returndata, errorMessage);
    }

    /**
     * @dev Tool to verify that a low level call to smart-contract was successful, and revert (either by bubbling
     * the revert reason or using the provided one) in case of unsuccessful call or if target was not a contract.
     *
     * _Available since v4.8._
     */
    function verifyCallResultFromTarget(
        address target,
        bool success,
        bytes memory returndata,
        string memory errorMessage
    ) internal view returns (bytes memory) {
        if (success) {
            if (returndata.length == 0) {
                // only check isContract if the call was successful and the return data is empty
                // otherwise we already know that it was a contract
                require(isContract(target), "Address: call to non-contract");
            }
            return returndata;
        } else {
            _revert(returndata, errorMessage);
        }
    }

    /**
     * @dev Tool to verify that a low level call was successful, and revert if it wasn't, either by bubbling the
     * revert reason or 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 {
            _revert(returndata, errorMessage);
        }
    }

    function _revert(bytes memory returndata, string memory errorMessage) private pure {
        // 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
            /// @solidity memory-safe-assembly
            assembly {
                let returndata_size := mload(returndata)
                revert(add(32, returndata), returndata_size)
            }
        } else {
            revert(errorMessage);
        }
    }
}


// File @openzeppelin/contracts/token/ERC721/[email protected]

// OpenZeppelin Contracts (last updated v4.8.2) (token/ERC721/ERC721.sol)

pragma solidity ^0.8.0;







/**
 * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including
 * the Metadata extension, but not including the Enumerable extension, which is available separately as
 * {ERC721Enumerable}.
 */
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata {
    using Address for address;
    using Strings for uint256;

    // Token name
    string private _name;

    // Token symbol
    string private _symbol;

    // Mapping from token ID to owner address
    mapping(uint256 => address) private _owners;

    // Mapping owner address to token count
    mapping(address => uint256) private _balances;

    // Mapping from token ID to approved address
    mapping(uint256 => address) private _tokenApprovals;

    // Mapping from owner to operator approvals
    mapping(address => mapping(address => bool)) private _operatorApprovals;

    /**
     * @dev Initializes the contract by setting a `name` and a `symbol` to the token collection.
     */
    constructor(string memory name_, string memory symbol_) {
        _name = name_;
        _symbol = symbol_;
    }

    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) {
        return
            interfaceId == type(IERC721).interfaceId ||
            interfaceId == type(IERC721Metadata).interfaceId ||
            super.supportsInterface(interfaceId);
    }

    /**
     * @dev See {IERC721-balanceOf}.
     */
    function balanceOf(address owner) public view virtual override returns (uint256) {
        require(owner != address(0), "ERC721: address zero is not a valid owner");
        return _balances[owner];
    }

    /**
     * @dev See {IERC721-ownerOf}.
     */
    function ownerOf(uint256 tokenId) public view virtual override returns (address) {
        address owner = _ownerOf(tokenId);
        require(owner != address(0), "ERC721: invalid token ID");
        return owner;
    }

    /**
     * @dev See {IERC721Metadata-name}.
     */
    function name() public view virtual override returns (string memory) {
        return _name;
    }

    /**
     * @dev See {IERC721Metadata-symbol}.
     */
    function symbol() public view virtual override returns (string memory) {
        return _symbol;
    }

    /**
     * @dev See {IERC721Metadata-tokenURI}.
     */
    function tokenURI(uint256 tokenId) public view virtual override returns (string memory) {
        _requireMinted(tokenId);

        string memory baseURI = _baseURI();
        return bytes(baseURI).length > 0 ? string(abi.encodePacked(baseURI, tokenId.toString())) : "";
    }

    /**
     * @dev Base URI for computing {tokenURI}. If set, the resulting URI for each
     * token will be the concatenation of the `baseURI` and the `tokenId`. Empty
     * by default, can be overridden in child contracts.
     */
    function _baseURI() internal view virtual returns (string memory) {
        return "";
    }

    /**
     * @dev See {IERC721-approve}.
     */
    function approve(address to, uint256 tokenId) public virtual override {
        address owner = ERC721.ownerOf(tokenId);
        require(to != owner, "ERC721: approval to current owner");

        require(
            _msgSender() == owner || isApprovedForAll(owner, _msgSender()),
            "ERC721: approve caller is not token owner or approved for all"
        );

        _approve(to, tokenId);
    }

    /**
     * @dev See {IERC721-getApproved}.
     */
    function getApproved(uint256 tokenId) public view virtual override returns (address) {
        _requireMinted(tokenId);

        return _tokenApprovals[tokenId];
    }

    /**
     * @dev See {IERC721-setApprovalForAll}.
     */
    function setApprovalForAll(address operator, bool approved) public virtual override {
        _setApprovalForAll(_msgSender(), operator, approved);
    }

    /**
     * @dev See {IERC721-isApprovedForAll}.
     */
    function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) {
        return _operatorApprovals[owner][operator];
    }

    /**
     * @dev See {IERC721-transferFrom}.
     */
    function transferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public virtual override {
        //solhint-disable-next-line max-line-length
        require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: caller is not token owner or approved");

        _transfer(from, to, tokenId);
    }

    /**
     * @dev See {IERC721-safeTransferFrom}.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public virtual override {
        safeTransferFrom(from, to, tokenId, "");
    }

    /**
     * @dev See {IERC721-safeTransferFrom}.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId,
        bytes memory data
    ) public virtual override {
        require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: caller is not token owner or approved");
        _safeTransfer(from, to, tokenId, data);
    }

    /**
     * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients
     * are aware of the ERC721 protocol to prevent tokens from being forever locked.
     *
     * `data` is additional data, it has no specified format and it is sent in call to `to`.
     *
     * This internal function is equivalent to {safeTransferFrom}, and can be used to e.g.
     * implement alternative mechanisms to perform token transfer, such as signature-based.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must exist and be owned by `from`.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function _safeTransfer(
        address from,
        address to,
        uint256 tokenId,
        bytes memory data
    ) internal virtual {
        _transfer(from, to, tokenId);
        require(_checkOnERC721Received(from, to, tokenId, data), "ERC721: transfer to non ERC721Receiver implementer");
    }

    /**
     * @dev Returns the owner of the `tokenId`. Does NOT revert if token doesn't exist
     */
    function _ownerOf(uint256 tokenId) internal view virtual returns (address) {
        return _owners[tokenId];
    }

    /**
     * @dev Returns whether `tokenId` exists.
     *
     * Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}.
     *
     * Tokens start existing when they are minted (`_mint`),
     * and stop existing when they are burned (`_burn`).
     */
    function _exists(uint256 tokenId) internal view virtual returns (bool) {
        return _ownerOf(tokenId) != address(0);
    }

    /**
     * @dev Returns whether `spender` is allowed to manage `tokenId`.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) {
        address owner = ERC721.ownerOf(tokenId);
        return (spender == owner || isApprovedForAll(owner, spender) || getApproved(tokenId) == spender);
    }

    /**
     * @dev Safely mints `tokenId` and transfers it to `to`.
     *
     * Requirements:
     *
     * - `tokenId` must not exist.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function _safeMint(address to, uint256 tokenId) internal virtual {
        _safeMint(to, tokenId, "");
    }

    /**
     * @dev Same as {xref-ERC721-_safeMint-address-uint256-}[`_safeMint`], with an additional `data` parameter which is
     * forwarded in {IERC721Receiver-onERC721Received} to contract recipients.
     */
    function _safeMint(
        address to,
        uint256 tokenId,
        bytes memory data
    ) internal virtual {
        _mint(to, tokenId);
        require(
            _checkOnERC721Received(address(0), to, tokenId, data),
            "ERC721: transfer to non ERC721Receiver implementer"
        );
    }

    /**
     * @dev Mints `tokenId` and transfers it to `to`.
     *
     * WARNING: Usage of this method is discouraged, use {_safeMint} whenever possible
     *
     * Requirements:
     *
     * - `tokenId` must not exist.
     * - `to` cannot be the zero address.
     *
     * Emits a {Transfer} event.
     */
    function _mint(address to, uint256 tokenId) internal virtual {
        require(to != address(0), "ERC721: mint to the zero address");
        require(!_exists(tokenId), "ERC721: token already minted");

        _beforeTokenTransfer(address(0), to, tokenId, 1);

        // Check that tokenId was not minted by `_beforeTokenTransfer` hook
        require(!_exists(tokenId), "ERC721: token already minted");

        unchecked {
            // Will not overflow unless all 2**256 token ids are minted to the same owner.
            // Given that tokens are minted one by one, it is impossible in practice that
            // this ever happens. Might change if we allow batch minting.
            // The ERC fails to describe this case.
            _balances[to] += 1;
        }

        _owners[tokenId] = to;

        emit Transfer(address(0), to, tokenId);

        _afterTokenTransfer(address(0), to, tokenId, 1);
    }

    /**
     * @dev Destroys `tokenId`.
     * The approval is cleared when the token is burned.
     * This is an internal function that does not check if the sender is authorized to operate on the token.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     *
     * Emits a {Transfer} event.
     */
    function _burn(uint256 tokenId) internal virtual {
        address owner = ERC721.ownerOf(tokenId);

        _beforeTokenTransfer(owner, address(0), tokenId, 1);

        // Update ownership in case tokenId was transferred by `_beforeTokenTransfer` hook
        owner = ERC721.ownerOf(tokenId);

        // Clear approvals
        delete _tokenApprovals[tokenId];

        unchecked {
            // Cannot overflow, as that would require more tokens to be burned/transferred
            // out than the owner initially received through minting and transferring in.
            _balances[owner] -= 1;
        }
        delete _owners[tokenId];

        emit Transfer(owner, address(0), tokenId);

        _afterTokenTransfer(owner, address(0), tokenId, 1);
    }

    /**
     * @dev Transfers `tokenId` from `from` to `to`.
     *  As opposed to {transferFrom}, this imposes no restrictions on msg.sender.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - `tokenId` token must be owned by `from`.
     *
     * Emits a {Transfer} event.
     */
    function _transfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual {
        require(ERC721.ownerOf(tokenId) == from, "ERC721: transfer from incorrect owner");
        require(to != address(0), "ERC721: transfer to the zero address");

        _beforeTokenTransfer(from, to, tokenId, 1);

        // Check that tokenId was not transferred by `_beforeTokenTransfer` hook
        require(ERC721.ownerOf(tokenId) == from, "ERC721: transfer from incorrect owner");

        // Clear approvals from the previous owner
        delete _tokenApprovals[tokenId];

        unchecked {
            // `_balances[from]` cannot overflow for the same reason as described in `_burn`:
            // `from`'s balance is the number of token held, which is at least one before the current
            // transfer.
            // `_balances[to]` could overflow in the conditions described in `_mint`. That would require
            // all 2**256 token ids to be minted, which in practice is impossible.
            _balances[from] -= 1;
            _balances[to] += 1;
        }
        _owners[tokenId] = to;

        emit Transfer(from, to, tokenId);

        _afterTokenTransfer(from, to, tokenId, 1);
    }

    /**
     * @dev Approve `to` to operate on `tokenId`
     *
     * Emits an {Approval} event.
     */
    function _approve(address to, uint256 tokenId) internal virtual {
        _tokenApprovals[tokenId] = to;
        emit Approval(ERC721.ownerOf(tokenId), to, tokenId);
    }

    /**
     * @dev Approve `operator` to operate on all of `owner` tokens
     *
     * Emits an {ApprovalForAll} event.
     */
    function _setApprovalForAll(
        address owner,
        address operator,
        bool approved
    ) internal virtual {
        require(owner != operator, "ERC721: approve to caller");
        _operatorApprovals[owner][operator] = approved;
        emit ApprovalForAll(owner, operator, approved);
    }

    /**
     * @dev Reverts if the `tokenId` has not been minted yet.
     */
    function _requireMinted(uint256 tokenId) internal view virtual {
        require(_exists(tokenId), "ERC721: invalid token ID");
    }

    /**
     * @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target address.
     * The call is not executed if the target address is not a contract.
     *
     * @param from address representing the previous owner of the given token ID
     * @param to target address that will receive the tokens
     * @param tokenId uint256 ID of the token to be transferred
     * @param data bytes optional data to send along with the call
     * @return bool whether the call correctly returned the expected magic value
     */
    function _checkOnERC721Received(
        address from,
        address to,
        uint256 tokenId,
        bytes memory data
    ) private returns (bool) {
        if (to.isContract()) {
            try IERC721Receiver(to).onERC721Received(_msgSender(), from, tokenId, data) returns (bytes4 retval) {
                return retval == IERC721Receiver.onERC721Received.selector;
            } catch (bytes memory reason) {
                if (reason.length == 0) {
                    revert("ERC721: transfer to non ERC721Receiver implementer");
                } else {
                    /// @solidity memory-safe-assembly
                    assembly {
                        revert(add(32, reason), mload(reason))
                    }
                }
            }
        } else {
            return true;
        }
    }

    /**
     * @dev Hook that is called before any token transfer. This includes minting and burning. If {ERC721Consecutive} is
     * used, the hook may be called as part of a consecutive (batch) mint, as indicated by `batchSize` greater than 1.
     *
     * Calling conditions:
     *
     * - When `from` and `to` are both non-zero, ``from``'s tokens will be transferred to `to`.
     * - When `from` is zero, the tokens will be minted for `to`.
     * - When `to` is zero, ``from``'s tokens will be burned.
     * - `from` and `to` are never both zero.
     * - `batchSize` is non-zero.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _beforeTokenTransfer(
        address from,
        address to,
        uint256 firstTokenId,
        uint256 batchSize
    ) internal virtual {}

    /**
     * @dev Hook that is called after any token transfer. This includes minting and burning. If {ERC721Consecutive} is
     * used, the hook may be called as part of a consecutive (batch) mint, as indicated by `batchSize` greater than 1.
     *
     * Calling conditions:
     *
     * - When `from` and `to` are both non-zero, ``from``'s tokens were transferred to `to`.
     * - When `from` is zero, the tokens were minted for `to`.
     * - When `to` is zero, ``from``'s tokens were burned.
     * - `from` and `to` are never both zero.
     * - `batchSize` is non-zero.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _afterTokenTransfer(
        address from,
        address to,
        uint256 firstTokenId,
        uint256 batchSize
    ) internal virtual {}

    /**
     * @dev Unsafe write access to the balances, used by extensions that "mint" tokens using an {ownerOf} override.
     *
     * WARNING: Anyone calling this MUST ensure that the balances remain consistent with the ownership. The invariant
     * being that for any address `a` the value returned by `balanceOf(a)` must be equal to the number of tokens such
     * that `ownerOf(tokenId)` is `a`.
     */
    // solhint-disable-next-line func-name-mixedcase
    function __unsafe_increaseBalance(address account, uint256 amount) internal {
        _balances[account] += amount;
    }
}


// File @openzeppelin/contracts/token/ERC721/extensions/[email protected]

// OpenZeppelin Contracts (last updated v4.5.0) (token/ERC721/extensions/IERC721Enumerable.sol)

pragma solidity ^0.8.0;

/**
 * @title ERC-721 Non-Fungible Token Standard, optional enumeration extension
 * @dev See https://eips.ethereum.org/EIPS/eip-721
 */
interface IERC721Enumerable is IERC721 {
    /**
     * @dev Returns the total amount of tokens stored by the contract.
     */
    function totalSupply() external view returns (uint256);

    /**
     * @dev Returns a token ID owned by `owner` at a given `index` of its token list.
     * Use along with {balanceOf} to enumerate all of ``owner``'s tokens.
     */
    function tokenOfOwnerByIndex(address owner, uint256 index) external view returns (uint256);

    /**
     * @dev Returns a token ID at a given `index` of all the tokens stored by the contract.
     * Use along with {totalSupply} to enumerate all tokens.
     */
    function tokenByIndex(uint256 index) external view returns (uint256);
}


// File @openzeppelin/contracts/token/ERC721/extensions/[email protected]

// OpenZeppelin Contracts (last updated v4.8.0) (token/ERC721/extensions/ERC721Enumerable.sol)

pragma solidity ^0.8.0;


/**
 * @dev This implements an optional extension of {ERC721} defined in the EIP that adds
 * enumerability of all the token ids in the contract as well as all token ids owned by each
 * account.
 */
abstract contract ERC721Enumerable is ERC721, IERC721Enumerable {
    // Mapping from owner to list of owned token IDs
    mapping(address => mapping(uint256 => uint256)) private _ownedTokens;

    // Mapping from token ID to index of the owner tokens list
    mapping(uint256 => uint256) private _ownedTokensIndex;

    // Array with all token ids, used for enumeration
    uint256[] private _allTokens;

    // Mapping from token id to position in the allTokens array
    mapping(uint256 => uint256) private _allTokensIndex;

    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override(IERC165, ERC721) returns (bool) {
        return interfaceId == type(IERC721Enumerable).interfaceId || super.supportsInterface(interfaceId);
    }

    /**
     * @dev See {IERC721Enumerable-tokenOfOwnerByIndex}.
     */
    function tokenOfOwnerByIndex(address owner, uint256 index) public view virtual override returns (uint256) {
        require(index < ERC721.balanceOf(owner), "ERC721Enumerable: owner index out of bounds");
        return _ownedTokens[owner][index];
    }

    /**
     * @dev See {IERC721Enumerable-totalSupply}.
     */
    function totalSupply() public view virtual override returns (uint256) {
        return _allTokens.length;
    }

    /**
     * @dev See {IERC721Enumerable-tokenByIndex}.
     */
    function tokenByIndex(uint256 index) public view virtual override returns (uint256) {
        require(index < ERC721Enumerable.totalSupply(), "ERC721Enumerable: global index out of bounds");
        return _allTokens[index];
    }

    /**
     * @dev See {ERC721-_beforeTokenTransfer}.
     */
    function _beforeTokenTransfer(
        address from,
        address to,
        uint256 firstTokenId,
        uint256 batchSize
    ) internal virtual override {
        super._beforeTokenTransfer(from, to, firstTokenId, batchSize);

        if (batchSize > 1) {
            // Will only trigger during construction. Batch transferring (minting) is not available afterwards.
            revert("ERC721Enumerable: consecutive transfers not supported");
        }

        uint256 tokenId = firstTokenId;

        if (from == address(0)) {
            _addTokenToAllTokensEnumeration(tokenId);
        } else if (from != to) {
            _removeTokenFromOwnerEnumeration(from, tokenId);
        }
        if (to == address(0)) {
            _removeTokenFromAllTokensEnumeration(tokenId);
        } else if (to != from) {
            _addTokenToOwnerEnumeration(to, tokenId);
        }
    }

    /**
     * @dev Private function to add a token to this extension's ownership-tracking data structures.
     * @param to address representing the new owner of the given token ID
     * @param tokenId uint256 ID of the token to be added to the tokens list of the given address
     */
    function _addTokenToOwnerEnumeration(address to, uint256 tokenId) private {
        uint256 length = ERC721.balanceOf(to);
        _ownedTokens[to][length] = tokenId;
        _ownedTokensIndex[tokenId] = length;
    }

    /**
     * @dev Private function to add a token to this extension's token tracking data structures.
     * @param tokenId uint256 ID of the token to be added to the tokens list
     */
    function _addTokenToAllTokensEnumeration(uint256 tokenId) private {
        _allTokensIndex[tokenId] = _allTokens.length;
        _allTokens.push(tokenId);
    }

    /**
     * @dev Private function to remove a token from this extension's ownership-tracking data structures. Note that
     * while the token is not assigned a new owner, the `_ownedTokensIndex` mapping is _not_ updated: this allows for
     * gas optimizations e.g. when performing a transfer operation (avoiding double writes).
     * This has O(1) time complexity, but alters the order of the _ownedTokens array.
     * @param from address representing the previous owner of the given token ID
     * @param tokenId uint256 ID of the token to be removed from the tokens list of the given address
     */
    function _removeTokenFromOwnerEnumeration(address from, uint256 tokenId) private {
        // To prevent a gap in from's tokens array, we store the last token in the index of the token to delete, and
        // then delete the last slot (swap and pop).

        uint256 lastTokenIndex = ERC721.balanceOf(from) - 1;
        uint256 tokenIndex = _ownedTokensIndex[tokenId];

        // When the token to delete is the last token, the swap operation is unnecessary
        if (tokenIndex != lastTokenIndex) {
            uint256 lastTokenId = _ownedTokens[from][lastTokenIndex];

            _ownedTokens[from][tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token
            _ownedTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index
        }

        // This also deletes the contents at the last position of the array
        delete _ownedTokensIndex[tokenId];
        delete _ownedTokens[from][lastTokenIndex];
    }

    /**
     * @dev Private function to remove a token from this extension's token tracking data structures.
     * This has O(1) time complexity, but alters the order of the _allTokens array.
     * @param tokenId uint256 ID of the token to be removed from the tokens list
     */
    function _removeTokenFromAllTokensEnumeration(uint256 tokenId) private {
        // To prevent a gap in the tokens array, we store the last token in the index of the token to delete, and
        // then delete the last slot (swap and pop).

        uint256 lastTokenIndex = _allTokens.length - 1;
        uint256 tokenIndex = _allTokensIndex[tokenId];

        // When the token to delete is the last token, the swap operation is unnecessary. However, since this occurs so
        // rarely (when the last minted token is burnt) that we still do the swap here to avoid the gas cost of adding
        // an 'if' statement (like in _removeTokenFromOwnerEnumeration)
        uint256 lastTokenId = _allTokens[lastTokenIndex];

        _allTokens[tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token
        _allTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index

        // This also deletes the contents at the last position of the array
        delete _allTokensIndex[tokenId];
        _allTokens.pop();
    }
}


// File @openzeppelin/contracts/utils/[email protected]

// OpenZeppelin Contracts (last updated v4.7.0) (utils/Base64.sol)

pragma solidity ^0.8.0;

/**
 * @dev Provides a set of functions to operate with Base64 strings.
 *
 * _Available since v4.5._
 */
library Base64 {
    /**
     * @dev Base64 Encoding/Decoding Table
     */
    string internal constant _TABLE = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";

    /**
     * @dev Converts a `bytes` to its Bytes64 `string` representation.
     */
    function encode(bytes memory data) internal pure returns (string memory) {
        /**
         * Inspired by Brecht Devos (Brechtpd) implementation - MIT licence
         * https://github.com/Brechtpd/base64/blob/e78d9fd951e7b0977ddca77d92dc85183770daf4/base64.sol
         */
        if (data.length == 0) return "";

        // Loads the table into memory
        string memory table = _TABLE;

        // Encoding takes 3 bytes chunks of binary data from `bytes` data parameter
        // and split into 4 numbers of 6 bits.
        // The final Base64 length should be `bytes` data length multiplied by 4/3 rounded up
        // - `data.length + 2`  -> Round up
        // - `/ 3`              -> Number of 3-bytes chunks
        // - `4 *`              -> 4 characters for each chunk
        string memory result = new string(4 * ((data.length + 2) / 3));

        /// @solidity memory-safe-assembly
        assembly {
            // Prepare the lookup table (skip the first "length" byte)
            let tablePtr := add(table, 1)

            // Prepare result pointer, jump over length
            let resultPtr := add(result, 32)

            // Run over the input, 3 bytes at a time
            for {
                let dataPtr := data
                let endPtr := add(data, mload(data))
            } lt(dataPtr, endPtr) {

            } {
                // Advance 3 bytes
                dataPtr := add(dataPtr, 3)
                let input := mload(dataPtr)

                // To write each character, shift the 3 bytes (18 bits) chunk
                // 4 times in blocks of 6 bits for each character (18, 12, 6, 0)
                // and apply logical AND with 0x3F which is the number of
                // the previous character in the ASCII table prior to the Base64 Table
                // The result is then added to the table to get the character to write,
                // and finally write it in the result pointer but with a left shift
                // of 256 (1 byte) - 8 (1 ASCII char) = 248 bits

                mstore8(resultPtr, mload(add(tablePtr, and(shr(18, input), 0x3F))))
                resultPtr := add(resultPtr, 1) // Advance

                mstore8(resultPtr, mload(add(tablePtr, and(shr(12, input), 0x3F))))
                resultPtr := add(resultPtr, 1) // Advance

                mstore8(resultPtr, mload(add(tablePtr, and(shr(6, input), 0x3F))))
                resultPtr := add(resultPtr, 1) // Advance

                mstore8(resultPtr, mload(add(tablePtr, and(input, 0x3F))))
                resultPtr := add(resultPtr, 1) // Advance
            }

            // When data `bytes` is not exactly 3 bytes long
            // it is padded with `=` characters at the end
            switch mod(mload(data), 3)
            case 1 {
                mstore8(sub(resultPtr, 1), 0x3d)
                mstore8(sub(resultPtr, 2), 0x3d)
            }
            case 2 {
                mstore8(sub(resultPtr, 1), 0x3d)
            }
        }

        return result;
    }
}


// File contracts/Renderer.sol

pragma solidity ^0.8.18;

contract Renderer {
    using Strings for uint256;

    string[] public positiveColors = [
        "%23f5e9a3",
        "%23e9cd2f2",
        "%23f6f2ee",
        "%23D7C2B2",
        "%23f7edf4",
        "%23BFA498",
        "%23be5b9b",
        "%23f7edf4",
        "%23d4d1fa",
        "%234030e8",
        "%23ffc107",
        "%23ff9800",
        "%23ff5722",
        "%23e85b30"
    ];

    string[] public negativeColors = [
        "%23A17E64",
        "%23005365",
        "%237C96A3",
        "%236B8486",
        "%23465D5B",
        "%23B7BCC3",
        "%23989992",
        "%23757766",
        "%23391AD4",
        "%230098C2",
        "%23007392",
        "%237E3A00",
        "%2300025B",
        "%235D44E6",
        "%23602CEE"
    ];

    string[] public neutralColors = [
        "%23B4AB87",
        "%23A09A7F",
        "%23827957",
        "%23F2F1EF",
        "%23E7E7E6",
        "%23D8D7D3",
        "%23F2C19B",
        "%23E7AF8F",
        "%23D89269"
    ];

    string[] public positiveBackground = [
        "white",
        "%23c0d8c7",
        "%23ccb671",
        "%23691df5"
    ];

    string[] public neutralBackground = [
        "%23E7E7E6",
        "%238E8F65",
        "%23D5C7B9",
        "%23f4cccc",
        "%23fff2cc",
        "%23a1a48d",
        "%23e1f3f4",
        "%23e6e1f4"
    ];

    string[] public negativeBackground = [
        "%231A1A1A",
        "%23788EFF",
        "%2316537e",
        "%23202c36"
    ];

    enum Palette {
        POSITIVE,
        NEGATIVE,
        NEUTRAL
    }

    uint256 public constant DECIMALS = 3;

    function getPrimaryPalette(
        uint256 positive,
        uint256 negative,
        uint256 neutral
    ) internal pure returns (Palette) {
        Palette ret = Palette.POSITIVE;
        uint256 max = positive;

        if (negative > max) {
            ret = Palette.NEGATIVE;
            max = negative;
        }

        if (neutral > max) {
            ret = Palette.NEUTRAL;
        }

        return ret;
    }

    function randomColorsCount(
        uint256 positive,
        uint256 negative,
        uint256 neutral,
        Palette pal
    ) public view returns (uint256) {
        //Palette pal = getPrimaryPalette(positive, negative, neutral);

        uint256 nbOfColors = 0;

        if (pal == Palette.POSITIVE) {
            uint256 coef = (positiveColors.length - 3) * 2700;
            nbOfColors = ((coef * positive) / 10**DECIMALS + 3000 - coef / 3);
        } else if (pal == Palette.NEGATIVE) {
            uint256 coef = (negativeColors.length - 3) * 2700;
            nbOfColors = ((coef * negative) / 10**DECIMALS + 3000 - coef / 3);
        } else {
            uint256 coef = (neutralColors.length - 3) * 2700;
            nbOfColors = (neutralColors.length *
                10**DECIMALS +
                (coef / 3) -
                ((coef * neutral) / 10**DECIMALS));
        }

        nbOfColors = nbOfColors / 10**DECIMALS;

        if (nbOfColors < 3) {
            nbOfColors = 3;
        }

        return nbOfColors;
    }

    function getColors(
        uint256 positive,
        uint256 negative,
        uint256 neutral,
        uint256 seed
    )
        public
        view
        returns (
            string[] memory,
            string memory,
            string memory
        )
    {
        Palette pal = getPrimaryPalette(positive, negative, neutral);

        uint256 nbOfColors = randomColorsCount(
            positive,
            negative,
            neutral,
            pal
        );

        string[] memory cubeColors = new string[](nbOfColors);

        uint256 rand_acc = uint256(keccak256(abi.encodePacked(seed)));

        for (uint256 i = 0; i < nbOfColors; i++) {
            if (pal == Palette.POSITIVE) {
                cubeColors[i] = positiveColors[
                    rand_acc % positiveColors.length
                ];
            } else if (pal == Palette.NEGATIVE) {
                cubeColors[i] = negativeColors[
                    rand_acc % negativeColors.length
                ];
            } else {
                cubeColors[i] = neutralColors[rand_acc % neutralColors.length];
            }

            rand_acc = uint256(keccak256(abi.encodePacked(rand_acc)));
        }

        string memory backgroundColor = "";
        string memory borderColor = "";

        if (pal == Palette.POSITIVE) {
            backgroundColor = positiveBackground[
                rand_acc % positiveBackground.length
            ];
            rand_acc = uint256(keccak256(abi.encodePacked(rand_acc)));
            borderColor = positiveBackground[
                rand_acc % positiveBackground.length
            ];
        } else if (pal == Palette.NEGATIVE) {
            backgroundColor = negativeBackground[
                rand_acc % negativeBackground.length
            ];
            rand_acc = uint256(keccak256(abi.encodePacked(rand_acc)));
            borderColor = negativeBackground[
                rand_acc % negativeBackground.length
            ];
        } else {
            backgroundColor = neutralBackground[
                rand_acc % neutralBackground.length
            ];
            rand_acc = uint256(keccak256(abi.encodePacked(rand_acc)));
            borderColor = neutralBackground[
                rand_acc % neutralBackground.length
            ];
        }

        return (cubeColors, backgroundColor, borderColor);
    }

    function drawPreview(
        uint256 positive,
        uint256 negative,
        uint256 neutral,
        uint256 seed
    ) public view returns (string memory) {
        string[] memory colors;
        string memory backgroundColor;
        string memory borderColor;
        (colors, backgroundColor, borderColor) = getColors(
            positive,
            negative,
            neutral,
            seed
        );

        return
            string(
                abi.encodePacked(
                    "data:image/svg+xml,%3csvg style='background-color:",
                    backgroundColor,
                    "%3b' width='400' height='400' xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22 id='svg'%3e%3cpolygon points='286.60%2c150.00 286.60%2c250.00 200.00%2c300.00 200.00%2c200.00' fill='",
                    colors[0],
                    "' stroke='%2345484a' stroke-width='1'%3e%3c/polygon%3e%3cpolygon points='200.00%2c300.00 113.40%2c250.00 113.40%2c150.00 200.00%2c200.00' fill='",
                    colors[1],
                    "' stroke='%2345484a' stroke-width='1'%3e%3c/polygon%3e%3cpolygon points='113.40%2c150.00 200.00%2c100.00 286.60%2c150.00 200.00%2c200.00' fill='",
                    colors[2],
                    "' stroke='%2345484a' stroke-width='1'%3e%3c/polygon%3e%3cpolygon points='286.60%2c150.00 286.60%2c250.00 200.00%2c300.00 113.40%2c250.00 113.40%2c150.00 200.00%2c100.00' fill='transparent' stroke='black' stroke-width='2'%3e%3c/polygon%3e%3crect x='0' y='0' width='400' height='400' stroke='",
                    borderColor,
                    "' stroke-width='40' fill='transparent'%3e%3c/rect%3e%3crect x='20' y='20' width='360' height='360' stroke='black' stroke-width='3' fill='transparent'%3e%3c/rect%3e%3crect x='0' y='0' width='400' height='400' stroke='black' stroke-width='3' fill='transparent'%3e%3c/rect%3e%3c/svg%3e"
                )
            );
    }

    function drawHtml(
        uint256 positive,
        uint256 negative,
        uint256 neutral,
        uint256 seed
    ) public view returns (string memory) {

                string[] memory colors;
        string memory backgroundColor;
        string memory borderColor;
        (colors, backgroundColor, borderColor) = getColors(
            positive,
            negative,
            neutral,
            seed
        );

        string memory colorsArray = "[";


        for(uint i = 0; i < colors.length;i++){
            colorsArray = string.concat(colorsArray, "'", colors[i], "',");
        }

        colorsArray = string.concat(colorsArray, "];");


        return
            string(
                abi.encodePacked(
                    "data:text/html,%3Chtml%3E%3Cbody%3E%3Cdiv%20style%3D'height%3A%20100%25%3B%20display%3A%20flex%3B%20align-items%3Acenter%3B%20justiy-content%3Acenter%3B'%3E%3Csvg%20id%3D%22svg%22%20width%3D'100%25'%20viewBox%3D'-200%20-200%201500%20500'%20style%3D'aspect-ratio%3A%203%2F1%3B'%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3C%2Fsvg%3E%3C%2Fdiv%3E%3Cscript%3Efunction%20aleaPRNG()%7Breturn%20e%3DArray.prototype.slice.call(arguments)%2Cu%3Dnew%20Uint32Array(3)%2Cc%3D%22%22%2Co.fract53%3Dfunction()%7Breturn%20o()%2B11102230246251565e-32*(2097152*o()%7C0)%7D%2Co.int32%3Dfunction()%7Breturn%204294967296*o()%7D%2Co.cycle%3Dfunction(t)%7B(t%3Dvoid%200%3D%3D%3Dt%3F1%3A%2Bt)%3C1%26%26(t%3D1)%3Bfor(var%20e%3D0%3Be%3Ct%3Be%2B%2B)o()%7D%2Co.range%3Dfunction()%7Bvar%20t%2Ce%3D1%3D%3D%3Darguments.length%3Farguments%5Bt%3D0%5D%3A(t%3Darguments%5B0%5D%2Carguments%5B1%5D)%3Breturn%20arguments%5B1%5D%3Carguments%5B0%5D%26%26(t%3Darguments%5B1%5D%2Ce%3Darguments%5B0%5D)%2Cr(t)%26%26r(e)%3FMath.floor(o()*(e-t%2B1))%2Bt%3Ao()*(e-t)%2Bt%7D%2Co.restart%3Dfunction()%7Bt(n)%7D%2Co.seed%3Dfunction()%7Bt(Array.prototype.slice.call(arguments))%7D%2Co.version%3Dfunction()%7Breturn%22aleaPRNG%201.1.0%22%7D%2Co.versions%3Dfunction()%7Breturn%22aleaPRNG%201.1.0%2C%20%22%2Bc%7D%2C0%3D%3D%3De.length%26%26(window.crypto.getRandomValues(u)%2Ce%3D%5Bu%5B0%5D%2Cu%5B1%5D%2Cu%5B2%5D%5D)%2Ct(n%3De)%2Co%3Bfunction%20t(t)%7Bn%3D4022871197%2Cr.version%3D%22Mash%200.9%22%3Bvar%20n%2Ce%3Dr%3Bfunction%20r(t)%7Bfor(var%20e%3D0%2Cr%3D(t%3Dt.toString()).length%3Be%3Cr%3Be%2B%2B)%7Bvar%20o%3D.02519603282416938*(n%2B%3Dt.charCodeAt(e))%3Bn%3D(o%3D(o-%3Dn%3Do%3E%3E%3E0)*n)%3E%3E%3E0%2Cn%2B%3D4294967296*(o-%3Dn)%7Dreturn%202.3283064365386963e-10*(n%3E%3E%3E0)%7Da%3De(%22%20%22)%2Ci%3De(%22%20%22)%2Cl%3De(%22%20%22)%2Cs%3D1%3Bfor(var%20o%3D0%3Bo%3Ct.length%3Bo%2B%2B)(a-%3De(t%5Bo%5D))%3C0%26%26(a%2B%3D1)%2C(i-%3De(t%5Bo%5D))%3C0%26%26(i%2B%3D1)%2C(l-%3De(t%5Bo%5D))%3C0%26%26(l%2B%3D1)%3Bc%3De.version%7Dfunction%20r(t)%7Breturn%20parseInt(t%2C10)%3D%3D%3Dt%7Dfunction%20o()%7Bvar%20t%3D2091639*a%2B2.3283064365386963e-10*s%3Breturn%20a%3Di%2Ci%3Dl%2Cl%3Dt-(s%3D0%7Ct)%7Dvar%20e%2Ca%2Ci%2Cl%2Cs%2Cn%2Cu%2Cc%7Dconst%20slope%3D1.57735%3Blet%20selectedPalette%3D%5B%5D%2CbackgroundColor%3D%22%22%2CborderColor%3D%22%22%3Bfunction%20rotate(t%2Ce%2Cr%2Co%2Cn)%7Bvar%20n%3DMath.PI%2F180*n%2Ca%3DMath.cos(n)%2Cn%3DMath.sin(n)%3Breturn%5Ba*(r-t)%2Bn*(o-e)%2Bt%2Ca*(o-e)-n*(r-t)%2Be%5D%7Dfunction%20line_f(t%2Ce)%7Breturn%20y%3D(slope-1)*t%2Be%7Dfunction%20getPrimaryPalette(t)%7Blet%20e%3D%22negative%22%2Cr%3Dt%5B0%5D%3Breturn%20r%3C%3Dt%5B1%5D%26%26(e%3D%22neutral%22%2Cr%3Dt%5B1%5D)%2Ce%3Dr%3C%3Dt%5B2%5D%3F%22positive%22%3Ae%7Dfunction%20setBackground(t)%7Bsvg.setAttribute(%22style%22%2C%60background-color%3A%20%24%7BbackgroundColor%7D%3B%60)%7Dfunction%20setBorder(t)%7Blet%20e%3Dsvg.getAttribute(%22viewBox%22)%3Be%3De%3Fe.split(%22%20%22)%3A%5B0%2C0%2C1500%2C500%5D%3Bvar%20r%3Ddocument.createElementNS(%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%2C%22rect%22)%3Br.setAttribute(%22x%22%2Ce%5B0%5D)%2Cr.setAttribute(%22y%22%2Ce%5B1%5D)%2Cr.setAttribute(%22width%22%2Ce%5B2%5D)%2Cr.setAttribute(%22height%22%2Ce%5B3%5D)%2Cr.setAttribute(%22stroke%22%2CborderColor)%2Cr.setAttribute(%22stroke-width%22%2C%225%25%22)%2Cr.setAttribute(%22fill%22%2C%22transparent%22)%2Csvg.appendChild(r)%2C(r%3Ddocument.createElementNS(%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%2C%22rect%22)).setAttribute(%22x%22%2CNumber(e%5B0%5D)%2Be%5B2%5D%2F1500*28)%2Cr.setAttribute(%22y%22%2CNumber(e%5B1%5D)%2Be%5B3%5D%2F500*28)%2Cr.setAttribute(%22width%22%2CNumber(e%5B2%5D)-e%5B2%5D%2F1500*55)%2Cr.setAttribute(%22height%22%2CNumber(e%5B3%5D)-e%5B3%5D%2F500*55)%2Cr.setAttribute(%22stroke%22%2C%22%23000000%22)%2Cr.setAttribute(%22stroke-width%22%2C%220.25%25%22)%2Cr.setAttribute(%22fill%22%2C%22transparent%22)%2Csvg.appendChild(r)%2C(r%3Ddocument.createElementNS(%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%2C%22rect%22)).setAttribute(%22x%22%2Ce%5B0%5D)%2Cr.setAttribute(%22y%22%2Ce%5B1%5D)%2Cr.setAttribute(%22width%22%2Ce%5B2%5D)%2Cr.setAttribute(%22height%22%2Ce%5B3%5D)%2Cr.setAttribute(%22stroke%22%2C%22%23000000%22)%2Cr.setAttribute(%22stroke-width%22%2C%220.3%25%22)%2Cr.setAttribute(%22fill%22%2C%22transparent%22)%2Csvg.appendChild(r)%7Dfunction%20generateWeightedArray(e%2Ct)%7Bvar%20r%3D%5B%5D%2Co%3De.length%2Cn%3DMath.floor(100*t%2F(100%2Fo))%2Ca%3D50%2FMath.max(n%2Co-n)%2Ci%3D%5B%5D%3Bfor(let%20t%3D0%3Bt%3Cn%3B%2B%2Bt)var%20l%3DMath.floor(Math.abs(50-(n-t)*a))%2Cl%3D(i.push(l)%2CArray(l).fill(e%5Bt%5D))%2Cr%3Dr.concat(l)%3Bfor(let%20t%3Dn%3Bt%3Co%3B%2B%2Bt)%7Bvar%20s%3DMath.floor(50-(t-n)*a)%2Cs%3D(i.push(s)%2CArray(s).fill(e%5Bt%5D))%3Br%3Dr.concat(s)%7Dreturn%20r%7Dfunction%20getWeightedOption(t%2Ce)%7Bt%3DgenerateWeightedArray(t%2Ce)%3Breturn%20t%5BMath.floor(random()*t.length)%5D%7Dfunction%20getColors(t)%7BselectedPalette%3D%5B%5D%3Bvar%20e%3DgetPrimaryPalette(t)%2Ct%3DMath.max(...t)%3Blet%20r%3D(colors%5Be%5D.length-3)%2F(.7-.33)%2Co%3D3-.33*r%3B%22neutral%22%3D%3D%3De%26%26(r%3D-r%2Co%3Dcolors%5Be%5D.length-.33*r)%3Bvar%20n%3DMath.max(Math.min(Math.floor(r*t%2Bo)%2Ccolors%5Be%5D.length)%2C3)%2Ca%3D%5B...colors%5Be%5D%5D%3Bfor(let%20t%3D0%3Bt%3Cn%3Bt%2B%2B)%7Bvar%20i%3DMath.floor(random()*a.length)%3BselectedPalette.push(a%5Bi%5D)%2Ca.splice(i%2C1)%7D%7Dfunction%20randomColor()%7Breturn%20selectedPalette%5BMath.floor(random()*selectedPalette.length)%5D%7Dfunction%20drawCube(t%2Ce%2Cr)%7Bfor(var%20o%3D2*Math.PI%2F6%2Cn%3D%5B%5D%2Ca%3D0%3Ba%3C6%3Ba%2B%2B)p_x%3Dt%2Br*Math.cos(o*a)%2Cp_y%3De%2Br*Math.sin(o*a)%2Cpoint%3Drotate(t%2Ce%2Cp_x%2Cp_y%2C30)%2Cn.push(point)%3Bvar%20i%3D%5Bn%5B5%5D%5B0%5D%2C2*(n%5B0%5D%5B1%5D-n%5B5%5D%5B1%5D)%2Bn%5B5%5D%5B1%5D%5D%2Cl%3Dn.slice(0%2C3)%3Bl.push(i)%3Blet%20s%3D%5B%5D%3Bvar%20u%3Dn.slice(2%2C5)%3Bu.push(i)%3Blet%20c%3D%5B%5D%3Bvar%20h%3Dn.slice(-2)%3Bh.push(n%5B0%5D)%2Ch.push(i)%3Blet%20g%3D%5B%5D%3Bfor(a%3D0%3Ba%3C4%3Ba%2B%2B)s.push(l%5Ba%5D%5B0%5D%2B%22%2C%22%2Bl%5Ba%5D%5B1%5D)%2Cc.push(u%5Ba%5D%5B0%5D%2B%22%2C%22%2Bu%5Ba%5D%5B1%5D)%2Cg.push(h%5Ba%5D%5B0%5D%2B%22%2C%22%2Bh%5Ba%5D%5B1%5D)%3Bs%3Ds.join(%22%20%22)%2Cc%3Dc.join(%22%20%22)%2Cg%3Dg.join(%22%20%22)%3Blet%20d%3D%5B%5D%3Bfor(a%3D0%3Ba%3C6%3Ba%2B%2B)d.push(n%5Ba%5D%5B0%5D%2B%22%2C%22%2Bn%5Ba%5D%5B1%5D)%3Bvar%20i%3DrandomColor()%2Cp%3DrandomColor()%2Cf%3DrandomColor()%2Cv%3D(d%3Dd.join(%22%20%22)%2Cdocument.createElementNS(%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%2C%22polygon%22))%2Ci%3D(v.setAttribute(%22points%22%2Cl)%2Cv.setAttribute(%22fill%22%2Ci)%2Cdocument.createElementNS(%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%2C%22polygon%22))%2Cf%3D(i.setAttribute(%22points%22%2Cu)%2Ci.setAttribute(%22fill%22%2Cf)%2Cdocument.createElementNS(%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%2C%22polygon%22))%2Cp%3D(f.setAttribute(%22points%22%2Ch)%2Cf.setAttribute(%22fill%22%2Cp)%2Cdocument.createElementNS(%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%2C%22polygon%22))%3Bp.setAttribute(%22points%22%2Cd)%2Cp.setAttribute(%22fill%22%2C%22transparent%22)%2Cp.setAttribute(%22stroke%22%2C%22black%22)%2Cp.setAttribute(%22stroke-width%22%2C%222%22)%2Csvg.appendChild(v)%2Csvg.appendChild(i)%2Csvg.appendChild(f)%2Csvg.appendChild(p)%7Dasync%20function%20draw(e)%7Bsvg.innerHTML%3D%22%22%3Bvar%20r%3De.some(t%3D%3E.5%3C%3Dt)%3Blet%20o%3D-500%2Cn%3D600%2Ca%3D-400%2Ci%3D600%3Bvar%20t%3DgetPrimaryPalette(e)%3Blet%20l%3D100%2Cs%3Dl%3B%22positive%22%3D%3Dt%3F(s%3Dl*(1%2Be%5B2%5D)%2Cl%3D50)%3A%22negative%22%3D%3Dt%26%26(s%3Dl*(1%2Be%5B0%5D)%2Cl%3D150)%3Bfor(let%20t%3D0%3Bt%3C30%3B%2B%2Bt)%7Bvar%20u%3DMath.floor(random()*l)%2B5%2Cc%3DMath.floor(random()*s)%2Ch%3DMath.floor(random()*s)%3Bfor(let%20t%3D0%3Bt%3C30%3B%2B%2Bt)drawCube(o%2Cline_f(o%2Ca)%2Cu%2Ce%2Cr)%2CdrawCube(n%2C-line_f(n%2Ci)%2Cu%2Ce%2Cr)%2Co%2B%3Dc%2Cn-%3Dc%3Bo%3D-500%2Cn%3D600%2Ca%2B%3Dh%2Ci-%3Dh%7D%7Dvar%20svg%3Bfunction%20setDezoom(t)%7Blet%20e%3Dnull%3Bt%3DgetPrimaryPalette(t)%3B(e%3D%22positive%22%3D%3D%3Dt%3F200*random()-3250%2B%22%20-500%206000%202000%22%3A%22neutral%22%3D%3D%3Dt%3F%22-1375%20-625%202250%20750%22%3A100*random()%2B%22%200%201500%20500%22)%3Fsvg.setAttribute(%22viewBox%22%2Ce)%3Asvg.setAttribute(%22viewBox%22%2C%22%22)%7Dfunction%20random()%7Breturn%20generator()%7D",
                    ";var sentiment = [",
                    "0.",
                    positive.toString(),
                    ",0.",
                    neutral.toString(),
                    ",0.",
                    negative.toString(),
                    "];var seed='",
                    seed.toString(),
                    "';selectedPalette=",
                    colorsArray,
                    ";backgroundColor='",
                    backgroundColor,
                    "';borderColor='",
                    borderColor,
                    "';svg%20%3D%20document.getElementById('svg')%3Bgenerator%3DaleaPRNG(seed)%3BsetBackground(sentiment)%3Bdraw(sentiment)%3BsetDezoom(sentiment)%3BsetBorder(sentiment)%3B%3C%2Fscript%3E%3C%2Fbody%3E%3C%2Fhtml%3E"
                )
            );
    }
}


// File operator-filter-registry/src/lib/[email protected]

pragma solidity ^0.8.13;

address constant CANONICAL_OPERATOR_FILTER_REGISTRY_ADDRESS = 0x000000000000AAeB6D7670E522A718067333cd4E;
address constant CANONICAL_CORI_SUBSCRIPTION = 0x3cc6CddA760b79bAfa08dF41ECFA224f810dCeB6;


// File operator-filter-registry/src/[email protected]

pragma solidity ^0.8.13;

interface IOperatorFilterRegistry {
    /**
     * @notice Returns true if operator is not filtered for a given token, either by address or codeHash. Also returns
     *         true if supplied registrant address is not registered.
     */
    function isOperatorAllowed(address registrant, address operator) external view returns (bool);

    /**
     * @notice Registers an address with the registry. May be called by address itself or by EIP-173 owner.
     */
    function register(address registrant) external;

    /**
     * @notice Registers an address with the registry and "subscribes" to another address's filtered operators and codeHashes.
     */
    function registerAndSubscribe(address registrant, address subscription) external;

    /**
     * @notice Registers an address with the registry and copies the filtered operators and codeHashes from another
     *         address without subscribing.
     */
    function registerAndCopyEntries(address registrant, address registrantToCopy) external;

    /**
     * @notice Unregisters an address with the registry and removes its subscription. May be called by address itself or by EIP-173 owner.
     *         Note that this does not remove any filtered addresses or codeHashes.
     *         Also note that any subscriptions to this registrant will still be active and follow the existing filtered addresses and codehashes.
     */
    function unregister(address addr) external;

    /**
     * @notice Update an operator address for a registered address - when filtered is true, the operator is filtered.
     */
    function updateOperator(address registrant, address operator, bool filtered) external;

    /**
     * @notice Update multiple operators for a registered address - when filtered is true, the operators will be filtered. Reverts on duplicates.
     */
    function updateOperators(address registrant, address[] calldata operators, bool filtered) external;

    /**
     * @notice Update a codeHash for a registered address - when filtered is true, the codeHash is filtered.
     */
    function updateCodeHash(address registrant, bytes32 codehash, bool filtered) external;

    /**
     * @notice Update multiple codeHashes for a registered address - when filtered is true, the codeHashes will be filtered. Reverts on duplicates.
     */
    function updateCodeHashes(address registrant, bytes32[] calldata codeHashes, bool filtered) external;

    /**
     * @notice Subscribe an address to another registrant's filtered operators and codeHashes. Will remove previous
     *         subscription if present.
     *         Note that accounts with subscriptions may go on to subscribe to other accounts - in this case,
     *         subscriptions will not be forwarded. Instead the former subscription's existing entries will still be
     *         used.
     */
    function subscribe(address registrant, address registrantToSubscribe) external;

    /**
     * @notice Unsubscribe an address from its current subscribed registrant, and optionally copy its filtered operators and codeHashes.
     */
    function unsubscribe(address registrant, bool copyExistingEntries) external;

    /**
     * @notice Get the subscription address of a given registrant, if any.
     */
    function subscriptionOf(address addr) external returns (address registrant);

    /**
     * @notice Get the set of addresses subscribed to a given registrant.
     *         Note that order is not guaranteed as updates are made.
     */
    function subscribers(address registrant) external returns (address[] memory);

    /**
     * @notice Get the subscriber at a given index in the set of addresses subscribed to a given registrant.
     *         Note that order is not guaranteed as updates are made.
     */
    function subscriberAt(address registrant, uint256 index) external returns (address);

    /**
     * @notice Copy filtered operators and codeHashes from a different registrantToCopy to addr.
     */
    function copyEntriesOf(address registrant, address registrantToCopy) external;

    /**
     * @notice Returns true if operator is filtered by a given address or its subscription.
     */
    function isOperatorFiltered(address registrant, address operator) external returns (bool);

    /**
     * @notice Returns true if the hash of an address's code is filtered by a given address or its subscription.
     */
    function isCodeHashOfFiltered(address registrant, address operatorWithCode) external returns (bool);

    /**
     * @notice Returns true if a codeHash is filtered by a given address or its subscription.
     */
    function isCodeHashFiltered(address registrant, bytes32 codeHash) external returns (bool);

    /**
     * @notice Returns a list of filtered operators for a given address or its subscription.
     */
    function filteredOperators(address addr) external returns (address[] memory);

    /**
     * @notice Returns the set of filtered codeHashes for a given address or its subscription.
     *         Note that order is not guaranteed as updates are made.
     */
    function filteredCodeHashes(address addr) external returns (bytes32[] memory);

    /**
     * @notice Returns the filtered operator at the given index of the set of filtered operators for a given address or
     *         its subscription.
     *         Note that order is not guaranteed as updates are made.
     */
    function filteredOperatorAt(address registrant, uint256 index) external returns (address);

    /**
     * @notice Returns the filtered codeHash at the given index of the list of filtered codeHashes for a given address or
     *         its subscription.
     *         Note that order is not guaranteed as updates are made.
     */
    function filteredCodeHashAt(address registrant, uint256 index) external returns (bytes32);

    /**
     * @notice Returns true if an address has registered
     */
    function isRegistered(address addr) external returns (bool);

    /**
     * @dev Convenience method to compute the code hash of an arbitrary contract
     */
    function codeHashOf(address addr) external returns (bytes32);
}


// File operator-filter-registry/src/[email protected]

pragma solidity ^0.8.13;


/**
 * @title  OperatorFilterer
 * @notice Abstract contract whose constructor automatically registers and optionally subscribes to or copies another
 *         registrant's entries in the OperatorFilterRegistry.
 * @dev    This smart contract is meant to be inherited by token contracts so they can use the following:
 *         - `onlyAllowedOperator` modifier for `transferFrom` and `safeTransferFrom` methods.
 *         - `onlyAllowedOperatorApproval` modifier for `approve` and `setApprovalForAll` methods.
 *         Please note that if your token contract does not provide an owner with EIP-173, it must provide
 *         administration methods on the contract itself to interact with the registry otherwise the subscription
 *         will be locked to the options set during construction.
 */

abstract contract OperatorFilterer {
    /// @dev Emitted when an operator is not allowed.
    error OperatorNotAllowed(address operator);

    IOperatorFilterRegistry public constant OPERATOR_FILTER_REGISTRY =
        IOperatorFilterRegistry(CANONICAL_OPERATOR_FILTER_REGISTRY_ADDRESS);

    /// @dev The constructor that is called when the contract is being deployed.
    constructor(address subscriptionOrRegistrantToCopy, bool subscribe) {
        // If an inheriting token contract is deployed to a network without the registry deployed, the modifier
        // will not revert, but the contract will need to be registered with the registry once it is deployed in
        // order for the modifier to filter addresses.
        if (address(OPERATOR_FILTER_REGISTRY).code.length > 0) {
            if (subscribe) {
                OPERATOR_FILTER_REGISTRY.registerAndSubscribe(address(this), subscriptionOrRegistrantToCopy);
            } else {
                if (subscriptionOrRegistrantToCopy != address(0)) {
                    OPERATOR_FILTER_REGISTRY.registerAndCopyEntries(address(this), subscriptionOrRegistrantToCopy);
                } else {
                    OPERATOR_FILTER_REGISTRY.register(address(this));
                }
            }
        }
    }

    /**
     * @dev A helper function to check if an operator is allowed.
     */
    modifier onlyAllowedOperator(address from) virtual {
        // Allow spending tokens from addresses with balance
        // Note that this still allows listings and marketplaces with escrow to transfer tokens if transferred
        // from an EOA.
        if (from != msg.sender) {
            _checkFilterOperator(msg.sender);
        }
        _;
    }

    /**
     * @dev A helper function to check if an operator approval is allowed.
     */
    modifier onlyAllowedOperatorApproval(address operator) virtual {
        _checkFilterOperator(operator);
        _;
    }

    /**
     * @dev A helper function to check if an operator is allowed.
     */
    function _checkFilterOperator(address operator) internal view virtual {
        // Check registry code length to facilitate testing in environments without a deployed registry.
        if (address(OPERATOR_FILTER_REGISTRY).code.length > 0) {
            // under normal circumstances, this function will revert rather than return false, but inheriting contracts
            // may specify their own OperatorFilterRegistry implementations, which may behave differently
            if (!OPERATOR_FILTER_REGISTRY.isOperatorAllowed(address(this), operator)) {
                revert OperatorNotAllowed(operator);
            }
        }
    }
}


// File operator-filter-registry/src/[email protected]

pragma solidity ^0.8.13;


/**
 * @title  DefaultOperatorFilterer
 * @notice Inherits from OperatorFilterer and automatically subscribes to the default OpenSea subscription.
 * @dev    Please note that if your token contract does not provide an owner with EIP-173, it must provide
 *         administration methods on the contract itself to interact with the registry otherwise the subscription
 *         will be locked to the options set during construction.
 */

abstract contract DefaultOperatorFilterer is OperatorFilterer {
    /// @dev The constructor that is called when the contract is being deployed.
    constructor() OperatorFilterer(CANONICAL_CORI_SUBSCRIPTION, true) {}
}


// File contracts/Pol.sol


pragma solidity ^0.8.18;







contract POL is
    ERC721Enumerable,
    Ownable,
    AccessControlEnumerable,
    ERC2981,
    DefaultOperatorFilterer
{
    using Strings for uint256;

    bool public metadatasFrozen = false;

    uint256 public maxSupply = 4000;

    //General admin role
    bytes32 public constant ADMIN_ROLE = keccak256("ADMIN_ROLE");
    //Minter role, only allowed to mint
    bytes32 public constant MINTER_ROLE = keccak256("MINTER_ROLE");

    /**
     * @dev Struct used to store the traits of each NFT.
     * @dev Values for positive, negative and neutral are stored with 3 decimals. 1000 => 1.
     */
    struct Sentiments {
        uint64 positive;
        uint64 negative;
        uint64 neutral;
        uint64 seed;
    }

    /**
     * @dev Maps tokenId to its data
     */
    mapping(uint256 => Sentiments) public data;

    /**
     * @dev Contract for rendering.
     * See {Renderer}
     */
    Renderer public render;

    constructor(address _defaultRoyaltiesReceiver) ERC721("POL", "POL") {

        _setRoleAdmin(MINTER_ROLE, ADMIN_ROLE); //Admin role manages Minter role.
        _grantRole(ADMIN_ROLE, msg.sender); //msg.sender is granted temporary Admin role.
        _mintTo(msg.sender, 340, 330, 330); //Mint first NFT to creator. This is necessary to configure OpenSea.
        _setDefaultRoyalty(_defaultRoyaltiesReceiver, 750); //Default royalty
    }

    //Restrict function to admin role
    modifier onlyAdmin() {
        require(
            hasRole(ADMIN_ROLE, msg.sender),
            "You must be an Admin to perform this action"
        );
        _;
    }

    //Restrict function to minter role
    modifier onlyMinter() {
        require(
            hasRole(MINTER_ROLE, msg.sender),
            "You must be a Minter to perform this action"
        );
        _;
    }

    function _mintTo(
        address _address,
        uint64 positive,
        uint64 negative,
        uint64 neutral
    ) internal {
        uint64 seed = uint64(
            uint256(
                keccak256(abi.encode(positive, negative, neutral, _address))
            )
        );

        uint256 nextTokenId = totalSupply();

        data[nextTokenId] = Sentiments({
            positive: positive,
            negative: negative,
            neutral: neutral,
            seed: seed
        });

        _safeMint(_address, nextTokenId);
    }

    function mintTo(
        address _address,
        uint64 positive,
        uint64 negative,
        uint64 neutral
    ) public onlyMinter {
        require(totalSupply() < maxSupply, "Max Supply Reached");
        _mintTo(_address, positive, negative, neutral);
    }

    function reduceSupply() public onlyAdmin {
        maxSupply = totalSupply();
    }

    function freezeMetadatas() public onlyAdmin {
        metadatasFrozen = true;
    }

    function setRender(address _address) public onlyAdmin {
        require(!metadatasFrozen, "Metadatas are frozen");
        render = Renderer(_address);
    }

    function tokenURI(
        uint256 tokenId
    ) public view override(ERC721) returns (string memory) {
        Sentiments memory sentiments = data[tokenId];

        bytes memory base = abi.encodePacked(
            "data:application/json;base64,",
            Base64.encode(
                abi.encodePacked(
                    '{"name":"POL #',
                    tokenId.toString(),
                    '","image":"',
                    render.drawPreview(
                        sentiments.positive,
                        sentiments.negative,
                        sentiments.neutral,
                        sentiments.seed
                    ),
                    '","description": "We want to build the world\'s largest emotional NFT initiative, transforming community livestream sentiments into perpetually on-chain recorded geometric artworks",',
                    '"animation_url":"',
                    render.drawHtml(
                        sentiments.positive,
                        sentiments.negative,
                        sentiments.neutral,
                        sentiments.seed
                    ),
                    '", "attributes":[{"trait_type": "positive", "value":',
                    uint256(sentiments.positive).toString(),
                    '},{"trait_type": "negative", "value":',
                    uint256(sentiments.negative).toString(),
                    '},{"trait_type": "neutral", "value":',
                    uint256(sentiments.neutral).toString(),
                    '},{"trait_type": "seed", "value":"',
                    uint256(sentiments.seed).toString(),
                    '"}]}'
                )
            )
        );

        return string(base);
    }

    /**
     * @dev Indicates that this contract supports both ERC721Metadata, ERC2981 and AccessControlEnumerable interfaces
     */
    function supportsInterface(
        bytes4 interfaceId
    )
        public
        view
        override(ERC721Enumerable, ERC2981, AccessControlEnumerable)
        returns (bool)
    {
        return
            ERC721Enumerable.supportsInterface(interfaceId) ||
            AccessControlEnumerable.supportsInterface(interfaceId) ||
            ERC2981.supportsInterface(interfaceId);
    }

    /**
     * @notice This section is set up in accordance to the OpenSea OperatorFilterer documentation, in order to enforce creators royalties.
     * We use the default subscription.
     */
    function setApprovalForAll(
        address operator,
        bool approved
    ) public override(ERC721, IERC721) onlyAllowedOperatorApproval(operator) {
        super.setApprovalForAll(operator, approved);
    }

    function approve(
        address operator,
        uint256 tokenId
    ) public override(ERC721, IERC721) onlyAllowedOperatorApproval(operator) {
        super.approve(operator, tokenId);
    }

    function transferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public override(ERC721, IERC721) onlyAllowedOperator(from) {
        super.transferFrom(from, to, tokenId);
    }

    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public override(ERC721, IERC721) onlyAllowedOperator(from) {
        super.safeTransferFrom(from, to, tokenId);
    }

    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId,
        bytes memory _data
    ) public override(ERC721, IERC721) onlyAllowedOperator(from) {
        super.safeTransferFrom(from, to, tokenId, _data);
    }
}


// File @openzeppelin/contracts/utils/cryptography/[email protected]

// OpenZeppelin Contracts (last updated v4.8.0) (utils/cryptography/MerkleProof.sol)

pragma solidity ^0.8.0;

/**
 * @dev These functions deal with verification of Merkle Tree proofs.
 *
 * The tree and the proofs can be generated using our
 * https://github.com/OpenZeppelin/merkle-tree[JavaScript library].
 * You will find a quickstart guide in the readme.
 *
 * WARNING: You should avoid using leaf values that are 64 bytes long prior to
 * hashing, or use a hash function other than keccak256 for hashing leaves.
 * This is because the concatenation of a sorted pair of internal nodes in
 * the merkle tree could be reinterpreted as a leaf value.
 * OpenZeppelin's JavaScript library generates merkle trees that are safe
 * against this attack out of the box.
 */
library MerkleProof {
    /**
     * @dev Returns true if a `leaf` can be proved to be a part of a Merkle tree
     * defined by `root`. For this, a `proof` must be provided, containing
     * sibling hashes on the branch from the leaf to the root of the tree. Each
     * pair of leaves and each pair of pre-images are assumed to be sorted.
     */
    function verify(
        bytes32[] memory proof,
        bytes32 root,
        bytes32 leaf
    ) internal pure returns (bool) {
        return processProof(proof, leaf) == root;
    }

    /**
     * @dev Calldata version of {verify}
     *
     * _Available since v4.7._
     */
    function verifyCalldata(
        bytes32[] calldata proof,
        bytes32 root,
        bytes32 leaf
    ) internal pure returns (bool) {
        return processProofCalldata(proof, leaf) == root;
    }

    /**
     * @dev Returns the rebuilt hash obtained by traversing a Merkle tree up
     * from `leaf` using `proof`. A `proof` is valid if and only if the rebuilt
     * hash matches the root of the tree. When processing the proof, the pairs
     * of leafs & pre-images are assumed to be sorted.
     *
     * _Available since v4.4._
     */
    function processProof(bytes32[] memory proof, bytes32 leaf) internal pure returns (bytes32) {
        bytes32 computedHash = leaf;
        for (uint256 i = 0; i < proof.length; i++) {
            computedHash = _hashPair(computedHash, proof[i]);
        }
        return computedHash;
    }

    /**
     * @dev Calldata version of {processProof}
     *
     * _Available since v4.7._
     */
    function processProofCalldata(bytes32[] calldata proof, bytes32 leaf) internal pure returns (bytes32) {
        bytes32 computedHash = leaf;
        for (uint256 i = 0; i < proof.length; i++) {
            computedHash = _hashPair(computedHash, proof[i]);
        }
        return computedHash;
    }

    /**
     * @dev Returns true if the `leaves` can be simultaneously proven to be a part of a merkle tree defined by
     * `root`, according to `proof` and `proofFlags` as described in {processMultiProof}.
     *
     * CAUTION: Not all merkle trees admit multiproofs. See {processMultiProof} for details.
     *
     * _Available since v4.7._
     */
    function multiProofVerify(
        bytes32[] memory proof,
        bool[] memory proofFlags,
        bytes32 root,
        bytes32[] memory leaves
    ) internal pure returns (bool) {
        return processMultiProof(proof, proofFlags, leaves) == root;
    }

    /**
     * @dev Calldata version of {multiProofVerify}
     *
     * CAUTION: Not all merkle trees admit multiproofs. See {processMultiProof} for details.
     *
     * _Available since v4.7._
     */
    function multiProofVerifyCalldata(
        bytes32[] calldata proof,
        bool[] calldata proofFlags,
        bytes32 root,
        bytes32[] memory leaves
    ) internal pure returns (bool) {
        return processMultiProofCalldata(proof, proofFlags, leaves) == root;
    }

    /**
     * @dev Returns the root of a tree reconstructed from `leaves` and sibling nodes in `proof`. The reconstruction
     * proceeds by incrementally reconstructing all inner nodes by combining a leaf/inner node with either another
     * leaf/inner node or a proof sibling node, depending on whether each `proofFlags` item is true or false
     * respectively.
     *
     * CAUTION: Not all merkle trees admit multiproofs. To use multiproofs, it is sufficient to ensure that: 1) the tree
     * is complete (but not necessarily perfect), 2) the leaves to be proven are in the opposite order they are in the
     * tree (i.e., as seen from right to left starting at the deepest layer and continuing at the next layer).
     *
     * _Available since v4.7._
     */
    function processMultiProof(
        bytes32[] memory proof,
        bool[] memory proofFlags,
        bytes32[] memory leaves
    ) internal pure returns (bytes32 merkleRoot) {
        // This function rebuild the root hash by traversing the tree up from the leaves. The root is rebuilt by
        // consuming and producing values on a queue. The queue starts with the `leaves` array, then goes onto the
        // `hashes` array. At the end of the process, the last hash in the `hashes` array should contain the root of
        // the merkle tree.
        uint256 leavesLen = leaves.length;
        uint256 totalHashes = proofFlags.length;

        // Check proof validity.
        require(leavesLen + proof.length - 1 == totalHashes, "MerkleProof: invalid multiproof");

        // The xxxPos values are "pointers" to the next value to consume in each array. All accesses are done using
        // `xxx[xxxPos++]`, which return the current value and increment the pointer, thus mimicking a queue's "pop".
        bytes32[] memory hashes = new bytes32[](totalHashes);
        uint256 leafPos = 0;
        uint256 hashPos = 0;
        uint256 proofPos = 0;
        // At each step, we compute the next hash using two values:
        // - a value from the "main queue". If not all leaves have been consumed, we get the next leaf, otherwise we
        //   get the next hash.
        // - depending on the flag, either another value for the "main queue" (merging branches) or an element from the
        //   `proof` array.
        for (uint256 i = 0; i < totalHashes; i++) {
            bytes32 a = leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++];
            bytes32 b = proofFlags[i] ? leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++] : proof[proofPos++];
            hashes[i] = _hashPair(a, b);
        }

        if (totalHashes > 0) {
            return hashes[totalHashes - 1];
        } else if (leavesLen > 0) {
            return leaves[0];
        } else {
            return proof[0];
        }
    }

    /**
     * @dev Calldata version of {processMultiProof}.
     *
     * CAUTION: Not all merkle trees admit multiproofs. See {processMultiProof} for details.
     *
     * _Available since v4.7._
     */
    function processMultiProofCalldata(
        bytes32[] calldata proof,
        bool[] calldata proofFlags,
        bytes32[] memory leaves
    ) internal pure returns (bytes32 merkleRoot) {
        // This function rebuild the root hash by traversing the tree up from the leaves. The root is rebuilt by
        // consuming and producing values on a queue. The queue starts with the `leaves` array, then goes onto the
        // `hashes` array. At the end of the process, the last hash in the `hashes` array should contain the root of
        // the merkle tree.
        uint256 leavesLen = leaves.length;
        uint256 totalHashes = proofFlags.length;

        // Check proof validity.
        require(leavesLen + proof.length - 1 == totalHashes, "MerkleProof: invalid multiproof");

        // The xxxPos values are "pointers" to the next value to consume in each array. All accesses are done using
        // `xxx[xxxPos++]`, which return the current value and increment the pointer, thus mimicking a queue's "pop".
        bytes32[] memory hashes = new bytes32[](totalHashes);
        uint256 leafPos = 0;
        uint256 hashPos = 0;
        uint256 proofPos = 0;
        // At each step, we compute the next hash using two values:
        // - a value from the "main queue". If not all leaves have been consumed, we get the next leaf, otherwise we
        //   get the next hash.
        // - depending on the flag, either another value for the "main queue" (merging branches) or an element from the
        //   `proof` array.
        for (uint256 i = 0; i < totalHashes; i++) {
            bytes32 a = leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++];
            bytes32 b = proofFlags[i] ? leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++] : proof[proofPos++];
            hashes[i] = _hashPair(a, b);
        }

        if (totalHashes > 0) {
            return hashes[totalHashes - 1];
        } else if (leavesLen > 0) {
            return leaves[0];
        } else {
            return proof[0];
        }
    }

    function _hashPair(bytes32 a, bytes32 b) private pure returns (bytes32) {
        return a < b ? _efficientHash(a, b) : _efficientHash(b, a);
    }

    function _efficientHash(bytes32 a, bytes32 b) private pure returns (bytes32 value) {
        /// @solidity memory-safe-assembly
        assembly {
            mstore(0x00, a)
            mstore(0x20, b)
            value := keccak256(0x00, 0x40)
        }
    }
}


// File contracts/PolMint.sol

// SPDX-License-Identifier: UNLICENSED

pragma solidity ^0.8.18;




contract PolMint is Ownable, Pausable {
    POL immutable pol;

    bytes32 public root;

    mapping(address => bool) public minted;

    constructor(address _pol) {
        pol = POL(_pol);
    }

    function _verify(
        bytes32[] memory proof,
        uint64 positive,
        uint64 negative,
        uint64 neutral,
        address addr
    ) internal view returns(bool) {
        bytes32 leaf = keccak256(
            bytes.concat(
                keccak256(abi.encode(addr, positive, negative, neutral))
            )
        );
        return MerkleProof.verify(proof, root, leaf);
    }

    function setRoot(bytes32 _root) public onlyOwner {
        root = _root;
    }

    function pause() public onlyOwner {
        _pause();
    }

    function unpause() public onlyOwner {
        _unpause();
    }

    function mint(
        bytes32[] memory proof,
        uint64 positive,
        uint64 negative,
        uint64 neutral
    ) public whenNotPaused {
        require(_verify(proof,positive, negative, neutral, msg.sender), "You are not on the list");
        require(minted[msg.sender] == false, "You have alreay minted");

        minted[msg.sender] = true;

        pol.mintTo(msg.sender, positive, negative, neutral);

    }
}

Settings
{
  "optimizer": {
    "enabled": false,
    "runs": 200
  },
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "devdoc",
        "userdoc",
        "metadata",
        "abi"
      ]
    }
  }
}

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"address","name":"_defaultRoyaltiesReceiver","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"operator","type":"address"}],"name":"OperatorNotAllowed","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":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":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[],"name":"ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEFAULT_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MINTER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"OPERATOR_FILTER_REGISTRY","outputs":[{"internalType":"contract IOperatorFilterRegistry","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"data","outputs":[{"internalType":"uint64","name":"positive","type":"uint64"},{"internalType":"uint64","name":"negative","type":"uint64"},{"internalType":"uint64","name":"neutral","type":"uint64"},{"internalType":"uint64","name":"seed","type":"uint64"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"freezeMetadatas","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","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":"uint256","name":"index","type":"uint256"}],"name":"getRoleMember","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleMemberCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"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":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"metadatasFrozen","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_address","type":"address"},{"internalType":"uint64","name":"positive","type":"uint64"},{"internalType":"uint64","name":"negative","type":"uint64"},{"internalType":"uint64","name":"neutral","type":"uint64"}],"name":"mintTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"reduceSupply","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"render","outputs":[{"internalType":"contract Renderer","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"renounceRole","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":"uint256","name":"_tokenId","type":"uint256"},{"internalType":"uint256","name":"_salePrice","type":"uint256"}],"name":"royaltyInfo","outputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"_data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_address","type":"address"}],"name":"setRender","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenOfOwnerByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}]

60806040526000600f60006101000a81548160ff021916908315150217905550610fa06010553480156200003257600080fd5b5060405162007cb438038062007cb48339818101604052810190620000589190620015f2565b733cc6cdda760b79bafa08df41ecfa224f810dceb660016040518060400160405280600381526020017f504f4c00000000000000000000000000000000000000000000000000000000008152506040518060400160405280600381526020017f504f4c00000000000000000000000000000000000000000000000000000000008152508160009081620000ec91906200189e565b508060019081620000fe91906200189e565b5050506200012162000115620003cf60201b60201c565b620003d760201b60201c565b60006daaeb6d7670e522a718067333cd4e73ffffffffffffffffffffffffffffffffffffffff163b111562000316578015620001dc576daaeb6d7670e522a718067333cd4e73ffffffffffffffffffffffffffffffffffffffff16637d3e3dbe30846040518363ffffffff1660e01b8152600401620001a292919062001996565b600060405180830381600087803b158015620001bd57600080fd5b505af1158015620001d2573d6000803e3d6000fd5b5050505062000315565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161462000296576daaeb6d7670e522a718067333cd4e73ffffffffffffffffffffffffffffffffffffffff1663a0af290330846040518363ffffffff1660e01b81526004016200025c92919062001996565b600060405180830381600087803b1580156200027757600080fd5b505af11580156200028c573d6000803e3d6000fd5b5050505062000314565b6daaeb6d7670e522a718067333cd4e73ffffffffffffffffffffffffffffffffffffffff16634420e486306040518263ffffffff1660e01b8152600401620002df9190620019c3565b600060405180830381600087803b158015620002fa57600080fd5b505af11580156200030f573d6000803e3d6000fd5b505050505b5b5b50506200036a7f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a67fa49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c217756200049d60201b60201c565b6200039c7fa49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c21775336200050160201b60201c565b620003b43361015461014a806200054960201b60201c565b620003c8816102ee620006c860201b60201c565b506200206f565b600033905090565b6000600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905081600a60006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b6000620004b0836200086b60201b60201c565b905081600b6000858152602001908152602001600020600101819055508181847fbd79b86ffe0ab8e8776151514217cd7cacd52c909f66475c3af44e129f0b00ff60405160405180910390a4505050565b6200051882826200088b60201b6200187b1760201c565b6200054481600c60008581526020019081526020016000206200097d60201b6200195c1790919060201c565b505050565b60008383838760405160200162000564949392919062001a05565b6040516020818303038152906040528051906020012060001c9050600062000591620009b560201b60201c565b905060405180608001604052808667ffffffffffffffff1681526020018567ffffffffffffffff1681526020018467ffffffffffffffff1681526020018367ffffffffffffffff168152506011600083815260200190815260200160002060008201518160000160006101000a81548167ffffffffffffffff021916908367ffffffffffffffff16021790555060208201518160000160086101000a81548167ffffffffffffffff021916908367ffffffffffffffff16021790555060408201518160000160106101000a81548167ffffffffffffffff021916908367ffffffffffffffff16021790555060608201518160000160186101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550905050620006c08682620009c260201b60201c565b505050505050565b620006d8620009e860201b60201c565b6bffffffffffffffffffffffff16816bffffffffffffffffffffffff16111562000739576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401620007309062001ad9565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603620007ab576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401620007a29062001b4b565b60405180910390fd5b60405180604001604052808373ffffffffffffffffffffffffffffffffffffffff168152602001826bffffffffffffffffffffffff16815250600d60008201518160000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060208201518160000160146101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055509050505050565b6000600b6000838152602001908152602001600020600101549050919050565b6200089d8282620009f260201b60201c565b62000979576001600b600084815260200190815260200160002060000160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055506200091e620003cf60201b60201c565b73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45b5050565b6000620009ad836000018373ffffffffffffffffffffffffffffffffffffffff1660001b62000a5d60201b60201c565b905092915050565b6000600880549050905090565b620009e482826040518060200160405280600081525062000ad760201b60201c565b5050565b6000612710905090565b6000600b600084815260200190815260200160002060000160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16905092915050565b600062000a71838362000b4560201b60201c565b62000acc57826000018290806001815401808255809150506001900390600052602060002001600090919091909150558260000180549050836001016000848152602001908152602001600020819055506001905062000ad1565b600090505b92915050565b62000ae9838362000b6860201b60201c565b62000afe600084848462000dae60201b60201c565b62000b40576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040162000b379062001be3565b60405180910390fd5b505050565b600080836001016000848152602001908152602001600020541415905092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff160362000bda576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040162000bd19062001c55565b60405180910390fd5b62000beb8162000f5760201b60201c565b1562000c2e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040162000c259062001cc7565b60405180910390fd5b62000c4460008383600162000fa060201b60201c565b62000c558162000f5760201b60201c565b1562000c98576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040162000c8f9062001cc7565b60405180910390fd5b6001600360008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282540192505081905550816002600083815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550808273ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a462000daa6000838360016200113460201b60201c565b5050565b600062000ddc8473ffffffffffffffffffffffffffffffffffffffff166200113a60201b6200198c1760201c565b1562000f4a578373ffffffffffffffffffffffffffffffffffffffff1663150b7a0262000e0e620003cf60201b60201c565b8786866040518563ffffffff1660e01b815260040162000e32949392919062001d94565b6020604051808303816000875af192505050801562000e7157506040513d601f19601f8201168201806040525081019062000e6e919062001e45565b60015b62000ef9573d806000811462000ea4576040519150601f19603f3d011682016040523d82523d6000602084013e62000ea9565b606091505b50600081510362000ef1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040162000ee89062001be3565b60405180910390fd5b805181602001fd5b63150b7a0260e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161491505062000f4f565b600190505b949350505050565b60008073ffffffffffffffffffffffffffffffffffffffff1662000f81836200115d60201b60201c565b73ffffffffffffffffffffffffffffffffffffffff1614159050919050565b62000fb9848484846200119a60201b620019af1760201c565b600181111562001000576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040162000ff79062001eed565b60405180910390fd5b6000829050600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff160362001051576200104b81620011a060201b60201c565b62001099565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff16146200109857620010978582620011e960201b60201c565b5b5b600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1603620010e557620010df816200136660201b60201c565b6200112d565b8473ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff16146200112c576200112b84826200144260201b60201c565b5b5b5050505050565b50505050565b6000808273ffffffffffffffffffffffffffffffffffffffff163b119050919050565b60006002600083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b50505050565b6008805490506009600083815260200190815260200160002081905550600881908060018154018082558091505060019003906000526020600020016000909190919091505550565b600060016200120384620014ce60201b62000f0a1760201c565b6200120f919062001f3e565b9050600060076000848152602001908152602001600020549050818114620012f5576000600660008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600084815260200190815260200160002054905080600660008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600084815260200190815260200160002081905550816007600083815260200190815260200160002081905550505b6007600084815260200190815260200160002060009055600660008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008381526020019081526020016000206000905550505050565b600060016008805490506200137c919062001f3e565b9050600060096000848152602001908152602001600020549050600060088381548110620013af57620013ae62001f79565b5b906000526020600020015490508060088381548110620013d457620013d362001f79565b5b90600052602060002001819055508160096000838152602001908152602001600020819055506009600085815260200190815260200160002060009055600880548062001426576200142562001fa8565b5b6001900381819060005260206000200160009055905550505050565b60006200145a83620014ce60201b62000f0a1760201c565b905081600660008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600083815260200190815260200160002081905550806007600084815260200190815260200160002081905550505050565b60008073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff160362001541576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040162001538906200204d565b60405180910390fd5b600360008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000620015ba826200158d565b9050919050565b620015cc81620015ad565b8114620015d857600080fd5b50565b600081519050620015ec81620015c1565b92915050565b6000602082840312156200160b576200160a62001588565b5b60006200161b84828501620015db565b91505092915050565b600081519050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b60006002820490506001821680620016a657607f821691505b602082108103620016bc57620016bb6200165e565b5b50919050565b60008190508160005260206000209050919050565b60006020601f8301049050919050565b600082821b905092915050565b600060088302620017267fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82620016e7565b620017328683620016e7565b95508019841693508086168417925050509392505050565b6000819050919050565b6000819050919050565b60006200177f6200177962001773846200174a565b62001754565b6200174a565b9050919050565b6000819050919050565b6200179b836200175e565b620017b3620017aa8262001786565b848454620016f4565b825550505050565b600090565b620017ca620017bb565b620017d781848462001790565b505050565b5b81811015620017ff57620017f3600082620017c0565b600181019050620017dd565b5050565b601f8211156200184e576200181881620016c2565b6200182384620016d7565b8101602085101562001833578190505b6200184b6200184285620016d7565b830182620017dc565b50505b505050565b600082821c905092915050565b6000620018736000198460080262001853565b1980831691505092915050565b60006200188e838362001860565b9150826002028217905092915050565b620018a98262001624565b67ffffffffffffffff811115620018c557620018c46200162f565b5b620018d182546200168d565b620018de82828562001803565b600060209050601f83116001811462001916576000841562001901578287015190505b6200190d858262001880565b8655506200197d565b601f1984166200192686620016c2565b60005b82811015620019505784890151825560018201915060208501945060208101905062001929565b868310156200197057848901516200196c601f89168262001860565b8355505b6001600288020188555050505b505050505050565b6200199081620015ad565b82525050565b6000604082019050620019ad600083018562001985565b620019bc602083018462001985565b9392505050565b6000602082019050620019da600083018462001985565b92915050565b600067ffffffffffffffff82169050919050565b620019ff81620019e0565b82525050565b600060808201905062001a1c6000830187620019f4565b62001a2b6020830186620019f4565b62001a3a6040830185620019f4565b62001a49606083018462001985565b95945050505050565b600082825260208201905092915050565b7f455243323938313a20726f79616c7479206665652077696c6c2065786365656460008201527f2073616c65507269636500000000000000000000000000000000000000000000602082015250565b600062001ac1602a8362001a52565b915062001ace8262001a63565b604082019050919050565b6000602082019050818103600083015262001af48162001ab2565b9050919050565b7f455243323938313a20696e76616c696420726563656976657200000000000000600082015250565b600062001b3360198362001a52565b915062001b408262001afb565b602082019050919050565b6000602082019050818103600083015262001b668162001b24565b9050919050565b7f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560008201527f63656976657220696d706c656d656e7465720000000000000000000000000000602082015250565b600062001bcb60328362001a52565b915062001bd88262001b6d565b604082019050919050565b6000602082019050818103600083015262001bfe8162001bbc565b9050919050565b7f4552433732313a206d696e7420746f20746865207a65726f2061646472657373600082015250565b600062001c3d60208362001a52565b915062001c4a8262001c05565b602082019050919050565b6000602082019050818103600083015262001c708162001c2e565b9050919050565b7f4552433732313a20746f6b656e20616c7265616479206d696e74656400000000600082015250565b600062001caf601c8362001a52565b915062001cbc8262001c77565b602082019050919050565b6000602082019050818103600083015262001ce28162001ca0565b9050919050565b62001cf4816200174a565b82525050565b600081519050919050565b600082825260208201905092915050565b60005b8381101562001d3657808201518184015260208101905062001d19565b60008484015250505050565b6000601f19601f8301169050919050565b600062001d608262001cfa565b62001d6c818562001d05565b935062001d7e81856020860162001d16565b62001d898162001d42565b840191505092915050565b600060808201905062001dab600083018762001985565b62001dba602083018662001985565b62001dc9604083018562001ce9565b818103606083015262001ddd818462001d53565b905095945050505050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b62001e1f8162001de8565b811462001e2b57600080fd5b50565b60008151905062001e3f8162001e14565b92915050565b60006020828403121562001e5e5762001e5d62001588565b5b600062001e6e8482850162001e2e565b91505092915050565b7f455243373231456e756d657261626c653a20636f6e736563757469766520747260008201527f616e7366657273206e6f7420737570706f727465640000000000000000000000602082015250565b600062001ed560358362001a52565b915062001ee28262001e77565b604082019050919050565b6000602082019050818103600083015262001f088162001ec6565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600062001f4b826200174a565b915062001f58836200174a565b925082820390508181111562001f735762001f7262001f0f565b5b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b7f4552433732313a2061646472657373207a65726f206973206e6f74206120766160008201527f6c6964206f776e65720000000000000000000000000000000000000000000000602082015250565b60006200203560298362001a52565b9150620020428262001fd7565b604082019050919050565b60006020820190508181036000830152620020688162002026565b9050919050565b615c35806200207f6000396000f3fe608060405234801561001057600080fd5b506004361061023c5760003560e01c8063715018a61161013b578063ca15c873116100b8578063e104f60c1161007c578063e104f60c146106dc578063e985e9c5146106e6578063f0ba844014610716578063f0c136cb14610749578063f2fde38b146107655761023c565b8063ca15c87314610636578063d539139314610666578063d547741f14610684578063d5abeb01146106a0578063d607497a146106be5761023c565b806395d89b41116100ff57806395d89b4114610592578063a217fddf146105b0578063a22cb465146105ce578063b88d4fde146105ea578063c87b56dd146106065761023c565b8063715018a6146104ec57806375b238fc146104f65780638da5cb5b146105145780639010d07c1461053257806391d14854146105625761023c565b80632a55205a116101c957806342842e0e1161018d57806342842e0e146104245780634f6ccce71461044057806358ff857c146104705780636352211e1461048c57806370a08231146104bc5761023c565b80632a55205a1461036d5780632f2ff15d1461039e5780632f745c59146103ba57806336568abe146103ea57806341f43434146104065761023c565b8063095ea7b311610210578063095ea7b3146102dd57806314b2542b146102f957806318160ddd1461030357806323b872dd14610321578063248a9ca31461033d5761023c565b8062f9a5aa1461024157806301ffc9a71461025f57806306fdde031461028f578063081812fc146102ad575b600080fd5b610249610781565b6040516102569190613c44565b60405180910390f35b61027960048036038101906102749190613ccb565b610794565b6040516102869190613c44565b60405180910390f35b6102976107c6565b6040516102a49190613d88565b60405180910390f35b6102c760048036038101906102c29190613de0565b610858565b6040516102d49190613e4e565b60405180910390f35b6102f760048036038101906102f29190613e95565b61089e565b005b6103016108b7565b005b61030b61093d565b6040516103189190613ee4565b60405180910390f35b61033b60048036038101906103369190613eff565b61094a565b005b61035760048036038101906103529190613f88565b610999565b6040516103649190613fc4565b60405180910390f35b61038760048036038101906103829190613fdf565b6109b9565b60405161039592919061401f565b60405180910390f35b6103b860048036038101906103b39190614048565b610ba3565b005b6103d460048036038101906103cf9190613e95565b610bc4565b6040516103e19190613ee4565b60405180910390f35b61040460048036038101906103ff9190614048565b610c69565b005b61040e610cec565b60405161041b91906140e7565b60405180910390f35b61043e60048036038101906104399190613eff565b610cfe565b005b61045a60048036038101906104559190613de0565b610d4d565b6040516104679190613ee4565b60405180910390f35b61048a60048036038101906104859190614142565b610dbe565b005b6104a660048036038101906104a19190613de0565b610e84565b6040516104b39190613e4e565b60405180910390f35b6104d660048036038101906104d191906141a9565b610f0a565b6040516104e39190613ee4565b60405180910390f35b6104f4610fc1565b005b6104fe610fd5565b60405161050b9190613fc4565b60405180910390f35b61051c610ff9565b6040516105299190613e4e565b60405180910390f35b61054c600480360381019061054791906141d6565b611023565b6040516105599190613e4e565b60405180910390f35b61057c60048036038101906105779190614048565b611052565b6040516105899190613c44565b60405180910390f35b61059a6110bd565b6040516105a79190613d88565b60405180910390f35b6105b861114f565b6040516105c59190613fc4565b60405180910390f35b6105e860048036038101906105e39190614242565b611156565b005b61060460048036038101906105ff91906143b7565b61116f565b005b610620600480360381019061061b9190613de0565b6111c0565b60405161062d9190613d88565b60405180910390f35b610650600480360381019061064b9190613f88565b6114d9565b60405161065d9190613ee4565b60405180910390f35b61066e6114fd565b60405161067b9190613fc4565b60405180910390f35b61069e60048036038101906106999190614048565b611521565b005b6106a8611542565b6040516106b59190613ee4565b60405180910390f35b6106c6611548565b6040516106d3919061445b565b60405180910390f35b6106e461156e565b005b61070060048036038101906106fb9190614476565b6115e7565b60405161070d9190613c44565b60405180910390f35b610730600480360381019061072b9190613de0565b61167b565b60405161074094939291906144c5565b60405180910390f35b610763600480360381019061075e91906141a9565b6116fb565b005b61077f600480360381019061077a91906141a9565b6117f8565b005b600f60009054906101000a900460ff1681565b600061079f826119b5565b806107af57506107ae82611a2f565b5b806107bf57506107be82611aa9565b5b9050919050565b6060600080546107d590614539565b80601f016020809104026020016040519081016040528092919081815260200182805461080190614539565b801561084e5780601f106108235761010080835404028352916020019161084e565b820191906000526020600020905b81548152906001019060200180831161083157829003601f168201915b5050505050905090565b600061086382611b23565b6004600083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b816108a881611b6e565b6108b28383611c6b565b505050565b6108e17fa49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c2177533611052565b610920576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610917906145dc565b60405180910390fd5b6001600f60006101000a81548160ff021916908315150217905550565b6000600880549050905090565b823373ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16146109885761098733611b6e565b5b610993848484611d82565b50505050565b6000600b6000838152602001908152602001600020600101549050919050565b6000806000600e60008681526020019081526020016000206040518060400160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016000820160149054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff16815250509050600073ffffffffffffffffffffffffffffffffffffffff16816000015173ffffffffffffffffffffffffffffffffffffffff1603610b4e57600d6040518060400160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016000820160149054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff168152505090505b6000610b58611de2565b6bffffffffffffffffffffffff1682602001516bffffffffffffffffffffffff1686610b84919061462b565b610b8e919061469c565b90508160000151819350935050509250929050565b610bac82610999565b610bb581611dec565b610bbf8383611e00565b505050565b6000610bcf83610f0a565b8210610c10576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610c079061473f565b60405180910390fd5b600660008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600083815260200190815260200160002054905092915050565b610c71611e34565b73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614610cde576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610cd5906147d1565b60405180910390fd5b610ce88282611e3c565b5050565b6daaeb6d7670e522a718067333cd4e81565b823373ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614610d3c57610d3b33611b6e565b5b610d47848484611e70565b50505050565b6000610d5761093d565b8210610d98576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610d8f90614863565b60405180910390fd5b60088281548110610dac57610dab614883565b5b90600052602060002001549050919050565b610de87f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a633611052565b610e27576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610e1e90614924565b60405180910390fd5b601054610e3261093d565b10610e72576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610e6990614990565b60405180910390fd5b610e7e84848484611e90565b50505050565b600080610e9083611ffd565b9050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610f01576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610ef8906149fc565b60405180910390fd5b80915050919050565b60008073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603610f7a576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610f7190614a8e565b60405180910390fd5b600360008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b610fc961203a565b610fd360006120b8565b565b7fa49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c2177581565b6000600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b600061104a82600c600086815260200190815260200160002061217e90919063ffffffff16565b905092915050565b6000600b600084815260200190815260200160002060000160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16905092915050565b6060600180546110cc90614539565b80601f01602080910402602001604051908101604052809291908181526020018280546110f890614539565b80156111455780601f1061111a57610100808354040283529160200191611145565b820191906000526020600020905b81548152906001019060200180831161112857829003601f168201915b5050505050905090565b6000801b81565b8161116081611b6e565b61116a8383612198565b505050565b833373ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16146111ad576111ac33611b6e565b5b6111b9858585856121ae565b5050505050565b60606000601160008481526020019081526020016000206040518060800160405290816000820160009054906101000a900467ffffffffffffffff1667ffffffffffffffff1667ffffffffffffffff1681526020016000820160089054906101000a900467ffffffffffffffff1667ffffffffffffffff1667ffffffffffffffff1681526020016000820160109054906101000a900467ffffffffffffffff1667ffffffffffffffff1667ffffffffffffffff1681526020016000820160189054906101000a900467ffffffffffffffff1667ffffffffffffffff1667ffffffffffffffff1681525050905060006114ae6112ba85612210565b601260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663758127fa85600001518660200151876040015188606001516040518563ffffffff1660e01b815260040161132b9493929190614adf565b600060405180830381865afa158015611348573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f820116820180604052508101906113719190614bc5565b601260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166387257f6b86600001518760200151886040015189606001516040518563ffffffff1660e01b81526004016113e29493929190614adf565b600060405180830381865afa1580156113ff573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f820116820180604052508101906114289190614bc5565b61143f866000015167ffffffffffffffff16612210565b611456876020015167ffffffffffffffff16612210565b61146d886040015167ffffffffffffffff16612210565b611484896060015167ffffffffffffffff16612210565b60405160200161149a979695949392919061504c565b6040516020818303038152906040526122de565b6040516020016114be9190615160565b60405160208183030381529060405290508092505050919050565b60006114f6600c6000848152602001908152602001600020612441565b9050919050565b7f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a681565b61152a82610999565b61153381611dec565b61153d8383611e3c565b505050565b60105481565b601260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6115987fa49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c2177533611052565b6115d7576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016115ce906145dc565b60405180910390fd5b6115df61093d565b601081905550565b6000600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16905092915050565b60116020528060005260406000206000915090508060000160009054906101000a900467ffffffffffffffff16908060000160089054906101000a900467ffffffffffffffff16908060000160109054906101000a900467ffffffffffffffff16908060000160189054906101000a900467ffffffffffffffff16905084565b6117257fa49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c2177533611052565b611764576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161175b906145dc565b60405180910390fd5b600f60009054906101000a900460ff16156117b4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016117ab906151ce565b60405180910390fd5b80601260006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b61180061203a565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff160361186f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161186690615260565b60405180910390fd5b611878816120b8565b50565b6118858282611052565b611958576001600b600084815260200190815260200160002060000160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055506118fd611e34565b73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45b5050565b6000611984836000018373ffffffffffffffffffffffffffffffffffffffff1660001b612456565b905092915050565b6000808273ffffffffffffffffffffffffffffffffffffffff163b119050919050565b50505050565b60007f780e9d63000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161480611a285750611a27826124c6565b5b9050919050565b60007f5a05180f000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161480611aa25750611aa1826125a8565b5b9050919050565b60007f2a55205a000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161480611b1c5750611b1b82611a2f565b5b9050919050565b611b2c81612622565b611b6b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611b62906149fc565b60405180910390fd5b50565b60006daaeb6d7670e522a718067333cd4e73ffffffffffffffffffffffffffffffffffffffff163b1115611c68576daaeb6d7670e522a718067333cd4e73ffffffffffffffffffffffffffffffffffffffff1663c617113430836040518363ffffffff1660e01b8152600401611be5929190615280565b602060405180830381865afa158015611c02573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611c2691906152be565b611c6757806040517fede71dcc000000000000000000000000000000000000000000000000000000008152600401611c5e9190613e4e565b60405180910390fd5b5b50565b6000611c7682610e84565b90508073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1603611ce6576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611cdd9061535d565b60405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff16611d05611e34565b73ffffffffffffffffffffffffffffffffffffffff161480611d345750611d3381611d2e611e34565b6115e7565b5b611d73576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611d6a906153ef565b60405180910390fd5b611d7d8383612663565b505050565b611d93611d8d611e34565b8261271c565b611dd2576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611dc990615481565b60405180910390fd5b611ddd8383836127b1565b505050565b6000612710905090565b611dfd81611df8611e34565b612aaa565b50565b611e0a828261187b565b611e2f81600c600085815260200190815260200160002061195c90919063ffffffff16565b505050565b600033905090565b611e468282612b2f565b611e6b81600c6000858152602001908152602001600020612c1190919063ffffffff16565b505050565b611e8b8383836040518060200160405280600081525061116f565b505050565b600083838387604051602001611ea994939291906154a1565b6040516020818303038152906040528051906020012060001c90506000611ece61093d565b905060405180608001604052808667ffffffffffffffff1681526020018567ffffffffffffffff1681526020018467ffffffffffffffff1681526020018367ffffffffffffffff168152506011600083815260200190815260200160002060008201518160000160006101000a81548167ffffffffffffffff021916908367ffffffffffffffff16021790555060208201518160000160086101000a81548167ffffffffffffffff021916908367ffffffffffffffff16021790555060408201518160000160106101000a81548167ffffffffffffffff021916908367ffffffffffffffff16021790555060608201518160000160186101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550905050611ff58682612c41565b505050505050565b60006002600083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b612042611e34565b73ffffffffffffffffffffffffffffffffffffffff16612060610ff9565b73ffffffffffffffffffffffffffffffffffffffff16146120b6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016120ad90615532565b60405180910390fd5b565b6000600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905081600a60006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b600061218d8360000183612c5f565b60001c905092915050565b6121aa6121a3611e34565b8383612c8a565b5050565b6121bf6121b9611e34565b8361271c565b6121fe576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016121f590615481565b60405180910390fd5b61220a84848484612df6565b50505050565b60606000600161221f84612e52565b01905060008167ffffffffffffffff81111561223e5761223d61428c565b5b6040519080825280601f01601f1916602001820160405280156122705781602001600182028036833780820191505090505b509050600082602001820190505b6001156122d3578080600190039150507f3031323334353637383961626364656600000000000000000000000000000000600a86061a8153600a85816122c7576122c661466d565b5b0494506000850361227e575b819350505050919050565b606060008251036123005760405180602001604052806000815250905061243c565b6000604051806060016040528060408152602001615bc0604091399050600060036002855161232f9190615552565b612339919061469c565b6004612345919061462b565b67ffffffffffffffff81111561235e5761235d61428c565b5b6040519080825280601f01601f1916602001820160405280156123905781602001600182028036833780820191505090505b509050600182016020820185865187015b808210156123fc576003820191508151603f8160121c168501518453600184019350603f81600c1c168501518453600184019350603f8160061c168501518453600184019350603f81168501518453600184019350506123a1565b5050600386510660018114612418576002811461242b57612433565b603d6001830353603d6002830353612433565b603d60018303535b50505080925050505b919050565b600061244f82600001612fa5565b9050919050565b60006124628383612fb6565b6124bb5782600001829080600181540180825580915050600190039060005260206000200160009091909190915055826000018054905083600101600084815260200190815260200160002081905550600190506124c0565b600090505b92915050565b60007f80ac58cd000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916148061259157507f5b5e139f000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b806125a157506125a082612fd9565b5b9050919050565b60007f7965db0b000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916148061261b575061261a826119b5565b5b9050919050565b60008073ffffffffffffffffffffffffffffffffffffffff1661264483611ffd565b73ffffffffffffffffffffffffffffffffffffffff1614159050919050565b816004600083815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550808273ffffffffffffffffffffffffffffffffffffffff166126d683610e84565b73ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b60008061272883610e84565b90508073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff16148061276a575061276981856115e7565b5b806127a857508373ffffffffffffffffffffffffffffffffffffffff1661279084610858565b73ffffffffffffffffffffffffffffffffffffffff16145b91505092915050565b8273ffffffffffffffffffffffffffffffffffffffff166127d182610e84565b73ffffffffffffffffffffffffffffffffffffffff1614612827576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161281e906155f8565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603612896576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161288d9061568a565b60405180910390fd5b6128a38383836001613043565b8273ffffffffffffffffffffffffffffffffffffffff166128c382610e84565b73ffffffffffffffffffffffffffffffffffffffff1614612919576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612910906155f8565b60405180910390fd5b6004600082815260200190815260200160002060006101000a81549073ffffffffffffffffffffffffffffffffffffffff02191690556001600360008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825403925050819055506001600360008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282540192505081905550816002600083815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550808273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a4612aa583838360016131a1565b505050565b612ab48282611052565b612b2b57612ac1816131a7565b612acf8360001c60206131d4565b604051602001612ae0929190615742565b6040516020818303038152906040526040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612b229190613d88565b60405180910390fd5b5050565b612b398282611052565b15612c0d576000600b600084815260200190815260200160002060000160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff021916908315150217905550612bb2611e34565b73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16837ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b60405160405180910390a45b5050565b6000612c39836000018373ffffffffffffffffffffffffffffffffffffffff1660001b613410565b905092915050565b612c5b828260405180602001604052806000815250613524565b5050565b6000826000018281548110612c7757612c76614883565b5b9060005260206000200154905092915050565b8173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1603612cf8576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612cef906157c8565b60405180910390fd5b80600560008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c3183604051612de99190613c44565b60405180910390a3505050565b612e018484846127b1565b612e0d8484848461357f565b612e4c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612e439061585a565b60405180910390fd5b50505050565b600080600090507a184f03e93ff9f4daa797ed6e38ed64bf6a1f0100000000000000008310612eb0577a184f03e93ff9f4daa797ed6e38ed64bf6a1f0100000000000000008381612ea657612ea561466d565b5b0492506040810190505b6d04ee2d6d415b85acef81000000008310612eed576d04ee2d6d415b85acef81000000008381612ee357612ee261466d565b5b0492506020810190505b662386f26fc100008310612f1c57662386f26fc100008381612f1257612f1161466d565b5b0492506010810190505b6305f5e1008310612f45576305f5e1008381612f3b57612f3a61466d565b5b0492506008810190505b6127108310612f6a576127108381612f6057612f5f61466d565b5b0492506004810190505b60648310612f8d5760648381612f8357612f8261466d565b5b0492506002810190505b600a8310612f9c576001810190505b80915050919050565b600081600001805490509050919050565b600080836001016000848152602001908152602001600020541415905092915050565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916149050919050565b61304f848484846119af565b6001811115613093576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161308a906158ec565b60405180910390fd5b6000829050600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff16036130da576130d581613706565b613119565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff161461311857613117858261374f565b5b5b600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff160361315b57613156816138bc565b61319a565b8473ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff161461319957613198848261398d565b5b5b5050505050565b50505050565b60606131cd8273ffffffffffffffffffffffffffffffffffffffff16601460ff166131d4565b9050919050565b6060600060028360026131e7919061462b565b6131f19190615552565b67ffffffffffffffff81111561320a5761320961428c565b5b6040519080825280601f01601f19166020018201604052801561323c5781602001600182028036833780820191505090505b5090507f30000000000000000000000000000000000000000000000000000000000000008160008151811061327457613273614883565b5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053507f7800000000000000000000000000000000000000000000000000000000000000816001815181106132d8576132d7614883565b5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535060006001846002613318919061462b565b6133229190615552565b90505b60018111156133c2577f3031323334353637383961626364656600000000000000000000000000000000600f86166010811061336457613363614883565b5b1a60f81b82828151811061337b5761337a614883565b5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350600485901c9450806133bb9061590c565b9050613325565b5060008414613406576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016133fd90615981565b60405180910390fd5b8091505092915050565b6000808360010160008481526020019081526020016000205490506000811461351857600060018261344291906159a1565b905060006001866000018054905061345a91906159a1565b90508181146134c957600086600001828154811061347b5761347a614883565b5b906000526020600020015490508087600001848154811061349f5761349e614883565b5b90600052602060002001819055508387600101600083815260200190815260200160002081905550505b856000018054806134dd576134dc6159d5565b5b60019003818190600052602060002001600090559055856001016000868152602001908152602001600020600090556001935050505061351e565b60009150505b92915050565b61352e8383613a0c565b61353b600084848461357f565b61357a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016135719061585a565b60405180910390fd5b505050565b60006135a08473ffffffffffffffffffffffffffffffffffffffff1661198c565b156136f9578373ffffffffffffffffffffffffffffffffffffffff1663150b7a026135c9611e34565b8786866040518563ffffffff1660e01b81526004016135eb9493929190615a59565b6020604051808303816000875af192505050801561362757506040513d601f19601f820116820180604052508101906136249190615aba565b60015b6136a9573d8060008114613657576040519150601f19603f3d011682016040523d82523d6000602084013e61365c565b606091505b5060008151036136a1576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016136989061585a565b60405180910390fd5b805181602001fd5b63150b7a0260e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916149150506136fe565b600190505b949350505050565b6008805490506009600083815260200190815260200160002081905550600881908060018154018082558091505060019003906000526020600020016000909190919091505550565b6000600161375c84610f0a565b61376691906159a1565b905060006007600084815260200190815260200160002054905081811461384b576000600660008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600084815260200190815260200160002054905080600660008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600084815260200190815260200160002081905550816007600083815260200190815260200160002081905550505b6007600084815260200190815260200160002060009055600660008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008381526020019081526020016000206000905550505050565b600060016008805490506138d091906159a1565b9050600060096000848152602001908152602001600020549050600060088381548110613900576138ff614883565b5b90600052602060002001549050806008838154811061392257613921614883565b5b906000526020600020018190555081600960008381526020019081526020016000208190555060096000858152602001908152602001600020600090556008805480613971576139706159d5565b5b6001900381819060005260206000200160009055905550505050565b600061399883610f0a565b905081600660008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600083815260200190815260200160002081905550806007600084815260200190815260200160002081905550505050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603613a7b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401613a7290615b33565b60405180910390fd5b613a8481612622565b15613ac4576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401613abb90615b9f565b60405180910390fd5b613ad2600083836001613043565b613adb81612622565b15613b1b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401613b1290615b9f565b60405180910390fd5b6001600360008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282540192505081905550816002600083815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550808273ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a4613c256000838360016131a1565b5050565b60008115159050919050565b613c3e81613c29565b82525050565b6000602082019050613c596000830184613c35565b92915050565b6000604051905090565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b613ca881613c73565b8114613cb357600080fd5b50565b600081359050613cc581613c9f565b92915050565b600060208284031215613ce157613ce0613c69565b5b6000613cef84828501613cb6565b91505092915050565b600081519050919050565b600082825260208201905092915050565b60005b83811015613d32578082015181840152602081019050613d17565b60008484015250505050565b6000601f19601f8301169050919050565b6000613d5a82613cf8565b613d648185613d03565b9350613d74818560208601613d14565b613d7d81613d3e565b840191505092915050565b60006020820190508181036000830152613da28184613d4f565b905092915050565b6000819050919050565b613dbd81613daa565b8114613dc857600080fd5b50565b600081359050613dda81613db4565b92915050565b600060208284031215613df657613df5613c69565b5b6000613e0484828501613dcb565b91505092915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000613e3882613e0d565b9050919050565b613e4881613e2d565b82525050565b6000602082019050613e636000830184613e3f565b92915050565b613e7281613e2d565b8114613e7d57600080fd5b50565b600081359050613e8f81613e69565b92915050565b60008060408385031215613eac57613eab613c69565b5b6000613eba85828601613e80565b9250506020613ecb85828601613dcb565b9150509250929050565b613ede81613daa565b82525050565b6000602082019050613ef96000830184613ed5565b92915050565b600080600060608486031215613f1857613f17613c69565b5b6000613f2686828701613e80565b9350506020613f3786828701613e80565b9250506040613f4886828701613dcb565b9150509250925092565b6000819050919050565b613f6581613f52565b8114613f7057600080fd5b50565b600081359050613f8281613f5c565b92915050565b600060208284031215613f9e57613f9d613c69565b5b6000613fac84828501613f73565b91505092915050565b613fbe81613f52565b82525050565b6000602082019050613fd96000830184613fb5565b92915050565b60008060408385031215613ff657613ff5613c69565b5b600061400485828601613dcb565b925050602061401585828601613dcb565b9150509250929050565b60006040820190506140346000830185613e3f565b6140416020830184613ed5565b9392505050565b6000806040838503121561405f5761405e613c69565b5b600061406d85828601613f73565b925050602061407e85828601613e80565b9150509250929050565b6000819050919050565b60006140ad6140a86140a384613e0d565b614088565b613e0d565b9050919050565b60006140bf82614092565b9050919050565b60006140d1826140b4565b9050919050565b6140e1816140c6565b82525050565b60006020820190506140fc60008301846140d8565b92915050565b600067ffffffffffffffff82169050919050565b61411f81614102565b811461412a57600080fd5b50565b60008135905061413c81614116565b92915050565b6000806000806080858703121561415c5761415b613c69565b5b600061416a87828801613e80565b945050602061417b8782880161412d565b935050604061418c8782880161412d565b925050606061419d8782880161412d565b91505092959194509250565b6000602082840312156141bf576141be613c69565b5b60006141cd84828501613e80565b91505092915050565b600080604083850312156141ed576141ec613c69565b5b60006141fb85828601613f73565b925050602061420c85828601613dcb565b9150509250929050565b61421f81613c29565b811461422a57600080fd5b50565b60008135905061423c81614216565b92915050565b6000806040838503121561425957614258613c69565b5b600061426785828601613e80565b92505060206142788582860161422d565b9150509250929050565b600080fd5b600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6142c482613d3e565b810181811067ffffffffffffffff821117156142e3576142e261428c565b5b80604052505050565b60006142f6613c5f565b905061430282826142bb565b919050565b600067ffffffffffffffff8211156143225761432161428c565b5b61432b82613d3e565b9050602081019050919050565b82818337600083830152505050565b600061435a61435584614307565b6142ec565b90508281526020810184848401111561437657614375614287565b5b614381848285614338565b509392505050565b600082601f83011261439e5761439d614282565b5b81356143ae848260208601614347565b91505092915050565b600080600080608085870312156143d1576143d0613c69565b5b60006143df87828801613e80565b94505060206143f087828801613e80565b935050604061440187828801613dcb565b925050606085013567ffffffffffffffff81111561442257614421613c6e565b5b61442e87828801614389565b91505092959194509250565b6000614445826140b4565b9050919050565b6144558161443a565b82525050565b6000602082019050614470600083018461444c565b92915050565b6000806040838503121561448d5761448c613c69565b5b600061449b85828601613e80565b92505060206144ac85828601613e80565b9150509250929050565b6144bf81614102565b82525050565b60006080820190506144da60008301876144b6565b6144e760208301866144b6565b6144f460408301856144b6565b61450160608301846144b6565b95945050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b6000600282049050600182168061455157607f821691505b6020821081036145645761456361450a565b5b50919050565b7f596f75206d75737420626520616e2041646d696e20746f20706572666f726d2060008201527f7468697320616374696f6e000000000000000000000000000000000000000000602082015250565b60006145c6602b83613d03565b91506145d18261456a565b604082019050919050565b600060208201905081810360008301526145f5816145b9565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061463682613daa565b915061464183613daa565b925082820261464f81613daa565b91508282048414831517614666576146656145fc565b5b5092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60006146a782613daa565b91506146b283613daa565b9250826146c2576146c161466d565b5b828204905092915050565b7f455243373231456e756d657261626c653a206f776e657220696e646578206f7560008201527f74206f6620626f756e6473000000000000000000000000000000000000000000602082015250565b6000614729602b83613d03565b9150614734826146cd565b604082019050919050565b600060208201905081810360008301526147588161471c565b9050919050565b7f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560008201527f20726f6c657320666f722073656c660000000000000000000000000000000000602082015250565b60006147bb602f83613d03565b91506147c68261475f565b604082019050919050565b600060208201905081810360008301526147ea816147ae565b9050919050565b7f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60008201527f7574206f6620626f756e64730000000000000000000000000000000000000000602082015250565b600061484d602c83613d03565b9150614858826147f1565b604082019050919050565b6000602082019050818103600083015261487c81614840565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f596f75206d7573742062652061204d696e74657220746f20706572666f726d2060008201527f7468697320616374696f6e000000000000000000000000000000000000000000602082015250565b600061490e602b83613d03565b9150614919826148b2565b604082019050919050565b6000602082019050818103600083015261493d81614901565b9050919050565b7f4d617820537570706c7920526561636865640000000000000000000000000000600082015250565b600061497a601283613d03565b915061498582614944565b602082019050919050565b600060208201905081810360008301526149a98161496d565b9050919050565b7f4552433732313a20696e76616c696420746f6b656e2049440000000000000000600082015250565b60006149e6601883613d03565b91506149f1826149b0565b602082019050919050565b60006020820190508181036000830152614a15816149d9565b9050919050565b7f4552433732313a2061646472657373207a65726f206973206e6f74206120766160008201527f6c6964206f776e65720000000000000000000000000000000000000000000000602082015250565b6000614a78602983613d03565b9150614a8382614a1c565b604082019050919050565b60006020820190508181036000830152614aa781614a6b565b9050919050565b6000614ac9614ac4614abf84614102565b614088565b613daa565b9050919050565b614ad981614aae565b82525050565b6000608082019050614af46000830187614ad0565b614b016020830186614ad0565b614b0e6040830185614ad0565b614b1b6060830184614ad0565b95945050505050565b600067ffffffffffffffff821115614b3f57614b3e61428c565b5b614b4882613d3e565b9050602081019050919050565b6000614b68614b6384614b24565b6142ec565b905082815260208101848484011115614b8457614b83614287565b5b614b8f848285613d14565b509392505050565b600082601f830112614bac57614bab614282565b5b8151614bbc848260208601614b55565b91505092915050565b600060208284031215614bdb57614bda613c69565b5b600082015167ffffffffffffffff811115614bf957614bf8613c6e565b5b614c0584828501614b97565b91505092915050565b600081905092915050565b7f7b226e616d65223a22504f4c2023000000000000000000000000000000000000600082015250565b6000614c4f600e83614c0e565b9150614c5a82614c19565b600e82019050919050565b6000614c7082613cf8565b614c7a8185614c0e565b9350614c8a818560208601613d14565b80840191505092915050565b7f222c22696d616765223a22000000000000000000000000000000000000000000600082015250565b6000614ccc600b83614c0e565b9150614cd782614c96565b600b82019050919050565b7f222c226465736372697074696f6e223a202257652077616e7420746f2062756960008201527f6c642074686520776f726c642773206c61726765737420656d6f74696f6e616c60208201527f204e465420696e69746961746976652c207472616e73666f726d696e6720636f60408201527f6d6d756e697479206c69766573747265616d2073656e74696d656e747320696e60608201527f746f2070657270657475616c6c79206f6e2d636861696e207265636f7264656460808201527f2067656f6d657472696320617274776f726b73222c000000000000000000000060a082015250565b6000614dd660b583614c0e565b9150614de182614ce2565b60b582019050919050565b7f22616e696d6174696f6e5f75726c223a22000000000000000000000000000000600082015250565b6000614e22601183614c0e565b9150614e2d82614dec565b601182019050919050565b7f222c202261747472696275746573223a5b7b2274726169745f74797065223a2060008201527f22706f736974697665222c202276616c7565223a000000000000000000000000602082015250565b6000614e94603483614c0e565b9150614e9f82614e38565b603482019050919050565b7f7d2c7b2274726169745f74797065223a20226e65676174697665222c2022766160008201527f6c7565223a000000000000000000000000000000000000000000000000000000602082015250565b6000614f06602583614c0e565b9150614f1182614eaa565b602582019050919050565b7f7d2c7b2274726169745f74797065223a20226e65757472616c222c202276616c60008201527f7565223a00000000000000000000000000000000000000000000000000000000602082015250565b6000614f78602483614c0e565b9150614f8382614f1c565b602482019050919050565b7f7d2c7b2274726169745f74797065223a202273656564222c202276616c75652260008201527f3a22000000000000000000000000000000000000000000000000000000000000602082015250565b6000614fea602283614c0e565b9150614ff582614f8e565b602282019050919050565b7f227d5d7d00000000000000000000000000000000000000000000000000000000600082015250565b6000615036600483614c0e565b915061504182615000565b600482019050919050565b600061505782614c42565b9150615063828a614c65565b915061506e82614cbf565b915061507a8289614c65565b915061508582614dc9565b915061509082614e15565b915061509c8288614c65565b91506150a782614e87565b91506150b38287614c65565b91506150be82614ef9565b91506150ca8286614c65565b91506150d582614f6b565b91506150e18285614c65565b91506150ec82614fdd565b91506150f88284614c65565b915061510382615029565b915081905098975050505050505050565b7f646174613a6170706c69636174696f6e2f6a736f6e3b6261736536342c000000600082015250565b600061514a601d83614c0e565b915061515582615114565b601d82019050919050565b600061516b8261513d565b91506151778284614c65565b915081905092915050565b7f4d6574616461746173206172652066726f7a656e000000000000000000000000600082015250565b60006151b8601483613d03565b91506151c382615182565b602082019050919050565b600060208201905081810360008301526151e7816151ab565b9050919050565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160008201527f6464726573730000000000000000000000000000000000000000000000000000602082015250565b600061524a602683613d03565b9150615255826151ee565b604082019050919050565b600060208201905081810360008301526152798161523d565b9050919050565b60006040820190506152956000830185613e3f565b6152a26020830184613e3f565b9392505050565b6000815190506152b881614216565b92915050565b6000602082840312156152d4576152d3613c69565b5b60006152e2848285016152a9565b91505092915050565b7f4552433732313a20617070726f76616c20746f2063757272656e74206f776e6560008201527f7200000000000000000000000000000000000000000000000000000000000000602082015250565b6000615347602183613d03565b9150615352826152eb565b604082019050919050565b600060208201905081810360008301526153768161533a565b9050919050565b7f4552433732313a20617070726f76652063616c6c6572206973206e6f7420746f60008201527f6b656e206f776e6572206f7220617070726f76656420666f7220616c6c000000602082015250565b60006153d9603d83613d03565b91506153e48261537d565b604082019050919050565b60006020820190508181036000830152615408816153cc565b9050919050565b7f4552433732313a2063616c6c6572206973206e6f7420746f6b656e206f776e6560008201527f72206f7220617070726f76656400000000000000000000000000000000000000602082015250565b600061546b602d83613d03565b91506154768261540f565b604082019050919050565b6000602082019050818103600083015261549a8161545e565b9050919050565b60006080820190506154b660008301876144b6565b6154c360208301866144b6565b6154d060408301856144b6565b6154dd6060830184613e3f565b95945050505050565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572600082015250565b600061551c602083613d03565b9150615527826154e6565b602082019050919050565b6000602082019050818103600083015261554b8161550f565b9050919050565b600061555d82613daa565b915061556883613daa565b92508282019050808211156155805761557f6145fc565b5b92915050565b7f4552433732313a207472616e736665722066726f6d20696e636f72726563742060008201527f6f776e6572000000000000000000000000000000000000000000000000000000602082015250565b60006155e2602583613d03565b91506155ed82615586565b604082019050919050565b60006020820190508181036000830152615611816155d5565b9050919050565b7f4552433732313a207472616e7366657220746f20746865207a65726f2061646460008201527f7265737300000000000000000000000000000000000000000000000000000000602082015250565b6000615674602483613d03565b915061567f82615618565b604082019050919050565b600060208201905081810360008301526156a381615667565b9050919050565b7f416363657373436f6e74726f6c3a206163636f756e7420000000000000000000600082015250565b60006156e0601783614c0e565b91506156eb826156aa565b601782019050919050565b7f206973206d697373696e6720726f6c6520000000000000000000000000000000600082015250565b600061572c601183614c0e565b9150615737826156f6565b601182019050919050565b600061574d826156d3565b91506157598285614c65565b91506157648261571f565b91506157708284614c65565b91508190509392505050565b7f4552433732313a20617070726f766520746f2063616c6c657200000000000000600082015250565b60006157b2601983613d03565b91506157bd8261577c565b602082019050919050565b600060208201905081810360008301526157e1816157a5565b9050919050565b7f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560008201527f63656976657220696d706c656d656e7465720000000000000000000000000000602082015250565b6000615844603283613d03565b915061584f826157e8565b604082019050919050565b6000602082019050818103600083015261587381615837565b9050919050565b7f455243373231456e756d657261626c653a20636f6e736563757469766520747260008201527f616e7366657273206e6f7420737570706f727465640000000000000000000000602082015250565b60006158d6603583613d03565b91506158e18261587a565b604082019050919050565b60006020820190508181036000830152615905816158c9565b9050919050565b600061591782613daa565b91506000820361592a576159296145fc565b5b600182039050919050565b7f537472696e67733a20686578206c656e67746820696e73756666696369656e74600082015250565b600061596b602083613d03565b915061597682615935565b602082019050919050565b6000602082019050818103600083015261599a8161595e565b9050919050565b60006159ac82613daa565b91506159b783613daa565b92508282039050818111156159cf576159ce6145fc565b5b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600081519050919050565b600082825260208201905092915050565b6000615a2b82615a04565b615a358185615a0f565b9350615a45818560208601613d14565b615a4e81613d3e565b840191505092915050565b6000608082019050615a6e6000830187613e3f565b615a7b6020830186613e3f565b615a886040830185613ed5565b8181036060830152615a9a8184615a20565b905095945050505050565b600081519050615ab481613c9f565b92915050565b600060208284031215615ad057615acf613c69565b5b6000615ade84828501615aa5565b91505092915050565b7f4552433732313a206d696e7420746f20746865207a65726f2061646472657373600082015250565b6000615b1d602083613d03565b9150615b2882615ae7565b602082019050919050565b60006020820190508181036000830152615b4c81615b10565b9050919050565b7f4552433732313a20746f6b656e20616c7265616479206d696e74656400000000600082015250565b6000615b89601c83613d03565b9150615b9482615b53565b602082019050919050565b60006020820190508181036000830152615bb881615b7c565b905091905056fe4142434445464748494a4b4c4d4e4f505152535455565758595a6162636465666768696a6b6c6d6e6f707172737475767778797a303132333435363738392b2fa26469706673582212208e9bedfe77995b3b426cbf50ac3ad6bf7f5e1cbd4b9caa72c4aab44feef6586864736f6c63430008120033000000000000000000000000c3937dc16711773a2d8b8a5d405b1307cbafe345

Deployed Bytecode

0x608060405234801561001057600080fd5b506004361061023c5760003560e01c8063715018a61161013b578063ca15c873116100b8578063e104f60c1161007c578063e104f60c146106dc578063e985e9c5146106e6578063f0ba844014610716578063f0c136cb14610749578063f2fde38b146107655761023c565b8063ca15c87314610636578063d539139314610666578063d547741f14610684578063d5abeb01146106a0578063d607497a146106be5761023c565b806395d89b41116100ff57806395d89b4114610592578063a217fddf146105b0578063a22cb465146105ce578063b88d4fde146105ea578063c87b56dd146106065761023c565b8063715018a6146104ec57806375b238fc146104f65780638da5cb5b146105145780639010d07c1461053257806391d14854146105625761023c565b80632a55205a116101c957806342842e0e1161018d57806342842e0e146104245780634f6ccce71461044057806358ff857c146104705780636352211e1461048c57806370a08231146104bc5761023c565b80632a55205a1461036d5780632f2ff15d1461039e5780632f745c59146103ba57806336568abe146103ea57806341f43434146104065761023c565b8063095ea7b311610210578063095ea7b3146102dd57806314b2542b146102f957806318160ddd1461030357806323b872dd14610321578063248a9ca31461033d5761023c565b8062f9a5aa1461024157806301ffc9a71461025f57806306fdde031461028f578063081812fc146102ad575b600080fd5b610249610781565b6040516102569190613c44565b60405180910390f35b61027960048036038101906102749190613ccb565b610794565b6040516102869190613c44565b60405180910390f35b6102976107c6565b6040516102a49190613d88565b60405180910390f35b6102c760048036038101906102c29190613de0565b610858565b6040516102d49190613e4e565b60405180910390f35b6102f760048036038101906102f29190613e95565b61089e565b005b6103016108b7565b005b61030b61093d565b6040516103189190613ee4565b60405180910390f35b61033b60048036038101906103369190613eff565b61094a565b005b61035760048036038101906103529190613f88565b610999565b6040516103649190613fc4565b60405180910390f35b61038760048036038101906103829190613fdf565b6109b9565b60405161039592919061401f565b60405180910390f35b6103b860048036038101906103b39190614048565b610ba3565b005b6103d460048036038101906103cf9190613e95565b610bc4565b6040516103e19190613ee4565b60405180910390f35b61040460048036038101906103ff9190614048565b610c69565b005b61040e610cec565b60405161041b91906140e7565b60405180910390f35b61043e60048036038101906104399190613eff565b610cfe565b005b61045a60048036038101906104559190613de0565b610d4d565b6040516104679190613ee4565b60405180910390f35b61048a60048036038101906104859190614142565b610dbe565b005b6104a660048036038101906104a19190613de0565b610e84565b6040516104b39190613e4e565b60405180910390f35b6104d660048036038101906104d191906141a9565b610f0a565b6040516104e39190613ee4565b60405180910390f35b6104f4610fc1565b005b6104fe610fd5565b60405161050b9190613fc4565b60405180910390f35b61051c610ff9565b6040516105299190613e4e565b60405180910390f35b61054c600480360381019061054791906141d6565b611023565b6040516105599190613e4e565b60405180910390f35b61057c60048036038101906105779190614048565b611052565b6040516105899190613c44565b60405180910390f35b61059a6110bd565b6040516105a79190613d88565b60405180910390f35b6105b861114f565b6040516105c59190613fc4565b60405180910390f35b6105e860048036038101906105e39190614242565b611156565b005b61060460048036038101906105ff91906143b7565b61116f565b005b610620600480360381019061061b9190613de0565b6111c0565b60405161062d9190613d88565b60405180910390f35b610650600480360381019061064b9190613f88565b6114d9565b60405161065d9190613ee4565b60405180910390f35b61066e6114fd565b60405161067b9190613fc4565b60405180910390f35b61069e60048036038101906106999190614048565b611521565b005b6106a8611542565b6040516106b59190613ee4565b60405180910390f35b6106c6611548565b6040516106d3919061445b565b60405180910390f35b6106e461156e565b005b61070060048036038101906106fb9190614476565b6115e7565b60405161070d9190613c44565b60405180910390f35b610730600480360381019061072b9190613de0565b61167b565b60405161074094939291906144c5565b60405180910390f35b610763600480360381019061075e91906141a9565b6116fb565b005b61077f600480360381019061077a91906141a9565b6117f8565b005b600f60009054906101000a900460ff1681565b600061079f826119b5565b806107af57506107ae82611a2f565b5b806107bf57506107be82611aa9565b5b9050919050565b6060600080546107d590614539565b80601f016020809104026020016040519081016040528092919081815260200182805461080190614539565b801561084e5780601f106108235761010080835404028352916020019161084e565b820191906000526020600020905b81548152906001019060200180831161083157829003601f168201915b5050505050905090565b600061086382611b23565b6004600083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b816108a881611b6e565b6108b28383611c6b565b505050565b6108e17fa49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c2177533611052565b610920576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610917906145dc565b60405180910390fd5b6001600f60006101000a81548160ff021916908315150217905550565b6000600880549050905090565b823373ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16146109885761098733611b6e565b5b610993848484611d82565b50505050565b6000600b6000838152602001908152602001600020600101549050919050565b6000806000600e60008681526020019081526020016000206040518060400160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016000820160149054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff16815250509050600073ffffffffffffffffffffffffffffffffffffffff16816000015173ffffffffffffffffffffffffffffffffffffffff1603610b4e57600d6040518060400160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016000820160149054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff168152505090505b6000610b58611de2565b6bffffffffffffffffffffffff1682602001516bffffffffffffffffffffffff1686610b84919061462b565b610b8e919061469c565b90508160000151819350935050509250929050565b610bac82610999565b610bb581611dec565b610bbf8383611e00565b505050565b6000610bcf83610f0a565b8210610c10576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610c079061473f565b60405180910390fd5b600660008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600083815260200190815260200160002054905092915050565b610c71611e34565b73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614610cde576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610cd5906147d1565b60405180910390fd5b610ce88282611e3c565b5050565b6daaeb6d7670e522a718067333cd4e81565b823373ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614610d3c57610d3b33611b6e565b5b610d47848484611e70565b50505050565b6000610d5761093d565b8210610d98576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610d8f90614863565b60405180910390fd5b60088281548110610dac57610dab614883565b5b90600052602060002001549050919050565b610de87f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a633611052565b610e27576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610e1e90614924565b60405180910390fd5b601054610e3261093d565b10610e72576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610e6990614990565b60405180910390fd5b610e7e84848484611e90565b50505050565b600080610e9083611ffd565b9050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610f01576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610ef8906149fc565b60405180910390fd5b80915050919050565b60008073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603610f7a576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610f7190614a8e565b60405180910390fd5b600360008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b610fc961203a565b610fd360006120b8565b565b7fa49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c2177581565b6000600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b600061104a82600c600086815260200190815260200160002061217e90919063ffffffff16565b905092915050565b6000600b600084815260200190815260200160002060000160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16905092915050565b6060600180546110cc90614539565b80601f01602080910402602001604051908101604052809291908181526020018280546110f890614539565b80156111455780601f1061111a57610100808354040283529160200191611145565b820191906000526020600020905b81548152906001019060200180831161112857829003601f168201915b5050505050905090565b6000801b81565b8161116081611b6e565b61116a8383612198565b505050565b833373ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16146111ad576111ac33611b6e565b5b6111b9858585856121ae565b5050505050565b60606000601160008481526020019081526020016000206040518060800160405290816000820160009054906101000a900467ffffffffffffffff1667ffffffffffffffff1667ffffffffffffffff1681526020016000820160089054906101000a900467ffffffffffffffff1667ffffffffffffffff1667ffffffffffffffff1681526020016000820160109054906101000a900467ffffffffffffffff1667ffffffffffffffff1667ffffffffffffffff1681526020016000820160189054906101000a900467ffffffffffffffff1667ffffffffffffffff1667ffffffffffffffff1681525050905060006114ae6112ba85612210565b601260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663758127fa85600001518660200151876040015188606001516040518563ffffffff1660e01b815260040161132b9493929190614adf565b600060405180830381865afa158015611348573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f820116820180604052508101906113719190614bc5565b601260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166387257f6b86600001518760200151886040015189606001516040518563ffffffff1660e01b81526004016113e29493929190614adf565b600060405180830381865afa1580156113ff573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f820116820180604052508101906114289190614bc5565b61143f866000015167ffffffffffffffff16612210565b611456876020015167ffffffffffffffff16612210565b61146d886040015167ffffffffffffffff16612210565b611484896060015167ffffffffffffffff16612210565b60405160200161149a979695949392919061504c565b6040516020818303038152906040526122de565b6040516020016114be9190615160565b60405160208183030381529060405290508092505050919050565b60006114f6600c6000848152602001908152602001600020612441565b9050919050565b7f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a681565b61152a82610999565b61153381611dec565b61153d8383611e3c565b505050565b60105481565b601260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6115987fa49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c2177533611052565b6115d7576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016115ce906145dc565b60405180910390fd5b6115df61093d565b601081905550565b6000600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16905092915050565b60116020528060005260406000206000915090508060000160009054906101000a900467ffffffffffffffff16908060000160089054906101000a900467ffffffffffffffff16908060000160109054906101000a900467ffffffffffffffff16908060000160189054906101000a900467ffffffffffffffff16905084565b6117257fa49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c2177533611052565b611764576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161175b906145dc565b60405180910390fd5b600f60009054906101000a900460ff16156117b4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016117ab906151ce565b60405180910390fd5b80601260006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b61180061203a565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff160361186f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161186690615260565b60405180910390fd5b611878816120b8565b50565b6118858282611052565b611958576001600b600084815260200190815260200160002060000160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055506118fd611e34565b73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45b5050565b6000611984836000018373ffffffffffffffffffffffffffffffffffffffff1660001b612456565b905092915050565b6000808273ffffffffffffffffffffffffffffffffffffffff163b119050919050565b50505050565b60007f780e9d63000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161480611a285750611a27826124c6565b5b9050919050565b60007f5a05180f000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161480611aa25750611aa1826125a8565b5b9050919050565b60007f2a55205a000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161480611b1c5750611b1b82611a2f565b5b9050919050565b611b2c81612622565b611b6b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611b62906149fc565b60405180910390fd5b50565b60006daaeb6d7670e522a718067333cd4e73ffffffffffffffffffffffffffffffffffffffff163b1115611c68576daaeb6d7670e522a718067333cd4e73ffffffffffffffffffffffffffffffffffffffff1663c617113430836040518363ffffffff1660e01b8152600401611be5929190615280565b602060405180830381865afa158015611c02573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611c2691906152be565b611c6757806040517fede71dcc000000000000000000000000000000000000000000000000000000008152600401611c5e9190613e4e565b60405180910390fd5b5b50565b6000611c7682610e84565b90508073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1603611ce6576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611cdd9061535d565b60405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff16611d05611e34565b73ffffffffffffffffffffffffffffffffffffffff161480611d345750611d3381611d2e611e34565b6115e7565b5b611d73576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611d6a906153ef565b60405180910390fd5b611d7d8383612663565b505050565b611d93611d8d611e34565b8261271c565b611dd2576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611dc990615481565b60405180910390fd5b611ddd8383836127b1565b505050565b6000612710905090565b611dfd81611df8611e34565b612aaa565b50565b611e0a828261187b565b611e2f81600c600085815260200190815260200160002061195c90919063ffffffff16565b505050565b600033905090565b611e468282612b2f565b611e6b81600c6000858152602001908152602001600020612c1190919063ffffffff16565b505050565b611e8b8383836040518060200160405280600081525061116f565b505050565b600083838387604051602001611ea994939291906154a1565b6040516020818303038152906040528051906020012060001c90506000611ece61093d565b905060405180608001604052808667ffffffffffffffff1681526020018567ffffffffffffffff1681526020018467ffffffffffffffff1681526020018367ffffffffffffffff168152506011600083815260200190815260200160002060008201518160000160006101000a81548167ffffffffffffffff021916908367ffffffffffffffff16021790555060208201518160000160086101000a81548167ffffffffffffffff021916908367ffffffffffffffff16021790555060408201518160000160106101000a81548167ffffffffffffffff021916908367ffffffffffffffff16021790555060608201518160000160186101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550905050611ff58682612c41565b505050505050565b60006002600083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b612042611e34565b73ffffffffffffffffffffffffffffffffffffffff16612060610ff9565b73ffffffffffffffffffffffffffffffffffffffff16146120b6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016120ad90615532565b60405180910390fd5b565b6000600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905081600a60006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b600061218d8360000183612c5f565b60001c905092915050565b6121aa6121a3611e34565b8383612c8a565b5050565b6121bf6121b9611e34565b8361271c565b6121fe576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016121f590615481565b60405180910390fd5b61220a84848484612df6565b50505050565b60606000600161221f84612e52565b01905060008167ffffffffffffffff81111561223e5761223d61428c565b5b6040519080825280601f01601f1916602001820160405280156122705781602001600182028036833780820191505090505b509050600082602001820190505b6001156122d3578080600190039150507f3031323334353637383961626364656600000000000000000000000000000000600a86061a8153600a85816122c7576122c661466d565b5b0494506000850361227e575b819350505050919050565b606060008251036123005760405180602001604052806000815250905061243c565b6000604051806060016040528060408152602001615bc0604091399050600060036002855161232f9190615552565b612339919061469c565b6004612345919061462b565b67ffffffffffffffff81111561235e5761235d61428c565b5b6040519080825280601f01601f1916602001820160405280156123905781602001600182028036833780820191505090505b509050600182016020820185865187015b808210156123fc576003820191508151603f8160121c168501518453600184019350603f81600c1c168501518453600184019350603f8160061c168501518453600184019350603f81168501518453600184019350506123a1565b5050600386510660018114612418576002811461242b57612433565b603d6001830353603d6002830353612433565b603d60018303535b50505080925050505b919050565b600061244f82600001612fa5565b9050919050565b60006124628383612fb6565b6124bb5782600001829080600181540180825580915050600190039060005260206000200160009091909190915055826000018054905083600101600084815260200190815260200160002081905550600190506124c0565b600090505b92915050565b60007f80ac58cd000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916148061259157507f5b5e139f000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b806125a157506125a082612fd9565b5b9050919050565b60007f7965db0b000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916148061261b575061261a826119b5565b5b9050919050565b60008073ffffffffffffffffffffffffffffffffffffffff1661264483611ffd565b73ffffffffffffffffffffffffffffffffffffffff1614159050919050565b816004600083815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550808273ffffffffffffffffffffffffffffffffffffffff166126d683610e84565b73ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b60008061272883610e84565b90508073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff16148061276a575061276981856115e7565b5b806127a857508373ffffffffffffffffffffffffffffffffffffffff1661279084610858565b73ffffffffffffffffffffffffffffffffffffffff16145b91505092915050565b8273ffffffffffffffffffffffffffffffffffffffff166127d182610e84565b73ffffffffffffffffffffffffffffffffffffffff1614612827576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161281e906155f8565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603612896576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161288d9061568a565b60405180910390fd5b6128a38383836001613043565b8273ffffffffffffffffffffffffffffffffffffffff166128c382610e84565b73ffffffffffffffffffffffffffffffffffffffff1614612919576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612910906155f8565b60405180910390fd5b6004600082815260200190815260200160002060006101000a81549073ffffffffffffffffffffffffffffffffffffffff02191690556001600360008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825403925050819055506001600360008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282540192505081905550816002600083815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550808273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a4612aa583838360016131a1565b505050565b612ab48282611052565b612b2b57612ac1816131a7565b612acf8360001c60206131d4565b604051602001612ae0929190615742565b6040516020818303038152906040526040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612b229190613d88565b60405180910390fd5b5050565b612b398282611052565b15612c0d576000600b600084815260200190815260200160002060000160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff021916908315150217905550612bb2611e34565b73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16837ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b60405160405180910390a45b5050565b6000612c39836000018373ffffffffffffffffffffffffffffffffffffffff1660001b613410565b905092915050565b612c5b828260405180602001604052806000815250613524565b5050565b6000826000018281548110612c7757612c76614883565b5b9060005260206000200154905092915050565b8173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1603612cf8576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612cef906157c8565b60405180910390fd5b80600560008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c3183604051612de99190613c44565b60405180910390a3505050565b612e018484846127b1565b612e0d8484848461357f565b612e4c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612e439061585a565b60405180910390fd5b50505050565b600080600090507a184f03e93ff9f4daa797ed6e38ed64bf6a1f0100000000000000008310612eb0577a184f03e93ff9f4daa797ed6e38ed64bf6a1f0100000000000000008381612ea657612ea561466d565b5b0492506040810190505b6d04ee2d6d415b85acef81000000008310612eed576d04ee2d6d415b85acef81000000008381612ee357612ee261466d565b5b0492506020810190505b662386f26fc100008310612f1c57662386f26fc100008381612f1257612f1161466d565b5b0492506010810190505b6305f5e1008310612f45576305f5e1008381612f3b57612f3a61466d565b5b0492506008810190505b6127108310612f6a576127108381612f6057612f5f61466d565b5b0492506004810190505b60648310612f8d5760648381612f8357612f8261466d565b5b0492506002810190505b600a8310612f9c576001810190505b80915050919050565b600081600001805490509050919050565b600080836001016000848152602001908152602001600020541415905092915050565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916149050919050565b61304f848484846119af565b6001811115613093576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161308a906158ec565b60405180910390fd5b6000829050600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff16036130da576130d581613706565b613119565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff161461311857613117858261374f565b5b5b600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff160361315b57613156816138bc565b61319a565b8473ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff161461319957613198848261398d565b5b5b5050505050565b50505050565b60606131cd8273ffffffffffffffffffffffffffffffffffffffff16601460ff166131d4565b9050919050565b6060600060028360026131e7919061462b565b6131f19190615552565b67ffffffffffffffff81111561320a5761320961428c565b5b6040519080825280601f01601f19166020018201604052801561323c5781602001600182028036833780820191505090505b5090507f30000000000000000000000000000000000000000000000000000000000000008160008151811061327457613273614883565b5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053507f7800000000000000000000000000000000000000000000000000000000000000816001815181106132d8576132d7614883565b5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535060006001846002613318919061462b565b6133229190615552565b90505b60018111156133c2577f3031323334353637383961626364656600000000000000000000000000000000600f86166010811061336457613363614883565b5b1a60f81b82828151811061337b5761337a614883565b5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350600485901c9450806133bb9061590c565b9050613325565b5060008414613406576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016133fd90615981565b60405180910390fd5b8091505092915050565b6000808360010160008481526020019081526020016000205490506000811461351857600060018261344291906159a1565b905060006001866000018054905061345a91906159a1565b90508181146134c957600086600001828154811061347b5761347a614883565b5b906000526020600020015490508087600001848154811061349f5761349e614883565b5b90600052602060002001819055508387600101600083815260200190815260200160002081905550505b856000018054806134dd576134dc6159d5565b5b60019003818190600052602060002001600090559055856001016000868152602001908152602001600020600090556001935050505061351e565b60009150505b92915050565b61352e8383613a0c565b61353b600084848461357f565b61357a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016135719061585a565b60405180910390fd5b505050565b60006135a08473ffffffffffffffffffffffffffffffffffffffff1661198c565b156136f9578373ffffffffffffffffffffffffffffffffffffffff1663150b7a026135c9611e34565b8786866040518563ffffffff1660e01b81526004016135eb9493929190615a59565b6020604051808303816000875af192505050801561362757506040513d601f19601f820116820180604052508101906136249190615aba565b60015b6136a9573d8060008114613657576040519150601f19603f3d011682016040523d82523d6000602084013e61365c565b606091505b5060008151036136a1576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016136989061585a565b60405180910390fd5b805181602001fd5b63150b7a0260e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916149150506136fe565b600190505b949350505050565b6008805490506009600083815260200190815260200160002081905550600881908060018154018082558091505060019003906000526020600020016000909190919091505550565b6000600161375c84610f0a565b61376691906159a1565b905060006007600084815260200190815260200160002054905081811461384b576000600660008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600084815260200190815260200160002054905080600660008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600084815260200190815260200160002081905550816007600083815260200190815260200160002081905550505b6007600084815260200190815260200160002060009055600660008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008381526020019081526020016000206000905550505050565b600060016008805490506138d091906159a1565b9050600060096000848152602001908152602001600020549050600060088381548110613900576138ff614883565b5b90600052602060002001549050806008838154811061392257613921614883565b5b906000526020600020018190555081600960008381526020019081526020016000208190555060096000858152602001908152602001600020600090556008805480613971576139706159d5565b5b6001900381819060005260206000200160009055905550505050565b600061399883610f0a565b905081600660008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600083815260200190815260200160002081905550806007600084815260200190815260200160002081905550505050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603613a7b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401613a7290615b33565b60405180910390fd5b613a8481612622565b15613ac4576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401613abb90615b9f565b60405180910390fd5b613ad2600083836001613043565b613adb81612622565b15613b1b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401613b1290615b9f565b60405180910390fd5b6001600360008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282540192505081905550816002600083815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550808273ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a4613c256000838360016131a1565b5050565b60008115159050919050565b613c3e81613c29565b82525050565b6000602082019050613c596000830184613c35565b92915050565b6000604051905090565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b613ca881613c73565b8114613cb357600080fd5b50565b600081359050613cc581613c9f565b92915050565b600060208284031215613ce157613ce0613c69565b5b6000613cef84828501613cb6565b91505092915050565b600081519050919050565b600082825260208201905092915050565b60005b83811015613d32578082015181840152602081019050613d17565b60008484015250505050565b6000601f19601f8301169050919050565b6000613d5a82613cf8565b613d648185613d03565b9350613d74818560208601613d14565b613d7d81613d3e565b840191505092915050565b60006020820190508181036000830152613da28184613d4f565b905092915050565b6000819050919050565b613dbd81613daa565b8114613dc857600080fd5b50565b600081359050613dda81613db4565b92915050565b600060208284031215613df657613df5613c69565b5b6000613e0484828501613dcb565b91505092915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000613e3882613e0d565b9050919050565b613e4881613e2d565b82525050565b6000602082019050613e636000830184613e3f565b92915050565b613e7281613e2d565b8114613e7d57600080fd5b50565b600081359050613e8f81613e69565b92915050565b60008060408385031215613eac57613eab613c69565b5b6000613eba85828601613e80565b9250506020613ecb85828601613dcb565b9150509250929050565b613ede81613daa565b82525050565b6000602082019050613ef96000830184613ed5565b92915050565b600080600060608486031215613f1857613f17613c69565b5b6000613f2686828701613e80565b9350506020613f3786828701613e80565b9250506040613f4886828701613dcb565b9150509250925092565b6000819050919050565b613f6581613f52565b8114613f7057600080fd5b50565b600081359050613f8281613f5c565b92915050565b600060208284031215613f9e57613f9d613c69565b5b6000613fac84828501613f73565b91505092915050565b613fbe81613f52565b82525050565b6000602082019050613fd96000830184613fb5565b92915050565b60008060408385031215613ff657613ff5613c69565b5b600061400485828601613dcb565b925050602061401585828601613dcb565b9150509250929050565b60006040820190506140346000830185613e3f565b6140416020830184613ed5565b9392505050565b6000806040838503121561405f5761405e613c69565b5b600061406d85828601613f73565b925050602061407e85828601613e80565b9150509250929050565b6000819050919050565b60006140ad6140a86140a384613e0d565b614088565b613e0d565b9050919050565b60006140bf82614092565b9050919050565b60006140d1826140b4565b9050919050565b6140e1816140c6565b82525050565b60006020820190506140fc60008301846140d8565b92915050565b600067ffffffffffffffff82169050919050565b61411f81614102565b811461412a57600080fd5b50565b60008135905061413c81614116565b92915050565b6000806000806080858703121561415c5761415b613c69565b5b600061416a87828801613e80565b945050602061417b8782880161412d565b935050604061418c8782880161412d565b925050606061419d8782880161412d565b91505092959194509250565b6000602082840312156141bf576141be613c69565b5b60006141cd84828501613e80565b91505092915050565b600080604083850312156141ed576141ec613c69565b5b60006141fb85828601613f73565b925050602061420c85828601613dcb565b9150509250929050565b61421f81613c29565b811461422a57600080fd5b50565b60008135905061423c81614216565b92915050565b6000806040838503121561425957614258613c69565b5b600061426785828601613e80565b92505060206142788582860161422d565b9150509250929050565b600080fd5b600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6142c482613d3e565b810181811067ffffffffffffffff821117156142e3576142e261428c565b5b80604052505050565b60006142f6613c5f565b905061430282826142bb565b919050565b600067ffffffffffffffff8211156143225761432161428c565b5b61432b82613d3e565b9050602081019050919050565b82818337600083830152505050565b600061435a61435584614307565b6142ec565b90508281526020810184848401111561437657614375614287565b5b614381848285614338565b509392505050565b600082601f83011261439e5761439d614282565b5b81356143ae848260208601614347565b91505092915050565b600080600080608085870312156143d1576143d0613c69565b5b60006143df87828801613e80565b94505060206143f087828801613e80565b935050604061440187828801613dcb565b925050606085013567ffffffffffffffff81111561442257614421613c6e565b5b61442e87828801614389565b91505092959194509250565b6000614445826140b4565b9050919050565b6144558161443a565b82525050565b6000602082019050614470600083018461444c565b92915050565b6000806040838503121561448d5761448c613c69565b5b600061449b85828601613e80565b92505060206144ac85828601613e80565b9150509250929050565b6144bf81614102565b82525050565b60006080820190506144da60008301876144b6565b6144e760208301866144b6565b6144f460408301856144b6565b61450160608301846144b6565b95945050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b6000600282049050600182168061455157607f821691505b6020821081036145645761456361450a565b5b50919050565b7f596f75206d75737420626520616e2041646d696e20746f20706572666f726d2060008201527f7468697320616374696f6e000000000000000000000000000000000000000000602082015250565b60006145c6602b83613d03565b91506145d18261456a565b604082019050919050565b600060208201905081810360008301526145f5816145b9565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061463682613daa565b915061464183613daa565b925082820261464f81613daa565b91508282048414831517614666576146656145fc565b5b5092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60006146a782613daa565b91506146b283613daa565b9250826146c2576146c161466d565b5b828204905092915050565b7f455243373231456e756d657261626c653a206f776e657220696e646578206f7560008201527f74206f6620626f756e6473000000000000000000000000000000000000000000602082015250565b6000614729602b83613d03565b9150614734826146cd565b604082019050919050565b600060208201905081810360008301526147588161471c565b9050919050565b7f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560008201527f20726f6c657320666f722073656c660000000000000000000000000000000000602082015250565b60006147bb602f83613d03565b91506147c68261475f565b604082019050919050565b600060208201905081810360008301526147ea816147ae565b9050919050565b7f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60008201527f7574206f6620626f756e64730000000000000000000000000000000000000000602082015250565b600061484d602c83613d03565b9150614858826147f1565b604082019050919050565b6000602082019050818103600083015261487c81614840565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f596f75206d7573742062652061204d696e74657220746f20706572666f726d2060008201527f7468697320616374696f6e000000000000000000000000000000000000000000602082015250565b600061490e602b83613d03565b9150614919826148b2565b604082019050919050565b6000602082019050818103600083015261493d81614901565b9050919050565b7f4d617820537570706c7920526561636865640000000000000000000000000000600082015250565b600061497a601283613d03565b915061498582614944565b602082019050919050565b600060208201905081810360008301526149a98161496d565b9050919050565b7f4552433732313a20696e76616c696420746f6b656e2049440000000000000000600082015250565b60006149e6601883613d03565b91506149f1826149b0565b602082019050919050565b60006020820190508181036000830152614a15816149d9565b9050919050565b7f4552433732313a2061646472657373207a65726f206973206e6f74206120766160008201527f6c6964206f776e65720000000000000000000000000000000000000000000000602082015250565b6000614a78602983613d03565b9150614a8382614a1c565b604082019050919050565b60006020820190508181036000830152614aa781614a6b565b9050919050565b6000614ac9614ac4614abf84614102565b614088565b613daa565b9050919050565b614ad981614aae565b82525050565b6000608082019050614af46000830187614ad0565b614b016020830186614ad0565b614b0e6040830185614ad0565b614b1b6060830184614ad0565b95945050505050565b600067ffffffffffffffff821115614b3f57614b3e61428c565b5b614b4882613d3e565b9050602081019050919050565b6000614b68614b6384614b24565b6142ec565b905082815260208101848484011115614b8457614b83614287565b5b614b8f848285613d14565b509392505050565b600082601f830112614bac57614bab614282565b5b8151614bbc848260208601614b55565b91505092915050565b600060208284031215614bdb57614bda613c69565b5b600082015167ffffffffffffffff811115614bf957614bf8613c6e565b5b614c0584828501614b97565b91505092915050565b600081905092915050565b7f7b226e616d65223a22504f4c2023000000000000000000000000000000000000600082015250565b6000614c4f600e83614c0e565b9150614c5a82614c19565b600e82019050919050565b6000614c7082613cf8565b614c7a8185614c0e565b9350614c8a818560208601613d14565b80840191505092915050565b7f222c22696d616765223a22000000000000000000000000000000000000000000600082015250565b6000614ccc600b83614c0e565b9150614cd782614c96565b600b82019050919050565b7f222c226465736372697074696f6e223a202257652077616e7420746f2062756960008201527f6c642074686520776f726c642773206c61726765737420656d6f74696f6e616c60208201527f204e465420696e69746961746976652c207472616e73666f726d696e6720636f60408201527f6d6d756e697479206c69766573747265616d2073656e74696d656e747320696e60608201527f746f2070657270657475616c6c79206f6e2d636861696e207265636f7264656460808201527f2067656f6d657472696320617274776f726b73222c000000000000000000000060a082015250565b6000614dd660b583614c0e565b9150614de182614ce2565b60b582019050919050565b7f22616e696d6174696f6e5f75726c223a22000000000000000000000000000000600082015250565b6000614e22601183614c0e565b9150614e2d82614dec565b601182019050919050565b7f222c202261747472696275746573223a5b7b2274726169745f74797065223a2060008201527f22706f736974697665222c202276616c7565223a000000000000000000000000602082015250565b6000614e94603483614c0e565b9150614e9f82614e38565b603482019050919050565b7f7d2c7b2274726169745f74797065223a20226e65676174697665222c2022766160008201527f6c7565223a000000000000000000000000000000000000000000000000000000602082015250565b6000614f06602583614c0e565b9150614f1182614eaa565b602582019050919050565b7f7d2c7b2274726169745f74797065223a20226e65757472616c222c202276616c60008201527f7565223a00000000000000000000000000000000000000000000000000000000602082015250565b6000614f78602483614c0e565b9150614f8382614f1c565b602482019050919050565b7f7d2c7b2274726169745f74797065223a202273656564222c202276616c75652260008201527f3a22000000000000000000000000000000000000000000000000000000000000602082015250565b6000614fea602283614c0e565b9150614ff582614f8e565b602282019050919050565b7f227d5d7d00000000000000000000000000000000000000000000000000000000600082015250565b6000615036600483614c0e565b915061504182615000565b600482019050919050565b600061505782614c42565b9150615063828a614c65565b915061506e82614cbf565b915061507a8289614c65565b915061508582614dc9565b915061509082614e15565b915061509c8288614c65565b91506150a782614e87565b91506150b38287614c65565b91506150be82614ef9565b91506150ca8286614c65565b91506150d582614f6b565b91506150e18285614c65565b91506150ec82614fdd565b91506150f88284614c65565b915061510382615029565b915081905098975050505050505050565b7f646174613a6170706c69636174696f6e2f6a736f6e3b6261736536342c000000600082015250565b600061514a601d83614c0e565b915061515582615114565b601d82019050919050565b600061516b8261513d565b91506151778284614c65565b915081905092915050565b7f4d6574616461746173206172652066726f7a656e000000000000000000000000600082015250565b60006151b8601483613d03565b91506151c382615182565b602082019050919050565b600060208201905081810360008301526151e7816151ab565b9050919050565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160008201527f6464726573730000000000000000000000000000000000000000000000000000602082015250565b600061524a602683613d03565b9150615255826151ee565b604082019050919050565b600060208201905081810360008301526152798161523d565b9050919050565b60006040820190506152956000830185613e3f565b6152a26020830184613e3f565b9392505050565b6000815190506152b881614216565b92915050565b6000602082840312156152d4576152d3613c69565b5b60006152e2848285016152a9565b91505092915050565b7f4552433732313a20617070726f76616c20746f2063757272656e74206f776e6560008201527f7200000000000000000000000000000000000000000000000000000000000000602082015250565b6000615347602183613d03565b9150615352826152eb565b604082019050919050565b600060208201905081810360008301526153768161533a565b9050919050565b7f4552433732313a20617070726f76652063616c6c6572206973206e6f7420746f60008201527f6b656e206f776e6572206f7220617070726f76656420666f7220616c6c000000602082015250565b60006153d9603d83613d03565b91506153e48261537d565b604082019050919050565b60006020820190508181036000830152615408816153cc565b9050919050565b7f4552433732313a2063616c6c6572206973206e6f7420746f6b656e206f776e6560008201527f72206f7220617070726f76656400000000000000000000000000000000000000602082015250565b600061546b602d83613d03565b91506154768261540f565b604082019050919050565b6000602082019050818103600083015261549a8161545e565b9050919050565b60006080820190506154b660008301876144b6565b6154c360208301866144b6565b6154d060408301856144b6565b6154dd6060830184613e3f565b95945050505050565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572600082015250565b600061551c602083613d03565b9150615527826154e6565b602082019050919050565b6000602082019050818103600083015261554b8161550f565b9050919050565b600061555d82613daa565b915061556883613daa565b92508282019050808211156155805761557f6145fc565b5b92915050565b7f4552433732313a207472616e736665722066726f6d20696e636f72726563742060008201527f6f776e6572000000000000000000000000000000000000000000000000000000602082015250565b60006155e2602583613d03565b91506155ed82615586565b604082019050919050565b60006020820190508181036000830152615611816155d5565b9050919050565b7f4552433732313a207472616e7366657220746f20746865207a65726f2061646460008201527f7265737300000000000000000000000000000000000000000000000000000000602082015250565b6000615674602483613d03565b915061567f82615618565b604082019050919050565b600060208201905081810360008301526156a381615667565b9050919050565b7f416363657373436f6e74726f6c3a206163636f756e7420000000000000000000600082015250565b60006156e0601783614c0e565b91506156eb826156aa565b601782019050919050565b7f206973206d697373696e6720726f6c6520000000000000000000000000000000600082015250565b600061572c601183614c0e565b9150615737826156f6565b601182019050919050565b600061574d826156d3565b91506157598285614c65565b91506157648261571f565b91506157708284614c65565b91508190509392505050565b7f4552433732313a20617070726f766520746f2063616c6c657200000000000000600082015250565b60006157b2601983613d03565b91506157bd8261577c565b602082019050919050565b600060208201905081810360008301526157e1816157a5565b9050919050565b7f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560008201527f63656976657220696d706c656d656e7465720000000000000000000000000000602082015250565b6000615844603283613d03565b915061584f826157e8565b604082019050919050565b6000602082019050818103600083015261587381615837565b9050919050565b7f455243373231456e756d657261626c653a20636f6e736563757469766520747260008201527f616e7366657273206e6f7420737570706f727465640000000000000000000000602082015250565b60006158d6603583613d03565b91506158e18261587a565b604082019050919050565b60006020820190508181036000830152615905816158c9565b9050919050565b600061591782613daa565b91506000820361592a576159296145fc565b5b600182039050919050565b7f537472696e67733a20686578206c656e67746820696e73756666696369656e74600082015250565b600061596b602083613d03565b915061597682615935565b602082019050919050565b6000602082019050818103600083015261599a8161595e565b9050919050565b60006159ac82613daa565b91506159b783613daa565b92508282039050818111156159cf576159ce6145fc565b5b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600081519050919050565b600082825260208201905092915050565b6000615a2b82615a04565b615a358185615a0f565b9350615a45818560208601613d14565b615a4e81613d3e565b840191505092915050565b6000608082019050615a6e6000830187613e3f565b615a7b6020830186613e3f565b615a886040830185613ed5565b8181036060830152615a9a8184615a20565b905095945050505050565b600081519050615ab481613c9f565b92915050565b600060208284031215615ad057615acf613c69565b5b6000615ade84828501615aa5565b91505092915050565b7f4552433732313a206d696e7420746f20746865207a65726f2061646472657373600082015250565b6000615b1d602083613d03565b9150615b2882615ae7565b602082019050919050565b60006020820190508181036000830152615b4c81615b10565b9050919050565b7f4552433732313a20746f6b656e20616c7265616479206d696e74656400000000600082015250565b6000615b89601c83613d03565b9150615b9482615b53565b602082019050919050565b60006020820190508181036000830152615bb881615b7c565b905091905056fe4142434445464748494a4b4c4d4e4f505152535455565758595a6162636465666768696a6b6c6d6e6f707172737475767778797a303132333435363738392b2fa26469706673582212208e9bedfe77995b3b426cbf50ac3ad6bf7f5e1cbd4b9caa72c4aab44feef6586864736f6c63430008120033

Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)

000000000000000000000000c3937dc16711773a2d8b8a5d405b1307cbafe345

-----Decoded View---------------
Arg [0] : _defaultRoyaltiesReceiver (address): 0xc3937dC16711773a2d8b8A5d405B1307cbAfE345

-----Encoded View---------------
1 Constructor Arguments found :
Arg [0] : 000000000000000000000000c3937dc16711773a2d8b8a5d405b1307cbafe345


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.