Feature Tip: Add private address tag to any address under My Name Tag !
ERC-721
Overview
Max Total Supply
217 PEARLS
Holders
74
Market
Volume (24H)
N/A
Min Price (24H)
N/A
Max Price (24H)
N/A
Other Info
Token Contract
Balance
4 PEARLSLoading...
Loading
Loading...
Loading
Loading...
Loading
# | Exchange | Pair | Price | 24H Volume | % Volume |
---|
Contract Name:
Pearls
Compiler Version
v0.8.9+commit.e5eed63a
Optimization Enabled:
Yes with 200 runs
Other Settings:
byzantium EvmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: AGPL-3.0 pragma solidity ^0.8.9; import "openzeppelin-solidity/contracts/token/ERC721/ERC721.sol"; import "openzeppelin-solidity/contracts/token/ERC721/extensions/ERC721Enumerable.sol"; import "openzeppelin-solidity/contracts/access/Ownable.sol"; import "openzeppelin-solidity/contracts/finance/PaymentSplitter.sol"; import 'openzeppelin-solidity/contracts/security/Pausable.sol'; import "openzeppelin-solidity/contracts/utils/Counters.sol"; import "openzeppelin-solidity/contracts/utils/cryptography/MerkleProof.sol"; /* * @author rollauver */ contract Pearls is ERC721Enumerable, Ownable, Pausable, PaymentSplitter { using Counters for Counters.Counter; Counters.Counter private _tokenIds; string public _contractURI; string public _placeholderURI; string public _baseTokenURI; bytes32 public _merkleRoot; uint256 public _price; uint256 public _presalePrice; uint256 public _maxSupply; uint256 public _maxPerAddress; uint256 public _presaleMaxPerAddress; uint256 public _publicSaleTime; uint256 public _preSaleTime; uint256 public _maxTxPerAddress; event EarlyPurchase(address indexed addr, uint256 indexed atPrice, uint256 indexed count); event Purchase(address indexed addr, uint256 indexed atPrice, uint256 indexed count); constructor( string memory name, string memory symbol, string[] memory uris, // _placeholderURI - 0, _contractURI - 1, baseTokenURI - 2 uint256[] memory numericValues, // price - 0, presalePrice - 1, maxSupply - 2, maxPerAddress - 3, presaleMaxPerAddress - 4, publicSaleTime - 5, _preSaleTime - 6, _maxTxPerAddress - 7 bytes32 merkleRoot, address[] memory payees, uint256[] memory shares ) ERC721(name, symbol) PaymentSplitter(payees, shares) { _placeholderURI = uris[0]; _contractURI = uris[1]; _baseTokenURI = uris[2]; _price = numericValues[0]; _presalePrice = numericValues[1]; _maxSupply = numericValues[2]; _maxPerAddress = numericValues[3]; _presaleMaxPerAddress = numericValues[4]; _publicSaleTime = numericValues[5]; _preSaleTime = numericValues[6]; _maxTxPerAddress = numericValues[7]; _merkleRoot = merkleRoot; } function setSaleInformation( uint256 publicSaleTime, uint256 preSaleTime, uint256 maxPerAddress, uint256 presaleMaxPerAddress, uint256 price, uint256 presalePrice, bytes32 merkleRoot, uint256 maxTxPerAddress ) external onlyOwner { _publicSaleTime = publicSaleTime; _preSaleTime = preSaleTime; _maxPerAddress = maxPerAddress; _presaleMaxPerAddress = presaleMaxPerAddress; _price = price; _presalePrice = presalePrice; _merkleRoot = merkleRoot; _maxTxPerAddress = maxTxPerAddress; } function setURIs( string memory placeholderUri, string memory contractUri, string memory baseUri ) external onlyOwner { _placeholderURI = placeholderUri; _contractURI = contractUri; _baseTokenURI = baseUri; } function setMerkleRoot(bytes32 merkleRoot) external onlyOwner { _merkleRoot = merkleRoot; } function contractURI() public view returns (string memory) { return _contractURI; } function tokenURI(uint256 _tokenId) override public view returns (string memory) { if (bytes(_baseTokenURI).length > 0) { return string( abi.encodePacked( _baseTokenURI, Strings.toHexString(uint256(uint160(address(this))), 20), '/', Strings.toString(_tokenId) ) ); } return _placeholderURI; } function mint(address to, uint256 count) external onlyOwner { ensureMintConditions(count); safeMint(to, count); } function purchase(uint256 count) external payable whenNotPaused { ensurePublicMintConditions(msg.sender, count, _maxPerAddress); require(isPublicSaleActive(), "BASE_COLLECTION/CANNOT_MINT"); _purchase(count, _price); emit Purchase(msg.sender, _price, count); } function earlyPurchase(uint256 count, bytes32[] calldata merkleProof) external payable whenNotPaused { ensurePublicMintConditions(msg.sender, count, _presaleMaxPerAddress); require(isPreSaleActive() && onEarlyPurchaseList(msg.sender, merkleProof), "BASE_COLLECTION/CANNOT_MINT_PRESALE"); _purchase(count, _presalePrice); emit EarlyPurchase(msg.sender, _presalePrice, count); } function _purchase(uint256 count, uint256 price) private { require(price * count <= msg.value, 'BASE_COLLECTION/INSUFFICIENT_ETH_AMOUNT'); safeMint(msg.sender, count); } function safeMint(address addr, uint256 count) private { for (uint256 i = 0; i < count; i++) { _safeMint(addr, _getNextTokenId()); } } function ensureMintConditions(uint256 count) internal view { require(totalSupply() + count <= _maxSupply, "BASE_COLLECTION/EXCEEDS_MAX_SUPPLY"); } function ensurePublicMintConditions(address to, uint256 count, uint256 maxPerAddress) internal view { ensureMintConditions(count); require((_maxTxPerAddress != 0) && (count <= _maxTxPerAddress), "BASE_COLLECTION/EXCEEDS_MAX_PER_TRANSACTION"); uint totalMintFromAddress = balanceOf(to) + count; require ((maxPerAddress != 0) && (totalMintFromAddress <= maxPerAddress), "BASE_COLLECTION/EXCEEDS_INDIVIDUAL_SUPPLY"); } function _getNextTokenId() private returns (uint256) { _tokenIds.increment(); uint256 newTokenId = _tokenIds.current(); return newTokenId; } function isPublicSaleActive() public view returns (bool) { return (_publicSaleTime != 0 && _publicSaleTime < block.timestamp); } function isPreSaleActive() public view returns (bool) { return (_preSaleTime != 0 && (_preSaleTime < block.timestamp) && (block.timestamp < _publicSaleTime)); } function onEarlyPurchaseList(address addr, bytes32[] calldata merkleProof) public view returns (bool) { require(_merkleRoot.length > 0, "BASE_COLLECTION/PRESALE_MINT_LIST_UNSET"); bytes32 node = keccak256(abi.encodePacked(addr)); return MerkleProof.verify(merkleProof, _merkleRoot, node); } function MAX_TOTAL_MINT() public view returns (uint256) { return _maxSupply; } function PRICE() public view returns (uint256) { if (isPreSaleActive()) { return _presalePrice; } return _price; } function MAX_TOTAL_MINT_PER_ADDRESS() public view returns (uint256) { if (isPreSaleActive()) { return _presaleMaxPerAddress; } return _maxPerAddress; } function pause() external onlyOwner { _pause(); } function unpause() external onlyOwner { _unpause(); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; // CAUTION // This version of SafeMath should only be used with Solidity 0.8 or later, // because it relies on the compiler's built in overflow checks. /** * @dev Wrappers over Solidity's arithmetic operations. * * NOTE: `SafeMath` is no longer needed starting with Solidity 0.8. The compiler * now has built in overflow checking. */ library SafeMath { /** * @dev Returns the addition of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { uint256 c = a + b; if (c < a) return (false, 0); return (true, c); } } /** * @dev Returns the substraction of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function trySub(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b > a) return (false, 0); return (true, a - b); } } /** * @dev Returns the multiplication of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function tryMul(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { // Gas optimization: this is cheaper than requiring 'a' not being zero, but the // benefit is lost if 'b' is also tested. // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522 if (a == 0) return (true, 0); uint256 c = a * b; if (c / a != b) return (false, 0); return (true, c); } } /** * @dev Returns the division of two unsigned integers, with a division by zero flag. * * _Available since v3.4._ */ function tryDiv(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b == 0) return (false, 0); return (true, a / b); } } /** * @dev Returns the remainder of dividing two unsigned integers, with a division by zero flag. * * _Available since v3.4._ */ function tryMod(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b == 0) return (false, 0); return (true, a % b); } } /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { return a + b; } /** * @dev Returns the subtraction of two unsigned integers, reverting on * overflow (when the result is negative). * * Counterpart to Solidity's `-` operator. * * Requirements: * * - Subtraction cannot overflow. */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { return a - b; } /** * @dev Returns the multiplication of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `*` operator. * * Requirements: * * - Multiplication cannot overflow. */ function mul(uint256 a, uint256 b) internal pure returns (uint256) { return a * b; } /** * @dev Returns the integer division of two unsigned integers, reverting on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. * * Requirements: * * - The divisor cannot be zero. */ function div(uint256 a, uint256 b) internal pure returns (uint256) { return a / b; } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * reverting when dividing by zero. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function mod(uint256 a, uint256 b) internal pure returns (uint256) { return a % b; } /** * @dev Returns the subtraction of two unsigned integers, reverting with custom message on * overflow (when the result is negative). * * CAUTION: This function is deprecated because it requires allocating memory for the error * message unnecessarily. For custom revert reasons use {trySub}. * * Counterpart to Solidity's `-` operator. * * Requirements: * * - Subtraction cannot overflow. */ function sub( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { unchecked { require(b <= a, errorMessage); return a - b; } } /** * @dev Returns the integer division of two unsigned integers, reverting with custom message on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. Note: this function uses a * `revert` opcode (which leaves remaining gas untouched) while Solidity * uses an invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function div( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { unchecked { require(b > 0, errorMessage); return a / b; } } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * reverting with custom message when dividing by zero. * * CAUTION: This function is deprecated because it requires allocating memory for the error * message unnecessarily. For custom revert reasons use {tryMod}. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function mod( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { unchecked { require(b > 0, errorMessage); return a % b; } } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Interface of the ERC165 standard, as defined in the * https://eips.ethereum.org/EIPS/eip-165[EIP]. * * Implementers can declare support of contract interfaces, which can then be * queried by others ({ERC165Checker}). * * For an implementation, see {ERC165}. */ interface IERC165 { /** * @dev Returns true if this contract implements the interface defined by * `interfaceId`. See the corresponding * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section] * to learn more about how these ids are created. * * This function call must use less than 30 000 gas. */ function supportsInterface(bytes4 interfaceId) external view returns (bool); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./IERC165.sol"; /** * @dev Implementation of the {IERC165} interface. * * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check * for the additional interface id that will be supported. For example: * * ```solidity * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { * return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId); * } * ``` * * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation. */ abstract contract ERC165 is IERC165 { /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IERC165).interfaceId; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev These functions deal with verification of Merkle Trees proofs. * * The proofs can be generated using the JavaScript library * https://github.com/miguelmota/merkletreejs[merkletreejs]. * Note: the hashing algorithm should be keccak256 and pair sorting should be enabled. * * See `test/utils/cryptography/MerkleProof.test.js` for some examples. */ 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) { bytes32 computedHash = leaf; for (uint256 i = 0; i < proof.length; i++) { bytes32 proofElement = proof[i]; if (computedHash <= proofElement) { // Hash(current computed hash + current element of the proof) computedHash = keccak256(abi.encodePacked(computedHash, proofElement)); } else { // Hash(current element of the proof + current computed hash) computedHash = keccak256(abi.encodePacked(proofElement, computedHash)); } } // Check if the computed hash (root) is equal to the provided root return computedHash == root; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev String operations. */ library Strings { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { // Inspired by OraclizeAPI's implementation - MIT licence // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol if (value == 0) { return "0"; } uint256 temp = value; uint256 digits; while (temp != 0) { digits++; temp /= 10; } bytes memory buffer = new bytes(digits); while (value != 0) { digits -= 1; buffer[digits] = bytes1(uint8(48 + uint256(value % 10))); value /= 10; } return string(buffer); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */ function toHexString(uint256 value) internal pure returns (string memory) { if (value == 0) { return "0x00"; } uint256 temp = value; uint256 length = 0; while (temp != 0) { length++; temp >>= 8; } return toHexString(value, length); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. */ function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { bytes memory buffer = new bytes(2 * length + 2); buffer[0] = "0"; buffer[1] = "x"; for (uint256 i = 2 * length + 1; i > 1; --i) { buffer[i] = _HEX_SYMBOLS[value & 0xf]; value >>= 4; } require(value == 0, "Strings: hex length insufficient"); return string(buffer); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @title Counters * @author Matt Condon (@shrugs) * @dev Provides counters that can only be incremented, decremented or reset. This can be used e.g. to track the number * of elements in a mapping, issuing ERC721 ids, or counting request ids. * * Include with `using Counters for Counters.Counter;` */ library Counters { struct Counter { // This variable should never be directly accessed by users of the library: interactions must be restricted to // the library's function. As of Solidity v0.5.2, this cannot be enforced, though there is a proposal to add // this feature: see https://github.com/ethereum/solidity/issues/4637 uint256 _value; // default: 0 } function current(Counter storage counter) internal view returns (uint256) { return counter._value; } function increment(Counter storage counter) internal { unchecked { counter._value += 1; } } function decrement(Counter storage counter) internal { uint256 value = counter._value; require(value > 0, "Counter: decrement overflow"); unchecked { counter._value = value - 1; } } function reset(Counter storage counter) internal { counter._value = 0; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with meta-transactions the account sending and * paying for execution may not be the actual sender (as far as an application * is concerned). * * This contract is only required for intermediate, library-like contracts. */ abstract contract Context { function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Collection of functions related to the address type */ library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will return false for the following * types of addresses: * * - an externally-owned account * - a contract in construction * - an address where a contract will be created * - an address where a contract lived, but was destroyed * ==== */ function isContract(address account) internal view returns (bool) { // This method relies on extcodesize, which returns 0 for contracts in // construction, since the code is only stored at the end of the // constructor execution. uint256 size; assembly { size := extcodesize(account) } return size > 0; } /** * @dev Replacement for Solidity's `transfer`: sends `amount` wei to * `recipient`, forwarding all available gas and reverting on errors. * * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost * of certain opcodes, possibly making contracts go over the 2300 gas limit * imposed by `transfer`, making them unable to receive funds via * `transfer`. {sendValue} removes this limitation. * * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more]. * * IMPORTANT: because control is transferred to `recipient`, care must be * taken to not create reentrancy vulnerabilities. Consider using * {ReentrancyGuard} or the * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. */ function sendValue(address payable recipient, uint256 amount) internal { require(address(this).balance >= amount, "Address: insufficient balance"); (bool success, ) = recipient.call{value: amount}(""); require(success, "Address: unable to send value, recipient may have reverted"); } /** * @dev Performs a Solidity function call using a low level `call`. A * plain `call` is an unsafe replacement for a function call: use this * function instead. * * If `target` reverts with a revert reason, it is bubbled up by this * function (like regular Solidity function calls). * * Returns the raw returned data. To convert to the expected return value, * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`]. * * Requirements: * * - `target` must be a contract. * - calling `target` with `data` must not revert. * * _Available since v3.1._ */ function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCall(target, data, "Address: low-level call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with * `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { return functionCallWithValue(target, data, 0, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but also transferring `value` wei to `target`. * * Requirements: * * - the calling contract must have an ETH balance of at least `value`. * - the called Solidity function must be `payable`. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value ) internal returns (bytes memory) { return functionCallWithValue(target, data, value, "Address: low-level call with value failed"); } /** * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but * with `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value, string memory errorMessage ) internal returns (bytes memory) { require(address(this).balance >= value, "Address: insufficient balance for call"); require(isContract(target), "Address: call to non-contract"); (bool success, bytes memory returndata) = target.call{value: value}(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { return functionStaticCall(target, data, "Address: low-level static call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall( address target, bytes memory data, string memory errorMessage ) internal view returns (bytes memory) { require(isContract(target), "Address: static call to non-contract"); (bool success, bytes memory returndata) = target.staticcall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { return functionDelegateCall(target, data, "Address: low-level delegate call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { require(isContract(target), "Address: delegate call to non-contract"); (bool success, bytes memory returndata) = target.delegatecall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the * revert reason using the provided one. * * _Available since v4.3._ */ function verifyCallResult( bool success, bytes memory returndata, string memory errorMessage ) internal pure returns (bytes memory) { if (success) { return returndata; } else { // Look for revert reason and bubble it up if present if (returndata.length > 0) { // The easiest way to bubble the revert reason is using memory via assembly assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert(errorMessage); } } } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../IERC721.sol"; /** * @title ERC-721 Non-Fungible Token Standard, optional metadata extension * @dev See https://eips.ethereum.org/EIPS/eip-721 */ interface IERC721Metadata is IERC721 { /** * @dev Returns the token collection name. */ function name() external view returns (string memory); /** * @dev Returns the token collection symbol. */ function symbol() external view returns (string memory); /** * @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token. */ function tokenURI(uint256 tokenId) external view returns (string memory); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../IERC721.sol"; /** * @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 tokenId); /** * @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); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../ERC721.sol"; import "./IERC721Enumerable.sol"; /** * @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 Hook that is called before any token transfer. This includes minting * and burning. * * Calling conditions: * * - When `from` and `to` are both non-zero, ``from``'s `tokenId` will be * transferred to `to`. * - When `from` is zero, `tokenId` will be minted for `to`. * - When `to` is zero, ``from``'s `tokenId` will be burned. * - `from` cannot be the zero address. * - `to` cannot be the zero address. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _beforeTokenTransfer( address from, address to, uint256 tokenId ) internal virtual override { super._beforeTokenTransfer(from, to, tokenId); 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(); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @title ERC721 token receiver interface * @dev Interface for any contract that wants to support safeTransfers * from ERC721 asset contracts. */ interface IERC721Receiver { /** * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom} * by `operator` from `from`, this function is called. * * It must return its Solidity selector to confirm the token transfer. * If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted. * * The selector can be obtained in Solidity with `IERC721.onERC721Received.selector`. */ function onERC721Received( address operator, address from, uint256 tokenId, bytes calldata data ) external returns (bytes4); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../../utils/introspection/IERC165.sol"; /** * @dev Required interface of an ERC721 compliant contract. */ interface IERC721 is IERC165 { /** * @dev Emitted when `tokenId` token is transferred from `from` to `to`. */ event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token. */ event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets. */ event ApprovalForAll(address indexed owner, address indexed operator, bool approved); /** * @dev Returns the number of tokens in ``owner``'s account. */ function balanceOf(address owner) external view returns (uint256 balance); /** * @dev Returns the owner of the `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function ownerOf(uint256 tokenId) external view returns (address owner); /** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be have been allowed to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Transfers `tokenId` token from `from` to `to`. * * WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * * Emits a {Transfer} event. */ function transferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Gives permission to `to` to transfer `tokenId` token to another account. * The approval is cleared when the token is transferred. * * Only a single account can be approved at a time, so approving the zero address clears previous approvals. * * Requirements: * * - The caller must own the token or be an approved operator. * - `tokenId` must exist. * * Emits an {Approval} event. */ function approve(address to, uint256 tokenId) external; /** * @dev Returns the account approved for `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function getApproved(uint256 tokenId) external view returns (address operator); /** * @dev Approve or remove `operator` as an operator for the caller. * Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller. * * Requirements: * * - The `operator` cannot be the caller. * * Emits an {ApprovalForAll} event. */ function setApprovalForAll(address operator, bool _approved) external; /** * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`. * * See {setApprovalForAll} */ function isApprovedForAll(address owner, address operator) external view returns (bool); /** * @dev Safely transfers `tokenId` token from `from` to `to`. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes calldata data ) external; }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./IERC721.sol"; import "./IERC721Receiver.sol"; import "./extensions/IERC721Metadata.sol"; import "../../utils/Address.sol"; import "../../utils/Context.sol"; import "../../utils/Strings.sol"; import "../../utils/introspection/ERC165.sol"; /** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */ contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _owners; // Mapping owner address to token count mapping(address => uint256) private _balances; // Mapping from token ID to approved address mapping(uint256 => address) private _tokenApprovals; // Mapping from owner to operator approvals mapping(address => mapping(address => bool)) private _operatorApprovals; /** * @dev Initializes the contract by setting a `name` and a `symbol` to the token collection. */ constructor(string memory name_, string memory symbol_) { _name = name_; _symbol = symbol_; } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { return interfaceId == type(IERC721).interfaceId || interfaceId == type(IERC721Metadata).interfaceId || super.supportsInterface(interfaceId); } /** * @dev See {IERC721-balanceOf}. */ function balanceOf(address owner) public view virtual override returns (uint256) { require(owner != address(0), "ERC721: balance query for the zero address"); return _balances[owner]; } /** * @dev See {IERC721-ownerOf}. */ function ownerOf(uint256 tokenId) public view virtual override returns (address) { address owner = _owners[tokenId]; require(owner != address(0), "ERC721: owner query for nonexistent token"); return owner; } /** * @dev See {IERC721Metadata-name}. */ function name() public view virtual override returns (string memory) { return _name; } /** * @dev See {IERC721Metadata-symbol}. */ function symbol() public view virtual override returns (string memory) { return _symbol; } /** * @dev See {IERC721Metadata-tokenURI}. */ function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { require(_exists(tokenId), "ERC721Metadata: URI query for nonexistent token"); string memory baseURI = _baseURI(); return bytes(baseURI).length > 0 ? string(abi.encodePacked(baseURI, tokenId.toString())) : ""; } /** * @dev Base URI for computing {tokenURI}. If set, the resulting URI for each * token will be the concatenation of the `baseURI` and the `tokenId`. Empty * by default, can be overriden in child contracts. */ function _baseURI() internal view virtual returns (string memory) { return ""; } /** * @dev See {IERC721-approve}. */ function approve(address to, uint256 tokenId) public virtual override { address owner = ERC721.ownerOf(tokenId); require(to != owner, "ERC721: approval to current owner"); require( _msgSender() == owner || isApprovedForAll(owner, _msgSender()), "ERC721: approve caller is not owner nor approved for all" ); _approve(to, tokenId); } /** * @dev See {IERC721-getApproved}. */ function getApproved(uint256 tokenId) public view virtual override returns (address) { require(_exists(tokenId), "ERC721: approved query for nonexistent token"); return _tokenApprovals[tokenId]; } /** * @dev See {IERC721-setApprovalForAll}. */ function setApprovalForAll(address operator, bool approved) public virtual override { require(operator != _msgSender(), "ERC721: approve to caller"); _operatorApprovals[_msgSender()][operator] = approved; emit ApprovalForAll(_msgSender(), operator, approved); } /** * @dev See {IERC721-isApprovedForAll}. */ function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { return _operatorApprovals[owner][operator]; } /** * @dev See {IERC721-transferFrom}. */ function transferFrom( address from, address to, uint256 tokenId ) public virtual override { //solhint-disable-next-line max-line-length require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved"); _transfer(from, to, tokenId); } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 tokenId ) public virtual override { safeTransferFrom(from, to, tokenId, ""); } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes memory _data ) public virtual override { require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved"); _safeTransfer(from, to, tokenId, _data); } /** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * `_data` is additional data, it has no specified format and it is sent in call to `to`. * * This internal function is equivalent to {safeTransferFrom}, and can be used to e.g. * implement alternative mechanisms to perform token transfer, such as signature-based. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function _safeTransfer( address from, address to, uint256 tokenId, bytes memory _data ) internal virtual { _transfer(from, to, tokenId); require(_checkOnERC721Received(from, to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer"); } /** * @dev Returns whether `tokenId` exists. * * Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}. * * Tokens start existing when they are minted (`_mint`), * and stop existing when they are burned (`_burn`). */ function _exists(uint256 tokenId) internal view virtual returns (bool) { return _owners[tokenId] != address(0); } /** * @dev Returns whether `spender` is allowed to manage `tokenId`. * * Requirements: * * - `tokenId` must exist. */ function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) { require(_exists(tokenId), "ERC721: operator query for nonexistent token"); address owner = ERC721.ownerOf(tokenId); return (spender == owner || getApproved(tokenId) == spender || isApprovedForAll(owner, spender)); } /** * @dev Safely mints `tokenId` and transfers it to `to`. * * Requirements: * * - `tokenId` must not exist. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function _safeMint(address to, uint256 tokenId) internal virtual { _safeMint(to, tokenId, ""); } /** * @dev Same as {xref-ERC721-_safeMint-address-uint256-}[`_safeMint`], with an additional `data` parameter which is * forwarded in {IERC721Receiver-onERC721Received} to contract recipients. */ function _safeMint( address to, uint256 tokenId, bytes memory _data ) internal virtual { _mint(to, tokenId); require( _checkOnERC721Received(address(0), to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer" ); } /** * @dev Mints `tokenId` and transfers it to `to`. * * WARNING: Usage of this method is discouraged, use {_safeMint} whenever possible * * Requirements: * * - `tokenId` must not exist. * - `to` cannot be the zero address. * * Emits a {Transfer} event. */ function _mint(address to, uint256 tokenId) internal virtual { require(to != address(0), "ERC721: mint to the zero address"); require(!_exists(tokenId), "ERC721: token already minted"); _beforeTokenTransfer(address(0), to, tokenId); _balances[to] += 1; _owners[tokenId] = to; emit Transfer(address(0), to, tokenId); } /** * @dev Destroys `tokenId`. * The approval is cleared when the token is burned. * * Requirements: * * - `tokenId` must exist. * * Emits a {Transfer} event. */ function _burn(uint256 tokenId) internal virtual { address owner = ERC721.ownerOf(tokenId); _beforeTokenTransfer(owner, address(0), tokenId); // Clear approvals _approve(address(0), tokenId); _balances[owner] -= 1; delete _owners[tokenId]; emit Transfer(owner, address(0), tokenId); } /** * @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 of token that is not own"); require(to != address(0), "ERC721: transfer to the zero address"); _beforeTokenTransfer(from, to, tokenId); // Clear approvals from the previous owner _approve(address(0), tokenId); _balances[from] -= 1; _balances[to] += 1; _owners[tokenId] = to; emit Transfer(from, to, tokenId); } /** * @dev Approve `to` to operate on `tokenId` * * Emits a {Approval} event. */ function _approve(address to, uint256 tokenId) internal virtual { _tokenApprovals[tokenId] = to; emit Approval(ERC721.ownerOf(tokenId), to, tokenId); } /** * @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target address. * The call is not executed if the target address is not a contract. * * @param from address representing the previous owner of the given token ID * @param to target address that will receive the tokens * @param tokenId uint256 ID of the token to be transferred * @param _data bytes optional data to send along with the call * @return bool whether the call correctly returned the expected magic value */ function _checkOnERC721Received( address from, address to, uint256 tokenId, bytes memory _data ) private returns (bool) { if (to.isContract()) { try IERC721Receiver(to).onERC721Received(_msgSender(), from, tokenId, _data) returns (bytes4 retval) { return retval == IERC721Receiver.onERC721Received.selector; } catch (bytes memory reason) { if (reason.length == 0) { revert("ERC721: transfer to non ERC721Receiver implementer"); } else { assembly { revert(add(32, reason), mload(reason)) } } } } else { return true; } } /** * @dev Hook that is called before any token transfer. This includes minting * and burning. * * Calling conditions: * * - When `from` and `to` are both non-zero, ``from``'s `tokenId` will be * transferred to `to`. * - When `from` is zero, `tokenId` will be minted for `to`. * - When `to` is zero, ``from``'s `tokenId` will be burned. * - `from` and `to` are never both zero. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _beforeTokenTransfer( address from, address to, uint256 tokenId ) internal virtual {} }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../utils/Context.sol"; /** * @dev Contract module which allows children to implement an emergency stop * mechanism that can be triggered by an authorized account. * * This module is used through inheritance. It will make available the * modifiers `whenNotPaused` and `whenPaused`, which can be applied to * the functions of your contract. Note that they will not be pausable by * simply including this module, only once the modifiers are put in place. */ abstract contract Pausable is Context { /** * @dev Emitted when the pause is triggered by `account`. */ event Paused(address account); /** * @dev Emitted when the pause is lifted by `account`. */ event Unpaused(address account); bool private _paused; /** * @dev Initializes the contract in unpaused state. */ constructor() { _paused = false; } /** * @dev Returns true if the contract is paused, and false otherwise. */ function paused() public view virtual returns (bool) { return _paused; } /** * @dev Modifier to make a function callable only when the contract is not paused. * * Requirements: * * - The contract must not be paused. */ modifier whenNotPaused() { require(!paused(), "Pausable: paused"); _; } /** * @dev Modifier to make a function callable only when the contract is paused. * * Requirements: * * - The contract must be paused. */ modifier whenPaused() { require(paused(), "Pausable: not paused"); _; } /** * @dev Triggers stopped state. * * Requirements: * * - The contract must not be paused. */ function _pause() internal virtual whenNotPaused { _paused = true; emit Paused(_msgSender()); } /** * @dev Returns to normal state. * * Requirements: * * - The contract must be paused. */ function _unpause() internal virtual whenPaused { _paused = false; emit Unpaused(_msgSender()); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../utils/Address.sol"; import "../utils/Context.sol"; import "../utils/math/SafeMath.sol"; /** * @title PaymentSplitter * @dev This contract allows to split Ether payments among a group of accounts. The sender does not need to be aware * that the Ether will be split in this way, since it is handled transparently by the contract. * * The split can be in equal parts or in any other arbitrary proportion. The way this is specified is by assigning each * account to a number of shares. Of all the Ether that this contract receives, each account will then be able to claim * an amount proportional to the percentage of total shares they were assigned. * * `PaymentSplitter` follows a _pull payment_ model. This means that payments are not automatically forwarded to the * accounts but kept in this contract, and the actual transfer is triggered as a separate step by calling the {release} * function. */ contract PaymentSplitter is Context { event PayeeAdded(address account, uint256 shares); event PaymentReleased(address to, uint256 amount); event PaymentReceived(address from, uint256 amount); uint256 private _totalShares; uint256 private _totalReleased; mapping(address => uint256) private _shares; mapping(address => uint256) private _released; address[] private _payees; /** * @dev Creates an instance of `PaymentSplitter` where each account in `payees` is assigned the number of shares at * the matching position in the `shares` array. * * All addresses in `payees` must be non-zero. Both arrays must have the same non-zero length, and there must be no * duplicates in `payees`. */ constructor(address[] memory payees, uint256[] memory shares_) payable { require(payees.length == shares_.length, "PaymentSplitter: payees and shares length mismatch"); require(payees.length > 0, "PaymentSplitter: no payees"); for (uint256 i = 0; i < payees.length; i++) { _addPayee(payees[i], shares_[i]); } } /** * @dev The Ether received will be logged with {PaymentReceived} events. Note that these events are not fully * reliable: it's possible for a contract to receive Ether without triggering this function. This only affects the * reliability of the events, and not the actual splitting of Ether. * * To learn more about this see the Solidity documentation for * https://solidity.readthedocs.io/en/latest/contracts.html#fallback-function[fallback * functions]. */ receive() external payable virtual { emit PaymentReceived(_msgSender(), msg.value); } /** * @dev Getter for the total shares held by payees. */ function totalShares() public view returns (uint256) { return _totalShares; } /** * @dev Getter for the total amount of Ether already released. */ function totalReleased() public view returns (uint256) { return _totalReleased; } /** * @dev Getter for the amount of shares held by an account. */ function shares(address account) public view returns (uint256) { return _shares[account]; } /** * @dev Getter for the amount of Ether already released to a payee. */ function released(address account) public view returns (uint256) { return _released[account]; } /** * @dev Getter for the address of the payee number `index`. */ function payee(uint256 index) public view returns (address) { return _payees[index]; } /** * @dev Triggers a transfer to `account` of the amount of Ether they are owed, according to their percentage of the * total shares and their previous withdrawals. */ function release(address payable account) public virtual { require(_shares[account] > 0, "PaymentSplitter: account has no shares"); uint256 totalReceived = address(this).balance + _totalReleased; uint256 payment = (totalReceived * _shares[account]) / _totalShares - _released[account]; require(payment != 0, "PaymentSplitter: account is not due payment"); _released[account] = _released[account] + payment; _totalReleased = _totalReleased + payment; Address.sendValue(account, payment); emit PaymentReleased(account, payment); } /** * @dev Add a new payee to the contract. * @param account The address of the payee to add. * @param shares_ The number of shares owned by the payee. */ function _addPayee(address account, uint256 shares_) private { require(account != address(0), "PaymentSplitter: account is the zero address"); require(shares_ > 0, "PaymentSplitter: shares are 0"); require(_shares[account] == 0, "PaymentSplitter: account already has shares"); _payees.push(account); _shares[account] = shares_; _totalShares = _totalShares + shares_; emit PayeeAdded(account, shares_); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../utils/Context.sol"; /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor() { _setOwner(_msgSender()); } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { require(owner() == _msgSender(), "Ownable: caller is not the owner"); _; } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _setOwner(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"); _setOwner(newOwner); } function _setOwner(address newOwner) private { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
{ "remappings": [], "optimizer": { "enabled": true, "runs": 200 }, "evmVersion": "byzantium", "libraries": {}, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"symbol","type":"string"},{"internalType":"string[]","name":"uris","type":"string[]"},{"internalType":"uint256[]","name":"numericValues","type":"uint256[]"},{"internalType":"bytes32","name":"merkleRoot","type":"bytes32"},{"internalType":"address[]","name":"payees","type":"address[]"},{"internalType":"uint256[]","name":"shares","type":"uint256[]"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"addr","type":"address"},{"indexed":true,"internalType":"uint256","name":"atPrice","type":"uint256"},{"indexed":true,"internalType":"uint256","name":"count","type":"uint256"}],"name":"EarlyPurchase","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"uint256","name":"shares","type":"uint256"}],"name":"PayeeAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"from","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"PaymentReceived","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"PaymentReleased","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"addr","type":"address"},{"indexed":true,"internalType":"uint256","name":"atPrice","type":"uint256"},{"indexed":true,"internalType":"uint256","name":"count","type":"uint256"}],"name":"Purchase","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"inputs":[],"name":"MAX_TOTAL_MINT","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAX_TOTAL_MINT_PER_ADDRESS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"PRICE","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_baseTokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_contractURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_maxPerAddress","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_maxSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_maxTxPerAddress","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_merkleRoot","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_placeholderURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_preSaleTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_presaleMaxPerAddress","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_presalePrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_price","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_publicSaleTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"contractURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"count","type":"uint256"},{"internalType":"bytes32[]","name":"merkleProof","type":"bytes32[]"}],"name":"earlyPurchase","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"isPreSaleActive","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"isPublicSaleActive","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"count","type":"uint256"}],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"bytes32[]","name":"merkleProof","type":"bytes32[]"}],"name":"onEarlyPurchaseList","outputs":[{"internalType":"bool","name":"","type":"bool"}],"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":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"}],"name":"payee","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"count","type":"uint256"}],"name":"purchase","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address payable","name":"account","type":"address"}],"name":"release","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"released","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","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":"bytes32","name":"merkleRoot","type":"bytes32"}],"name":"setMerkleRoot","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"publicSaleTime","type":"uint256"},{"internalType":"uint256","name":"preSaleTime","type":"uint256"},{"internalType":"uint256","name":"maxPerAddress","type":"uint256"},{"internalType":"uint256","name":"presaleMaxPerAddress","type":"uint256"},{"internalType":"uint256","name":"price","type":"uint256"},{"internalType":"uint256","name":"presalePrice","type":"uint256"},{"internalType":"bytes32","name":"merkleRoot","type":"bytes32"},{"internalType":"uint256","name":"maxTxPerAddress","type":"uint256"}],"name":"setSaleInformation","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"placeholderUri","type":"string"},{"internalType":"string","name":"contractUri","type":"string"},{"internalType":"string","name":"baseUri","type":"string"}],"name":"setURIs","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"shares","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","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":"totalReleased","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalShares","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"stateMutability":"payable","type":"receive"}]
Contract Creation Code
60806040523480156200001157600080fd5b506040516200412c3803806200412c8339810160408190526200003491620009d7565b81818888816000908051906020019062000050929190620006a8565b50805162000066906001906020840190620006a8565b5050506200009562000086620003f3640100000000026401000000009004565b640100000000620003f7810204565b600a805460a060020a60ff021916905580518251146200013c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603260248201527f5061796d656e7453706c69747465723a2070617965657320616e64207368617260448201527f6573206c656e677468206d69736d61746368000000000000000000000000000060648201526084015b60405180910390fd5b6000825111620001a9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f5061796d656e7453706c69747465723a206e6f20706179656573000000000000604482015260640162000133565b60005b82518110156200021e5762000209838281518110620001cf57620001cf62000ae9565b6020026020010151838381518110620001ec57620001ec62000ae9565b602002602001015162000449640100000000026401000000009004565b80620002158162000b47565b915050620001ac565b5050508460008151811062000237576200023762000ae9565b60200260200101516012908051906020019062000256929190620006a8565b50846001815181106200026d576200026d62000ae9565b6020026020010151601190805190602001906200028c929190620006a8565b5084600281518110620002a357620002a362000ae9565b602002602001015160139080519060200190620002c2929190620006a8565b5083600081518110620002d957620002d962000ae9565b602002602001015160158190555083600181518110620002fd57620002fd62000ae9565b60200260200101516016819055508360028151811062000321576200032162000ae9565b60200260200101516017819055508360038151811062000345576200034562000ae9565b60200260200101516018819055508360048151811062000369576200036962000ae9565b6020026020010151601981905550836005815181106200038d576200038d62000ae9565b6020026020010151601a8190555083600681518110620003b157620003b162000ae9565b6020026020010151601b8190555083600781518110620003d557620003d562000ae9565b6020908102919091010151601c5550506014555062000bd692505050565b3390565b600a8054600160a060020a03838116600160a060020a0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b600160a060020a038216620004e1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602c60248201527f5061796d656e7453706c69747465723a206163636f756e74206973207468652060448201527f7a65726f20616464726573730000000000000000000000000000000000000000606482015260840162000133565b600081116200054d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f5061796d656e7453706c69747465723a20736861726573206172652030000000604482015260640162000133565b600160a060020a0382166000908152600d602052604090205415620005f5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f5061796d656e7453706c69747465723a206163636f756e7420616c726561647960448201527f2068617320736861726573000000000000000000000000000000000000000000606482015260840162000133565b600f8054600181019091557f8d1108e10bcb7c27dddfc02ed9d693a074039d026cf4ea4240b40f7d581ac802018054600160a060020a031916600160a060020a0384169081179091556000908152600d60205260409020819055600b546200065f90829062000b65565b600b5560408051600160a060020a0384168152602081018390527f40c340f65e17194d14ddddb073d3c9f888e3cb52b5aae0c6c7706b4fbc905fac910160405180910390a15050565b828054620006b69062000b80565b90600052602060002090601f016020900481019282620006da576000855562000725565b82601f10620006f557805160ff191683800117855562000725565b8280016001018555821562000725579182015b828111156200072557825182559160200191906001019062000708565b506200073392915062000737565b5090565b5b8082111562000733576000815560010162000738565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f8201601f191681016001604060020a0381118282101715620007a857620007a86200074e565b604052919050565b600082601f830112620007c257600080fd5b81516001604060020a03811115620007de57620007de6200074e565b6020620007f4601f8301601f191682016200077d565b82815285828487010111156200080957600080fd5b60005b83811015620008295785810183015182820184015282016200080c565b838111156200083b5760008385840101525b5095945050505050565b60006001604060020a038211156200086157620008616200074e565b5060209081020190565b600082601f8301126200087d57600080fd5b8151602062000896620008908362000845565b6200077d565b82815291810284018101918181019086841115620008b357600080fd5b8286015b84811015620008f75780516001604060020a03811115620008d85760008081fd5b620008e88986838b0101620007b0565b845250918301918301620008b7565b509695505050505050565b600082601f8301126200091457600080fd5b8151602062000927620008908362000845565b828152918102840181019181810190868411156200094457600080fd5b8286015b84811015620008f7578051835291830191830162000948565b600082601f8301126200097357600080fd5b8151602062000986620008908362000845565b82815291810284018101918181019086841115620009a357600080fd5b8286015b84811015620008f7578051600160a060020a0381168114620009c95760008081fd5b8352918301918301620009a7565b600080600080600080600060e0888a031215620009f357600080fd5b87516001604060020a038082111562000a0b57600080fd5b62000a198b838c01620007b0565b985060208a015191508082111562000a3057600080fd5b62000a3e8b838c01620007b0565b975060408a015191508082111562000a5557600080fd5b62000a638b838c016200086b565b965060608a015191508082111562000a7a57600080fd5b62000a888b838c0162000902565b955060808a0151945060a08a015191508082111562000aa657600080fd5b62000ab48b838c0162000961565b935060c08a015191508082111562000acb57600080fd5b5062000ada8a828b0162000902565b91505092959891949750929550565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600060001982141562000b5e5762000b5e62000b18565b5060010190565b6000821982111562000b7b5762000b7b62000b18565b500190565b60028104600182168062000b9557607f821691505b6020821081141562000bd0577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b6135468062000be66000396000f3fe60806040526004361061033b576000357c01000000000000000000000000000000000000000000000000000000009004806374721235116101c8578063b88d4fde11610114578063e2d5ee2d116100b2578063e985e9c51161008c578063e985e9c514610900578063efef39a114610949578063f2fde38b1461095c578063fa156f9a1461097c57600080fd5b8063e2d5ee2d146108c0578063e33b7de3146108d6578063e8a3d485146108eb57600080fd5b8063ce7c2ac2116100ee578063ce7c2ac21461084d578063cf9e8e6914610883578063cfc86f7b14610898578063e2ab10ce146108ad57600080fd5b8063b88d4fde146107f8578063c0e7274014610818578063c87b56dd1461082d57600080fd5b80638da5cb5b116101815780639852595c1161015b5780639852595c146107775780639d044ed3146107ad578063a22cb465146107c2578063b85ef036146107e257600080fd5b80638da5cb5b1461072e578063904be6da1461074c57806395d89b411461076257600080fd5b806374721235146106845780637b96a3b2146106a45780637cb64759146106c45780638456cb59146106e45780638b83209b146106f95780638d859f3e1461071957600080fd5b80633f4ba83a116102875780635c975abb1161024057806366cfb1f31161021a57806366cfb1f314610624578063696fa41e1461063957806370a082311461064f578063715018a61461066f57600080fd5b80635c975abb146105cf5780635f0d246a146105ee5780636352211e1461060457600080fd5b80633f4ba83a1461052557806340a4dddd1461053a57806340c10f191461055a57806342842e0e1461057a5780634f6ccce71461059a578063547eb5b6146105ba57600080fd5b80631e84c413116102f457806323b872dd116102ce57806323b872dd146104ba5780632f745c59146104da5780632fc37ab2146104fa5780633a98ef391461051057600080fd5b80631e84c4131461047957806322f4596f1461048e578063235b6ea1146104a457600080fd5b806301ffc9a71461038957806306fdde03146103be578063081812fc146103e0578063095ea7b31461041857806318160ddd1461043a578063191655871461045957600080fd5b36610384577f6ef95f06320e7a25a04a175ca677b7052bdd97131872c2192525a629f51be7703360408051600160a060020a0390921682523460208301520160405180910390a1005b600080fd5b34801561039557600080fd5b506103a96103a4366004612cca565b610992565b60405190151581526020015b60405180910390f35b3480156103ca57600080fd5b506103d36109d6565b6040516103b59190612d3f565b3480156103ec57600080fd5b506104006103fb366004612d52565b610a68565b604051600160a060020a0390911681526020016103b5565b34801561042457600080fd5b50610438610433366004612d80565b610b16565b005b34801561044657600080fd5b506008545b6040519081526020016103b5565b34801561046557600080fd5b50610438610474366004612dac565b610c4e565b34801561048557600080fd5b506103a9610e4f565b34801561049a57600080fd5b5061044b60175481565b3480156104b057600080fd5b5061044b60155481565b3480156104c657600080fd5b506104386104d5366004612dc9565b610e6a565b3480156104e657600080fd5b5061044b6104f5366004612d80565b610e9e565b34801561050657600080fd5b5061044b60145481565b34801561051c57600080fd5b50600b5461044b565b34801561053157600080fd5b50610438610f49565b34801561054657600080fd5b50610438610555366004612eb9565b610f80565b34801561056657600080fd5b50610438610575366004612d80565b610fee565b34801561058657600080fd5b50610438610595366004612dc9565b611032565b3480156105a657600080fd5b5061044b6105b5366004612d52565b61104d565b3480156105c657600080fd5b506103d36110f4565b3480156105db57600080fd5b50600a5460a060020a900460ff166103a9565b3480156105fa57600080fd5b5061044b60165481565b34801561061057600080fd5b5061040061061f366004612d52565b611182565b34801561063057600080fd5b5061044b611210565b34801561064557600080fd5b5061044b601c5481565b34801561065b57600080fd5b5061044b61066a366004612dac565b61122d565b34801561067b57600080fd5b506104386112ca565b34801561069057600080fd5b5061043861069f366004612f41565b611301565b3480156106b057600080fd5b506103a96106bf366004612fe1565b611354565b3480156106d057600080fd5b506104386106df366004612d52565b6113df565b3480156106f057600080fd5b50610438611411565b34801561070557600080fd5b50610400610714366004612d52565b611446565b34801561072557600080fd5b5061044b611476565b34801561073a57600080fd5b50600a54600160a060020a0316610400565b34801561075857600080fd5b5061044b60195481565b34801561076e57600080fd5b506103d3611493565b34801561078357600080fd5b5061044b610792366004612dac565b600160a060020a03166000908152600e602052604090205490565b3480156107b957600080fd5b506103a96114a2565b3480156107ce57600080fd5b506104386107dd366004613036565b6114c8565b3480156107ee57600080fd5b5061044b601a5481565b34801561080457600080fd5b50610438610813366004613074565b611590565b34801561082457600080fd5b506103d36115c5565b34801561083957600080fd5b506103d3610848366004612d52565b6115d2565b34801561085957600080fd5b5061044b610868366004612dac565b600160a060020a03166000908152600d602052604090205490565b34801561088f57600080fd5b5060175461044b565b3480156108a457600080fd5b506103d36116bb565b6104386108bb3660046130f4565b6116c8565b3480156108cc57600080fd5b5061044b60185481565b3480156108e257600080fd5b50600c5461044b565b3480156108f757600080fd5b506103d36117d3565b34801561090c57600080fd5b506103a961091b366004613127565b600160a060020a03918216600090815260056020908152604080832093909416825291909152205460ff1690565b610438610957366004612d52565b6117e2565b34801561096857600080fd5b50610438610977366004612dac565b6118b3565b34801561098857600080fd5b5061044b601b5481565b6000600160e060020a031982167f780e9d630000000000000000000000000000000000000000000000000000000014806109d057506109d08261196b565b92915050565b6060600080546109e590613155565b80601f0160208091040260200160405190810160405280929190818152602001828054610a1190613155565b8015610a5e5780601f10610a3357610100808354040283529160200191610a5e565b820191906000526020600020905b815481529060010190602001808311610a4157829003601f168201915b5050505050905090565b600081815260026020526040812054600160a060020a0316610afa5760405160e560020a62461bcd02815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201527f697374656e7420746f6b656e000000000000000000000000000000000000000060648201526084015b60405180910390fd5b50600090815260046020526040902054600160a060020a031690565b6000610b2182611182565b905080600160a060020a031683600160a060020a03161415610bae5760405160e560020a62461bcd02815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e6560448201527f72000000000000000000000000000000000000000000000000000000000000006064820152608401610af1565b33600160a060020a0382161480610bca5750610bca813361091b565b610c3f5760405160e560020a62461bcd02815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610af1565b610c498383611a06565b505050565b600160a060020a0381166000908152600d6020526040902054610cdc5760405160e560020a62461bcd02815260206004820152602660248201527f5061796d656e7453706c69747465723a206163636f756e7420686173206e6f2060448201527f73686172657300000000000000000000000000000000000000000000000000006064820152608401610af1565b600c54600090610ced9030316131ac565b600160a060020a0383166000908152600e6020908152604080832054600b54600d909352908320549394509192610d2490856131c4565b610d2e91906131fc565b610d389190613210565b905080610db05760405160e560020a62461bcd02815260206004820152602b60248201527f5061796d656e7453706c69747465723a206163636f756e74206973206e6f742060448201527f647565207061796d656e740000000000000000000000000000000000000000006064820152608401610af1565b600160a060020a0383166000908152600e6020526040902054610dd49082906131ac565b600160a060020a0384166000908152600e6020526040902055600c54610dfb9082906131ac565b600c55610e088382611a81565b60408051600160a060020a0385168152602081018390527fdf20fd1e76bc69d672e4814fafb2c449bba3a5369d8359adf9e05e6fde87b056910160405180910390a1505050565b6000601a54600014158015610e65575042601a54105b905090565b610e743382611ba1565b610e935760405160e560020a62461bcd028152600401610af190613227565b610c49838383611cac565b6000610ea98361122d565b8210610f205760405160e560020a62461bcd02815260206004820152602b60248201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560448201527f74206f6620626f756e64730000000000000000000000000000000000000000006064820152608401610af1565b50600160a060020a03919091166000908152600660209081526040808320938352929052205490565b600a54600160a060020a03163314610f765760405160e560020a62461bcd028152600401610af190613284565b610f7e611e97565b565b600a54600160a060020a03163314610fad5760405160e560020a62461bcd028152600401610af190613284565b8251610fc0906012906020860190612c1b565b508151610fd4906011906020850190612c1b565b508051610fe8906013906020840190612c1b565b50505050565b600a54600160a060020a0316331461101b5760405160e560020a62461bcd028152600401610af190613284565b61102481611f51565b61102e8282611fdf565b5050565b610c4983838360405180602001604052806000815250611590565b600061105860085490565b82106110cf5760405160e560020a62461bcd02815260206004820152602c60248201527f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60448201527f7574206f6620626f756e647300000000000000000000000000000000000000006064820152608401610af1565b600882815481106110e2576110e26132b9565b90600052602060002001549050919050565b6012805461110190613155565b80601f016020809104026020016040519081016040528092919081815260200182805461112d90613155565b801561117a5780601f1061114f5761010080835404028352916020019161117a565b820191906000526020600020905b81548152906001019060200180831161115d57829003601f168201915b505050505081565b600081815260026020526040812054600160a060020a0316806109d05760405160e560020a62461bcd02815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201527f656e7420746f6b656e00000000000000000000000000000000000000000000006064820152608401610af1565b600061121a6114a2565b15611226575060195490565b5060185490565b6000600160a060020a0382166112ae5760405160e560020a62461bcd02815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a6560448201527f726f2061646472657373000000000000000000000000000000000000000000006064820152608401610af1565b50600160a060020a031660009081526003602052604090205490565b600a54600160a060020a031633146112f75760405160e560020a62461bcd028152600401610af190613284565b610f7e600061200d565b600a54600160a060020a0316331461132e5760405160e560020a62461bcd028152600401610af190613284565b601a97909755601b95909555601893909355601991909155601555601655601455601c55565b60006040516c01000000000000000000000000600160a060020a0386160260208201526000906034016040516020818303038152906040528051906020012090506113d684848080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050601454915084905061206c565b95945050505050565b600a54600160a060020a0316331461140c5760405160e560020a62461bcd028152600401610af190613284565b601455565b600a54600160a060020a0316331461143e5760405160e560020a62461bcd028152600401610af190613284565b610f7e61211b565b6000600f828154811061145b5761145b6132b9565b600091825260209091200154600160a060020a031692915050565b60006114806114a2565b1561148c575060165490565b5060155490565b6060600180546109e590613155565b6000601b546000141580156114b8575042601b54105b8015610e65575050601a54421090565b600160a060020a0382163314156115245760405160e560020a62461bcd02815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610af1565b336000818152600560209081526040808320600160a060020a03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b61159a3383611ba1565b6115b95760405160e560020a62461bcd028152600401610af190613227565b610fe884848484612194565b6011805461110190613155565b60606000601380546115e390613155565b905011156116295760136115f83060146121ca565b611601846123d3565b604051602001611613939291906132ee565b6040516020818303038152906040529050919050565b6012805461163690613155565b80601f016020809104026020016040519081016040528092919081815260200182805461166290613155565b80156116af5780601f10611684576101008083540402835291602001916116af565b820191906000526020600020905b81548152906001019060200180831161169257829003601f168201915b50505050509050919050565b6013805461110190613155565b600a5460a060020a900460ff16156116f55760405160e560020a62461bcd028152600401610af1906133ce565b611702338460195461250c565b61170a6114a2565b801561171c575061171c338383611354565b6117915760405160e560020a62461bcd02815260206004820152602360248201527f424153455f434f4c4c454354494f4e2f43414e4e4f545f4d494e545f5052455360448201527f414c4500000000000000000000000000000000000000000000000000000000006064820152608401610af1565b61179d83601654612639565b60165460405184919033907f38bd02858ca92987ff585a4c06998aea8187e96864df1eaf349dec3cfddc0fbb90600090a4505050565b6060601180546109e590613155565b600a5460a060020a900460ff161561180f5760405160e560020a62461bcd028152600401610af1906133ce565b61181c338260185461250c565b611824610e4f565b6118735760405160e560020a62461bcd02815260206004820152601b60248201527f424153455f434f4c4c454354494f4e2f43414e4e4f545f4d494e5400000000006044820152606401610af1565b61187f81601554612639565b60155460405182919033907f12cb4648cf3058b17ceeb33e579f8b0bc269fe0843f3900b8e24b6c54871703c90600090a450565b600a54600160a060020a031633146118e05760405160e560020a62461bcd028152600401610af190613284565b600160a060020a03811661195f5760405160e560020a62461bcd02815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f64647265737300000000000000000000000000000000000000000000000000006064820152608401610af1565b6119688161200d565b50565b6000600160e060020a031982167f80ac58cd0000000000000000000000000000000000000000000000000000000014806119ce5750600160e060020a031982167f5b5e139f00000000000000000000000000000000000000000000000000000000145b806109d057507f01ffc9a700000000000000000000000000000000000000000000000000000000600160e060020a03198316146109d0565b6000818152600460205260409020805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0384169081179091558190611a4882611182565b600160a060020a03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b3031811115611ad55760405160e560020a62461bcd02815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e63650000006044820152606401610af1565b600082600160a060020a03168260405160006040518083038185875af1925050503d8060008114611b22576040519150601f19603f3d011682016040523d82523d6000602084013e611b27565b606091505b5050905080610c495760405160e560020a62461bcd02815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d617920686176652072657665727465640000000000006064820152608401610af1565b600081815260026020526040812054600160a060020a0316611c2e5760405160e560020a62461bcd02815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201527f697374656e7420746f6b656e00000000000000000000000000000000000000006064820152608401610af1565b6000611c3983611182565b905080600160a060020a031684600160a060020a03161480611c74575083600160a060020a0316611c6984610a68565b600160a060020a0316145b80611ca45750600160a060020a0380821660009081526005602090815260408083209388168352929052205460ff165b949350505050565b82600160a060020a0316611cbf82611182565b600160a060020a031614611d3e5760405160e560020a62461bcd02815260206004820152602960248201527f4552433732313a207472616e73666572206f6620746f6b656e2074686174206960448201527f73206e6f74206f776e00000000000000000000000000000000000000000000006064820152608401610af1565b600160a060020a038216611dbc5760405160e560020a62461bcd028152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f2061646460448201527f72657373000000000000000000000000000000000000000000000000000000006064820152608401610af1565b611dc78383836126c5565b611dd2600082611a06565b600160a060020a0383166000908152600360205260408120805460019290611dfb908490613210565b9091555050600160a060020a0382166000908152600360205260408120805460019290611e299084906131ac565b9091555050600081815260026020526040808220805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b600a5460a060020a900460ff16611ef35760405160e560020a62461bcd02815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610af1565b600a805474ff0000000000000000000000000000000000000000191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b604051600160a060020a03909116815260200160405180910390a1565b60175481611f5e60085490565b611f6891906131ac565b11156119685760405160e560020a62461bcd02815260206004820152602260248201527f424153455f434f4c4c454354494f4e2f455843454544535f4d41585f5355505060448201527f4c590000000000000000000000000000000000000000000000000000000000006064820152608401610af1565b60005b81811015610c4957611ffb83611ff661277d565b612798565b8061200581613405565b915050611fe2565b600a8054600160a060020a0383811673ffffffffffffffffffffffffffffffffffffffff19831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b600081815b855181101561211057600086828151811061208e5761208e6132b9565b602002602001015190508083116120d05760408051602081018590529081018290526060016040516020818303038152906040528051906020012092506120fd565b60408051602081018390529081018490526060016040516020818303038152906040528051906020012092505b508061210881613405565b915050612071565b509092149392505050565b600a5460a060020a900460ff16156121485760405160e560020a62461bcd028152600401610af1906133ce565b600a805474ff0000000000000000000000000000000000000000191660a060020a1790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258611f343390565b61219f848484611cac565b6121ab848484846127b2565b610fe85760405160e560020a62461bcd028152600401610af190613420565b606060006121d98360026131c4565b6121e49060026131ac565b67ffffffffffffffff8111156121fc576121fc612e0a565b6040519080825280601f01601f191660200182016040528015612226576020820181803683370190505b5090507f30000000000000000000000000000000000000000000000000000000000000008160008151811061225d5761225d6132b9565b6020010190600160f860020a031916908160001a9053507f7800000000000000000000000000000000000000000000000000000000000000816001815181106122a8576122a86132b9565b6020010190600160f860020a031916908160001a90535060006122cc8460026131c4565b6122d79060016131ac565b90505b600181111561237a577f303132333435363738396162636465660000000000000000000000000000000085600f1660108110612318576123186132b9565b1a7f01000000000000000000000000000000000000000000000000000000000000000282828151811061234d5761234d6132b9565b6020010190600160f860020a031916908160001a9053506010909404936123738161347d565b90506122da565b5083156123cc5760405160e560020a62461bcd02815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401610af1565b9392505050565b60608161241357505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b811561243d578061242781613405565b91506124369050600a836131fc565b9150612417565b60008167ffffffffffffffff81111561245857612458612e0a565b6040519080825280601f01601f191660200182016040528015612482576020820181803683370190505b5090505b8415611ca457612497600183613210565b91506124a4600a86613494565b6124af9060306131ac565b7f0100000000000000000000000000000000000000000000000000000000000000028183815181106124e3576124e36132b9565b6020010190600160f860020a031916908160001a905350612505600a866131fc565b9450612486565b61251582611f51565b601c54158015906125285750601c548211155b61259d5760405160e560020a62461bcd02815260206004820152602b60248201527f424153455f434f4c4c454354494f4e2f455843454544535f4d41585f5045525f60448201527f5452414e53414354494f4e0000000000000000000000000000000000000000006064820152608401610af1565b6000826125a98561122d565b6125b391906131ac565b905081158015906125c45750818111155b610fe85760405160e560020a62461bcd02815260206004820152602960248201527f424153455f434f4c4c454354494f4e2f455843454544535f494e44495649445560448201527f414c5f535550504c5900000000000000000000000000000000000000000000006064820152608401610af1565b3461264483836131c4565b11156126bb5760405160e560020a62461bcd02815260206004820152602760248201527f424153455f434f4c4c454354494f4e2f494e53554646494349454e545f45544860448201527f5f414d4f554e54000000000000000000000000000000000000000000000000006064820152608401610af1565b61102e3383611fdf565b600160a060020a0383166127205761271b81600880546000838152600960205260408120829055600182018355919091527ff3f7a9fe364faab93b216da50a3214154f22a0a2b415b23a84c8169e8b636ee30155565b612743565b81600160a060020a031683600160a060020a0316146127435761274383826128f4565b600160a060020a03821661275a57610c4981612991565b82600160a060020a031682600160a060020a031614610c4957610c498282612a40565b600061278d601080546001019055565b60006109d060105490565b61102e828260405180602001604052806000815250612a84565b6000600160a060020a0384163b156128e9576040517f150b7a02000000000000000000000000000000000000000000000000000000008152600160a060020a0385169063150b7a029061280f9033908990889088906004016134a8565b602060405180830381600087803b15801561282957600080fd5b505af1925050508015612859575060408051601f3d908101601f19168201909252612856918101906134da565b60015b6128b6573d808015612887576040519150601f19603f3d011682016040523d82523d6000602084013e61288c565b606091505b5080516128ae5760405160e560020a62461bcd028152600401610af190613420565b805181602001fd5b600160e060020a0319167f150b7a0200000000000000000000000000000000000000000000000000000000149050611ca4565b506001949350505050565b600060016129018461122d565b61290b9190613210565b60008381526007602052604090205490915080821461295e57600160a060020a03841660009081526006602090815260408083208584528252808320548484528184208190558352600790915290208190555b506000918252600760209081526040808420849055600160a060020a039094168352600681528383209183525290812055565b6008546000906129a390600190613210565b600083815260096020526040812054600880549394509092849081106129cb576129cb6132b9565b9060005260206000200154905080600883815481106129ec576129ec6132b9565b6000918252602080832090910192909255828152600990915260408082208490558582528120556008805480612a2457612a246134f7565b6001900381819060005260206000200160009055905550505050565b6000612a4b8361122d565b600160a060020a039093166000908152600660209081526040808320868452825280832085905593825260079052919091209190915550565b612a8e8383612aba565b612a9b60008484846127b2565b610c495760405160e560020a62461bcd028152600401610af190613420565b600160a060020a038216612b135760405160e560020a62461bcd02815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610af1565b600081815260026020526040902054600160a060020a031615612b7b5760405160e560020a62461bcd02815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610af1565b612b87600083836126c5565b600160a060020a0382166000908152600360205260408120805460019290612bb09084906131ac565b9091555050600081815260026020526040808220805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b828054612c2790613155565b90600052602060002090601f016020900481019282612c495760008555612c8f565b82601f10612c6257805160ff1916838001178555612c8f565b82800160010185558215612c8f579182015b82811115612c8f578251825591602001919060010190612c74565b50612c9b929150612c9f565b5090565b5b80821115612c9b5760008155600101612ca0565b600160e060020a03198116811461196857600080fd5b600060208284031215612cdc57600080fd5b81356123cc81612cb4565b60005b83811015612d02578181015183820152602001612cea565b83811115610fe85750506000910152565b60008151808452612d2b816020860160208601612ce7565b601f01601f19169290920160200192915050565b6020815260006123cc6020830184612d13565b600060208284031215612d6457600080fd5b5035919050565b600160a060020a038116811461196857600080fd5b60008060408385031215612d9357600080fd5b8235612d9e81612d6b565b946020939093013593505050565b600060208284031215612dbe57600080fd5b81356123cc81612d6b565b600080600060608486031215612dde57600080fd5b8335612de981612d6b565b92506020840135612df981612d6b565b929592945050506040919091013590565b60e060020a634e487b7102600052604160045260246000fd5b600067ffffffffffffffff80841115612e3e57612e3e612e0a565b604051601f8501601f19908116603f01168101908282118183101715612e6657612e66612e0a565b81604052809350858152868686011115612e7f57600080fd5b858560208301376000602087830101525050509392505050565b600082601f830112612eaa57600080fd5b6123cc83833560208501612e23565b600080600060608486031215612ece57600080fd5b833567ffffffffffffffff80821115612ee657600080fd5b612ef287838801612e99565b94506020860135915080821115612f0857600080fd5b612f1487838801612e99565b93506040860135915080821115612f2a57600080fd5b50612f3786828701612e99565b9150509250925092565b600080600080600080600080610100898b031215612f5e57600080fd5b505086359860208801359850604088013597606081013597506080810135965060a0810135955060c0810135945060e0013592509050565b60008083601f840112612fa857600080fd5b50813567ffffffffffffffff811115612fc057600080fd5b6020830191508360208083028501011115612fda57600080fd5b9250929050565b600080600060408486031215612ff657600080fd5b833561300181612d6b565b9250602084013567ffffffffffffffff81111561301d57600080fd5b61302986828701612f96565b9497909650939450505050565b6000806040838503121561304957600080fd5b823561305481612d6b565b91506020830135801515811461306957600080fd5b809150509250929050565b6000806000806080858703121561308a57600080fd5b843561309581612d6b565b935060208501356130a581612d6b565b925060408501359150606085013567ffffffffffffffff8111156130c857600080fd5b8501601f810187136130d957600080fd5b6130e887823560208401612e23565b91505092959194509250565b60008060006040848603121561310957600080fd5b83359250602084013567ffffffffffffffff81111561301d57600080fd5b6000806040838503121561313a57600080fd5b823561314581612d6b565b9150602083013561306981612d6b565b60028104600182168061316957607f821691505b6020821081141561318d5760e060020a634e487b7102600052602260045260246000fd5b50919050565b60e060020a634e487b7102600052601160045260246000fd5b600082198211156131bf576131bf613193565b500190565b60008160001904831182151516156131de576131de613193565b500290565b60e060020a634e487b7102600052601260045260246000fd5b60008261320b5761320b6131e3565b500490565b60008282101561322257613222613193565b500390565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f60408201527f776e6572206e6f7220617070726f766564000000000000000000000000000000606082015260800190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b60e060020a634e487b7102600052603260045260246000fd5b600081516132e4818560208601612ce7565b9290920192915050565b835460009081906002810460018083168061330a57607f831692505b602080841082141561332d5760e060020a634e487b710286526022600452602486fd5b81801561334157600181146133525761337f565b60ff1986168952848901965061337f565b60008c81526020902060005b868110156133775781548b82015290850190830161335e565b505084890196505b5050505050506133c46133be61339583886132d2565b7f2f00000000000000000000000000000000000000000000000000000000000000815260010190565b856132d2565b9695505050505050565b60208082526010908201527f5061757361626c653a2070617573656400000000000000000000000000000000604082015260600190565b600060001982141561341957613419613193565b5060010190565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527f63656976657220696d706c656d656e7465720000000000000000000000000000606082015260800190565b60008161348c5761348c613193565b506000190190565b6000826134a3576134a36131e3565b500690565b6000600160a060020a038087168352808616602084015250836040830152608060608301526133c46080830184612d13565b6000602082840312156134ec57600080fd5b81516123cc81612cb4565b60e060020a634e487b7102600052603160045260246000fdfea2646970667358221220170b5837e8391da87c96a2298fd2fbce4b093ea8236ec9008d24117ca70ecf1b64736f6c6343000809003300000000000000000000000000000000000000000000000000000000000000e0000000000000000000000000000000000000000000000000000000000000012000000000000000000000000000000000000000000000000000000000000001600000000000000000000000000000000000000000000000000000000000000280175956f5ac32de19fc127eeda3f1d1f9ffa9f3aefa8c22df73f04c8b6aa9560100000000000000000000000000000000000000000000000000000000000003a000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000006506561726c7300000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000006504541524c53000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000030000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002568747470733a2f2f706561726c732e68616e676e66742e78797a2f636f6e7472616374732f0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000008e1bc9bf040000000000000000000000000000000000000000000000000000007c58508723800000000000000000000000000000000000000000000000000000000000000015b3000000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000140000000000000000000000000000000000000000000000000000000061e432f00000000000000000000000000000000000000000000000000000000061e2e17000000000000000000000000000000000000000000000000000000000000000140000000000000000000000000000000000000000000000000000000000000002000000000000000000000000ccdfa1d254db47873bbd25d7afe85abf560034040000000000000000000000006ff0b7fba61bce14c49da1940ec7de4fa3343a5c000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000009
Deployed Bytecode
0x60806040526004361061033b576000357c01000000000000000000000000000000000000000000000000000000009004806374721235116101c8578063b88d4fde11610114578063e2d5ee2d116100b2578063e985e9c51161008c578063e985e9c514610900578063efef39a114610949578063f2fde38b1461095c578063fa156f9a1461097c57600080fd5b8063e2d5ee2d146108c0578063e33b7de3146108d6578063e8a3d485146108eb57600080fd5b8063ce7c2ac2116100ee578063ce7c2ac21461084d578063cf9e8e6914610883578063cfc86f7b14610898578063e2ab10ce146108ad57600080fd5b8063b88d4fde146107f8578063c0e7274014610818578063c87b56dd1461082d57600080fd5b80638da5cb5b116101815780639852595c1161015b5780639852595c146107775780639d044ed3146107ad578063a22cb465146107c2578063b85ef036146107e257600080fd5b80638da5cb5b1461072e578063904be6da1461074c57806395d89b411461076257600080fd5b806374721235146106845780637b96a3b2146106a45780637cb64759146106c45780638456cb59146106e45780638b83209b146106f95780638d859f3e1461071957600080fd5b80633f4ba83a116102875780635c975abb1161024057806366cfb1f31161021a57806366cfb1f314610624578063696fa41e1461063957806370a082311461064f578063715018a61461066f57600080fd5b80635c975abb146105cf5780635f0d246a146105ee5780636352211e1461060457600080fd5b80633f4ba83a1461052557806340a4dddd1461053a57806340c10f191461055a57806342842e0e1461057a5780634f6ccce71461059a578063547eb5b6146105ba57600080fd5b80631e84c413116102f457806323b872dd116102ce57806323b872dd146104ba5780632f745c59146104da5780632fc37ab2146104fa5780633a98ef391461051057600080fd5b80631e84c4131461047957806322f4596f1461048e578063235b6ea1146104a457600080fd5b806301ffc9a71461038957806306fdde03146103be578063081812fc146103e0578063095ea7b31461041857806318160ddd1461043a578063191655871461045957600080fd5b36610384577f6ef95f06320e7a25a04a175ca677b7052bdd97131872c2192525a629f51be7703360408051600160a060020a0390921682523460208301520160405180910390a1005b600080fd5b34801561039557600080fd5b506103a96103a4366004612cca565b610992565b60405190151581526020015b60405180910390f35b3480156103ca57600080fd5b506103d36109d6565b6040516103b59190612d3f565b3480156103ec57600080fd5b506104006103fb366004612d52565b610a68565b604051600160a060020a0390911681526020016103b5565b34801561042457600080fd5b50610438610433366004612d80565b610b16565b005b34801561044657600080fd5b506008545b6040519081526020016103b5565b34801561046557600080fd5b50610438610474366004612dac565b610c4e565b34801561048557600080fd5b506103a9610e4f565b34801561049a57600080fd5b5061044b60175481565b3480156104b057600080fd5b5061044b60155481565b3480156104c657600080fd5b506104386104d5366004612dc9565b610e6a565b3480156104e657600080fd5b5061044b6104f5366004612d80565b610e9e565b34801561050657600080fd5b5061044b60145481565b34801561051c57600080fd5b50600b5461044b565b34801561053157600080fd5b50610438610f49565b34801561054657600080fd5b50610438610555366004612eb9565b610f80565b34801561056657600080fd5b50610438610575366004612d80565b610fee565b34801561058657600080fd5b50610438610595366004612dc9565b611032565b3480156105a657600080fd5b5061044b6105b5366004612d52565b61104d565b3480156105c657600080fd5b506103d36110f4565b3480156105db57600080fd5b50600a5460a060020a900460ff166103a9565b3480156105fa57600080fd5b5061044b60165481565b34801561061057600080fd5b5061040061061f366004612d52565b611182565b34801561063057600080fd5b5061044b611210565b34801561064557600080fd5b5061044b601c5481565b34801561065b57600080fd5b5061044b61066a366004612dac565b61122d565b34801561067b57600080fd5b506104386112ca565b34801561069057600080fd5b5061043861069f366004612f41565b611301565b3480156106b057600080fd5b506103a96106bf366004612fe1565b611354565b3480156106d057600080fd5b506104386106df366004612d52565b6113df565b3480156106f057600080fd5b50610438611411565b34801561070557600080fd5b50610400610714366004612d52565b611446565b34801561072557600080fd5b5061044b611476565b34801561073a57600080fd5b50600a54600160a060020a0316610400565b34801561075857600080fd5b5061044b60195481565b34801561076e57600080fd5b506103d3611493565b34801561078357600080fd5b5061044b610792366004612dac565b600160a060020a03166000908152600e602052604090205490565b3480156107b957600080fd5b506103a96114a2565b3480156107ce57600080fd5b506104386107dd366004613036565b6114c8565b3480156107ee57600080fd5b5061044b601a5481565b34801561080457600080fd5b50610438610813366004613074565b611590565b34801561082457600080fd5b506103d36115c5565b34801561083957600080fd5b506103d3610848366004612d52565b6115d2565b34801561085957600080fd5b5061044b610868366004612dac565b600160a060020a03166000908152600d602052604090205490565b34801561088f57600080fd5b5060175461044b565b3480156108a457600080fd5b506103d36116bb565b6104386108bb3660046130f4565b6116c8565b3480156108cc57600080fd5b5061044b60185481565b3480156108e257600080fd5b50600c5461044b565b3480156108f757600080fd5b506103d36117d3565b34801561090c57600080fd5b506103a961091b366004613127565b600160a060020a03918216600090815260056020908152604080832093909416825291909152205460ff1690565b610438610957366004612d52565b6117e2565b34801561096857600080fd5b50610438610977366004612dac565b6118b3565b34801561098857600080fd5b5061044b601b5481565b6000600160e060020a031982167f780e9d630000000000000000000000000000000000000000000000000000000014806109d057506109d08261196b565b92915050565b6060600080546109e590613155565b80601f0160208091040260200160405190810160405280929190818152602001828054610a1190613155565b8015610a5e5780601f10610a3357610100808354040283529160200191610a5e565b820191906000526020600020905b815481529060010190602001808311610a4157829003601f168201915b5050505050905090565b600081815260026020526040812054600160a060020a0316610afa5760405160e560020a62461bcd02815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201527f697374656e7420746f6b656e000000000000000000000000000000000000000060648201526084015b60405180910390fd5b50600090815260046020526040902054600160a060020a031690565b6000610b2182611182565b905080600160a060020a031683600160a060020a03161415610bae5760405160e560020a62461bcd02815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e6560448201527f72000000000000000000000000000000000000000000000000000000000000006064820152608401610af1565b33600160a060020a0382161480610bca5750610bca813361091b565b610c3f5760405160e560020a62461bcd02815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610af1565b610c498383611a06565b505050565b600160a060020a0381166000908152600d6020526040902054610cdc5760405160e560020a62461bcd02815260206004820152602660248201527f5061796d656e7453706c69747465723a206163636f756e7420686173206e6f2060448201527f73686172657300000000000000000000000000000000000000000000000000006064820152608401610af1565b600c54600090610ced9030316131ac565b600160a060020a0383166000908152600e6020908152604080832054600b54600d909352908320549394509192610d2490856131c4565b610d2e91906131fc565b610d389190613210565b905080610db05760405160e560020a62461bcd02815260206004820152602b60248201527f5061796d656e7453706c69747465723a206163636f756e74206973206e6f742060448201527f647565207061796d656e740000000000000000000000000000000000000000006064820152608401610af1565b600160a060020a0383166000908152600e6020526040902054610dd49082906131ac565b600160a060020a0384166000908152600e6020526040902055600c54610dfb9082906131ac565b600c55610e088382611a81565b60408051600160a060020a0385168152602081018390527fdf20fd1e76bc69d672e4814fafb2c449bba3a5369d8359adf9e05e6fde87b056910160405180910390a1505050565b6000601a54600014158015610e65575042601a54105b905090565b610e743382611ba1565b610e935760405160e560020a62461bcd028152600401610af190613227565b610c49838383611cac565b6000610ea98361122d565b8210610f205760405160e560020a62461bcd02815260206004820152602b60248201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560448201527f74206f6620626f756e64730000000000000000000000000000000000000000006064820152608401610af1565b50600160a060020a03919091166000908152600660209081526040808320938352929052205490565b600a54600160a060020a03163314610f765760405160e560020a62461bcd028152600401610af190613284565b610f7e611e97565b565b600a54600160a060020a03163314610fad5760405160e560020a62461bcd028152600401610af190613284565b8251610fc0906012906020860190612c1b565b508151610fd4906011906020850190612c1b565b508051610fe8906013906020840190612c1b565b50505050565b600a54600160a060020a0316331461101b5760405160e560020a62461bcd028152600401610af190613284565b61102481611f51565b61102e8282611fdf565b5050565b610c4983838360405180602001604052806000815250611590565b600061105860085490565b82106110cf5760405160e560020a62461bcd02815260206004820152602c60248201527f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60448201527f7574206f6620626f756e647300000000000000000000000000000000000000006064820152608401610af1565b600882815481106110e2576110e26132b9565b90600052602060002001549050919050565b6012805461110190613155565b80601f016020809104026020016040519081016040528092919081815260200182805461112d90613155565b801561117a5780601f1061114f5761010080835404028352916020019161117a565b820191906000526020600020905b81548152906001019060200180831161115d57829003601f168201915b505050505081565b600081815260026020526040812054600160a060020a0316806109d05760405160e560020a62461bcd02815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201527f656e7420746f6b656e00000000000000000000000000000000000000000000006064820152608401610af1565b600061121a6114a2565b15611226575060195490565b5060185490565b6000600160a060020a0382166112ae5760405160e560020a62461bcd02815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a6560448201527f726f2061646472657373000000000000000000000000000000000000000000006064820152608401610af1565b50600160a060020a031660009081526003602052604090205490565b600a54600160a060020a031633146112f75760405160e560020a62461bcd028152600401610af190613284565b610f7e600061200d565b600a54600160a060020a0316331461132e5760405160e560020a62461bcd028152600401610af190613284565b601a97909755601b95909555601893909355601991909155601555601655601455601c55565b60006040516c01000000000000000000000000600160a060020a0386160260208201526000906034016040516020818303038152906040528051906020012090506113d684848080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050601454915084905061206c565b95945050505050565b600a54600160a060020a0316331461140c5760405160e560020a62461bcd028152600401610af190613284565b601455565b600a54600160a060020a0316331461143e5760405160e560020a62461bcd028152600401610af190613284565b610f7e61211b565b6000600f828154811061145b5761145b6132b9565b600091825260209091200154600160a060020a031692915050565b60006114806114a2565b1561148c575060165490565b5060155490565b6060600180546109e590613155565b6000601b546000141580156114b8575042601b54105b8015610e65575050601a54421090565b600160a060020a0382163314156115245760405160e560020a62461bcd02815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610af1565b336000818152600560209081526040808320600160a060020a03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b61159a3383611ba1565b6115b95760405160e560020a62461bcd028152600401610af190613227565b610fe884848484612194565b6011805461110190613155565b60606000601380546115e390613155565b905011156116295760136115f83060146121ca565b611601846123d3565b604051602001611613939291906132ee565b6040516020818303038152906040529050919050565b6012805461163690613155565b80601f016020809104026020016040519081016040528092919081815260200182805461166290613155565b80156116af5780601f10611684576101008083540402835291602001916116af565b820191906000526020600020905b81548152906001019060200180831161169257829003601f168201915b50505050509050919050565b6013805461110190613155565b600a5460a060020a900460ff16156116f55760405160e560020a62461bcd028152600401610af1906133ce565b611702338460195461250c565b61170a6114a2565b801561171c575061171c338383611354565b6117915760405160e560020a62461bcd02815260206004820152602360248201527f424153455f434f4c4c454354494f4e2f43414e4e4f545f4d494e545f5052455360448201527f414c4500000000000000000000000000000000000000000000000000000000006064820152608401610af1565b61179d83601654612639565b60165460405184919033907f38bd02858ca92987ff585a4c06998aea8187e96864df1eaf349dec3cfddc0fbb90600090a4505050565b6060601180546109e590613155565b600a5460a060020a900460ff161561180f5760405160e560020a62461bcd028152600401610af1906133ce565b61181c338260185461250c565b611824610e4f565b6118735760405160e560020a62461bcd02815260206004820152601b60248201527f424153455f434f4c4c454354494f4e2f43414e4e4f545f4d494e5400000000006044820152606401610af1565b61187f81601554612639565b60155460405182919033907f12cb4648cf3058b17ceeb33e579f8b0bc269fe0843f3900b8e24b6c54871703c90600090a450565b600a54600160a060020a031633146118e05760405160e560020a62461bcd028152600401610af190613284565b600160a060020a03811661195f5760405160e560020a62461bcd02815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f64647265737300000000000000000000000000000000000000000000000000006064820152608401610af1565b6119688161200d565b50565b6000600160e060020a031982167f80ac58cd0000000000000000000000000000000000000000000000000000000014806119ce5750600160e060020a031982167f5b5e139f00000000000000000000000000000000000000000000000000000000145b806109d057507f01ffc9a700000000000000000000000000000000000000000000000000000000600160e060020a03198316146109d0565b6000818152600460205260409020805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0384169081179091558190611a4882611182565b600160a060020a03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b3031811115611ad55760405160e560020a62461bcd02815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e63650000006044820152606401610af1565b600082600160a060020a03168260405160006040518083038185875af1925050503d8060008114611b22576040519150601f19603f3d011682016040523d82523d6000602084013e611b27565b606091505b5050905080610c495760405160e560020a62461bcd02815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d617920686176652072657665727465640000000000006064820152608401610af1565b600081815260026020526040812054600160a060020a0316611c2e5760405160e560020a62461bcd02815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201527f697374656e7420746f6b656e00000000000000000000000000000000000000006064820152608401610af1565b6000611c3983611182565b905080600160a060020a031684600160a060020a03161480611c74575083600160a060020a0316611c6984610a68565b600160a060020a0316145b80611ca45750600160a060020a0380821660009081526005602090815260408083209388168352929052205460ff165b949350505050565b82600160a060020a0316611cbf82611182565b600160a060020a031614611d3e5760405160e560020a62461bcd02815260206004820152602960248201527f4552433732313a207472616e73666572206f6620746f6b656e2074686174206960448201527f73206e6f74206f776e00000000000000000000000000000000000000000000006064820152608401610af1565b600160a060020a038216611dbc5760405160e560020a62461bcd028152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f2061646460448201527f72657373000000000000000000000000000000000000000000000000000000006064820152608401610af1565b611dc78383836126c5565b611dd2600082611a06565b600160a060020a0383166000908152600360205260408120805460019290611dfb908490613210565b9091555050600160a060020a0382166000908152600360205260408120805460019290611e299084906131ac565b9091555050600081815260026020526040808220805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b600a5460a060020a900460ff16611ef35760405160e560020a62461bcd02815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610af1565b600a805474ff0000000000000000000000000000000000000000191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b604051600160a060020a03909116815260200160405180910390a1565b60175481611f5e60085490565b611f6891906131ac565b11156119685760405160e560020a62461bcd02815260206004820152602260248201527f424153455f434f4c4c454354494f4e2f455843454544535f4d41585f5355505060448201527f4c590000000000000000000000000000000000000000000000000000000000006064820152608401610af1565b60005b81811015610c4957611ffb83611ff661277d565b612798565b8061200581613405565b915050611fe2565b600a8054600160a060020a0383811673ffffffffffffffffffffffffffffffffffffffff19831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b600081815b855181101561211057600086828151811061208e5761208e6132b9565b602002602001015190508083116120d05760408051602081018590529081018290526060016040516020818303038152906040528051906020012092506120fd565b60408051602081018390529081018490526060016040516020818303038152906040528051906020012092505b508061210881613405565b915050612071565b509092149392505050565b600a5460a060020a900460ff16156121485760405160e560020a62461bcd028152600401610af1906133ce565b600a805474ff0000000000000000000000000000000000000000191660a060020a1790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258611f343390565b61219f848484611cac565b6121ab848484846127b2565b610fe85760405160e560020a62461bcd028152600401610af190613420565b606060006121d98360026131c4565b6121e49060026131ac565b67ffffffffffffffff8111156121fc576121fc612e0a565b6040519080825280601f01601f191660200182016040528015612226576020820181803683370190505b5090507f30000000000000000000000000000000000000000000000000000000000000008160008151811061225d5761225d6132b9565b6020010190600160f860020a031916908160001a9053507f7800000000000000000000000000000000000000000000000000000000000000816001815181106122a8576122a86132b9565b6020010190600160f860020a031916908160001a90535060006122cc8460026131c4565b6122d79060016131ac565b90505b600181111561237a577f303132333435363738396162636465660000000000000000000000000000000085600f1660108110612318576123186132b9565b1a7f01000000000000000000000000000000000000000000000000000000000000000282828151811061234d5761234d6132b9565b6020010190600160f860020a031916908160001a9053506010909404936123738161347d565b90506122da565b5083156123cc5760405160e560020a62461bcd02815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401610af1565b9392505050565b60608161241357505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b811561243d578061242781613405565b91506124369050600a836131fc565b9150612417565b60008167ffffffffffffffff81111561245857612458612e0a565b6040519080825280601f01601f191660200182016040528015612482576020820181803683370190505b5090505b8415611ca457612497600183613210565b91506124a4600a86613494565b6124af9060306131ac565b7f0100000000000000000000000000000000000000000000000000000000000000028183815181106124e3576124e36132b9565b6020010190600160f860020a031916908160001a905350612505600a866131fc565b9450612486565b61251582611f51565b601c54158015906125285750601c548211155b61259d5760405160e560020a62461bcd02815260206004820152602b60248201527f424153455f434f4c4c454354494f4e2f455843454544535f4d41585f5045525f60448201527f5452414e53414354494f4e0000000000000000000000000000000000000000006064820152608401610af1565b6000826125a98561122d565b6125b391906131ac565b905081158015906125c45750818111155b610fe85760405160e560020a62461bcd02815260206004820152602960248201527f424153455f434f4c4c454354494f4e2f455843454544535f494e44495649445560448201527f414c5f535550504c5900000000000000000000000000000000000000000000006064820152608401610af1565b3461264483836131c4565b11156126bb5760405160e560020a62461bcd02815260206004820152602760248201527f424153455f434f4c4c454354494f4e2f494e53554646494349454e545f45544860448201527f5f414d4f554e54000000000000000000000000000000000000000000000000006064820152608401610af1565b61102e3383611fdf565b600160a060020a0383166127205761271b81600880546000838152600960205260408120829055600182018355919091527ff3f7a9fe364faab93b216da50a3214154f22a0a2b415b23a84c8169e8b636ee30155565b612743565b81600160a060020a031683600160a060020a0316146127435761274383826128f4565b600160a060020a03821661275a57610c4981612991565b82600160a060020a031682600160a060020a031614610c4957610c498282612a40565b600061278d601080546001019055565b60006109d060105490565b61102e828260405180602001604052806000815250612a84565b6000600160a060020a0384163b156128e9576040517f150b7a02000000000000000000000000000000000000000000000000000000008152600160a060020a0385169063150b7a029061280f9033908990889088906004016134a8565b602060405180830381600087803b15801561282957600080fd5b505af1925050508015612859575060408051601f3d908101601f19168201909252612856918101906134da565b60015b6128b6573d808015612887576040519150601f19603f3d011682016040523d82523d6000602084013e61288c565b606091505b5080516128ae5760405160e560020a62461bcd028152600401610af190613420565b805181602001fd5b600160e060020a0319167f150b7a0200000000000000000000000000000000000000000000000000000000149050611ca4565b506001949350505050565b600060016129018461122d565b61290b9190613210565b60008381526007602052604090205490915080821461295e57600160a060020a03841660009081526006602090815260408083208584528252808320548484528184208190558352600790915290208190555b506000918252600760209081526040808420849055600160a060020a039094168352600681528383209183525290812055565b6008546000906129a390600190613210565b600083815260096020526040812054600880549394509092849081106129cb576129cb6132b9565b9060005260206000200154905080600883815481106129ec576129ec6132b9565b6000918252602080832090910192909255828152600990915260408082208490558582528120556008805480612a2457612a246134f7565b6001900381819060005260206000200160009055905550505050565b6000612a4b8361122d565b600160a060020a039093166000908152600660209081526040808320868452825280832085905593825260079052919091209190915550565b612a8e8383612aba565b612a9b60008484846127b2565b610c495760405160e560020a62461bcd028152600401610af190613420565b600160a060020a038216612b135760405160e560020a62461bcd02815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610af1565b600081815260026020526040902054600160a060020a031615612b7b5760405160e560020a62461bcd02815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610af1565b612b87600083836126c5565b600160a060020a0382166000908152600360205260408120805460019290612bb09084906131ac565b9091555050600081815260026020526040808220805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b828054612c2790613155565b90600052602060002090601f016020900481019282612c495760008555612c8f565b82601f10612c6257805160ff1916838001178555612c8f565b82800160010185558215612c8f579182015b82811115612c8f578251825591602001919060010190612c74565b50612c9b929150612c9f565b5090565b5b80821115612c9b5760008155600101612ca0565b600160e060020a03198116811461196857600080fd5b600060208284031215612cdc57600080fd5b81356123cc81612cb4565b60005b83811015612d02578181015183820152602001612cea565b83811115610fe85750506000910152565b60008151808452612d2b816020860160208601612ce7565b601f01601f19169290920160200192915050565b6020815260006123cc6020830184612d13565b600060208284031215612d6457600080fd5b5035919050565b600160a060020a038116811461196857600080fd5b60008060408385031215612d9357600080fd5b8235612d9e81612d6b565b946020939093013593505050565b600060208284031215612dbe57600080fd5b81356123cc81612d6b565b600080600060608486031215612dde57600080fd5b8335612de981612d6b565b92506020840135612df981612d6b565b929592945050506040919091013590565b60e060020a634e487b7102600052604160045260246000fd5b600067ffffffffffffffff80841115612e3e57612e3e612e0a565b604051601f8501601f19908116603f01168101908282118183101715612e6657612e66612e0a565b81604052809350858152868686011115612e7f57600080fd5b858560208301376000602087830101525050509392505050565b600082601f830112612eaa57600080fd5b6123cc83833560208501612e23565b600080600060608486031215612ece57600080fd5b833567ffffffffffffffff80821115612ee657600080fd5b612ef287838801612e99565b94506020860135915080821115612f0857600080fd5b612f1487838801612e99565b93506040860135915080821115612f2a57600080fd5b50612f3786828701612e99565b9150509250925092565b600080600080600080600080610100898b031215612f5e57600080fd5b505086359860208801359850604088013597606081013597506080810135965060a0810135955060c0810135945060e0013592509050565b60008083601f840112612fa857600080fd5b50813567ffffffffffffffff811115612fc057600080fd5b6020830191508360208083028501011115612fda57600080fd5b9250929050565b600080600060408486031215612ff657600080fd5b833561300181612d6b565b9250602084013567ffffffffffffffff81111561301d57600080fd5b61302986828701612f96565b9497909650939450505050565b6000806040838503121561304957600080fd5b823561305481612d6b565b91506020830135801515811461306957600080fd5b809150509250929050565b6000806000806080858703121561308a57600080fd5b843561309581612d6b565b935060208501356130a581612d6b565b925060408501359150606085013567ffffffffffffffff8111156130c857600080fd5b8501601f810187136130d957600080fd5b6130e887823560208401612e23565b91505092959194509250565b60008060006040848603121561310957600080fd5b83359250602084013567ffffffffffffffff81111561301d57600080fd5b6000806040838503121561313a57600080fd5b823561314581612d6b565b9150602083013561306981612d6b565b60028104600182168061316957607f821691505b6020821081141561318d5760e060020a634e487b7102600052602260045260246000fd5b50919050565b60e060020a634e487b7102600052601160045260246000fd5b600082198211156131bf576131bf613193565b500190565b60008160001904831182151516156131de576131de613193565b500290565b60e060020a634e487b7102600052601260045260246000fd5b60008261320b5761320b6131e3565b500490565b60008282101561322257613222613193565b500390565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f60408201527f776e6572206e6f7220617070726f766564000000000000000000000000000000606082015260800190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b60e060020a634e487b7102600052603260045260246000fd5b600081516132e4818560208601612ce7565b9290920192915050565b835460009081906002810460018083168061330a57607f831692505b602080841082141561332d5760e060020a634e487b710286526022600452602486fd5b81801561334157600181146133525761337f565b60ff1986168952848901965061337f565b60008c81526020902060005b868110156133775781548b82015290850190830161335e565b505084890196505b5050505050506133c46133be61339583886132d2565b7f2f00000000000000000000000000000000000000000000000000000000000000815260010190565b856132d2565b9695505050505050565b60208082526010908201527f5061757361626c653a2070617573656400000000000000000000000000000000604082015260600190565b600060001982141561341957613419613193565b5060010190565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527f63656976657220696d706c656d656e7465720000000000000000000000000000606082015260800190565b60008161348c5761348c613193565b506000190190565b6000826134a3576134a36131e3565b500690565b6000600160a060020a038087168352808616602084015250836040830152608060608301526133c46080830184612d13565b6000602082840312156134ec57600080fd5b81516123cc81612cb4565b60e060020a634e487b7102600052603160045260246000fdfea2646970667358221220170b5837e8391da87c96a2298fd2fbce4b093ea8236ec9008d24117ca70ecf1b64736f6c63430008090033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
00000000000000000000000000000000000000000000000000000000000000e0000000000000000000000000000000000000000000000000000000000000012000000000000000000000000000000000000000000000000000000000000001600000000000000000000000000000000000000000000000000000000000000280175956f5ac32de19fc127eeda3f1d1f9ffa9f3aefa8c22df73f04c8b6aa9560100000000000000000000000000000000000000000000000000000000000003a000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000006506561726c7300000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000006504541524c53000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000030000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002568747470733a2f2f706561726c732e68616e676e66742e78797a2f636f6e7472616374732f0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000008e1bc9bf040000000000000000000000000000000000000000000000000000007c58508723800000000000000000000000000000000000000000000000000000000000000015b3000000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000140000000000000000000000000000000000000000000000000000000061e432f00000000000000000000000000000000000000000000000000000000061e2e17000000000000000000000000000000000000000000000000000000000000000140000000000000000000000000000000000000000000000000000000000000002000000000000000000000000ccdfa1d254db47873bbd25d7afe85abf560034040000000000000000000000006ff0b7fba61bce14c49da1940ec7de4fa3343a5c000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000009
-----Decoded View---------------
Arg [0] : name (string): Pearls
Arg [1] : symbol (string): PEARLS
Arg [2] : uris (string[]): ,,https://pearls.hangnft.xyz/contracts/
Arg [3] : numericValues (uint256[]): 40000000000000000,35000000000000000,5555,20,20,1642345200,1642258800,20
Arg [4] : merkleRoot (bytes32): 0x175956f5ac32de19fc127eeda3f1d1f9ffa9f3aefa8c22df73f04c8b6aa95601
Arg [5] : payees (address[]): 0xcCDFa1d254DB47873BBd25d7AfE85aBF56003404,0x6ff0b7FBA61bcE14c49Da1940eC7DE4fa3343a5C
Arg [6] : shares (uint256[]): 1,9
-----Encoded View---------------
35 Constructor Arguments found :
Arg [0] : 00000000000000000000000000000000000000000000000000000000000000e0
Arg [1] : 0000000000000000000000000000000000000000000000000000000000000120
Arg [2] : 0000000000000000000000000000000000000000000000000000000000000160
Arg [3] : 0000000000000000000000000000000000000000000000000000000000000280
Arg [4] : 175956f5ac32de19fc127eeda3f1d1f9ffa9f3aefa8c22df73f04c8b6aa95601
Arg [5] : 00000000000000000000000000000000000000000000000000000000000003a0
Arg [6] : 0000000000000000000000000000000000000000000000000000000000000400
Arg [7] : 0000000000000000000000000000000000000000000000000000000000000006
Arg [8] : 506561726c730000000000000000000000000000000000000000000000000000
Arg [9] : 0000000000000000000000000000000000000000000000000000000000000006
Arg [10] : 504541524c530000000000000000000000000000000000000000000000000000
Arg [11] : 0000000000000000000000000000000000000000000000000000000000000003
Arg [12] : 0000000000000000000000000000000000000000000000000000000000000060
Arg [13] : 0000000000000000000000000000000000000000000000000000000000000080
Arg [14] : 00000000000000000000000000000000000000000000000000000000000000a0
Arg [15] : 0000000000000000000000000000000000000000000000000000000000000000
Arg [16] : 0000000000000000000000000000000000000000000000000000000000000000
Arg [17] : 0000000000000000000000000000000000000000000000000000000000000025
Arg [18] : 68747470733a2f2f706561726c732e68616e676e66742e78797a2f636f6e7472
Arg [19] : 616374732f000000000000000000000000000000000000000000000000000000
Arg [20] : 0000000000000000000000000000000000000000000000000000000000000008
Arg [21] : 000000000000000000000000000000000000000000000000008e1bc9bf040000
Arg [22] : 000000000000000000000000000000000000000000000000007c585087238000
Arg [23] : 00000000000000000000000000000000000000000000000000000000000015b3
Arg [24] : 0000000000000000000000000000000000000000000000000000000000000014
Arg [25] : 0000000000000000000000000000000000000000000000000000000000000014
Arg [26] : 0000000000000000000000000000000000000000000000000000000061e432f0
Arg [27] : 0000000000000000000000000000000000000000000000000000000061e2e170
Arg [28] : 0000000000000000000000000000000000000000000000000000000000000014
Arg [29] : 0000000000000000000000000000000000000000000000000000000000000002
Arg [30] : 000000000000000000000000ccdfa1d254db47873bbd25d7afe85abf56003404
Arg [31] : 0000000000000000000000006ff0b7fba61bce14c49da1940ec7de4fa3343a5c
Arg [32] : 0000000000000000000000000000000000000000000000000000000000000002
Arg [33] : 0000000000000000000000000000000000000000000000000000000000000001
Arg [34] : 0000000000000000000000000000000000000000000000000000000000000009
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.